.cursor/skills/fantasia-i18n/SKILL.md
Manages vue-i18n messages and locale structure for Fantasia Archive. Use when adding or changing user-facing strings, locale files under repo-root i18n/, or markdown-backed documents wired into i18n.
npx skillsauth add vishiri/fantasia-archive fantasia-i18nInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
vue-i18n v9.i18n/index.ts at the repository root (next to src/) exports locale keys (e.g. en-US, de) and merges each locale module. The Quasar app and externalFileLoader import it as app/i18n.src/boot/i18n.ts (declare module 'vue-i18n'). Under yarn lint:typescript, tsc may report TS2665 against the ESM module resolution; the boot file documents a @ts-expect-error for that line. Keep eslint-disable @typescript-eslint/no-empty-object-type on the augmentation block (typescript-eslint v8 rule name). See eslint-typescript.mdc.i18n/en-US/)i18n/
index.ts — merges en-US, fr, de, …
externalFileLoader.ts — standalone createI18n instance for Pinia / scripts
specialCharactersFixer.ts — escapes characters for vue-i18n message compiler
_tests/ — Vitest specs (**unit-i18n**)
en-US/
index.ts — composes the full locale tree; no hardcoded strings (see rules below)
documents/ — Markdown source files (.md); imported via ?raw and passed through specialCharacterFixer
components/<bucket>/<ComponentName>/ — mirrors src/components/: globals, elements, other (not foundation/; Storybook-only catalogues use inline English)
dialogs/ — one L_<DialogName>.ts per dialog (dialog copy; not the same as components/dialogs/)
pages/ — one L_<PageName>.ts per page
globalFunctionality/ — one L_<feature>.ts per app-wide, non-component concern (e.g. store notifications)
Do not place locale files in any other location. If no folder fits, use globalFunctionality/.
Naming: locale message files use the L_ prefix (for example L_programSettings.ts). TypeScript type aliases elsewhere in the app use T_ per project conventions — do not use T_ for locale filenames.
index.ts use camelCase with a lowercase first letter (e.g. globalWindowButtons, appControlMenus, dialogs, errorNotFound, globalFunctionality).L_*.ts modules also use camelCase with a lowercase first letter.index.ts must contain no hardcoded user-visible strings; every string lives in a dedicated L_*.ts file.documents section holds processed markdown strings, not static text — it is the only section that calls specialCharacterFixer; do not add plain string keys there. Those strings are still compiled as vue-i18n messages: avoid literal {...} in Markdown (for example glob .*.{vue,css}) or the in-app changelog and other document dialogs can throw message compilation errors — see fantasia-changelog-en-us.| as special (plural / list). To show a literal vertical bar in user-visible text, write \\| in the TypeScript string (backslash + pipe in the source so the runtime message contains \|, which compiles to a single |). The same escape style applies to @, {, }, and \ where you need them literally; see Intlify message syntax docs.globalFunctionality/. Uncategorised strings live in globalFunctionality/L_unsortedAppTexts.ts under the globalFunctionality.unsortedAppTexts key.index.ts must contain only imports and the composed export object. No hardcoded user-visible strings.L_* locale module (or, for documents, to its specialCharacterFixer(...) call).index.ts: markdown document imports first, then component L_* imports grouped by folder (components/, then dialogs/, then globalFunctionality/, then pages/).$t('camelCaseKey.subKey') — do not import useI18n just to call t(...) when $t is available in the template.import { i18n } from 'app/i18n/externalFileLoader' then i18n.global.t('camelCaseKey.subKey')..vue templates, _data/ files, or scripts; always route through an i18n key.components/<bucket>/<ComponentName>/, dialogs/, pages/, or globalFunctionality/).L_<name>.ts in that folder and add the new keys (camelCase, lowercase first letter).index.ts and assign it to a new camelCase top-level key.$t('topLevelKey.subKey')) or scripts (i18n.global.t('topLevelKey.subKey')).de, etc.) when those are maintained.L_* locale modules directly (for example app/i18n/en-US/components/globals/GlobalWindowButtons/L_GlobalWindowButtons.ts) instead of importing i18n/en-US/index.ts.documents/*.md, which can break Storybook/Vite import analysis.documents.*), provide explicit placeholder strings (for example lorem ipsum) in .storybook-workspace/.storybook/preview.ts rather than importing markdown files.types/)interface / type declarations in repository-root types/ (import with app/types/...). Prefer one domain-oriented module per feature area with brief JSDoc on exports (see types/I_appMenusDataList.ts). Do not add colocated <filename>.types.ts under src/, src-electron/, or .storybook-workspace/. Ambient augmentations for third-party modules also live under types/ and are loaded with a side-effect import from the owning boot file or src/stores/index.ts (see types/piniaModuleAugmentation.ts)..js), TypeScript (.ts), Vue (.vue), and JSON (.json, .jsonc, .json5) files, enforce expanded multi-line object literals via ESLint (object-curly-newline + object-property-newline) and keep files auto-fixable with eslint --fix.development
Splits working tree changes into logical Git commits with conventional messages (feat, fix, test, chore, refactor, style, docs). Proposes commits one at a time and waits for explicit user approval before each git commit. Use when the user asks to commit, split commits, stage by topic, or use conventional / semantic commit messages.
development
Aligns AI suggestions with Fantasia Archive as a worldbuilding database manager: projects, documents, and in-app concepts. Use when designing UX, data models, menus, or copy that should match the product purpose.
development
Runs and extends Fantasia Archive tests: Vitest unit tests vs Playwright component and E2E tests, including rebuild-before-Playwright rules and file naming. Use when writing tests, debugging CI, or when the user mentions Vitest, Playwright, component tests, or e2e.
development
Designs SQLite usage in Fantasia Archive’s Electron main process: file locations under userData, native better-sqlite3 module constraints, and migrations. Use when editing electron-main database code, schema, or persistence paths.