zed/assets
thataboy 1723713dc2
Add ability to copy assistant code block to clipboard or insert into editor, without manual selection (#17853)
Some notes:

- You can put the cursor on the start or end line with triple backticks,
it doesn't actually have to be inside the block.
- Placing the cursor outside of a code block does nothing.
- Code blocks are determined by counting triple backticks pairs from
either start or end of buffer, and nothing else.
- If you manually select something, the selection takes precedence over
any code blocks.

Release Notes:

- Added the ability to copy surrounding code blocks in the assistant
panel into the clipboard, or inserting them directly into the editor,
without manually selecting. Place cursor anywhere in a code block
(marked by triple backticks) and use the `assistant::CopyCode` action
(`cmd-k c` / `ctrl-k c`) to copy to the clipboard, or the
`assistant::InsertIntoEditor` action (`cmd-<` / `ctrl-<`) to insert into
editor.

---------

Co-authored-by: Thorsten Ball <mrnugget@gmail.com>
Co-authored-by: Bennet <bennet@zed.dev>
2024-09-19 13:43:49 +02:00
..
fonts Fix font selection on macOS (#13615) 2024-06-27 17:02:45 -06:00
icons Refine assistant config UI (#17871) 2024-09-16 08:12:07 -03:00
images add ui::Vector and separate images from icons (#17815) 2024-09-13 17:44:16 -04:00
keymaps Add ability to copy assistant code block to clipboard or insert into editor, without manual selection (#17853) 2024-09-19 13:43:49 +02:00
prompts Have models indicate code locations in workflows using textual search, not symbol names (#17282) 2024-09-02 18:20:05 -07:00
settings Add ability to display backgrounds for inlay hints (#18010) 2024-09-18 11:11:38 -04:00
sounds Update collaboration sounds, add sounds to screensharing 2023-07-04 16:18:42 -04:00
themes Revert accidental one theme changes (#17273) 2024-09-02 14:48:23 -04:00