Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[closebrackets addon] When wrapping selection, create new selection w…
…ithout brackets Right now if you have a selection, and you enter a bracket/quote, surrounds it with quotation marks, and selects the entire quote. This change should change the behaviour to selecting the interior of the quote instead. The motivating example for me was autocomplete, where after autocompleting a function the arguments are selected, so if you want to insert a string literal right now you have to delete the selection before you can enter the quotes. With the proposed fix, it'll be rather more fluid.
- Loading branch information
c65244d
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Brilliant!
I've noticed myself fighting a similar trouble in Chrome DevTools lately, but after search. I want to replace the found text with enquoted string, or array/brackets — and get caught in the selection muddle.
I wish Chrome picked CodeMirror changes soon, great improvement.