-
Notifications
You must be signed in to change notification settings - Fork 36
Open
Description
Problem
The current <leader>oi behavior has two issues that prevent accumulating selections across files:
- Selections are cleared when switching files - After selecting content in File A, switching to File B clears the previous selection
- Cannot add selections when panel is already open - When the panel is open, selecting content in another file and pressing
<leader>oihas no effect
Reproduction
- Open File A, select some code, press
<leader>oito add to context - Switch to File B, select another piece of code
- Press
<leader>oi- expected to add File B's selection to context, but:- Issue 1: If panel is not open, File A's selection is already cleared
- Issue 2: If panel is already open, nothing happens
Expected Behavior
Allow accumulating selections across files, supporting selection in any buffer and adding to the existing selection set, with selections persisting throughout the session lifecycle.
Proposed Solution
- New API:
context.add_visual_selection()- Only adds the current visual selection without clearing existing selections - Bug fix: Modify
debounced_load()to append selections instead of replacing them - New keymap:
<leader>oa(add selection) specifically for adding selections, separating the responsibility from<leader>oi(open input)
This allows <leader>oa to add selections from any buffer at any time without interfering with the normal <leader>oi workflow.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels