Skip to content

fix(transcript): select text in sent prompts; plan chat forking - #342

Merged
sambitcreate merged 1 commit into
mainfrom
fix/prompt-text-selection
Oct 5, 2026
Merged

sambitcreate merged 1 commit into
mainfrom
fix/prompt-text-selection

Conversation

@sambitcreate

Copy link
Copy Markdown
Owner

Summary

  • Bug: sent user prompts could not be selected with the pointer. body sets user-select: none and only assistant Markdown opted back in. The user bubble and the unrenderable-message fallback now use select-text.
  • Plan: adds docs/plans/chat-fork-plan.md (indexed in docs/plans/README.md). It covers forking a chat from any message across desktop, Aiden Remote, iOS and Android, with an optional Pi branch summary. It was informed by opencode's POST /session/:id/fork and pi's fork/branch_summary. Implementation follows in stacked PRs.

Test plan

  • New Electron E2E sent user prompts can be selected with the pointer. It drags across a sent prompt and reads window.getSelection(). It fails without the fix (0 chars selected) and passes with it.
  • tests/e2e/chat-shell-interactions.spec.ts: 23/23 pass locally.
  • renderer/components/message-bubble.test.tsx: 31/31 pass.
  • npm run type-check:e2e

🤖 Generated with Claude Code

The app body sets user-select: none and only assistant Markdown opted
back in, so a sent user prompt could not be selected with the pointer.
The user bubble and the unrenderable-message fallback now allow text
selection. An Electron E2E drags across a sent prompt and reads the
selection back.

Adds docs/plans/chat-fork-plan.md: fork a chat from any message on
desktop, Remote, iOS and Android, informed by opencode and pi.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@very-hermes-bot

Copy link
Copy Markdown
Collaborator

Hermes Review Bot

Confidence: 5

Engine: agy/gemini-3.8-flash-high
Review mode: full
Head: 95958f17b31e686af6a35f495aa8619568d7d934
Generated: 2026-10-05T15:27:05+00:00
Reviews: 1

Summary

Sent user prompts in the chat transcript previously inherited user-select: none from the global body styles, preventing users from highlighting or selecting prompt text with a cursor. This change adds the select-text utility class to the user message bubble container and the unrenderable message fallback in MessageBubble, opting them back into pointer selection alongside existing assistant Markdown prose. A dedicated Playwright E2E test validates pointer drag-selection against window.getSelection(), and an architectural design document is added detailing cross-platform chat forking ahead of subsequent implementation PRs. Maintainers should double-check that pointer text selection inside the user bubble does not conflict with clicking embedded links or triggering the hover-revealed copy action.

Confidence Score: 5/5

Full end-to-end inspection of changed component styling, call sites, existing CSS rules, E2E fixtures, and architectural plan references against main verified that the fix is clean and non-regressive.

📁 Important Files Changed
  • renderer/components/message-bubble.tsx: Adds select-text to the user message bubble wrapper and the UnrenderableMessage fallback to enable pointer text selection.
  • tests/e2e/chat-shell-interactions.spec.ts: Adds an Electron E2E test confirming sent user messages can be selected with pointer drag interactions and inspected via window.getSelection().
  • docs/plans/chat-fork-plan.md: Introduces the 5-phase design plan for forking chats from any message across Desktop, Aiden Remote, and mobile clients.
  • docs/plans/README.md: Indexes the new chat forking plan under active/planned architectural roadmaps.

Findings

No findings.

Sequence Diagram

Unchanged or not applicable for this change.

[]

Last reviewed commit: 95958f17b31e
Reviews (1) · Comment /hermes review to trigger a new review · /hermes review full for full re-review

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes — Reviewed the complete PR diff, the shared transcript rendering path, the new pointer-selection test, and the chat-forking plan against the current storage and client seams.

  • Prompt selection: Enables pointer text selection in sent user prompts and raw-content formatting fallbacks.
  • Regression coverage: Adds a real pointer drag and checks that the selected text comes from the displayed prompt.
  • Forking plan: Documents message boundaries, lineage, Pi journal preservation and summaries, Remote contracts, desktop/mobile flows, and staged delivery; registers the plan in the index.

Validation: all 31 message-bubble tests pass, E2E type checking passes, and Playwright collects all 23 tests in the changed spec. Electron execution requires macOS and was not run on this Linux runner; hosted CI is still in progress.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@sambitcreate
sambitcreate merged commit 95958f1 into main Oct 5, 2026
23 checks passed
@sambitcreate
sambitcreate deleted the fix/prompt-text-selection branch October 5, 2026 16:37
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