Session Share: instant Start/Stop + readable Thinking on the phone PWA#318
Merged
Conversation
…summaries, open-state survives repaints (P-REMOTE.9b) Guests watching a turn saw only tool chips: every streamed event repainted the transcript with innerHTML, resetting each <details> to collapsed (an opened Thinking block snapped shut within ms), and the collapsed row was a bare dim 'Thinking' with no gist of the reasoning. pwa_view.ts (pure, tested): thinkingGist() = the freshest non-empty line, clipped + escaped, shown in the summary and hidden while open; renderItem gains (i, activeThinking) - data-think='<i>' keys open-state across repaints, and the trailing thinking block renders OPEN like the desktop's live reasoning, collapsing when the answer starts. app.ts: a tap on a Thinking summary records intent per index; render() re-applies intents after each repaint; cleared on reconnect. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…s + optimistic teardown (P-SHARE.4) Start and Stop looked frozen: Start awaited collabSetP2P -> relay-token fetch -> collabStart with zero UI feedback, and Stop awaited the backend before redrawing. Start now disables its button and shows a two-line progress readout under it that narrates each phase (Preparing -> Authorizing this device -> Opening the room, or Finding a relay -> Connecting for P2P) with the relay label; a double-click guard and a startFail helper (re-enable + toast) cover re-entry and errors. Stop is optimistic: local teardown is synchronous, the idle body paints instantly from cached serve/p2p/relay config (no round-trip), and the backend collabStop + a reconciling draw run in the background so the button never hangs. Verified: renderer tsc clean; collab + share_dock 384/384; the .share-prog readout checked against the real styles.css in the preview. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Two session-share UX fixes, both reported from live use.
feat(share): instant Start/Stop (P-SHARE.4) — d5f70e3
The Share dock looked frozen on both actions. Start awaited
collabSetP2P→ a relay-token fetch →collabStartwith no UI feedback; Stop awaited the backend before redrawing.Preparing to share…→ (gated)Authorizing this device…→Opening the room…, or for P2PFinding a relay…→Connecting…— with the relay label. A double-click guard blocks re-entry mid-handshake, and astartFailhelper re-enables + toasts on any error.drawIdleOptimistic, no status round-trip), and the backendcollabStop()+ a reconcilingdraw()run in the background — so the button never hangs on a slow socket close.feat(remote-pwa): readable Thinking on the phone (P-REMOTE.9b) — 909d3a0
Guests watching a turn saw only tool chips. The per-event
innerHTMLrepaint reset every<details>to collapsed (an opened Thinking block snapped shut within ms), and the collapsed row was a bare dim "Thinking" with no gist.pwa_view.ts(pure, tested):thinkingGist()shows the freshest reasoning line in the summary (escaped, clipped, hidden when open);renderItemstampsdata-think="<i>"and renders the trailing thinking block open like the desktop's live reasoning, collapsing when the answer starts.app.ts: a tap records intent per index;render()re-applies it after each repaint; cleared on reconnect.Verification
pwa_view15/15 (incl. hostile-text escaping of the gist); collab + share_dock 384/384..share-progreadout checked against the real styles.css in the browser preview; PWA Thinking checked via DOM geometry in the preview.Reconciliation
No overlap with the only other open PR (#282, a Dependabot npm bump touching
package.json/bun.lock).🤖 Generated with Claude Code