Skip to content

Commit 7a2c464

Browse files
V29 Gate 9: Terminal UX Quality And Browser Proof
Closes Gate 9 by proving the Terminal cockpit UX with source-safe landmarks, state semantics, responsive Playwright coverage, and maintained gate-quality automation.
1 parent f059a0d commit 7a2c464

22 files changed

Lines changed: 951 additions & 34 deletions

.github/workflows/bitcode-gate-quality.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ jobs:
7070
node scripts/check-v29-gate6-settlement-reconciliation-repair.mjs --skip-branch-check
7171
node scripts/check-v29-gate7-organization-permission-authority.mjs --skip-branch-check
7272
node scripts/check-v29-gate8-demonstration-origin-formalization.mjs --skip-branch-check
73+
node scripts/check-v29-gate9-terminal-ux-browser-proof.mjs --skip-branch-check
7374
7475
- name: Validate source casing and imports
7576
run: |
@@ -116,9 +117,16 @@ jobs:
116117
tests/protocolCommercialBoundary.test.ts \
117118
tests/terminalTransactionDetailCards.test.tsx \
118119
tests/terminalTransactionDetailSnapshot.test.ts \
120+
tests/terminalUxBrowserProof.test.tsx \
119121
tests/pipelineExecutionLogHeader.test.tsx \
120122
--runInBand
121123
124+
- name: Install Terminal browser proof browser
125+
run: pnpm --dir uapi exec playwright install chromium --with-deps
126+
127+
- name: Browser proof Terminal cockpit
128+
run: pnpm --dir uapi run test:e2e:terminal-ux
129+
122130
- name: Test pipeline readback verifier
123131
run: pnpm test:qa:v28:pipeline-readback
124132

BITCODE_SPEC_V29.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,29 @@ The Terminal transaction read model must contain:
223223
The model is deterministic from execution history, detail readback, route query state, and data mode.
224224
It must tolerate partial live readback by preserving a fallback selected-run projection while naming empty or blocked sections.
225225

226+
## V29 Terminal UX quality and browser-proof canon
227+
228+
The Terminal transaction cockpit is a protocol-facing operator interface.
229+
It must be readable by default, keyboard reachable, responsive, and browser-proven.
230+
231+
The cockpit must expose:
232+
233+
- one named `main` landmark for the Terminal route;
234+
- a keyboard-reachable skip link to the selected transaction workspace;
235+
- a named transaction workspace region for activity selection, filtering, and selected-result digest;
236+
- a named selected activity detail region for the low-detail detail hero, route-owned section controls, and source-safe detail surfaces;
237+
- explicit loading, empty, failed, blocked, and source-safe preview states with `status` or `alert` semantics where appropriate;
238+
- contained table overflow so phone and tablet viewports do not acquire document-level horizontal overflow;
239+
- route-owned detail controls whose current, available, empty, and blocked states are understandable before raw payload expansion.
240+
241+
The browser-proof contract is package-local to Terminal and exported by `uapi/app/terminal/terminal-ux-browser-proof.ts`.
242+
It identifies the required landmarks, viewports, state semantics, route checks, and evidence files.
243+
The focused Jest test proves the contract and state semantics.
244+
The focused Playwright spec proves the cockpit in a real browser in deterministic mock mode across key route and responsive states.
245+
246+
Gate 9 acceptance does not change Reading law, source disclosure law, settlement law, or organization authority law.
247+
It makes the current V29 Terminal cockpit commercially operable enough that later local/staging promotion readiness can debug failures from the UI rather than from browser network logs alone.
248+
226249
## V29 Wallet/BTC operation canon
227250

228251
Wallet and BTC fee state is an ordinary Terminal transaction surface, not an opaque settlement footnote.

BITCODE_SPEC_V29_DELTA.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,16 @@ Closure acceptance:
183183

184184
Gate 9 owns accessibility, responsive layout, copy/prose clarity, empty/loading/blocked/failed states, Playwright coverage, and visual/browser verification for the complete Terminal transaction cockpit.
185185

186+
Closure acceptance:
187+
188+
- Terminal exposes one named cockpit `main` landmark, a keyboard-reachable skip link to the selected transaction workspace, named regions for the transaction workspace and selected activity detail, and accessible controls for route-owned detail sections.
189+
- The default operator path remains low-detail: activity summary, selected result digest, section availability, blockers, and source-safe preview metadata are readable before raw payload expansion.
190+
- Loading, empty, failed, blocked, and source-safe preview states are represented by typed UI states with `status` or `alert` semantics where appropriate, not only by browser-network inspection.
191+
- The complete cockpit is responsive across phone, tablet, laptop, and widescreen viewports without document-level horizontal overflow; table overflow remains contained inside the table scroller.
192+
- Browser proof is executable through a focused Playwright spec that opens Terminal in deterministic mock mode, verifies landmarks, skip navigation, blocked Console posture, source-safe detail, route-owned selection, and responsive readability.
193+
- Focused Jest coverage proves the UI state contract and the exported browser-proof contract that CI and documentation name.
194+
- `check:v29-gate9` fails closed unless V29 specification, Terminal README, Terminal UX contract, Jest tests, Playwright spec, package scripts, and gate-quality workflow all name the Gate 9 browser-proof surface.
195+
186196
### Gate 10: Local And Staging Promotion Readiness
187197

188198
Gate 10 owns non-mocked local validation, staging-testnet readback, generated proof artifacts, V29 promotion workflow support, promotion dry-run, and final version branch readiness.

BITCODE_SPEC_V29_NOTES.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ For a simplified reading of V29:
7676

7777
9. **Gate 9: Terminal UX Quality And Browser Proof**
7878
- Close accessibility, responsive, copy, loading/empty/error/blocked states, browser checks, and Playwright coverage for the complete Terminal cockpit.
79+
- Acceptance detail: the Terminal page exposes a named cockpit `main`, skip navigation into the selected transaction workspace, named workspace/detail regions, source-safe low-detail defaults, explicit state semantics, and deterministic Playwright coverage for landmarks, blocked Console posture, route-owned selection, and phone/tablet/laptop/widescreen readability.
7980

8081
10. **Gate 10: Local And Staging Promotion Readiness**
8182
- Run non-mocked local validation, staging-testnet readback, generated proof artifacts, promotion dry-run, and `version/v29` promotion readiness.
@@ -209,6 +210,34 @@ Gate 8 completion condition:
209210
- Protocol package tests pass.
210211
- The spec family, package README, root scripts, and CI all name and enforce the package-native boundary.
211212

213+
## Gate 9 working notes
214+
215+
Gate 9 closes the Terminal cockpit quality slice.
216+
It treats UX quality as protocol evidence: operators must be able to read the transaction state, section availability, source-safe preview posture, blocked actions, and activity stream without relying on browser network logs.
217+
218+
Accepted surfaces:
219+
220+
- `uapi/app/terminal/terminal-ux-browser-proof.ts` records the browser-proof contract: required landmarks, state semantics, viewports, route checks, and evidence files.
221+
- `TerminalPageClient.tsx` owns the named cockpit `main` landmark and skip link.
222+
- `TerminalTransactionWorkspace.tsx` owns the named transaction workspace region, loading/empty/error semantics, and selected result status.
223+
- `TerminalTransactionDetailSurface.tsx`, `TerminalTransactionDetailHero.tsx`, and `TerminalTransactionDetailActionBar.tsx` own the selected activity detail region, low-detail source-safe header, section controls, blocked Console posture, and action errors.
224+
- `BitcodeTransactionsTable.tsx` and `BitcodeTransactionsDataTable.tsx` keep transaction table overflow contained while exposing loading, empty, error, and selectable-row states to tests and assistive technology.
225+
- `uapi/tests/terminalUxBrowserProof.test.tsx` proves the typed state contract.
226+
- `uapi/tests/e2e/commercial-mvp.terminal-ux.spec.ts` proves the cockpit in a real browser in deterministic mock mode.
227+
228+
Gate 9 accepted boundaries:
229+
230+
- Gate 9 does not redesign the five-step Reading product flow; it makes the current transaction cockpit accessible and provable.
231+
- Gate 9 does not reveal protected AssetPack source before settlement.
232+
- Gate 9 does not add versioned routes, gate-named runtime routes, or work-in-progress source identifiers.
233+
- Gate 9 does not require live staging credentials; Gate 10 owns non-mocked local/staging promotion readiness.
234+
235+
Gate 9 completion condition:
236+
237+
- `pnpm run check:v29-gate9` passes.
238+
- Focused UAPI Jest coverage and Terminal Playwright browser proof pass locally.
239+
- Gate-quality CI invokes the Gate 9 checker, focused Jest test, and focused Playwright browser proof.
240+
212241
## Later-version boundaries
213242

214243
- V30 remains reserved for Protocol/BTD hardening that is not necessary to close Terminal transaction depth.

BITCODE_SPEC_V29_PARITY_MATRIX.md

Lines changed: 30 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ No `_legacy/` source is active source truth.
5656
| Settlement reconciliation repair | Gate 6 | BTD journal/reconciliation, Supabase readback, sandbox harness settlement evidence, Terminal repair UI, Gate 6 checker | drafted | Ledger, database, and metaphysical state drift is classified, proof-rooted, repair-actioned, and visible. |
5757
| Organization permission authority | Gate 7 | `packages/btd/src/authority.ts`, BTD/API/MCP/ChatGPT App tests, sandbox harness authority evidence, Terminal Authority section, Gate 7 checker | drafted | Registry-derived roles, holdings, read-license authority, settlement, confirmation, and interface admission govern actions. |
5858
| Commercial formalization | Gate 8 | `packages/protocol/src/index.js`, `packages/protocol/src/canon-posture.js`, root scripts, protocol package tests, import scans, docs, Gate 8 checker | drafted | Demonstration-origin commercial internals are package-native and no direct demonstration-source imports remain in commercial/runtime sources. |
59-
| Terminal UX quality | Gate 9 | Playwright/Jest/a11y/responsive/browser QA | pending | Complete transaction cockpit is usable by default and inspectable in detail. |
59+
| Terminal UX quality | Gate 9 | Terminal UX contract, Playwright/Jest/a11y/responsive/browser QA | drafted | Complete transaction cockpit is usable by default and inspectable in detail. |
6060
| Promotion readiness | Gate 10 | promotion workflow, `.bitcode/v29-*`, `BITCODE_SPEC_V29_PROVEN.md` | pending | `version/v29` can promote to `main` only after all V29 checks pass. |
6161

6262
## V29 implementation checklist
@@ -73,7 +73,7 @@ No `_legacy/` source is active source truth.
7373
| Gate 5 AssetPack disclosure | `pnpm run check:v29-gate5` proves source-safe disclosure review, leakage detection, Terminal preview rendering, and PR title enforcement | drafted |
7474
| Gate 7 organization authority | `pnpm run check:v29-gate7` proves shared org/interface authority across BTD, API, MCP, ChatGPT App, harness, and Terminal | drafted |
7575
| Gate 8 commercial formalization | `pnpm run check:v29-gate8` proves package-native protocol exports, V28/V29 posture, script import cleanup, docs, tests, and CI wiring | drafted |
76-
| Product implementation gates | Gate 9 closes remaining Terminal transaction UX quality with browser proof | pending |
76+
| Gate 9 Terminal UX browser proof | `pnpm run check:v29-gate9` proves named landmarks, explicit state semantics, responsive browser coverage, focused Jest coverage, and CI wiring | drafted |
7777
| Promotion gate | Gate 10 closes generated proof and promotion automation | pending |
7878

7979
## Gate 1 Parity
@@ -272,3 +272,31 @@ Gate 8 completion condition:
272272
- Focused protocol package typecheck/test and the UAPI commercial protocol boundary test pass.
273273
- V29 SPEC, DELTA, NOTES, PARITY, protocol package README, package scripts, and gate-quality workflow name the formalized package-native boundary.
274274
- Root scripts use protocol package exports for canonical helpers and do not directly import `protocol-demonstration/src/*`.
275+
276+
## Gate 9 Parity
277+
278+
Gate 9 closes the Terminal UX quality and browser-proof slice by making the transaction cockpit readable, keyboard reachable, responsive, and test-proven.
279+
280+
Accepted surfaces:
281+
282+
- `uapi/app/terminal/terminal-ux-browser-proof.ts` exports the typed contract for Gate 9 landmarks, viewports, states, route checks, and evidence files.
283+
- `TerminalPageClient.tsx` exposes a named `main` cockpit region and skip link to the selected transaction workspace.
284+
- `TerminalTransactionWorkspace.tsx` exposes a named transaction workspace region, selected activity status, and explicit loading, empty, and error states.
285+
- `TerminalTransactionDetailSurface.tsx`, `TerminalTransactionDetailHero.tsx`, and `TerminalTransactionDetailActionBar.tsx` expose a named selected activity detail region, source-safe low-detail detail hero, route-owned section controls, blocked Console posture, and action error alerts.
286+
- `BitcodeTransactionsTable.tsx` and `BitcodeTransactionsDataTable.tsx` expose table state semantics while containing table overflow inside the table scroller.
287+
- `uapi/tests/terminalUxBrowserProof.test.tsx` proves the contract and UI state semantics.
288+
- `uapi/tests/e2e/commercial-mvp.terminal-ux.spec.ts` proves the cockpit through a real browser in deterministic mock mode.
289+
- `.github/workflows/bitcode-gate-quality.yml` runs the Gate 9 checker, focused Jest test, Playwright browser install, and focused Terminal browser proof.
290+
291+
Accepted boundaries:
292+
293+
- Gate 9 does not redesign Reading into a different flow.
294+
- Gate 9 does not reveal protected AssetPack source before settlement.
295+
- Gate 9 does not add versioned API routes or gate/work-in-progress runtime identifiers.
296+
- Gate 9 does not perform non-mocked staging promotion readiness; Gate 10 owns that slice.
297+
298+
Gate 9 completion condition:
299+
300+
- `pnpm run check:v29-gate9` passes.
301+
- Focused UAPI Jest coverage and Playwright Terminal browser proof pass.
302+
- V29 SPEC, DELTA, NOTES, PARITY, Terminal README, package scripts, and gate-quality workflow name the browser-proof contract.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252
"check:v29-gate6": "node scripts/check-v29-gate6-settlement-reconciliation-repair.mjs",
5353
"check:v29-gate7": "node scripts/check-v29-gate7-organization-permission-authority.mjs",
5454
"check:v29-gate8": "node scripts/check-v29-gate8-demonstration-origin-formalization.mjs",
55+
"check:v29-gate9": "node scripts/check-v29-gate9-terminal-ux-browser-proof.mjs",
5556
"check:spec-quality": "node scripts/run-bitcode-spec-quality.mjs --mode basic",
5657
"check:spec-quality:title": "node scripts/run-bitcode-spec-quality.mjs --mode strict-from-title",
5758
"check:spec-quality:v24": "node scripts/run-bitcode-spec-quality.mjs --mode strict-version --version V24",

0 commit comments

Comments
 (0)