Fix: don't reorder options
This commit is contained in:
parent
90aadfd728
commit
9dd3cd43c1
|
@ -10,6 +10,21 @@
|
||||||
|
|
||||||
const defaults = {
|
const defaults = {
|
||||||
autoCloseBrackets: prefs.get('editor.autoCloseBrackets'),
|
autoCloseBrackets: prefs.get('editor.autoCloseBrackets'),
|
||||||
|
mode: 'css',
|
||||||
|
lineNumbers: true,
|
||||||
|
lineWrapping: prefs.get('editor.lineWrapping'),
|
||||||
|
foldGutter: true,
|
||||||
|
gutters: [
|
||||||
|
'CodeMirror-linenumbers',
|
||||||
|
'CodeMirror-foldgutter',
|
||||||
|
...(prefs.get('editor.linter') ? ['CodeMirror-lint-markers'] : []),
|
||||||
|
],
|
||||||
|
matchBrackets: true,
|
||||||
|
hintOptions: {},
|
||||||
|
lintReportDelay: prefs.get('editor.lintReportDelay'),
|
||||||
|
styleActiveLine: true,
|
||||||
|
theme: prefs.get('editor.theme'),
|
||||||
|
keyMap: prefs.get('editor.keyMap'),
|
||||||
extraKeys: Object.assign(CodeMirror.defaults.extraKeys || {}, {
|
extraKeys: Object.assign(CodeMirror.defaults.extraKeys || {}, {
|
||||||
// independent of current keyMap
|
// independent of current keyMap
|
||||||
'Alt-Enter': 'toggleStyle',
|
'Alt-Enter': 'toggleStyle',
|
||||||
|
@ -17,23 +32,7 @@
|
||||||
'Alt-PageUp': 'prevEditor',
|
'Alt-PageUp': 'prevEditor',
|
||||||
'Ctrl-Pause': 'toggleEditorFocus',
|
'Ctrl-Pause': 'toggleEditorFocus',
|
||||||
}),
|
}),
|
||||||
foldGutter: true,
|
|
||||||
gutters: [
|
|
||||||
'CodeMirror-linenumbers',
|
|
||||||
'CodeMirror-foldgutter',
|
|
||||||
...(prefs.get('editor.linter') ? ['CodeMirror-lint-markers'] : []),
|
|
||||||
],
|
|
||||||
// highlightSelectionMatches: {showToken: /[#.\-\w]/, annotateScrollbar: true},
|
|
||||||
hintOptions: {},
|
|
||||||
keyMap: prefs.get('editor.keyMap'),
|
|
||||||
lintReportDelay: prefs.get('editor.lintReportDelay'),
|
|
||||||
lineNumbers: true,
|
|
||||||
lineWrapping: prefs.get('editor.lineWrapping'),
|
|
||||||
matchBrackets: true,
|
|
||||||
maxHighlightLength: 100e3,
|
maxHighlightLength: 100e3,
|
||||||
mode: 'css',
|
|
||||||
styleActiveLine: true,
|
|
||||||
theme: prefs.get('editor.theme'),
|
|
||||||
};
|
};
|
||||||
|
|
||||||
Object.assign(CodeMirror.defaults, defaults, prefs.get('editor.options'));
|
Object.assign(CodeMirror.defaults, defaults, prefs.get('editor.options'));
|
||||||
|
|
Loading…
Reference in New Issue
Block a user