Skip to content

Shaders tab: the Amount slider stays put, and the shader tag follows a change - #325

Merged
elripalda merged 5 commits into
elripalda:mainfrom
Xarishark:feat/shaders-comparison-phrasing-4ec744
Nov 19, 2026
Merged

elripalda merged 5 commits into
elripalda:mainfrom
Xarishark:feat/shaders-comparison-phrasing-4ec744

Conversation

@Xarishark

@Xarishark Xarishark commented Nov 19, 2026 •

Copy link
Copy Markdown
Collaborator

What this changes

Two fixes on a game's Shaders tab.

The Amount slider no longer moves when you pick a shader. Two lines under the picture changed length:

  • the line about the picture got "Drag across the picture to compare." added on the end once a shader was picked;
  • the Amount line said "Pick a shader first." with no shader, then "How strong the CRT shader is." (or another shader's name).

The longer text wrapped onto another line and pushed the slider down by about 20px. Each of those lines now keeps every wording it can show in one spot, with only one visible, so the line is always as tall as its longest wording. The Amount line now says "How strong the shader is." for every shader (that wording was already in every language file); the shader's name is still on the picture and in the list.

The shader tag under the game's name follows a shader change. Picking a shader redraws the game page through refreshGame, which redrew the tabs, the buttons and the page body but not the lines under the name, so the "{name} shader" tag kept showing the old shader until the game was opened again. Those lines are now built by gameTitle, which both the page and refreshGame use, so the other tags there (like "Your copy is set up") stay current the same way.

How you tested it

  • npm test passes (cargo test on Windows: 750 passed, 1 ignored)
  • node --test tests/*.test.cjs passes (371/371, on Bazzite)
  • Tried it in the launcher (npm run dev)

New test: tests/shader-chip.test.cjs picks another shader and checks that the redraw shows its tag under the name. It fails on the old code and passes with the fix.

Not tried in the running launcher. For the slider, I checked the layout on a test page that uses the real app.css and the tab's markup: before the change the slider sat about 20px lower once a shader was picked; after it, it's at the same height either way.

Checklist

  • One change per pull request (both are Shaders tab fixes)
  • No version bump or patch notes (those are done at release time)
  • If it changes what developers can write in recomplauncher.json: the schema and docs are updated too (it doesn't)

The line under the picture gained "Drag across the picture to compare."
and the Amount hint named the shader, so both rewrapped on every pick
and pushed the slider up or down. Each line now holds all its wordings
in one spot with only one visible, and the Amount hint no longer names
the shader.
@Xarishark
Xarishark marked this pull request as ready for review November 19, 2026 16:33
@Xarishark
Xarishark marked this pull request as draft November 19, 2026 17:54
Picking a shader redraws the game page through refreshGame, which
redrew the tabs, the buttons and the page body but never the lines under
the name, so the "{name} shader" tag kept the old shader until the game
was opened again. Those lines are now built by gameTitle, which both the
page and refreshGame use.
@Xarishark Xarishark changed the title The Shaders tab's Amount slider stays put when you pick a shader Shaders tab: the Amount slider stays put, and the shader tag follows a change Nov 19, 2026
@Xarishark
Xarishark marked this pull request as ready for review November 19, 2026 18:06
@Xarishark
Xarishark marked this pull request as draft November 19, 2026 21:48
@Xarishark
Xarishark marked this pull request as ready for review November 19, 2026 22:12
@elripalda
elripalda merged commit df8ce81 into elripalda:main Nov 19, 2026
6 checks passed
Xarishark added a commit to Xarishark/RecompLauncher that referenced this pull request Nov 19, 2026
elripalda#325)

No conflicts. elripalda#325's game title line and elripalda#319's save status line already sit together in main's refreshGame; this branch doesn't change app.js.
@Xarishark
Xarishark deleted the feat/shaders-comparison-phrasing-4ec744 branch November 23, 2026 23:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants