diff --git a/docs/output.md b/docs/output.md index 4c5d992..fb18b49 100644 --- a/docs/output.md +++ b/docs/output.md @@ -61,6 +61,7 @@ the per-shot output when piped, `--no-progress` the summary on a terminal. | `1 accepted` | That many of the shot's changes are accepted; the rest are new. | | `findings: N repeated on 2+ routes` | After the routes: the same `dom` entry, text line, `fonts` face or element-less band delta (`band -24px`) on two or more routes, once per line with `×N routes` and where (`/a@1440,375`, then `+N routes`), most widespread first, accepted ones aside. Top 20; `summary.findings` in results.json has them all. One cause behind many rows: fix it once. A selector names an element per page, so the same path may be a different element on another route: check one crop. | | `computed: N findings` | With `--computed`: each `key prop left→right` once, with the routes and widths it was seen at; `dom identical`: the markup matches apart from asset hashes and generated class names, so look at CSS or script. See [below](#computed-styles---computed). | +| `rules: N changed groups` | With `--computed`: style rules only one side has, by stylesheet and `@media`, and whether any shot had an element they could style. `matched nothing`: the run proved nothing about those rules. See [below](#rule-coverage). | | `aria: identical on N of M route(s)` | With `--aria`: routes whose accessibility tree matches at every width, then each differing route's lines, `+` left only, `-` right only. See [below](#aria-snapshots---aria). | | `crops …` | Up to 3 PNGs per comparison, bands first, relative to `results.json`. Left is on top or on the left, and the change is boxed in red. | | `ERROR …` | Unmeasured, which is neither a pass nor a fail. Exits 3. | @@ -263,6 +264,43 @@ Links and controls (`a[href]`, `button`, `input`, `select`, `textarea`, `summary (`ul:has(a:hover) a:not(:hover)`) isn't seen, nor `:hover` on an ancestor (`li:hover` menus), `:active`, `:focus-within` or script hover handlers. +### Rule coverage + +A clean run doesn't show that a changed rule ever applied. So `--computed` also reads every +style rule in each side's stylesheets and lists the groups of rules only one side has: + +``` +rules: 3 changed groups, 1 never matched, 2 matched on some shots + +chat.css (1 rule) matched nothing: /help@1440,375 + +docs.css @media (width >= 60em) (5 rules) matched /a@960,1440 /b@960; nothing /a@959,375 + -docs.css @media (min-width: 60em) (5 rules) matched /a@960,1440 /b@960; nothing /a@959,375 +``` + +- A rule is its enclosing at-rules, selector (nesting resolved) and declarations, as Chrome + serializes them. So pure notation changes Chrome normalizes (`rgb(0 0 0)` and + `rgb(0, 0, 0)`) are no change, while `min-width:` against `width >=` is. Asset hashes in + `url()` and the left origin are read as on the other side. A rule moved to another file is + no change. Only style rules count: not `@font-face`, `@keyframes` or `@property`. +- `+` rules only the left (your change) has, `-` only the right. A group is a stylesheet's file + name (asset hash as `#`; a ` + +
+The two sides write one breakpoint in different notation and render the same, so only rule coverage tells the rewritten rule apart, and whether any shot reached it.
+ +At 960 the breakpoint holds and its rule styles three items; at 959 it styles none. A rule for an element no page has matches nothing on any shot.
+