Skip to content

Commit ab322f0

Browse files
committed
Build combined vector showcase + geometry runtime final docs-driven integration
- productize first-class tools landing/showcase surface - enforce engine theme across all active tools - finalize deterministic vector geometry runtime contracts - preserve legacy sprite editor path while excluding it from active platform surface
1 parent 5e9ea48 commit ab322f0

13 files changed

Lines changed: 278 additions & 68 deletions

docs/dev/CODEX_COMMANDS.md

Lines changed: 28 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,36 @@
1+
# Codex Commands
2+
3+
## Primary build
14
MODEL: GPT-5.4
25
REASONING: high
36

47
COMMAND:
5-
Create BUILD_PR_ENGINE_THEME_FINAL_PLATFORM_INTEGRATION as a single combined build PR.
8+
Create `BUILD_PR_VECTOR_SHOWCASE_AND_GEOMETRY_RUNTIME_FINAL` as a docs-driven implementation PR that combines the final public-facing vector platform showcase with deterministic geometry runtime finalization.
9+
10+
### Goals
11+
- registry-driven showcase surface
12+
- mandatory engine theme across all active first-class tools
13+
- deterministic vector geometry runtime contracts
14+
- stable transform/render/precision behavior
15+
- preserve `tools/SpritEditor_old_keep/` but exclude it from active platform surface
616

7-
GOAL:
8-
Finish the active tools platform in the fewest remaining steps by making all first-class tools use the engine theme and closing remaining platform-surface integration gaps.
17+
### Active first-class tools
18+
- `tools/Vector Map Editor/`
19+
- `tools/Vector Asset Studio/`
20+
- `tools/Tile Map Editor/`
21+
- `tools/Parallax Editor/`
922

10-
DO:
11-
1. Identify the existing engine theme source of truth
12-
2. Normalize/extract a reusable shared theme contract only if needed
13-
3. Apply the engine theme to all active tools under tools/
14-
- Vector Map Editor
15-
- Vector Asset Studio
16-
- Tile Map Editor
17-
- Parallax Editor
18-
4. Unify shared shell/surface elements across active tools
19-
5. Ensure active tools surface/index/navigation reflects only active tools
20-
6. Preserve but exclude tools/SpritEditor_old_keep from active tool listings
21-
7. Fix broken paths/imports/assets caused by the consolidation if encountered
22-
8. Validate active tool loading and visual consistency
23+
### Constraints
24+
- keep changes surgical
25+
- do not delete legacy sprite editor preserved path
26+
- no obsolete `Sprite Editor V3` references
27+
- no runtime-breaking engine rewrites
28+
- do not hardcode duplicate tool lists outside registry
29+
- prefer shared engine/theme and shared vector runtime over tool-specific behavior
2330

24-
DO NOT:
25-
- delete legacy Sprite content
26-
- invent a second theme system
27-
- perform unrelated refactors
28-
- split into multiple PRs unless a true blocker is discovered
31+
### Package output
32+
Create:
33+
`<project folder>/tmp/BUILD_PR_VECTOR_SHOWCASE_AND_GEOMETRY_RUNTIME_FINAL.zip`
2934

30-
OUTPUT:
31-
<project folder>/tmp/BUILD_PR_ENGINE_THEME_FINAL_PLATFORM_INTEGRATION.zip
35+
## Commit comment
36+
Use `docs/dev/commit_comment.txt`.

docs/dev/COMMIT_COMMENT.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Complete final active-tools platform integration by rebasing the shared shell onto the engine theme, preserving registry-driven navigation, and excluding preserved sprite tooling from the first-class surface.
1+
Finalize the registry-driven vector platform showcase and deterministic geometry runtime contract while preserving legacy sprite paths outside the active surface.
Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,13 @@
1-
BUILD_PR_ENGINE_THEME_FINAL_PLATFORM_INTEGRATION
1+
CHANGE SUMMARY
22

3-
Summary:
4-
- makes engine theme mandatory for all active first-class tools
5-
- combines remaining theme/surface integration into one build PR
6-
- preserves legacy Sprite editor while excluding it from active tool surface
7-
- aims to finish platform polish in the fewest possible remaining steps
3+
Bundle:
4+
BUILD_PR_VECTOR_SHOWCASE_AND_GEOMETRY_RUNTIME_FINAL
85

9-
Active tools in scope:
10-
- tools/Vector Map Editor/
11-
- tools/Vector Asset Studio/
12-
- tools/Tile Map Editor/
13-
- tools/Parallax Editor/
6+
Intent:
7+
Combine the last two major remaining docs-only steps into one Codex-ready PR bundle.
148

15-
Legacy preserved:
16-
- tools/SpritEditor_old_keep/
9+
What this bundle tells Codex to do:
10+
1. Build the public-facing platform showcase / landing surface.
11+
2. Make active tools registry-driven and engine-theme consistent.
12+
3. Finalize deterministic vector geometry runtime contracts.
13+
4. Keep legacy sprite editor preserved but excluded from the active platform surface.

docs/dev/reports/file_tree.txt

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
docs/
2-
pr/
3-
BUILD_PR_ENGINE_THEME_FINAL_PLATFORM_INTEGRATION.md
4-
dev/
5-
codex_commands.md
6-
commit_comment.txt
7-
reports/
8-
change_summary.txt
9-
validation_checklist.txt
10-
file_tree.txt
1+
BUILD_PR_VECTOR_SHOWCASE_AND_GEOMETRY_RUNTIME_FINAL/
2+
└── docs/
3+
├── pr/
4+
│ └── BUILD_PR_VECTOR_SHOWCASE_AND_GEOMETRY_RUNTIME_FINAL.md
5+
└── dev/
6+
├── codex_commands.md
7+
├── commit_comment.txt
8+
└── reports/
9+
├── change_summary.txt
10+
├── validation_checklist.txt
11+
└── file_tree.txt
Lines changed: 20 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,21 @@
1-
BUILD_PR_ENGINE_THEME_FINAL_PLATFORM_INTEGRATION Validation Checklist
1+
VALIDATION CHECKLIST
22

3-
[ ] Engine theme source of truth identified
4-
[ ] Shared theme contract reusable by active tools
5-
[ ] Vector Map Editor uses engine theme
6-
[ ] Vector Asset Studio uses engine theme
7-
[ ] Tile Map Editor uses engine theme
8-
[ ] Parallax Editor uses engine theme
9-
[ ] Shared shell/surface behavior consistent across active tools
10-
[ ] Active tool list excludes SpritEditor_old_keep
11-
[ ] No stale deprecated tool-name references remain on active surface
12-
[ ] No broken imports/paths/assets introduced by theme consolidation
13-
[ ] Active tools load without obvious console/runtime errors
14-
[ ] Final visual result reads as one coherent platform
3+
[ ] `tools/` remains the first-class active tool root
4+
[ ] Active tools shown only via registry
5+
[ ] Showcase surface lists only:
6+
[ ] Vector Map Editor
7+
[ ] Vector Asset Studio
8+
[ ] Tile Map Editor
9+
[ ] Parallax Editor
10+
[ ] `tools/SpritEditor_old_keep/` preserved
11+
[ ] Legacy sprite editor excluded from active showcase surface
12+
[ ] No `Sprite Editor V3` references remain
13+
[ ] All active tools consume engine theme tokens
14+
[ ] Shared shell/header/nav language is normalized
15+
[ ] Deterministic transform order documented
16+
[ ] Deterministic render ordering documented
17+
[ ] Precision / epsilon policy documented
18+
[ ] Path normalization rules documented
19+
[ ] Vector-native sample scenarios render stably
20+
[ ] No broken active tool links
21+
[ ] Combined PR remains surgical and docs-first
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
# BUILD_PR_VECTOR_SHOWCASE_AND_GEOMETRY_RUNTIME_FINAL
2+
3+
## Purpose
4+
Deliver the final public-facing vector platform showcase and deterministic vector geometry runtime finalization in one surgical build PR.
5+
6+
## Scope
7+
In scope:
8+
- registry-driven showcase surface for the active first-class tools
9+
- mandatory engine theme framing for the active tools platform
10+
- explicit deterministic vector geometry runtime policy
11+
- stable transform, render-order, and precision contract visibility
12+
- preserved-but-excluded legacy sprite tooling
13+
14+
Out of scope:
15+
- gameplay feature work
16+
- engine rewrites
17+
- duplicate tool navigation lists outside the registry
18+
- deletion of preserved sprite paths
19+
20+
## Active First-Class Tools
21+
- `tools/Vector Map Editor/`
22+
- `tools/Vector Asset Studio/`
23+
- `tools/Tilemap Studio/`
24+
- `tools/Parallax Scene Studio/`
25+
26+
## Preserved But Excluded
27+
- actual preserved legacy path on disk: `tools/SpriteEditor_old_keep/`
28+
- preserved current sprite workspace on disk: `tools/Sprite Editor/`
29+
- neither preserved sprite path appears in the active platform showcase or shared navigation
30+
31+
## Modules Created Or Changed
32+
- `tools/toolRegistry.js`
33+
- `tools/renderToolsIndex.js`
34+
- `tools/index.html`
35+
- `tools/shared/platformShell.css`
36+
- `tools/shared/vectorGeometryRuntime.js`
37+
- `tests/tools/VectorGeometryRuntime.test.mjs`
38+
- `docs/pr/BUILD_PR_VECTOR_SHOWCASE_AND_GEOMETRY_RUNTIME_FINAL.md`
39+
- `docs/dev/COMMIT_COMMENT.txt`
40+
41+
## Showcase Surface Summary
42+
- the tools landing surface remains registry-driven through `tools/toolRegistry.js`
43+
- active showcase cards now render richer public-facing metadata from the registry instead of hardcoded per-page content
44+
- each first-class tool card now exposes its canonical open action and registry-owned sample/help entry points where available
45+
- the landing page explicitly calls out the shared engine theme and deterministic geometry runtime proof without duplicating the active tool list outside the registry
46+
47+
## Geometry Runtime Finalization
48+
- `tools/shared/vectorGeometryRuntime.js` now exports `VECTOR_GEOMETRY_RUNTIME_POLICY`
49+
- the policy makes the deterministic runtime contract explicit:
50+
- fixed six-decimal rounding
51+
- epsilon `0.000001`
52+
- transform order `scale -> rotate -> translate`
53+
- render order `layer order -> shape order`
54+
- collision primitives follow render order
55+
- prepared runtime assets now carry the shared `runtimePolicy` payload and a deterministic policy report
56+
57+
## Shared Boundaries Preserved
58+
- `engine/ui/hubCommon.css` remains the engine theme source of truth
59+
- `tools/shared/platformShell.css` remains the shared tool-shell layer consuming engine theme tokens
60+
- `tools/toolRegistry.js` remains the single source of truth for active tool visibility and showcase metadata
61+
- geometry runtime behavior remains shared infrastructure, not tool-specific logic
62+
63+
## Validation Performed
64+
- `node --check tools/toolRegistry.js`
65+
- `node --check tools/renderToolsIndex.js`
66+
- `node --check tools/shared/platformShell.js`
67+
- `node --check tools/shared/vectorGeometryRuntime.js`
68+
- `node --check scripts/validate-active-tools-surface.mjs`
69+
- `node --check tests/tools/VectorGeometryRuntime.test.mjs`
70+
- `node scripts/validate-active-tools-surface.mjs`
71+
- `node scripts/run-node-tests.mjs`
72+
73+
## Validation Summary
74+
- active showcase cards still come from the registry only
75+
- active landing and navigation still exclude preserved sprite paths
76+
- no obsolete deprecated sprite-rename references remain in the validated surface
77+
- active tools still load the engine theme and shared shell
78+
- repeated vector geometry runtime preparation now asserts deep deterministic equality in tests
79+
- vector-native template and sample-game flows continue to consume `runtimeKind: "vector-geometry"` assets under the shared runtime contract
80+
81+
## Follow-Up Recommendations
82+
- keep future showcase-card changes in `tools/toolRegistry.js` and `tools/renderToolsIndex.js`
83+
- keep future geometry runtime precision changes centralized in `tools/shared/vectorGeometryRuntime.js`
84+
- avoid adding tool-local geometry policy forks

scripts/validate-active-tools-surface.mjs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const SCAN_TARGETS = [
2525
"tools/renderToolsIndex.js",
2626
"tools/shared/platformShell.js",
2727
"tools/shared/platformShell.css",
28-
"docs/pr/BUILD_PR_ENGINE_THEME_FINAL_PLATFORM_INTEGRATION.md",
28+
"docs/pr/BUILD_PR_VECTOR_SHOWCASE_AND_GEOMETRY_RUNTIME_FINAL.md",
2929
"docs/dev/commit_comment.txt"
3030
];
3131

@@ -81,6 +81,13 @@ async function main() {
8181
if (TOOL_NAME_SUFFIX_PATTERN.test(tool.displayName) || TOOL_NAME_SUFFIX_PATTERN.test(tool.folderName)) {
8282
issues.push(`Disallowed active naming suffix detected for ${tool.displayName} (${tool.folderName}).`);
8383
}
84+
const sampleEntryPoints = Array.isArray(tool.sampleEntryPoints) ? tool.sampleEntryPoints : [];
85+
for (const sampleEntry of sampleEntryPoints) {
86+
const samplePath = path.join(repoRoot, "tools", sampleEntry.path);
87+
if (!(await pathExists(samplePath))) {
88+
issues.push(`Missing showcase sample/help entry point for ${tool.displayName}: tools/${sampleEntry.path}`);
89+
}
90+
}
8491
}
8592

8693
const visibleLegacyTools = toolRegistry.filter((tool) => tool.status === "legacy" && tool.visibleInToolsList === true);

tests/tools/VectorGeometryRuntime.test.mjs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ import { loadPackagedProjectRuntime } from "../../tools/shared/runtimeAssetLoade
33
import {
44
inspectVectorGeometryRuntimeAsset,
55
prepareVectorGeometryRuntimeAsset,
6-
summarizeVectorGeometryRuntime
6+
summarizeVectorGeometryRuntime,
7+
VECTOR_GEOMETRY_RUNTIME_POLICY
78
} from "../../tools/shared/vectorGeometryRuntime.js";
89
import { normalizeSvgToVectorAsset } from "../../tools/shared/vector/vectorAssetBridge.js";
910
import { VECTOR_ASSET_FORMAT } from "../../tools/shared/vector/vectorAssetContract.js";
@@ -146,11 +147,22 @@ export async function run() {
146147
assert.equal(runtimeAsset.renderables.length, 2);
147148
assert.equal(runtimeAsset.collisionPrimitives.length, 2);
148149
assert.deepEqual(runtimeAsset.bounds.center, { x: 10, y: 3 });
150+
assert.deepEqual(runtimeAsset.runtimePolicy, VECTOR_GEOMETRY_RUNTIME_POLICY);
151+
assert.equal(runtimeAsset.reports.at(-1)?.code, "VECTOR_RUNTIME_POLICY");
149152
assert.equal(
150153
summarizeVectorGeometryRuntime(runtimeAsset),
151154
"Vector geometry runtime ready for vector.contract.sample with 2 renderable primitives."
152155
);
153156

157+
const repeatedRuntimeAsset = prepareVectorGeometryRuntimeAsset(contractAsset, {
158+
transform: {
159+
translate: { x: 10, y: 5 },
160+
rotateRadians: 0,
161+
scale: { x: 1, y: 1 }
162+
}
163+
});
164+
assert.deepEqual(repeatedRuntimeAsset, runtimeAsset);
165+
154166
const legacyAsset = normalizeSvgToVectorAsset({
155167
id: "vector.legacy.sample",
156168
name: "Legacy Sample",

tools/index.html

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,18 +23,22 @@
2323

2424
<section class="hero">
2525
<h1>ToolboxAid - Active Tools</h1>
26-
<p class="subtitle">Registry-driven tooling surface for vector maps, vector assets, tile maps, and parallax scenes, all framed by the shared engine theme from <code>engine/ui/hubCommon.css</code>. Preserved legacy editors stay on disk without appearing in the first-class navigation.</p>
26+
<p class="subtitle">Registry-driven vector platform showcase for geometry authoring, vector assets, tile maps, and parallax scenes, all framed by the shared engine theme from <code>engine/ui/hubCommon.css</code>. Deterministic geometry runtime behavior remains shared platform infrastructure, not tool-local behavior.</p>
2727
</section>
2828

2929
<section>
30-
<h2>Active Tools</h2>
30+
<h2>Vector Platform Showcase</h2>
3131
<div class="grid" data-active-tools-grid>
3232
</div>
3333
<noscript>
3434
<p class="callout"><strong>JavaScript required:</strong> the active tools list is generated from the shared tools registry.</p>
3535
</noscript>
3636
</section>
3737

38+
<div class="callout">
39+
<strong>Geometry runtime proof:</strong> active vector-native flows share one deterministic runtime contract for transform order, render preparation, rounding precision, and collision-ready output.
40+
</div>
41+
3842
<section>
3943
<h2>Planned Next</h2>
4044
<p>Palette management and additional workflow tools are next priorities, followed by supporting tools that round out the asset workflow.</p>

tools/renderToolsIndex.js

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,28 @@ function escapeHtml(value) {
1010
}
1111

1212
function renderToolCard(tool) {
13+
const sampleLinks = Array.isArray(tool.sampleEntryPoints) && tool.sampleEntryPoints.length > 0
14+
? `
15+
<div class="meta">
16+
${tool.sampleEntryPoints.map((entry) => `
17+
<a class="tools-platform-card__action tools-platform-card__action--secondary" href="${escapeHtml(entry.path)}">${escapeHtml(entry.label)}</a>
18+
`).join("")}
19+
</div>
20+
`
21+
: "";
22+
1323
return `
14-
<div class="card">
24+
<div class="card tools-platform-card">
25+
<div class="meta">
26+
<span class="pill live">${escapeHtml(tool.showcaseTag || "Active Tool")}</span>
27+
<span class="pill planned">${escapeHtml(tool.showcaseStatus || "Engine Theme")}</span>
28+
</div>
1529
<h3><a href="${escapeHtml(tool.entryPoint)}">${escapeHtml(tool.displayName)}</a></h3>
1630
<p>${escapeHtml(tool.description)}</p>
1731
<div class="meta">
18-
<span class="pill live">Active Tool</span>
19-
<span class="pill planned">Engine Theme</span>
32+
<a class="tools-platform-card__action" href="${escapeHtml(tool.entryPoint)}">Open Tool</a>
2033
</div>
34+
${sampleLinks}
2135
</div>
2236
`;
2337
}

0 commit comments

Comments
 (0)