Skip to content

Commit

Permalink
Desktop: Fixes #3749: Use joplin list handling in emacs mode (#3758)
Browse files Browse the repository at this point in the history
  • Loading branch information
CalebJohn authored Sep 17, 2020
1 parent bdedf69 commit 38eda3f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/Editor.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,10 @@ function Editor(props: EditorProps, ref: any) {
'Insert': 'toggleOverwrite',
'Esc': 'singleSelection',
};
// Add some of the Joplin smart list handling to emacs mode
CodeMirror.keyMap.emacs['Tab'] = 'smartListIndent';
CodeMirror.keyMap.emacs['Enter'] = 'insertListElement';
CodeMirror.keyMap.emacs['Shift-Tab'] = 'smartListUnindent';

if (shim.isMac()) {
CodeMirror.keyMap.default = {
Expand Down

0 comments on commit 38eda3f

Please sign in to comment.