Skip to content

Conversation

@samhvw8
Copy link
Contributor

@samhvw8 samhvw8 commented Mar 29, 2025

When a user shift-clicks a suggestion, the text is now appended to the current text area content instead of being sent immediately. This allows users to:

  • Build complex prompts by combining multiple suggestions
  • Edit suggestions before sending them
  • Reuse parts of previous suggestions

The implementation passes the mouse event through the component chain and checks for the shift key before deciding whether to append or send the message.

Context

Implementation

Video Demo

https://www.loom.com/share/c691ff7dd266465b920a27cfcda3146e

How to Test

Get in Touch


Important

Shift-clicking a suggestion now appends it to the text area instead of sending it immediately, allowing for more flexible prompt building.

  • Behavior:
    • Shift-clicking a suggestion appends it to the text area instead of sending it immediately.
    • Allows users to build complex prompts, edit suggestions, and reuse parts of previous suggestions.
  • Components:
    • ChatRow: Updated onSuggestionClick to accept a React.MouseEvent and check for shiftKey.
    • ChatView: Modified onSuggestionClick in itemContent to append text if shiftKey is pressed.
    • FollowUpSuggest: Updated onSuggestionClick to pass React.MouseEvent to handler.

This description was created by Ellipsis for 32ec09f7dd1dc55db84ed594ec1513d49b2b8310. It will automatically update as commits are pushed.

@changeset-bot
Copy link

changeset-bot bot commented Mar 29, 2025

⚠️ No Changeset found

Latest commit: 47b7a1f

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. enhancement New feature or request labels Mar 29, 2025
@mrubens
Copy link
Collaborator

mrubens commented Mar 29, 2025

Think anyone will know to do this? I was wondering if we should have little copy icons in the top right of the buttons instead.

When a user shift-clicks a suggestion, the text is now appended to the current text area content instead of being sent immediately. This allows users to:
- Build complex prompts by combining multiple suggestions
- Edit suggestions before sending them
- Reuse parts of previous suggestions

The implementation passes the mouse event through the component chain and checks for the shift key before deciding whether to append or send the message.
@samhvw8 samhvw8 force-pushed the feat/shift-click-suggestion branch from 32ec09f to b5c9b2d Compare March 30, 2025 14:45
@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. and removed size:S This PR changes 10-29 lines, ignoring generated files. labels Mar 30, 2025
@samhvw8
Copy link
Contributor Author

samhvw8 commented Mar 30, 2025

@mrubens

just update pr

https://www.loom.com/share/3913969eb486422dbd7ae0b4a069c4dd

what do you think about it

Copy link
Collaborator

@mrubens mrubens left a comment

Choose a reason for hiding this comment

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

Nice work!

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Mar 31, 2025
@mrubens mrubens merged commit 48148e3 into RooCodeInc:main Mar 31, 2025
10 checks passed
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Mar 31, 2025
Smartsheet-JB-Brown added a commit to Smartsheet-JB-Brown/Roo-Code that referenced this pull request Apr 1, 2025
* main: (21 commits)
  Update contributors list (RooCodeInc#2137)
  Tree-sitter Enhancements: TSX, TypeScript, JSON, and Markdown Support (RooCodeInc#2169)
  Fix Tests to run properly on Windows (RooCodeInc#1963)
  We should post state to webview at the end of `RooCodeAPI.clearCurrentTask()` (RooCodeInc#1874)
  Update app icon (RooCodeInc#2166)
  Changeset version bump (RooCodeInc#2163)
  Revert "feat @-mention window path style & file with space (RooCodeInc#1924)" (RooCodeInc#2162)
  Changeset version bump (RooCodeInc#2154)
  Include inference-profile in Bedrock arnRegex (RooCodeInc#2156)
  Add requesty to connect-src (RooCodeInc#2155)
  Update the webview when changing settings via the API (RooCodeInc#2143)
  Split webviewMessageHandler out of ClineProvider.ts (RooCodeInc#2149)
  Changeset version bump (RooCodeInc#2141)
  Relax provider profiles schema and log parse error to PostHog (RooCodeInc#2139)
  Changeset version bump (RooCodeInc#1992)
  v3.11.0 (RooCodeInc#2136)
  Update contributors list (RooCodeInc#2090)
  Preserve existing provider profiles when importing (RooCodeInc#2052)
  feat: Add shift-click to append suggestions to text area (RooCodeInc#2081)
  Remove hard-coded o3-mini model when streaming is enabled, allowing custom o3-mini-<reasoning> model (RooCodeInc#2134)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request lgtm This PR has been approved by a maintainer size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants