Skip to content

feat(staged): add icon-only tier for narrow branch card footer#753

Merged
matt2e merged 1 commit into
mainfrom
narrow-branch-card
May 27, 2026
Merged

feat(staged): add icon-only tier for narrow branch card footer#753
matt2e merged 1 commit into
mainfrom
narrow-branch-card

Conversation

@matt2e
Copy link
Copy Markdown
Contributor

@matt2e matt2e commented May 27, 2026

Summary

  • Adds a third, icon-only display tier to the branch timeline's add-item buttons (New note / New commit / New code review) for very narrow widths (≤480px), so they remain usable when the branch card is squeezed.
  • Switches the responsive breakpoints from viewport @media to @container queries (container-type: inline-size on .timeline), so the tiers respond to the branch card's actual width instead of the window.
  • Adds aria-label to each button now that the text label can be hidden.

Test plan

  • Resize a branch card and confirm the add-item buttons transition through full-label → compact-label → icon-only tiers.
  • Verify enlarged buttons (.add-item-btn-enlarged) remain unaffected at all widths.
  • Screen reader / accessibility check: buttons announce correctly when only the icon is visible.

🤖 Generated with Claude Code

Replace viewport `@media` query on the timeline footer add-item buttons
with a container query on `.timeline`, and add a third icon-only tier
that drops labels entirely when the card is too narrow to fit the full
PR/Diff buttons alongside compact labels. Adds `aria-label` for screen
readers when the visible text is hidden.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Signed-off-by: Matt Toohey <contact@matttoohey.com>
@matt2e matt2e requested review from baxen and wesbillman as code owners May 27, 2026 05:17
@matt2e matt2e merged commit 2461444 into main May 27, 2026
5 checks passed
@matt2e matt2e deleted the narrow-branch-card branch May 27, 2026 05:22
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