Skip to content

Float the background-work chip and open it as a card - #113

Merged
eivindjonassen merged 2 commits into
mainfrom
floating-background-work-card
Nov 15, 2026
Merged

eivindjonassen merged 2 commits into
mainfrom
floating-background-work-card

Conversation

@eivindjonassen

@eivindjonassen eivindjonassen commented Nov 14, 2026 •

Copy link
Copy Markdown
Member

Summary

iPhone screenshots showed four problems around the composer: the background-work chip sat in an opaque band, the composer folded after an agent choice, model changes hid behind a disclosure, and the chip's spinner competed with the Working line.

  • Floating chip: the chip now floats over the transcript. Only the rest of the dock (the execution panel and the composer) reserves space, measured in one piece, so the chip appearing or going away never resizes the transcript. The inverted list pads its newest end by the chip's height, so at the live edge the newest row rests above the chip. Touches beside the chip reach the transcript (pointerEvents="box-none" through the dock). iOS scroll indicators are inset to match.
  • Chip icon: one chip, one icon. It spins (WorkingIndicator) while a subagent runs. When only shells run it shows a still terminal glyph, info-colored when confirmed and dim when last known. The warm dot stays for needs-you. The label is unchanged ("1 subagent · 1 shell").
  • Card instead of a sheet: tapping the chip opens a new PopoverCard over the chip, with the screen dimmed behind. Tapping outside closes it. Sections are unchanged: Needs you, Subagents, Shells, and finished subagents. A shell's page opens inside the card. Android back and the iOS escape gesture step back from the shell page to the list.
    • The card pins its bottom edge to the chip and measures it again on rotation, on resize, on keyboard show and hide, and once shown, because opening can fold the composer under the chip.
    • It never grows taller than the space above it. It stays clear of a notch on either side and is capped at 640pt wide on tablets. It supports landscape.
    • Tapping the chip dismisses the keyboard first.
    • Focus opens on the stale notice, else the first section, else Shells. It returns to the chip on close: through onDismiss on iOS, and through useReturnFocusAfterClose, now exported from modal-sheet.tsx, on Android.
  • Composer stays open: choosing an agent, model or variant no longer folds the composer. A hold keeps it expanded until the prompt is tapped and then blurs, or the prompt is sent. Only focus that follows a tap releases the hold, so focus passing through the prompt while the agent sheet (which has its own search field) closes doesn't fold it. Picker presses blur the prompt explicitly, for Android, and reset the tap flag.
  • Model change inline: the feed reads "Model changed to model · variant" like the agent change, with nothing to expand. Screen readers hear a comma instead of "·".

Revisions were published as EAS Updates to preview (runtime 0.1.6). The latest revision is published from this branch's commit 09c0290 (update group c89981dd). Every changed file is JavaScript.

Known limits:

  • Android measureInWindow alignment with the status-bar-translucent card needs device evidence.
  • If a permission or form grows the dock while the card is open, the card isn't measured again until the next keyboard or size change.
  • A screen-reader activation of the prompt may not report a press, so the hold then lasts until send. That only keeps the toolbar showing.

Verification

  • pnpm check (1575 mobile tests, adapter tests, both Hermes exports)
  • pnpm native:doctor (18/18)
  • pnpm crap --threshold 30
  • Tests cover the changed behavior: the spacer leaves out the floating row (the row appearing or going away keeps the viewport, the keyboard offset still applies), list padding and indicator insets, box-none through the dock, the chip icon per kind, Keyboard.dismiss on chip press, the card's bottom pin, height clamp, fill, re-measuring on resize, keyboardDidHide and show, asymmetric safe-area insets, escape stepping back, backdrop close and reopen, the composer hold (agent and variant choice, focus without a tap, tap then blur, cancel, send), and the inline model change with its spoken label.
  • Platform behavior is verified on the affected targets, or the gap is documented. On an iPhone the chip floated over the transcript. Still unverified on devices: the final revision, the composer staying open after an agent choice, Android card alignment, the card with the keyboard open, in landscape and with large text, and VoiceOver and TalkBack focus on open and close. The gap is recorded in docs/COMPATIBILITY.md.
  • No credentials, addresses, identifiers, user content, private paths, or deployment files are included.
  • Documentation and TODO.md reflect the resulting behavior.

Council review

Rounds: 6

Delegate Round 1 Round 2 Round 3 Round 4 Round 5 Round 6
Claude Opus 6.5/10 8.5/10 9.5/10 7/10 8/10 9/10
GPT Sol 8/10 9/10 9.5/10 7/10 8/10 9/10
Gemini 7/10 9.5/10 10/10 7/10 9/10 10/10

Rounds 1 to 3 reviewed the floating chip and the first composer fix. Round 2 scored the composer separately (Opus 8, GPT Sol 9, Gemini 8), and the table shows the chip scores. Rounds 4 to 6 reviewed the revised composer fix, the inline model change, the chip icon and the card. Gemini's round 4 note that the composer could fold mid-tap was fixed in round 5. Opus's round 6 note about a late measurement leaving a stale position for one frame was left as is, because the effect measures again on open.

The background-work chip sat in an opaque band above the composer because
the transcript spacer reserved the whole dock, chip included. Only the rest
of the dock now reserves space, measured in one piece, and the inverted
list pads its newest end by the chip's height. The transcript scrolls under
the chip, and touches beside it reach the rows behind.

The chip spins while a subagent runs, shows a still terminal glyph when
only shells run, and keeps the warm dot when something needs you. Tapping
it opens a card over the chip instead of a sheet: the screen dims, tapping
outside closes it, and a shell's page opens inside the card. The card is
measured from the chip again on rotation, resize, keyboard changes and
once shown, and stays within the safe area.

Choosing an agent, model or variant no longer folds the composer. A hold
keeps it expanded until the prompt is tapped and blurs, or the prompt is
sent, so focus passing through the prompt as a sheet closes does not fold
it. Model changes read inline as "Model changed to" the model and variant.
The shell page inside the background-work card kept the sheet's 360pt
output cap, so the output stayed small in a tall card. In the card the
output now grows into the space the page leaves.

Choosing a variant opened a full-screen sheet for a handful of options. It
now opens as a card just above the Variant button, headed with the model
name. The card gains an "above" placement for this.

A session-screen test now chooses an agent through the real dock and
checks that the composer stays expanded.
@eivindjonassen
eivindjonassen merged commit d0fe45c into main Nov 15, 2026
4 checks passed
@eivindjonassen
eivindjonassen deleted the floating-background-work-card branch November 15, 2026 02:21
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.

1 participant