cmux NEXT sidebar: avatar-only account control; its menu shows the team, Accounts… and Cloud

Merged
TE
15d ago
+293-127

Takes back #22569: Leo and Lawrence asked for the avatar alone in the sidebar footer (Lawrence: "should not show name down here, only icon"); #22569 had added the name and a chevron.

Summary

Avatar-only account control (Leo's request, 148.png). Before, the sidebar's bottom-left control was a chip: an off-center "L" in a circle, then the full email. Now it is the avatar alone at every width, with no name, email or chevron. The name shows on hover, and the full identity, team, Accounts… and Cloud are in the menu its click opens.

  • The initial is centered on its ink and the capital letter's height, not on its text box, so the "L" sits in the middle of the circle. This holds in the sidebar and in the menu's avatar image.
  • The initial is drawn heavier. The type scale gains a third weight, strong (700), for monogram initials; it is generated from schemas/type-scale/type-scale.json into Swift and CSS.
  • I described the screenshot here instead of attaching it, because it shows Leo's email and this repository is public.

This adds the team, Accounts… and Cloud to the account menu at the sidebar's bottom left (PRIORITIES 1.14). cmux NEXT already had the menu: the footer's avatar button is on by default and opens one native menu. That menu showed the signed-in name and email, Settings and Sign In or Sign Out. It did not show the team or Cloud.

Signed in, the menu now reads, top to bottom:

  1. The name and email (not clickable).
  2. The selected team, new. The row is the team's name with a person.2 icon, and it opens the team picker (openTeamPicker, ⌥⇧⌘T, shown on the row).
  3. The profile and its submenus (Bookmarks, Downloads, Extensions, History, Developers), then Show or Hide Chief and Settings.
  4. Accounts… (accounts.show, Settings › Accounts) and Cloud (palette.openCloudPane), new.
  5. New Tab and Incognito Window, then Sign Out.

Signed out, the team row is absent and the menu ends with Sign In.

Every row runs a registry action, so the menu, the palette, the CLI and MCP share one path. A build that doesn't bind an action leaves its row out. The Cloud row reuses the Cloud page's own wording, in all 21 locales.

Before opening this, I searched open and merged PRs for the menu. Related work:

  • #14893 and #20853 are the classic app's footer menus and target main.
  • #21233 adds a team switcher in Settings › Accounts.
  • #22377 adds Sign Out per provider.

This PR changes none of their files.

Observed / Not run

  • ProfileMenuBuilderTests.accountsAndCloudFollowSettings checks the order and that unbound rows are left out. SidebarAccountMenuTests checks the team row (its position, icon and run) and that no team means no row.
  • Ran scripts/cmux-next/prepush-gate.py (no new violations) and scripts/localization_catalog.py check (no error on menu.profile.cloud).
  • Not run locally: the Swift build and tests. CI covers them, and this PR waits for a compile before it merges.
  • SidebarProfileChipTests checks that the control is the avatar's square at 240 and 120 pt, with no name and no chevron, and that its tooltip names the profile. theInitialIsCenteredInItsCircle checks the ink and cap-height centering, flipped and unflipped.
  • Ran scripts/web-lint.sh for the generated CSS token (passed).
  • No capture yet: the menu and the avatar are native AppKit, and I haven't recorded them on a capture mini.

Changelog

  • Added: The sidebar's account menu shows your cmux team (click to switch), Accounts… and Cloud.
  • Changed: The sidebar's account control is just your avatar, with the initial centered and bolder.

Agent session: cosmic-gray

🤖 Generated with Claude Code