Repository navigation
Explain where CSS overrides go, and fix two rules that matched nothing - #2796
Merged
Merged
Conversation
How it Works gains "Styles and overrides" on its Pages tab: a figure of the
cascade tiers in the document and in a widget's shadow tree, and where a page,
a Layout change, and a widget or package override go and what each can reach.
The claims were checked by probing rendered pages.
The survey found two rules that silently did nothing:
- The site package set `body.site-page main { padding-top: 28px }`, which the
column Layout's padding in `lf-layouts` has outranked since Layouts moved
above `lf-base`, so site pages started 72px down. It now sets the
`--page-pad-start` token the Layout reads, and the pages start 28px down
again, as the rule's comment intended.
- The extension guide's package CSS began `lf-callout {`, which matches
nothing because composition scopes a widget package's sheet to its tags and
a type selector inside `@scope` does not match the root. It now uses
`:scope`.
packages.md lists the page geometry inputs Layouts read among the theme
inputs, and says a package that declares widgets reaches only inside them.
page-authoring.md's example selector `lf-board .lf-btn` matched no control;
it is now `lf-board .lf-grip`.
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
previously approved these changes
Oct 14, 2026
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
approved these changes
Oct 14, 2026
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.
How it Works gains "Styles and overrides" on its Pages tab: a figure of the cascade tiers in the document and in a widget's shadow tree, then where CSS goes to override something for one page, for a Layout, and for a widget or package, and what each place can and cannot reach. Every claim was checked by probing rendered pages built from this tree.
The survey found two rules that silently did nothing:
body.site-page main { padding-top: 28px }has lost to the column Layout's padding inlf-layoutssince Layouts moved abovelf-base(Arrange pages with Layout classes, and let margins claim nothing #1246), so site pages started 72px down. It now sets the--page-pad-starttoken the Layout reads; pages start 28px down, as the rule's comment intended.lf-callout {, which matches nothing: composition scopes a widget package's sheet to its tags, and a type selector inside@scopedoes not match the root. It now uses:scope.packages.mdadds the page geometry inputs Layouts read (--col,--wide,--sidebar,--page-pad-*) to its theme inputs and says a package that declares widgets reaches only inside them.page-authoring.md's example selectorlf-board .lf-btnmatched no control; it is nowlf-board .lf-grip.