|
1 | 1 | # BUILD_PR_ENGINE_THEME_FINAL_PLATFORM_INTEGRATION |
2 | 2 |
|
3 | 3 | ## Purpose |
4 | | -Finish the active tools platform by making the engine theme the single visual source of truth for the first-class tools surface and by closing the remaining shared-shell integration gaps in one combined build PR. |
| 4 | +Finalize the active tools platform in the fewest possible remaining steps by applying the shared engine theme to all first-class tools and closing the remaining platform-surface integration gaps in one combined build PR. |
5 | 5 |
|
6 | | -## Engine Theme Source Of Truth |
7 | | -- `engine/ui/hubCommon.css` is the existing engine theme source of truth |
8 | | -- no second theme system was introduced |
9 | | -- no additional theme extraction layer was required beyond consuming the existing engine variables from the shared tools shell |
| 6 | +## Scope |
| 7 | +In scope: |
| 8 | +- Make the engine theme the required visual system for all active tools under `tools/` |
| 9 | +- Standardize shared shell/frame/navigation/header/footer behavior across active tools |
| 10 | +- Standardize shared tokens for color, spacing, typography, borders, shadows, focus, buttons, panels, dialogs, tabs, form controls, and status messaging |
| 11 | +- Align tool landing/index surfaces to the same engine-themed platform shell |
| 12 | +- Ensure active tools render consistently while preserving each tool's own workspace behavior |
| 13 | +- Ensure legacy `SpritEditor_old_keep` is excluded from active themed tool navigation unless explicitly opened by direct path |
| 14 | +- Fix pathing/imports/assets required to support the shared engine theme across tools |
| 15 | +- Perform one-pass validation for tool loading, theme application, and broken-reference checks |
10 | 16 |
|
11 | | -## First-Class Active Tools |
| 17 | +Out of scope: |
| 18 | +- New editor features unrelated to shared platform/theme integration |
| 19 | +- Engine runtime feature changes unrelated to theme/surface integration |
| 20 | +- Deleting legacy tools |
| 21 | +- Rewriting tool-specific domain logic unless required for shell/theme adoption |
| 22 | + |
| 23 | +## Required Target State |
| 24 | +Active first-class tools: |
12 | 25 | - `tools/Vector Map Editor/` |
13 | 26 | - `tools/Vector Asset Studio/` |
14 | | -- `tools/Tilemap Studio/` |
15 | | -- `tools/Parallax Scene Studio/` |
16 | | - |
17 | | -## Preserved But Excluded |
18 | | -- `tools/SpriteEditor_old_keep/` remains preserved on disk |
19 | | -- `tools/Sprite Editor/` remains on disk but is not promoted in the active tools landing page or shared navigation |
20 | | -- preserved sprite paths are excluded from the registry-driven active surface |
21 | | - |
22 | | -## Scope Implemented |
23 | | -- rebased the shared tools shell onto the engine theme tokens from `hubCommon.css` |
24 | | -- kept the active tools landing page and active-tool navigation registry-driven |
25 | | -- kept the four active tool workspaces intact while standardizing the shell, header, nav, and status chrome around them |
26 | | -- added validation for engine-theme stylesheet presence and shared-shell presence on active tool pages |
27 | | -- kept path fixes and repo changes limited to the active tools platform surface |
28 | | - |
29 | | -## Modules Created Or Changed |
30 | | -- `tools/shared/platformShell.css` |
31 | | -- `tools/shared/platformShell.js` |
32 | | -- `tools/index.html` |
33 | | -- `tools/renderToolsIndex.js` |
34 | | -- `scripts/validate-active-tools-surface.mjs` |
35 | | -- `docs/pr/BUILD_PR_ENGINE_THEME_FINAL_PLATFORM_INTEGRATION.md` |
36 | | -- `docs/dev/COMMIT_COMMENT.txt` |
37 | | - |
38 | | -## Public Surface Boundaries |
39 | | -- `engine/ui/hubCommon.css` supplies the theme variables and shared visual tokens |
40 | | -- `tools/shared/platformShell.css` consumes those tokens for platform chrome only |
41 | | -- `tools/shared/platformShell.js` renders the shared shell from the canonical tool registry |
42 | | -- `tools/toolRegistry.js` remains the source of truth for active-tool visibility and navigation |
43 | | -- tool-specific editor logic and engine/game runtime code were not modified for this PR |
44 | | - |
45 | | -## Implementation Summary |
46 | | -- converted the shared shell from a hardcoded standalone palette to the engine theme variables already defined in `hubCommon.css` |
47 | | -- kept the landing page and the four first-class tools visually aligned through the same shared shell |
48 | | -- made the landing surface explicitly communicate that it is engine-themed and registry-driven |
49 | | -- preserved the active tool list as the approved four-tool surface only |
50 | | -- kept preserved sprite content excluded from the first-class tools platform |
51 | | - |
52 | | -## Validation Performed |
53 | | -- `node --check tools/toolRegistry.js` |
54 | | -- `node --check tools/renderToolsIndex.js` |
55 | | -- `node --check tools/shared/platformShell.js` |
56 | | -- `node --check scripts/validate-active-tools-surface.mjs` |
57 | | -- `node --check tools/Vector Asset Studio/main.js` |
58 | | -- `node --check tools/Tilemap Studio/main.js` |
59 | | -- `node --check tools/Parallax Scene Studio/main.js` |
60 | | -- `node --check tools/Vector Map Editor/main.js` |
61 | | -- `node scripts/validate-active-tools-surface.mjs` |
62 | | - |
63 | | -## Validation Summary |
64 | | -- active tool pages still load the engine theme stylesheet from `engine/ui/hubCommon.css` |
65 | | -- active tool pages still load the shared shell stylesheet and module |
66 | | -- the landing page loads the engine theme and shared shell |
67 | | -- only the approved four tools appear in the active registry-driven surface |
68 | | -- preserved sprite tooling does not appear in active landing or navigation output |
69 | | -- stale deprecated sprite-rename references remain blocked by the validator |
70 | | - |
71 | | -## Follow-Up Recommendations |
72 | | -- keep future first-class tool visual changes routed through `hubCommon.css` tokens and `tools/shared/platformShell.css` |
73 | | -- keep future active-tool additions gated through `tools/toolRegistry.js` and the same validator |
74 | | -- avoid reintroducing bespoke shell palettes on per-tool pages |
| 27 | +- `tools/Tile Map Editor/` |
| 28 | +- `tools/Parallax Editor/` |
| 29 | + |
| 30 | +Legacy preserved but excluded from active platform surface: |
| 31 | +- `tools/SpritEditor_old_keep/` |
| 32 | + |
| 33 | +All active tools must: |
| 34 | +- use the engine theme |
| 35 | +- use the same platform shell |
| 36 | +- use the same shared design tokens/components where appropriate |
| 37 | +- appear as one coherent product family |
| 38 | + |
| 39 | +## Engine Theme Rule (mandatory) |
| 40 | +All active tools must adopt the engine theme as the single source of truth for visual styling. |
| 41 | + |
| 42 | +Codex must: |
| 43 | +- identify the current engine theme source(s) |
| 44 | +- normalize them into a reusable shared theme contract if needed |
| 45 | +- apply that contract to all active tools |
| 46 | +- remove duplicated per-tool visual drift where safe |
| 47 | +- preserve tool-specific layout/workspace needs while keeping the shared theme intact |
| 48 | + |
| 49 | +Minimum theme contract should cover: |
| 50 | +- app background / panel background / workspace background |
| 51 | +- primary / secondary / accent / muted colors |
| 52 | +- typography scale |
| 53 | +- spacing scale |
| 54 | +- borders / radii |
| 55 | +- elevation / shadows |
| 56 | +- button/input/tab/menu styling |
| 57 | +- selected/hover/focus/disabled states |
| 58 | +- status colors/messages |
| 59 | +- light/dark behavior only if already supported by engine theme; do not invent a new mode system unless already present |
| 60 | + |
| 61 | +## Implementation Plan (fewest remaining steps) |
| 62 | +Use a single combined build PR with these execution phases: |
| 63 | + |
| 64 | +### Phase 1 — Shared Theme Extraction/Normalization |
| 65 | +- Locate engine theme assets/tokens/styles/components already present in repo |
| 66 | +- Create or refine a shared theme module usable by all active tools |
| 67 | +- Define a stable public contract for tool consumption |
| 68 | +- Avoid duplicating theme values inside each tool |
| 69 | + |
| 70 | +### Phase 2 — Active Tool Adoption |
| 71 | +Apply the shared engine theme to: |
| 72 | +- Vector Map Editor |
| 73 | +- Vector Asset Studio |
| 74 | +- Tile Map Editor |
| 75 | +- Parallax Editor |
| 76 | + |
| 77 | +Per tool: |
| 78 | +- replace divergent shell/header/nav styling with the platform shell |
| 79 | +- align panel/button/input/tab/dialog styling to engine theme |
| 80 | +- keep existing tool workflows intact |
| 81 | +- preserve existing functionality while updating surface appearance |
| 82 | + |
| 83 | +### Phase 3 — Platform Surface Unification |
| 84 | +- Ensure tools landing/index/menu uses same engine-themed shell |
| 85 | +- Ensure active tool cards/listing/navigation are registry-driven where available |
| 86 | +- Ensure naming shown to user matches approved display names |
| 87 | +- Ensure legacy Sprite editor is not presented in the active tools surface |
| 88 | + |
| 89 | +### Phase 4 — Validation and Cleanup |
| 90 | +- verify all active tools load |
| 91 | +- verify no obvious broken paths/imports caused by theme consolidation |
| 92 | +- verify no stale references to deprecated tool names |
| 93 | +- verify visual consistency across active tools |
| 94 | +- verify legacy exclusion behavior |
| 95 | + |
| 96 | +## Acceptance Criteria |
| 97 | +- Every active tool clearly uses the engine theme |
| 98 | +- Tools look like one coherent platform, not separate mini-apps |
| 99 | +- No active tool retains outdated bespoke styling when an engine-theme equivalent exists |
| 100 | +- Shared shell/header/nav is consistent across active tools |
| 101 | +- Legacy `SpritEditor_old_keep` is preserved but excluded from active tool listings/navigation |
| 102 | +- No broken imports, obvious console errors, or missing style assets caused by the change |
| 103 | +- Tool names displayed to users are normalized and approved |
| 104 | + |
| 105 | +## Preferred File Placement |
| 106 | +Codex should prefer shared theme/platform assets in stable shared locations already used by the engine. If a new shared location is needed, keep it minimal and aligned with existing repo organization. |
| 107 | + |
| 108 | +## Constraints |
| 109 | +- Keep this as one combined build PR |
| 110 | +- Do not split into multiple follow-up PRs unless blocked by a real technical dependency |
| 111 | +- No destructive removal of legacy content |
| 112 | +- No unrelated refactors |
| 113 | +- Do not introduce a second competing theme system |
| 114 | + |
| 115 | +## Suggested Deliverables from Codex |
| 116 | +- shared engine-theme contract/module updates |
| 117 | +- active tool shell/theme adoption changes |
| 118 | +- tool index/landing/platform surface polish updates |
| 119 | +- validation notes and any necessary path fixes |
| 120 | + |
| 121 | +## Codex Execution Intent |
| 122 | +This PR is intended to be the shortest path from “mostly organized tools” to “coherent themed platform.” Favor surgical reuse of existing engine theme assets over reinvention. |
0 commit comments