Skip to content

fix(accessibility): rename Variant menu to Power (#13) - #14

Open
payown wants to merge 1 commit into
mainfrom
power-menu-label
Open

payown wants to merge 1 commit into
mainfrom
power-menu-label

Conversation

@payown

@payown payown commented Nov 21, 2026 •

Copy link
Copy Markdown

Issue for this PR

Closes #13

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

The composer's model-variant picker announced itself as "Variant: Default". This renames it to "Power" so screen readers say "Power: Default".

The button's visible text is just the selected value (for example "Default"), so only the copy around it changes. The keys and the menu behavior stay the same:

  • Accessible name: Variant: {{variant}} → Power: {{variant}} (ui.promptInput.variantCurrent)
  • Tooltip and mobile drawer title: Choose model variant → Choose power (ui.promptInput.chooseVariant)
  • Command palette entry for the Shift+Mod+D cycle shortcut: Cycle model variant / Switch to the next model variant → Cycle power / Switch to the next power level

Only English changed. Following packages/app/AGENTS.md, the other locales keep their existing translations until a language review. The timeline notice "Switched variant to …" and the TUI aren't part of this issue, so they're unchanged.

The screen reader decides whether it says "menu button" or "button menu". The app sets aria-haspopup on the trigger, and this PR doesn't change that.

How did you verify your code works?

  • bun typecheck passes in packages/ui and packages/app, and the full repo bun run typecheck passes (35/35).
  • oxlint and prettier pass on the changed lines.
  • App unit tests for i18n, composer and models: 357 pass.
  • Composer component tests: 27 pass, 1 fails. The failing test, "keeps command selection on the keyboard until the pointer moves", fails the same way on main.
  • Added toHaveAccessibleName("Power: Default") and ("Power: High") to the existing keyboard test. That test also covers Tab, Enter, End and Escape. I confirmed the new assertion fails on the old string (Received: "Variant: Default").
  • Updated the mobile drawer tests and e2e tests to use the "Choose power" dialog name. I didn't run the full app e2e suite.
  • Tested manually with JAWS in the Windows desktop app: the button is announced as "Power" with the current value.
  • I pushed with --no-verify because the pre-push bun run check fails on main. script/check-greys.ts reports 172 greys, all in services/site, which this PR doesn't touch.

Screenshots / recordings

There's no visual change. The visible text is still the selected value.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

🤖 Generated with Claude Code

The composer's reasoning-variant picker was announced as "Variant: Default".
Rename its accessible name, tooltip/drawer title and the cycle command's
palette entry to "Power" so screen readers announce "Power: Default".

Closes #13

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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.

[FEATURE]: Rename “Variant” menu button to “Power” for screen reader clarity

1 participant