@akinon/ui-theme 0.7.0 → 1.0.1

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/esm/theme.js CHANGED
@@ -48,14 +48,99 @@ export const theme = {
48
48
  fontFamily: "'Jost Variable'," + antdTheme.getDesignToken().fontFamily,
49
49
  fontSize: fontSize * 0.875
50
50
  },
51
+ CustomTokens: {
52
+ layout: {
53
+ displayFlex: 'flex',
54
+ displayGrid: 'grid',
55
+ displayBlock: 'block',
56
+ displayInline: 'inline',
57
+ displayInlineBlock: 'inline-block',
58
+ displayNone: 'none',
59
+ displayContents: 'contents',
60
+ positionAbsolute: 'absolute',
61
+ positionRelative: 'relative',
62
+ positionFixed: 'fixed',
63
+ positionSticky: 'sticky',
64
+ positionStatic: 'static',
65
+ flexStart: 'start',
66
+ flexCenter: 'center',
67
+ flexDirectionRow: 'row',
68
+ flexDirectionRowReverse: 'row-reverse',
69
+ flexDirectionColumn: 'column',
70
+ flexDirectionColumnReverse: 'column-reverse'
71
+ },
72
+ typography: {
73
+ textTransformUppercase: 'uppercase',
74
+ textTransformLowercase: 'lowercase',
75
+ textTransformCapitalize: 'capitalize',
76
+ textAlignLeft: 'left',
77
+ textAlignCenter: 'center',
78
+ textAlignRight: 'right',
79
+ textAlignJustify: 'justify',
80
+ whiteSpaceNormal: 'normal',
81
+ whiteSpaceNoWrap: 'nowrap',
82
+ whiteSpacePre: 'pre',
83
+ whiteSpacePreLine: 'pre-line',
84
+ whiteSpacePreWrap: 'pre-wrap',
85
+ whiteSpaceBreakSpaces: 'break-spaces',
86
+ wordBreak: 'break-word',
87
+ textDecorationUnderline: 'underline',
88
+ textDecorationOverline: 'overline',
89
+ textDecorationLineThrough: 'line-through',
90
+ fontWeightBold: '600',
91
+ fontWeightMedium: '500'
92
+ },
93
+ sizing: {
94
+ sizeMaxContent: 'max-content',
95
+ sizeMinContent: 'min-content',
96
+ sizeFitContent: 'fit-content',
97
+ valueFull: '100%',
98
+ valueThreeQuarter: '75%',
99
+ valueHalf: '50%',
100
+ valueQuarter: '25%',
101
+ valueZero: '0',
102
+ valueAuto: 'auto',
103
+ valueInherit: 'inherit'
104
+ },
105
+ others: {
106
+ colorTransparent: 'transparent',
107
+ valueHidden: 'hidden',
108
+ valueUnset: 'unset',
109
+ emptyContent: '""',
110
+ lineHeightShort: '1',
111
+ lineHeightTall: '2',
112
+ cursorNotAllowed: 'not-allowed',
113
+ cursorPointer: 'pointer',
114
+ verticalAlignMiddle: 'middle',
115
+ opacityFull: '1',
116
+ opacityNone: '0'
117
+ },
118
+ border: {
119
+ borderNone: 'none',
120
+ borderSolid: 'solid',
121
+ borderDashed: 'dashed',
122
+ borderDotted: 'dotted',
123
+ borderWidthThin: '1px',
124
+ borderWidthThick: '2px',
125
+ borderRadiusSm: '0.125rem'
126
+ },
127
+ overflow: {
128
+ overflowVisible: 'visible',
129
+ overflowHidden: 'hidden',
130
+ overflowScroll: 'scroll'
131
+ }
132
+ },
133
+ NavCardTokens: {
134
+ shadow: '2px 2px 4px 0 rgba(0, 0, 0, 0.2)'
135
+ },
51
136
  components: {
137
+ // TODO: Please order these props alphabetically.
52
138
  Button: {
53
139
  // type: primary
54
140
  colorPrimary: colors.azure['500'],
55
141
  colorPrimaryHover: colors.azure['600'],
56
142
  colorPrimaryActive: colors.azure['700'],
57
143
  colorPrimaryText: colors.neutral['50'],
58
- primaryShadow: 'unset',
59
144
  // type: default (secondary)
60
145
  defaultBg: colors.neutral['50'],
61
146
  defaultColor: colors.azure['500'],
@@ -64,7 +149,6 @@ export const theme = {
64
149
  defaultActiveBg: colors.neutral['50'],
65
150
  defaultActiveColor: colors.azure['500'],
66
151
  defaultBorderColor: colors.azure['500'],
67
- defaultShadow: 'unset',
68
152
  defaultBgSm: colors.gray['750'],
69
153
  defaultBgSmHover: colors.gray['800'],
70
154
  // prop: danger
@@ -72,7 +156,6 @@ export const theme = {
72
156
  colorErrorHover: colors.red['500'],
73
157
  colorErrorActive: colors.red['600'],
74
158
  colorErrorBorder: colors.red['500'],
75
- dangerShadow: 'unset',
76
159
  colorErrorBgSM: colors.red['425'],
77
160
  colorErrorBgSMHover: colors.red['450'],
78
161
  colorErrorSMHover: colors.neutral['50'],
@@ -92,7 +175,6 @@ export const theme = {
92
175
  colorTextDisabled: colors.neutral['350'],
93
176
  borderColorDisabled: colors.neutral['350'],
94
177
  // prop: ghost
95
- defaultGhostBorderColor: 'transparent',
96
178
  defaultGhostColor: colors.azure['500'],
97
179
  // all buttons
98
180
  contentFontSizeSM: fontSize * 0.75,
@@ -101,13 +183,15 @@ export const theme = {
101
183
  paddingInlineSM: 20,
102
184
  colorText: colors.neutral['50'],
103
185
  colorTextHover: colors.neutral['50'],
104
- contentLineHeightSM: 1,
105
186
  controlHeight: 40,
106
187
  borderRadius: 5,
107
188
  paddingBlock: 10,
108
189
  paddingInline: 45,
109
- contentLineHeight: 1,
110
- fontWeight: 600
190
+ contentLineHeight: 'normal',
191
+ fontWeight: 600,
192
+ defaultShadow: 'none',
193
+ primaryShadow: 'none',
194
+ dangerShadow: 'none'
111
195
  },
112
196
  Checkbox: {
113
197
  colorPrimary: colors.ebonyClay['25'],
@@ -136,21 +220,44 @@ export const theme = {
136
220
  },
137
221
  Layout: {
138
222
  headerBg: colors.ebonyClay['500'],
139
- siderBg: colors.ebonyClay['500']
223
+ siderBg: colors.ebonyClay['500'],
224
+ mainBorder: `1px solid ${colors.gray['900']}`
140
225
  },
141
226
  Dropdown: {
142
227
  colorPrimary: colors.neutral['100'], // primary color (azure500) doesn't work well with dropdown bg
143
228
  controlPaddingHorizontal: fontSize
144
229
  },
145
230
  Menu: {
231
+ minWidth: '250px',
146
232
  darkItemBg: colors.ebonyClay['500'],
147
233
  darkSubMenuItemBg: colors.ebonyClay['600'],
148
234
  darkItemSelectedBg: colors.ebonyClay['700'],
149
- itemBorderRadius: 0,
150
- itemMarginBlock: 0,
151
- itemMarginInline: 0,
152
235
  darkItemColor: colors.gray['500'],
153
- itemHeight: fontSize * 3.25
236
+ lightItemBg: `${colors.neutral['50']} !important`,
237
+ lightItemMainIconColor: `${colors.azure['500']} !important`,
238
+ lightItemMainTitle: `${colors.ebonyClay['500']} !important`,
239
+ LightSubItemBg: `${colors.neutral['90']} !important`,
240
+ lightSubTitleColor: `${colors.gray['500']} !important`,
241
+ lightSubIconColor: `${colors.ebonyClay['125']} !important`,
242
+ lightchildItemBg: `${colors.neutral['350']} !important`,
243
+ lightChildItemColor: `${colors.ebonyClay['500']} !important`,
244
+ itemHeight: fontSize * 3.25,
245
+ mainBorder: `1px solid ${colors.gray['900']}`,
246
+ mainMenuIconSize: '12px !important',
247
+ mainMenuExpandIconSize: '16px !important',
248
+ mainMenuColor: `${colors.neutral['50']} !important`,
249
+ subMenuTitleColor: `${colors.gray['500']} !important`,
250
+ subMenuTitleIconMargin: '-25px !important',
251
+ subMenuOnlyChildSize: '6px !important',
252
+ subMenuItemSelectedChildColor: `${colors.neutral['50']} !important`,
253
+ subMenuOnlyChildBgColor: `${colors.ebonyClay['125']} !important`,
254
+ subMenuOnlyChildMargin: '-23px !important',
255
+ subMenuIconSize: '10px !important',
256
+ childMenuItemSelectedChildWidth: '10px !important',
257
+ childMenuItemSelectedChildHeight: '2px !important',
258
+ childMenuItemSelectedChildRadius: '1px !important',
259
+ childMenuItemSelectedChildMargin: '-17px !important',
260
+ childMenuItemSelectedChildBgColor: `${colors.ebonyClay['125']} !important`
154
261
  },
155
262
  Breadcrumb: {
156
263
  fontSize: fontSize * 0.625,
@@ -165,9 +272,7 @@ export const theme = {
165
272
  fontWeight: 600,
166
273
  lineHeight: 1.5,
167
274
  separatorColor: colors.azure['500'],
168
- letterSpacing: fontSize * 0.03,
169
- marginInline: 0,
170
- height: 'auto'
275
+ letterSpacing: fontSize * 0.03
171
276
  },
172
277
  Tag: {
173
278
  defaultColorSuccess: colors.green['951'],
@@ -185,12 +290,14 @@ export const theme = {
185
290
  defaultColorFailed: colors.red['951'],
186
291
  defaultBorderColorFailed: colors.red['450'],
187
292
  defaultBgFailed: colors.red['952'],
293
+ defaultColorEmpty: colors.ebonyClay['400'],
294
+ defaultBorderColorEmpty: colors.neutral['350'],
295
+ defaultBgEmpty: colors.neutral['200'],
188
296
  borderRadius: 5,
189
297
  fontSize: fontSize * 0.8125,
190
298
  paddingLeft: 15,
191
299
  paddingRight: 15,
192
- fontSizeClose: fontSize * 0.6875,
193
- fontWeight: 500
300
+ fontSizeClose: fontSize * 0.6875
194
301
  },
195
302
  Tooltip: {
196
303
  bgColor: colors.ebonyClay['951']
@@ -249,14 +356,73 @@ export const theme = {
249
356
  verticalErrorPadding: '7px 0'
250
357
  },
251
358
  Pagination: {
252
- colorText: colors.ebonyClay['950'],
253
- itemInputBg: colors.neutral['75'],
254
- colorBorder: colors.neutral['350'],
255
- borderRadius: 4,
256
- itemActiveBg: colors.blue['200'],
257
- colorTextDisabled: colors.neutral['375'],
258
- marginXS: 0,
259
- itemSizeSM: 38
359
+ fontSize: '14px !important',
360
+ Simple: {
361
+ minWidth: '68.56px !important',
362
+ fontWeight: 'normal !important',
363
+ color: `${colors.gray['500']} !important`,
364
+ input: {
365
+ textColor: `${colors.ebonyClay['960']} !important`
366
+ },
367
+ prevNextButton: {
368
+ svgWidth: '10px !important',
369
+ svgFill: `${colors.gray['500']} !important`
370
+ },
371
+ slashPadding: '8px !important',
372
+ lightInputTextColor: `${colors.ebonyClay['960']} !important`,
373
+ darkInputTextColor: `${colors.neutral['50']} !important`
374
+ },
375
+ Table: {
376
+ totalText: {
377
+ color: `${colors.gray['500']} !important`,
378
+ margin: 'auto 32px !important'
379
+ },
380
+ prevNextButton: {
381
+ svgWidth: '10px !important',
382
+ svgFill: `${colors.gray['500']} !important`,
383
+ svgPadding: '14px 14px !important',
384
+ svgBorder: `1px solid ${colors.neutral['350']} !important`,
385
+ prevSvgBorderRadius: '5px 0 0 5px !important',
386
+ nextSvgBorderRadius: '0 5px 5px 0 !important'
387
+ },
388
+ pageInfo: {
389
+ border: `1px solid ${colors.neutral['350']} !important`,
390
+ padding: '12px 10px !important',
391
+ currentPageBgColor: `${colors.neutral['75']} !important`,
392
+ currentPageMinWidth: '18px !important',
393
+ currentPageTextColor: `${colors.ebonyClay['960']} !important`,
394
+ currentPageFontWeight: '600 !important',
395
+ totalPageBgColor: `${colors.neutral['50']} !important`,
396
+ totalPageTextColor: `${colors.gray['500']} !important`
397
+ },
398
+ sizeChanger: {
399
+ bgColor: `${colors.neutral['50']} !important`,
400
+ textColor: `${colors.ebonyClay['951']} !important`,
401
+ colGap: '10px !important',
402
+ border: `1px solid ${colors.neutral['350']} !important`,
403
+ borderRadius: '5px !important',
404
+ item1: {
405
+ bgColor: `${colors.neutral['50']} !important`,
406
+ textColor: `${colors.ebonyClay['951']} !important`,
407
+ padding: '10px 16px !important'
408
+ },
409
+ item2: {
410
+ textColor: `${colors.gray['500']} !important`
411
+ },
412
+ icon: {
413
+ bgColor: `${colors.neutral['50']} !important`,
414
+ textColor: `${colors.gray['500']} !important`,
415
+ width: '10px !important'
416
+ }
417
+ }
418
+ },
419
+ Jumper: {
420
+ border: `1px solid ${colors.neutral['350']} !important`,
421
+ bgColor: `${colors.neutral['75']} !important`,
422
+ textColor: `${colors.ebonyClay['960']} !important`,
423
+ minWidth: '18px',
424
+ height: 'calc(100% - 3px)'
425
+ }
260
426
  },
261
427
  Select: {
262
428
  colorTextDisabled: colors.ebonyClay['350'],
@@ -264,7 +430,25 @@ export const theme = {
264
430
  colorBgContainer: colors.ebonyClay['475'],
265
431
  fontSizeLG: fontSize * 0.875,
266
432
  colorBorder: colors.ebonyClay['550'],
267
- lineWidth: 2
433
+ lineWidth: 2,
434
+ colorBgElevated: '#fffcfc',
435
+ optionActiveBg: 'rgba(68, 130, 255, 0.2)',
436
+ colorText: '#9b9b9b',
437
+ selectedOptionColor: 'black',
438
+ selectItemBorderShadowColor: '#eaeff0',
439
+ selectItemBgColor: 'rgba(245, 245, 245, 0.5)',
440
+ selectItemHoverBgColor: 'rgba(68, 130, 255, 0.2)'
441
+ },
442
+ Table: {
443
+ headerBorderRadius: 0,
444
+ headerBg: 'transparent',
445
+ headerColor: '#9b9b9b',
446
+ headerSplitColor: 'transparent',
447
+ colorBgContainer: 'transparent',
448
+ rowHoverBg: 'unset',
449
+ borderColor: colors.neutral['350'],
450
+ cellPaddingInline: 0,
451
+ fontSize: fontSize
268
452
  },
269
453
  Input: {
270
454
  colorBgContainer: colors.ebonyClay['475'],
@@ -287,63 +471,52 @@ export const theme = {
287
471
  Modal: {
288
472
  titleFontSize: fontSize * 1.25,
289
473
  padding: '20px 35px',
290
- fontWeight: 500,
291
474
  borderBottom: `1px solid ${colors.blue['954']}`,
292
475
  footerPadding: '0 35px 20px 35px',
293
476
  closeIconColor: colors.neutral['100'],
294
- contentPadding: 0,
295
- footerMarginTop: 0,
296
477
  closeTop: 20,
297
478
  closeRight: 27,
298
- headerMarginBottom: 0,
299
- badgeColorContent: '',
300
479
  badgeColorTop: 27,
301
- badgeColorLeft: 0,
302
480
  badgeColorWidth: 4,
303
481
  badgeColorHeight: 16,
304
- badgeColorPosition: 'absolute',
305
482
  badgeColorBackgroundColor: colors.red['425']
306
483
  },
307
484
  Progress: {
308
- strokeColor: colors.green['100'],
309
- trailColor: colors.ebonyClay['850'],
310
- borderRadius: '0',
485
+ strokeColor: colors.ebonyClay['625'],
486
+ trailColor: colors.neutral['50'],
311
487
  height: '18px !important',
312
488
  successBgColor: 'repeating-linear-gradient(60deg, rgba(36, 180, 19, 1) 0, rgba(36, 180, 19, 1) 5px, rgba(72, 192, 62, 1) 5px, rgba(72, 192, 62, 1) 10px) !important'
313
489
  },
314
490
  Steps: {
315
- zero: '0 !important',
316
- auto: 'auto !important',
317
- none: 'none !important',
318
- full: '100% !important',
319
- flex: 'flex !important',
320
491
  rowGap: '10px',
321
492
  iconWidthHeight: '38px !important',
322
493
  iconSize: '18px !important',
323
494
  paddingInlineEnd: '16px',
324
495
  tailTop: '16px',
325
496
  tailHeight: '3px',
326
- titleFontSize: '14px !important',
327
- iconColor: 'white',
328
- tailColor: 'linear-gradient(to right, #343639 50%, transparent 50%) !important',
329
- tailLastChildColor: 'linear-gradient(to right, #4482ff 50%, transparent 50%) !important',
330
- tailFirstChildColor: 'linear-gradient(to right, transparent 50%, #4482ff 50%) !important',
331
- tailProcessFirstChildColor: 'linear-gradient(to right, transparent 50%, #3b404c 50%) !important',
332
- tailProcessColor: 'linear-gradient(to right, #4482ff 50%, #3b404c 50%) !important',
333
- tailWaitLastChildColor: 'linear-gradient(to right, #3b404c 50%, transparent 50%) !important',
334
- finishIconBgColor: `${colors.green['952']} !important`,
335
- finishTailColor: `${colors.azure['500']} !important`,
336
- processIconBgColor: `${colors.orange['425']} !important`,
337
- waitIconBgColor: `${colors.neutral['50']} !important`,
338
- waitIconColor: `${colors.ebonyClay['951']} !important`,
339
- waitTitleColor: `${colors.neutral['50']} !important`,
340
- waitTailColor: `${colors.gray['900']} !important`,
497
+ titleFontSize: '14px',
498
+ iconColor: colors.neutral['50'],
499
+ tailColor: 'linear-gradient(to right, #343639 50%, transparent 50%)',
500
+ tailLastChildColor: 'linear-gradient(to right, #4482ff 50%, transparent 50%)',
501
+ tailFirstChildColor: 'linear-gradient(to right, transparent 50%, #4482ff 50%)',
502
+ tailProcessFirstChildColor: 'linear-gradient(to right, transparent 50%, #3b404c 50%)',
503
+ tailProcessColor: 'linear-gradient(to right, #4482ff 50%, #3b404c 50%)',
504
+ tailWaitLastChildColor: 'linear-gradient(to right, #3b404c 50%, transparent 50%)',
505
+ tailWaitMiddleChildColor: `linear-gradient(to right, #4482ff 50%, #3b404c 50%)`,
506
+ tailErrorChildColor: `linear-gradient(to right, ${colors.red['450']} 50%, #3b404c 50%) !important`,
507
+ finishIconBgColor: `${colors.green['952']}`,
508
+ finishTailColor: `${colors.azure['500']}`,
509
+ processIconBgColor: `${colors.orange['425']}`,
510
+ waitIconBgColor: `${colors.neutral['50']}`,
511
+ waitIconColor: `${colors.ebonyClay['951']}`,
512
+ waitTitleColor: `${colors.neutral['50']}`,
513
+ waitTailColor: `${colors.gray['900']}`,
514
+ errorIconBgColor: `${colors.red['450']}`,
341
515
  manyItemsTransform: 'rotate(-40deg)',
342
516
  manyItemsWidth: '90px',
343
517
  manyItemsHeight: '80px',
344
- manyItemsWhiteSpace: 'break-spaces',
345
518
  manyItemsMarginInlineStart: '40px',
346
- manyItemsIconWidthHeight: '22px !important',
519
+ manyItemsIconWidthHeight: '22px',
347
520
  manyItemsTailHeight: '4px',
348
521
  manyItemsTailBottom: '10px'
349
522
  },
@@ -358,8 +531,7 @@ export const theme = {
358
531
  colorTextTertiary: colors.gray['300'],
359
532
  handleBg: colors.neutral['80'],
360
533
  handleShadow: '1px 1px 2px 0 rgba(156, 169, 194, 0.5)',
361
- fontSizeSM: fontSize * 0.5625,
362
- innerMinMargin: 0
534
+ fontSizeSM: fontSize * 0.5625
363
535
  },
364
536
  Divider: {
365
537
  colorSplit: colors.ebonyClay['175'],
@@ -368,6 +540,90 @@ export const theme = {
368
540
  fontWeight: 500,
369
541
  textPaddingInline: 8,
370
542
  margin: 48
543
+ },
544
+ DatePicker: {
545
+ general: {
546
+ fontSize: '14px',
547
+ fontColor: colors.gray['500'],
548
+ bgDarkBlue: colors.ebonyClay['475'],
549
+ wideBorder: `2px solid ${colors.ebonyClay['550']}`,
550
+ inputMarginBottom: '7px',
551
+ inputPadding: '7px 16px !important',
552
+ lightThemeBorder: `1px solid ${colors.neutral['350']}`
553
+ },
554
+ title: {
555
+ lightColor: `${colors.ebonyClay['500']}`
556
+ },
557
+ pickerPanel: {
558
+ shadow: '0 3px 6px 0 rgba(0, 0, 0, 0.2)',
559
+ width: '292px',
560
+ header: {
561
+ marginY: '20px',
562
+ padding: '0 22px',
563
+ textSize: '16px',
564
+ textColor: colors.neutral['380'],
565
+ arrawWidth: '10.2px',
566
+ arrowPaddingLeft: '12px',
567
+ arrowPaddingRight: '20px',
568
+ datePickerarrowPadding: '0.2px 0.2px 0.2px 0'
569
+ },
570
+ body: {
571
+ padding: '0 20px'
572
+ },
573
+ content: {
574
+ tableHeaderBorder: `1px solid ${colors.blue['250-10']}`,
575
+ tableHeaderFontSize: '12px',
576
+ tableHeaderFontColor: colors.neutral['380'],
577
+ tableHeaderWidth: '36px',
578
+ tableHeaderPaddingBottom: '6px'
579
+ },
580
+ row: {
581
+ marginY: '5px',
582
+ previousCellWidth: '36px',
583
+ cellLineHeight: '1.43',
584
+ cellFontWeight: 'normal',
585
+ cellTextColor: colors.neutral['380'],
586
+ cellBg: colors.ebonyClay['825'],
587
+ cellBorder: `2px solid ${colors.blue['250-10']}`,
588
+ cellBorderRadius: '3px'
589
+ },
590
+ separator: {
591
+ width: '6px',
592
+ height: '2px',
593
+ backgroundColor: colors.ebonyClay['550']
594
+ },
595
+ range: {
596
+ iconPosition: '10px',
597
+ iconTransform: 'translateY(-50%)',
598
+ inputPadding: '10px 16px !important',
599
+ inputRadius: '5px'
600
+ },
601
+ footer: {
602
+ margin: '4px 20px 0',
603
+ lineHeight: 'normal',
604
+ fontSize: '12px',
605
+ padding: '0 27px',
606
+ border: `1px solid ${colors.azure['500']}`,
607
+ borderRadius: '11px',
608
+ datePickerBorderTop: `1px solid ${colors.blue['250-10']}`,
609
+ datePickerPadding: '28px 0 23px',
610
+ rangeColGap: '50px',
611
+ rangeBorder: `1px solid ${colors.blue['250-20']}`,
612
+ rangePadding: '13px 20px 16px',
613
+ rangeCol: '12px',
614
+ rangeInputPadding: '10px 12px 10px 16px',
615
+ rangeInputRadius: '5px'
616
+ }
617
+ }
618
+ },
619
+ Upload: {
620
+ borderRadiusLG: 5,
621
+ colorFillAlter: colors.ebonyClay['475'],
622
+ colorError: colors.red['450'],
623
+ lineWidth: 0,
624
+ controlHeightLG: 30,
625
+ paddingXS: 0,
626
+ svgColor: colors.neutral['1000']
371
627
  }
372
628
  }
373
629
  };