Repository navigation
fix(cli): check no longer reports outline text as not painted - #6693
Conversation
There was a problem hiding this comment.
Verdict: APPROVE · 0 blocker · 0 important · 0 nits · head 8103b20f
Scope
Read both files. Checked the fails-without-fix claim locally (Chromium 1237): with main's layout-audit.browser.js, "judges outline text (transparent fill, visible stroke) by what it paints" fails with expected true to be false and the 3 transparent rows pass. With this head, all 73 tests in the file pass. The stroke check is safe when no stroke is set: -webkit-text-stroke-color computes from currentcolor, so a transparent color with no stroke colour still reads as transparent and is still reported. invisibleTextIssue has a single caller, and no other audit depends on it. CI, Comments, CodeQL, regression and Windows render verification are all green on this head.
What changed
checkreportedtext_not_paintedon outline text:color: transparentwith-webkit-text-stroke: 2px. The glyphs paint (the stroke), but the rule read only the fill. A visible stroke (width above 0, alpha above 0.05) now counts as paint; transparent text with no stroke, a zero-width stroke or a transparent stroke is still reported.What I measured
Real Chrome (headless shell 152), the audit script on a 1920x1080 composition with one
h1. On hyperframes 0.8.214 the outline case reportstext_not_painted; with this change it does not. Thelayout-auditChromium file passes, 73 tests.fails without the fix: judges outline text (transparent fill, visible stroke) by what it paints
Red on main (
expected true to be false), green here; the three transparent-text rows pass on both.What I did NOT exercise
snapshoton exact frame boundaries) are separate.Why under 100 lines
One condition and one test table, 30 lines.