Skip to content

Refine conversation hierarchy and activity status - #671

Merged
max-sixty merged 22 commits into
mainfrom
codex/ui-precision
Sep 13, 2026
Merged

max-sixty merged 22 commits into
mainfrom
codex/ui-precision

Conversation

@max-sixty

@max-sixty max-sixty commented Sep 13, 2026 •

Copy link
Copy Markdown
Owner

The conversation surfaces had the right restraint, but weak hierarchy made filters, thread context, replies, and agent activity compete for attention. This change gives Threads and anchored conversations a calmer, stable reading structure: filters disclose on demand with an explicit active-view summary, speaker and quoted-passage hierarchy is clearer, long replies remain usable inside the viewport, and the banner keeps a concise status line with the complete activity reading available through an accessible disclosure.

It also refreshes the recorded website media and records the remaining region-placement and cross-journey coherence work in TODO.md.

Validation:

  • uv run pre-commit run --all-files
  • uv run pytest tests (1043 passed)
  • uv run pytest -n 2 tests/test_render_controls.py (104 passed)
  • bin/leaf version check --render .tmp/previews/ui-precision-candidate
  • matched main/candidate Chrome review at 1440×1000, plus candidate filtering at 540×720; clean consoles

This was written by Codex on behalf of max-sixty

# Conflicts:
#	skills/leaf/assets/runtime/banner.js
#	skills/leaf/assets/runtime/chrome.css
#	skills/leaf/assets/theme.css
#	skills/leaf/packages/default/theme.css
#	skills/leaf/scripts/leaf/render-checks/standalone.js
#	skills/leaf/scripts/leaf/render_gate/scheme.py
#	tests/test_render_controls.py
#	tests/test_render_gate.py
#	tests/test_website_server.py

@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.

Putting the thread panel's facets behind a default-closed disclosure takes .lf-needs and [data-filter-value=...] out of the rendered page, and three cases in tests/test_render_controls.py reach them without opening Filters first. They fail on this head and pass on the merge base (d9695e6e), so the branch owns them:

case how it breaks
test_banner_status_is_compact_with_accessible_details the Tab walk that proves a version menu closes when native focus leaves it uses .lf-needs as its destination — AssertionError: native Tab never reached the pending-reader panel control
test_covering_threads_keeps_the_reader_and_their_work_inside open_filter.focus() on [data-filter-value="open"] is a no-op while the facet is display: none — Locator expected to be focused / Actual value: inactive
test_every_ring_the_layer_draws_is_shown_whole_somewhere_in_the_corpus the the page ring scope selects Resolved before walking; resolved.is_enabled() is still true behind the closed disclosure, so the click waits out its 30s timeout

The repair is the one the diff already applies in the other eight files — press .lf-thread-filter-toggle before reaching a facet — except in the second case, where open_filter.focus() needs the disclosure open before the focus call rather than a click. All three sit outside this diff's hunks, so I can't leave them as inline suggestions; say the word and I'll push the commit.

Worth knowing why the gate is quiet about this: test_render_*.py carries pytestmark = pytest.mark.nightly, and broad discovery deselects nightly, so uv run pytest tests — the PR's test job and the command in the description — never ran any of the render files this PR edits. The reds surface on the daily nightly job after merge.

Verification
# this head (bc2a805)
tests/test_render_controls.py: 3 failed, 101 passed
# merge base d9695e6e, same three cases
2 passed  (+ test_banner_status_is_one_line_with_full_hover_text, 1 passed)

The rest of the changed render surface is green here: test_render_conversations.py, test_render_reactions.py, test_render_projection.py, test_render_navigation.py, test_render_margin.py, test_render_widgets.py (edited cases, 37 passed) and test_render_startup.py (whole file, 94 passed).

@max-sixty
max-sixty merged commit 9a9a073 into main Sep 13, 2026
7 checks passed
@max-sixty
max-sixty deleted the codex/ui-precision branch September 13, 2026 08:23
max-sixty added a commit that referenced this pull request Sep 17, 2026
The banner said `Claude working` and kept what the agent was doing
behind a disclosure, so a reader watching a long piece of work saw one
word change for its whole length. Under a Codex App Server it said
something more detailed and less useful — `Running pytest -q tests/…` —
because streamed tool steps outranked the agent's own declaration. Both
are now the same reading on every host: the row carries the agent's
sentence, dated once the claim is older than "just now", and the watched
step stands beside it in the status disclosure.

## The banner row

`Claude working — running the browser suite`, and `Claude working · 5m
ago — running the browser suite` once the claim has aged. The date goes
before the detail because the detail is what the ellipsis eats first,
and a stale sentence with its date cut off is the one reading that row
must not give. #671 had moved the detail into the disclosure four days
ago for a calmer banner; this reverses that for `working` and leaves the
complete wording in the disclosure.

## What the work is, versus that it is happening

A watched tool step proves a session is alive and moving, which is why
it can still make a page `working` over a declaration that says
otherwise. It cannot say what the reader is waiting for. So a current
`working` declaration keeps the reading's sentence and its own date, and
the step is reported as `observed` — under a working reading alone,
since a step beside "last checked in 30m ago" would argue with the amber
dot that reading wears.

A declaration takes the sentence only when it has words: `leaf status
<page> working` with no detail says that work is happening and nothing
more, which a watched step says better. `delivery claim` called with no
detail writes one of Leaf's own, so a taken-up move says so at once.
That wording is not the agent's sentence and is marked `stated: false`:
a watched step whose floor reaches the same input knows more and takes
the sentence back. This is what keeps leaf.page's readings as detailed
as they were, since the hosted agent declares nothing of its own.

Teaching that agent to declare is left to `TODO.md` with the measurement
behind it: a "declare each step" paragraph in its instructions produced
four good sentences and a turn that ran a closing `resolve` and never
replied, which `verify_site.py local` caught; the same tree passed with
the paragraph removed.

## Guidance

`SKILL.md` states the priority: while a page is live, telling the reader
what you are doing comes before doing it.
`references/conversation-loop.md` gains the surfaces a reader follows,
when to write each, and a section on long-running work — a reader's
input reaches the agent only between its own operations, so work longer
than a few minutes goes to background workers, and one writer owns the
reading: the coordinator while its turn is open, summarizing its
workers, and the workers themselves once it ends and nothing in the
session can write.

The page contract states the reader's experience again, which two
rewrites had trimmed to the views and dropped: what the page wants of
them, visible before they read; a move in every state; a drawable move's
result at once; and what they have settled visible beside what is still
theirs.

## TODO

Two new sections: "Make Leaf feel like a game", gathering the items
already pulling that way, and "Agent activity on the page", holding what
this leaves open — the banner naming an arbitrary one of several
standing claims, observing Claude Code's tool steps the way App Server
observes Codex's, and whether delegated work may hold a reader move open
across turns.

## Validation

- `uv run pre-commit run --all-files`
- `uv run pytest tests` (1138 passed on the tree with main merged in)
- `uv run pytest tests/test_render_startup.py
tests/test_render_controls.py` (185 passed)
- `uv run scripts/verify_site.py local`: published revision 2 and
replied, with the hosted banner reading the watched steps
- matched baseline/candidate previews of `review-a-plan` at 1440×900,
fresh and five-minute-old claims, clean consoles in both arms
- the recorded demo and stills re-shot on the new row

> _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