studio: show the EU strings the page already defines (STUDIO-EU-STRINGS) #2339
No reviewers
No assignees
Labels
No labels
bug
dependencies
documentation
enhancement
missing claim
needs rebase
needs-triage
question
ready-for-agent
submodules
No project
No milestone
Dependencies
No dependencies set
Notifications
1 participant
Due date
No due date set.
Reference
leonida/mandy!2339
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/studio-stats-labels-i18n"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Pull request successfully merged and closed
Claimed in the coordination issue as: STUDIO-EU-STRINGS (https://github.com/ubiquitarianism/leonida/issues/1608#issuecomment-7194265327)
What and why
viewer/studio.html(served bytools/gallery.py) has an RU/EU switch and anI18Ntable with both languages, but several entries were never applied, so after choosing EU the page kept Russian text:mainstatModel,statCategory,statTriangles,statVertices,statSizeresetCameratexHeadingallCategoriestexCountSuffixtexNotFound/modelsNotFoundshowAllTexturesandtexLoadErrorapplyTranslationsnow sets the stats labels, the button, the heading, the chip and the texture count; the model and texture lists, which already re-render on a switch, read their messages fromI18N. The markup is unchanged apart from two ids (btn-reset-camera,tex-heading): each stats label is the text node in front of its value (<div>Модель: <b id="stat-name">), set the way the tab buttons' labels already are. Russian stays the default and reads exactly as before.Left out on purpose: the category names (
catNamesexists, but the chips are built once per load and the names already carry English in brackets) and the model download alert (it sits in the lines #2100 changes).Merges cleanly with the open studio PRs #1138, #1490, #2100, #2136, #2250 and with #2335 (STUDIO-MODEL-DETAILS, which adds translated rows to the same panel); with #2335 merged in, the studio tests pass 16/16.
Tested
Windows 11, Node 26.12.1, no game files:
node --test tests/test_viewer_studio.cjs: 13 pass. The new test loads an empty texture list and an empty model list in RU, switches to EU and checks all of the strings above, then the "show all" button with 81 textures and the load-error text. It fails onmain(the labels stay Russian); the 12 existing tests pass.scripts/check_no_game_data.pyon both files.GPUs tested: n/a (no GPU code)
AI-assisted: yes (Claude Code, Claude Opus 5.5)
Checklist
mainand merges cleanly (a conflicting pull request is labeledneeds rebase).docs/design.md, with how it was confirmed. (n/a: no translator change)🤖 Generated with Claude Code
Marking Ready for Review since no WIP/blocker reason for draft status is specified on this PR, so it can enter normal CI and review.
(AI-assisted triage.)
Now ready for review and
MERGEABLE. Clean-room verified: wiring the existing EU locale strings inviewer/studio.htmlwith tests intests/test_viewer_studio.cjsis clean and verified (@lixonik; also unblocks stacked Draft#2377once merged).Approving — ready to merge once CI runs green on current
main.(AI-assisted review.)
Found a stale texture-error label after changing the language at
3c9a09f12+9f27ba2e1. In the existing Node Studio harness I made the first texture request fail in Russian, then switched to EU. The rest of the UI changed language and the Russian error remained. A second scenario succeeds once, then fails, then switches back to Russian. The failure should remain visible in the selected language. A local change that tracks the load result and refreshes the count/error label in one place makes both sequences pass alongside the original locale test. All requests in this test are synthetic.AI-assisted with OpenAI Codex (GPT-6).