@fsegurai/codemirror-theme-github-light 6.2.0-beta.1 → 6.2.0-beta.3
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 +33 -33
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
var view = require('@codemirror/view');
|
|
4
4
|
var language = require('@codemirror/language');
|
|
5
5
|
var highlight = require('@lezer/highlight');
|
|
6
|
-
var
|
|
6
|
+
var codemirrorThemeUtils = require('@fsegurai/codemirror-theme-utils');
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* Enhanced GitHub Light theme color palette
|
|
@@ -50,17 +50,17 @@ const githubLightTheme = view.EditorView.theme({
|
|
|
50
50
|
'&': {
|
|
51
51
|
color: base01,
|
|
52
52
|
backgroundColor: base00,
|
|
53
|
-
fontSize:
|
|
54
|
-
fontFamily:
|
|
53
|
+
fontSize: codemirrorThemeUtils.generalContent.fontSize,
|
|
54
|
+
fontFamily: codemirrorThemeUtils.generalContent.fontFamily,
|
|
55
55
|
},
|
|
56
56
|
// Content and cursor
|
|
57
57
|
'.cm-content': {
|
|
58
58
|
caretColor: cursor,
|
|
59
|
-
lineHeight:
|
|
59
|
+
lineHeight: codemirrorThemeUtils.generalContent.lineHeight,
|
|
60
60
|
},
|
|
61
61
|
'.cm-cursor, .cm-dropCursor': {
|
|
62
62
|
borderLeftColor: cursor,
|
|
63
|
-
borderLeftWidth:
|
|
63
|
+
borderLeftWidth: codemirrorThemeUtils.generalCursor.borderLeftWidth,
|
|
64
64
|
},
|
|
65
65
|
'.cm-fat-cursor': {
|
|
66
66
|
backgroundColor: `${cursor}99`,
|
|
@@ -80,7 +80,7 @@ const githubLightTheme = view.EditorView.theme({
|
|
|
80
80
|
backgroundColor: '#daebff',
|
|
81
81
|
outline: `1px solid ${base08}`,
|
|
82
82
|
color: base01,
|
|
83
|
-
borderRadius:
|
|
83
|
+
borderRadius: codemirrorThemeUtils.generalSearchField.borderRadius,
|
|
84
84
|
'& span': {
|
|
85
85
|
color: base01,
|
|
86
86
|
},
|
|
@@ -88,15 +88,15 @@ const githubLightTheme = view.EditorView.theme({
|
|
|
88
88
|
'.cm-searchMatch.cm-searchMatch-selected': {
|
|
89
89
|
backgroundColor: '#79b8ff',
|
|
90
90
|
color: base00,
|
|
91
|
-
padding:
|
|
91
|
+
padding: codemirrorThemeUtils.generalSearchField.padding,
|
|
92
92
|
'& span': {
|
|
93
93
|
color: base00,
|
|
94
94
|
},
|
|
95
95
|
},
|
|
96
96
|
'.cm-search.cm-panel.cm-textfield': {
|
|
97
97
|
color: base01,
|
|
98
|
-
borderRadius:
|
|
99
|
-
padding:
|
|
98
|
+
borderRadius: codemirrorThemeUtils.generalSearchField.borderRadius,
|
|
99
|
+
padding: codemirrorThemeUtils.generalSearchField.padding,
|
|
100
100
|
},
|
|
101
101
|
// Panels
|
|
102
102
|
'.cm-panels': {
|
|
@@ -113,9 +113,9 @@ const githubLightTheme = view.EditorView.theme({
|
|
|
113
113
|
'.cm-panel button': {
|
|
114
114
|
backgroundColor: base00,
|
|
115
115
|
color: base01,
|
|
116
|
-
border:
|
|
117
|
-
borderRadius:
|
|
118
|
-
padding:
|
|
116
|
+
border: codemirrorThemeUtils.generalPanel.border,
|
|
117
|
+
borderRadius: codemirrorThemeUtils.generalPanel.borderRadius,
|
|
118
|
+
padding: codemirrorThemeUtils.generalPanel.padding,
|
|
119
119
|
},
|
|
120
120
|
'.cm-panel button:hover': {
|
|
121
121
|
backgroundColor: '#f5f5f5',
|
|
@@ -123,27 +123,27 @@ const githubLightTheme = view.EditorView.theme({
|
|
|
123
123
|
// Line highlighting
|
|
124
124
|
'.cm-activeLine': {
|
|
125
125
|
backgroundColor: highlightBackground,
|
|
126
|
-
borderRadius:
|
|
126
|
+
borderRadius: codemirrorThemeUtils.generalLine.borderRadius,
|
|
127
127
|
zIndex: 1,
|
|
128
128
|
},
|
|
129
129
|
// Gutters
|
|
130
130
|
'.cm-gutters': {
|
|
131
131
|
backgroundColor: base04,
|
|
132
132
|
color: base03,
|
|
133
|
-
border:
|
|
133
|
+
border: codemirrorThemeUtils.generalGutter.border,
|
|
134
134
|
borderRight: `1px solid ${base0E}`,
|
|
135
|
-
paddingRight:
|
|
135
|
+
paddingRight: codemirrorThemeUtils.generalGutter.paddingRight,
|
|
136
136
|
},
|
|
137
137
|
'.cm-activeLineGutter': {
|
|
138
138
|
backgroundColor: base0D,
|
|
139
139
|
color: base01,
|
|
140
|
-
fontWeight:
|
|
140
|
+
fontWeight: codemirrorThemeUtils.generalGutter.fontWeight,
|
|
141
141
|
},
|
|
142
142
|
'.cm-lineNumbers': {
|
|
143
|
-
fontSize:
|
|
143
|
+
fontSize: codemirrorThemeUtils.generalGutter.fontSize,
|
|
144
144
|
},
|
|
145
145
|
'.cm-foldGutter': {
|
|
146
|
-
fontSize:
|
|
146
|
+
fontSize: codemirrorThemeUtils.generalGutter.fontSize,
|
|
147
147
|
},
|
|
148
148
|
'.cm-foldGutter .cm-gutterElement': {
|
|
149
149
|
color: base03,
|
|
@@ -156,8 +156,8 @@ const githubLightTheme = view.EditorView.theme({
|
|
|
156
156
|
'.cm-tooltip': {
|
|
157
157
|
backgroundColor: tooltipBackground,
|
|
158
158
|
border: `1px solid ${base0E}`,
|
|
159
|
-
borderRadius:
|
|
160
|
-
padding:
|
|
159
|
+
borderRadius: codemirrorThemeUtils.generalTooltip.borderRadius,
|
|
160
|
+
padding: codemirrorThemeUtils.generalTooltip.padding,
|
|
161
161
|
boxShadow: '0 1px 5px rgba(0, 0, 0, 0.1)',
|
|
162
162
|
},
|
|
163
163
|
'.cm-tooltip-autocomplete': {
|
|
@@ -166,20 +166,20 @@ const githubLightTheme = view.EditorView.theme({
|
|
|
166
166
|
border: 'none',
|
|
167
167
|
},
|
|
168
168
|
'& > ul > li': {
|
|
169
|
-
padding:
|
|
170
|
-
lineHeight:
|
|
169
|
+
padding: codemirrorThemeUtils.generalTooltip.padding,
|
|
170
|
+
lineHeight: codemirrorThemeUtils.generalTooltip.lineHeight,
|
|
171
171
|
},
|
|
172
172
|
'& > ul > li[aria-selected]': {
|
|
173
173
|
backgroundColor: '#0366d630',
|
|
174
174
|
color: base01,
|
|
175
|
-
borderRadius:
|
|
175
|
+
borderRadius: codemirrorThemeUtils.generalTooltip.borderRadiusSelected,
|
|
176
176
|
},
|
|
177
177
|
'& > ul > li:hover': {
|
|
178
178
|
backgroundColor: '#0366d615',
|
|
179
179
|
},
|
|
180
180
|
'& > ul > li > span.cm-completionIcon': {
|
|
181
181
|
color: base03,
|
|
182
|
-
paddingRight:
|
|
182
|
+
paddingRight: codemirrorThemeUtils.generalTooltip.paddingRight,
|
|
183
183
|
},
|
|
184
184
|
'& > ul > li > span.cm-completionDetail': {
|
|
185
185
|
color: base03,
|
|
@@ -216,27 +216,27 @@ const githubLightTheme = view.EditorView.theme({
|
|
|
216
216
|
'.cm-matchingBracket': {
|
|
217
217
|
backgroundColor: activeBracketBg,
|
|
218
218
|
outline: `1px solid ${activeBracketBorder}80`,
|
|
219
|
-
borderRadius:
|
|
219
|
+
borderRadius: codemirrorThemeUtils.generalMatching.borderRadius,
|
|
220
220
|
},
|
|
221
221
|
'.cm-nonmatchingBracket': {
|
|
222
222
|
backgroundColor: '#ffeef080',
|
|
223
223
|
outline: `1px solid ${invalid}`,
|
|
224
|
-
borderRadius:
|
|
224
|
+
borderRadius: codemirrorThemeUtils.generalMatching.borderRadius,
|
|
225
225
|
},
|
|
226
226
|
// Selection matches
|
|
227
227
|
'.cm-selectionMatch': {
|
|
228
228
|
backgroundColor: selectionMatch,
|
|
229
229
|
outline: `1px solid ${base02}50`,
|
|
230
|
-
borderRadius:
|
|
230
|
+
borderRadius: codemirrorThemeUtils.generalMatching.borderRadius,
|
|
231
231
|
},
|
|
232
232
|
// Fold placeholder
|
|
233
233
|
'.cm-foldPlaceholder': {
|
|
234
234
|
backgroundColor: selectionMatch,
|
|
235
235
|
color: base03,
|
|
236
236
|
border: `1px dotted ${base0E}70`,
|
|
237
|
-
borderRadius:
|
|
238
|
-
padding:
|
|
239
|
-
margin:
|
|
237
|
+
borderRadius: codemirrorThemeUtils.generalPlaceholder.borderRadius,
|
|
238
|
+
padding: codemirrorThemeUtils.generalPlaceholder.padding,
|
|
239
|
+
margin: codemirrorThemeUtils.generalPlaceholder.margin,
|
|
240
240
|
},
|
|
241
241
|
// Focus outline
|
|
242
242
|
'&.cm-focused': {
|
|
@@ -245,15 +245,15 @@ const githubLightTheme = view.EditorView.theme({
|
|
|
245
245
|
},
|
|
246
246
|
// Scrollbars
|
|
247
247
|
'& .cm-scroller::-webkit-scrollbar': {
|
|
248
|
-
width:
|
|
249
|
-
height:
|
|
248
|
+
width: codemirrorThemeUtils.generalScroller.width,
|
|
249
|
+
height: codemirrorThemeUtils.generalScroller.height,
|
|
250
250
|
},
|
|
251
251
|
'& .cm-scroller::-webkit-scrollbar-track': {
|
|
252
252
|
background: base0E,
|
|
253
253
|
},
|
|
254
254
|
'& .cm-scroller::-webkit-scrollbar-thumb': {
|
|
255
255
|
backgroundColor: base01,
|
|
256
|
-
borderRadius:
|
|
256
|
+
borderRadius: codemirrorThemeUtils.generalScroller.borderRadius,
|
|
257
257
|
border: `3px solid ${base0E}`,
|
|
258
258
|
},
|
|
259
259
|
'& .cm-scroller::-webkit-scrollbar-thumb:hover': {
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { EditorView } from '@codemirror/view';
|
|
2
2
|
import { HighlightStyle, syntaxHighlighting } from '@codemirror/language';
|
|
3
3
|
import { tags } from '@lezer/highlight';
|
|
4
|
-
import { generalScroller, generalPlaceholder, generalMatching, generalTooltip, generalGutter, generalLine, generalPanel, generalSearchField, generalCursor, generalContent } from '@utils';
|
|
4
|
+
import { generalScroller, generalPlaceholder, generalMatching, generalTooltip, generalGutter, generalLine, generalPanel, generalSearchField, generalCursor, generalContent } from '@fsegurai/codemirror-theme-utils';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Enhanced GitHub Light theme color palette
|
package/package.json
CHANGED