Skip to content

Commit 70285e8

Browse files
author
DavidQ
committed
Create PR_26126_011-preview-generator-v2-rollback-and-cold-copy. Roll back all Preview Generator V2 changes made after the repo state before Preview Generator V2 was created. Remove the failed Preview Generator V2 implementation/docs/test changes from PR_26126_008 through PR_26126_010 unless needed only as review artifacts. Then create tools/preview-generator-v2/index.html by copying existing working preview.html cold as-is with no reskin, no rewrite, no renamed labels, no regrouping, no new controls, no removed controls, and no behavior changes. Preserve existing functionality exactly. Do not create a Preview Generator V2 schema. Do not modify samples. Add only the minimum registration/linking needed to open the new tool if required. Produce review artifacts showing rollback plus cold-copy result.
1 parent d643580 commit 70285e8

14 files changed

Lines changed: 5406 additions & 12338 deletions

docs/dev/codex_commands.md

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,24 @@
1-
# Codex Commands - PR_26126_010-preview-generator-v2-reskin-correction
1+
# Codex Commands - PR_26126_011-preview-generator-v2-rollback-and-cold-copy
22

33
```bash
4-
codex run "Create PR_26126_010-preview-generator-v2-reskin-correction. Correct Preview Generator V2 as a reskin of existing preview.html, not a rewrite. Review and preserve all existing preview.html functionality, labels, inputs, ids where possible, and behavior. Regroup the existing controls into the Palette Manager-style layout. Left column must contain: Repo Destination (rename Game Destination; it opens a folder, not a file), Target Source, and Render Controls. Center column must replace Main Preview with Paths or IDs using an input box. Right column must place Status under Output Summary. Header/NAV must remove Apply to Game and Export Image; keep Generate Preview only in the Palette Manager-style NAV. Do not add JSON UI. Do not create a Preview Generator V2 schema. Do not modify samples. Update Playwright/tests only for this corrected reskin behavior. Produce review artifacts."
4+
codex run "Create PR_26126_011-preview-generator-v2-rollback-and-cold-copy. Roll back all Preview Generator V2 changes made after the repo state before Preview Generator V2 was created. Remove the failed Preview Generator V2 implementation/docs/test changes from PR_26126_008 through PR_26126_010 unless needed only as review artifacts. Then create tools/preview-generator-v2/index.html by copying existing working preview.html cold as-is with no reskin, no rewrite, no renamed labels, no regrouping, no new controls, no removed controls, and no behavior changes. Preserve existing functionality exactly. Do not create a Preview Generator V2 schema. Do not modify samples. Add only the minimum registration/linking needed to open the new tool if required. Produce review artifacts showing rollback plus cold-copy result."
55
```
66

77
## Validation Commands
88

99
```bash
10-
node --check tools/preview-generator-v2/main.js
11-
node --check tools/preview-generator-v2/previewGeneratorShell.js
12-
node --check tests/tools/PreviewGeneratorV2FirstPass.test.mjs
13-
node tests/tools/PreviewGeneratorV2FirstPass.test.mjs
14-
git diff --check -- tools/preview-generator-v2/index.html tools/preview-generator-v2/main.js tools/preview-generator-v2/previewGeneratorShell.js tools/preview-generator-v2/previewGeneratorV2.css tools/toolRegistry.js tests/tools/PreviewGeneratorV2FirstPass.test.mjs docs/dev/codex_commands.md docs/dev/commit_comment.txt
10+
Get-FileHash tools/preview/preview_svg_generator.html, tools/preview-generator-v2/index.html -Algorithm SHA256
11+
node --input-type=module -e "import('./tools/toolRegistry.js').then(({getToolById})=>{const tool=getToolById('preview-generator-v2'); if(!tool || tool.entryPoint !== 'preview-generator-v2/index.html') throw new Error('preview-generator-v2 registry entry invalid'); console.log('preview-generator-v2 registry entry valid');})"
12+
node --input-type=module -e "import { chromium } from '@playwright/test'; import { startRepoServer } from './tests/helpers/playwrightRepoServer.mjs'; const server=await startRepoServer(); const browser=await chromium.launch({headless:true}); const page=await browser.newPage({viewport:{width:1280,height:900}}); const errors=[]; page.on('pageerror', error=>errors.push(error.message)); await page.goto(`${server.baseUrl}/tools/preview-generator-v2/index.html`, {waitUntil:'networkidle'}); if (await page.locator('h1').innerText() !== 'Preview SVG Generator') throw new Error('cold-copy heading mismatch'); if (await page.locator('#executeBtn').count() !== 1) throw new Error('executeBtn missing'); if (await page.locator('input[name=\"targetType\"]').count() !== 3) throw new Error('targetType radios missing'); if (await page.locator('#sampleList').count() !== 1) throw new Error('sampleList missing'); if (await page.locator('.preview-generator-v2, [data-preview-generator-v2-header], #shared-theme-header').count() !== 0) throw new Error('reskin shell still present'); if (errors.length) throw new Error(errors.join(' | ')); await browser.close(); await server.close(); console.log('preview-generator-v2 cold-copy browser smoke valid');"
13+
git diff --check -- tools/preview-generator-v2/index.html tools/toolRegistry.js docs/dev/codex_commands.md docs/dev/commit_comment.txt
1514
npm run test:workspace-v2
1615
npm run codex:review-artifacts
1716
```
1817

1918
## Notes
2019

21-
`tools/preview/preview_svg_generator.html` was used as the existing preview generator base because there is no literal `preview.html` file in the repository.
20+
`tools/preview/preview_svg_generator.html` was used as the existing working preview generator because there is no literal `preview.html` file in the repository.
2221

2322
`npm run test:workspace-v2` was attempted, but the script is not defined in this checkout.
2423

25-
Full samples smoke test was skipped because this PR is scoped to Preview Generator V2.
24+
Full samples smoke test was skipped because this PR is scoped to rolling back Preview Generator V2 and cold-copying one tool file.

docs/dev/commit_comment.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Correct Preview Generator V2 reskin layout - PR_26126_010-preview-generator-v2-reskin-correction
1+
Rollback Preview Generator V2 rewrites and cold-copy working generator - PR_26126_011-preview-generator-v2-rollback-and-cold-copy
Lines changed: 21 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,28 @@
11
# git status --short
22
M docs/dev/codex_commands.md
33
M docs/dev/commit_comment.txt
4-
M docs/dev/reports/codex_changed_files.txt
5-
M docs/dev/reports/codex_review.diff
6-
M tests/tools/PreviewGeneratorV2FirstPass.test.mjs
7-
A tools/preview-generator-v2/index.html
8-
A tools/preview-generator-v2/main.js
9-
A tools/preview-generator-v2/previewGeneratorShell.js
10-
A tools/preview-generator-v2/previewGeneratorV2.css
4+
D tests/tools/PreviewGeneratorV2FirstPass.test.mjs
5+
M tools/preview-generator-v2/index.html
6+
D tools/preview-generator-v2/main.js
7+
D tools/preview-generator-v2/previewGeneratorShell.js
8+
D tools/preview-generator-v2/previewGeneratorV2.css
9+
D tools/preview/index.html
10+
D tools/preview/main.js
11+
D tools/preview/previewGeneratorShell.js
12+
D tools/preview/previewGeneratorV2.css
1113
M tools/toolRegistry.js
1214

1315
# git diff --stat
14-
docs/dev/codex_commands.md | 19 +-
16+
docs/dev/codex_commands.md | 17 +-
1517
docs/dev/commit_comment.txt | 2 +-
16-
docs/dev/reports/codex_changed_files.txt | 32 +-
17-
docs/dev/reports/codex_review.diff | 6646 ++++++++++++++++++--
18-
tests/tools/PreviewGeneratorV2FirstPass.test.mjs | 144 +-
19-
tools/preview-generator-v2/index.html | 188 +
20-
tools/preview-generator-v2/main.js | 932 +++
21-
.../preview-generator-v2/previewGeneratorShell.js | 186 +
22-
tools/preview-generator-v2/previewGeneratorV2.css | 490 ++
23-
tools/toolRegistry.js | 18 +
24-
10 files changed, 8041 insertions(+), 616 deletions(-)
18+
tests/tools/PreviewGeneratorV2FirstPass.test.mjs | 157 ---
19+
tools/preview-generator-v2/index.html | 1182 +++++++++++++++++---
20+
tools/preview-generator-v2/main.js | 932 ---------------
21+
.../preview-generator-v2/previewGeneratorShell.js | 186 ---
22+
tools/preview-generator-v2/previewGeneratorV2.css | 490 --------
23+
tools/preview/index.html | 171 ---
24+
tools/preview/main.js | 493 --------
25+
tools/preview/previewGeneratorShell.js | 186 ---
26+
tools/preview/previewGeneratorV2.css | 534 ---------
27+
tools/toolRegistry.js | 4 +-
28+
12 files changed, 1029 insertions(+), 3325 deletions(-)

0 commit comments

Comments
 (0)