Skip to content

polish(studio): context meter in the composer toolbar, drop the approximate tag - #990

Closed
jtenniswood wants to merge 8 commits into
studio/S21from
studio/S22
Closed

polish(studio): context meter in the composer toolbar, drop the approximate tag#990
jtenniswood wants to merge 8 commits into
studio/S21from
studio/S22

Conversation

@jtenniswood

Copy link
Copy Markdown

Stack 22 — first change on top of the parity-verified port

Sits above #986 so the series' byte-parity proof stays intact: PRs 1–21 land #618 exactly; this is the first deliberate UX change on top.

  • The context strip moves from its floating spot above the composer into the toolbar row below the input, leftmost, next to the mode/model/memory pills.
  • The 'approximate' tag is removed — the ~ prefix on the percentage carries the approximation (the doc comment keeps the full why: the daemon's true trigger also counts the system prompt and tool schemas, and a reload loses the visit's running total).
  • Typography matches the toolbar: the pills' text-sm, colored text-muted-foreground like their value text (the On in Memory On).
  • Mechanically: ChatInput gains a contextMeter slot prop rendered first in the toolbar; chat-view keeps ownership of the usage data. Deliberate consequence: the toolbar is hidden on phones (its controls live in the + sheet), so the meter is desktop-only now.

Gates green: lint · typecheck · knip · vitest (439).

🤖 Generated with Claude Code

The context strip leaves its floating spot above the composer and becomes
the leftmost item in the toolbar row below the input, alongside the mode/
model/memory pills. The redundant 'approximate' tag goes — the ~ prefix on
the percentage carries the approximation, and the doc comment keeps the full
why. Typography now matches the toolbar: the pills' text size, colored like
their value text (the On in Memory On).

ChatInput takes the strip as a contextMeter slot, so the composer stays dumb
and chat-view keeps ownership of the data. One consequence, deliberate: the
toolbar row is hidden on phones (its controls live in the + sheet there), so
the meter is desktop-only now.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@jtenniswood jtenniswood added ux ui fit-and-finish Polish & correctness of surface details: labels, wording, alignment, spacing, visual state WebUI Applies to the WebUI interface labels Sep 2, 2026
jtenniswood and others added 7 commits September 2, 2026 13:47
Three render cases on top of the existing math pins: the ~percentage shows
without a standalone approximate tag, the strip uses the toolbar pills' value
typography (text-sm, muted), and it stays quiet until the visit has counted
tokens.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…self

The strip moves to the right end of the composer toolbar (ml-auto on the
slot, rendered after the pills), drops the ~ prefix, and reads 'N% used'.
The approximation caveat moves into a tooltip that also explains what a
context window is — how much conversation the model can consider at once,
and that the agent compacts older history as it fills. The bar graphic spans
40% of the toolbar's width (cqw against the row's existing @container).

Render tests updated: plain 'N% used' with no tilde/of-context/approximate,
right-docked with the 40cqw bar, quiet until the visit has counted tokens.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The strip reads as just the short bar plus 'N% used' — the model name goes
(the model pill next to it already says which model the chat runs on), and
the bar returns to its fixed 64px width instead of 40% of the toolbar, which
dominated the row on wide composers. Tests pinned accordingly (the strip's
whole text content IS 'N% used').

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Two short sentences in everyday words: roughly how much of the model's
working memory this chat has used, and that older messages are summarized
to make room when it fills.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The input panel loses its 768px cap in both the draft view and the open
chat (kept identical so the draft-to-chat transition still doesn't move the
input under your hands). The transcript column keeps its readable measure —
only the composer stretches.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
One 'studio' configuration: npm --prefix studio run dev (managed mode —
controller + supervised mecated) on port 3000, so the Claude Code browser
pane can start and attach to Studio directly.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@jhrozek jhrozek closed this Sep 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fit-and-finish Polish & correctness of surface details: labels, wording, alignment, spacing, visual state ui ux WebUI Applies to the WebUI interface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants