Description
This is a UI/UX issue surfacing keyboard shortcuts inside tooltips. The components/navbar/SearchInput.tsx should show "Cmd+K", BetConfirmPattern should show "Enter to confirm", and so on, rendered as styled <kbd> chips.
Requirements and Context
- New
components/ui/kbd.tsx primitive
- Centralised shortcut map in
lib/shortcuts.ts
- Tooltip respects OS (Cmd on macOS, Ctrl elsewhere)
- Must be secure, tested, and documented
- Should be efficient and easy to review
Suggested Execution
- Fork the repo and create a branch
git checkout -b feature/kbd-shortcut-hints
- Implement changes
- Add
components/ui/kbd.tsx, lib/shortcuts.ts
- Edit
components/navbar/SearchInput.tsx, components/patterns/BetConfirmPattern.tsx
- Test and commit
- Snapshot tests across macOS and Windows UA
- Cover edge cases (touch devices hide hints)
- Include test output and notes in the PR
Example commit message
feat: kbd shortcut hints in tooltips
Acceptance Criteria
Guidelines
- WCAG 2.1 AA, kbd semantics
- Clear documentation and inline comments
- Timeframe: 96 hours
Description
This is a UI/UX issue surfacing keyboard shortcuts inside tooltips. The
components/navbar/SearchInput.tsxshould show "Cmd+K", BetConfirmPattern should show "Enter to confirm", and so on, rendered as styled<kbd>chips.Requirements and Context
components/ui/kbd.tsxprimitivelib/shortcuts.tsSuggested Execution
components/ui/kbd.tsx,lib/shortcuts.tscomponents/navbar/SearchInput.tsx,components/patterns/BetConfirmPattern.tsxExample commit message
Acceptance Criteria
Guidelines