diff options
author | Kristóf Marussy <kristof@marussy.com> | 2022-07-27 16:34:14 +0200 |
---|---|---|
committer | Kristóf Marussy <kristof@marussy.com> | 2022-07-27 16:34:14 +0200 |
commit | deaa0580d952b77cf9e6df024d1f71ed29f53fc0 (patch) | |
tree | 95a4e538b21c13674de99a6645bae1424714721a /subprojects/frontend/src/editor/EditorStore.ts | |
parent | docs: Add note about proxy settings (diff) | |
download | refinery-deaa0580d952b77cf9e6df024d1f71ed29f53fc0.tar.gz refinery-deaa0580d952b77cf9e6df024d1f71ed29f53fc0.tar.zst refinery-deaa0580d952b77cf9e6df024d1f71ed29f53fc0.zip |
chore: bump dependencies
Diffstat (limited to 'subprojects/frontend/src/editor/EditorStore.ts')
-rw-r--r-- | subprojects/frontend/src/editor/EditorStore.ts | 40 |
1 files changed, 24 insertions, 16 deletions
diff --git a/subprojects/frontend/src/editor/EditorStore.ts b/subprojects/frontend/src/editor/EditorStore.ts index 5760de28..0f4d2936 100644 --- a/subprojects/frontend/src/editor/EditorStore.ts +++ b/subprojects/frontend/src/editor/EditorStore.ts | |||
@@ -1,27 +1,32 @@ | |||
1 | import { autocompletion, completionKeymap } from '@codemirror/autocomplete'; | ||
2 | import { closeBrackets, closeBracketsKeymap } from '@codemirror/closebrackets'; | ||
3 | import { defaultKeymap, indentWithTab } from '@codemirror/commands'; | ||
4 | import { commentKeymap } from '@codemirror/comment'; | ||
5 | import { foldGutter, foldKeymap } from '@codemirror/fold'; | ||
6 | import { highlightActiveLineGutter, lineNumbers } from '@codemirror/gutter'; | ||
7 | import { classHighlightStyle } from '@codemirror/highlight'; | ||
8 | import { | 1 | import { |
2 | closeBrackets, | ||
3 | closeBracketsKeymap, | ||
4 | autocompletion, | ||
5 | completionKeymap, | ||
6 | } from '@codemirror/autocomplete'; | ||
7 | import { | ||
8 | defaultKeymap, | ||
9 | history, | 9 | history, |
10 | historyKeymap, | 10 | historyKeymap, |
11 | indentWithTab, | ||
11 | redo, | 12 | redo, |
12 | redoDepth, | 13 | redoDepth, |
13 | undo, | 14 | undo, |
14 | undoDepth, | 15 | undoDepth, |
15 | } from '@codemirror/history'; | 16 | } from '@codemirror/commands'; |
16 | import { indentOnInput } from '@codemirror/language'; | 17 | import { |
18 | bracketMatching, | ||
19 | foldGutter, | ||
20 | foldKeymap, | ||
21 | indentOnInput, | ||
22 | syntaxHighlighting, | ||
23 | } from '@codemirror/language'; | ||
17 | import { | 24 | import { |
18 | Diagnostic, | 25 | Diagnostic, |
19 | lintKeymap, | 26 | lintKeymap, |
20 | setDiagnostics, | 27 | setDiagnostics, |
21 | } from '@codemirror/lint'; | 28 | } from '@codemirror/lint'; |
22 | import { bracketMatching } from '@codemirror/matchbrackets'; | 29 | import { search, searchKeymap } from '@codemirror/search'; |
23 | import { rectangularSelection } from '@codemirror/rectangular-selection'; | ||
24 | import { searchConfig, searchKeymap } from '@codemirror/search'; | ||
25 | import { | 30 | import { |
26 | EditorState, | 31 | EditorState, |
27 | StateCommand, | 32 | StateCommand, |
@@ -33,9 +38,13 @@ import { | |||
33 | drawSelection, | 38 | drawSelection, |
34 | EditorView, | 39 | EditorView, |
35 | highlightActiveLine, | 40 | highlightActiveLine, |
41 | highlightActiveLineGutter, | ||
36 | highlightSpecialChars, | 42 | highlightSpecialChars, |
37 | keymap, | 43 | keymap, |
44 | lineNumbers, | ||
45 | rectangularSelection, | ||
38 | } from '@codemirror/view'; | 46 | } from '@codemirror/view'; |
47 | import { classHighlighter } from '@lezer/highlight'; | ||
39 | import { | 48 | import { |
40 | makeAutoObservable, | 49 | makeAutoObservable, |
41 | observable, | 50 | observable, |
@@ -91,7 +100,6 @@ export class EditorStore { | |||
91 | (context) => this.client.contentAssist(context), | 100 | (context) => this.client.contentAssist(context), |
92 | ], | 101 | ], |
93 | }), | 102 | }), |
94 | classHighlightStyle.extension, | ||
95 | closeBrackets(), | 103 | closeBrackets(), |
96 | bracketMatching(), | 104 | bracketMatching(), |
97 | drawSelection(), | 105 | drawSelection(), |
@@ -106,10 +114,11 @@ export class EditorStore { | |||
106 | history(), | 114 | history(), |
107 | indentOnInput(), | 115 | indentOnInput(), |
108 | rectangularSelection(), | 116 | rectangularSelection(), |
109 | searchConfig({ | 117 | search({ |
110 | top: true, | 118 | top: true, |
111 | matchCase: true, | 119 | caseSensitive: true, |
112 | }), | 120 | }), |
121 | syntaxHighlighting(classHighlighter), | ||
113 | semanticHighlighting, | 122 | semanticHighlighting, |
114 | // We add the gutters to `extensions` in the order we want them to appear. | 123 | // We add the gutters to `extensions` in the order we want them to appear. |
115 | lineNumbers(), | 124 | lineNumbers(), |
@@ -117,7 +126,6 @@ export class EditorStore { | |||
117 | keymap.of([ | 126 | keymap.of([ |
118 | { key: 'Mod-Shift-f', run: () => this.formatText() }, | 127 | { key: 'Mod-Shift-f', run: () => this.formatText() }, |
119 | ...closeBracketsKeymap, | 128 | ...closeBracketsKeymap, |
120 | ...commentKeymap, | ||
121 | ...completionKeymap, | 129 | ...completionKeymap, |
122 | ...foldKeymap, | 130 | ...foldKeymap, |
123 | ...historyKeymap, | 131 | ...historyKeymap, |