Skip to content

Add Select to chat message context menus#119

Open
mcintyre94 wants to merge 1 commit intomainfrom
add-select-to-message-context-menu-ce79b1f8
Open

Add Select to chat message context menus#119
mcintyre94 wants to merge 1 commit intomainfrom
add-select-to-message-context-menu-ce79b1f8

Conversation

@mcintyre94
Copy link
Copy Markdown
Owner

Summary

  • Adds a Select action to the context menu on both user (blue) and assistant (grey) chat bubbles, alongside the existing Copy action
  • Tapping Select enters an inline selection mode: the bubble switches to a non-editable UITextView with all text immediately pre-selected and draggable handles
  • Tapping away (clearing the selection) automatically exits select mode and restores the normal bubble rendering
  • Backed by a new SelectableTextView (UIViewRepresentable) that selects all text on first appear and calls back via onDeselect when the selection length drops to zero

Test plan

  • Long-press a user message → context menu shows Copy and Select
  • Long-press an assistant message → context menu shows Copy, Select, and (if applicable) Create Checkpoint
  • Tap Select → bubble switches to text-selection mode with all text highlighted and handles visible
  • Drag handles to narrow the selection → system Copy popup appears
  • Tap away from the bubble → selection dismissed, bubble returns to normal
  • Tap Select on assistant message → raw text shown (markdown source), selectable
  • Copy still works as before on both bubble types

🤖 Generated with Claude Code

Adds a "Select" action alongside "Copy" in context menus for both user
and assistant chat bubbles. Tapping Select enters an inline selection
mode backed by a non-editable UITextView that immediately selects all
text with handles the user can drag to narrow the selection. Tapping
away exits select mode.

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
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