diff --git a/docs/reports/experience-refinement-20261026/README.md b/docs/reports/experience-refinement-20261026/README.md new file mode 100644 index 000000000..b7fdb66e3 --- /dev/null +++ b/docs/reports/experience-refinement-20261026/README.md @@ -0,0 +1,72 @@ +# Reader experience refinement, 26 October 2026 + +The Go to disclosure keeps nine existing destinations reachable during long +reading sessions on all eleven current reader pages. Native links work without +JavaScript; Formal stays script-free. Optional dismissal preserves normal outside +focus. The launcher yields while another element has visible keyboard focus; +it remains in tab order and returns when its summary receives focus. This also +works without JavaScript. Compare now has synchronized upper/lower page controls and verifies its +separate source inventory on demand, avoiding one duplicate initial payload +transfer while preserving both independent validators and all source refusals. + +The original mobile audit measured Library11275px and Compare9498px tall, with no +visible task navigation at scroll3000. Compare's original pager was5879px below +the first result. Browser baseline0/5 lacked Go to; Compare's three baseline +conditions failed (top pager absent, two initial current payload transfers, eager +inventory). Native navigation now passes6 cases; Compare11 focused and12 existing +browser checks passed in four desktop/phone themes, including final-page controls, +refusal/retry, delayed source acquisition and newer outside focus. + +Required local checks passed after a narrow compatibility repair: the existing +Research script allowlist rejected the new same-origin reader-jump module. Only +that exact name was added to its anchored/path whitelist; two negative-boundary +tests preserve rejection of arbitrary, remote, inline and duplicate scripts. +Original75/77 plus two failures remain recorded; the corrected79/79 run passed. +The remaining original public-shop groups, focused Node26/26 and118 browser cases +(navigation6, Library16, desk13, Undo80, Cite3) passed with zero page errors. +Two expected standalone museum skips passed with their prescribed fixture. + +The first browser attempts executed no cases because a deeply nested test TMPDIR +exceeded Chromium's Unix-socket path limit. A fresh short /tmp task directory fixed +the runner; the same product/browser/sandbox then executed all118 cases. No browser +policy was weakened. Compare's old driver also needed an explicit function wait +predicate instead of its CSP-unsafe expression; the original failure is retained. +All original logs and diagnostic failures stay in the private delivery evidence. + +Exact53-open-PR/1121-path inventory found only derived URL-key overlaps with399, +501 and644; no semantic hunk or657 documentation overlap.210 protected source, +snapshot, public-math, payload, registry, loader/model and generator members were +unchanged. SOURCE.json binds the tested working bytes at authored baseline8a7c59a1; +later composition, native review and deployment have their own receipts. + +A separate local v24 dashboard repair is delivered from its own repository and +package, not as a Main commit or a public worker integration. Its original +104-record namespace remains separate from this website's49. Its real loopback +planner GET/SSE check showed zero claims/completions/certificates and no journal +mutation after initialization. It is a planner snapshot view, not worker execution. + +Engineering only, actual OpenAI/Codex same GPT-6 family, organizational-independence +credit0 and scientific effect NONE. No statements, dependencies, source admission, +classifications or mathematical certification changed. Emulated Chromium checks +do not establish physical Safari/touch, spoken AT, full WCAG or large-graph FPS. + +The first hosted run and whole-branch review exposed ER-I1: the fixed launcher +covered the evidence table focus ring at320px with text spacing. A controlled +reviewer comparison measured65.6% coverage with it present and100% with it hidden. +The CSS focus-yield repair passed ten navigation cases (including Tab/Shift+Tab, +no-JS Formal, input focus and blur restoration), the exact original painted-ring +case at100%, thirty existing focus targets and twenty text-layout cases. No +pixel threshold was relaxed. Original AMEND review and failures are retained. +See focus-amendment.json and the previous SOURCE-before-focus.json receipt. +The initial full-suite qualification remains scoped to its original bytes; later +checks are separately bound rather than retroactively changing that evidence. + +A final test-tool amendment repairs an ineffective HTTPS URL glob in the navigation +driver. The selected site is admitted through the matching guard; offsite HTTPS +requests are refused. Actual browser fixtures first reproduced an external probe +escaping the old guard, then passed ten navigation cases,451 local-fixture HTTPS +requests and seven blocked offsite probes. Loopback replay also passed10/10. +These are synthetic origin fixtures, not deployed-byte/TLS/source-authentication +evidence. The initial own-origin-block diagnosis was disproved and corrected; +initial import/tunnel fixture setup failures remain preserved. Product bytes and +all scientific gates are unchanged. See origin-guard-amendment.json. diff --git a/docs/reports/experience-refinement-20261026/SOURCE-before-focus.json b/docs/reports/experience-refinement-20261026/SOURCE-before-focus.json new file mode 100644 index 000000000..031962868 --- /dev/null +++ b/docs/reports/experience-refinement-20261026/SOURCE-before-focus.json @@ -0,0 +1,25 @@ +{ + "authored_base": "8a7c59a1f99f43622aa5135e90f2dafb814d2c19", + "execution": "Working-tree bytes before source commit; actual execution bound by these SHA-256s, not a future Git commit.", + "source_sha256": { + "docs/site/index.html": "dc8fd4cb12d2ebbdd5602e6399d84b0696aea17484feb5a4f054bb49d98ebf66", + "docs/site/explore.html": "89381433e40ae5a09557dd3be4b4e84f07f4a54b45f79664bbdd2035d9270341", + "docs/site/research.html": "8d723716743f5e8886d0b335bd43ee53adef9c2fe4f76a360188d734cd05ab01", + "docs/site/workspace.html": "24415a778c77b0569cfa0867216b9ddd5781335aa928502386438fa0bdb335f1", + "docs/site/compare.html": "8a14095d5667d76171adae15861a5c3001aaf193aac07ad63d74e86c344d96a5", + "docs/site/cite.html": "83f8f7ff36d3361bf53d376f70e9b2c27f3fc0b497100550760f71b483ff86f9", + "docs/site/reproduce.html": "344e544c5a29d95ab3d5c5f34d9a169a15ce80eab573ef2601ef0be3c85c82c2", + "docs/site/dependencies.html": "adfb24760b07dc68859d7d38a34c8eb9863280f27fca14bfbe2c3e3664db159a", + "docs/site/measure.html": "20807835f5240726b8acccd476f046b13b8dbda456c730def0fa2d7ced953e21", + "docs/site/museum.html": "12ed1246c8daca162aa619b5fb3800d7ff73338ba07c9dbcdbfabd0e2ff1ed99", + "docs/site/formal.html": "a49cd8bb2ffcbb514cf8d77ca150d0f2b7e8822d786b2e3af8896a7ffe22da94", + "docs/site/reader-jump.css": "d5bffeb195aa71f99763237fe647143fb0143faa2c310b346d790ae022815fc2", + "docs/site/reader-jump.mjs": "103fe02d6ecdefe2d3017a9de7e56fe78a85992e6816c42e226c48ae79a38f30", + "docs/site/compare.mjs": "581a618d7feac9fafc02cc0e9da89aeb92f8eb99d00f1899b922a813b87c43ce", + "docs/site/compare.css": "8ac956c88c829c902a252aec94154ecd010a599f8abc2c29f4dec21fbdf849f3", + "docs/site/compare-source-panel.mjs": "6436b2c6651dfea4ec1dfd6612028ddbcd341ce6d662794a73b0625c37d96b3f", + "tests/test_reader_links.py": "726d487e49c9dbb5968666af0dabf09b2a83f8bba60832782bfd9e4d6e1a14bc" + }, + "release": "a7a202880f103f04e8685236c1770a846e31a9909064fd6b3cbd60377dce984d", + "scientific_effect": "NONE" +} diff --git a/docs/reports/experience-refinement-20261026/SOURCE.json b/docs/reports/experience-refinement-20261026/SOURCE.json new file mode 100644 index 000000000..fd9807f4f --- /dev/null +++ b/docs/reports/experience-refinement-20261026/SOURCE.json @@ -0,0 +1,27 @@ +{ + "authored_base": "8a7c59a1f99f43622aa5135e90f2dafb814d2c19", + "execution": "Product focus amendment tested on working bytes at b145; final two-line test-origin guard amendment tested as working bytes on f24a48af0fb68747c8cea37ba441ba0dbf4631c9. SHA-256s bind exact consumed files, not future commit execution.", + "source_sha256": { + "docs/site/index.html": "e9074f87a018e9b95065493b84224c23e436c8c56e8de008e901e906e22826b1", + "docs/site/explore.html": "b08a9de5a3112a203f3f32a77ce7676f0069d24f846c21b95e74ef67a7961d8e", + "docs/site/research.html": "d36072d6aecfc8606426b23b3ba41b808226a91bac02b333fa49232d8cb1fb02", + "docs/site/workspace.html": "360193a92faa12dec1ce84dc702529b4e2d8d78fbf988877cbdc23733bc98c86", + "docs/site/compare.html": "4b59f99dce19a399c7ff93796cda400d314bde0c8a08d8cde20b3a3f13b35824", + "docs/site/cite.html": "df624ee7d1db2fa09d891f90641b6cf0a5265eeaea93d4f71d42df3cc24cd2b3", + "docs/site/reproduce.html": "4d9a3210ba02d80119b1c919a09a5f850255d24ba2fe6028c7255b1b3858da54", + "docs/site/dependencies.html": "c1c982e3c481554d8b476ce0e733f96bec4f46c930adc644a0d629ba0cbb56e3", + "docs/site/measure.html": "56c960fa6a6761dd3f9989863d8eb5e5aa61fa000ca785333204a24c66150a4f", + "docs/site/museum.html": "f7a7d7134c7a9cace2bfc5f238f9119b9a19e78883ddeffc25cf8bf2a9dce27a", + "docs/site/formal.html": "9b0460ff4ce4744f91266d3a9bacace7a120124febbda7eabb10cec2604beaaa", + "docs/site/reader-jump.css": "23b581f4265d2e37f5b8008b4ce66c2b70d8b278e07d2e36bd2856ad69c87fb0", + "docs/site/reader-jump.mjs": "103fe02d6ecdefe2d3017a9de7e56fe78a85992e6816c42e226c48ae79a38f30", + "docs/site/compare.mjs": "581a618d7feac9fafc02cc0e9da89aeb92f8eb99d00f1899b922a813b87c43ce", + "docs/site/compare.css": "8ac956c88c829c902a252aec94154ecd010a599f8abc2c29f4dec21fbdf849f3", + "docs/site/compare-source-panel.mjs": "6436b2c6651dfea4ec1dfd6612028ddbcd341ce6d662794a73b0625c37d96b3f", + "tests/test_reader_links.py": "726d487e49c9dbb5968666af0dabf09b2a83f8bba60832782bfd9e4d6e1a14bc", + "tools/reader_jump_browser_check.py": "dd1fc35fb7565c5671cd0d87a8c399091df16a00369d6ac1a0274b807edbad94" + }, + "release": "913672ed65a56581c57b0d3763ea3cc57045ac708ba0752e0434472f7864fa51", + "scientific_effect": "NONE", + "previous_source_receipt": "SOURCE-before-focus.json" +} diff --git a/docs/reports/experience-refinement-20261026/compare-summary.json b/docs/reports/experience-refinement-20261026/compare-summary.json new file mode 100644 index 000000000..596307b4f --- /dev/null +++ b/docs/reports/experience-refinement-20261026/compare-summary.json @@ -0,0 +1,41 @@ +{ + "base": "8a7c59a1f99f43622aa5135e90f2dafb814d2c19", + "files": { + "docs/site/compare.html": "98c1125e982ca927e159b863b108f4c7115ee9dd33dd50d2cfb85d9a825841eb", + "docs/site/compare.css": "8ac956c88c829c902a252aec94154ecd010a599f8abc2c29f4dec21fbdf849f3", + "docs/site/compare.mjs": "581a618d7feac9fafc02cc0e9da89aeb92f8eb99d00f1899b922a813b87c43ce", + "docs/site/compare-source-panel.mjs": "6436b2c6651dfea4ec1dfd6612028ddbcd341ce6d662794a73b0625c37d96b3f", + "tests/test_compare_source_panel.mjs": "4bca6e043b16ee10876aec19d29696a16e630ce57cffb5ca995e51abac32155d", + "tools/compare_experience_browser_check.py": "962713a9786e624b13a1e3588dae19570ab21679f4e3a25224a515836f38d80c", + "tools/snapshot_compare_browser_check.py": "b8b4e1c49368f8ae68862d4515b7805e7219d846193b7bfc6d4c6183e7e9cdc4" + }, + "baseline": { + "top_pager_exists": false, + "current_payload_requests": 2, + "separate_inventory_disabled": false, + "expected": { + "top_pager_exists": true, + "current_payload_requests": 1, + "separate_inventory_disabled": true + }, + "failures": [ + "top_pager_exists", + "current_payload_requests", + "separate_inventory_disabled" + ] + }, + "unit_pass": 21, + "source_guard_pass": 24, + "focused_browser": "/workspace/research/experience-refinement-20261026/compare/browser-final/report.json", + "existing_browser": "/workspace/research/experience-refinement-20261026/compare/existing-browser-green/report.json", + "source_preservation": "/workspace/research/experience-refinement-20261026/compare/source-preservation.json", + "retained_failures": [ + "unit-red.txt", + "existing-browser-run.txt: original string predicate hit CSP unsafe-eval; explicit function predicate fixed the driver without relaxing CSP" + ], + "scientific_effect": "NONE", + "provider": "OpenAI", + "model_family": "GPT-6", + "organizational_independence_credit": 0, + "release_keys": "Not regenerated by this task; Root owns final stable rekey and full public-shop checks." +} diff --git a/docs/reports/experience-refinement-20261026/focus-amendment.json b/docs/reports/experience-refinement-20261026/focus-amendment.json new file mode 100644 index 000000000..1761d8657 --- /dev/null +++ b/docs/reports/experience-refinement-20261026/focus-amendment.json @@ -0,0 +1,213 @@ +{ + "finding": "ER-I1: fixed Go to obscured the evidence-region focus ring at320px with text-spacing override.", + "original_public_head": "b14519045c88d91c2a9bdde3b09fccc396c362ba", + "original_hosted_job": 121726619256, + "reviewer_controlled_ring": { + "launcher_present": 0.656, + "launcher_hidden": 1.0 + }, + "repair": "CSS yields opacity/pointer events during external :focus-visible, retains tab order and restores on menu focus. No display:none, focus redirection, scroll/layout change or test threshold change.", + "native_focus_regression": { + "cases": [ + { + "case": "persistent-keyboard-1440-light", + "passed": true + }, + { + "case": "persistent-keyboard-1440-dark", + "passed": true + }, + { + "case": "persistent-keyboard-390-light", + "passed": true + }, + { + "case": "persistent-keyboard-390-dark", + "passed": true + }, + { + "case": "persistent-keyboard-320-dark", + "passed": true + }, + { + "case": "focus-yield-light-scripted", + "passed": true + }, + { + "case": "focus-yield-dark-scripted", + "passed": true + }, + { + "case": "focus-yield-light-native-no-js", + "passed": true + }, + { + "case": "focus-yield-dark-native-no-js", + "passed": true + }, + { + "case": "native-no-js-and-script-free-formal", + "passed": true + } + ], + "page_errors": [], + "limits": "Headless Chromium/Linux, emulated widths; no physical/Safari/spoken AT/full WCAG claim.", + "browser": "154.0.8037.57", + "passed": 10, + "failed": 0 + }, + "exact_original_ring_case": [ + { + "hidden": false, + "screenshot": 1, + "viewport": { + "width": 320, + "height": 1127 + }, + "region": { + "x": 16, + "y": 52.296875, + "width": 288, + "height": 1045.5 + }, + "menu": { + "x": 203.34375, + "y": 1064, + "width": 100.65625, + "height": 47 + }, + "clip": { + "x": 7, + "y": 43, + "width": 307, + "height": 1064 + } + }, + { + "hidden": false, + "screenshot": 2, + "viewport": { + "width": 320, + "height": 1127 + }, + "region": { + "x": 16, + "y": 52.296875, + "width": 288, + "height": 1045.5 + }, + "menu": { + "x": 203.34375, + "y": 1064, + "width": 100.65625, + "height": 47 + }, + "clip": { + "x": 7, + "y": 43, + "width": 307, + "height": 1064 + } + }, + { + "hidden": false, + "pass": true, + "least_side": 1 + }, + { + "hidden": true, + "screenshot": 1, + "viewport": { + "width": 320, + "height": 1127 + }, + "region": { + "x": 16, + "y": 52.296875, + "width": 288, + "height": 1045.5 + }, + "menu": null, + "clip": { + "x": 7, + "y": 43, + "width": 307, + "height": 1064 + } + }, + { + "hidden": true, + "screenshot": 2, + "viewport": { + "width": 320, + "height": 1127 + }, + "region": { + "x": 16, + "y": 52.296875, + "width": 288, + "height": 1045.5 + }, + "menu": null, + "clip": { + "x": 7, + "y": 43, + "width": 307, + "height": 1064 + } + }, + { + "hidden": true, + "pass": true, + "least_side": 1 + } + ], + "existing_layout_checks": { + "focus_ring_targets": 30, + "text_layouts": 20, + "passed": true + }, + "limits": "Current sandboxed Chromium154/Linux; pointer-focused inputs may also match :focus-visible and hide launcher. Ordinary non-focused reading may still overlap it. No broader browser/physical/AT/fullWCAG claim.", + "artifacts": [ + { + "path": "red/report.json", + "bytes": 2801, + "sha256": "d5a3cc6957d740b20d9d9fdf309caaa85ed7bb6b63e94b9643d8ca67b0950bc8" + }, + { + "path": "green/report.json", + "bytes": 6252, + "sha256": "fa9d5958e221e98236123e39d8759b0b8f2c55d7e7e9872dd7feaeb060fa7c0e" + }, + { + "path": "green-disclosure/report.json", + "bytes": 6199, + "sha256": "5dd0bf0ec28ca1351666734033d2617293efb1ff38fc841e40ebc1b402d759d6" + }, + { + "path": "green-route/report.json", + "bytes": 1014, + "sha256": "b312709e80743d4135e08ed972ba38efb24259db8c532976103d3feb2d6638a3" + }, + { + "path": "layout/report.json", + "bytes": 16490, + "sha256": "ceee4f765929629ee42139af889ddcd4a3ab9ca01b28040702394ec2bd050a96" + }, + { + "path": "exact-ring/focus-ring-repro.json", + "bytes": 1622, + "sha256": "feddea932d98cc99050c8f4181a07c1566eb95aef6251aadd84b547925d89408" + }, + { + "path": "check_layout.py", + "bytes": 1475, + "sha256": "aeac8d611c9af631b9d22ce11c745af9ff9298a26748f7422da2fcc13cd248cc" + }, + { + "path": "exact_ring.py", + "bytes": 2095, + "sha256": "dd121f5c534123c788ec909ae5e2c9fa31f77f29877b9ef8ba800a4a592784bf" + } + ] +} diff --git a/docs/reports/experience-refinement-20261026/navigation-browser.json b/docs/reports/experience-refinement-20261026/navigation-browser.json new file mode 100644 index 000000000..8d7fec5f1 --- /dev/null +++ b/docs/reports/experience-refinement-20261026/navigation-browser.json @@ -0,0 +1,33 @@ +{ + "cases": [ + { + "case": "persistent-keyboard-1440-light", + "passed": true + }, + { + "case": "persistent-keyboard-1440-dark", + "passed": true + }, + { + "case": "persistent-keyboard-390-light", + "passed": true + }, + { + "case": "persistent-keyboard-390-dark", + "passed": true + }, + { + "case": "persistent-keyboard-320-dark", + "passed": true + }, + { + "case": "native-no-js-and-script-free-formal", + "passed": true + } + ], + "page_errors": [], + "limits": "Headless Chromium/Linux, emulated widths; no physical/Safari/spoken AT/full WCAG claim.", + "browser": "154.0.8037.57", + "passed": 6, + "failed": 0 +} diff --git a/docs/reports/experience-refinement-20261026/origin-guard-amendment.json b/docs/reports/experience-refinement-20261026/origin-guard-amendment.json new file mode 100644 index 000000000..1f0433393 --- /dev/null +++ b/docs/reports/experience-refinement-20261026/origin-guard-amendment.json @@ -0,0 +1,204 @@ +{ + "prior_head": "f24a48af0fb68747c8cea37ba441ba0dbf4631c9", + "scope": "Two reader navigation test-driver HTTPS route guards and this source/report receipt. Product site bytes unchanged.", + "cause": "Playwright glob https://** does not match full URL paths; its intended offsite refusal was ineffective. Initial own-origin-block diagnosis was disproved and corrected.", + "fix": "Match https://**/*; fallback for requests beneath selected origin prefix, abort other matched HTTPS requests.", + "red": { + "source": "synthetic HTTPS browser fixtures from exact local bytes, no TLS/public-custody claim", + "requests": 73, + "probes": [ + { + "external_fixture_served": true, + "error": null + } + ] + }, + "green_https": { + "navigation": { + "cases": [ + { + "case": "persistent-keyboard-1440-light", + "passed": true + }, + { + "case": "persistent-keyboard-1440-dark", + "passed": true + }, + { + "case": "persistent-keyboard-390-light", + "passed": true + }, + { + "case": "persistent-keyboard-390-dark", + "passed": true + }, + { + "case": "persistent-keyboard-320-dark", + "passed": true + }, + { + "case": "focus-yield-light-scripted", + "passed": true + }, + { + "case": "focus-yield-dark-scripted", + "passed": true + }, + { + "case": "focus-yield-light-native-no-js", + "passed": true + }, + { + "case": "focus-yield-dark-native-no-js", + "passed": true + }, + { + "case": "native-no-js-and-script-free-formal", + "passed": true + } + ], + "page_errors": [], + "limits": "Headless Chromium/Linux, emulated widths; no physical/Safari/spoken AT/full WCAG claim.", + "browser": "154.0.8037.57", + "passed": 10, + "failed": 0 + }, + "routing": { + "source": "synthetic HTTPS browser fixtures from exact local bytes, no TLS/public-custody claim", + "requests": 451, + "probes": [ + { + "external_fixture_served": false, + "error": "Page.goto: net::ERR_FAILED at https://excluded-reader.invalid/probe" + }, + { + "external_fixture_served": false, + "error": "Page.goto: net::ERR_FAILED at https://excluded-reader.invalid/probe" + }, + { + "external_fixture_served": false, + "error": "Page.goto: net::ERR_FAILED at https://excluded-reader.invalid/probe" + }, + { + "external_fixture_served": false, + "error": "Page.goto: net::ERR_FAILED at https://excluded-reader.invalid/probe" + }, + { + "external_fixture_served": false, + "error": "Page.goto: net::ERR_FAILED at https://excluded-reader.invalid/probe" + }, + { + "external_fixture_served": false, + "error": "Page.goto: net::ERR_FAILED at https://excluded-reader.invalid/probe" + }, + { + "external_fixture_served": false, + "error": "Page.goto: net::ERR_FAILED at https://excluded-reader.invalid/probe" + } + ] + } + }, + "green_loopback": { + "cases": [ + { + "case": "persistent-keyboard-1440-light", + "passed": true + }, + { + "case": "persistent-keyboard-1440-dark", + "passed": true + }, + { + "case": "persistent-keyboard-390-light", + "passed": true + }, + { + "case": "persistent-keyboard-390-dark", + "passed": true + }, + { + "case": "persistent-keyboard-320-dark", + "passed": true + }, + { + "case": "focus-yield-light-scripted", + "passed": true + }, + { + "case": "focus-yield-dark-scripted", + "passed": true + }, + { + "case": "focus-yield-light-native-no-js", + "passed": true + }, + { + "case": "focus-yield-dark-native-no-js", + "passed": true + }, + { + "case": "native-no-js-and-script-free-formal", + "passed": true + } + ], + "page_errors": [], + "limits": "Headless Chromium/Linux, emulated widths; no physical/Safari/spoken AT/full WCAG claim.", + "browser": "154.0.8037.57", + "passed": 10, + "failed": 0 + }, + "limits": "Synthetic HTTPS browser fixtures from exact local bytes; no TLS/network/public-byte/source-authentication claim. Seven offsite probes in scripted contexts. Initial ModuleNotFoundError and invalid-tunnel fixture attempts were setup failures, not mathematical or product RED. All retained.", + "artifacts": [ + { + "path": "check_https_origin.py", + "bytes": 2353, + "sha256": "c07795985978f93fcfd509d09acb6e769418b5c8714a664276d7dfebe425a81c" + }, + { + "path": "red.log", + "bytes": 725, + "sha256": "fcfea166cce957721bfb6ce37e2004707e891bc49abe951a91e8d45587c231a8" + }, + { + "path": "red-cases.log", + "bytes": 75, + "sha256": "7db7b885d7bbe3efda10de777ebc6f4f896b9848567093150a5b388c98c9321e" + }, + { + "path": "red-accessible-origin.log", + "bytes": 75, + "sha256": "7db7b885d7bbe3efda10de777ebc6f4f896b9848567093150a5b388c98c9321e" + }, + { + "path": "red-external.log", + "bytes": 1476, + "sha256": "fab69945d70ab59089c52ea216c3dd49e9a94b55193b659bbf69a5288ed468f3" + }, + { + "path": "red-external/fixture-custody.json", + "bytes": 211, + "sha256": "e2463b98d216a904c0068864604aa34189ae1b5ad88d35439e558c8a5a029aa4" + }, + { + "path": "green.log", + "bytes": 75, + "sha256": "09c079ed2d0a696cea15e91f1800feb10b2d693c88715c4ab97021af40f048ec" + }, + { + "path": "green/report.json", + "bytes": 1014, + "sha256": "b312709e80743d4135e08ed972ba38efb24259db8c532976103d3feb2d6638a3" + }, + { + "path": "green/fixture-custody.json", + "bytes": 1106, + "sha256": "3b4ec41a3e464dc567a327b1e5fc77f9d20c7e30d369d1793bcaab5ce2a3b669" + }, + { + "path": "green-loopback/report.json", + "bytes": 1014, + "sha256": "b312709e80743d4135e08ed972ba38efb24259db8c532976103d3feb2d6638a3" + } + ], + "scientific_effect": "NONE" +} diff --git a/docs/reports/experience-refinement-20261026/qualification.json b/docs/reports/experience-refinement-20261026/qualification.json new file mode 100644 index 000000000..4833fd91d --- /dev/null +++ b/docs/reports/experience-refinement-20261026/qualification.json @@ -0,0 +1,171 @@ +{ + "executor": "OpenAI / actual GPT-6 family / technical execution only", + "organizational_independence_credit": 0, + "scientific_effect": "NONE", + "status": "Applicable local qualification passed after two explicitly scoped recoveries; historical failures retained", + "public_product_release": "a7a202880f103f04e8685236c1770a846e31a9909064fd6b3cbd60377dce984d", + "base_head": "8a7c59a1f99f43622aa5135e90f2dafb814d2c19", + "base_tree": "5970f732a045f029fb3c4992ff9a3d83f9377dd1", + "initial_source_inventory_sha256": "76801300faabadb26b752af46bbc9277e9ad30fc351cbf3fd44d151548f6c22f", + "full_initial_pass": { + "publicshop_groups": 12, + "passed_initially": 11, + "reader_guard_failure": "77 tests,75 pass,2 failures; explicit script allowlist lacked reader-jump.mjs", + "focused_node": { + "tests": 26, + "passed": 26 + }, + "frontend_standalone": { + "tests": 313, + "passed": 311, + "expected_museum_skips": 2 + }, + "museum_fixture": { + "tests": 45, + "passed": 45, + "skipped": 0 + } + }, + "browser_setup_failure": { + "cases_started": 0, + "reason": "Scratch TMPDIR socket path exceeded Chromium Unix-domain socket length", + "original_failure_evidence": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-run1", + "recovery": "Scoped Root authorization; same frozen mirror, unmodified drivers and sandbox=True, explicit /usr/bin/chromium, fresh short /tmp/experience-qual-* TMPDIR" + }, + "browser_case_results": [ + { + "driver": "reader-jump", + "cases": 6, + "returncode": 0 + }, + { + "driver": "library-source-search", + "cases": 16, + "returncode": 0 + }, + { + "driver": "research-desk", + "cases": 13, + "returncode": 0 + }, + { + "driver": "reading-list-citation", + "cases": 3, + "returncode": 0 + }, + { + "driver": "research-desk-undo", + "cases": 80, + "returncode": 0 + } + ], + "browser_mirror_all_bytes_unchanged": true, + "reader_guard_amendment": { + "tests": 79, + "returncode": 0, + "only_changed_path": "tests/test_reader_links.py", + "old_sha256": "261cb6014a53bafff0a38a5989dcfa0885c992fcf818a2c9cf42ee8c80bd5af7", + "Root_new_sha256": "726d487e49c9dbb5968666af0dabf09b2a83f8bba60832782bfd9e4d6e1a14bc", + "product_unchanged": true, + "amended_mirror_unchanged_during_test": true + }, + "runtime_versions": { + "playwright": "1.62.0", + "python": "Python 3.12.14", + "node": "v24.19.0", + "chromium": "Chromium 154.0.8037.57 built on Debian GNU/Linux 13 (trixie)" + }, + "artifacts": [ + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-run1/summary.json", + "bytes": 40960, + "sha256": "fe42c043cb7a1eb0c4e8c48d3a0164fd54a757f4768cd6f1ef56507688e41eb2" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-run1/EXECUTION_RECEIPT.json", + "bytes": 2182, + "sha256": "e025725afac15d2b533c3a86439e23db6475f55e25d4f950d6a785ac3f8418d8" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-run1/source-before.json", + "bytes": 370045, + "sha256": "e961feddc36c019d03f79c6a58109f20f796dff1c681b2e156e2d305f16ce248" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-run1/mirror-before.json", + "bytes": 370085, + "sha256": "034cbf393e52fc2094a683107ae377cdafa0e8dba4acca980ab8074c919212eb" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-run1/mirror-after.json", + "bytes": 370085, + "sha256": "c179abdd4573eca36b132b2c0e3c5e75acad6d3ad797051c432ba0d688f0ad59" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-run1/executables.json", + "bytes": 858, + "sha256": "18b7a650e288193f0dba58058f1334e37a94e40d540b4b23e90ae5f085e7f2ec" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-browser-supplement/summary.json", + "bytes": 8308, + "sha256": "ff7c855dcd34de030a2165d904e9e5538d70f938b1b15a7e79cf0435bdc0b782" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-browser-supplement/ENV_DELTA.json", + "bytes": 346, + "sha256": "e3601066e2b99a79a0d5e6f751c40d39554704ab16462bea6ce09c84110c19b3" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-browser-supplement/mirror-before.json", + "bytes": 370085, + "sha256": "267ab571c23171ca88f6d192fa2e79484d57069e8fd38a0c69ce924bde341d1e" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-browser-supplement/mirror-after.json", + "bytes": 370085, + "sha256": "4a5b5901852f475d0b2b7d91a2320641dedee99cba430a5b680678e3978ae7eb" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-reader-amendment/summary.json", + "bytes": 1940, + "sha256": "fa52e5494189ea897c0450eb8010b3a357aa2eef9e79795f1624b860091e5d2a" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-reader-amendment/TEST_AMENDMENT.json", + "bytes": 952, + "sha256": "cd48117d0d0a786b29fd32f4978fcbe2a144e860288358fee5ef57564e4a5381" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-reader-amendment/reader-guard.patch", + "bytes": 2058, + "sha256": "b7fbe742e510480bb3aba877f17341237401fb03c8de36305661e664c5260b02" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-reader-amendment/test_reader_links.original.py", + "bytes": 163907, + "sha256": "261cb6014a53bafff0a38a5989dcfa0885c992fcf818a2c9cf42ee8c80bd5af7" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/frozen-a7a20288-reader-amendment/test_reader_links.amended.py", + "bytes": 164931, + "sha256": "726d487e49c9dbb5968666af0dabf09b2a83f8bba60832782bfd9e4d6e1a14bc" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/run_qualification.py", + "bytes": 12236, + "sha256": "d2b0bbf454908be9531d28137fbf79bc36aa01d8a162be5e36a93f433a533fe4" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/run_browser_supplement.py", + "bytes": 6123, + "sha256": "a804befd89a6dc3818a632dad071a1fe332c0f9a68d899d007d4b56fb8a74ddc" + }, + { + "path": "/workspace/research/experience-refinement-20261026/qualification/run_reader_amendment.py", + "bytes": 5112, + "sha256": "22b7cdef72abd32e6cca191e166f8ed076c6b12f1df314476383e8f3dcb99d19" + } + ], + "limits": "Local frozen working bytes on base8a7c59a1 only. No future Main composition, hosted checks, deployment, spoken AT, Safari/touch, full accessibility or scientific qualification. Compare browser suites were not repeated; their separate coauthor evidence is outside this runner receipt." +} diff --git a/docs/site/README.md b/docs/site/README.md index deb949be7..d1e02ef36 100644 --- a/docs/site/README.md +++ b/docs/site/README.md @@ -19,6 +19,14 @@ The front and technical layers use the same existing evidence. No second scienti ## Current source publication +The fixed **Go to** disclosure keeps Research, current-source search, the reading +list, Mathematics, Compare and citation/reproduction tools reachable during long +reading sessions. Its ordinary links work without JavaScript; Formal remains +script-free. Other current pages add Escape/outside dismissal without trapping +focus. It is navigation, not a proof search or an activity indicator. Print hides +the control. Focused checks: `node --test tests/test_reader_jump.mjs` and +`python3 -B tools/reader_jump_browser_check.py --output browser-evidence/reader-jump`. + `tools/current_site_data.py` resolves public main and Math- commits once, verifies their complete Git trees and the seven acquired source files, and extracts exact indented proof displays. Other inventory rows bind paths and Git blobs; their document bytes are not downloaded. The page calls equation blocks excerpts and keeps their surrounding proof scope available by pinned line links. `tools/current_site_build.py` renders one payload offline into marked current sections and static node pages. Formal remains script-free. Research preserves its dated reading cuts and their source pins, with a separately identified current observation. Generated Research pages use the existing `current.mjs` module to verify the advertised local `current.json` observation and progressively update its clock-derived freshness label (`current`, `stale` or `clock disagreement`); the same observation becomes stale after two hours. The module checks freshness each minute and on page/visibility events; it does not poll for a new observation or refresh editorial reading cuts. Generated current navigation, the observation timestamp and source pins remain readable without JavaScript. Current observations and original dated reading cuts have separate identities. "Resume this node" appears in the atlas inspector and on each current static node page. Both come from `resumeProjection` in `current-model.mjs`; `tools/current_site_history.py` keeps a Python copy, and `tests/test_current_site_resume.mjs` checks that the two agree on every node. The block names the snapshot's graph commit, path, SHA-256 and observation time, and warns readers to refresh from the live record before any ownership- or head-dependent action. Recorded `review_*` fields are labelled as review records, not as the current task, an owner or completion. Next action, missing input, owner evidence and retained stop read "not recorded in this snapshot" on the snapshot-only projection, because the graph records none of them. The atlas inspector also passes `node-status.json`, the published copy of `records/node_status`, into that same projection. Static node pages stay on the snapshot-only call. An owner object is shown only when `evidence_url` matches the shared comment pattern; `released_url`, when present, stays on that object and the atlas says released. The panel shows the recorded status and `observed_at`, and says stale when `observed_at` is more than 24 hours before the render clock. Status is freshness of that view, not scientific validity, and `scientific_effect` stays NONE. A bare `review_issue` number names no repository, so it is not linked. Continuation links come only from the small site-maintained `RESUME_TASK_RECORDS` table of explicitly identified operational pointers; they are not graph metadata, scientific acceptance or source-binding admission. Archived snapshot pages are unchanged. @@ -38,6 +46,17 @@ An additional focused browser check is `python3 -B tools/atlas_claim_summary_bro ## Verify the reader experience +Compare has synchronized page controls before and after its results. It verifies +its comparison metadata, registry and selected bytes immediately. Its separate +source inventory stays pinned and unverified until Sources and scope is opened +or a source deep link requests it, then uses the existing unchanged verifier. +This avoids a redundant initial current-payload transfer; it does not share or +weaken admission. Source-tool loading failures keep an explicit reload retry and +all static source links. Focused checks: `node --test tests/test_compare_source_panel.mjs` +and `python3 -B tools/compare_experience_browser_check.py --output +browser-evidence/compare-experience`; the existing snapshot comparison checks retain +their byte/registry/refusal coverage after explicitly opening that separate panel. + Persistent source-status reading: `python3 -B -S -m unittest tests.test_current_site_persistent_status` checks current paragraph semantics, exact previous live-page restoration, frozen historical renderer identities and refusal of altered source text or pins. `python3 -B tools/persistent_status_browser_check.py --site docs/site --output browser-evidence/persistent-status` exercises desktop/phone themes, source disclosures, static/no-JavaScript reading and verification failure. Use an admitted matching HTML/payload/meta observation; `--observe` records baseline failures. Actual speech and its platform limits are reported separately in `docs/reports/atlas-persistent-status-20261026`; these browser checks do not certify speech or full accessibility. No production dependency was added. Live Atlas control repair: `python3 -B tools/atlas_live_controls_browser_check.py --site docs/site --output browser-evidence/atlas-live-controls` exercises stable excerpt options, final-count announcements, keyboard View choice, exact source selection, reload/history and refused bookmarks at desktop/phone widths in both themes. Use an admitted matching HTML/payload/meta observation; `--observe` retains baseline failures. The report in `docs/reports/atlas-live-controls-20261026` distinguishes actual version-specific Orca speech from DOM checks and from the remaining Orca46.1 qualification. No production dependency was added. @@ -414,3 +433,14 @@ observation deliberately has a stale manifest and is not the positive fixture. Run python -B -m unittest tests.test_atlas_formal_evidence_build, its -O equivalent, and node --test tests/test_atlas_formal_evidence.mjs tests/test_current_site.mjs. The browser observer records served-file identities separately from its own driver. + +### Reader Go to and visible focus + +The native Go to disclosure on the eleven current reader pages stays available +while scrolling. With `:has` support it yields visually and ignores pointer events +while another element has `:focus-visible`, preventing the launcher from covering +that focus indicator. Its summary remains in tab order: Tab/Shift+Tab into the +menu restores it, and it stays visible while focus is inside. Pointer-focused +inputs may also trigger this behavior. No focus is redirected and no content +position changes. Formal remains script-free; native links work without scripts. +Current automated qualification covers Chromium/Linux, not every browser or AT. diff --git a/docs/site/cite.html b/docs/site/cite.html index eddc54645..5d47e29dc 100644 --- a/docs/site/cite.html +++ b/docs/site/cite.html @@ -8,9 +8,12 @@ + +
UNIVERSAL LAW MATHEMATICS IN THE OPEN
+
Go to
diff --git a/docs/site/compare-source-panel.mjs b/docs/site/compare-source-panel.mjs new file mode 100644 index 000000000..9a2efca31 --- /dev/null +++ b/docs/site/compare-source-panel.mjs @@ -0,0 +1,75 @@ +// Compare verifies its own publication immediately. This separate source-search +// view keeps the existing current.mjs verifier and loads only when requested. +export function sourcePanelRequested(section, href) { + const url = new URL(href); + if (url.searchParams.has('source-q')) return true; + if (!url.hash || url.hash === '#') return false; + try { + const target = section.ownerDocument.getElementById(decodeURIComponent(url.hash.slice(1))); + return !!target && (target === section || section.contains(target)); + } catch { return false; } +} + +export function installCompareSourcePanel(document, window) { + const section = document.getElementById('current-research'); + const panel = section?.querySelector('.current-source-details'); + const note = document.getElementById('compare-source-note'); + const retry = document.getElementById('compare-source-retry'); + if (!section || !panel || !note || !retry) return; + let state = 'idle'; + const setState = value => { state = value; section.dataset.compareSource = value; }; + setState('idle'); + + async function load() { + if (state === 'loading' || state === 'ready' || state === 'failed') return; + setState('loading'); + panel.setAttribute('aria-busy', 'true'); + note.textContent = 'Verifying the separate current-source inventory…'; + try { + const module = await import('./current.mjs?site-release=fc7e8a98c1e23f476962c4c83e95ed3ce817490007987112d9b2cf6d3d90b142'); + const data = await module.currentSnapshot; + if (!data) throw new Error('Source inventory verification did not complete.'); + setState('ready'); + note.hidden = true; + } catch { + setState('failed'); + note.textContent = 'The separate source inventory is unavailable. Reload to retry its verification; the pinned source links remain available.'; + retry.hidden = false; + } finally { + panel.removeAttribute('aria-busy'); + } + } + + function requested() { + if (!sourcePanelRequested(section, window.location.href)) return; + panel.open = true; + // A source query explicitly requests the search disclosure. Other fragments + // retain their native target and only reveal the target's own ancestors. + const url = new URL(window.location.href); + if (url.searchParams.has('source-q')) section.querySelector('.current-search')?.closest('details')?.setAttribute('open', ''); + else { + let target; + try { target = document.getElementById(decodeURIComponent(url.hash.slice(1))); } catch {} + for (let node = target; node && section.contains(node); node = node.parentElement) + if (node.tagName === 'DETAILS') node.open = true; + } + void load(); + } + + panel.addEventListener('toggle', () => { if (panel.open) void load(); }); + retry.addEventListener('click', () => { + // current.mjs exports one evaluation promise. A fresh document re-runs its + // unchanged verifier after either module acquisition or payload failure. + const url = new URL(window.location.href); + if (!sourcePanelRequested(section, url.href) || !url.hash) url.hash = 'current-research'; + window.history.replaceState(null, '', url); + window.location.reload(); + }); + window.addEventListener('hashchange', requested); + window.addEventListener('popstate', requested); + requested(); + if (panel.open) void load(); +} + +if (typeof document !== 'undefined' && typeof window !== 'undefined') + installCompareSourcePanel(document, window); diff --git a/docs/site/compare.css b/docs/site/compare.css index 67f1c59b7..64871e2cc 100644 --- a/docs/site/compare.css +++ b/docs/site/compare.css @@ -26,7 +26,7 @@ font: inherit; } #compare-form button, -#pagination button { +.comparison-pagination button { padding: 11px 18px; border: 1px solid var(--ul-edge); border-radius: 6px; @@ -36,7 +36,7 @@ cursor: pointer; } #compare-form button:disabled, -#pagination button:disabled { +.comparison-pagination button:disabled { opacity: 0.6; cursor: default; } @@ -110,13 +110,13 @@ cursor: pointer; padding: 10px 0; } -#pagination { +.comparison-pagination { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; } -#pagination[hidden] { +.comparison-pagination[hidden] { display: none; } @media (max-width: 650px) { @@ -138,7 +138,11 @@ } @media print { #compare-form, - #pagination { + .comparison-pagination { display: none; } } + +.compare-source-load { margin: 2rem 0 0; color: var(--ul-muted); font-size: .875rem; } +.compare-source-load button { min-height: 44px; } +.compare-source-load [hidden] { display: none; } diff --git a/docs/site/compare.html b/docs/site/compare.html index e06069d55..882e3eec7 100644 --- a/docs/site/compare.html +++ b/docs/site/compare.html @@ -11,16 +11,20 @@ - + - - + + + +
UNIVERSAL LAW MATHEMATICS IN THE OPEN
-

← Library · History registry

LIBRARY / TEMPORAL COMPARISON

What changed between observations?

Compare literal graph records and exact source identities across preserved versions. See commit pin movement separately from blob and byte changes.

Record differences do not establish mathematical inequivalence, correctness, acceptance or progress. These same-origin hashes check publication consistency; they are not authenticated remote custody or durable receipt replay. Scientific effect: NONE.

Link to this selection

Awaiting JavaScript verification. No comparison has been admitted.

Exact record differences

Twenty differences per page. Open a record to inspect its supplied fields; edge counts preserve complete-record multiplicity. The shared source record category includes changes also counted under pins or content.

+
Go to
+

← Library · History registry

LIBRARY / TEMPORAL COMPARISON

What changed between observations?

Compare literal graph records and exact source identities across preserved versions. See commit pin movement separately from blob and byte changes.

Record differences do not establish mathematical inequivalence, correctness, acceptance or progress. These same-origin hashes check publication consistency; they are not authenticated remote custody or durable receipt replay. Scientific effect: NONE.

Link to this selection

Awaiting JavaScript verification. No comparison has been admitted.

Exact record differences

Twenty differences per page. Open a record to inspect its supplied fields; edge counts preserve complete-record multiplicity. The shared source record category includes changes also counted under pins or content.

The separate source inventory below is pinned and unverified in this view. Open Sources and scope to verify and search it.

+

Source observation

Pinned source observation: . Compare this timestamp with the present time; observation is not scientific revalidation.

diff --git a/docs/site/compare.mjs b/docs/site/compare.mjs index e6a297e5f..32764e0ec 100644 --- a/docs/site/compare.mjs +++ b/docs/site/compare.mjs @@ -6,6 +6,7 @@ import { } from "./compare-model.mjs?site-release=4036fca2cd4519e4d09f2e19ffd38e64b3b2e6ce1ef20840dc52a9941d77d946"; import { sourceURL } from "./current-model.mjs?site-release=a30d68465e3acda48eedce64854afebc7af5c84903a4e6b0c649e08007b08999"; const $ = (id) => document.getElementById(id); +const pagerIDs = ["", "-top"]; let publication, generation = 0, pages = [], @@ -19,7 +20,12 @@ function clear() { page = 0; $("comparison-summary").replaceChildren(); $("comparison-results").replaceChildren(); - $("pagination").hidden = true; + for (const suffix of pagerIDs) { + $("pagination" + suffix).hidden = true; + $("previous" + suffix).disabled = true; + $("next" + suffix).disabled = true; + $("page-status" + suffix).textContent = ""; + } $("share").removeAttribute("href"); } function element(tag, text) { @@ -95,11 +101,13 @@ function drawPage() { } if (!pages.length) list.append(element("p", "No record differences in these categories.")); - $("page-status").textContent = - `${pages.length ? start + 1 : 0}–${Math.min(start + 20, pages.length)} of ${pages.length} differences`; - $("previous").disabled = page === 0; - $("next").disabled = start + 20 >= pages.length; - $("pagination").hidden = pages.length === 0; + for (const suffix of pagerIDs) { + $("page-status" + suffix).textContent = + `${pages.length ? start + 1 : 0}–${Math.min(start + 20, pages.length)} of ${pages.length} differences`; + $("previous" + suffix).disabled = page === 0; + $("next" + suffix).disabled = start + 20 >= pages.length; + $("pagination" + suffix).hidden = pages.length === 0; + } } function render(result, choices, before, after) { const summary = $("comparison-summary"); @@ -246,16 +254,18 @@ for (const id of ["from", "to"]) ); }); $("retry").addEventListener("click", initialize); -$("previous").addEventListener("click", () => { - page--; - drawPage(); - $("results-heading").focus(); -}); -$("next").addEventListener("click", () => { - page++; - drawPage(); - $("results-heading").focus(); -}); +for (const suffix of pagerIDs) { + $("previous" + suffix).addEventListener("click", () => { + page--; + drawPage(); + $("results-heading").focus(); + }); + $("next" + suffix).addEventListener("click", () => { + page++; + drawPage(); + $("results-heading").focus(); + }); +} window.addEventListener("popstate", () => { if (!publication) { initialize(); diff --git a/docs/site/dependencies.html b/docs/site/dependencies.html index 7e6a92adc..039b7b229 100644 --- a/docs/site/dependencies.html +++ b/docs/site/dependencies.html @@ -17,6 +17,8 @@ + + @@ -25,6 +27,7 @@ +
Go to
diff --git a/docs/site/explore.html b/docs/site/explore.html index dad68f03f..ef2f3472d 100644 --- a/docs/site/explore.html +++ b/docs/site/explore.html @@ -16,6 +16,8 @@ + + @@ -24,6 +26,7 @@ +
Go to
diff --git a/docs/site/formal.html b/docs/site/formal.html index 8b077b4b4..75ca3b9af 100644 --- a/docs/site/formal.html +++ b/docs/site/formal.html @@ -10,11 +10,13 @@ +
UNIVERSAL LAW MATHEMATICS IN THE OPEN
+
Go to
diff --git a/docs/site/index.html b/docs/site/index.html index 1d7ab651c..8ac93a910 100644 --- a/docs/site/index.html +++ b/docs/site/index.html @@ -10,10 +10,13 @@ + +
UNIVERSAL LAW MATHEMATICS IN THE OPEN
+
Go to
diff --git a/docs/site/measure.html b/docs/site/measure.html index be08ef506..d9b56c7f6 100644 --- a/docs/site/measure.html +++ b/docs/site/measure.html @@ -14,6 +14,8 @@ + + @@ -22,6 +24,7 @@ +
Go to
diff --git a/docs/site/museum.html b/docs/site/museum.html index da668b96f..cdc14046c 100644 --- a/docs/site/museum.html +++ b/docs/site/museum.html @@ -13,11 +13,14 @@ + +
UNIVERSAL LAW MATHEMATICS IN THE OPEN
+
Go to
diff --git a/docs/site/reader-jump.css b/docs/site/reader-jump.css new file mode 100644 index 000000000..9a25631f7 --- /dev/null +++ b/docs/site/reader-jump.css @@ -0,0 +1,15 @@ +/* Native task navigation; no scientific or source-state styling. */ +body > .reader-jump {position:fixed;right:16px;bottom:max(16px,env(safe-area-inset-bottom));z-index:1000;margin:0;padding:0;border:0;font-size:14px;max-width:calc(100vw - 32px)} +/* Yield to visible focus elsewhere without removing the native summary from + tab order. It returns as soon as focus enters the menu, including without JS. */ +body:has(:focus-visible):not(:has(.reader-jump:focus-within)) > .reader-jump {opacity:0;pointer-events:none} +.reader-jump > summary {display:list-item;list-style-position:inside;cursor:pointer;min-height:44px;padding:12px 18px;border:1px solid var(--ul-border);border-radius:var(--ul-radius-m,8px);background:var(--ul-surface);color:var(--ul-text);font:600 14px/1.4 system-ui,sans-serif;box-shadow:0 4px 16px rgb(0 0 0 / .15)} +.reader-jump > nav {position:absolute;bottom:calc(100% + 8px);right:0;width:19rem;max-width:calc(100vw - 32px);max-height:calc(100dvh - 100px);overflow:auto;overscroll-behavior:contain;background:var(--ul-surface);border:1px solid var(--ul-border);border-radius:var(--ul-radius-m,8px);padding:8px;box-shadow:0 12px 40px rgb(0 0 0 / .15)} +.reader-jump:not([open]) > nav {display:none} +.reader-jump[open] > nav {display:grid} +.reader-jump > nav a {display:flex;align-items:center;min-height:44px;padding:10px 12px;margin:0;color:var(--ul-link);font:14px/1.4 system-ui,sans-serif;text-decoration:underline;text-underline-offset:3px;overflow-wrap:anywhere} +.reader-jump > nav a:hover {background:var(--ul-background)} +.reader-jump :is(summary,a):focus-visible {outline:3px solid var(--ul-focus);outline-offset:2px} +body > .reader-jump ~ footer {padding-bottom:max(5rem,env(safe-area-inset-bottom))} +@media(forced-colors:active){.reader-jump > :is(summary,nav){border-color:CanvasText;box-shadow:none}} +@media print{body > .reader-jump{display:none!important}} diff --git a/docs/site/reader-jump.mjs b/docs/site/reader-jump.mjs new file mode 100644 index 000000000..8ac41a512 --- /dev/null +++ b/docs/site/reader-jump.mjs @@ -0,0 +1,26 @@ +// Optional dismissal only: native details/links work without this module. +export function startReaderJump(doc,win) { + const menu=doc.querySelector('body > .reader-jump'); + if(!menu||menu.dataset.enhanced)return null; + const summary=menu.querySelector(':scope > summary'); + if(!summary)return null; + menu.dataset.enhanced='true'; + menu.addEventListener('click',event=>{ + if(event.target.closest('a[href]'))menu.open=false; + }); + menu.addEventListener('keydown',event=>{ + if(event.key==='Escape'&&menu.open){ + event.preventDefault();event.stopPropagation();menu.open=false; + summary.focus({preventScroll:true}); + } + }); + doc.addEventListener('pointerdown',event=>{ + if(menu.open&&!menu.contains(event.target))menu.open=false; + }); + menu.addEventListener('focusout',event=>{ + if(event.relatedTarget&&!menu.contains(event.relatedTarget))menu.open=false; + }); + win.addEventListener('pagehide',()=>{menu.open=false;}); + return menu; +} +if(typeof document!=='undefined'&&typeof window!=='undefined')startReaderJump(document,window); diff --git a/docs/site/reproduce.html b/docs/site/reproduce.html index 46de47c9d..d10bef04c 100644 --- a/docs/site/reproduce.html +++ b/docs/site/reproduce.html @@ -9,9 +9,12 @@ + +
UNIVERSAL LAW MATHEMATICS IN THE OPEN
+
Go to
diff --git a/docs/site/research.html b/docs/site/research.html index 816dfd310..6871f039b 100644 --- a/docs/site/research.html +++ b/docs/site/research.html @@ -10,9 +10,12 @@ + +
UNIVERSAL LAW MATHEMATICS IN THE OPEN
+
Go to
diff --git a/docs/site/workspace.html b/docs/site/workspace.html index 70dc9e397..cd1899aa8 100644 --- a/docs/site/workspace.html +++ b/docs/site/workspace.html @@ -15,11 +15,14 @@ + +
UNIVERSAL LAW MATHEMATICS IN THE OPEN
+
Go to
diff --git a/docs/superpowers/plans/2026-10-26-experience-refinement.md b/docs/superpowers/plans/2026-10-26-experience-refinement.md new file mode 100644 index 000000000..60920b497 --- /dev/null +++ b/docs/superpowers/plans/2026-10-26-experience-refinement.md @@ -0,0 +1,58 @@ +# Experience refinement implementation plan + +> **For agentic workers:** Use superpowers:executing-plans or subagent-driven-development. Read the linked spec; preserve its source and scientific boundaries. + +**Goal:** Make research tools accessible while reading, make Compare faster to +navigate/load, and make local planner connection status truthful. +**Architecture:** Native disclosure/navigation; two synchronized pager controls; +Compare-only demand loading of the existing source verifier; separate local v24 +dashboard state machine. No framework/backend/schema change. +**Spec:** `docs/superpowers/specs/2026-10-26-experience-refinement.md`. + +## Global constraints and review focus + +No mathematical data, source admission, current.mjs/model, frozen history, worker +control, auth/CORS, workflow/settings or certification changes. Preserve newer +outside focus, no-JS links and script-free Formal. Explicitly distinguish planner +transport, valid data, stale data and worker execution. Check mobile overlay +obstruction, both pager disabled states, source deep links/retry and malformed SSE. + +### Task1: Persistent reader navigation (Root) + +- [ ] Write/run baseline browser tests for absent Go to, visible access at long + scroll, native keyboard/links and no-JS/formal behavior. +- [ ] Add reader-jump.css/mjs and consistent native markup to eleven current HTML + pages; module on ten pages, never Formal. Do initial shared HTML edit before + delegating Compare's other edits, then leave those hunks alone. +- [ ] Verify menus in desktop/phone schemes, outside/Escape focus, print and native + destination links. Stage new assets before one final release-key regeneration. + +### Task2: Compare ergonomics and acquisition (delegated) + +- [ ] Record baseline top-pager absence and two current.json requests. +- [ ] Modify only compare.html/css/mjs, new compare-source-panel.mjs, focused tests + and driver. Use existing loadPublication and source verifier unchanged. +- [ ] Verify synchronized upper/lower pagination/focus/refusal and exactly one + initial current payload fetch; second only after source disclosure requested. +- [ ] Verify direct source links and module/network failure, and existing Compare + regression suite. Return stable files for Root release-key generation. + +### Task3: Local v24 dashboard accuracy (separate checkout/delegate) + +- [ ] Create isolated source247981b checkout and external runtime; preserve exact + originals and claim exact dashboard/test/doc scope in existing architecture task. +- [ ] Reproduce premature Live and partial invalid render before changing code. +- [ ] Implement validated atomic snapshot preparation and honest transport/error/ + stale states. Never connect the full legacy Coordinator or formal workers. +- [ ] Run adversarial fixtures and documented real isolated planner GET/SSE flow; + prove snapshot/journal identity and no worker/certificate promotion. + +### Final integration + +- [ ] Run required site checks and affected browser regressions after all public + files stabilize; preserve source identities and test evidence. +- [ ] Separate whole-branch engineering review, current protected integration and + actual public-byte/browser acceptance. Apply effective existing LOOSEN C without + claiming a delayed service review passed or bypassing platform gates. +- [ ] Additive verified Drive source/site/local-patch/evidence delivery, one grouped + register entry, original failure/deletion records and explicit remaining gaps. diff --git a/docs/superpowers/specs/2026-10-26-experience-refinement.md b/docs/superpowers/specs/2026-10-26-experience-refinement.md new file mode 100644 index 000000000..21f9db6eb --- /dev/null +++ b/docs/superpowers/specs/2026-10-26-experience-refinement.md @@ -0,0 +1,55 @@ +# Reading and local-status refinement + +Owner direction delegates implementation choices and asks us to keep refining +the finished experience without repeated approval questions. Public baseline is +Main8a7c59a1. The browser audit found long pages without persistent navigation, +a mobile Compare pager5879px below its first result, and two current-payload +transfers on Compare. The separate existing v24 dashboard marks transport open +as Live before receiving a valid snapshot. + +## Public reader + +Add one compact fixed Go to disclosure on the eleven current top-level pages. +Use ordinary internal anchors to existing Home, Explore, Research, current-source +search, reading list, Mathematics, Compare, Cite and Reproduce routes. Native +details/summary and links remain useful without JavaScript. Formal stays script +free. A small optional module closes the menu on selection, Escape or an outside +pointer/focus move, preserving newer outside focus; no global shortcut, dialog +focus trap or new dependency. Use one scoped stylesheet, existing brand tokens, +44px controls, phone safe areas, forced colors and print hiding. Frozen historical +pages/renderers and original content/source identities are unchanged. + +Add synchronized Compare paging above results while preserving its bottom pager +and existing results-heading focus behavior. Both update together and clear on +selection/refusal. Defer only Compare's separate current-source inventory view +until Sources and scope is opened (or an explicit source deep link requests it). +Its status stays explicitly pinned/unverified until the unchanged current.mjs +verifier runs. Load comparison metadata/registry/current payload with its existing +independent validator immediately. No byte cache, shared trust receipt or weakened +admission rule. This removes the duplicate initial payload transfer, not necessary +verification. Failures remain visible; static source links work without scripts. + +## Separate local planner + +Use an isolated checkout of unchanged v24 source247981b. Repair the existing +dashboard's connection/last-snapshot/error states using its existing loopback +GET/SSE contract. An open transport is Awaiting snapshot, not live data. Validate +consumed fields before mutating the view; retain the last accepted view on bad +data and clearly label stale/reconnecting/unavailable states with receipt time. +Do not invent worker execution, event replay, authenticated production adoption +or Main49-to-historical104 joins. A fresh explicitly labeled external runtime may +initialize its own journal via the documented qualified planner path, with no +Coordinator, native checker, POST, authentication/CORS or service exposure change. +Tests use adversarial transport fixtures as tests and a real isolated planner +snapshot as separate operational evidence. No scientific review/promotion. + +## Verification and delivery + +Test phone/desktop light/dark, no-JavaScript navigation, keyboard focus, native +links/history, menu obstruction/print, both pagers, source-load refusal and exact +request counts. Preserve validators and original failures. Run prescribed reader +regressions, qualify separate engineering review and ordinary protected release; +archive deleted/replaced originals in Drive and never delete Drive material. +Package the public site and separate local planner patch with exact provenance. +Do not claim the entire research vision, spoken AT, Safari/touch, large-scale FPS +or mathematical certification from these engineering checks. diff --git a/tests/test_compare_source_panel.mjs b/tests/test_compare_source_panel.mjs new file mode 100644 index 000000000..a9920a819 --- /dev/null +++ b/tests/test_compare_source_panel.mjs @@ -0,0 +1,35 @@ +import test from 'node:test'; +import assert from 'node:assert/strict'; +import {readFile} from 'node:fs/promises'; +import {existsSync} from 'node:fs'; + +const moduleURL = new URL('../docs/site/compare-source-panel.mjs', import.meta.url); +test('Compare source panel demand loader exists', () => assert.ok(existsSync(moduleURL))); +const load = async () => existsSync(moduleURL) ? import(moduleURL) : null; +function section() { + const inside = {id: 'current-date-explanation'}; + const outside = {id: 'results-heading'}; + const root = {id:'current-research', contains:target=>target===inside||target===root}; + root.ownerDocument={getElementById:id=>({[inside.id]:inside,[outside.id]:outside,[root.id]:root})[id]||null}; + return root; +} +test('An explicit current-source query requests even the empty source search', async () => { + const m=await load();assert.ok(m,'demand loader missing'); + for(const query of ['?source-q=SIDE24','?source-q=','?source-q']) + assert.equal(m.sourcePanelRequested(section(),'https://example.test/compare.html'+query),true,query); +}); +test('Only a target in the actual source panel requests its verifier', async () => { + const m=await load();assert.ok(m,'demand loader missing'); + for(const hash of ['#current-research','#current-date-explanation','#current%2Ddate-explanation']) + assert.equal(m.sourcePanelRequested(section(),'https://example.test/compare.html'+hash),true,hash); + for(const suffix of ['', '?from=archive:abc', '#results-heading', '#missing', '#%EF%ZZ']) + assert.equal(m.sourcePanelRequested(section(),'https://example.test/compare.html'+suffix),false,suffix); +}); +test('Both pagers use distinct identities and ordinary, non-live count spans', async () => { + const html=await readFile(new URL('../docs/site/compare.html',import.meta.url),'utf8'); + for(const id of ['pagination-top','previous-top','next-top','page-status-top','pagination','previous','next','page-status']) + assert.equal([...html.matchAll(new RegExp(`id="${id}"`,'g'))].length,1,id); + assert.match(html,/aria-label="Result pages, above differences"/); + assert.match(html,/aria-label="Result pages, below differences"/); + for(const id of ['page-status','page-status-top']) assert.match(html,new RegExp(``)); +}); diff --git a/tests/test_reader_jump.mjs b/tests/test_reader_jump.mjs new file mode 100644 index 000000000..b03440e7e --- /dev/null +++ b/tests/test_reader_jump.mjs @@ -0,0 +1,27 @@ +import test from 'node:test'; +import assert from 'node:assert/strict'; +import fs from 'node:fs'; +import {startReaderJump} from '../docs/site/reader-jump.mjs'; +const root=new URL('../docs/site/',import.meta.url); +const pages=['index','explore','research','workspace','compare','cite','reproduce','dependencies','measure','museum','formal']; +test('current readers expose consistent native task links with real destinations',()=>{ + let expected; + for(const page of pages){ + const html=fs.readFileSync(new URL(page+'.html',root),'utf8'); + assert.equal((html.match(/class="reader-jump"/g)||[]).length,1,page); + const menu=html.match(/
(.*?)<\/details>/s)?.[1];assert.ok(menu,page); + const links=[...menu.matchAll(/href="([^"]+)"/g)].map(m=>m[1]); + if(!expected)expected=links;else assert.deepEqual(links,expected,page); + for(const href of links){ + const [name,id]=href.split('#');const target=new URL(name,root);assert.ok(fs.existsSync(target),href); + if(id)assert.ok(fs.readFileSync(target,'utf8').includes(`id="${id}"`),href); + } + assert.ok(html.includes('reader-jump.css'),page); + if(page==='formal')assert.ok(!/{ + assert.equal(startReaderJump({querySelector:()=>null},{}),null); + assert.equal(startReaderJump({querySelector:()=>({dataset:{enhanced:'true'}})},{}),null); +}); diff --git a/tests/test_reader_links.py b/tests/test_reader_links.py index 41cb772b5..cc45be0da 100644 --- a/tests/test_reader_links.py +++ b/tests/test_reader_links.py @@ -711,14 +711,28 @@ def assert_research_page_scripts(case, text): paths=[] for tag in tags: src=tag.group(1) - case.assertRegex(src, r'\A(?:current|reader-shell|research-reading)\.mjs(?:\?site-release=[0-9a-f]{64})?\Z') + case.assertRegex(src, r'\A(?:current|reader-shell|research-reading|reader-jump)\.mjs(?:\?site-release=[0-9a-f]{64})?\Z') parts=urlsplit(src) case.assertEqual((parts.scheme,parts.netloc,parts.fragment), ('','','')) - case.assertIn(parts.path,('current.mjs','reader-shell.mjs','research-reading.mjs')) + case.assertIn(parts.path,('current.mjs','reader-shell.mjs','research-reading.mjs','reader-jump.mjs')) case.assertRegex(parts.query, r'\A(?:site-release=[0-9a-f]{64})?\Z') paths.append(parts.path) case.assertEqual(len(paths),len(set(paths)), 'Duplicate module') +class ResearchScriptBoundary(unittest.TestCase): + def test_navigation_module_is_explicitly_admitted(self): + for suffix in ('', '?site-release='+'a'*64): + assert_research_page_scripts(self, '') + + def test_arbitrary_remote_inline_and_duplicate_scripts_remain_refused(self): + for src in ('evil.mjs','https://evil.example/reader-jump.mjs','//evil.example/reader-jump.mjs', + 'reader-jump.mjs#extra','reader-jump.mjs?unexpected=1','reader-jump.mjs?site-release=short'): + with self.subTest(src=src), self.assertRaises(AssertionError): + assert_research_page_scripts(self, '') + for text in ('', ''*2): + with self.subTest(text=text), self.assertRaises(AssertionError): + assert_research_page_scripts(self, text) + class LatestSourceControls(unittest.TestCase): def test_pinned_citations_are_exact_and_hashes_retain_the_checked_identity(self): self.assertEqual(len(validate_reading_pins((SITE/'research.html').read_text())),45+len(OCT10_FACE_PINS)+len(OCT10_PINS)) diff --git a/tools/compare_experience_browser_check.py b/tools/compare_experience_browser_check.py new file mode 100644 index 000000000..75c912880 --- /dev/null +++ b/tools/compare_experience_browser_check.py @@ -0,0 +1,218 @@ +#!/usr/bin/env python3 +"""Bounded Compare paging and demand-loaded source-view checks on real artifacts.""" +import argparse +import functools +import hashlib +import http.server +import json +from pathlib import Path +import subprocess +import threading +from urllib.parse import urlsplit, parse_qs +from playwright.sync_api import sync_playwright + + +def main(): + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument('--browser', default='/usr/bin/chromium') + parser.add_argument('--output', type=Path, required=True) + parser.add_argument('--site', type=Path, default=Path(__file__).resolve().parents[1] / 'docs/site') + args = parser.parse_args() + args.output.mkdir(parents=True, exist_ok=True) + class Quiet(http.server.SimpleHTTPRequestHandler): + def log_message(self, *_args): pass + server = http.server.ThreadingHTTPServer(('127.0.0.1', 0), functools.partial(Quiet, directory=str(args.site.resolve()))) + threading.Thread(target=server.serve_forever, daemon=True).start() + origin = f'http://127.0.0.1:{server.server_port}/' + report = {'checks': [], 'source_sha256': {name: hashlib.sha256((args.site/name).read_bytes()).hexdigest() + for name in ['compare.html', 'compare.css', 'compare.mjs', 'compare-source-panel.mjs', 'current.mjs', 'current-model.mjs', 'compare-model.mjs']}, + 'browser': subprocess.run([args.browser, '--version'], text=True, capture_output=True, check=True).stdout.strip(), + 'scientific_effect': 'NONE', 'scope': 'Local Chromium DOM, requests and keyboard focus; no spoken AT or Safari claims'} + errors = [] + def watch(page): + requests = [] + page.on('request', lambda r: requests.append(r.url)) + page.on('pageerror', lambda e: errors.append(str(e))) + return requests + def current_requests(requests): + return [u for u in requests if urlsplit(u).path == '/current.json'] + def completed(page): + page.locator('#compare-state[data-state="completed"]').wait_for() + page.wait_for_load_state('networkidle') + def synced(page): + assert page.locator('#page-status').inner_text() == page.locator('#page-status-top').inner_text() + for which in ['previous', 'next']: + assert page.locator('#'+which).is_disabled() == page.locator('#'+which+'-top').is_disabled() + assert page.locator('#pagination').is_visible() == page.locator('#pagination-top').is_visible() + try: + with sync_playwright() as p: + browser = p.chromium.launch(executable_path=args.browser, headless=True, chromium_sandbox=True) + for width, height, scheme in [(1440,1000,'light'),(1440,1000,'dark'),(390,844,'light'),(390,844,'dark')]: + page = browser.new_page(viewport={'width':width,'height':height}, color_scheme=scheme) + requests = watch(page) + page.goto(origin+'compare.html'); completed(page) + assert len(current_requests(requests)) == 1, current_requests(requests) + assert page.locator('.current-search').is_disabled() + assert 'pinned and unverified' in page.locator('#compare-source-note').inner_text() + assert page.locator('.current-state').inner_text().startswith('Pinned source observation:') + assert not page.locator('.current-source-details').get_attribute('open') + assert page.locator('#pagination-top').is_visible() + assert page.locator('#pagination-top').evaluate("e=>e.compareDocumentPosition(document.getElementById('comparison-results')) & Node.DOCUMENT_POSITION_FOLLOWING") + assert page.locator('#pagination-top').get_attribute('aria-label') != page.locator('#pagination').get_attribute('aria-label') + assert page.locator('#page-status-top').get_attribute('role') is None + assert page.locator('#page-status-top').get_attribute('aria-live') is None + synced(page) + assert page.locator('#previous-top').is_disabled() + first = page.locator('#comparison-results .change code').first.inner_text() + page.locator('#next-top').click(); synced(page) + assert page.locator('#comparison-results .change code').first.inner_text() != first + assert page.locator('#results-heading').evaluate('e=>e===document.activeElement') + page.locator('#previous').click(); synced(page) + assert page.locator('#comparison-results .change code').first.inner_text() == first + assert page.locator('#results-heading').evaluate('e=>e===document.activeElement') + # Requesting the separate source view adds precisely its own unchanged acquisition. + page.locator('.current-source-details > summary').click() + page.locator('#compare').focus() + page.locator('#current-research[data-compare-source="ready"]').wait_for() + assert len(current_requests(requests)) == 2 + assert page.locator('.current-search').is_enabled() + assert page.locator('.current-state').inner_text().startswith('Verified source observation:') + assert page.locator('#compare').evaluate('e=>e===document.activeElement') + page.locator('.current-source-details > summary').click() + page.locator('.current-source-details > summary').click() + page.wait_for_load_state('networkidle') + assert len(current_requests(requests)) == 2 + assert page.evaluate('document.documentElement.scrollWidth <= innerWidth') + expected = json.loads((args.site/'current.json').read_bytes())['sources'][0] + href = f'https://github.com/{expected["repository"]}/blob/{expected["commit"]}/{expected["path"]}' + assert page.locator('.current-results > li a').first.get_attribute('href') == href + page.emulate_media(media='print') + assert page.locator('#pagination-top').is_hidden() and page.locator('#pagination').is_hidden() + page.emulate_media(media='screen') + if scheme == 'light' and width == 1440: + # Exercise the real final page without hundreds of browser roundtrips. + steps = page.evaluate("""()=>{let n=0;while(!document.getElementById('next-top').disabled&&n<500){document.getElementById('next-top').click();n++;}return n;}""") + assert steps < 500 + assert page.locator('#next-top').is_disabled(); synced(page) + page.locator('#previous-top').click(); synced(page) + report['actual_last_page_steps'] = steps + # A changed selection clears and disables both paging surfaces. + same = page.locator('#from').input_value() + page.locator('#to').select_option(same) + for suffix in ['', '-top']: + assert page.locator('#pagination'+suffix).is_hidden() + assert page.locator('#previous'+suffix).is_disabled() + assert page.locator('#next'+suffix).is_disabled() + page.locator('#compare').click(); completed(page) + assert page.locator('#comparison-results .change').count() == 0 + synced(page) + page.screenshot(path=str(args.output/f'compare-{width}-{scheme}.png'), full_page=True) + report['checks'].append(f'{width}x{height} {scheme}: one initial current acquisition; dual paging/focus/clear/zero differences; independent requested source verification/exact URI; reopen reuse; outside focus; print/no overflow') + page.close() + # Keep the optional import pending while the reader closes the source + # disclosure and moves focus elsewhere. Completion must respect both. + page=browser.new_page();requests=watch(page);pending=[] + page.route('**/current.mjs?*',lambda route:pending.append(route)) + page.goto(origin+'compare.html');completed(page) + with page.expect_request('**/current.mjs?*'): + page.locator('.current-source-details > summary').click() + page.evaluate("document.querySelector('.current-source-details').open=false") + page.locator('#compare').focus() + assert pending + for route in pending:route.continue_() + page.unroute('**/current.mjs?*') + page.locator('#current-research[data-compare-source="ready"]').wait_for() + assert not page.locator('.current-source-details').evaluate('e=>e.open') + assert page.locator('#compare').evaluate('e=>e===document.activeElement') + assert len(current_requests(requests))==2 + page.close() + report['checks'].append('Pending optional import completion preserves a newly closed source disclosure and newer outside focus') + for suffix in ['?source-q=', '?source-q=SIDE24', '#current-research', '#current-date-explanation', '#current-inventory-legend']: + page=browser.new_page(); requests=watch(page) + page.goto(origin+'compare.html'+suffix);completed(page) + page.locator('#current-research[data-compare-source="ready"]').wait_for() + assert len(current_requests(requests)) == 2 + assert page.locator('.current-source-details').evaluate('e=>e.open') + if 'source-q' in suffix: + assert page.locator('.current-search').is_visible() + assert page.locator('.current-search').input_value() == parse_qs(urlsplit(suffix).query, keep_blank_values=True)['source-q'][0] + page.close() + report['checks'].append('Empty/nonempty source-q and actual source-section fragments demand the unchanged verifier initially') + page=browser.new_page();watch(page) + page.goto(origin+'compare.html');completed(page) + page.evaluate("location.hash='current-date-explanation'") + page.locator('#current-research[data-compare-source="ready"]').wait_for() + assert page.locator('#current-date-explanation').evaluate('e=>e.open') + page.close() + report['checks'].append('Later native source-fragment navigation opens its target disclosure and verifies source inventory') + # Fail only the optional source module; initial comparison remains admitted. + page=browser.new_page();watch(page) + page.route('**/current.mjs?*', lambda route: route.abort('failed')) + page.goto(origin+'compare.html');completed(page) + share=page.locator('#share').get_attribute('href') + page.goto(share);completed(page) + selected_query=urlsplit(page.url).query + page.locator('.current-source-details > summary').click() + page.locator('#current-research[data-compare-source="failed"]').wait_for() + assert page.locator('#compare-source-retry').is_visible() + assert page.locator('#compare-state').get_attribute('data-state') == 'completed' + assert page.locator('.current-search').is_disabled() + page.unroute('**/current.mjs?*') + page.locator('#compare-source-retry').click();completed(page) + page.locator('#current-research[data-compare-source="ready"]').wait_for() + assert urlsplit(page.url).query == selected_query + assert urlsplit(page.url).fragment == 'current-research' + page.close() + report['checks'].append('Optional-module import refusal stays visible and comparison intact; explicit reload retries with exact comparison selection retained') + # Payload corruption remains an unchanged source-verifier refusal. + page=browser.new_page();requests=watch(page) + page.goto(origin+'compare.html');completed(page) + def tamper(route): + response=route.fetch();body=bytearray(response.body());body[0]=ord('[') + route.fulfill(response=response,body=bytes(body)) + page.route('**/current.json*', tamper) + page.locator('.current-source-details > summary').click() + page.locator('#current-research[data-compare-source="failed"]').wait_for() + assert page.locator('.current-state').inner_text().startswith('Unavailable:') + assert page.locator('.current-search').is_disabled() + assert page.locator('#compare-state').get_attribute('data-state') == 'completed' + page.unroute('**/current.json*',tamper) + page.locator('#compare-source-retry').click();completed(page) + page.locator('#current-research[data-compare-source="ready"]').wait_for() + page.close() + report['checks'].append('Optional source payload corruption refuses without enabling search; explicit source reload recovers unchanged byte admission') + # Comparison Retry still reacquires its required metadata, registry and payload. + page=browser.new_page();requests=watch(page) + page.goto(origin+'compare.html');completed(page);requests.clear() + page.locator('#retry').click();completed(page) + assert any(urlsplit(u).path=='/current-meta.json' for u in requests) + assert any(urlsplit(u).path=='/snapshots/index.json' for u in requests) + assert len(current_requests(requests))==1 + assert len([u for u in requests if '/snapshots/' in u and u.endswith('/current.json')])==2 + assert page.locator('.current-search').is_disabled() + page.route('**/snapshots/*/current.json',lambda route:route.abort('failed')) + page.locator('#retry').click();page.locator('#compare-state[data-state="refused"]').wait_for() + for suffix in ['', '-top']: + assert page.locator('#pagination'+suffix).is_hidden() + assert page.locator('#next'+suffix).is_disabled() + page.close() + report['checks'].append('Comparison Retry freshly verifies metadata/registry/current/two archives; comparison refusal clears both pagers') + nojs=browser.new_page(java_script_enabled=False,viewport={'width':390,'height':844});nojs.goto(origin+'compare.html') + assert nojs.locator('#compare').is_disabled() + nojs.locator('.current-source-details > summary').click() + assert nojs.locator('.current-source-details a[href="current.json"]').is_visible() + assert nojs.locator('.current-state').inner_text().startswith('Pinned source observation:') + assert nojs.locator('noscript').first.is_visible() + nojs.close();report['checks'].append('No-JavaScript pinned source identities, exact payload and static inventory/history fallback retained') + assert not errors,errors + report['page_errors']=errors + browser.close() + except Exception as error: + report['failure']=str(error) + raise + finally: + server.shutdown();server.server_close() + (args.output/'report.json').write_text(json.dumps(report,indent=2)+'\n') + print(json.dumps(report,indent=2)) + +if __name__=='__main__':main() diff --git a/tools/reader_jump_browser_check.py b/tools/reader_jump_browser_check.py new file mode 100644 index 000000000..04e07a581 --- /dev/null +++ b/tools/reader_jump_browser_check.py @@ -0,0 +1,68 @@ +#!/usr/bin/env python3 +"""Native persistent navigation; emulated browser checks, not spoken AT evidence.""" +import argparse,json,shutil,traceback +from pathlib import Path +from research_desk_browser_check import serve,ROOT + +def main(): + ap=argparse.ArgumentParser();ap.add_argument('--output',type=Path,required=True);ap.add_argument('--browser',default=shutil.which('chromium'));ap.add_argument('--baseline',action='store_true');ap.add_argument('--origin');args=ap.parse_args();args.output.mkdir(parents=True,exist_ok=True) + from playwright.sync_api import sync_playwright,expect + report={'cases':[],'page_errors':[],'limits':'Headless Chromium/Linux, emulated widths; no physical/Safari/spoken AT/full WCAG claim.'} + def run(origin,browser): + for width,scheme in [(1440,'light'),(1440,'dark'),(390,'light'),(390,'dark'),(320,'dark')]: + c=browser.new_context(viewport={'width':width,'height':844},color_scheme=scheme,reduced_motion='reduce');c.route('https://**/*',lambda route:route.fallback() if route.request.url.startswith(origin) else route.abort());p=c.new_page();p.set_default_timeout(5000);p.on('pageerror',lambda e:report['page_errors'].append(str(e))) + row={'case':f'persistent-keyboard-{width}-{scheme}'};report['cases'].append(row) + try: + p.goto(origin+'workspace.html');assert p.locator('.reader-jump').count()==1,'Persistent Go to navigation is absent' + menu=p.locator('.reader-jump');summary=menu.locator('summary');p.evaluate('scrollTo(0,3000)');box=summary.bounding_box();assert box and 0<=box['y'] and box['y']+box['height']<=844 + summary.focus();p.keyboard.press('Space');expect(menu).to_have_attribute('open','') + nav=menu.locator('nav');box=nav.bounding_box();assert box and box['x']>=0 and box['y']>=0 and box['x']+box['width']<=width and box['y']+box['height']<=844 + if not args.baseline: + menu.locator('a').first.focus();p.keyboard.press('Escape');assert not menu.evaluate('(e)=>e.open');expect(summary).to_be_focused() + summary.press('Space');p.locator('#reading-list > summary').click();assert not menu.evaluate('(e)=>e.open');expect(p.locator('#reading-list > summary')).to_be_focused() + summary.press('Space');link=menu.get_by_role('link',name='Compare snapshots',exact=True);link.focus();p.keyboard.press('Enter');expect(p).to_have_url(origin+'compare.html');assert not p.locator('.reader-jump').evaluate('(e)=>e.open') + p.locator('.reader-jump > summary').click();p.locator('.reader-jump').get_by_role('link',name='Reading list',exact=True).click();expect(p).to_have_url(origin+'workspace.html#reading-list');expect(p.locator('#reading-list')).to_have_attribute('open','') + p.emulate_media(media='print');expect(p.locator('.reader-jump')).to_be_hidden();p.emulate_media(media='screen') + assert p.evaluate('document.documentElement.scrollWidth<=innerWidth') + p.locator('.reader-jump > summary').click();p.screenshot(path=str(args.output/f'menu-{width}-{scheme}.png')) + row['passed']=True + except Exception:row['passed']=False;row['error']=traceback.format_exc() + c.close() + if not args.baseline: + for scripted in [True,False]: + for scheme in ['light','dark']: + row={'case':f'focus-yield-{scheme}-'+('scripted' if scripted else 'native-no-js')};report['cases'].append(row) + c=browser.new_context(viewport={'width':320,'height':800},color_scheme=scheme,java_script_enabled=scripted);c.route('https://**/*',lambda route:route.fallback() if route.request.url.startswith(origin) else route.abort());p=c.new_page();p.set_default_timeout(5000);p.on('pageerror',lambda e:report['page_errors'].append(str(e))) + try: + p.goto(origin+('workspace.html' if scripted else 'formal.html')) + menu=p.locator('.reader-jump');summary=menu.locator('summary') + summary.focus();expect(summary).to_be_focused() + p.keyboard.press('Shift+Tab');assert not menu.evaluate('(e)=>e.contains(document.activeElement)') + assert p.evaluate('document.activeElement.matches(":focus-visible")') + assert menu.evaluate('(e)=>getComputedStyle(e).opacity')=='0','External visible focus must not be covered by the launcher' + assert menu.evaluate('(e)=>getComputedStyle(e).pointerEvents')=='none' + p.keyboard.press('Tab');expect(summary).to_be_focused();assert menu.evaluate('(e)=>getComputedStyle(e).opacity')=='1' + p.keyboard.press('Space');expect(menu).to_have_attribute('open','');p.keyboard.press('Tab');expect(menu.locator('a').first).to_be_focused();assert menu.evaluate('(e)=>getComputedStyle(e).opacity')=='1' + p.keyboard.press('Shift+Tab');expect(summary).to_be_focused();p.keyboard.press('Space');assert not menu.evaluate('(e)=>e.open') + summary.evaluate('(e)=>e.blur()');assert menu.evaluate('(e)=>getComputedStyle(e).opacity')=='1' + if scripted: + p.locator('#library-current-link').click() + field=p.locator('.current-search');field.click();expect(field).to_be_focused();assert menu.evaluate('(e)=>getComputedStyle(e).opacity')=='0' + field.evaluate('(e)=>e.blur()');assert menu.evaluate('(e)=>getComputedStyle(e).opacity')=='1' + row['passed']=True + except Exception:row['passed']=False;row['error']=traceback.format_exc() + c.close() + row={'case':'native-no-js-and-script-free-formal'};report['cases'].append(row) + c=browser.new_context(viewport={'width':390,'height':844},java_script_enabled=False);p=c.new_page() + try: + p.goto(origin+'formal.html');assert ' summary');summary.focus();p.keyboard.press('Space');expect(p.locator('.reader-jump nav')).to_be_visible();p.locator('.reader-jump').get_by_role('link',name='Compare snapshots',exact=True).click();expect(p).to_have_url(origin+'compare.html');p.locator('.reader-jump > summary').click();expect(p.locator('.reader-jump nav')).to_be_visible();row['passed']=True + except Exception:row['passed']=False;row['error']=traceback.format_exc() + c.close() + with sync_playwright() as pw: + b=pw.chromium.launch(executable_path=args.browser,chromium_sandbox=True);report['browser']=b.version + if args.origin:run(args.origin,b) + else: + with serve() as origin:run(origin,b) + b.close() + report['passed']=sum(c['passed'] for c in report['cases']);report['failed']=len(report['cases'])-report['passed'];(args.output/'report.json').write_text(json.dumps(report,indent=2)+'\n');print(json.dumps({k:report[k] for k in ['browser','passed','failed','page_errors']}));return 1 if report['failed'] or report['page_errors'] else 0 +if __name__=='__main__':raise SystemExit(main()) diff --git a/tools/snapshot_compare_browser_check.py b/tools/snapshot_compare_browser_check.py index 213969bdf..7ffd5c6bf 100644 --- a/tools/snapshot_compare_browser_check.py +++ b/tools/snapshot_compare_browser_check.py @@ -61,8 +61,11 @@ def log_message(self, *_args): for link in page.locator('body > header nav a').all(): assert link.bounding_box()['height'] >= 44 report['checks'].append('Shared shell, exact CSP, five primary links, 44px header targets, Research tools and 14-link footer map') - page.wait_for_function("!document.querySelector('#current-research .current-search').disabled") - report['checks'].append('Existing current loader initializes copied source inventory controls') + assert page.locator('#current-research .current-search').is_disabled() + assert 'pinned and unverified' in page.locator('#compare-source-note').inner_text() + page.locator('#current-research .current-source-details > summary').click() + page.wait_for_function("() => !document.querySelector('#current-research .current-search').disabled") + report['checks'].append('Separate source inventory stays pinned until requested; existing current loader then verifies and initializes controls') summary = page.locator('#comparison-summary').inner_text() assert 'Source commit pins' in summary and 'Source blob / byte identities' in summary report['actual_summary'] = summary