feat(ui): add R/F/D action shortcuts and unify keycap hint style

- Bind R=refresh, F=fetch metadata, D=download in PageControls via
  eventManager (plain letters only, skipped while typing or when a
  modal is open); triggers reuse the buttons' existing click handlers
- Show key-hint chips on the refresh/fetch/download/bulk toolbar
  buttons; convert the bulk chip to a semantic <kbd>
- Redesign shortcut hints as a neutral theme-adaptive keycap:
  --shortcut-* variables in base.css now derive from --text-muted
  with a bottom-edge shadow, shared by the toolbar chips, the header
  search cue, the help-modal cheat sheet, and onboarding key hints
- Add shared isTypingContext() helper to uiHelpers
- Add an Actions group (R/F/D) to the Shortcuts cheat-sheet tab

Verified with vitest (926 passing, incl. 6 new shortcut cases) and a
sandboxed E2E run in real Chrome (light/dark rendering, hover state,
'?' opening the Shortcuts tab, clean console)
This commit is contained in:
Will Miao
2026-09-03 19:10:16 +08:00
parent 8260bd022d
commit 726fc178f1
21 changed files with 253 additions and 25 deletions
+4
View File
@@ -1977,6 +1977,7 @@
"title": "[TODO: Translate] Keyboard & Mouse Shortcuts",
"groups": {
"general": "[TODO: Translate] General",
"actions": "[TODO: Translate] Actions",
"selection": "[TODO: Translate] Selection & Bulk Mode",
"navigation": "[TODO: Translate] Navigation",
"modelModal": "[TODO: Translate] Model / Recipe Modal",
@@ -1993,6 +1994,9 @@
"focusSearch": "[TODO: Translate] Focus search",
"closeModal": "[TODO: Translate] Close modal / panel",
"openShortcuts": "[TODO: Translate] Open this shortcuts panel",
"refresh": "[TODO: Translate] Refresh model list",
"fetchMetadata": "[TODO: Translate] Fetch metadata from CivitAI (model pages only)",
"downloadModel": "[TODO: Translate] Download a model (model pages only)",
"toggleBulkMode": "[TODO: Translate] Toggle bulk mode",
"selectAll": "[TODO: Translate] Select all visible models",
"rangeSelect": "[TODO: Translate] Range select",