Repository navigation
Set a page of parts' header text from a fact only core reads, and take --lf-holds-parts out of the references - #7070
Merged
Merged
Conversation
…-holds-parts out of the references #7058 set the column's header text from the reading theme by asking main's --lf-holds-parts, and declared that property in packages.md so the theme could read it. That made a fact of one page shape part of the interface every package may rely on, where browser/AGENTS.md already says a width needs no token: a size query on the reader's container answers it. The header is now an inline-size container where layouts.css fixes it in the column, and the reading face sets prose in a box under 15rem wide at t-5/1.45 and an h1 there at t-3/1.25. The face's layer lets an eyebrow, a caption or a chip keep the size it sets for itself by specificity, which the theme's unlayered rule could not. A lede in such a box reverts to the face's size for the prose around it (revert-layer), or to the browser's on a page without the face. A page's own box that narrow gets the same. The reading theme no longer names a page of parts, nothing reads --lf-parts-title as a property, and packages.md keeps --lf-parts-title only as the anchor name tabs.css reads. Behaviour that changed: at phone width the header stacks full width, so its text takes the page's sizes again (h1 31px, lede 20px, a paragraph 17px), where #7058 had set them at the column's (20px, 14px, 14px). Probed the sparkjoy page with an eyebrow, a lede, a paragraph and a tag, and a 126-word lede, against main at 1280x720 and 1440x900 in Chromium and Firefox: every computed size and the header and list heights are equal on both arms. Ran test_theme_tokens.py, test_interact_layer.py, test_interact_document.py, the three page-of-parts tests in tests/browser/widgets/test_tabs.py and the page-of-parts test in tests/browser/test_render_pages.py. > _This was written by Claude Code on behalf of max-sixty_
leaf-agent
previously approved these changes
Nov 24, 2026
…'s width The header heads the column and shares the column's height with the list of parts, so its text is set small for that reason, not for being narrow. The size query on boxes under 15rem also reached a three-card options row in a reading column (207px of text per card, against the header's 200px), whose paragraphs fell from 17px to 14px beside a two-card row at 17px, and root-parts' 226px Workbench queue pane. No width parts the header from those. layouts.css again marks the header `--lf-parts-title: 1`, which inherits, and the reading face's narrow rule and the lede idiom ask that by a style query. The header is no longer a size container. Only core reads the property; packages.md keeps `--lf-parts-title` only as the anchor name tabs.css reads. Against this branch's parent (#7058's rules): review-parts and root-parts at 1440x900, 390x844 and 1280x720 in Chromium and Firefox show no pixel change; the header and hgroup boxes compute 17px where they computed 14px, and every element in them sets its own size. Three cards across keep 17px, and the Workbench pane's list and paragraph keep 17px, in both engines. On the sparkjoy copy (78- and 126-word ledes) at 1280x720, 1440x900 and 390x844 in both engines, header height, list room and the h1, lede, paragraph, eyebrow and tag sizes are equal. Ran test_theme_tokens.py, test_interact_layer.py and test_interact_document.py. > _This was written by Claude Code on behalf of max-sixty_
leaf-agent
previously approved these changes
Nov 24, 2026
max-sixty
added a commit
that referenced
this pull request
Nov 24, 2026
… Layout `parts-in-layout` is advice, not a refusal (#6641): a `main` that carries a Layout may hold parts, and they draw as a strip of tabs inside that Layout. The previous commit dropped layouts.css's guards on that premise and is reverted, and tabs.css's `body > main > lf-parts` root had dropped the package's guard the same way, so on such a page the list drew as a centred column of names with a rule beside the part (720x188 where #7070 draws a 720x47 row, Chromium and Firefox). The parts' holder now asks its `main` whether it carries a Layout, by the declared `--lf-layout-box`, which doesn't inherit, so only `main`'s children can ask. Where it carries none, the holder sets `--lf-parts-column: 1`, the package's own, and the list's look, the parts' rule and the holder's ::before ask that, since a style query asks only an element's parent or, for a pseudo-element, its originating element (probed in both engines). No rule in the package names a Layout, and packages.md gains no name. The property starts with `--lf-` as every property a shipped sheet declares must (test_every_property_leaf_declares_is_named_as_leaf_s); only the package names it, so it is the package's own. Parts in a `main class="layout-column"` (root-parts' markup) draw a 720x47 strip at 1440x900 and a 342x47 strip at 390x844, as on #7070, in Chromium and Firefox. review-parts and root-parts at 1440x900, 390x844 and 1280x720 in both engines are unchanged against #7070 in pixels and computed styles. test_interact_layer.py, test_theme_tokens.py and test_interact_document.py: 408 passed. > _This was written by Claude Code on behalf of max-sixty_
leaf-agent
approved these changes
Nov 27, 2026
Comment on lines
+613
to
+614
| * names, and its title at a section heading's. An eyebrow, a caption or a chip keeps | ||
| * the size it sets for itself, by its rule's weight in this layer. The Layout's |
Collaborator
There was a problem hiding this comment.
An eyebrow keeps its size because of its layer, not its weight. The page's own sheet, lf-idioms and a theme's rules all outrank lf-reading-face whatever their weight (this file's header: "Every other rule of the tier outranks them whatever its weight"), and no eyebrow rule stands in this layer. As written, the comment tells the next reader that a heavier selector inside the face is what protects an eyebrow.
Suggested change
| * names, and its title at a section heading's. An eyebrow, a caption or a chip keeps | |
| * the size it sets for itself, by its rule's weight in this layer. The Layout's | |
| * names, and its title at a section heading's. An eyebrow, a caption or a chip keeps | |
| * the size it sets for itself, since any rule outside this layer outranks the face's. The Layout's |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#7058 set a page of parts' header text from the reading theme by asking
main's--lf-holds-parts, and declared that property inpackages.mdso a theme could read it. That put one page shape's layout into the interface every package may rely on. Now the kernel's reading face sets it, by a style query on the--lf-parts-title: 1thatlayouts.cssalready sets on the header: what the header holds at the list's size (t-5/1.45), its title at t-3/1.25. An eyebrow and a tag keep their own sizes. Only core reads the property. The reading theme no longer names a page of parts, andpackages.mddrops--lf-holds-partsand keeps--lf-parts-titleonly as the anchor nametabs.cssreads.To weigh:
reading.cssrecords the rejected first version, a size query on boxes under 15rem. Three option cards across a reading column hold 207px of text and the header 200px, so no width separates them. Text written straight in the header, outside a paragraph, list or heading, now takes the body's size.No pixel change on
review-partsandroot-partsat 1440×900, 390×844 and 1280×720 in Chromium and Firefox. Header height and type sizes are equal on a 78-word and a 126-word lede. Tests:test_theme_tokens.py,test_interact_layer.py,test_interact_document.py.