@fsegurai/codemirror-theme-github-light 6.0.5 → 6.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +17 -16
- package/dist/index.js +17 -16
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -9,6 +9,7 @@ const base00 = '#fff', // Background
|
|
|
9
9
|
base01 = '#24292e', // Foreground
|
|
10
10
|
base02 = '#BBDFFF', // Selection and Selection Match
|
|
11
11
|
base03 = '#6e7781', // Gutter Foreground
|
|
12
|
+
base04 = '#f6f8fa', // Caret, using Foreground color
|
|
12
13
|
base05 = '#116329', // TagName and Standard TagName
|
|
13
14
|
base06 = '#6a737d', // Comment and Bracket
|
|
14
15
|
base07 = '#6f42c1', // ClassName and PropertyName
|
|
@@ -20,52 +21,52 @@ base0C = '#e36209', // Atom, Bool, Special VariableName
|
|
|
20
21
|
base0D = '#b31d28', // Deleted
|
|
21
22
|
base0E = '#ffeef0', // Background for Deleted
|
|
22
23
|
invalid = '#cb2431'; // Invalid color
|
|
23
|
-
const darkBackground =
|
|
24
|
+
const darkBackground = base04, // A lighter background for panels, assuming a light theme variant
|
|
24
25
|
highlightBackground = base02 + '20', // Adding opacity for highlight
|
|
25
26
|
tooltipBackground = base00, cursor = base01, selection = base02;
|
|
26
27
|
// Define the editor theme styles for GitHub Light.
|
|
27
28
|
const githubLightTheme = view.EditorView.theme({
|
|
28
29
|
'&': {
|
|
29
30
|
color: base01,
|
|
30
|
-
backgroundColor: base00
|
|
31
|
+
backgroundColor: base00,
|
|
31
32
|
},
|
|
32
33
|
'.cm-content': {
|
|
33
|
-
caretColor: cursor
|
|
34
|
+
caretColor: cursor,
|
|
34
35
|
},
|
|
35
36
|
'.cm-cursor, .cm-dropCursor': {
|
|
36
|
-
borderLeftColor: cursor
|
|
37
|
+
borderLeftColor: cursor,
|
|
37
38
|
},
|
|
38
39
|
'&.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground, .cm-selectionBackground, .cm-content ::selection': {
|
|
39
|
-
backgroundColor: selection
|
|
40
|
+
backgroundColor: selection,
|
|
40
41
|
},
|
|
41
42
|
'.cm-searchMatch': {
|
|
42
43
|
backgroundColor: base02,
|
|
43
|
-
outline: `1px solid ${base03}
|
|
44
|
+
outline: `1px solid ${base03}`,
|
|
44
45
|
},
|
|
45
46
|
'.cm-searchMatch.cm-searchMatch-selected': {
|
|
46
47
|
backgroundColor: base05,
|
|
47
|
-
color: base07
|
|
48
|
+
color: base07,
|
|
48
49
|
},
|
|
49
50
|
'.cm-panels': {
|
|
50
51
|
backgroundColor: darkBackground,
|
|
51
|
-
color: base03
|
|
52
|
+
color: base03,
|
|
52
53
|
},
|
|
53
54
|
'.cm-panels.cm-panels-top': {
|
|
54
|
-
borderBottom: '2px solid black'
|
|
55
|
+
borderBottom: '2px solid black',
|
|
55
56
|
},
|
|
56
57
|
'.cm-panels.cm-panels-bottom': {
|
|
57
|
-
borderTop: '2px solid black'
|
|
58
|
+
borderTop: '2px solid black',
|
|
58
59
|
},
|
|
59
60
|
'.cm-activeLine': {
|
|
60
|
-
backgroundColor: highlightBackground
|
|
61
|
+
backgroundColor: highlightBackground,
|
|
61
62
|
},
|
|
62
63
|
'.cm-gutters': {
|
|
63
64
|
backgroundColor: base00,
|
|
64
|
-
color: base03
|
|
65
|
+
color: base03,
|
|
65
66
|
},
|
|
66
67
|
'.cm-tooltip': {
|
|
67
|
-
backgroundColor: tooltipBackground
|
|
68
|
-
}
|
|
68
|
+
backgroundColor: tooltipBackground,
|
|
69
|
+
},
|
|
69
70
|
}, { dark: false });
|
|
70
71
|
// Define the highlighting style for code in the GitHub Light theme.
|
|
71
72
|
const githubLightHighlightStyle = language.HighlightStyle.define([
|
|
@@ -83,12 +84,12 @@ const githubLightHighlightStyle = language.HighlightStyle.define([
|
|
|
83
84
|
{ tag: [highlight.tags.url, highlight.tags.escape, highlight.tags.regexp, highlight.tags.link], color: base0A },
|
|
84
85
|
{ tag: highlight.tags.link, textDecoration: 'underline' },
|
|
85
86
|
{ tag: highlight.tags.strikethrough, textDecoration: 'line-through' },
|
|
86
|
-
{ tag: highlight.tags.invalid, color: invalid }
|
|
87
|
+
{ tag: highlight.tags.invalid, color: invalid },
|
|
87
88
|
]);
|
|
88
89
|
// Extension to enable the GitHub Light theme (both the editor theme and the highlight style).
|
|
89
90
|
const githubLight = [
|
|
90
91
|
githubLightTheme,
|
|
91
|
-
language.syntaxHighlighting(githubLightHighlightStyle)
|
|
92
|
+
language.syntaxHighlighting(githubLightHighlightStyle),
|
|
92
93
|
];
|
|
93
94
|
|
|
94
95
|
exports.githubLight = githubLight;
|
package/dist/index.js
CHANGED
|
@@ -7,6 +7,7 @@ const base00 = '#fff', // Background
|
|
|
7
7
|
base01 = '#24292e', // Foreground
|
|
8
8
|
base02 = '#BBDFFF', // Selection and Selection Match
|
|
9
9
|
base03 = '#6e7781', // Gutter Foreground
|
|
10
|
+
base04 = '#f6f8fa', // Caret, using Foreground color
|
|
10
11
|
base05 = '#116329', // TagName and Standard TagName
|
|
11
12
|
base06 = '#6a737d', // Comment and Bracket
|
|
12
13
|
base07 = '#6f42c1', // ClassName and PropertyName
|
|
@@ -18,52 +19,52 @@ base0C = '#e36209', // Atom, Bool, Special VariableName
|
|
|
18
19
|
base0D = '#b31d28', // Deleted
|
|
19
20
|
base0E = '#ffeef0', // Background for Deleted
|
|
20
21
|
invalid = '#cb2431'; // Invalid color
|
|
21
|
-
const darkBackground =
|
|
22
|
+
const darkBackground = base04, // A lighter background for panels, assuming a light theme variant
|
|
22
23
|
highlightBackground = base02 + '20', // Adding opacity for highlight
|
|
23
24
|
tooltipBackground = base00, cursor = base01, selection = base02;
|
|
24
25
|
// Define the editor theme styles for GitHub Light.
|
|
25
26
|
const githubLightTheme = /*@__PURE__*/EditorView.theme({
|
|
26
27
|
'&': {
|
|
27
28
|
color: base01,
|
|
28
|
-
backgroundColor: base00
|
|
29
|
+
backgroundColor: base00,
|
|
29
30
|
},
|
|
30
31
|
'.cm-content': {
|
|
31
|
-
caretColor: cursor
|
|
32
|
+
caretColor: cursor,
|
|
32
33
|
},
|
|
33
34
|
'.cm-cursor, .cm-dropCursor': {
|
|
34
|
-
borderLeftColor: cursor
|
|
35
|
+
borderLeftColor: cursor,
|
|
35
36
|
},
|
|
36
37
|
'&.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground, .cm-selectionBackground, .cm-content ::selection': {
|
|
37
|
-
backgroundColor: selection
|
|
38
|
+
backgroundColor: selection,
|
|
38
39
|
},
|
|
39
40
|
'.cm-searchMatch': {
|
|
40
41
|
backgroundColor: base02,
|
|
41
|
-
outline: `1px solid ${base03}
|
|
42
|
+
outline: `1px solid ${base03}`,
|
|
42
43
|
},
|
|
43
44
|
'.cm-searchMatch.cm-searchMatch-selected': {
|
|
44
45
|
backgroundColor: base05,
|
|
45
|
-
color: base07
|
|
46
|
+
color: base07,
|
|
46
47
|
},
|
|
47
48
|
'.cm-panels': {
|
|
48
49
|
backgroundColor: darkBackground,
|
|
49
|
-
color: base03
|
|
50
|
+
color: base03,
|
|
50
51
|
},
|
|
51
52
|
'.cm-panels.cm-panels-top': {
|
|
52
|
-
borderBottom: '2px solid black'
|
|
53
|
+
borderBottom: '2px solid black',
|
|
53
54
|
},
|
|
54
55
|
'.cm-panels.cm-panels-bottom': {
|
|
55
|
-
borderTop: '2px solid black'
|
|
56
|
+
borderTop: '2px solid black',
|
|
56
57
|
},
|
|
57
58
|
'.cm-activeLine': {
|
|
58
|
-
backgroundColor: highlightBackground
|
|
59
|
+
backgroundColor: highlightBackground,
|
|
59
60
|
},
|
|
60
61
|
'.cm-gutters': {
|
|
61
62
|
backgroundColor: base00,
|
|
62
|
-
color: base03
|
|
63
|
+
color: base03,
|
|
63
64
|
},
|
|
64
65
|
'.cm-tooltip': {
|
|
65
|
-
backgroundColor: tooltipBackground
|
|
66
|
-
}
|
|
66
|
+
backgroundColor: tooltipBackground,
|
|
67
|
+
},
|
|
67
68
|
}, { dark: false });
|
|
68
69
|
// Define the highlighting style for code in the GitHub Light theme.
|
|
69
70
|
const githubLightHighlightStyle = /*@__PURE__*/HighlightStyle.define([
|
|
@@ -81,12 +82,12 @@ const githubLightHighlightStyle = /*@__PURE__*/HighlightStyle.define([
|
|
|
81
82
|
{ tag: [tags.url, tags.escape, tags.regexp, tags.link], color: base0A },
|
|
82
83
|
{ tag: tags.link, textDecoration: 'underline' },
|
|
83
84
|
{ tag: tags.strikethrough, textDecoration: 'line-through' },
|
|
84
|
-
{ tag: tags.invalid, color: invalid }
|
|
85
|
+
{ tag: tags.invalid, color: invalid },
|
|
85
86
|
]);
|
|
86
87
|
// Extension to enable the GitHub Light theme (both the editor theme and the highlight style).
|
|
87
88
|
const githubLight = [
|
|
88
89
|
githubLightTheme,
|
|
89
|
-
/*@__PURE__*/syntaxHighlighting(githubLightHighlightStyle)
|
|
90
|
+
/*@__PURE__*/syntaxHighlighting(githubLightHighlightStyle),
|
|
90
91
|
];
|
|
91
92
|
|
|
92
93
|
export { githubLight, githubLightHighlightStyle, githubLightTheme };
|