Skip to content

Commit 485e96c

Browse files
committed
Merge remote-tracking branch 'origin/main' into codex/pr-26171-044-idea-board-game-hub-project-flow
# Conflicts: # docs_build/dev/reports/codex_changed_files.txt # docs_build/dev/reports/codex_review.diff
2 parents 2a38796 + 83fa8ad commit 485e96c

13 files changed

Lines changed: 1081 additions & 25 deletions
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# PR_26171_067 Instruction Compliance Checklist
2+
3+
## Required Reads
4+
5+
- PASS: Read `docs_build/dev/PROJECT_INSTRUCTIONS.md` before implementation.
6+
- PASS: Read `docs_build/dev/PROJECT_MULTI_PC.txt` before implementation.
7+
- PASS: Read repository `AGENTS.md` instructions from the active workspace context.
8+
- PASS: Read relevant target files before editing.
9+
10+
## Gate Checks
11+
12+
- PASS: Started from `main`.
13+
- PASS: Pulled latest `origin/main`.
14+
- PASS: Repo was clean before branch creation.
15+
- PASS: Created scoped branch `pr/26171-067-tts-profile-emotion-table-foundation`.
16+
- PASS: PR number `067` is odd and assigned to Laptop / Environment 2.
17+
- PASS: TTS Studio is within Laptop ownership.
18+
- PASS: Active path is `toolbox/text-to-speech/`.
19+
- PASS: No wrong `tools/text2speech/` path was created.
20+
- PASS: No database changes were made.
21+
- PASS: No placeholder-only provider blocking behavior was introduced.
22+
23+
## Required Artifacts
24+
25+
- PASS: PR-specific report created.
26+
- PASS: Parent-child table checklist created.
27+
- PASS: Message/TTS contract checklist created.
28+
- PASS: Validation report created.
29+
- PASS: Manual validation notes created.
30+
- PASS: `codex_review.diff` and `codex_changed_files.txt` will be generated from the final scoped diff.
31+
- PASS: Repo-structured delta ZIP will be created under `tmp/`.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# PR_26171_067 Manual Validation Notes
2+
3+
## Notes
4+
5+
- Verified TTS Studio keeps the active path `toolbox/text-to-speech/`.
6+
- Verified the page uses Theme V2 classes and external JavaScript only.
7+
- Verified the profile table can open child Emotion Settings by clicking the profile row.
8+
- Verified `Default Balanced Profile` delete is disabled because it is marked in use by Message Studio data.
9+
- Verified default `Neutral` emotion delete is disabled because it is marked in use by Message Parts.
10+
- Verified Add Profile, Edit Profile, Add Emotion, and Edit Emotion inline rows through targeted Playwright validation.
11+
- Verified Message Studio remains separate and its existing TTS dropdown smoke path still passes.
12+
- Verified no `tools/text2speech/` path was created.
13+
- Verified no database files were changed.
14+
15+
## Follow Up
16+
17+
- Future persistence can connect TTS Studio profile authoring to the existing Local API profile contract once that API ownership is assigned.
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# PR_26171_067 Message TTS Contract Checklist
2+
3+
## Ownership
4+
5+
- PASS: Message Studio owns message text and ordered message parts.
6+
- PASS: TTS Studio owns reusable TTS Profiles and per-profile Emotion Settings.
7+
- PASS: `src/engine/audio/` remains the playback owner.
8+
- PASS: Audio playback results remain owned by the audio engine flow.
9+
- PASS: Message Studio and TTS Studio are not merged into one tool.
10+
11+
## Contract Readiness
12+
13+
- PASS: TTS Studio exposes `TTS_PROFILE_CONTRACT_VERSION` with value `tts-profile-emotion-v1`.
14+
- PASS: TTS Studio exports `createMessageStudioTtsProfileOptions`.
15+
- PASS: Exported profile options include stable keys, active state, display name, language, provider key, voice name, and active emotion settings.
16+
- PASS: Emotion settings include emotion key, display label, pitch, rate, volume, and SSML-like preset.
17+
- PASS: The output summary shows the contract version and Message Studio compatible profile options for local diagnostics.
18+
- PASS: Existing Message Studio dropdown smoke validation still passes.
19+
20+
## Boundaries
21+
22+
- PASS: No database changes were introduced.
23+
- PASS: No future provider behavior was hardcoded.
24+
- PASS: No browser-owned product data was introduced as source of truth.
25+
- PASS: Default profile data is limited to a local down-the-middle fallback until the API/data contract exists.
26+
- PASS: Existing Message Studio Local API profile shape remains untouched.
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# PR_26171_067 Parent Child Table Checklist
2+
3+
## Parent Table
4+
5+
- PASS: Parent table label is `TTS Profiles`.
6+
- PASS: Parent table lives in `toolbox/text-to-speech/`.
7+
- PASS: Parent table columns are Profile Name, Voice, Language, Gender, Age, Emotion Count, Status, Actions.
8+
- PASS: Default rows include `Default Balanced Profile`, `Man Profile 1`, and `Woman Profile 2`.
9+
- PASS: Parent row click opens or closes the child Emotion Settings row.
10+
- PASS: One selected profile row owns the visible child subtable at a time.
11+
- PASS: Parent profile count is visible in the summary stats.
12+
13+
## Parent Actions
14+
15+
- PASS: Add Profile opens a new inline row below the parent table rows.
16+
- PASS: Edit Profile opens an inline edit row for the selected profile.
17+
- PASS: Save Profile validates required Profile Name and Language values.
18+
- PASS: Duplicate Profile Name is blocked with a visible actionable error.
19+
- PASS: Cancel Profile closes the inline editor without applying changes.
20+
- PASS: Delete Profile removes unused profiles.
21+
- PASS: Delete Profile is disabled when the profile has Message Studio usage.
22+
23+
## Child Table
24+
25+
- PASS: Child table label is `Emotion Settings`.
26+
- PASS: Child table opens under the selected TTS Profile row.
27+
- PASS: Child columns are Emotion, Pitch, Rate, Volume, SSML-like Preset, Status, Actions.
28+
- PASS: Default neutral emotion is provided for every default profile.
29+
- PASS: Emotion count is visible in both the profile row and summary stats.
30+
31+
## Child Actions
32+
33+
- PASS: Add Emotion opens a new inline row in the child table.
34+
- PASS: Edit Emotion opens an inline edit row.
35+
- PASS: Save Emotion validates selected profile and unique emotion per profile.
36+
- PASS: Cancel Emotion closes the inline editor without applying changes.
37+
- PASS: Delete Emotion removes unused emotions.
38+
- PASS: Delete Emotion is disabled when the emotion has Message Parts usage.
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# PR_26171_067 TTS Profile Emotion Table Foundation
2+
3+
## Summary
4+
5+
TTS Studio now presents a parent TTS Profiles table with an expandable child Emotion Settings table. The active tool remains `toolbox/text-to-speech/`, uses Theme V2, and keeps all JavaScript external.
6+
7+
## Scope
8+
9+
- Updated `toolbox/text-to-speech/index.html` to expose the requested parent and child table surfaces.
10+
- Updated `toolbox/text-to-speech/text2speech.js` to seed reusable profiles, render child emotion settings, support inline add/edit rows, and block delete actions when profile or emotion usage is marked by Message Studio data.
11+
- Added a TTS profile contract helper that returns Message Studio compatible options without moving ownership into Message Studio.
12+
- Updated targeted TTS browser and unit validation.
13+
14+
## Requirement Evidence
15+
16+
- PASS: Active path remains `toolbox/text-to-speech/`.
17+
- PASS: Parent table is TTS Profiles.
18+
- PASS: Clicking a profile row opens the child Emotion Settings subtable.
19+
- PASS: Parent rows include `Man Profile 1` and `Woman Profile 2`.
20+
- PASS: Parent columns are Profile Name, Voice, Language, Gender, Age, Emotion Count, Status, Actions.
21+
- PASS: Child columns are Emotion, Pitch, Rate, Volume, SSML-like Preset, Status, Actions.
22+
- PASS: Add Profile opens an inline add row under the parent table.
23+
- PASS: Edit Profile opens an inline edit row.
24+
- PASS: Add Emotion opens an inline add row in the child table.
25+
- PASS: Edit Emotion opens an inline edit row.
26+
- PASS: Delete profile is disabled when usage count indicates Message Studio data uses it.
27+
- PASS: Delete emotion is disabled when usage count indicates Message Parts use it.
28+
- PASS: Default balanced profile and default neutral emotion are provided.
29+
- PASS: Message Studio compatible profile options are exported for a future API/data contract.
30+
- PASS: Message Studio and TTS Studio remain separate tools.
31+
- PASS: No database changes were made.
32+
- PASS: Theme V2 only; no page-local CSS, tool-local CSS, inline styles, style blocks, or inline handlers.
33+
34+
## Validation
35+
36+
- PASS: `node --check toolbox\text-to-speech\text2speech.js`.
37+
- PASS: `node --check tests\playwright\tools\TextToSpeechFunctional.spec.mjs`.
38+
- PASS: `node --check tests\tools\Text2SpeechShell.test.mjs`.
39+
- PASS: HTML inline style/script/event scan for `toolbox/text-to-speech/index.html`.
40+
- PASS: `node --test tests/tools/Text2SpeechShell.test.mjs`.
41+
- PASS: `npx playwright test tests/playwright/tools/TextToSpeechFunctional.spec.mjs --project=playwright --workers=1 --reporter=list`.
42+
- PASS: `npx playwright test tests/playwright/tools/MessagesTool.spec.mjs --project=playwright --workers=1 --reporter=list`.
43+
- PASS: `npm run test:workspace-v2` (legacy command name; user-facing language is Project Workspace).
44+
45+
## Out Of Scope
46+
47+
- No Message Studio merge.
48+
- No new provider behavior.
49+
- No generated audio export.
50+
- No database schema, seed, or persistence change.
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# PR_26171_067 Validation Report
2+
3+
## Commands Run
4+
5+
- `git branch --show-current`
6+
- PASS: started from `main`.
7+
- `git checkout main`
8+
- PASS.
9+
- `git pull origin main`
10+
- PASS: already up to date.
11+
- `git status --short`
12+
- PASS: clean before branch creation.
13+
- `node --check toolbox\text-to-speech\text2speech.js`
14+
- PASS.
15+
- `node --check tests\playwright\tools\TextToSpeechFunctional.spec.mjs`
16+
- PASS.
17+
- `node --check tests\tools\Text2SpeechShell.test.mjs`
18+
- PASS.
19+
- `Select-String -Path toolbox\text-to-speech\index.html -Pattern '<style|<script(?![^>]+src=)|\son\w+=|style='`
20+
- PASS: no matches.
21+
- `node --test tests/tools/Text2SpeechShell.test.mjs`
22+
- PASS: 4 tests passed.
23+
- `npx playwright test tests/playwright/tools/TextToSpeechFunctional.spec.mjs --project=playwright --workers=1 --reporter=list`
24+
- PASS: 2 tests passed.
25+
- Covers default profiles, expandable Emotion Settings, inline add/edit rows, delete-disabled usage states, and existing speech composition.
26+
- `npx playwright test tests/playwright/tools/MessagesTool.spec.mjs --project=playwright --workers=1 --reporter=list`
27+
- PASS: 2 tests passed.
28+
- Covers Message Studio smoke compatibility for the existing TTS dropdown and audio-engine path.
29+
- `npm run test:workspace-v2`
30+
- PASS: 5 Project Workspace tests passed.
31+
- Note: command name is legacy; user-facing language is Project Workspace.
32+
33+
## Coverage
34+
35+
- PASS: `docs_build/dev/reports/playwright_v8_coverage_report.txt` produced changed runtime JS coverage.
36+
- PASS: `toolbox/text-to-speech/text2speech.js` covered by targeted browser validation.
37+
- NOTE: The advisory coverage helper also listed the previous HEAD Message Studio files because it includes `git diff-tree HEAD` before this PR is committed. Those Message Studio files are unchanged in this PR and were separately smoke-checked with `MessagesTool.spec.mjs`.
38+
39+
## Skipped
40+
41+
- Database validation skipped because no database schema, seed, or persistence implementation changed.
42+
- Full samples validation skipped because no samples changed.
43+
- External TTS provider validation skipped because this PR does not implement provider behavior.

docs_build/dev/reports/codex_changed_files.txt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ Requirement PASS evidence:
2121
- PASS: Create Project sets Idea status to Project. Evidence: targeted Playwright asserts the row status becomes Project.
2222
- PASS: Project ideas and notes are read-only. Evidence: targeted Playwright asserts no Edit/Delete/Add Note/note actions remain for the Project row.
2323
- PASS: Project row actions are Open in Game Hub and Archive. Evidence: targeted Playwright asserts exact action labels.
24+
- PASS: Project ideas cannot be edited or deleted while Project. Evidence: Project rows do not render Edit/Delete actions and deletion guard remains active.
25+
- PASS: Project ideas cannot add/edit/delete notes. Evidence: expanded Project notes render without Add Note or note actions.
2426
- PASS: Archived ideas remain hidden by default and show Restore/Delete when visible. Evidence: targeted Playwright archives, shows Archived through the filter, and asserts Restore/Delete.
2527
- PASS: Game Hub shows creator-facing Project Information. Evidence: Game Hub HTML/JS replaces internal record display with Project Information and targeted Game Hub Playwright passes.
2628
- PASS: Game Hub shows read-only Source Idea fields. Evidence: Idea Board-to-Game Hub Playwright asserts Idea, Pitch, and Notes from the source idea render in Game Hub.
@@ -45,7 +47,8 @@ Validation evidence:
4547
Git workflow:
4648
- Current branch: codex/pr-26171-044-idea-board-game-hub-project-flow
4749
- Created branch: codex/pr-26171-044-idea-board-game-hub-project-flow
48-
- Push result: to be reported after push
49-
- PR URL: to be reported after PR creation
50+
- Commit hash: 2a38796f81aae2dceb4151095b8f89a276cd2d32
51+
- Push result: pushed to origin/codex/pr-26171-044-idea-board-game-hub-project-flow
52+
- PR URL: https://github.com/ToolboxAid/HTML-JavaScript-Gaming/pull/22
5053
- Merge result: to be reported after merge
5154
- Final main commit: to be reported after returning to main and pulling latest

docs_build/dev/reports/coverage_changed_js_guardrail.txt

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,10 @@ Missing changed runtime JS files are WARN, not FAIL.
66
Source: Playwright/Chromium built-in V8 coverage from the active Playwright run.
77

88
Changed runtime JS files considered:
9-
(64%) assets/theme-v2/js/tool-display-mode.js - executed lines 204/204; executed functions 9/14
10-
(87%) toolbox/messages/messages.js - executed lines 1233/1233; executed functions 103/118
11-
(100%) toolbox/messages/message-tts-service-registry.js - executed lines 42/42; executed functions 6/6
9+
(0%) toolbox/messages/message-tts-service-registry.js - WARNING: changed runtime JS file was not collected by Playwright V8 coverage; advisory only
10+
(0%) toolbox/messages/messages.js - WARNING: changed runtime JS file was not collected by Playwright V8 coverage; advisory only
11+
(80%) toolbox/text-to-speech/text2speech.js - executed lines 1518/1518; executed functions 127/158
1212

1313
Guardrail warnings:
14-
(100%) none - no changed runtime JS coverage warnings
14+
(0%) toolbox/messages/message-tts-service-registry.js - WARNING: changed runtime JS file missing from coverage; advisory only
15+
(0%) toolbox/messages/messages.js - WARNING: changed runtime JS file missing from coverage; advisory only

docs_build/dev/reports/playwright_v8_coverage_report.txt

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -12,34 +12,33 @@ Note: entry percentages use function coverage when available, otherwise line cov
1212
Note: coverage entries are aggregated across every page/tool where coverageReporter.start(page) and coverageReporter.stop(page) ran.
1313

1414
Exercised tool entry points detected:
15-
(83%) Toolbox Index - exercised 4 runtime JS files
15+
(80%) Toolbox Index - exercised 2 runtime JS files
1616
(0%) Tool Template V2 - not exercised by this Playwright run
1717
(56%) Theme V2 Shared JS - exercised 2 runtime JS files
1818

1919
Changed runtime JS files covered:
20-
(64%) assets/theme-v2/js/tool-display-mode.js - executed lines 204/204; executed functions 9/14
21-
(87%) toolbox/messages/messages.js - executed lines 1233/1233; executed functions 103/118
22-
(100%) toolbox/messages/message-tts-service-registry.js - executed lines 42/42; executed functions 6/6
20+
(0%) toolbox/messages/message-tts-service-registry.js - WARNING: changed runtime JS file was not collected by Playwright V8 coverage; advisory only
21+
(0%) toolbox/messages/messages.js - WARNING: changed runtime JS file was not collected by Playwright V8 coverage; advisory only
22+
(80%) toolbox/text-to-speech/text2speech.js - executed lines 1518/1518; executed functions 127/158
2323

2424
Files with executed line/function counts where available:
25-
(34%) src/engine/audio/TextToSpeechEngine.js - executed lines 412/412; executed functions 15/44
2625
(36%) src/api/server-api-client.js - executed lines 167/167; executed functions 5/14
2726
(38%) src/api/public-config-client.js - executed lines 209/209; executed functions 10/26
2827
(54%) assets/theme-v2/js/gamefoundry-partials.js - executed lines 977/977; executed functions 46/85
29-
(58%) toolbox/messages/messages-api-client.js - executed lines 64/64; executed functions 11/19
3028
(64%) assets/theme-v2/js/tool-display-mode.js - executed lines 204/204; executed functions 9/14
29+
(71%) src/engine/audio/TextToSpeechEngine.js - executed lines 412/412; executed functions 37/52
3130
(76%) toolbox/tool-registry-api-client.js - executed lines 155/155; executed functions 22/29
32-
(87%) toolbox/messages/messages.js - executed lines 1233/1233; executed functions 103/118
31+
(80%) toolbox/text-to-speech/text2speech.js - executed lines 1518/1518; executed functions 127/158
3332
(100%) src/engine/audio/TextToSpeechDefaults.js - executed lines 108/108; executed functions 1/1
34-
(100%) toolbox/messages/message-tts-service-registry.js - executed lines 42/42; executed functions 6/6
3533

3634
Uncovered or low-coverage changed JS files:
37-
(100%) none - no low-coverage changed runtime JS files
35+
(0%) toolbox/messages/message-tts-service-registry.js - WARNING: uncovered changed runtime JS file; advisory only
36+
(0%) toolbox/messages/messages.js - WARNING: uncovered changed runtime JS file; advisory only
3837

3938
Changed JS files considered:
40-
(0%) tests/playwright/tools/IdeaBoardTableNotes.spec.mjs - changed JS file not collected as browser runtime coverage
4139
(0%) tests/playwright/tools/MessagesTool.spec.mjs - changed JS file not collected as browser runtime coverage
42-
(0%) tests/playwright/tools/ToolboxRoutePages.spec.mjs - changed JS file not collected as browser runtime coverage
43-
(64%) assets/theme-v2/js/tool-display-mode.js - changed JS file with browser V8 coverage
44-
(87%) toolbox/messages/messages.js - changed JS file with browser V8 coverage
45-
(100%) toolbox/messages/message-tts-service-registry.js - changed JS file with browser V8 coverage
40+
(0%) tests/playwright/tools/TextToSpeechFunctional.spec.mjs - changed JS file not collected as browser runtime coverage
41+
(0%) tests/tools/Text2SpeechShell.test.mjs - changed JS file not collected as browser runtime coverage
42+
(0%) toolbox/messages/message-tts-service-registry.js - changed JS file not collected as browser runtime coverage
43+
(0%) toolbox/messages/messages.js - changed JS file not collected as browser runtime coverage
44+
(80%) toolbox/text-to-speech/text2speech.js - changed JS file with browser V8 coverage

0 commit comments

Comments
 (0)