Skip to content

Commit 73c4903

Browse files
author
DavidQ
committed
Remove shape level runtime IDs and clean up Object Vector Studio shape identity display - PR_26133_030-shape-identity-schema-and-ui-cleanup
1 parent 396616c commit 73c4903

13 files changed

Lines changed: 770 additions & 402 deletions
Lines changed: 20 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,39 @@
1-
# PR_26133_029 Playwright V8 Coverage Report
1+
# PR_26133_030 Playwright V8 Coverage Report
22

3-
Task: PR_26133_029-remove-asteroids-shared-tool-fallbacks
3+
Task: PR_26133_030-shape-identity-schema-and-ui-cleanup
44
Date: 2026-05-14
55

66
## Result
77

88
PASS - Coverage reporting was generated during `npm run test:workspace-v2`.
99

10-
- Test result: 49 passed.
1110
- Coverage source: Playwright/Chromium built-in V8 coverage.
1211
- Thresholds: none enforced.
1312
- Coverage is advisory for this PR.
13+
- Source report: `docs/dev/reports/playwright_v8_coverage_report.txt`.
1414

1515
## Exercised Tool Entry Points
1616

17-
- Workspace Manager V2: exercised by all 49 tests.
18-
- Object Vector Studio V2: exercised through shell, editing, dirty-state, geometry, and Asteroids runtime-loading flows.
19-
- Asset Manager V2 and Preview Generator V2: exercised by Workspace Manager V2 cross-tool tests.
20-
- Tool Template V2 and legacy Workspace Manager: not targeted by this Playwright run.
17+
```text
18+
(82%) Preview Generator V2 - exercised 19 runtime JS files
19+
(74%) Asset Manager V2 - exercised 13 runtime JS files
20+
(62%) Palette Manager V2 - exercised 12 runtime JS files
21+
(0%) Tool Template V2 - not exercised by this Playwright run
22+
(91%) Workspace Manager V2 - exercised 10 runtime JS files
23+
(0%) Workspace Manager - not exercised by this Playwright run
24+
```
2125

2226
## Changed Runtime JS Coverage
2327

24-
- `games/Asteroids/game/asteroidObjectGeometry.js`: covered by focused node probes; used by Asteroids scene/world construction.
25-
- `games/Asteroids/entities/Asteroid.js`: covered by focused Asteroids vector-transform and collision probes.
26-
- `games/Asteroids/game/AsteroidsWorld.js`: covered by focused collision timing probes.
27-
- `games/Asteroids/game/AsteroidsGameScene.js` and `games/Asteroids/index.js`: covered by focused validation boot probe and Workspace V2 Asteroids runtime test.
28-
- `tools/shared/vectorAssetSystem.js`: covered by focused node probe.
29-
- `tools/shared/asteroidsPlatformDemo.js`: removed.
28+
```text
29+
(0%) tools/shared/vectorAssetSystem.js - WARNING: changed runtime JS file was not collected by Playwright V8 coverage; advisory only
30+
(94%) tools/object-vector-studio-v2/js/ToolStarterApp.js - executed lines 4196/4196; executed functions 453/484
31+
(95%) tools/object-vector-studio-v2/js/services/ObjectVectorStudioV2SchemaService.js - executed lines 430/430; executed functions 54/57
32+
(98%) src/engine/rendering/ObjectVectorRuntimeAssetService.js - executed lines 935/935; executed functions 107/109
33+
```
3034

31-
## PR-Specific Coverage/Validation Relevance
35+
Note: the generated V8 reporter includes `tools/shared/vectorAssetSystem.js` because it also considers HEAD-changed runtime files. This PR did not modify that file.
3236

33-
The Workspace V2 run plus focused probes verify the paths affected by this PR:
37+
## PR-Specific Note
3438

35-
- Object Vector Studio V2 remains the editor/source payload for Asteroids geometry.
36-
- Asteroids runtime uses manifest-backed `object.asteroids.*` object IDs.
37-
- Shared tools no longer carry Asteroids-specific SVG fallback constants or the Asteroids platform demo module.
38-
- Shape IDs remain local editable shape IDs inside each object and are not used as runtime object identity.
39-
40-
Generated source report: `docs/dev/reports/playwright_v8_coverage_report.txt`.
39+
The Object Vector Studio V2 app and schema service were collected by V8 coverage in the Workspace V2 run. The runtime object-vector asset service was also collected through the Asteroids runtime-loading flow.
Lines changed: 12 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,20 @@
1-
# PR_26133_029 Workspace V2 Validation
1+
# PR_26133_030 Workspace V2 Playwright Results
22

3-
Task: PR_26133_029-remove-asteroids-shared-tool-fallbacks
3+
Task: PR_26133_030-shape-identity-schema-and-ui-cleanup
44
Date: 2026-05-14
55

66
## Result
77

8-
PASS - `npm run test:workspace-v2`
8+
PASS - `npm run test:workspace-v2` completed successfully.
99

10-
- 49 Playwright tests passed.
11-
- Object Vector Studio V2 still loads and edits the Asteroids object payload through `tools.object-vector-studio-v2.objects`.
12-
- Asteroids runtime coverage in Workspace Manager V2 still renders Object Vector assets through `object.asteroids.*` object IDs.
13-
- No sample JSON files were changed.
10+
- Command: `npm run test:workspace-v2`
11+
- Playwright target: `tests/playwright/tools/WorkspaceManagerV2.spec.mjs --project=playwright --workers=1 --reporter=list`
12+
- Final result: 49 passed, 0 failed.
13+
- Runtime console checks: Object Vector Studio V2 targeted flows asserted empty page errors/console errors where covered by the suite.
1414

15-
## Targeted Verification
15+
## PR-Specific Coverage
1616

17-
- PASS - `tools/shared/asteroidsPlatformDemo.js` was removed.
18-
- PASS - `tools/shared` contains no hardcoded Asteroids SVG constants or Asteroids object-vector fallback data.
19-
- PASS - `games/Asteroids/entities/Asteroid.js` no longer defines `BASE_VECTOR_MAP`.
20-
- PASS - Asteroid collision geometry is derived from the manifest Object Vector payload.
21-
- PASS - Object Vector runtime payload validation loads 6 Asteroids objects from `games/Asteroids/game.manifest.json`.
22-
- PASS - Small, medium, and large asteroid geometry profiles resolve from object IDs while shape IDs remain local shape identifiers.
23-
- PASS - No `vector.asteroids.*` references remain in the active Asteroids runtime/shared-tool validation targets.
24-
25-
## Commands
26-
27-
- PASS - `node --check games/Asteroids/game/asteroidObjectGeometry.js`
28-
- PASS - `node --check games/Asteroids/entities/Asteroid.js`
29-
- PASS - `node --check games/Asteroids/game/AsteroidsWorld.js`
30-
- PASS - `node --check games/Asteroids/game/AsteroidsGameScene.js`
31-
- PASS - `node --check games/Asteroids/index.js`
32-
- PASS - `node --check tools/shared/vectorAssetSystem.js`
33-
- PASS - `node --check tests/games/AsteroidsPlatformDemo.test.mjs`
34-
- PASS - focused node probes for Asteroids manifest Object Vector runtime, asteroid vector transforms, collision timing, Asteroids validation boot, and VectorAssetSystem.
35-
- PASS - targeted `rg` scans for removed Asteroids SVG constants, `BASE_VECTOR_MAP`, `vector.asteroids.*`, and shared Asteroids fallback usage.
36-
- PASS - `npm run test:workspace-v2`
17+
- Object Vector Studio V2 loads schema-valid Asteroids object-vector payloads using local `shapeKey` metadata.
18+
- Shape list rendering and selection use `data-shape-key` / `data-object-tile-shape-key`.
19+
- Object Geometry header no longer renders the selected shape type/name suffix.
20+
- Shape override cleanup and delete flows preserve schema-valid `shapeKey` references.
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# PR_26133_030 Shape Identity Schema Cleanup Report
2+
3+
Task: PR_26133_030-shape-identity-schema-and-ui-cleanup
4+
Date: 2026-05-14
5+
6+
## Contract Update
7+
8+
- Removed shape-level `id` from Object Vector Studio V2 shape data.
9+
- Added required local editor metadata fields on shapes: `shapeKey`, `label`, and `tool`.
10+
- Updated animation frame overrides from `shapeId` to `shapeKey`.
11+
- Kept `object.*` object IDs as the only runtime/gameplay object identity.
12+
- Added schema/manual validation that local `shapeKey` values do not use `object.*` identity format.
13+
14+
## Manifest/Data Changes
15+
16+
- Migrated `games/Asteroids/game.manifest.json` Object Vector Studio V2 shapes from `id` to `shapeKey` plus display `label` and tool identity `tool`.
17+
- Migrated Asteroids ship `shapeOverrides` to reference `shapeKey`.
18+
- Confirmed Asteroids Object Vector payload has no shape-level `id` fields and all shapes provide `shapeKey`, `label`, `tool`, and `type`.
19+
20+
## UI/Runtime Changes
21+
22+
- Object Vector Studio V2 selection, shape tiles, render-surface DOM hooks, palette sync, grouping, geometry, transform, duplicate, and delete logic now use local shape keys.
23+
- Object tile shape rows display the local shape label, preserving rows such as `0. ship-hull`, `1. ship-thrust-port`, and `2. ship-thrust-starboard`.
24+
- Object Geometry accordion header now renders as `Object Geometry` without selected shape suffix text.
25+
- Runtime inheritance and frame override resolution now match shapes by `shapeKey`.
26+
27+
## Validation
28+
29+
- `npm run test:workspace-v2`: PASS, 49 passed.
30+
- Object Vector Studio V2 schema validation for Asteroids payload: PASS.
31+
- Workspace Manager V2 game manifest schema validation for `games/Asteroids/game.manifest.json`: PASS.
32+
- Object Vector runtime asset load from Asteroids manifest, including `object.asteroids.asteroid.small`: PASS.

games/Asteroids/game.manifest.json

Lines changed: 34 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,9 @@
262262
"name": "Asteroids Ship",
263263
"shapes": [
264264
{
265-
"id": "ship-hull",
265+
"shapeKey": "ship-hull",
266+
"label": "ship-hull",
267+
"tool": "polygon",
266268
"type": "polygon",
267269
"order": 0,
268270
"visible": true,
@@ -304,7 +306,9 @@
304306
}
305307
},
306308
{
307-
"id": "ship-thrust-port",
309+
"shapeKey": "ship-thrust-port",
310+
"label": "ship-thrust-port",
311+
"tool": "line",
308312
"type": "line",
309313
"order": 1,
310314
"visible": true,
@@ -332,7 +336,9 @@
332336
}
333337
},
334338
{
335-
"id": "ship-thrust-starboard",
339+
"shapeKey": "ship-thrust-starboard",
340+
"label": "ship-thrust-starboard",
341+
"tool": "line",
336342
"type": "line",
337343
"order": 2,
338344
"visible": true,
@@ -371,11 +377,11 @@
371377
"durationFrames": 1,
372378
"shapeOverrides": [
373379
{
374-
"shapeId": "ship-thrust-port",
380+
"shapeKey": "ship-thrust-port",
375381
"visible": false
376382
},
377383
{
378-
"shapeId": "ship-thrust-starboard",
384+
"shapeKey": "ship-thrust-starboard",
379385
"visible": false
380386
}
381387
]
@@ -392,11 +398,11 @@
392398
"durationFrames": 1,
393399
"shapeOverrides": [
394400
{
395-
"shapeId": "ship-thrust-port",
401+
"shapeKey": "ship-thrust-port",
396402
"visible": true
397403
},
398404
{
399-
"shapeId": "ship-thrust-starboard",
405+
"shapeKey": "ship-thrust-starboard",
400406
"visible": true
401407
}
402408
]
@@ -410,7 +416,9 @@
410416
"name": "Large Asteroid",
411417
"shapes": [
412418
{
413-
"id": "large-asteroid-ridge",
419+
"shapeKey": "large-asteroid-ridge",
420+
"label": "large-asteroid-ridge",
421+
"tool": "polygon",
414422
"type": "polygon",
415423
"order": 0,
416424
"visible": true,
@@ -504,7 +512,9 @@
504512
"name": "Medium Asteroid",
505513
"shapes": [
506514
{
507-
"id": "medium-asteroid-ridge",
515+
"shapeKey": "medium-asteroid-ridge",
516+
"label": "medium-asteroid-ridge",
517+
"tool": "polygon",
508518
"type": "polygon",
509519
"order": 0,
510520
"visible": true,
@@ -578,7 +588,9 @@
578588
"name": "Small Asteroid",
579589
"shapes": [
580590
{
581-
"id": "small-asteroid-ridge",
591+
"shapeKey": "small-asteroid-ridge",
592+
"label": "small-asteroid-ridge",
593+
"tool": "polygon",
582594
"type": "polygon",
583595
"order": 0,
584596
"visible": true,
@@ -648,7 +660,9 @@
648660
"name": "Large UFO",
649661
"shapes": [
650662
{
651-
"id": "large-ufo-body",
663+
"shapeKey": "large-ufo-body",
664+
"label": "large-ufo-body",
665+
"tool": "ellipse",
652666
"type": "ellipse",
653667
"order": 0,
654668
"visible": true,
@@ -676,7 +690,9 @@
676690
}
677691
},
678692
{
679-
"id": "large-ufo-canopy",
693+
"shapeKey": "large-ufo-canopy",
694+
"label": "large-ufo-canopy",
695+
"tool": "ellipse",
680696
"type": "ellipse",
681697
"order": 1,
682698
"visible": true,
@@ -724,7 +740,9 @@
724740
"name": "Small UFO",
725741
"shapes": [
726742
{
727-
"id": "small-ufo-body",
743+
"shapeKey": "small-ufo-body",
744+
"label": "small-ufo-body",
745+
"tool": "ellipse",
728746
"type": "ellipse",
729747
"order": 0,
730748
"visible": true,
@@ -752,7 +770,9 @@
752770
}
753771
},
754772
{
755-
"id": "small-ufo-canopy",
773+
"shapeKey": "small-ufo-canopy",
774+
"label": "small-ufo-canopy",
775+
"tool": "ellipse",
756776
"type": "ellipse",
757777
"order": 1,
758778
"visible": true,

0 commit comments

Comments
 (0)