fix: mobile tools layout, tools-in-chat preference, cross-client user messages - #14
Open
bmurray wants to merge 1 commit into
Open
Conversation
Mobile was stacking the tools column under the chat and eating ~40vh.
Hide it on narrow viewports and place tool cards by preference instead.
Add a client-only "tool calls in conversation" setting (localStorage)
so inline tool cards can be toggled on wide and narrow. Default stays
responsive (inline on mobile, side panel on desktop) until the user
picks an explicit value.
Cross-client: user_message was never registered on the EventSource
client, so remote browsers never received the prompt text and
ensureTurn('') painted blank "you" ghosts. Listen for user_message
(and related lifecycle events), skip empty user bubbles, and fill an
empty shell turn when user_message arrives late.
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Three related UI/SSE fixes for multi-device and phone use:
Mobile tools pane — On viewports ≤720px the tools column stacked under the chat (up to ~40vh) and made conversations nearly unusable. The side tools column is now hidden on narrow screens; tool cards can live inline in the turn stream instead.
Tools-in-chat preference — Settings → general → “tool calls in conversation” (client-only,
localStorage). When on, tool cards render inline in the chat stream on both wide and narrow. When off, they only appear in the desktop tools side panel. Unset default: inline on mobile, side panel on desktop. Toggling re-homes existing tool groups live.Cross-client blank / ghost user messages — The server already broadcast
user_messageover SSE, but the browserEventSourceclient never registered that event name, so remote clients never received the prompt text. The first assistant/tool chunk then calledensureTurn('')and painted an empty “you” bubble (and similar ghosts when late events arrived after a turn ended).user_message(and a few related lifecycle events) inKNOWN_EVENTSuser_messagearrivesTest plan
npm run typechecknpm test(356 pass), including newuser_messageSSE client coverageuser_messagewith full text on/prompt