1 | "use strict";
|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
3 | exports.antvLight = exports.createLightStyleSheet = void 0;
|
4 | var BLACK_COLORS = {
|
5 | 100: '#000',
|
6 | 95: '#0D0D0D',
|
7 | 85: '#262626',
|
8 | 65: '#595959',
|
9 | 45: '#8C8C8C',
|
10 | 25: '#BFBFBF',
|
11 | 15: '#D9D9D9',
|
12 | 6: '#F0F0F0',
|
13 | };
|
14 | var WHITE_COLORS = {
|
15 | 100: '#FFFFFF',
|
16 | 95: '#F2F2F2',
|
17 | 85: '#D9D9D9',
|
18 | 65: '#A6A6A6',
|
19 | 45: '#737373',
|
20 | 25: '#404040',
|
21 | 15: '#262626',
|
22 | 6: '#0F0F0F',
|
23 | };
|
24 | var QUALITATIVE_10 = [
|
25 | '#5B8FF9',
|
26 | '#5AD8A6',
|
27 | '#5D7092',
|
28 | '#F6BD16',
|
29 | '#6F5EF9',
|
30 | '#6DC8EC',
|
31 | '#945FB9',
|
32 | '#FF9845',
|
33 | '#1E9493',
|
34 | '#FF99C3',
|
35 | ];
|
36 | var QUALITATIVE_20 = [
|
37 | '#5B8FF9',
|
38 | '#CDDDFD',
|
39 | '#5AD8A6',
|
40 | '#CDF3E4',
|
41 | '#5D7092',
|
42 | '#CED4DE',
|
43 | '#F6BD16',
|
44 | '#FCEBB9',
|
45 | '#6F5EF9',
|
46 | '#D3CEFD',
|
47 | '#6DC8EC',
|
48 | '#D3EEF9',
|
49 | '#945FB9',
|
50 | '#DECFEA',
|
51 | '#FF9845',
|
52 | '#FFE0C7',
|
53 | '#1E9493',
|
54 | '#BBDEDE',
|
55 | '#FF99C3',
|
56 | '#FFE0ED',
|
57 | ];
|
58 |
|
59 | var SINGLE_SEQUENCE = [
|
60 | '#B8E1FF',
|
61 | '#9AC5FF',
|
62 | '#7DAAFF',
|
63 | '#5B8FF9',
|
64 | '#3D76DD',
|
65 | '#085EC0',
|
66 | '#0047A5',
|
67 | '#00318A',
|
68 | '#001D70',
|
69 | ];
|
70 | var createLightStyleSheet = function (cfg) {
|
71 | if (cfg === void 0) { cfg = {}; }
|
72 | var _a = cfg.backgroundColor, backgroundColor = _a === void 0 ? 'transparent' : _a, _b = cfg.subColor, subColor = _b === void 0 ? 'rgba(0,0,0,0.05)' : _b, _c = cfg.paletteQualitative10, paletteQualitative10 = _c === void 0 ? QUALITATIVE_10 : _c, _d = cfg.paletteQualitative20, paletteQualitative20 = _d === void 0 ? QUALITATIVE_20 : _d, _e = cfg.paletteSemanticRed, paletteSemanticRed = _e === void 0 ? '#F4664A' : _e, _f = cfg.paletteSemanticGreen, paletteSemanticGreen = _f === void 0 ? '#30BF78' : _f, _g = cfg.paletteSemanticYellow, paletteSemanticYellow = _g === void 0 ? '#FAAD14' : _g, _h = cfg.paletteSequence, paletteSequence = _h === void 0 ? SINGLE_SEQUENCE : _h, _j = cfg.fontFamily, fontFamily = _j === void 0 ? "\"Segoe UI\", Roboto, \"Helvetica Neue\", Arial,\n \"Noto Sans\", sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\",\n \"Noto Color Emoji\"" : _j;
|
73 | var _k = cfg.brandColor, brandColor = _k === void 0 ? paletteQualitative10[0] : _k;
|
74 | return {
|
75 |
|
76 | backgroundColor: backgroundColor,
|
77 |
|
78 | brandColor: brandColor,
|
79 |
|
80 | subColor: subColor,
|
81 |
|
82 | paletteQualitative10: paletteQualitative10,
|
83 |
|
84 | paletteQualitative20: paletteQualitative20,
|
85 |
|
86 | paletteSemanticRed: paletteSemanticRed,
|
87 |
|
88 | paletteSemanticGreen: paletteSemanticGreen,
|
89 |
|
90 | paletteSemanticYellow: paletteSemanticYellow,
|
91 |
|
92 | paletteSequence: paletteSequence,
|
93 |
|
94 | fontFamily: fontFamily,
|
95 |
|
96 |
|
97 | axisLineBorderColor: BLACK_COLORS[25],
|
98 |
|
99 | axisLineBorder: 1,
|
100 |
|
101 | axisLineDash: null,
|
102 |
|
103 | axisTitleTextFillColor: BLACK_COLORS[65],
|
104 |
|
105 | axisTitleTextFontSize: 12,
|
106 |
|
107 | axisTitleTextLineHeight: 12,
|
108 |
|
109 | axisTitleTextFontWeight: 'normal',
|
110 |
|
111 | axisTitleSpacing: 12,
|
112 |
|
113 | axisTickLineBorderColor: BLACK_COLORS[25],
|
114 |
|
115 | axisTickLineLength: 4,
|
116 |
|
117 | axisTickLineBorder: 1,
|
118 |
|
119 | axisSubTickLineBorderColor: BLACK_COLORS[15],
|
120 |
|
121 | axisSubTickLineLength: 2,
|
122 |
|
123 | axisSubTickLineBorder: 1,
|
124 |
|
125 | axisLabelFillColor: BLACK_COLORS[45],
|
126 |
|
127 | axisLabelFontSize: 12,
|
128 |
|
129 | axisLabelLineHeight: 12,
|
130 |
|
131 | axisLabelFontWeight: 'normal',
|
132 |
|
133 | axisLabelOffset: 8,
|
134 |
|
135 | axisGridBorderColor: BLACK_COLORS[15],
|
136 |
|
137 | axisGridBorder: 1,
|
138 |
|
139 | axisGridLineDash: null,
|
140 |
|
141 |
|
142 | legendTitleTextFillColor: BLACK_COLORS[45],
|
143 |
|
144 | legendTitleTextFontSize: 12,
|
145 |
|
146 | legendTitleTextLineHeight: 21,
|
147 |
|
148 | legendTitleTextFontWeight: 'normal',
|
149 |
|
150 | legendMarkerColor: brandColor,
|
151 |
|
152 | legendMarkerSpacing: 8,
|
153 |
|
154 | legendMarkerSize: 4,
|
155 |
|
156 | legendCircleMarkerSize: 4,
|
157 |
|
158 | legendSquareMarkerSize: 4,
|
159 |
|
160 | legendLineMarkerSize: 5,
|
161 |
|
162 | legendItemNameFillColor: BLACK_COLORS[65],
|
163 |
|
164 | legendItemNameFontSize: 12,
|
165 |
|
166 | legendItemNameLineHeight: 12,
|
167 |
|
168 | legendItemNameFontWeight: 'normal',
|
169 |
|
170 | legendItemSpacing: 24,
|
171 |
|
172 | legendItemMarginBottom: 12,
|
173 |
|
174 | legendPadding: [8, 8, 8, 8],
|
175 |
|
176 | legendHorizontalPadding: [8, 0, 8, 0],
|
177 |
|
178 | legendVerticalPadding: [0, 8, 0, 8],
|
179 |
|
180 |
|
181 | legendPageNavigatorMarkerSize: 12,
|
182 |
|
183 | legendPageNavigatorMarkerInactiveFillColor: BLACK_COLORS[100],
|
184 |
|
185 | legendPageNavigatorMarkerInactiveFillOpacity: 0.45,
|
186 |
|
187 | legendPageNavigatorMarkerFillColor: BLACK_COLORS[100],
|
188 |
|
189 | legendPageNavigatorMarkerFillOpacity: 1,
|
190 |
|
191 | legendPageNavigatorTextFillColor: BLACK_COLORS[45],
|
192 |
|
193 | legendPageNavigatorTextFontSize: 12,
|
194 |
|
195 | sliderRailFillColor: BLACK_COLORS[15],
|
196 |
|
197 | sliderRailBorder: 0,
|
198 |
|
199 | sliderRailBorderColor: null,
|
200 |
|
201 | sliderRailWidth: 100,
|
202 |
|
203 | sliderRailHeight: 12,
|
204 |
|
205 | sliderLabelTextFillColor: BLACK_COLORS[45],
|
206 |
|
207 | sliderLabelTextFontSize: 12,
|
208 |
|
209 | sliderLabelTextLineHeight: 12,
|
210 |
|
211 | sliderLabelTextFontWeight: 'normal',
|
212 |
|
213 | sliderHandlerFillColor: BLACK_COLORS[6],
|
214 |
|
215 | sliderHandlerWidth: 10,
|
216 |
|
217 | sliderHandlerHeight: 14,
|
218 |
|
219 | sliderHandlerBorder: 1,
|
220 |
|
221 | sliderHandlerBorderColor: BLACK_COLORS[25],
|
222 |
|
223 |
|
224 | annotationArcBorderColor: BLACK_COLORS[15],
|
225 |
|
226 | annotationArcBorder: 1,
|
227 |
|
228 | annotationLineBorderColor: BLACK_COLORS[25],
|
229 |
|
230 | annotationLineBorder: 1,
|
231 |
|
232 | annotationLineDash: null,
|
233 |
|
234 | annotationTextFillColor: BLACK_COLORS[65],
|
235 |
|
236 | annotationTextFontSize: 12,
|
237 |
|
238 | annotationTextLineHeight: 12,
|
239 |
|
240 | annotationTextFontWeight: 'normal',
|
241 |
|
242 | annotationTextBorderColor: null,
|
243 |
|
244 | annotationTextBorder: 0,
|
245 |
|
246 | annotationRegionFillColor: BLACK_COLORS[100],
|
247 |
|
248 | annotationRegionFillOpacity: 0.06,
|
249 |
|
250 | annotationRegionBorder: 0,
|
251 |
|
252 | annotationRegionBorderColor: null,
|
253 |
|
254 | annotationDataMarkerLineLength: 16,
|
255 |
|
256 |
|
257 | tooltipCrosshairsBorderColor: BLACK_COLORS[25],
|
258 |
|
259 | tooltipCrosshairsBorder: 1,
|
260 |
|
261 | tooltipCrosshairsLineDash: null,
|
262 |
|
263 | tooltipContainerFillColor: 'rgb(255, 255, 255)',
|
264 | tooltipContainerFillOpacity: 0.95,
|
265 |
|
266 | tooltipContainerShadow: '0px 0px 10px #aeaeae',
|
267 |
|
268 | tooltipContainerBorderRadius: 3,
|
269 |
|
270 | tooltipTextFillColor: BLACK_COLORS[65],
|
271 |
|
272 | tooltipTextFontSize: 12,
|
273 |
|
274 | tooltipTextLineHeight: 12,
|
275 |
|
276 | tooltipTextFontWeight: 'bold',
|
277 |
|
278 |
|
279 | labelFillColor: BLACK_COLORS[65],
|
280 | labelFillColorDark: '#2c3542',
|
281 | labelFillColorLight: '#ffffff',
|
282 |
|
283 | labelFontSize: 12,
|
284 |
|
285 | labelLineHeight: 12,
|
286 |
|
287 | labelFontWeight: 'normal',
|
288 |
|
289 | labelBorderColor: null,
|
290 |
|
291 | labelBorder: 0,
|
292 |
|
293 | innerLabelFillColor: WHITE_COLORS[100],
|
294 |
|
295 | innerLabelFontSize: 12,
|
296 |
|
297 | innerLabelLineHeight: 12,
|
298 |
|
299 | innerLabelFontWeight: 'normal',
|
300 |
|
301 | innerLabelBorderColor: null,
|
302 |
|
303 | innerLabelBorder: 0,
|
304 |
|
305 | overflowLabelFillColor: BLACK_COLORS[65],
|
306 |
|
307 | overflowLabelFontSize: 12,
|
308 |
|
309 | overflowLabelLineHeight: 12,
|
310 |
|
311 | overflowLabelFontWeight: 'normal',
|
312 |
|
313 | overflowLabelBorderColor: WHITE_COLORS[100],
|
314 |
|
315 | overflowLabelBorder: 1,
|
316 |
|
317 | labelLineBorder: 1,
|
318 |
|
319 | labelLineBorderColor: BLACK_COLORS[25],
|
320 |
|
321 |
|
322 | cSliderRailHieght: 16,
|
323 |
|
324 | cSliderBackgroundFillColor: '#416180',
|
325 |
|
326 | cSliderBackgroundFillOpacity: 0.05,
|
327 |
|
328 | cSliderForegroundFillColor: '#5B8FF9',
|
329 |
|
330 | cSliderForegroundFillOpacity: 0.15,
|
331 |
|
332 |
|
333 | cSliderHandlerHeight: 24,
|
334 |
|
335 | cSliderHandlerWidth: 10,
|
336 |
|
337 | cSliderHandlerFillColor: '#F7F7F7',
|
338 |
|
339 | cSliderHandlerFillOpacity: 1,
|
340 |
|
341 | cSliderHandlerHighlightFillColor: '#FFF',
|
342 |
|
343 | cSliderHandlerBorderColor: '#BFBFBF',
|
344 |
|
345 | cSliderHandlerBorder: 1,
|
346 |
|
347 | cSliderHandlerBorderRadius: 2,
|
348 |
|
349 |
|
350 | cSliderTextFillColor: '#000',
|
351 |
|
352 | cSliderTextFillOpacity: 0.45,
|
353 |
|
354 | cSliderTextFontSize: 12,
|
355 |
|
356 | cSliderTextLineHeight: 12,
|
357 |
|
358 | cSliderTextFontWeight: 'normal',
|
359 |
|
360 | cSliderTextBorderColor: null,
|
361 |
|
362 | cSliderTextBorder: 0,
|
363 |
|
364 |
|
365 | scrollbarTrackFillColor: 'rgba(0,0,0,0)',
|
366 |
|
367 | scrollbarThumbFillColor: 'rgba(0,0,0,0.15)',
|
368 |
|
369 | scrollbarThumbHighlightFillColor: 'rgba(0,0,0,0.2)',
|
370 |
|
371 |
|
372 | pointFillColor: brandColor,
|
373 |
|
374 | pointFillOpacity: 0.95,
|
375 |
|
376 | pointSize: 4,
|
377 |
|
378 | pointBorder: 1,
|
379 |
|
380 | pointBorderColor: WHITE_COLORS[100],
|
381 |
|
382 | pointBorderOpacity: 1,
|
383 |
|
384 | pointActiveBorderColor: BLACK_COLORS[100],
|
385 |
|
386 | pointSelectedBorder: 2,
|
387 |
|
388 | pointSelectedBorderColor: BLACK_COLORS[100],
|
389 |
|
390 | pointInactiveFillOpacity: 0.3,
|
391 |
|
392 | pointInactiveBorderOpacity: 0.3,
|
393 |
|
394 | hollowPointSize: 4,
|
395 |
|
396 | hollowPointBorder: 1,
|
397 |
|
398 | hollowPointBorderColor: brandColor,
|
399 |
|
400 | hollowPointBorderOpacity: 0.95,
|
401 | hollowPointFillColor: WHITE_COLORS[100],
|
402 |
|
403 | hollowPointActiveBorder: 1,
|
404 |
|
405 | hollowPointActiveBorderColor: BLACK_COLORS[100],
|
406 |
|
407 | hollowPointActiveBorderOpacity: 1,
|
408 |
|
409 | hollowPointSelectedBorder: 2,
|
410 |
|
411 | hollowPointSelectedBorderColor: BLACK_COLORS[100],
|
412 |
|
413 | hollowPointSelectedBorderOpacity: 1,
|
414 |
|
415 | hollowPointInactiveBorderOpacity: 0.3,
|
416 |
|
417 | lineBorder: 2,
|
418 |
|
419 | lineBorderColor: brandColor,
|
420 |
|
421 | lineBorderOpacity: 1,
|
422 |
|
423 | lineActiveBorder: 3,
|
424 |
|
425 | lineSelectedBorder: 3,
|
426 |
|
427 | lineInactiveBorderOpacity: 0.3,
|
428 |
|
429 | areaFillColor: brandColor,
|
430 |
|
431 | areaFillOpacity: 0.25,
|
432 |
|
433 | areaActiveFillColor: brandColor,
|
434 | areaActiveFillOpacity: 0.5,
|
435 |
|
436 | areaSelectedFillColor: brandColor,
|
437 | areaSelectedFillOpacity: 0.5,
|
438 |
|
439 | areaInactiveFillOpacity: 0.3,
|
440 |
|
441 | hollowAreaBorderColor: brandColor,
|
442 |
|
443 | hollowAreaBorder: 2,
|
444 |
|
445 | hollowAreaBorderOpacity: 1,
|
446 |
|
447 | hollowAreaActiveBorder: 3,
|
448 | hollowAreaActiveBorderColor: BLACK_COLORS[100],
|
449 |
|
450 | hollowAreaSelectedBorder: 3,
|
451 | hollowAreaSelectedBorderColor: BLACK_COLORS[100],
|
452 |
|
453 | hollowAreaInactiveBorderOpacity: 0.3,
|
454 |
|
455 | intervalFillColor: brandColor,
|
456 |
|
457 | intervalFillOpacity: 0.95,
|
458 |
|
459 | intervalActiveBorder: 1,
|
460 |
|
461 | intervalActiveBorderColor: BLACK_COLORS[100],
|
462 | intervalActiveBorderOpacity: 1,
|
463 |
|
464 | intervalSelectedBorder: 2,
|
465 |
|
466 | intervalSelectedBorderColor: BLACK_COLORS[100],
|
467 |
|
468 | intervalSelectedBorderOpacity: 1,
|
469 |
|
470 | intervalInactiveBorderOpacity: 0.3,
|
471 |
|
472 | intervalInactiveFillOpacity: 0.3,
|
473 |
|
474 | hollowIntervalBorder: 2,
|
475 |
|
476 | hollowIntervalBorderColor: brandColor,
|
477 |
|
478 | hollowIntervalBorderOpacity: 1,
|
479 | hollowIntervalFillColor: WHITE_COLORS[100],
|
480 |
|
481 | hollowIntervalActiveBorder: 2,
|
482 |
|
483 | hollowIntervalActiveBorderColor: BLACK_COLORS[100],
|
484 |
|
485 | hollowIntervalSelectedBorder: 3,
|
486 |
|
487 | hollowIntervalSelectedBorderColor: BLACK_COLORS[100],
|
488 |
|
489 | hollowIntervalSelectedBorderOpacity: 1,
|
490 |
|
491 | hollowIntervalInactiveBorderOpacity: 0.3,
|
492 | };
|
493 | };
|
494 | exports.createLightStyleSheet = createLightStyleSheet;
|
495 | exports.antvLight = (0, exports.createLightStyleSheet)();
|
496 |
|
\ | No newline at end of file |