Open OrlovAlexei opened 1 month ago
Are you using a plugin for daq
? We should already support da"
, and dab
. I'm not against adding it, but I don't think it's part of vim by default.
The objects we currently support:
You're right, daq is not a default Vim command. The behavior I was referring to typically comes from the popular plugin vim-surround for Vim or nvim-surround for Neovim, which adds more flexible and powerful manipulation of surrounding text like quotes, brackets, and other delimiters.
I was wondering if there's a way to replicate this behavior manually in Zed, or if you have any suggestions on how I could implement something similar.
Thanks again for your consideration!
If I want to implement this via keymaps/vim.json, is it possible to add something like vim::AnyQuotes? AnyQuotes would refer to any of the following: Quotes, BackQuotes, or DoubleQuotes. Could something similar be done for brackets as well?
Thanks again for your consideration!
This is especially useful when using the English international layout, where entering double quotes (") requires pressing three keys: Shift + " + Space. Instead, I prefer using Vim commands like ciq, caq, diq, and daq for greater efficiency.
Check for existing issues
Describe the feature
Please add support for the following Vim commands:
caq: Change around quotes — Changes the entire text inside and around quotes, putting the user in insert mode. ciq: Change inside quotes — Changes only the text inside the quotes, without affecting the quotes themselves. cab: Change around brackets — Changes the entire text inside and around brackets ( ), { }, or [ ], switching to insert mode. cib: Change inside brackets — Changes only the text inside the brackets, keeping the brackets intact. daq / diq: Delete around / inside quotes — Deletes the text around or inside quotes. dab / dib: Delete around / inside brackets — Deletes text inside or around different types of brackets.
If applicable, add mockups / screenshots to help present your vision of the feature
No response