Skip to content

Take the solid accent fill off every pressable - #803

Merged
max-sixty merged 3 commits into
mainfrom
subtle-buttons
Sep 18, 2026
Merged

max-sixty merged 3 commits into
mainfrom
subtle-buttons

Conversation

@max-sixty

Copy link
Copy Markdown
Owner

The send disc, the banner's Approve, and the visual-review's chosen verdict all wore the accent as a solid fill with paper text, which read as the loudest thing on the page. A pressable now carries the accent as its ink and hairline only, and a tint rises under it on hover.

  • The send button is a bare accent glyph whose 28px disc stays clear at rest and takes --accent-tint on hover. Send and resolve now share one glyph-action rule and differ only in their inks and tints.
  • .lf-btn.primary is accent ink on the ordinary card under a softened accent hairline, with the tint as its hover, a step apart from the .lf-btn.on toggle face.
  • The visual-review's chosen disposition restates .lf-btn.on instead of filling with the accent.

--accent-tint is the one token both hovers spend. The gate test that named a deliberately absent --accent-tint in a diagram now names --accent-glow, and the sign-off face test asserts accent ink on the card rather than paper on the accent. A dead border-color on the resolving thread's clear disc goes with it.

Left as it was: the diff package's hover-revealed line-comment +, which is a gutter affordance rather than an action face.

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

🤖 Generated with Claude Code

max-sixty and others added 2 commits September 18, 2026 12:42
The send disc, the banner's Approve, and the visual-review's chosen
verdict all wore the accent as a solid fill with paper text, which read
as the loudest thing on the page. A pressable now carries the accent as
its ink and hairline only, and a tint rises under it on hover:

- the send button is a bare accent glyph whose 28px disc stays clear at
  rest and takes --accent-tint on hover; send and resolve now share one
  glyph-action rule and differ only in their inks and tints;
- .lf-btn.primary is accent ink on the ordinary card under a softened
  accent hairline, with the tint as its hover, a step apart from the
  .lf-btn.on toggle face;
- the visual-review's chosen disposition restates .lf-btn.on instead of
  filling with the accent.

--accent-tint is the one token both hovers spend. The gate test that
named a deliberately absent --accent-tint in a diagram now names
--accent-glow, and the sign-off face test asserts accent ink on the card
rather than paper on the accent. A dead border-color on the resolving
thread's clear disc goes with it.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
# Conflicts:
#	skills/leaf/assets/theme.css

@leaf-agent leaf-agent left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The face change itself lands cleanly — the send/resolve glyph actions now share one
rule, the disabled and hover paths still resolve to the same computed values the
::before contracts assert, and --accent-tint keeps 5.9:1 or better against
--accent in both schemes. The everyday gate is green and test_render_gate.py
passes locally on the renamed --accent-glow probe.

One thing the diff states that the layer contradicts: the accent-ink-and-border
face is already taken, in the same row, by a different meaning.
chrome.css gives
.lf-banner-more[data-lf-news] and :is(.lf-banner-actions, .lf-banner-menu) > .lf-version[data-lf-news] border-color: var(--accent); color: var(--accent), and
names it there as "the same border-and-ink vocabulary as a folded-news door." After
this PR .lf-btn.primary is that vocabulary at a weaker border, and both controls
live in .lf-banner-actions — lf-btn primary lf-signoff from banner.js beside
lf-btn lf-version from version-chooser.js, which carries data-lf-news whenever
the page is pinned or deferred. So on a pinned page offering sign-off, Approve and
the Versions door both read as accent-on-neutral, and the news door wears the full
accent border while the commitment wears 45% of one.

That makes the new comment's claim — "the one control in its row drawn in the
accent" — false, and the test docstring repeats it. The claim is the part worth
fixing: it is what a later reader will reason from when they add the next accent
control. Suggestions inline reword both to say what actually separates the two
faces (the card ground, which the news doors clear). If you would rather keep the
claim and make it true, the other route is to give the commitment the tint as its
resting ground rather than only on hover, so a commitment and a news door differ by
ground instead of by border weight.

Separately, outside the diff: the comment above sendBtn.classList.add(...) in
skills/leaf/assets/runtime/composing/input.js still explains why a send press never
wears primary with "primary is a different face: it fills the press's own box" —
the fill it names is what this PR removed. The geometric point it is making (the box
is the hit target and stands larger than the disc) still holds; only the wording is
stale. Happy to push that one-line fix if you want it in this PR.

Comment thread skills/leaf/assets/theme.css Resolved
Comment thread tests/test_chrome_contracts.py Resolved
The comment on .lf-btn.primary called it the row's only accent face,
which chrome.css contradicts: a folded-news door and a pinned Versions
door wear a full accent border on no ground. What separates the
commitment is the card ground. The sign-off test's docstring repeats
only what its assertion reads, and the send-press comment in input.js
no longer describes primary as a fill.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
@max-sixty
max-sixty merged commit 84136d1 into main Sep 18, 2026
7 checks passed
@max-sixty
max-sixty deleted the subtle-buttons branch September 18, 2026 20:52
max-sixty added a commit that referenced this pull request Sep 18, 2026
The `+` a diff line reveals on hover was the last pressable still filled
with the accent, against the rule the theme states beside --accent-tint.
It now wears the tint as its ground, the accent as its ink, and a
softened accent hairline. The old face also lost its glyph when the
pointer reached the button: .lf-btn's hover swapped the ground for the
chip and left the ink on paper.

The catalog stills are recaptured because #803 changed a first viewport:
release-notes and triage-board carry no open Ask, so their banner shows
Approve enabled. example-previews.json pins max-sixty/leaf-assets at
bf3106b2, and the two docs pages take the new media paths.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
max-sixty pushed a commit that referenced this pull request Sep 18, 2026
…ill expect the solid accent fill (#814)

`nightly` on main failed in [run
35397355730](https://github.com/max-sixty/leaf/actions/runs/35397355730)
with four cases, and all four are the same fact: the send press no
longer wears a solid accent fill, and two nightly tests still assert
that it does.
[`84136d1`](84136d1)
(#803) made `.lf-compose-submit` a bare accent glyph over a 28px disc
that stays clear at rest and takes `--accent-tint` under the pointer,
and it moved the assertions in the everyday gate with it. The two that
read the same face in `tests/test_render_drafts.py` and
`tests/test_render_options_addition.py` are `nightly`-marked, so no pull
request ran them; main holds one nightly slot, and the first one to
complete after that merge was
[`bdf581c`](bdf581c9f2a85f566a5ebcb79aecba4a48e25060)'s.
The product is right and the tests are stale.

Both now read the face through one `glyph_action_face` helper beside
`token_colour` and `button_radius`, and assert the shipped contract at
rest and under the pointer, so the next move of this face has one
reading to change rather than two hand-written `getComputedStyle` blocks
that drifted apart.

What each assertion was holding is kept, restated against the current
face:

- **The press paints nothing of its own.** `press` is still transparent
at rest, still transparent on hover, and still transparent once
`--aim-floor` widens the hit box to 44px — that last one is the claim
the coarse-pointer section makes, and it now reads a press at rest
because the pointer is moved off first.
- **The disc is the whole of the paint, at a size the hit box does not
change.** It is clear at rest, `--accent-tint` on hover, and 28px in
every reading.
- **The add press is not the pick mark's circle.** Unchanged: the disc
takes the shared margin entry corner, not `50%`.
- **The glyph outranks the `.lf-ui` ink.** The old form asserted
paper-on-accent, which proved it incidentally. It is now stated directly
— the glyph is `--accent` and is *not* `--ink`, which is what the rule
it outranks would have drawn.

One observation rather than a request: a theme change reaches these
faces only through nightly, so its author gets no signal until main has
already moved. Every other `--accent` assertion in `tests/` survived
#803, so this was the whole of the exposure this time.

<details><summary>Reproduction and verification</summary>

The four cases fail locally at the run's head with CI's exact diffs —
`assert 'rgb(47, 84, 128)' == 'rgb(250, 249, 245)'` for the three
composer parametrizations, and `assert 'rgba(0, 0, 0, 0)' != 'rgba(0, 0,
0, 0)'` for the add field, which is the disc having gone clear.

- `uv run pytest tests/test_render_options_addition.py
tests/test_render_drafts.py` — 92 passed, both files complete
- The four repaired cases re-run green on this branch's base,
[`f56b814`](f56b814)
- `uv run pre-commit run --files tests/render_cases_layout.py
tests/test_render_drafts.py tests/test_render_options_addition.py`

</details>

Co-authored-by: leaf-agent <[email protected]>
max-sixty added a commit that referenced this pull request Sep 18, 2026
… out (#816)

A slot was a page directory plus three files beside it: the watcher's
identity and stop flag in `<slot>.preview.json`, the lease `--stop`
waits on, and a second lock serializing writes to that flag. The two
locks sat next to what they guard, which is why a discard could not
remove them — a `--reset` that unlinked the lease would hand a waiting
`--stop` an inode excluding nobody, and that stop would then take down
the server the reset had just started. `leaf.leases` already keeps a
stable per-path lock in the state home for exactly this reason, and the
page's own transition lease is one, so both of a slot's locks are page
locks now.

The stop flag is gone with them. `--stop` holds its request open for as
long as it waits, so the watcher reads it between passes and wherever it
would bring the server back up, an update in flight finishes, and its
pending restart is suppressed — the guarantee the flag was for, minus
the file, the lock that protected it, and the case where a watcher
starting after the flag was written overwrote it and left the stop
waiting forever. With one writer left, the watcher's own, the identity
moves into the page's `preview.json` beside the fields the browser
chrome shows: the slot's whole record in one file the discard already
removes, and `.tmp/previews` is empty after one. `preview_metadata`
projects the named safe fields, so the checkout and fixture paths in
that record reach no browser, which is what `page-storage.md` already
said the server does.

`PreviewService` owns the one difference between a reader preview's
durable claimed service and an automation preview's process-owned
temporary server. The watch loop branched on it seven times and now
states what it wants — stop, refresh, start — without knowing which kind
it has.

`lock_is_held` asks with a shared lock. An exclusive probe is refused by
another probe as readily as by a lease, so two processes reading at once
told each other a lease was held.

One bug found while testing this, and older than it: `watchfiles` starts
its rust watcher on the subscription's first read, and the read the
preview's loop makes comes after it has announced its URL. The edit a
developer makes the moment that URL appears landed in a window nothing
was watching — measured on the parent commit, six of six such edits were
lost, and none of six are now. That is also what made
`test_a_detached_preview_restarts_under_its_original_codex_claim` and
`test_stopping_a_preview_waits_for_its_active_recompose` fail under
load: both edit an input the instant the preview reports ready.
`watch_changes` reads once before it returns and hands that batch on as
its caller's first.

Three test assertions moved with the state they read: the lease and the
stop request are read as locks, the fixture requires the directory it
swept to be clean, and the released detached watcher is asked for the
record that lets a later start resume rather than for a flag saying it
stopped.

## Verified

- `uv run pytest tests --run-nightly` — 2728 passed, 4 failed. All four
—
`test_render_drafts.py::test_a_single_space_is_message_content_in_every_composer`
(reply, general, composer) and
`test_render_options_addition.py::test_the_add_field_previews_the_option_it_will_make`
— fail identically on the merge base 9e5e0d3 with no branch in play:
they assert a press face or preview disc differs from its transparent
button, and #803 made both transparent.
- `uv run pytest tests` — 1145 passed. `uv run pre-commit run
--all-files` clean.
- The startup window, measured with a probe that starts a background
preview and writes the source the instant the command returns: 0 of 6
edits reached the page on d264163, 6 of 6 here.
`test_a_watch_subscription_collects_before_its_first_read` is the
bug-back — red on the merge base, green here.
- Five rounds of the two load-sensitive preview tests against five on
the merge base, launched together: 5 green here, 4 green and 1 red
there.
- By hand: start, repeat start (same URL, joins the running watcher),
`--stop`, `--reset --background`, discard — after which `.tmp/previews`
holds nothing.

> _This was written by Claude Code on behalf of @max-sixty_

Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
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