Skip to content

Commit 75be94b

Browse files
committed
Rebuild Localization from toolbox template with legacy copy preserved - PR_26154_024-localization-template-rebuild
1 parent 2e125ca commit 75be94b

7 files changed

Lines changed: 263 additions & 113 deletions

File tree

docs_build/dev/codex_commands.md

Lines changed: 27 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -2,45 +2,46 @@
22

33
Task:
44

5-
- `PR_26154_023-template-consistency-safe-css-audit`
5+
- `PR_26154_024-localization-template-rebuild`
66

77
Commands run:
88

9+
- `Get-Content .codex/skills/repo-build/SKILL.md`
910
- `Get-Content docs_build/dev/PROJECT_INSTRUCTIONS.md`
10-
- `Get-Content docs_build/dev/reports/template_consistency_audit_report.md`
11+
- `git status --short`
1112
- Inspected:
12-
- `assets/theme/v2/css/styles.css`
13-
- `assets/theme/v2/css/theme.css`
14-
- `_page_template_v2.html`
13+
- `toolbox/localization/index.html`
14+
- `toolbox/localization/css/localization-studio.css`
15+
- `toolbox/localization/js/localization-studio.js`
1516
- `toolbox/_tool_template-v2/index.html`
16-
- active public/root pages from the PR_26154_022 audit
17-
- active toolbox pages from the PR_26154_022 audit
18-
- Ran targeted stylesheet coverage checks for public/root pages using `styles.css`.
19-
- Replaced `styles.css` with `theme.css` for safe public/root pages only.
20-
- Added `theme.css` wiring to PR022-listed active toolbox pages where the tool template clearly expects it.
21-
- Added missing ToolDisplayMode host markers to `toolbox/builder/index.html` and `toolbox/creator/index.html`.
22-
- Left aggregate-only CSS cases documented for later approved Theme V2 extraction.
23-
- Left `toolbox/cloud/index.html` documented as an ambiguous display-only page.
24-
- Reran the template consistency audit and recorded before/after mismatch counts.
17+
- `toolbox/tools-page-accordions.js`
18+
- direct Localization launch expectation in `tests/playwright/tools/RootToolsFutureState.spec.mjs`
19+
- Copied current `toolbox/localization/` to `old-tools/localization_pre_template_rebuild/`.
20+
- Deleted active `toolbox/localization/`.
21+
- Rebuilt active `toolbox/localization/` by copying `toolbox/_tool_template-v2/`.
22+
- Updated only the rebuilt `toolbox/localization/index.html` Localization identity values.
2523
- Ran targeted reference checks for:
26-
- `assets/theme/v2/css/styles.css`
27-
- `assets/theme/v2/css/theme.css`
28-
- `_page_template_v2.html`
29-
- `toolbox/_tool_template-v2`
30-
- Ran static path validation for changed active HTML and CSS references.
31-
- Ran targeted static syntax validation for changed file types.
24+
- `toolbox/localization/`
25+
- `old-tools/localization_pre_template_rebuild/`
26+
- `toolbox/_tool_template-v2/`
27+
- active local `css/` and `js/` folders
28+
- Localization links
29+
- Ran static path and encoding validation for the rebuilt active HTML.
30+
- Ran static path and encoding validation for the preserved old-tools backup HTML/CSS.
31+
- Ran `node --check old-tools/localization_pre_template_rebuild/js/localization-studio.js`.
3232
- Ran `git diff --check`.
3333
- Ran `npm run codex:review-artifacts`.
3434
- Packaged repo-structured ZIP:
35-
- `tmp/PR_26154_023-template-consistency-safe-css-audit_delta.zip`
35+
- `tmp/PR_26154_024-localization-template-rebuild_delta.zip`
3636

3737
Validation summary:
3838

39-
- PASS targeted PR023 reference checks: 14 safe public/root pages no longer reference `styles.css`, expected aggregate-only public/root references remain documented, and template source paths exist.
40-
- PASS template consistency audit rerun: public/root pages improved from 15/43 matching to 28/43 matching; active toolbox pages improved from 11/20 matching to 19/20 matching.
41-
- PASS static path validation for changed active HTML/CSS references.
42-
- PASS targeted static syntax validation for changed file types.
39+
- PASS targeted Localization rebuild reference checks.
40+
- PASS active `toolbox/localization/` contains only `index.html`.
41+
- PASS old implementation preserved under `old-tools/localization_pre_template_rebuild/`.
42+
- PASS no active local Localization CSS or JS folders remain.
43+
- PASS static validation for changed HTML/CSS/JS surfaces in scope.
4344
- PASS `git diff --check`.
44-
- SKIPPED `npm run test:workspace-v2` because this PR did not change active toolbox launch or navigation behavior.
45+
- SKIPPED `npm run test:workspace-v2` because active toolbox registration and launch behavior were not changed.
4546
- SKIPPED tests against `old-tools/`, `old_games/`, and `old_samples` per request.
4647
- SKIPPED full samples smoke test per request.

docs_build/dev/commit_comment.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
Safe Theme V2 CSS/template consistency cleanup - PR_26154_023-template-consistency-safe-css-audit
1+
Rebuild Localization from tool template - PR_26154_024-localization-template-rebuild
22

3-
- Replace `styles.css` with `theme.css` only for public/root pages classified as safe-replace.
4-
- Document aggregate-only `styles.css` cases that need approved Theme V2 extraction before migration.
5-
- Add missing `theme.css` wiring to PR022-listed active toolbox pages and add ToolDisplayMode hosts to builder and creator.
6-
- Leave display-only or ambiguous pages unchanged and report remaining template mismatches.
7-
- Produce before/after template consistency counts and required Codex review artifacts.
3+
- Preserve the previous Localization implementation under `old-tools/localization_pre_template_rebuild/`.
4+
- Replace active `toolbox/localization/` with a fresh copy of `toolbox/_tool_template-v2/`.
5+
- Adapt only Localization identity text and ToolDisplayMode metadata in the rebuilt template.
6+
- Remove active local Localization CSS/JS folders by not copying old implementation code back into the active tool.
7+
- Validate active folder shape, preserved backup, Localization links, static paths, and diff hygiene.
Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
# PR_26154_024 Localization Template Rebuild Report
2+
3+
## Scope
4+
5+
Rebuilt only `toolbox/localization/` from the first-class tool template source at `toolbox/_tool_template-v2/`.
6+
7+
No other active toolbox page was modified.
8+
9+
## Backup
10+
11+
Before deleting the active Localization folder, the current implementation was copied to:
12+
13+
- `old-tools/localization_pre_template_rebuild/`
14+
15+
The preserved backup contains:
16+
17+
- `old-tools/localization_pre_template_rebuild/index.html`
18+
- `old-tools/localization_pre_template_rebuild/css/localization-studio.css`
19+
- `old-tools/localization_pre_template_rebuild/js/localization-studio.js`
20+
21+
## Active Rebuild
22+
23+
Deleted the prior active folder:
24+
25+
- `toolbox/localization/`
26+
27+
Rebuilt it by copying:
28+
29+
- from `toolbox/_tool_template-v2/`
30+
- to `toolbox/localization/`
31+
32+
The rebuilt active folder contains only:
33+
34+
- `toolbox/localization/index.html`
35+
36+
No active `toolbox/localization/css/` or `toolbox/localization/js/` folder remains.
37+
38+
## Template Adaptations
39+
40+
Only minimal Localization identity values were changed in the copied template:
41+
42+
- Page `<title>` changed to `Localization - Game Foundry Studio`.
43+
- Meta description changed to Localization planning/template copy.
44+
- Template kicker changed to `Toolbox / Localization`.
45+
- Main heading changed to `Localization`.
46+
- Lede changed to describe translation, language coverage, contributor review, and future localization workflows.
47+
- Left panel heading changed to `Localization`.
48+
- Template setup/output body labels changed from generic tool copy to Localization copy.
49+
- ToolDisplayMode host slug and shared badge/character metadata changed to `localization-studio` so the shared display-mode script does not resolve the page as `index`.
50+
51+
## What Was Not Reintroduced
52+
53+
- No old Localization implementation JavaScript was copied back into active `toolbox/localization/`.
54+
- No old Localization implementation CSS was copied back into active `toolbox/localization/`.
55+
- No active local `css/` folder was created.
56+
- No active local `js/` folder was created.
57+
- No tool-specific CSS was added.
58+
- No tool-specific JavaScript was added.
59+
60+
## Link And Registration Check
61+
62+
Existing active toolbox link remains valid:
63+
64+
- `toolbox/tools-page-accordions.js` links to `../toolbox/localization/index.html`.
65+
66+
Existing Playwright launch expectation remains aligned:
67+
68+
- `tests/playwright/tools/RootToolsFutureState.spec.mjs` expects `../toolbox/localization/index.html`.
69+
70+
No active toolbox registration or launch path was changed.
71+
72+
## Validation
73+
74+
- PASS: required files exist under `toolbox/localization/`, `old-tools/localization_pre_template_rebuild/`, and `toolbox/_tool_template-v2/`.
75+
- PASS: active `toolbox/localization/` has no local `css/` or `js/` folders.
76+
- PASS: active Localization page contains the expected template wiring, shared CSS, shared partial loader, ToolDisplayMode script, and `localization-studio` display-mode slug.
77+
- PASS: active Localization page has no references to `css/localization-studio.css`, `js/localization-studio.js`, `localization-workspace`, or `localization-status-grid`.
78+
- PASS: active Localization link remains present in `toolbox/tools-page-accordions.js`.
79+
- PASS: static path and encoding validation for the rebuilt active HTML.
80+
- PASS: static path and encoding validation for the preserved old-tools backup HTML/CSS.
81+
- PASS: `node --check old-tools/localization_pre_template_rebuild/js/localization-studio.js`.
82+
- PASS: `git diff --check`.
83+
- SKIPPED: `npm run test:workspace-v2` because active toolbox registration and launch behavior were not changed.
84+
- SKIPPED: tests against `old-tools/`, `old_games/`, and `old_samples` per request.
85+
- SKIPPED: full samples smoke test per request.

toolbox/localization/css/localization-studio.css renamed to old-tools/localization_pre_template_rebuild/css/localization-studio.css

File renamed without changes.
Lines changed: 122 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,122 @@
1+
<!doctype html>
2+
<html lang="en">
3+
4+
<head>
5+
<meta charset="utf-8">
6+
<meta name="viewport" content="width=device-width, initial-scale=1">
7+
<title>Localization - Game Foundry Studio</title>
8+
<meta name="description" content="Localization planning placeholder for Game Foundry Studio translation workflows.">
9+
<link rel="icon" href="/favicon.svg">
10+
<link rel="stylesheet" href="../../assets/theme/v2/css/styles.css">
11+
<link rel="stylesheet" href="../../assets/theme/v2/css/theme.css">
12+
<link rel="stylesheet" href="css/localization-studio.css">
13+
</head>
14+
15+
<body>
16+
<div data-partial="header-nav"></div>
17+
<main>
18+
<section class="page-title">
19+
<div class="container">
20+
<div class="kicker">Community / Media</div>
21+
<h1>Localization</h1>
22+
<p class="lede">Plan game translation, language coverage, contributor review and localization readiness. Status = Planning.</p>
23+
</div>
24+
</section>
25+
<section class="section">
26+
<div class="container">
27+
<div class="tool-workspace localization-workspace" data-localization-placeholder>
28+
<aside class="tool-column tool-group-community-marketplace">
29+
<div class="tool-column-header forge-gold">
30+
<h2>Translation Plan</h2>
31+
</div>
32+
<div class="accordion-stack">
33+
<details class="vertical-accordion" open>
34+
<summary>Purpose</summary>
35+
<div class="accordion-body">
36+
<p>Localization is a placeholder for planning how games, templates, tutorials and marketplace assets can be translated for more players.</p>
37+
</div>
38+
</details>
39+
<details class="vertical-accordion">
40+
<summary>Why Localization Matters</summary>
41+
<div class="accordion-body">
42+
<p>Clear language support helps creators reach more communities and lets players understand controls, goals, ratings and tutorials without guessing.</p>
43+
</div>
44+
</details>
45+
<details class="vertical-accordion">
46+
<summary>Supported Languages</summary>
47+
<div class="accordion-body">
48+
<ul>
49+
<li>English source content</li>
50+
<li>Spanish planning track</li>
51+
<li>French planning track</li>
52+
<li>Japanese planning track</li>
53+
<li>Community-requested languages</li>
54+
</ul>
55+
</div>
56+
</details>
57+
<details class="vertical-accordion">
58+
<summary>Contributor Workflow</summary>
59+
<div class="accordion-body">
60+
<p>Future contributors will be able to suggest translated strings, add context notes and flag copy that needs creator review.</p>
61+
</div>
62+
</details>
63+
</div>
64+
</aside>
65+
<div data-tool-display-mode data-asset-root="../../assets/theme/v2/images" data-tool-slug="localization-studio" data-tool-icon-src="../../assets/theme/v2/images/icons/localization-studio.png"></div>
66+
<section class="tool-center-panel">
67+
<img class="localization-hero-image" src="../../assets/theme/v2/images/characters/localization-studio.png" alt="Localization mascot">
68+
<h2>Localization Placeholder</h2>
69+
<p>Status = Planning. No translation functionality is implemented yet.</p>
70+
<div class="localization-status-grid" aria-label="Localization placeholder status">
71+
<div class="mini-stat"><strong>Planning</strong>Status</div>
72+
<div class="mini-stat"><strong>Placeholder</strong>Implementation</div>
73+
<div class="mini-stat"><strong>Community</strong>Theme</div>
74+
</div>
75+
</section>
76+
<aside class="tool-column tool-group-community-marketplace">
77+
<div class="tool-column-header forge-gold">
78+
<h2>Review Track</h2>
79+
</div>
80+
<div class="accordion-stack">
81+
<details class="vertical-accordion" open>
82+
<summary>Translation Workflow</summary>
83+
<div class="accordion-body">
84+
<p>Future translation workflows will organize source strings, language targets, context notes and contributor submissions.</p>
85+
</div>
86+
</details>
87+
<details class="vertical-accordion">
88+
<summary>Review &amp; Approval</summary>
89+
<div class="accordion-body">
90+
<p>Future review surfaces will help creators approve translations, reject mismatches and preserve tone across game content.</p>
91+
</div>
92+
</details>
93+
<details class="vertical-accordion">
94+
<summary>Future Scope</summary>
95+
<div class="accordion-body">
96+
<ul>
97+
<li>Language packs for games and tutorials</li>
98+
<li>Contributor suggestions and review queues</li>
99+
<li>Marketplace localization notes</li>
100+
<li>Rating and community copy translation</li>
101+
</ul>
102+
</div>
103+
</details>
104+
<details class="vertical-accordion">
105+
<summary>Status = Planning</summary>
106+
<div class="accordion-body">
107+
<p>This page is informational only. Localization editing, export, import and approval actions are intentionally not available yet.</p>
108+
</div>
109+
</details>
110+
</div>
111+
</aside>
112+
</div>
113+
</div>
114+
</section>
115+
</main>
116+
<div data-partial="footer"></div>
117+
<script src="../../assets/theme/v2/js/gamefoundry-partials.js" defer></script>
118+
<script src="../../assets/theme/v2/js/tool-display-mode.js" defer></script>
119+
<script src="js/localization-studio.js" defer></script>
120+
</body>
121+
122+
</html>

toolbox/localization/js/localization-studio.js renamed to old-tools/localization_pre_template_rebuild/js/localization-studio.js

File renamed without changes.

0 commit comments

Comments
 (0)