Skip to content

feat: branch conversations from selected text - #698

Merged
agegr merged 5 commits into
agegr:mainfrom
Radiummm:feat/quoted-branch-chat
Sep 5, 2026
Merged

feat: branch conversations from selected text#698
agegr merged 5 commits into
agegr:mainfrom
Radiummm:feat/quoted-branch-chat

Conversation

@Radiummm

@Radiummm Radiummm commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Summary

Add optional actions for selected conversation text: quote it into the current composer or ask about it in a new branch. Enable the feature in Settings > General; it defaults off and the preference is saved in the browser.

The new-branch action opens a compact composer that reuses ChatInput, the Send button, input-method handling, and draft restoration. It prefills an editable quote followed by "My question:". Sending creates the branch at the selected assistant response, navigates to it, and submits the prompt once. Opening or cancelling the composer creates no session, and failed submissions preserve the input.

The selection toolbar has labeled icons and 35px buttons. Both the toolbar and composer stay within the visible desktop or mobile viewport. The non-replacing fork_branch RPC command and English, Simplified Chinese, and Traditional Chinese labels are included.

Validation

  • TypeScript and ESLint passed.
  • npm test: 943 passing.
  • npm run test:e2e: desktop and mobile history, branches, extension dialogs, chat appearance, and draft resizing passed.
  • Quoted-branch browser checks cover the default-off General switch, saved on/off states, editable quote prefill, IME and mobile Enter handling, cancellation, fork failure recovery, correct branch history, one automatic prompt, and 320px/390px mobile layouts.

@agegr
agegr merged commit c0abfc2 into agegr:main Sep 5, 2026
2 checks passed
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