Commit Graph

278 Commits

Author SHA1 Message Date
Georges-Antoine Assi
5600324f21 Merge remote-tracking branch 'origin/master' into feat/frontend-eslint-guideline-rules
# Conflicts:
#	.claude/skills/review-polish/SKILL.md
2026-09-26 10:39:09 -04:00
Georges-Antoine Assi
1c2a60a776 refactor(frontend): parse SFC styles with PostCSS, resolve the lib boundary (simplify)
- Style rules walk a PostCSS AST parsed once per file instead of
  hand-rolled declaration, @media and comment regexes. postcss becomes a
  direct devDependency at the version already in the lockfile.
- The src/v2/lib boundary uses import-x/no-restricted-paths, so aliases
  and relative imports resolve to the same zones. The resolver now knows
  .d.ts so the emitter types match.
- typescript-eslint's eslintRecommended applies to .vue in place of a
  single no-undef override.
- A reportAt helper replaces the per-rule loc boilerplate, and sfc()
  carries the test filename.
- The Trunk no-emdash linter runs batched.
- CLAUDE.md and address-bot-reviews point to review-polish instead of
  repeating the encode-a-check guidance.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-26 10:31:43 -04:00
Georges-Antoine Assi
3c09cd9e4c chore(frontend): drop the lint script in favour of trunk check
Trunk already runs ESLint with the same config in CI, scoped to changed files and respecting the v1 ignores.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-26 08:13:24 -04:00
Stuart Anderson
f09d96360d chore: no emdash IN COMMENTS specifically 2026-09-24 15:34:42 -05:00
Sam Dornan
44ed3b3cb3 Upgrade vitest and @vitest/ui to v5
Bumps vitest and @vitest/ui from 4.1.11 to 5.0.1. No config or test
changes were needed. The full suite (208 files, 2483 tests) and the
Storybook play() suite pass; typecheck is clean.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GA4rTTBz2roX6zgK9VSBr3
2026-09-24 04:00:18 +00:00
Georges-Antoine Assi
e4b341d233 Merge remote-tracking branch 'origin/master' into chore/dpdm-circular-deps
# Conflicts:
#	docs/FRONTEND_ARCHITECTURE.md
2026-09-22 08:59:05 -04:00
Georges-Antoine Assi
728354c157 Merge pull request #4609 from rommapp/claude/css-prefixing-dev-and-prod
build(frontend): prefix CSS in dev as well as production
2026-09-22 08:52:20 -04:00
Georges-Antoine Assi
836d88ad64 Merge pull request #4575 from andest01/chore/vite-config-ts
chore: expand ts typecheck to `frontend/scripts/**/*.ts`
2026-09-22 08:09:49 -04:00
Georges-Antoine Assi
b2d5ffb4b4 chore: split the scripts typecheck into its own script
Keep `typecheck` to vue-tsc and move the tsconfig.node.json pass to
`typecheck:scripts`, run as a separate CI step so a failure names the
pass that broke. Drop the JSON-invalid comments from tsconfig.node.json.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-09-22 07:41:36 -04:00
Georges-Antoine Assi
0fcf674045 build(frontend): detect import cycles with eslint instead of dpdm
dpdm cannot resolve or parse Vue SFCs, so it saw none of the ~519
components: `.vue` imports were dead ends and the graph stopped at the
first one. `import-x/no-cycle` runs on the ESLint config that already
parses `.vue` with type awareness, and Trunk already runs ESLint in CI,
so the check needs no separate tool, config file or CI step.

Lazy route components make the router reachable from the views it
renders, so dynamic edges are excluded; without that the rule reports
390 files instead of the real 3. Those 3 are the frozen-v1 `src/console`
cycles dpdm also found, so the two tools agree on today's graph and the
swap is not a cleanup.

Drop the `circular` script, `dpdm.config.ts`, the `@dpdm-ignore`
directive and dpdm itself.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-09-20 11:07:53 -04:00
Stuart Anderson
d476723241 chore: surface circular dependencies via dpdm 2026-09-19 15:42:26 -05:00
Georges-Antoine Assi
0f7f10ccbe Merge pull request #4627 from rommapp/dependabot/npm_and_yarn/frontend/md-editor-v3-6.5.4
chore(deps): bump md-editor-v3 from 5.8.5 to 6.5.4 in /frontend
2026-09-18 16:43:58 -04:00
dependabot[bot]
2ab69d9e65 chore(deps): bump md-editor-v3 from 5.8.5 to 6.5.4 in /frontend
Bumps [md-editor-v3](https://github.com/imzbf/md-editor-v3) from 5.8.5 to 6.5.4.
- [Release notes](https://github.com/imzbf/md-editor-v3/releases)
- [Changelog](https://github.com/imzbf/md-editor-v3/blob/develop/CHANGELOG.md)
- [Commits](https://github.com/imzbf/md-editor-v3/compare/v5.8.5...v6.5.4)

---
updated-dependencies:
- dependency-name: md-editor-v3
  dependency-version: 6.5.4
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-09-18 17:27:02 +00:00
Sam Dornan
374f6dac4e Merge branch 'master' into claude/typescript-upgrade-eval-j65v0x
The overview table in docs/FRONTEND_ARCHITECTURE.md conflicted: master
updated the Vue row to 3.5 and re-wrapped the column, this branch bumped the
TypeScript row. Resolved by keeping master's table and carrying the
TypeScript 5.9.3 bump into it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SvDZhPHsNguuX5zqFjDfSD
2026-09-18 15:39:20 +00:00
Sam Dornan
896cb77f2e chore(frontend): upgrade vue-tsc to 3.x and raise the TypeScript floor
vue-tsc 2.2.x runs on the old Volar core; 3.x cuts a full typecheck of the
196k-LOC frontend from 47.2s to 36.1s with no new diagnostics.

The declared TypeScript floor of ^5.7.3 already resolved to 5.9.3, so raising
it to ^5.9.3 only makes the constraint honest and satisfies @vue/tsconfig
0.9's `typescript >= 5.8` peer.

erasableSyntaxOnly makes the existing style a compiler rule: Vite strips types
with esbuild, so enums, namespaces and parameter properties would not survive
the transform. The codebase already has none, and the flag reports 0 errors.

TypeScript 6 and 7 are deliberately not taken. 7.0 is the native port and
drops the JS compiler API, which both vue-tsc and typescript-eslint still
require, so each fails to start under it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SvDZhPHsNguuX5zqFjDfSD
2026-09-18 15:31:28 +00:00
Sam Dornan
ffd26fe6dc fix(a11y): translate the v2 primitives' own control labels (#4620)
* fix(a11y): translate the v2 primitives' own control labels

The library hard-coded 20 English strings for controls a primitive
renders on its own behalf, so screen-reader users heard English in every
locale: close on RDialog/RDrawer/RCarousel, remove on RChip/RSelect/
RComboboxField, clear on RTextField/RSelect/RComboboxField/RDateField,
RDateField's picker toggle and four month/year steppers, plus the
visible "Today" and "All" text.

The overridable-prop pattern was already there and had already failed:
RCarousel's closeLabel/prevLabel/nextLabel and RDateField's
clearLabel/todayLabel defaulted to English literals and no call site
ever passed one. Extending it would have made translation depend on
roughly 130 call sites each remembering to pass a label for a string
that is identical at every one of them.

Instead the app provides one bundle and every primitive reads it through
useChromeLabels(). The provider hands over getters that resolve via
i18n, so they run inside the reading component's render effect and a
locale switch re-renders the labels with no refs to unwrap. inject is
plain Vue, so lib still imports no i18n, and the English defaults keep a
bare mount rendering an accessible name. The existing label props stay
as per-instance overrides, now defaulting to undefined so they resolve
through the bundle.

Reuses common.close, common.clear, common.remove and common.all; adds
eight common.* keys across all 18 locales for the date-field steppers
and carousel navigation. setup.previous/next were left alone: they are
wizard step semantics ("previous step", "back"), not item navigation.

Storybook provides the same bundle, so stories exercise the real path.
Two tests guard the decay this had already suffered once: that an
injected bundle reaches a primitive's aria-label, and that every label
resolves to a real translation in every locale.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ENyaGKiTZiwPGH7qyN4iMe

* refactor: tighten the chrome-label comments and use import.meta.url

Condense the module header and the test's header to the repo's comment
limit, and derive the locales directory from import.meta.url rather than
__dirname, matching the review feedback on #4619.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ENyaGKiTZiwPGH7qyN4iMe

* fix(a11y): cover RAlert and RSteps, and test the real locale switch

RAlert's close button and RSteps' stepper name were missed on the first
pass: RAlert writes its label as a bound string literal
(:aria-label="'Close'") and RSteps builds "Step 2 of 5" from a template
string, neither of which the plain aria-label="Text" scan matched. Both
now read the injected bundle, which gains a step(current, total) member
backed by common.step-of across all 18 locales.

The locale-propagation test previously flipped a local variable and
called $forceUpdate, which only proved a getter re-reads on render. It
now mounts against createChromeLabels(), switches i18n.global.locale and
asserts the rendered label changes on its own, so it exercises the path
the app actually uses. RAlert and RSteps get assertions of their own.

Wrap the new skill bullet so it stops adding a markdownlint line-length
violation, and drop three comments that only restated the ?? beside them.

Reported by Copilot (RAlert) and Greptile (test, comments) on #4620.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ENyaGKiTZiwPGH7qyN4iMe

* fix(a11y): put RDateField's combobox role on its focusable input

The role sat on the field's wrapper div, which is not focusable and had
no aria-controls, so the two accessibility lints on it were right:
assistive tech saw a combobox it could not reach and that pointed at no
popup. The previous comment explained why the role could not go on
RTextField, and it was accurate: RTextField binds $attrs to its outer
element, which becomes a <label> when it owns the visible label, where
the role is disallowed.

So give RTextField a typed `popup` prop that lands role="combobox",
aria-haspopup, aria-expanded and aria-controls on the native input,
where ARIA 1.2 wants them. A single object prop rather than an attribute
bag keeps arbitrary attributes off the input. RDateField passes it,
drops the role from the wrapper (keeping the keydown handler, which is
what the wrapper is actually for) and gives the teleported panel a
useId() so aria-controls resolves.

The wrapper never was a tab stop, so no tab order changes: the input it
delegates to is the same element that now carries the role.

Covers the two vuejs-accessibility errors that eslint reported against
this file on master; src/v2/lib is now lint-clean.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ENyaGKiTZiwPGH7qyN4iMe

* fix(a11y): make popup and multiline exclusive, and tighten comments

The new `popup` prop rendered its combobox attributes only on the
<input> branch, so a caller that also set `multiline` type-checked but
got a plain <textarea> with none of the role, expanded state or popup
association it asked for. Binding them to the textarea instead is not an
option: ARIA in HTML allows no role override on <textarea>, so
role=combobox there would be invalid. The conflict now reports itself
through console.error rather than dropping the ARIA in silence, and the
prop documents the single-line constraint.

Adds RTextField.test.ts covering all three cases: the role landing on
the input while the <label> outer element stays clear of it, no
combobox attributes when the prop is absent, and the conflict being
reported.

Also drop a sentence recording what the code used to do, which CLAUDE.md
rules out, and shorten the RDateField template comment.

Reported by Greptile (both P2) on #4621.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ENyaGKiTZiwPGH7qyN4iMe

* chore(deps): declare the Vue 3.5 floor the code already requires

useId lands in Vue 3.5 and RComboboxField has been calling it on master,
so the declared ^3.4.27 range understated the real minimum: a resolution
inside 3.4 would fail to build. The lockfile already pins 3.5.29, so
this only corrects the manifest and changes no resolved version.

RTextField carried a comment claiming the project was "on 3.4 still",
which is what made useId look like a regression in review; it is gone,
and the architecture doc's framework row now matches.

Also stop advertising aria-controls while the picker is closed. The
panel is v-if'd, so the input pointed at an element that was not in the
document; `controls` is now optional and RDateField passes it only while
the panel is mounted, with the closed state asserted.

Reported by Copilot on #4621.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ENyaGKiTZiwPGH7qyN4iMe

* refactor: drop a comment recording what the code used to do

The describe name already states what the block verifies, and the rest
was change history, which CLAUDE.md rules out.

Reported by Greptile on #4620.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ENyaGKiTZiwPGH7qyN4iMe

---------

Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
2026-09-18 10:19:33 -05:00
Sam Dornan
c1183109c6 build(frontend): prefix CSS in dev as well as production
Vendor prefixes were generated only on the build's minify path, so the dev
server served `backdrop-filter` with no `-webkit-` twin. caniuse has Safari
16.3-17.6 as supported-with-prefix, which left every glass surface unblurred
while developing in Safari below 18.4. Two rules papered over it by hand, and
that made production worse: Lightning CSS collapses such a pair to whichever is
declared last, dropping the standard property for Chrome, Edge and Firefox.

Lightning CSS as the CSS transformer covers both paths from one setting. Dev now
serves both properties, verified against the running server.

That also retires the hand-rolled browserslist-to-esbuild conversion. It existed
because `target: "esnext"` was inherited by `cssTarget`, and Vite's
`convertTargets` skips the `esnext` entry, leaving Lightning CSS with no targets
at all. Vite's default target resolves to chrome111, edge111, firefox114,
safari16.4, ios16.4, which both the transformer and the minifier read, so the
converter, both explicit targets and the `browserslist` dependency all go.

`.browserslistrc` goes with them: nothing reads it once the conversion is gone.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BEtFQ17BQDS52wXosTjcUU
2026-09-18 00:52:31 +00:00
Stuart Anderson
f947da3778 chore: typecheck frontend/scripts via tsconfig.node.json 2026-09-17 10:50:28 -05:00
Sam Dornan
68aa2501e5 fix(frontend): stop ESLint and Prettier fighting over formatting (#4456) 2026-09-11 10:19:47 -05:00
dependabot[bot]
68ad8ad35b chore(deps-dev): bump vitest from 4.1.8 to 4.1.11 in /frontend
Bumps [vitest](https://github.com/vitest-dev/vitest/tree/HEAD/packages/vitest) from 4.1.8 to 4.1.11.
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Changelog](https://github.com/vitest-dev/vitest/blob/main/docs/releases.md)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.11/packages/vitest)

---
updated-dependencies:
- dependency-name: vitest
  dependency-version: 4.1.11
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-09-08 21:32:12 +00:00
dependabot[bot]
f1b54b877b chore(deps-dev): Bump browserslist from 4.28.1 to 4.28.8 in /frontend
Bumps [browserslist](https://github.com/browserslist/browserslist) from 4.28.1 to 4.28.8.
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.28.1...4.28.8)

---
updated-dependencies:
- dependency-name: browserslist
  dependency-version: 4.28.8
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-09-01 22:18:03 +00:00
Georges-Antoine Assi
08901ca3a9 cleanup: reuse, simplify and trim the physical-games feature
Backend:

- Drop the post-scan re-assert of is_physical/upc/fs_path in
  create_physical_rom; scan_rom already forwards them in rom_attrs. The test
  fake was written to drop those fields to exercise the dead path, so it now
  matches the real scan_rom contract.
- Extract build_hashless_fs_rom() and use it from both the physical endpoint
  and the scan socket, which built the same FSRom literal by hand.
- Return added_rom instead of re-fetching it; add_rom is already decorated
  with @with_details, so get_rom repeated the whole eager-load fan-out.
- Pair invalidate_filter_values_cache() with refresh_affected_smart_collections(),
  as every other rom-mutating endpoint does.
- Reword the 409 detail: build_physical_fs_name uniquifies the name, so an
  IntegrityError can only mean a concurrent add.
- upc_handler: inline the single-use base_url and hoist the minimum title
  length to a module constant.

Frontend:

- Load BarcodeScannerDialog lazily. GlobalDialogs is mounted on every page, so
  the static import chain put ZXing (~438 KB) in the eager layout chunk. The
  scanner's watcher now runs immediate/post so it still starts when mounted
  behind a v-if.
- Guard the scanner against a teardown that races the decodeFromConstraints
  await; closing during the permission prompt left the camera on and the
  decode loop running.
- Render the UPC scan trigger through RTextField's append-inner adornment
  instead of a hand-built flex row.
- Type the createPhysicalRom payload with the generated PhysicalRomCreateForm
  and drop the metadataSources argument, which had no caller.
- Declare @zxing/library directly; it was imported but resolved transitively.
- Drop two write-only refs, scope the reader local to startCamera, and trim
  comments that restate the code.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-25 20:47:56 -04:00
Georges-Antoine Assi
69938b1cee add support for physical (DB only) games 2026-08-25 20:19:05 -04:00
Georges-Antoine Assi
b037276bfc Add Playwright e2e cover for permission gating
The #3954 fix is about what a read-only user can SEE, which the Vitest
specs can't reach: visibility depends on grants the backend resolves and
`useCan` projects. These drive a real instance instead.

  frontend/e2e/rom-actions.spec.ts        ⋯ menu items + divider collapse
  frontend/e2e/profile-role.spec.ts       no self-editable role control
  frontend/e2e/game-media-files.spec.ts   Media/Files upload + delete

Every spec asserts both sides -- absent for `e2e_viewer`, present for
`e2e_admin` -- so it can't pass against a page that failed to render, and
notices a fix that over-hides. Verified by reverting the fix: 8 of 15 fail,
and the 6 admin-side guards stay green.

`backend/tools/seed_e2e_users.py` seeds the two fixture users idempotently.
Specs live in e2e/ so Vitest's src/** and test/** globs skip them, and
tsconfig now covers them so they're typechecked.

Not wired into CI: that needs a backend, a database and a library fixture
in the runner.
2026-07-26 09:07:14 -04:00
zurdi
23b0217329 refactor(frontend): drive CSS targets from a shared .browserslistrc
Replace the hardcoded `build.cssTarget` version list with a single source
of truth. The browser baseline (Tailwind v4's floor) now lives in
`.browserslistrc` as `>=` floors, and vite.config derives the esbuild-style
`cssTarget` Lightning CSS needs from it. Version data comes from
caniuse-lite instead of being pinned in the build config, and any other
tool reads the same file.

No behavior change: the derived targets resolve to the same set, so the
production build still emits both `-webkit-backdrop-filter` and the
standard property for every glass surface.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 22:57:09 +00:00
Georges-Antoine Assi
1eb4d1c8ed test(v2): add axe accessibility gate + keyboard nav tests to Storybook
Wire axe-core into the vitest Storybook runner so every v2 lib story is
scanned for accessibility violations, gated per story by the
@storybook/addon-a11y `a11y.test` parameter (error / todo / off) with a
global default of "error".

Fix the unlabeled-control violations this surfaces (icon-only buttons,
decorative images) and mark the remaining component-level gaps as `todo`
so CI stays green while the backlog stays visible. Add keyboard-operability
play() tests to RSwitch, RTabNav, and RRating.

Refs #1848

Generated-By: PostHog Code
Task-Id: b44aba2c-90c9-407d-8c80-5bbe77ecd6c1
2026-07-05 22:10:52 -04:00
Claude
23dbffd17a fix(deps): bump dependencies to patch reported vulnerabilities
Address vulnerabilities flagged by the security scanner:

Backend (pyproject.toml / uv.lock):
- cryptography 46.0.5 -> 49.0.0 (CVE-2026-39892, memory buffer)
- mako 1.3.10 -> 1.3.12 (CVE-2026-41205/44307, path traversal)
- gunicorn 23.0.0 -> 26.0.0 (HTTP request smuggling hardening)
- yarl 1.20.1 -> 1.24.2 (SSRF via host parsing)

Frontend (package.json / package-lock.json):
- axios ^1.16.0 -> ^1.18.1 (sensitive data exposure)
- form-data pinned to ^4.0.6 via override (CVE-2026-12143, CRLF injection)

starlette is already on 1.0.1, which is the patched release for the
BadHost advisory (CVE-2026-48710), so no change is needed there.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01W5nnYmsCNdUjNpuwRxqUiR
2026-06-24 17:45:22 +00:00
Georges-Antoine Assi
a3176494c9 Patcher backend refinements, dep cleanup, regenerated types
- Move default_category_for_non_nested validator onto RomFileSchema so
  top-level files default to category "game" (the v2 patcher's base-file
  filter relies on this).
- Use Annotated Body() in the patch endpoint; check patcher output via
  anyio async Path.
- Drop the now-unused client-side rom-patcher and vite-plugin-static-copy
  (patching is server-side); simplify the Storybook plugin filter.
- Regenerate frontend OpenAPI types.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-23 09:17:52 -04:00
Georges-Antoine Assi
52163633e5 Merge branch 'master' into claude/server-side-rom-patching-EaQck 2026-06-23 07:01:07 -04:00
zurdi
85952d850f chore: remove unused lint scripts from package.json and update bcrypt dependency in pyproject.toml 2026-06-17 09:59:32 +02:00
zurdi
0780c3820b chore: update package dependencies and configurations
- Added "esbuild" version "^0.28.1" to frontend package overrides.
- Updated "exclude-newer-package" in pyproject.toml to include "vcrpy" with a date of "2026-06-17".
- Modified uv.lock to reflect the new "vcrpy" version "8.2.1" and removed platform-specific markers for dependencies.
2026-06-17 01:27:08 +02:00
zurdi
f01eda9227 Merge remote-tracking branch 'origin/master' into chore/frontend-v2 2026-06-16 18:21:14 +02:00
zurdi
9f6138d010 Merge branch 'master' into chore/frontend-v2
Adopt master's ROM schema design (sibling_roms + files, batched
get_files_for_roms / get_siblings_for_roms) while preserving the v2-branch
features master lacks: per-user is_main_sibling on siblings and audio_meta
on rom files.

Conflict resolution:
- responses/rom.py: keep master's sibling_roms/files fields; re-graft
  is_main_sibling via SiblingRomSchema.from_rom(rom, is_main_sibling=...);
  restore the eager-relationship fallback in
  SimpleRomSchema.from_orm_with_request (None sentinel) so the v2
  /{id}/simple endpoint still returns siblings/files.
- roms_handler.py: get_siblings_for_roms now left-joins RomUser and returns
  (Rom, is_main_sibling) tuples; keep both branch and master file helpers.
- drop the redundant branch-only sibling_ids field and
  get_sibling_data_for_roms.
- generated types resolved to match (sibling_roms + files; RomFileSchema
  keeps audio_meta and gains archive_members).
- update v2 components and the RelatedGameCard mock to read sibling_roms.
- fix stale exclude={"siblings"} -> "sibling_roms" in scan emit payloads.
- re-chain the audio_meta migration as 0083 (after master's 0082) to keep a
  single Alembic head.
- package.json: union of branch tooling + master dependency bumps; lock
  regenerated.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-16 01:19:55 +02:00
Georges-Antoine Assi
2cb60a67eb override rolldown 2026-06-15 13:26:49 -04:00
dependabot[bot]
12f1619e04 build(deps): bump esbuild, vite, @tailwindcss/vite, @vitejs/plugin-vue, vite-plugin-pwa and vite-plugin-static-copy
Removes [esbuild](https://github.com/evanw/esbuild). It's no longer used after updating ancestor dependencies [esbuild](https://github.com/evanw/esbuild), [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite), [@tailwindcss/vite](https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/@tailwindcss-vite), [@vitejs/plugin-vue](https://github.com/vitejs/vite-plugin-vue/tree/HEAD/packages/plugin-vue), [vite-plugin-pwa](https://github.com/vite-pwa/vite-plugin-pwa) and [vite-plugin-static-copy](https://github.com/sapphi-red/vite-plugin-static-copy). These dependencies need to be updated together.


Removes `esbuild`

Updates `vite` from 6.4.2 to 8.0.16
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v8.0.16/packages/vite)

Updates `@tailwindcss/vite` from 4.2.1 to 4.3.1
- [Release notes](https://github.com/tailwindlabs/tailwindcss/releases)
- [Changelog](https://github.com/tailwindlabs/tailwindcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/tailwindlabs/tailwindcss/commits/v4.3.1/packages/@tailwindcss-vite)

Updates `@vitejs/plugin-vue` from 5.2.4 to 6.0.7
- [Release notes](https://github.com/vitejs/vite-plugin-vue/releases)
- [Changelog](https://github.com/vitejs/vite-plugin-vue/blob/main/packages/plugin-vue/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite-plugin-vue/commits/plugin-vue@6.0.7/packages/plugin-vue)

Updates `vite-plugin-pwa` from 0.21.2 to 1.3.0
- [Release notes](https://github.com/vite-pwa/vite-plugin-pwa/releases)
- [Commits](https://github.com/vite-pwa/vite-plugin-pwa/compare/v0.21.2...v1.3.0)

Updates `vite-plugin-static-copy` from 3.2.0 to 3.4.0
- [Release notes](https://github.com/sapphi-red/vite-plugin-static-copy/releases)
- [Changelog](https://github.com/sapphi-red/vite-plugin-static-copy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sapphi-red/vite-plugin-static-copy/compare/vite-plugin-static-copy@3.2.0...vite-plugin-static-copy@3.4.0)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-version:
  dependency-type: indirect
- dependency-name: vite
  dependency-version: 8.0.16
  dependency-type: direct:development
- dependency-name: "@tailwindcss/vite"
  dependency-version: 4.3.1
  dependency-type: direct:development
- dependency-name: "@vitejs/plugin-vue"
  dependency-version: 6.0.7
  dependency-type: direct:development
- dependency-name: vite-plugin-pwa
  dependency-version: 1.3.0
  dependency-type: direct:development
- dependency-name: vite-plugin-static-copy
  dependency-version: 3.4.0
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-06-12 22:36:20 +00:00
zurdi
8f879d0b59 chore: update Node.js version to 24.16 across workflows and Dockerfile, and enhance package.json with npm version specification 2026-05-26 09:23:47 +00:00
zurdi
17ea8da23d Merge remote-tracking branch 'origin/master' into chore/frontend-v2 2026-05-25 07:56:38 +00:00
dependabot[bot]
83fb6193e3 chore(deps): bump js-cookie from 3.0.5 to 3.0.7 in /frontend
Bumps [js-cookie](https://github.com/js-cookie/js-cookie) from 3.0.5 to 3.0.7.
- [Release notes](https://github.com/js-cookie/js-cookie/releases)
- [Commits](https://github.com/js-cookie/js-cookie/compare/v3.0.5...v3.0.7)

---
updated-dependencies:
- dependency-name: js-cookie
  dependency-version: 3.0.7
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-05-21 21:35:37 +00:00
Georges-Antoine Assi
d72e645049 use bowser 2026-05-16 19:17:38 -04:00
zurdi
a361299b20 feat: add @floating-ui/vue for tooltip positioning and enhance RTooltip component with new features 2026-05-13 23:40:44 +00:00
dependabot[bot]
d0b2c89e60 chore(deps): bump axios from 1.15.0 to 1.16.0 in /frontend
Bumps [axios](https://github.com/axios/axios) from 1.15.0 to 1.16.0.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.15.0...v1.16.0)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.16.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-05-08 09:10:01 +00:00
zurdi
b3180a5aca feat(frontend-v2): generate tokens.css from index.ts as single source
scripts/build-tokens.ts emits src/v2/styles/tokens.css with explicit
naming overrides for the special cases (--r-row-pad, --r-elev-*,
--r-nav-h, abbreviated layout vars). tsx wired into devDeps;
build:tokens script + predev/prebuild hooks keep the CSS in sync.

Backfill missing tokens that lived only in CSS: --r-color-fav
joins colorBrand, and the focus colors in colorDark / colorLight
match the translucent values components actually consume (not the
unused #ffffff / #111117 they used to declare). Drop the orphan
--r-focus-ring-color (zero references in the codebase).

Adopt --r-radius-card (14px) for RMenuPanel and RDialog instead of
hard-coded 14px; switch a NotesTab badge from 10px to --r-radius-lg.
Closes the "panels use 14px not --r-radius-lg" pitfall — the
constitution no longer needs that footnote.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-28 13:09:50 +00:00
zurdi
df8f6178ef chore(frontend): set up vitest + storybook play() tests and align CI
Add Vitest 4 with happy-dom, @vue/test-utils, and a single
test/storybook.test.ts that auto-discovers every story under
src/v2/lib and runs its play() via composeStories — no Playwright,
just composition-based interaction tests. 89 stories now smoke-pass
in CI.

Scripts: lint:fix (auto-fix), lint (now scoped to ./src/v2; v1 is
frozen), lint:all (legacy sweep), test, test:watch, test:ui,
storybook:test.

eslint.config.js gets argsIgnorePattern: "^_" so unused-by-design
parameters can use the underscore convention.

CI: new frontend.yml runs lint, test, build in parallel on
frontend/** changes; typecheck.yml bumped to Node 22 with cached
npm ci. Existing typecheck job preserved for branch protection.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-28 11:52:44 +00:00
zurdi
cc2556da7b Refactor code structure for improved readability and maintainability 2026-04-22 09:57:42 +00:00
Georges-Antoine Assi
1ee4682845 feat: drive frontend patcher via server-side endpoint, isolate Node deps
- Rewrite frontend/src/views/Patcher.vue around library ROM/patch pickers
  (v-autocomplete with debounced search) and call POST /api/roms/{id}/patch
  with responseType: blob; download and/or re-upload the patched output.
- Drop the rom-patcher npm dep and vite-plugin-static-copy from the frontend;
  remove the now-unused web worker, type decls, and viteStaticCopy plugin.
- Move the Node patcher into a self-contained npm project at
  backend/utils/rom_patcher/ (dir uses underscore so it's a valid Python
  package). Patcher.js loads RomPatcher.js from its sibling node_modules.
- Extract the heavy subprocess logic into backend/utils/rom_patcher/patcher.py
  (apply_patch, PatcherError, SUPPORTED_PATCH_EXTENSIONS); slim patch.py to
  HTTP/DB plumbing and fix a stale .parent.parent path.
- Wire up Docker: dev Dockerfile installs the new npm project; prod
  Dockerfile adds a backend-node-build stage and copies rom-patcher-js into
  the production image; install nodejs at runtime.
- Add new patcher i18n keys to en_US (other locales fall back).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-13 07:39:31 -04:00
dependabot[bot]
77c7110fca chore(deps): bump axios from 1.13.6 to 1.15.0 in /frontend
Bumps [axios](https://github.com/axios/axios) from 1.13.6 to 1.15.0.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.13.6...v1.15.0)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.15.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-04-10 05:57:18 +00:00
dependabot[bot]
dfcd4126f7 chore(deps-dev): bump vite from 6.4.1 to 6.4.2 in /frontend
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 6.4.1 to 6.4.2.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.4.2/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.4.2/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 6.4.2
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-04-07 04:31:41 +00:00
dependabot[bot]
648954d15a chore(deps): bump lodash from 4.17.23 to 4.18.1 in /frontend
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.23 to 4.18.1.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.23...4.18.1)

---
updated-dependencies:
- dependency-name: lodash
  dependency-version: 4.18.1
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-04-03 13:48:06 +00:00
Georges-Antoine Assi
883824a5d6 update eslint to v10 2026-03-08 10:41:46 -04:00
Georges-Antoine Assi
06d07e5477 corerct set to v24 2026-02-16 22:15:22 -05:00