Skip to content

fix(ui): move Save to the first tab stop in the comment popover footer#1122

Open
balasivagn wants to merge 1 commit into
backnotprop:mainfrom
balasivagn:fix/comment-popover-save-tab-order
Open

fix(ui): move Save to the first tab stop in the comment popover footer#1122
balasivagn wants to merge 1 commit into
backnotprop:mainfrom
balasivagn:fix/comment-popover-save-tab-order

Conversation

@balasivagn

Copy link
Copy Markdown

Summary

  • Reorders the comment popover footer (packages/ui/components/CommentPopover.tsx) so Save is the first focusable control after the textarea, ahead of Ask AI and the image-upload button.
  • Tab order previously matched left-to-right DOM order (image icon → Ask AI → Save), so a fast keyboard flow (select text → comment → Tab, Tab, Enter) could land on the image-upload button instead of Save — the opposite of what you'd want for the primary action.
  • Pure reorder: no handler, class, or behavior changes. Mod+Enter/Escape are unaffected (they're wired on the textarea's onKeyDown, independent of button DOM position). Applied identically to both duplicated footer blocks in the file (dialog/expanded mode and popover mode). Since CommentPopover is shared, this fixes both the plan-review and code-review surfaces.

Fixes #1121

Test plan

  • packages/ui typechecks clean (tsc --noEmit on packages/ui/tsconfig.json and tsconfig.strict-consumer.json)
  • bun test — full suite passes (3 pre-existing, unrelated failures in packages/core/crypto.test.ts hitting the live paste service over the network, not touched by this change)
  • Rebuilt apps/review + apps/hook bundles and manually verified in the review-editor dev server: Save appears leftmost, and tabbing from the textarea reaches Save before Ask AI / the image icon, in both the inline popover and expanded dialog variants

Reorders the comment popover footer so Save is the first focusable
control after the textarea, ahead of Ask AI and the image-upload
button. Tab order previously matched DOM order left-to-right (image
icon, Ask AI, Save), so fast keyboard-driven flows (select text →
comment → Tab, Tab, Enter) could land on the image-upload button
instead of Save. Pure reorder, no behavior change.

Fixes backnotprop#1121

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
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.

Comment popover: Save button is the last tab stop, behind the image-upload icon

1 participant