Skip to content

specs/ui: the site viewport contract as a .t27 spec (tiers, panes, 44px targets, six-size QA matrix) - #3558

Merged
gHashTag merged 2 commits into
masterfrom
feat/viewport-spec
Sep 10, 2026
Merged

specs/ui: the site viewport contract as a .t27 spec (tiers, panes, 44px targets, six-size QA matrix)#3558
gHashTag merged 2 commits into
masterfrom
feat/viewport-spec

Conversation

@gHashTag

@gHashTag gHashTag commented Sep 9, 2026

Copy link
Copy Markdown
Owner

Closes #3557

What

specs/ui/viewport.t27 (module ui_viewport, KIND = "viewport") — the one source for how the explorers of t27.ai lay themselves out at a given viewport, plus specs/ui/README.md, an OWNERS.md row (ui/ → T-Queen) and a docs/now entry.

Constant Value Why
PHONE_MAX / TABLET_MAX / DESKTOP_MAX 600 / 1024 / 1600 inclusive upper bounds of phone / tablet / desktop; above is wide
HEADER_CHROME_MAX 1100 the threshold the explorers' TSX already used for trimming the header; kept inside the desktop tier so 1025–1099 renders as before. Not a tier
PHONE_PANES / TABLET_PANES / DESKTOP_PANES 1 / 2 / 2 phone = list or card (master-detail), a ?<key>= deep link opens the card
ONE_SCROLLER_PER_PANE, DOCUMENT_SCROLLS true, false one vertical scroller per visible pane, the document never scrolls
TOUCH_TARGET_MIN_PX, BACK_CONTROL_MIN_PX 44, 44 WCAG 2.5.5
VIEWPORTS 390x844 600x900 768x1024 1024x768 1280x800 1920x1080 the QA matrix, with VIEWPORT_TIERS per entry and DESKTOP_REFERENCE_WIDTH = 1280
RAIL_* from Queen.css with file:line the Queen rail capacity per matrix height — described, not changed (P0 = explorers only)

Witnesses

  • SOURCE comment in the file — live t27.ai, 2026-09-09, cloud Chromium, DPR 1: at 390x844 #/tools?tool=mcp%2Fgitbutler shows only the 62-item list, the deep-linked card is not in the viewport, document scrollHeight 924 > 844; reproduced on a build of trinity main c881e7f (the hash written after mount is ignored). Rail numbers: Queen.css:5311-5312 (44px tile), :5302 (gap 4), :3997-3998 (48px rows), :3868 (gap 6), :4277 + :4397 (chrome 64 + 84); tile height 74 and rail clientWidth 344 measured at 390x844.
  • Compiler (vendored t27_compiler.wasm on the site): typecheck ok, nothing discarded, module ui_viewport; 6 test blocks, 49 asserts, 49/49 hold when evaluated from the AST by the site generator (typecheck.ok alone stays true for assert 1 > 2 — the generator's own test proves the false-assert case is refused).
  • sha256 of the spec: 91c9235486599fdd18a188c4e191dd6ff7a591a13b01625e766fc70403dd43a4; the copy in trinity apps/website/public/t27/files/specs/ui/viewport.t27 is byte-identical (cmp), and both generated files carry this sha in their header.
  • ASCII only, English only (checked with grep -P '[^\x00-\x7F]' → 0 hits in the .t27, the README and the docs/now entry); no absolute home path; the checkout is T27_ROOT or git rev-parse --show-toplevel.

spec-guards

The first run of spec-guards on this PR failed on "Published figures": the pinned test blocks population (tools/published_figures.py) was 12456 and the corpus re-derived to 12462 — exactly the six test blocks this spec adds. Per the file's own protocol ("the pin FOLLOWED the corpus, and the movement is explained"), commit b63c3df6 moves the pin to 12462 with the reason written next to it; the other nine figures are unchanged, --check exits 0 and --self-check passes locally. This is not a ratchet raise: the figure is a population count that must track the corpus.

Boundaries

  • Only specs/ui/, specs/OWNERS.md, one docs/now file and the test blocks pin in tools/published_figures.py are touched; no other spec changes.
  • The bootstrap compiler on master was not run against this file.
  • Inside a test block only // comments are safe (the parser reads a ; line inside a block as a statement) — recorded in the README.
  • No i18n SCOPE row: the spec carries no user-visible text.
  • The rail capacity is a model (a CSS budget plus one consistent observation at 1024x768), not a measurement of every height.
  • Known pre-existing reds on master (gate-topology, untrusted-input) are not addressed.

Consumer

trinity feat/viewport-p0: scripts/viewport-from-spec.mjssrc/lib/viewport.generated.ts + src/styles/viewport.generated.css, useViewport(), master-detail phone tier in the five explorers, qa/explorer-viewport-contract.mjs over the matrix (link in the trinity PR).

Do not merge without the owner's approval.

…px targets, six-size QA matrix, rail capacity)

- specs/ui/viewport.t27 (module ui_viewport, KIND viewport): PHONE_MAX 600,
  TABLET_MAX 1024, DESKTOP_MAX 1600, HEADER_CHROME_MAX 1100, one pane on a
  phone, 44 px touch targets, the six-size matrix with tiers, the Queen rail
  capacity read from Queen.css (described, not changed).
- Six test blocks / 49 asserts inside the spec; the site generator evaluates
  them because typecheck.ok stays true for a false assert.
- specs/ui/README.md, OWNERS row ui/ -> T-Queen, docs/now entry.

Closes #3557
@github-actions

github-actions Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

📓 NotebookLM Notebook linked to this PR

This notebook contains session context, decisions, and artifacts for this work.

@github-actions

github-actions Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-09-09 20:49:54 UTC

Summary

Status Count
Total Open PRs 17
PRs with Failing Checks 14
PRs with All Checks Green 3
READY 2
FAILING 14
PENDING 0
NO CHECKS YET 0

These columns do not partition: 2 + 14 + 0 + 0 = 16, and there are 17 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=d4c5b22b471e != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

…st blocks of specs/ui/viewport.t27)

spec-guards on #3558 reported the drift; the movement is the six test
blocks this branch adds, written next to the pin. --check exits 0.

Refs #3557
@github-actions

github-actions Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-09-09 21:02:21 UTC

Summary

Status Count
Total Open PRs 17
PRs with Failing Checks 15
PRs with All Checks Green 2
READY 2
FAILING 15
PENDING 0
NO CHECKS YET 0

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=d4c5b22b471e != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@github-actions

github-actions Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

📓 NotebookLM Notebook linked to this PR

This notebook contains session context, decisions, and artifacts for this work.

@gHashTag
gHashTag merged commit 4a740c7 into master Sep 10, 2026
30 of 32 checks passed
@gHashTag
gHashTag deleted the feat/viewport-spec branch September 10, 2026 00:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

specs/ui/viewport.t27: one viewport contract for the site's explorers (breakpoints, touch targets, QA matrix)

1 participant