1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
import { styled } from '@mui/material/styles';
export const EditorParent = styled('div')(({ theme }) => ({
background: theme.palette.background.default,
'&, .cm-editor': {
height: '100%',
},
'.cm-scroller': {
fontSize: 16,
fontFamily: '"JetBrains MonoVariable", "JetBrains Mono", monospace',
fontFeatureSettings: '"liga", "calt"',
fontWeight: 400,
letterSpacing: 0,
textRendering: 'optimizeLegibility',
color: theme.palette.text.secondary,
},
'.cm-gutters': {
background: theme.palette.background.default,
color: theme.palette.text.disabled,
border: 'none',
},
'.cm-specialChar': {
color: theme.palette.secondary.main,
},
'.cm-activeLine': {
background: 'rgba(0, 0, 0, 0.3)',
},
'.cm-activeLineGutter': {
background: 'rgba(0, 0, 0, 0.3)',
color: theme.palette.text.primary,
},
'.cm-cursor, .cm-cursor-primary': {
borderColor: theme.palette.primary.main,
background: theme.palette.common.black,
},
'.cm-selectionBackground': {
background: '#3e4453',
},
'.cm-focused': {
outline: 'none',
'.cm-selectionBackground': {
background: '#3e4453',
},
},
'.cm-panels-top': {
color: theme.palette.text.secondary,
},
'.cm-panel': {
background: theme.palette.background.paper,
borderTop: `1px solid ${theme.palette.divider}`,
'button[name="close"]': {
// HACK We can't hook the panel close button to go through `EditorStore`,
// so we hide it altogether.
display: 'none',
},
},
'.cmt-comment': {
fontVariant: 'italic',
color: theme.palette.text.disabled,
},
}));
|