Skip to content

Drop offers from paper in shadow trees too, from one rule in state.css - #2899

Merged
max-sixty merged 2 commits into
mainfrom
slim-css
Oct 14, 2026
Merged

max-sixty merged 2 commits into
mainfrom
slim-css

Conversation

@max-sixty

Copy link
Copy Markdown
Owner

The print rule that drops a widget's injected controls ([data-lf-offer]) lived in chrome.css, which only the document adopts. As a result the two shadow-tree widgets, lf-diff and lf-file-editor, either restated it or printed their controls. The rule now lives once in state.css, which the document and every shadow stage both read. It is important in the top tier, so it outranks every ordinary display rule and still yields to a widget's own important print rule, as the unlayered chrome copy did.

That deletes the diff's print hides for its tools, file actions and comment presses, code-copy's print hide, and the thread rule's hides for reply rows and comment boxes.

The file editor used offer() for its stage, mounts, header and comparison pane, so the shared rule would have dropped the file itself from paper. Those are plain elements now. The diff's file-action bar was a box of presses marked by hand, and is now an offer.

Behavior changes on paper:

  • A file editor no longer prints its status line ("Unavailable · Retry").
  • A resolved thread group prints open, with its summary line, in the document as well as in a diff.

The screen is unchanged: the computed faces and geometry of the editor and diff elements were compared against base. A new test, test_paper_keeps_the_files_words_and_drops_the_editors_controls, fails when the editor's file area is an offer again.

This was written by Claude Code on behalf of max-sixty

max-sixty and others added 2 commits October 14, 2026 14:03
The print rule that drops a widget's injected controls lived in chrome.css,
which only the document adopts, so lf-diff and lf-file-editor (declared
shadow trees) each restated it or printed their controls.

It now lives in state.css, which both the document and every shadow stage
read, important in the top tier: it outranks every ordinary display and still
yields to a widget's own important print rule, as the unlayered chrome copy
did. Deleted: the diff's hides for its tools, file actions and comment presses,
code-copy's print hide, and the thread rule's hides for reply rows and comment
boxes, which are offers.

The file editor built its stage, editor mounts, header and comparison pane as
offers, so the shared rule would have dropped the file from paper. They are
plain elements now: the file's name, its lines and an open comparison print;
its status and controls do not. The diff's file-action bar, a box of presses it
marked by hand, is an offer.

Behavior changes on paper:
- a file editor no longer prints its status line ("Unavailable · Retry");
- a resolved thread group prints open, with its summary line, in the document
  as it already did in a diff (the thread print rule now names the group).

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
@max-sixty
max-sixty merged commit be84e0d into main Oct 14, 2026
3 checks passed
@max-sixty
max-sixty deleted the slim-css branch October 14, 2026 21:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants