Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Move cursor to unfold #1585

Open
tamo opened this issue Aug 28, 2020 · 0 comments
Open

Feature request: Move cursor to unfold #1585

tamo opened this issue Aug 28, 2020 · 0 comments

Comments

@tamo
Copy link
Contributor

@tamo tamo commented Aug 28, 2020

It would be nice to have an option to enable "down to unfold" feature in sublime mode.

diff --git a/public/js/lib/editor/index.js b/public/js/lib/editor/index.js
--- a/public/js/lib/editor/index.js
+++ b/public/js/lib/editor/index.js
@@ -85,6 +85,10 @@ export default class Editor {
       'Cmd-Right': 'goLineRight',
       Home: 'goLineLeftSmart',
       End: 'goLineRight',
+      'Down': function(cm) {
+        cm.moveV(1, "line")
+        cm.execCommand('unfold')
+      },
       'Ctrl-C': function (cm) {
         if (!isMac && cm.getOption('keyMap').substr(0, 3) === 'vim') {
           document.execCommand('copy')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.