mirror of
https://github.com/massbug/judge4c.git
synced 2025-05-17 23:12:23 +00:00
refactor(config): migrate editor options to standalone editor config
- Rename `editor-language.ts` to `editor.ts` - Update interface from `IEditorConstructionOptions` to `IStandaloneEditorConstructionOptions` - Keep all existing editor options unchanged
This commit is contained in:
parent
49419654a0
commit
2e74ffbac3
@ -1,45 +0,0 @@
|
|||||||
import { type editor } from "monaco-editor";
|
|
||||||
|
|
||||||
export const DefaultEditorOptionConfig: editor.IEditorConstructionOptions = {
|
|
||||||
fontFamily: "Fira Code",
|
|
||||||
fontLigatures: true,
|
|
||||||
lineHeight: 20,
|
|
||||||
fontSize: 14,
|
|
||||||
bracketPairColorization: {
|
|
||||||
enabled: true,
|
|
||||||
},
|
|
||||||
showFoldingControls: "always",
|
|
||||||
guides: {
|
|
||||||
bracketPairs: true,
|
|
||||||
bracketPairsHorizontal: "active",
|
|
||||||
highlightActiveBracketPair: true,
|
|
||||||
highlightActiveIndentation: "always",
|
|
||||||
indentation: true,
|
|
||||||
},
|
|
||||||
hover: {
|
|
||||||
above: false,
|
|
||||||
},
|
|
||||||
padding: {
|
|
||||||
top: 8,
|
|
||||||
},
|
|
||||||
scrollbar: {
|
|
||||||
horizontalSliderSize: 10,
|
|
||||||
verticalSliderSize: 10,
|
|
||||||
},
|
|
||||||
wordWrap: "on",
|
|
||||||
minimap: {
|
|
||||||
enabled: false,
|
|
||||||
},
|
|
||||||
smoothScrolling: true,
|
|
||||||
stickyScroll: {
|
|
||||||
enabled: true,
|
|
||||||
maxLineCount: 5,
|
|
||||||
},
|
|
||||||
cursorBlinking: "smooth",
|
|
||||||
cursorSmoothCaretAnimation: "on",
|
|
||||||
suggestSelection: "recentlyUsed",
|
|
||||||
autoIndent: "full",
|
|
||||||
automaticLayout: true,
|
|
||||||
contextmenu: true,
|
|
||||||
matchBrackets: "always",
|
|
||||||
};
|
|
46
src/config/editor.ts
Normal file
46
src/config/editor.ts
Normal file
@ -0,0 +1,46 @@
|
|||||||
|
import type { editor } from "monaco-editor";
|
||||||
|
|
||||||
|
export const DEFAULT_EDITOR_OPTIONS: editor.IStandaloneEditorConstructionOptions =
|
||||||
|
{
|
||||||
|
fontFamily: "Fira Code",
|
||||||
|
fontLigatures: true,
|
||||||
|
lineHeight: 20,
|
||||||
|
fontSize: 14,
|
||||||
|
bracketPairColorization: {
|
||||||
|
enabled: true,
|
||||||
|
},
|
||||||
|
showFoldingControls: "always",
|
||||||
|
guides: {
|
||||||
|
bracketPairs: true,
|
||||||
|
bracketPairsHorizontal: "active",
|
||||||
|
highlightActiveBracketPair: true,
|
||||||
|
highlightActiveIndentation: "always",
|
||||||
|
indentation: true,
|
||||||
|
},
|
||||||
|
hover: {
|
||||||
|
above: false,
|
||||||
|
},
|
||||||
|
padding: {
|
||||||
|
top: 8,
|
||||||
|
},
|
||||||
|
scrollbar: {
|
||||||
|
horizontalSliderSize: 10,
|
||||||
|
verticalSliderSize: 10,
|
||||||
|
},
|
||||||
|
wordWrap: "on",
|
||||||
|
minimap: {
|
||||||
|
enabled: false,
|
||||||
|
},
|
||||||
|
smoothScrolling: true,
|
||||||
|
stickyScroll: {
|
||||||
|
enabled: true,
|
||||||
|
maxLineCount: 5,
|
||||||
|
},
|
||||||
|
cursorBlinking: "smooth",
|
||||||
|
cursorSmoothCaretAnimation: "on",
|
||||||
|
suggestSelection: "recentlyUsed",
|
||||||
|
autoIndent: "full",
|
||||||
|
automaticLayout: true,
|
||||||
|
contextmenu: true,
|
||||||
|
matchBrackets: "always",
|
||||||
|
};
|
Loading…
Reference in New Issue
Block a user