Fantasia keybinds

From vishiri/fantasia-archive · View interactive version

Fantasia keybinds is an AI agent skill from the GitHub repository vishiri/fantasia-archive. Global keyboard shortcuts (faKeybinds): renderer matching, Pinia store, main-process persistence over IPC, and Keybind settings UI. Use when adding or changing app-wide shortcuts, capture validation, or bridge APIs for keybind storage.

How to use this skill

Skill file

Fantasia Archive — global keyboard shortcuts (faKeybinds)

What exists today

`src/scripts/keybinds/` — avoid fragmentation

Few domain modules: chord parse, equality/resolve, display/conflict, dispatch wiring. faKeybindRunCommand.ts stays thin for vi.mock seam — typescript-scripts.mdc.

Adding a new global command (checklist)

  1. types/I_faKeybindsDomain.ts — append FA_KEYBIND_COMMAND_IDS
  2. faKeybindCommandDefinitions.ts — one definition row
  3. i18n/*/dialogs/L_dialogKeybindSettings.ts — commands.<camelCaseId>
  4. faKeybindRunCommand.ts — FA_KEYBIND_COMMAND_TO_ACTION_ID row; register action in faActionDefinitions.ts
  5. Tests — run command, dispatch integration, definitions, store, dialog, Electron IPC/preload

Persisted schema changes → Zod in src-electron/shared/ + keybinds_manager + bridge sync.

Playwright (`keyboard.press`)

Use faPlaywrightKeyboardChords.ts — primary vs literal Control per faKeybindExpandDefaultChord. Docs: playwright-tests.mdc, fantasia-testing.

Related

Types

Shared types → types/. See types-folder.mdc.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.