A `[` needs no closing bracket, so on notes carrying unclosed ones the
skip-the-existing-link alternative scanned to the end of the text for
each of them: quadratic, and measurably so, 2s over 100KB of them and
33s over 400KB. Capping the label and the target, far above the longest
link the notes actually carry (134 characters), holds it to a line's
worth of work per bracket: 42ms and 159ms for the same two, and the
same output on every published release.
Raised by @gantoine in review of #4705.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016bZ7R3xC73MZu1vTNuatPK
Trim the usePlayFocus module comment to two lines and type the useGamepad
test fixture fully instead of casting through unknown.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Annotate the new filter_values endpoint tests and their helper, and build
the galleryRoms null-coercion test's platform with a typed factory
instead of casting a bare literal.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The ROM list and /roms/filters responses already validate every
filter_values key as a list, so the API never sends nulls. Make that
contract explicit: the handler now returns RomFiltersDict directly
(moved to handler/database/rom_filters.py to avoid an import cycle),
which drops the mypy typeddict-item ignores in the endpoints. Endpoint
tests pin that every key is present and a list, including for a ROM
with no metadata and with with_filter_values=false.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Drop the one-line listOrEmpty wrapper and the setter test the
galleryRoms test already covers.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Addresses Greptile's review of #4705.
The rewrite matched a reference anywhere but right after a link's
bracket, so one written inside code was turned into markdown the preview
then printed verbatim, and one inside a longer link label nested a link
in a link. Code spans, fenced blocks and whole existing links are now
matched first and handed back untouched. A trailing query no longer
splits a reference either: `?` joins the guard that already kept
`/files` and `#issuecomment-1` whole.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016bZ7R3xC73MZu1vTNuatPK
Make the null filter_value tests fail without the guards they cover,
and drop the FilterDrawer fallback the store setters make unreachable.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
GitHub's generated release notes credit each change with the pull
request's full URL, which the changelog dialog printed in full: every
entry wrapped onto a second line of `https://github.com/...`.
Bare pull request and issue URLs are now rewritten the way GitHub
renders them, `#4252` here and `owner/name#12` for another repository,
before the notes reach the markdown preview. A URL that is already a
link, and a deeper page of one (`/files`, `#issuecomment-1`), are left
as they are.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016bZ7R3xC73MZu1vTNuatPK
v2's UA-drawn chrome currently follows Vuetify's runtime theme, which injects
`:root { color-scheme: dark }` while a dark theme is active and nothing at the
root for light. That holds only because RomM.vue keeps vuetifyTheme.change() in
sync, and v1 plus Vuetify are slated for deletion: once their stylesheet is
gone the root is undeclared again, where Chrome falls back to light chrome and
a dark v2 UI gets light form controls.
Declare the scheme next to each palette so it travels in the same scope class
the v2 tokens already own, rather than depending on a v1 framework's runtime
theme.
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
Addresses Greptile's review: nothing stopped a later NGINX_VERSION pin from
reintroducing the "js vm init njs" notice this PR removes.
njs 0.9.7 dropped the notice, but the njs build is not a function of the nginx
version alone: nginx's apk repo published 1.30.0 against njs 0.9.6 before
rebuilding it against 0.9.7 and 0.9.8, so 1.30.1 is the first release that
never logs it.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
master refreshed the Alpine 3.23 digest and added the python-runtime
stage; this branch moves the same pins to Alpine 3.24 and nginx 1.30.5.
Kept 3.24 and re-resolved every tag to its current manifest-list digest,
so the base images carry the patches master was reaching for.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
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>
A player's setup screen has no spatial navigation for a d-pad to walk, and
useGamepad maps no button to Tab, so the Play CTA is the only way a pad gets
into the view. JsDos and Ruffle never focused it at all, leaving DOS and
Flash games unstartable on a controller; Pico8 and Stream only checked the
modality at mount, so picking up a pad after a mouse click stranded the user
the same way #4397 described.
The behaviour moves into usePlayFocus, which claims the CTA once the screen
is ready, again on a switch to a directional device, and again when a running
game hands the screen back. PlayerShell owns it for the three players it
renders; Stream and EmulatorJS, which lay themselves out, call it directly
and drop their hand-rolled copies.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The stick is translated into synthetic Arrow keydowns, which bubble to
useInputModality and read as a keyboard press. Buttons re-assert the pad
right after dispatching; the stick never did, so a stick-only user settled
in "key" modality and the grid-nav autofocus, which only claims a page for
"pad", never fired. Nothing was focused, so the arrows had nowhere to go.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Moving PlatformTile onto the shared Tile component dropped its `plat-tile`
root class, which is the cell selector PlatformsIndex hands useWrapGridNav.
The selector has matched nothing since, so the platforms grid has had no
arrow or gamepad navigation and its pad autofocus had no cell to land on.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The skeletons were loose markdown, so markdownlint read the `<Feature>`
placeholders as inline HTML and the repeated `## Community news` as duplicate
headings. Fencing both shapes as literal text settles that and marks exactly
what gets copied into Discord.
The section shape now carries the upgrade-warning slot the bullet shape had,
and the notes extraction pulls `[!CAUTION]` alongside `[!WARNING]`.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Codifies the house format of the Discord release announcements from the
last three years: the timely hook, the upgrade warning, two to five
features in prose with the tail as bullets, community news, and the
pointer to the release notes.
The community news is the half of an announcement no diff contains, so
the skill interviews the maintainer for it one step at a time, and
refuses to invent a contributor, an app, a milestone or a handle.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Socket has been scanning this repo's pull requests for supply chain
risk, under their free open source plan, so it belongs in Supported By.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
A release compromised at publish time is usually yanked within days, so
waiting a week before proposing it keeps the window where a malicious
version can land in a PR here closed.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Adds zizmor to Trunk, which audits GitHub Actions workflows, and clears
the 19 findings it reports:
- Every actions/checkout now sets persist-credentials: false, so the
token stops being written into .git/config where any later step (or
an uploaded artifact) could read it.
- Service ports and the release version move from run-block template
expansions into env vars, keeping expansion out of the shell.
- Frontend Checks drops read-all for the contents: read it actually
needs.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Trim the query-only navigation comment to the non-obvious why, and build
the test's route fixtures from `router.resolve` instead of casting bare
literals through `unknown`.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Routes whose title is owned by the view (usePageTitle) carry no
meta.title, so the navigation guard reset document.title to "RomM" on
every navigation, including the query-only ones the v2 game details tabs
and the gallery filter syncs make. The view's watcher never refires there
(its source is unchanged), so the title stayed lost.
Fixes#4646
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
`~= 2.3` allowed any release below 3.0, so a later `uv lock` could pick
2.4 while Trunk stayed on 2.3.0 and quietly reintroduce the skew this
change exists to remove. `~= 2.3.0` holds the same minor line as Trunk.
The resolved version is unchanged at 2.3.1; only the recorded specifier
moves in the lockfile.
The config comment now states what the current value is rather than what
the previous one did.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SPpv6W2ygP9tQ61fTQxdYp