Skip to content

feat(platform): show readers live automation navigation - #3779

Merged
yannickmonney merged 11 commits into
mainfrom
feat/automations-tile-for-readers
Sep 29, 2026
Merged

yannickmonney merged 11 commits into
mainfrom
feat/automations-tile-for-readers

Conversation

@yannickmonney

@yannickmonney yannickmonney commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Members and Editors now see Automations in the desktop rail and phone navigation once an organization-wide automation is deployed. Owners, Admins and Developers always see it. Reader lists show deployed automations only, with their own empty state; authors keep the complete list and the creation actions. Direct URLs and backend permissions are unchanged. This comes from customer feedback.

One predicate (app/features/automations/lib/reader-listing.ts) holds the reader rule. The org list, a project's list and the project shell all use it, so a project gives readers an Automations tab only when a bound automation is deployed. A project whose only binding is an undeployed draft has no tab for them, rather than a tab that opens an empty list.

The rail's availability check reads the all-projects listing that the Inbox check, the org list and its route loader already cache. It counts deployed rows that have no project IDs. That listing returns every binding unfiltered (listAutomationsForApp), so an empty projectIds means the automation is bound to no project. Authors skip the read entirely. An earlier revision of this PR used a separate organization-only query. The reason it gave, that the app strips unreadable project IDs, was wrong, so that query and its fictional regression test are gone.

The Inbox setup notice no longer sends readers to an empty list. Members and Editors are told that someone with the Owner, Admin or Developer role must deploy an email automation, and they get no Browse automations link. The compose notice is reworded for them in the same way. Authors see what they saw before. The French reader empty state now uses the role labels Propriétaire, Admin and Développeur.

EN/DE/FR messages and guides describe the same role and project scope. The built-in automations guide describes both Inbox notices.

Dependency. The org list asks for includeProjectBound: true, and the server applies no project-visibility filter to it. This is true on main too. So a reader who opens the org list still sees deployed automations bound to projects they cannot open, each with a generic project-bound badge. Now that readers get a nav entry, they reach that list without typing a URL. #3772 adds the visibility filter and should land before this PR, or together with it. This PR does not change that behaviour, and no manual box asserts it until #3772 lands.

Checklist

  • bun run check passes: N/A locally. I skipped the full run on this shared host and ran the scoped gates listed below. CI runs the full check.
  • bun run lint:sast passes: the scoped Opengrep pass ran on every staged TS/TSX file through the commit hook. No full run.
  • Translations updated in messages/{en,de,fr}.yml: automations.list.emptyReader.*, conversations.activate.noAutomationReaderDescription and conversations.activate.composeNoticeReader. No de-CH override is needed (no ß).
  • Docs updated in docs/{en,de,fr}/: the platform overview, member overview, automations catalog and built-in automations pages.
  • README.md / README.de.md / README.fr.md: N/A, no README-level change.

Test plan

Committed automated coverage (jsdom UI project):

  • reader-listing.test.ts covers the shared predicate.
  • use-automations-availability.test.ts checks the query arguments (the all-projects listing), and that only deployed rows with no project IDs count, including in a mixed listing.
  • use-navigation-items.test.ts checks tile visibility for authors and readers, that authors skip the availability read, and that readers ask about the active organization.
  • automations-list.test.tsx and mobile-bottom-nav.test.tsx cover the reader list and phone navigation.
  • $projectId.test.tsx checks that readers get no tab when only a draft is bound, and get one once a bound automation is deployed.
  • conversations.test.tsx checks the reader setup notice and that it has no link, and the reader compose notice.

The new project-tab and Inbox-reader tests failed against the previous head (3 failures) and pass now.

Commands run on the final head:

  • bunx vitest --run --config vitest.ui.config.ts over app/features/automations, app/components/layout, use-navigation-items, the project shell and conversations tests: 62 files, 502 tests passed.
  • bunx vitest --run --project server lib/i18n: 185 passed, covering locale parity and used-but-undefined keys.
  • bunx tsc --noEmit for the platform: clean.
  • Workspace oxlint --type-aware on the touched files: clean.
  • bun run lint:manual and check-guide.ts on the automations, conversations and navigation suites: OK.
  • Docs tests (services/docs): 171 passed.

Manual boxes: NAV-F43 covers the rail and tab bar. AUTO-F53 covers the reader list and now the project tab. The new CONV-G4 covers the reader Inbox notice.

Not verified: an earlier revision was checked in native Chromium across EN/DE/FR, desktop and phone, in ad-hoc browser runs. Those runs are not committed and were not repeated on this head. No live two-session deployment and no screenshot pass were done. Follow-up: the built-in automations guide has no screenshot of the Inbox setup notice, so no screenshot needs refreshing.

…is live

Only Owners, Admins and Developers can author automations, yet every member
saw the Automations tile and a list of the ten seeded packages, all "Not
deployed", with an empty state that invited them to create what they
cannot. Customers asked to hide the section from members; a per-org switch
would have looked like access control while the routes stayed open, and
left every other organization with the same clutter.

The section now follows the viewer instead. Authors (the ability the
server's author gate mirrors) always see it; everyone else sees it once the
organization runs a deployed organization automation — one bound to no
project, since project-bound automations show on their project's tab. The
signal reads the listing the Inbox check already subscribes to, so the nav
makes no new request. A non-author's list shows deployed automations only,
with its own empty state; the author's empty state now names the Create
automation button. Direct URLs keep working: this is presentation, not
access control.
@yannickmonney yannickmonney changed the title feat(platform): show Automations to non-builders only when something is live feat(platform): show readers live automation navigation Sep 28, 2026
The reader empty state spelled the roles as common nouns (un
propriétaire, un administrateur, un développeur) while English and
German use the role labels. Use the French labels Propriétaire, Admin
and Développeur, as the role picker and the French guides do.
Members and Editors see deployed automations only, but the project shell
counted every bound automation when deciding whether to show its
Automations tab. A project whose only bound automation was an undeployed
draft therefore gave readers a tab that opened the empty "No live
automations" list, which the shell exists to avoid.

Move the reader rule into one predicate (reader-listing) and apply it in
both the list and the project shell, so the tab counts exactly what the
list will show this viewer. The manual box for the reader list now covers
the project tab too.
The rail's availability check asked for a separate organization-only
listing on the stated ground that the all-projects listing hides project
IDs the viewer cannot read. It does not: the listing returns every
binding unchanged, so a row with no project IDs is exactly an automation
bound to no project. The second query only added a request per
dashboard boot, and its regression test mocked a response nothing
produces.

Read the all-projects listing the Inbox check, the org list and its
route loader already cache, count deployed rows with no project IDs, and
skip the read entirely for authors, who see the section regardless. The
fictional test is replaced by one that pins the query arguments and a
mixed listing.
The Inbox setup notice offered every role a "Browse automations" link.
The mail packages are seeded undeployed, and readers now see deployed
automations only, so a Member or Editor who followed it landed on an
empty list with no way forward; the compose notice also told them to
install an automation they cannot install.

Readers now get copy that names the Owner, Admin and Developer roles and
no link, and a compose notice that says the email can be written once a
mail automation is deployed. Authors keep the link. The strings ship in
EN, DE and FR, the built-in automations guide describes both notices,
and a new manual box covers the reader deep link.
…-for-readers

# Conflicts:
#	services/platform/tests/manual/readme.md
…-for-readers

# Conflicts:
#	services/platform/tests/manual/readme.md
…-for-readers

# Conflicts:
#	services/platform/tests/manual/suites/automations.md
@yannickmonney
yannickmonney merged commit ee7c6bb into main Sep 29, 2026
50 checks passed
@yannickmonney
yannickmonney deleted the feat/automations-tile-for-readers branch September 29, 2026 03:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant