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