π€ GPT-6-Astra (Codex), reviewing for session 21a32889.
VERDICT: CHANGES-REQUIRED β needs changes.
I read #26 first and reviewed the whole branch at aab5e141024bc9fadc1b9643212672b7842e12da against fetched origin/main (f14458a4683cf73b654cb45c79c053dcf2752e5f). Review used the detached scratch worktree /tmp/estilo-review-21a32889. No tracked files were edited; mutations used Go -overlay files outside the worktree. No commit, push, merge or deploy.
- P1 β
theme/fonts.go:54: optional + preload does not meet the no-invisible-text rule across engines. Chromium's render hold is useful, but it is not a cross-engine guarantee. I reproduced painted page content with invisible chrome text in WebKit. In a native macOS WKWebView using this branch's actualFontHead(),FontHandler()and theme, with page JavaScript disabled and the font delayed 3.5 s, screenshots at 338 ms and 383 ms after navigation show the green page marker and system-font control while both chrome text rows have zero dark pixels. At 428 ms the rows become visible in fallback and remain unchanged through font arrival. This is exactly the visible gap Paul disallowed. WebKit's implementation explicitly assigns optional a 0.1 s block period and zero swap period (source). The branch must not record this mechanism as satisfying the rule in AGENTS.md row 9 or recommend accepting this residual without resolving the requirement. Suggested fix: use the system UI stack for chrome, without a downloadable chrome face, preload or font-loading gate. That is scriptless and removes both the font-loading invisible interval and late swap in all three engines. If retaining Onest is mandatory, resolve that design tradeoff explicitly; optional alone cannot deliver both promises.
- P2 β
theme/fontflash.browser.mjs:53andtheme/fonts_browser_test.go:175: the browser test does not establish that text was visible.CSS.getPlatformFontsForNodereports fonts used for text layout even when the glyph color is transparent. An rAF callback is also not proof that text pixels have been painted, and the Go reducer discards empty font samples. My mutation added only this CSS to the existing probe:#bar, #nav { animation: hide-text 1s step-end; } @keyframes hide-text { from { color: transparent; } to { color: inherit; } }. The browser test still passed all six visits, including samples inside the invisible second. By comparison, actualswapandblockmutations each failed at both slow delays, and the ordinary optional-only unit test rejectedswap. So the swap check works; the claimed invisible-text check does not. Suggested fix: add pixel/frame assertions showing the chrome text is present whenever the surrounding chrome first paints, retain the font-identity assertions, and cover WebKit and Firefox. Include an invisible-text negative control. Do not wait fordocument.fonts.readybefore capturing the initial frames; Playwright screenshots normally do that and can hide the defect.
- P2 β
theme/fonts.go:23andtheme/fonts_test.go:79: the version bump unnecessarily removes old assets. Both/static/estilo/fonts/v1/fonts.cssand/static/estilo/fonts/v1/onest-latin.woff2return 404, verified against the branch handler. Changing the new stylesheet URL is correct for escaping immutable cached CSS; deleting the previous URLs is a separate compatibility break. Old HTML/static consumers lose Onest, and a cached v1 stylesheet whose font has been evicted still requests the now-missing v1 font. Fully cached clients behave differently. Suggested fix: retain the original v1 assets and their original bytes, mount both versions during migration, and replace the 404 assertion with compatibility assertions. Point new markup at v2 (or the chosen replacement design). Keeping v1 does not itself fix old cachedswappages, but deleting it does not reliably migrate those pages either.
The head partial itself is correct: preload precedes the stylesheet, the URL/type match the font, crossorigin supplies the required request mode, it needs no data or script, and the partial-equals-FontHead() test passes. I found no separate partial defect.
Browser evidence and limits:
| Engine | What I ran and observed | |---|---| | Chromium | Required browser suite passed with Chrome for Testing 152.0.7977.54. The separate scriptless Playwright probe on Chromium 151.0.7922.34 showed visible, stable fallback from its first captured content frame. | | WebKit | Playwright 1.62.1, WebKit 26.5, launched successfully. Its probe showed invisible rows until the delayed font arrived, about 3.5 s, with scripts both off and on. That timing differs from normal WebKit's 100 ms setting, so I am not presenting it as Safari's exact duration. I therefore also ran the native macOS WebKit probe above (installed WebKit 22625, Safari reports 27.0), which independently confirmed the brief visible gap. This native probe is WKWebView, not Safari browser automation. | | Firefox | Installed Playwright Firefox 153.0 / revision 1538 and tried headless, headed, and a launch with per-process sandbox-disable environment variables. All timed out before an automated page was available; logs include sandbox_extension_issue_file_to_process ... Operation not permitted and a headless SWGL framebuffer error. No Firefox runtime result claimed. Mozilla's font loader and default preference specify the 100 ms short delay and optional timeout. This is source evidence for the risk, not a measured Firefox screenshot here. |
The distinction is documented by Chromium itself: preloading optional fonts eliminates the invisible first render through a Chrome-specific rendering optimization. Browser support for the two individual features does not establish identical first-paint behavior.
Validation: GOTOOLCHAIN=go1.26.5 make test PASS; GOTOOLCHAIN=go1.26.5 make test-browser PASS on the unmodified branch. swap mutation FAIL as expected; block mutation FAIL as expected; one-second transparent-text mutation PASS (false green). Scratch worktree remains clean. Logs, overlay files, standalone probe servers/drivers, and native/Playwright screenshots are retained in /tmp/estilo-font-review/; the native gap is visible in native-001.png and native-002.png, followed by text in native-003.png.