@itcase/ui 1.8.29 → 1.8.31
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/{Avatar_cjs_33OrnLtt.js → Avatar_cjs_DRaNGlad.js} +1 -1
- package/dist/{Avatar_es_B3LiV8MM.js → Avatar_es_Ck1RiTgB.js} +1 -1
- package/dist/{Button_cjs_C05Joa8j.js → Button_cjs_CnBP4mKv.js} +1 -1
- package/dist/{Button_es_CO_dwo-N.js → Button_es_WG0yV-rp.js} +1 -1
- package/dist/{ChipsGroup_cjs_Cm_pVx8z.js → ChipsGroup_cjs_BCnPa9xv.js} +2 -4
- package/dist/{ChipsGroup_es_CLpRB95W.js → ChipsGroup_es_1854brF_.js} +2 -4
- package/dist/{DatePicker_cjs_0y_2FcnF.js → DatePicker_cjs_Cbv3ffoB.js} +3 -6
- package/dist/{DatePicker_es_bY1aXemt.js → DatePicker_es_DGck2HRu.js} +3 -6
- package/dist/{DropdownItem_cjs_DPoFy70W.js → DropdownItem_cjs_C3BV7axh.js} +1 -1
- package/dist/{DropdownItem_es_CVztMEm0.js → DropdownItem_es_VDp5tKZr.js} +1 -1
- package/dist/{Label_cjs_BefEcq6i.js → Label_cjs_CqSZcFNk.js} +63 -63
- package/dist/{Label_es_Dl_DrMOh.js → Label_es_s3M2-dON.js} +63 -63
- package/dist/{Tooltip_cjs_pBGCcXLZ.js → Tooltip_cjs_BE4fABOp.js} +34 -5
- package/dist/{Tooltip_es_frBCZDrO.js → Tooltip_es_BPMRrd2L.js} +34 -5
- package/dist/cjs/components/Accordion.js +28 -12
- package/dist/cjs/components/Avatar.js +2 -2
- package/dist/cjs/components/AvatarStack.js +2 -2
- package/dist/cjs/components/Badge.js +1 -1
- package/dist/cjs/components/Breadcrumbs.js +1 -1
- package/dist/cjs/components/Button.js +2 -2
- package/dist/cjs/components/Cell.js +2 -2
- package/dist/cjs/components/Chips.js +2 -2
- package/dist/cjs/components/Choice/stories/__mock__.js +11 -0
- package/dist/cjs/components/Choice.js +59 -17
- package/dist/cjs/components/CookiesWarning.js +2 -2
- package/dist/cjs/components/DatePeriod.js +14 -14
- package/dist/cjs/components/DatePicker.js +4 -4
- package/dist/cjs/components/Drawer.js +1 -1
- package/dist/cjs/components/Dropdown.js +2 -2
- package/dist/cjs/components/HeroTitle.js +1 -1
- package/dist/cjs/components/Icon.js +1 -1
- package/dist/cjs/components/InputPassword.js +1 -1
- package/dist/cjs/components/Label.js +2 -2
- package/dist/cjs/components/MenuItem.js +38 -68
- package/dist/cjs/components/Modal.js +1 -1
- package/dist/cjs/components/Notification.js +1 -1
- package/dist/cjs/components/Pagination.js +2 -2
- package/dist/cjs/components/Response.js +2 -2
- package/dist/cjs/components/Search.js +4 -4
- package/dist/cjs/components/Segmented.js +21 -44
- package/dist/cjs/components/Select.js +1 -1
- package/dist/cjs/components/Swiper.js +1 -1
- package/dist/cjs/components/Tab.js +1 -1
- package/dist/cjs/components/Tile.js +1 -1
- package/dist/cjs/components/Title.js +1 -1
- package/dist/cjs/components/Tooltip.js +1 -1
- package/dist/components/Accordion.js +28 -12
- package/dist/components/Avatar.js +2 -2
- package/dist/components/AvatarStack.js +2 -2
- package/dist/components/Badge.js +1 -1
- package/dist/components/Breadcrumbs.js +1 -1
- package/dist/components/Button.js +2 -2
- package/dist/components/Cell.js +2 -2
- package/dist/components/Chips.js +2 -2
- package/dist/components/Choice/stories/__mock__.js +9 -0
- package/dist/components/Choice.js +59 -17
- package/dist/components/CookiesWarning.js +2 -2
- package/dist/components/DatePeriod.js +14 -14
- package/dist/components/DatePicker.js +4 -4
- package/dist/components/Drawer.js +1 -1
- package/dist/components/Dropdown.js +2 -2
- package/dist/components/HeroTitle.js +1 -1
- package/dist/components/Icon.js +1 -1
- package/dist/components/InputPassword.js +1 -1
- package/dist/components/Label.js +2 -2
- package/dist/components/MenuItem.js +38 -68
- package/dist/components/Modal.js +1 -1
- package/dist/components/Notification.js +1 -1
- package/dist/components/Pagination.js +2 -2
- package/dist/components/Response.js +2 -2
- package/dist/components/Search.js +4 -4
- package/dist/components/Segmented.js +21 -44
- package/dist/components/Select.js +1 -1
- package/dist/components/Swiper.js +1 -1
- package/dist/components/Tab.js +1 -1
- package/dist/components/Tile.js +1 -1
- package/dist/components/Title.js +1 -1
- package/dist/components/Tooltip.js +1 -1
- package/dist/css/components/Accordion/Accordion.css +27 -7
- package/dist/css/components/Badge/Badge.css +1 -1
- package/dist/css/components/Choice/Choice.css +27 -19
- package/dist/css/components/MenuItem/MenuItem.css +45 -8
- package/dist/stories/ChoiceOverview.mdx +2 -2
- package/dist/stories/ChoicePlayground.mdx +3 -3
- package/dist/types/components/Accordion/appearance/accordionSize.d.ts +14 -7
- package/dist/types/components/Accordion/appearance/accordionSurface.d.ts +11 -2
- package/dist/types/components/Breadcrumbs/stories/__mock__/index.d.ts +1 -1
- package/dist/types/components/Cell/stories/__mock__/index.d.ts +2 -2
- package/dist/types/components/Choice/Choice.interface.d.ts +1 -0
- package/dist/types/components/Choice/appearance/choiceDefault.d.ts +10 -0
- package/dist/types/components/Choice/appearance/choiceDisabled.d.ts +10 -0
- package/dist/types/components/Choice/appearance/choiceError.d.ts +10 -0
- package/dist/types/components/Choice/appearance/choiceRequire.d.ts +11 -0
- package/dist/types/components/Choice/appearance/choiceStyle.d.ts +6 -4
- package/dist/types/components/Choice/appearance/choiceSuccess.d.ts +11 -0
- package/dist/types/components/Choice/stories/__mock__/index.d.ts +4 -0
- package/dist/types/components/DatePeriod/appearance/datePeriodSize.d.ts +4 -2
- package/dist/types/components/DatePeriod/appearance/datePeriodSurface.d.ts +0 -2
- package/dist/types/components/DatePicker/DatePicker.appearance.d.ts +6 -8
- package/dist/types/components/DatePicker/appearance/datePickerSize.d.ts +6 -6
- package/dist/types/components/DatePicker/appearance/datePickerSurface.d.ts +0 -2
- package/dist/types/components/Drawer/appearance/drawerSurface.d.ts +1 -1
- package/dist/types/components/Icon/appearance/iconDanger.d.ts +6 -0
- package/dist/types/components/Icon/appearance/iconError.d.ts +6 -0
- package/dist/types/components/Icon/appearance/iconPrimary.d.ts +5 -0
- package/dist/types/components/Icon/appearance/iconSecondary.d.ts +5 -0
- package/dist/types/components/Icon/appearance/iconStyle.d.ts +6 -5
- package/dist/types/components/Icon/appearance/iconWarning.d.ts +6 -0
- package/dist/types/components/Label/appearance/labelAccent.d.ts +1 -1
- package/dist/types/components/Label/appearance/labelDanger.d.ts +1 -1
- package/dist/types/components/Label/appearance/labelError.d.ts +7 -7
- package/dist/types/components/Label/appearance/labelPrimary.d.ts +1 -1
- package/dist/types/components/Label/appearance/labelSecondary.d.ts +1 -1
- package/dist/types/components/Label/appearance/labelSuccess.d.ts +1 -1
- package/dist/types/components/Label/appearance/labelSurface.d.ts +8 -8
- package/dist/types/components/Label/appearance/labelWarning.d.ts +1 -1
- package/dist/types/components/MenuItem/MenuItem.interface.d.ts +1 -0
- package/dist/types/components/MenuItem/appearance/menuItemAccent.d.ts +5 -8
- package/dist/types/components/MenuItem/appearance/menuItemError.d.ts +3 -3
- package/dist/types/components/MenuItem/appearance/menuItemSize.d.ts +0 -15
- package/dist/types/components/MenuItem/appearance/menuItemStyle.d.ts +1 -3
- package/dist/types/components/MenuItem/appearance/menuItemSurface.d.ts +3 -5
- package/dist/types/components/Notification/appearance/notificationDefault.d.ts +1 -1
- package/dist/types/components/Notification/appearance/notificationError.d.ts +1 -1
- package/dist/types/components/Notification/appearance/notificationSuccess.d.ts +1 -1
- package/dist/types/components/Notification/appearance/notificationWarning.d.ts +1 -1
- package/dist/types/components/Pagination/appearance/paginationSurface.d.ts +1 -1
- package/dist/types/components/Search/appearance/searchSize.d.ts +12 -12
- package/dist/types/components/Segmented/appearance/{segmentedSurface.d.ts → segmentedDefault.d.ts} +4 -4
- package/dist/types/components/Select/SelectLoadingIndicator.d.ts +1 -2
- package/dist/types/components/Tab/stories/__mock__/index.d.ts +1 -1
- package/dist/types/hooks/useDeviceTargetClass.d.ts +5 -0
- package/package.json +12 -12
- package/dist/types/components/Choice/appearance/choiceAccent.d.ts +0 -10
- package/dist/types/components/Label/appearance/labelGradient.d.ts +0 -9
- package/dist/types/components/MenuItem/appearance/menuItemPrimary.d.ts +0 -8
- package/dist/types/components/Pagination/appearance/paginationAccent.d.ts +0 -21
- package/dist/types/components/Pagination/appearance/paginationDanger.d.ts +0 -7
- package/dist/types/components/Pagination/appearance/paginationError.d.ts +0 -11
- package/dist/types/components/Pagination/appearance/paginationInfo.d.ts +0 -21
- package/dist/types/components/Pagination/appearance/paginationPrimary.d.ts +0 -8
- package/dist/types/components/Pagination/appearance/paginationSecondary.d.ts +0 -8
- package/dist/types/components/Pagination/appearance/paginationSize.d.ts +0 -48
- package/dist/types/components/Pagination/appearance/paginationStyle.d.ts +0 -16
- package/dist/types/components/Pagination/appearance/paginationSuccess.d.ts +0 -11
- package/dist/types/components/Pagination/appearance/paginationWarning.d.ts +0 -11
- package/dist/types/components/Segmented/appearance/segmentedAccent.d.ts +0 -19
- package/dist/types/components/Segmented/appearance/segmentedFalse.d.ts +0 -4
- package/dist/types/config/forms/datepicker.d.ts +0 -18
- package/dist/types/config/forms/index.d.ts +0 -3
- package/dist/types/config/forms/input.d.ts +0 -14
|
@@ -317,6 +317,12 @@ var iconAppearanceDanger = {
|
|
|
317
317
|
labelTextColor: 'dangerTextSecondary',
|
|
318
318
|
labelTextColorHover: 'dangerTextSecondary',
|
|
319
319
|
},
|
|
320
|
+
dangerPrimary: {
|
|
321
|
+
fill: 'dangerPrimary',
|
|
322
|
+
fillHover: 'dangerHover',
|
|
323
|
+
labelTextColor: 'dangerTextSecondary',
|
|
324
|
+
labelTextColorHover: 'dangerTextSecondary',
|
|
325
|
+
},
|
|
320
326
|
};
|
|
321
327
|
|
|
322
328
|
var iconAppearanceError = {
|
|
@@ -326,6 +332,12 @@ var iconAppearanceError = {
|
|
|
326
332
|
labelTextColor: 'errorTextPrimary',
|
|
327
333
|
labelTextColorHover: 'errorTextPrimary',
|
|
328
334
|
},
|
|
335
|
+
errorPrimary: {
|
|
336
|
+
fill: 'errorPrimary',
|
|
337
|
+
fillHover: 'errorHover',
|
|
338
|
+
labelTextColor: 'errorTextPrimary',
|
|
339
|
+
labelTextColorHover: 'errorTextPrimary',
|
|
340
|
+
},
|
|
329
341
|
};
|
|
330
342
|
|
|
331
343
|
var iconAppearanceInfo = {
|
|
@@ -351,6 +363,11 @@ var iconAppearancePrimary = {
|
|
|
351
363
|
fillHover: 'primaryPrimaryHover',
|
|
352
364
|
labelTextColor: 'primaryTextPrimary',
|
|
353
365
|
},
|
|
366
|
+
primaryPrimary: {
|
|
367
|
+
fill: 'primaryPrimary',
|
|
368
|
+
fillHover: 'primaryPrimaryHover',
|
|
369
|
+
labelTextColor: 'primaryTextPrimary',
|
|
370
|
+
},
|
|
354
371
|
};
|
|
355
372
|
|
|
356
373
|
var iconAppearanceSecondary = {
|
|
@@ -359,6 +376,11 @@ var iconAppearanceSecondary = {
|
|
|
359
376
|
fillHover: 'secondaryPrimaryHover',
|
|
360
377
|
labelTextColor: 'secondaryTextPrimary',
|
|
361
378
|
},
|
|
379
|
+
secondaryPrimary: {
|
|
380
|
+
fill: 'secondaryPrimary',
|
|
381
|
+
fillHover: 'secondaryPrimaryHover',
|
|
382
|
+
labelTextColor: 'secondaryTextPrimary',
|
|
383
|
+
},
|
|
362
384
|
};
|
|
363
385
|
|
|
364
386
|
var iconAppearanceSize = {
|
|
@@ -505,16 +527,17 @@ var iconAppearanceSize = {
|
|
|
505
527
|
};
|
|
506
528
|
|
|
507
529
|
var iconAppearanceStyle = {
|
|
508
|
-
|
|
530
|
+
full: {
|
|
509
531
|
borderColor: '0',
|
|
510
532
|
},
|
|
511
|
-
|
|
533
|
+
ghost: {
|
|
512
534
|
fill: 'none',
|
|
535
|
+
borderColor: '0',
|
|
513
536
|
},
|
|
514
|
-
|
|
515
|
-
ghost: {
|
|
537
|
+
outlined: {
|
|
516
538
|
fill: 'none',
|
|
517
|
-
|
|
539
|
+
},
|
|
540
|
+
solid: {
|
|
518
541
|
borderColor: '0',
|
|
519
542
|
},
|
|
520
543
|
};
|
|
@@ -573,6 +596,12 @@ var iconAppearanceWarning = {
|
|
|
573
596
|
labelTextColor: 'warningTextSecondary',
|
|
574
597
|
labelTextColorHover: 'warningTextSecondary',
|
|
575
598
|
},
|
|
599
|
+
warningPrimary: {
|
|
600
|
+
fill: 'warningPrimary',
|
|
601
|
+
fillHover: 'warningHover',
|
|
602
|
+
labelTextColor: 'warningTextSecondary',
|
|
603
|
+
labelTextColorHover: 'warningTextSecondary',
|
|
604
|
+
},
|
|
576
605
|
};
|
|
577
606
|
|
|
578
607
|
var iconAppearance = tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign({}, iconAppearanceSize), iconAppearanceStyle), iconAppearanceAccent), iconAppearanceDanger), iconAppearanceError), iconAppearanceInfo), iconAppearancePrimary), iconAppearanceSecondary), iconAppearanceSuccess), iconAppearanceSurface), iconAppearanceWarning);
|
|
@@ -315,6 +315,12 @@ var iconAppearanceDanger = {
|
|
|
315
315
|
labelTextColor: 'dangerTextSecondary',
|
|
316
316
|
labelTextColorHover: 'dangerTextSecondary',
|
|
317
317
|
},
|
|
318
|
+
dangerPrimary: {
|
|
319
|
+
fill: 'dangerPrimary',
|
|
320
|
+
fillHover: 'dangerHover',
|
|
321
|
+
labelTextColor: 'dangerTextSecondary',
|
|
322
|
+
labelTextColorHover: 'dangerTextSecondary',
|
|
323
|
+
},
|
|
318
324
|
};
|
|
319
325
|
|
|
320
326
|
var iconAppearanceError = {
|
|
@@ -324,6 +330,12 @@ var iconAppearanceError = {
|
|
|
324
330
|
labelTextColor: 'errorTextPrimary',
|
|
325
331
|
labelTextColorHover: 'errorTextPrimary',
|
|
326
332
|
},
|
|
333
|
+
errorPrimary: {
|
|
334
|
+
fill: 'errorPrimary',
|
|
335
|
+
fillHover: 'errorHover',
|
|
336
|
+
labelTextColor: 'errorTextPrimary',
|
|
337
|
+
labelTextColorHover: 'errorTextPrimary',
|
|
338
|
+
},
|
|
327
339
|
};
|
|
328
340
|
|
|
329
341
|
var iconAppearanceInfo = {
|
|
@@ -349,6 +361,11 @@ var iconAppearancePrimary = {
|
|
|
349
361
|
fillHover: 'primaryPrimaryHover',
|
|
350
362
|
labelTextColor: 'primaryTextPrimary',
|
|
351
363
|
},
|
|
364
|
+
primaryPrimary: {
|
|
365
|
+
fill: 'primaryPrimary',
|
|
366
|
+
fillHover: 'primaryPrimaryHover',
|
|
367
|
+
labelTextColor: 'primaryTextPrimary',
|
|
368
|
+
},
|
|
352
369
|
};
|
|
353
370
|
|
|
354
371
|
var iconAppearanceSecondary = {
|
|
@@ -357,6 +374,11 @@ var iconAppearanceSecondary = {
|
|
|
357
374
|
fillHover: 'secondaryPrimaryHover',
|
|
358
375
|
labelTextColor: 'secondaryTextPrimary',
|
|
359
376
|
},
|
|
377
|
+
secondaryPrimary: {
|
|
378
|
+
fill: 'secondaryPrimary',
|
|
379
|
+
fillHover: 'secondaryPrimaryHover',
|
|
380
|
+
labelTextColor: 'secondaryTextPrimary',
|
|
381
|
+
},
|
|
360
382
|
};
|
|
361
383
|
|
|
362
384
|
var iconAppearanceSize = {
|
|
@@ -503,16 +525,17 @@ var iconAppearanceSize = {
|
|
|
503
525
|
};
|
|
504
526
|
|
|
505
527
|
var iconAppearanceStyle = {
|
|
506
|
-
|
|
528
|
+
full: {
|
|
507
529
|
borderColor: '0',
|
|
508
530
|
},
|
|
509
|
-
|
|
531
|
+
ghost: {
|
|
510
532
|
fill: 'none',
|
|
533
|
+
borderColor: '0',
|
|
511
534
|
},
|
|
512
|
-
|
|
513
|
-
ghost: {
|
|
535
|
+
outlined: {
|
|
514
536
|
fill: 'none',
|
|
515
|
-
|
|
537
|
+
},
|
|
538
|
+
solid: {
|
|
516
539
|
borderColor: '0',
|
|
517
540
|
},
|
|
518
541
|
};
|
|
@@ -571,6 +594,12 @@ var iconAppearanceWarning = {
|
|
|
571
594
|
labelTextColor: 'warningTextSecondary',
|
|
572
595
|
labelTextColorHover: 'warningTextSecondary',
|
|
573
596
|
},
|
|
597
|
+
warningPrimary: {
|
|
598
|
+
fill: 'warningPrimary',
|
|
599
|
+
fillHover: 'warningHover',
|
|
600
|
+
labelTextColor: 'warningTextSecondary',
|
|
601
|
+
labelTextColorHover: 'warningTextSecondary',
|
|
602
|
+
},
|
|
574
603
|
};
|
|
575
604
|
|
|
576
605
|
var iconAppearance = __assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, iconAppearanceSize), iconAppearanceStyle), iconAppearanceAccent), iconAppearanceDanger), iconAppearanceError), iconAppearanceInfo), iconAppearancePrimary), iconAppearanceSecondary), iconAppearanceSuccess), iconAppearanceSurface), iconAppearanceWarning);
|
|
@@ -7,8 +7,8 @@ var clsx = require('clsx');
|
|
|
7
7
|
var castArray = require('lodash/castArray');
|
|
8
8
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
9
9
|
var useStyles = require('../hooks/useStyles/useStyles.js');
|
|
10
|
+
var Tooltip = require('../../Tooltip_cjs_BE4fABOp.js');
|
|
10
11
|
var Divider = require('../../Divider_cjs_BmCJj3TN.js');
|
|
11
|
-
var Tooltip = require('../../Tooltip_cjs_pBGCcXLZ.js');
|
|
12
12
|
var Text = require('../../Text_cjs_C9fOm0nd.js');
|
|
13
13
|
var _default = require('@itcase/icons/default');
|
|
14
14
|
require('lodash/camelCase');
|
|
@@ -28,42 +28,49 @@ require('../../Link_cjs_DbRGq2Yk.js');
|
|
|
28
28
|
var accordionAppearanceSize = {
|
|
29
29
|
sizeXXL: {
|
|
30
30
|
size: 'xxl',
|
|
31
|
-
titleTextSize: '
|
|
31
|
+
titleTextSize: 'h3',
|
|
32
|
+
badgeAppearanceSize: 'sizeXS',
|
|
32
33
|
contentTextSize: 'xxl',
|
|
33
34
|
icon: _default.icon16.ChevronDown,
|
|
34
35
|
},
|
|
35
36
|
sizeXL: {
|
|
36
37
|
size: 'xl',
|
|
37
|
-
titleTextSize: '
|
|
38
|
+
titleTextSize: 'h3',
|
|
39
|
+
badgeAppearanceSize: 'sizeXS',
|
|
38
40
|
contentTextSize: 'l',
|
|
39
41
|
icon: _default.icon16.ChevronDown,
|
|
40
42
|
},
|
|
41
43
|
sizeL: {
|
|
42
44
|
size: 'l',
|
|
43
|
-
titleTextSize: '
|
|
45
|
+
titleTextSize: 'h4',
|
|
46
|
+
badgeAppearanceSize: 'sizeXS',
|
|
44
47
|
icon: _default.icon16.ChevronDown,
|
|
45
48
|
},
|
|
46
49
|
sizeM: {
|
|
47
50
|
size: 'm',
|
|
48
|
-
titleTextSize: '
|
|
51
|
+
titleTextSize: 'h5',
|
|
52
|
+
badgeAppearanceSize: 'sizeXS',
|
|
49
53
|
contentTextSize: 'm',
|
|
50
54
|
icon: _default.icon16.ChevronDown,
|
|
51
55
|
},
|
|
52
56
|
sizeS: {
|
|
53
57
|
size: 's',
|
|
54
|
-
titleTextSize: '
|
|
58
|
+
titleTextSize: 'h6',
|
|
59
|
+
badgeAppearanceSize: 'sizeXS',
|
|
55
60
|
contentTextSize: 's',
|
|
56
61
|
icon: _default.icon16.ChevronDown,
|
|
57
62
|
},
|
|
58
63
|
sizeXS: {
|
|
59
64
|
size: 'xs',
|
|
60
|
-
titleTextSize: '
|
|
65
|
+
titleTextSize: 'h6',
|
|
66
|
+
badgeAppearanceSize: 'sizeXS',
|
|
61
67
|
contentTextSize: 'xs',
|
|
62
68
|
icon: _default.icon16.ChevronDown,
|
|
63
69
|
},
|
|
64
70
|
sizeXXS: {
|
|
65
71
|
size: 'xxs',
|
|
66
|
-
titleTextSize: '
|
|
72
|
+
titleTextSize: 'h6',
|
|
73
|
+
badgeAppearanceSize: 'sizeXS',
|
|
67
74
|
contentTextSize: 'xs',
|
|
68
75
|
icon: _default.icon16.ChevronDown,
|
|
69
76
|
},
|
|
@@ -89,24 +96,33 @@ var accordionAppearanceSurface = {
|
|
|
89
96
|
fillHover: 'surfacePrimaryHover',
|
|
90
97
|
titleTextColor: 'surfaceTextPrimary',
|
|
91
98
|
labelTextColor: 'surfaceTextPrimary',
|
|
99
|
+
badgeAppearance: 'accentPrimary solid',
|
|
100
|
+
badgeShape: 'circular',
|
|
92
101
|
iconFillIcon: 'surfaceItemPrimary',
|
|
93
102
|
},
|
|
94
103
|
surfaceSecondary: {
|
|
95
104
|
fill: 'surfaceSecondary',
|
|
96
105
|
fillHover: 'surfaceSecondaryHover',
|
|
97
106
|
labelTextColor: 'surfaceTextPrimary',
|
|
98
|
-
|
|
99
|
-
|
|
107
|
+
badgeAppearance: 'accentPrimary solid',
|
|
108
|
+
badgeShape: 'circular',
|
|
109
|
+
iconFillIcon: 'surfaceItemPrimary',
|
|
100
110
|
},
|
|
101
111
|
surfaceTertiary: {
|
|
102
112
|
fill: 'surfaceTertiary',
|
|
103
113
|
fillHover: 'surfaceTertiaryHover',
|
|
104
114
|
labelTextColor: 'surfaceTextPrimary',
|
|
115
|
+
badgeAppearance: 'accentPrimary solid',
|
|
116
|
+
badgeShape: 'circular',
|
|
117
|
+
iconFillIcon: 'surfaceItemPrimary',
|
|
105
118
|
},
|
|
106
119
|
surfaceQuaternary: {
|
|
107
120
|
fill: 'surfaceQuaternary',
|
|
108
121
|
fillHover: 'surfaceQuaternaryHover',
|
|
109
122
|
labelTextColor: 'surfaceTextPrimary',
|
|
123
|
+
badgeAppearance: 'accentPrimary solid',
|
|
124
|
+
badgeShape: 'circular',
|
|
125
|
+
iconFillIcon: 'surfaceItemPrimary',
|
|
110
126
|
},
|
|
111
127
|
};
|
|
112
128
|
|
|
@@ -135,10 +151,10 @@ function AccordionItem(props) {
|
|
|
135
151
|
return (tslib_es6.__assign(tslib_es6.__assign({}, resultConfig), (_a = accordionItemConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
136
152
|
}, {});
|
|
137
153
|
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
138
|
-
var fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, titleBorderColorClass = propsGenerator.titleBorderColorClass, titleFillClass = propsGenerator.titleFillClass, titleFillHoverClass = propsGenerator.titleFillHoverClass, titleTextColor = propsGenerator.titleTextColor, titleTextSize = propsGenerator.titleTextSize, titleTextWeight = propsGenerator.titleTextWeight,
|
|
154
|
+
var fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, titleBorderColorClass = propsGenerator.titleBorderColorClass, titleFillClass = propsGenerator.titleFillClass, titleFillHoverClass = propsGenerator.titleFillHoverClass, titleTextColor = propsGenerator.titleTextColor, titleTextSize = propsGenerator.titleTextSize, titleTextWeight = propsGenerator.titleTextWeight, titleWidthClass = propsGenerator.titleWidthClass, borderColorClass = propsGenerator.borderColorClass, badgeAppearance = propsGenerator.badgeAppearance, badgeAppearanceSize = propsGenerator.badgeAppearanceSize, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, badgeValue = propsGenerator.badgeValue, contentTextColor = propsGenerator.contentTextColor, contentTextSize = propsGenerator.contentTextSize, contentTextWeight = propsGenerator.contentTextWeight, dividerDirection = propsGenerator.dividerDirection, dividerFill = propsGenerator.dividerFill, dividerSize = propsGenerator.dividerSize, icon = propsGenerator.icon, iconFill = propsGenerator.iconFill, iconFillIcon = propsGenerator.iconFillIcon, iconFillSize = propsGenerator.iconFillSize, iconShape = propsGenerator.iconShape, iconSize = propsGenerator.iconSize, iconSrc = propsGenerator.iconSrc, shapeClass = propsGenerator.shapeClass, showDivider = propsGenerator.showDivider, sizeClass = propsGenerator.sizeClass, zeroGap = propsGenerator.zeroGap, zeroPadding = propsGenerator.zeroPadding;
|
|
139
155
|
// @ts-expect-error
|
|
140
156
|
var styles = useStyles.useStyles(props).styles;
|
|
141
|
-
return (jsxRuntime.jsxs("div", { className: clsx('accordion-item', className, borderColorClass && "border-color_".concat(borderColorClass), shapeClass && "accordion-item_shape_".concat(shapeClass), sizeClass && "accordion-item_size_".concat(sizeClass), isExpanded && 'accordion-item_state_open'), style: styles, children: [jsxRuntime.jsxs("div", { className: clsx('accordion-item__header', fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass)), children: [jsxRuntime.jsx(Text.Text, { className: clsx('accordion-item__title', titleBorderColorClass && "border-color_".concat(titleBorderColorClass), titleFillClass && "fill_".concat(titleFillClass), titleFillHoverClass && "fill_hover_".concat(titleFillHoverClass), titleWidthClass && "width_".concat(titleWidthClass), onClickTitle && 'cursor_type_pointer'), size: titleTextSize, textColor: titleTextColor, textWeight: titleTextWeight, onClick: onClickTitle, children: title }), (icon || iconSrc) && (jsxRuntime.jsx(Tooltip.Icon, { className: clsx('accordion-item__icon'), fill: iconFill, fillSize: iconFillSize, iconFill: iconFillIcon, iconSize: iconSize, imageSrc: iconSrc, shape: iconShape, SvgImage: icon, onClick: onClickTitle }))
|
|
157
|
+
return (jsxRuntime.jsxs("div", { className: clsx('accordion-item', className, zeroPadding && 'accordion-item_zero-padding', zeroGap && 'accordion-item_zero-gap', borderColorClass && "border-color_".concat(borderColorClass), shapeClass && "accordion-item_shape_".concat(shapeClass), sizeClass && "accordion-item_size_".concat(sizeClass), isExpanded && 'accordion-item_state_open'), style: styles, children: [jsxRuntime.jsxs("div", { className: clsx('accordion-item__header', fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass)), children: [jsxRuntime.jsx(Text.Text, { className: clsx('accordion-item__title', titleBorderColorClass && "border-color_".concat(titleBorderColorClass), titleFillClass && "fill_".concat(titleFillClass), titleFillHoverClass && "fill_hover_".concat(titleFillHoverClass), titleWidthClass && "width_".concat(titleWidthClass), onClickTitle && 'cursor_type_pointer'), size: titleTextSize, textColor: titleTextColor, textWeight: titleTextWeight, onClick: onClickTitle, children: title }), jsxRuntime.jsxs("div", { className: "accordion-item__action", children: [badgeValue && (jsxRuntime.jsx(Tooltip.Badge, { className: "accordion-item__badge", appearance: "".concat(badgeAppearance, " ").concat(badgeAppearanceSize), size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), (icon || iconSrc) && (jsxRuntime.jsx(Tooltip.Icon, { className: clsx('accordion-item__icon'), fill: iconFill, fillSize: iconFillSize, iconFill: iconFillIcon, iconSize: iconSize, imageSrc: iconSrc, shape: iconShape, SvgImage: icon, onClick: onClickTitle }))] }), showDivider && (jsxRuntime.jsx(Divider.Divider, { width: "fill", direction: dividerDirection, size: dividerSize, fill: dividerFill || 'surfaceTertiary' }))] }), beforeContent, isExpanded && (jsxRuntime.jsxs("div", { className: clsx('accordion-item__content'), children: [content && (jsxRuntime.jsx("div", { className: clsx('accordion-item__content-inner', fillClass && "fill_".concat(fillClass)), children: jsxRuntime.jsx(Text.Text, { size: contentTextSize, textColor: contentTextColor, textWeight: contentTextWeight, children: content }) })), children] })), afterContent] }));
|
|
142
158
|
}
|
|
143
159
|
|
|
144
160
|
function Accordion(props) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var Avatar = require('../../
|
|
3
|
+
var Avatar = require('../../Avatar_cjs_DRaNGlad.js');
|
|
4
4
|
require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
5
5
|
require('react/jsx-runtime');
|
|
6
6
|
require('react');
|
|
@@ -16,7 +16,7 @@ require('../context/UIContext.js');
|
|
|
16
16
|
require('../hooks/useMediaQueries/useMediaQueries.js');
|
|
17
17
|
require('react-responsive');
|
|
18
18
|
require('../utils/setViewportProperty.js');
|
|
19
|
-
require('../../
|
|
19
|
+
require('../../Tooltip_cjs_BE4fABOp.js');
|
|
20
20
|
require('../hooks/useStyles/useStyles.js');
|
|
21
21
|
require('lodash/maxBy');
|
|
22
22
|
require('../hooks/useStyles/styleAttributes.js');
|
|
@@ -5,7 +5,7 @@ var jsxRuntime = require('react/jsx-runtime');
|
|
|
5
5
|
var clsx = require('clsx');
|
|
6
6
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
7
7
|
var useStyles = require('../hooks/useStyles/useStyles.js');
|
|
8
|
-
var Avatar = require('../../
|
|
8
|
+
var Avatar = require('../../Avatar_cjs_DRaNGlad.js');
|
|
9
9
|
var Group = require('../../Group_cjs_Cwt0gWk4.js');
|
|
10
10
|
var Text = require('../../Text_cjs_C9fOm0nd.js');
|
|
11
11
|
require('react');
|
|
@@ -21,7 +21,7 @@ require('react-responsive');
|
|
|
21
21
|
require('../utils/setViewportProperty.js');
|
|
22
22
|
require('lodash/maxBy');
|
|
23
23
|
require('../hooks/useStyles/styleAttributes.js');
|
|
24
|
-
require('../../
|
|
24
|
+
require('../../Tooltip_cjs_BE4fABOp.js');
|
|
25
25
|
require('react-inlinesvg');
|
|
26
26
|
require('../../Link_cjs_DbRGq2Yk.js');
|
|
27
27
|
require('../../Image_cjs_CCWqbNn4.js');
|
|
@@ -6,7 +6,7 @@ var clsx = require('clsx');
|
|
|
6
6
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
7
7
|
var useStyles = require('../hooks/useStyles/useStyles.js');
|
|
8
8
|
var tslib_es6 = require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
9
|
-
var Tooltip = require('../../
|
|
9
|
+
var Tooltip = require('../../Tooltip_cjs_BE4fABOp.js');
|
|
10
10
|
var Link = require('../../Link_cjs_DbRGq2Yk.js');
|
|
11
11
|
var Text = require('../../Text_cjs_C9fOm0nd.js');
|
|
12
12
|
require('lodash/camelCase');
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var Button = require('../../
|
|
3
|
+
var Button = require('../../Button_cjs_CnBP4mKv.js');
|
|
4
4
|
require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
5
5
|
require('react/jsx-runtime');
|
|
6
6
|
require('react');
|
|
7
7
|
require('clsx');
|
|
8
|
-
require('../../
|
|
8
|
+
require('../../Tooltip_cjs_BE4fABOp.js');
|
|
9
9
|
require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
10
10
|
require('lodash/camelCase');
|
|
11
11
|
require('lodash/castArray');
|
|
@@ -5,8 +5,8 @@ var jsxRuntime = require('react/jsx-runtime');
|
|
|
5
5
|
var clsx = require('clsx');
|
|
6
6
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
7
7
|
var useStyles = require('../hooks/useStyles/useStyles.js');
|
|
8
|
-
var Tooltip = require('../../
|
|
9
|
-
var Label = require('../../
|
|
8
|
+
var Tooltip = require('../../Tooltip_cjs_BE4fABOp.js');
|
|
9
|
+
var Label = require('../../Label_cjs_CqSZcFNk.js');
|
|
10
10
|
var Text = require('../../Text_cjs_C9fOm0nd.js');
|
|
11
11
|
require('react');
|
|
12
12
|
require('lodash/camelCase');
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var ChipsGroup = require('../../
|
|
3
|
+
var ChipsGroup = require('../../ChipsGroup_cjs_BCnPa9xv.js');
|
|
4
4
|
require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
5
5
|
require('react/jsx-runtime');
|
|
6
6
|
require('react');
|
|
@@ -19,7 +19,7 @@ require('../utils/setViewportProperty.js');
|
|
|
19
19
|
require('../hooks/useStyles/useStyles.js');
|
|
20
20
|
require('lodash/maxBy');
|
|
21
21
|
require('../hooks/useStyles/styleAttributes.js');
|
|
22
|
-
require('../../
|
|
22
|
+
require('../../Tooltip_cjs_BE4fABOp.js');
|
|
23
23
|
require('../../Text_cjs_C9fOm0nd.js');
|
|
24
24
|
require('react-inlinesvg');
|
|
25
25
|
require('../../Link_cjs_DbRGq2Yk.js');
|
|
@@ -6,7 +6,7 @@ var React = require('react');
|
|
|
6
6
|
var clsx = require('clsx');
|
|
7
7
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
8
8
|
var useStyles = require('../hooks/useStyles/useStyles.js');
|
|
9
|
-
var Tooltip = require('../../
|
|
9
|
+
var Tooltip = require('../../Tooltip_cjs_BE4fABOp.js');
|
|
10
10
|
var Loader = require('../../Loader_cjs_CCrbD8Em.js');
|
|
11
11
|
var Text = require('../../Text_cjs_C9fOm0nd.js');
|
|
12
12
|
require('lodash/camelCase');
|
|
@@ -24,13 +24,44 @@ require('../hooks/useStyles/styleAttributes.js');
|
|
|
24
24
|
require('react-inlinesvg');
|
|
25
25
|
require('../../Link_cjs_DbRGq2Yk.js');
|
|
26
26
|
|
|
27
|
-
var
|
|
28
|
-
|
|
29
|
-
fill: '
|
|
30
|
-
fillItemActive: 'accentPrimary',
|
|
31
|
-
labelTextActiveColor: 'accentTextPrimary',
|
|
27
|
+
var choiceAppearanceDefault = {
|
|
28
|
+
defaultPrimary: {
|
|
29
|
+
fill: 'surfaceSecondary',
|
|
32
30
|
labelTextColor: 'surfaceTextPrimary',
|
|
33
|
-
borderColor: '
|
|
31
|
+
borderColor: 'surfaceBorderQuaternary',
|
|
32
|
+
iconAfterFill: 'surfaceItemQuaternary',
|
|
33
|
+
iconBeforeFill: 'surfaceItemQuaternary',
|
|
34
|
+
},
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
var choiceAppearanceDisabled = {
|
|
38
|
+
disabledPrimary: {
|
|
39
|
+
fill: 'surfaceDisabled',
|
|
40
|
+
labelTextColor: 'surfaceTextQuaternary',
|
|
41
|
+
borderColor: 'surfaceBorderPrimary',
|
|
42
|
+
iconAfterFill: 'surfaceItemPrimary',
|
|
43
|
+
iconBeforeFill: 'surfaceItemPrimary',
|
|
44
|
+
},
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
var choiceAppearanceError = {
|
|
48
|
+
errorPrimary: {
|
|
49
|
+
fill: 'errorTertiary',
|
|
50
|
+
labelTextColor: 'surfaceTextPrimary',
|
|
51
|
+
borderColor: 'errorBorderQuaternary',
|
|
52
|
+
iconAfterFill: 'errorItemPrimary',
|
|
53
|
+
iconBeforeFill: 'errorItemPrimary',
|
|
54
|
+
},
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
var choiceAppearanceRequire = {
|
|
58
|
+
requirePrimary: {
|
|
59
|
+
fill: 'warningTertiary',
|
|
60
|
+
fillItemActive: 'warningTertiary',
|
|
61
|
+
labelTextColor: 'surfaceTextPrimary',
|
|
62
|
+
borderColor: 'warningBorderSecondary',
|
|
63
|
+
iconAfterFill: 'warningItemSecondary',
|
|
64
|
+
iconBeforeFill: 'warningItemSecondary',
|
|
34
65
|
},
|
|
35
66
|
};
|
|
36
67
|
|
|
@@ -53,18 +84,29 @@ var choiceAppearanceSize = {
|
|
|
53
84
|
};
|
|
54
85
|
|
|
55
86
|
var choiceAppearanceStyle = {
|
|
56
|
-
|
|
57
|
-
borderColor: '
|
|
87
|
+
full: {
|
|
88
|
+
borderColor: '0',
|
|
89
|
+
},
|
|
90
|
+
ghost: {
|
|
91
|
+
fill: 'none',
|
|
92
|
+
borderColor: '0',
|
|
58
93
|
},
|
|
59
94
|
outlined: {
|
|
60
95
|
fill: 'none',
|
|
61
96
|
},
|
|
62
|
-
|
|
63
|
-
|
|
97
|
+
solid: {
|
|
98
|
+
borderColor: '0',
|
|
64
99
|
},
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
var choiceAppearanceSuccess = {
|
|
103
|
+
successPrimary: {
|
|
104
|
+
fill: 'successTertiary',
|
|
105
|
+
fillItemActive: 'successTertiary',
|
|
106
|
+
labelTextColor: 'surfaceTextPrimary',
|
|
107
|
+
borderColor: 'successBorderSecondary',
|
|
108
|
+
iconAfterFill: 'successItemSecondary',
|
|
109
|
+
iconBeforeFill: 'successItemSecondary',
|
|
68
110
|
},
|
|
69
111
|
};
|
|
70
112
|
|
|
@@ -93,7 +135,7 @@ var choiceAppearanceSurface = {
|
|
|
93
135
|
},
|
|
94
136
|
};
|
|
95
137
|
|
|
96
|
-
var choiceAppearance = tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign({},
|
|
138
|
+
var choiceAppearance = tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign({}, choiceAppearanceError), choiceAppearanceDisabled), choiceAppearanceDefault), choiceAppearanceSuccess), choiceAppearanceRequire), choiceAppearanceStyle), choiceAppearanceSize), choiceAppearanceSurface);
|
|
97
139
|
|
|
98
140
|
var choiceConfig = {
|
|
99
141
|
appearance: choiceAppearance,
|
|
@@ -102,7 +144,7 @@ var choiceConfig = {
|
|
|
102
144
|
},
|
|
103
145
|
};
|
|
104
146
|
function Choice(props) {
|
|
105
|
-
var id = props.id, className = props.className, name = props.name, appearance = props.appearance, _a = props.isDisabled, isDisabled = _a === void 0 ? false : _a, _b = props.active, active = _b === void 0 ? { value: undefined } : _b, dataTestId = props.dataTestId, dataTour = props.dataTour, icon = props.icon, itemAfter = props.itemAfter, itemBefore = props.itemBefore, _c = props.options, options = _c === void 0 ? [] : _c, before = props.before, after = props.after, _d = props.isCheckbox, isCheckbox = _d === void 0 ? false : _d, _e = props.isLoading, isLoading = _e === void 0 ? false : _e, setActiveSegment = props.setActiveSegment;
|
|
147
|
+
var id = props.id, className = props.className, name = props.name, appearance = props.appearance, _a = props.isDisabled, isDisabled = _a === void 0 ? false : _a, _b = props.active, active = _b === void 0 ? { value: undefined } : _b, dataTestId = props.dataTestId, dataTour = props.dataTour, icon = props.icon, itemAfter = props.itemAfter, itemBefore = props.itemBefore, _c = props.options, options = _c === void 0 ? [] : _c, before = props.before, after = props.after, _d = props.isCheckbox, isCheckbox = _d === void 0 ? false : _d, _e = props.isLoading, isLoading = _e === void 0 ? false : _e, isSkeleton = props.isSkeleton, setActiveSegment = props.setActiveSegment;
|
|
106
148
|
var controlRef = React.useRef(null);
|
|
107
149
|
var optionsRefs = React.useMemo(function () {
|
|
108
150
|
return new Map(options.map(function (item) { return [item.value, React.createRef()]; }));
|
|
@@ -118,7 +160,7 @@ function Choice(props) {
|
|
|
118
160
|
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
119
161
|
var size = propsGenerator.size, fillClass = propsGenerator.fillClass, fillItemActiveClass = propsGenerator.fillItemActiveClass, fillItemActiveDisabledClass = propsGenerator.fillItemActiveDisabledClass, fillItemActiveHoverClass = propsGenerator.fillItemActiveHoverClass, fillItemClass = propsGenerator.fillItemClass, fillItemDisabledClass = propsGenerator.fillItemDisabledClass, fillItemHoverClass = propsGenerator.fillItemHoverClass, labelTextActiveColor = propsGenerator.labelTextActiveColor, labelTextActiveColorDisabled = propsGenerator.labelTextActiveColorDisabled, labelTextColor = propsGenerator.labelTextColor, labelTextColorDisabled = propsGenerator.labelTextColorDisabled, labelTextSize = propsGenerator.labelTextSize, labelTextWeight = propsGenerator.labelTextWeight, labelTextWrap = propsGenerator.labelTextWrap, borderColorClass = propsGenerator.borderColorClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, iconAfterFillDisabled = propsGenerator.iconAfterFillDisabled, iconBeforeFillDisabled = propsGenerator.iconBeforeFillDisabled, iconFillDisabled = propsGenerator.iconFillDisabled, iconActive = propsGenerator.iconActive, iconAfter = propsGenerator.iconAfter, iconAfterActive = propsGenerator.iconAfterActive, iconAfterFill = propsGenerator.iconAfterFill, iconAfterFillActive = propsGenerator.iconAfterFillActive, iconAfterSize = propsGenerator.iconAfterSize, iconBefore = propsGenerator.iconBefore, iconBeforeActive = propsGenerator.iconBeforeActive, iconBeforeFill = propsGenerator.iconBeforeFill, iconBeforeFillActive = propsGenerator.iconBeforeFillActive, iconBeforeSize = propsGenerator.iconBeforeSize, iconFill = propsGenerator.iconFill, iconFillActive = propsGenerator.iconFillActive, iconSize = propsGenerator.iconSize, shapeClass = propsGenerator.shapeClass, shapeItemClass = propsGenerator.shapeItemClass, wrapClass = propsGenerator.wrapClass;
|
|
120
162
|
var styles = useStyles.useStyles(props).styles;
|
|
121
|
-
return (jsxRuntime.jsxs("div", { id: id, className: clsx(className, 'choice', size && "choice_size_".concat(size), fillClass && "fill_".concat(fillClass), wrapClass && "choice_wrap_".concat(wrapClass)), "data-testid": dataTestId && "".concat(dataTestId, "Choice"), "data-tour": dataTour, ref: controlRef, style: styles, children: [before && jsxRuntime.jsx("div", { className: "choice__before", children: before }), isLoading ? (jsxRuntime.jsx(Loader.Loader, { width: "fill", height: "fill", fill: "surfacePrimary", itemFill: "surfaceItemAccent" })) : (jsxRuntime.jsx(React.Fragment, { children: options.map(function (item) {
|
|
163
|
+
return (jsxRuntime.jsxs("div", { id: id, className: clsx(className, 'choice', size && "choice_size_".concat(size), fillClass && "fill_".concat(fillClass), wrapClass && "choice_wrap_".concat(wrapClass), isSkeleton && "choice_skeleton"), "data-testid": dataTestId && "".concat(dataTestId, "Choice"), "data-tour": dataTour, ref: controlRef, style: styles, children: [before && jsxRuntime.jsx("div", { className: "choice__before", children: before }), isLoading ? (jsxRuntime.jsx(Loader.Loader, { width: "fill", height: "fill", fill: "surfacePrimary", itemFill: "surfaceItemAccent" })) : (jsxRuntime.jsx(React.Fragment, { children: options.map(function (item) {
|
|
122
164
|
var isActive = typeof active === 'object'
|
|
123
165
|
? String(item.value) === String(active.value)
|
|
124
166
|
: String(item.value) === String(active);
|
|
@@ -6,7 +6,7 @@ var React = require('react');
|
|
|
6
6
|
var clsx = require('clsx');
|
|
7
7
|
var Cookies = require('js-cookie');
|
|
8
8
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
9
|
-
var Button = require('../../
|
|
9
|
+
var Button = require('../../Button_cjs_CnBP4mKv.js');
|
|
10
10
|
var Text = require('../../Text_cjs_C9fOm0nd.js');
|
|
11
11
|
require('lodash/camelCase');
|
|
12
12
|
require('lodash/castArray');
|
|
@@ -18,7 +18,7 @@ require('../context/UIContext.js');
|
|
|
18
18
|
require('../hooks/useMediaQueries/useMediaQueries.js');
|
|
19
19
|
require('react-responsive');
|
|
20
20
|
require('../utils/setViewportProperty.js');
|
|
21
|
-
require('../../
|
|
21
|
+
require('../../Tooltip_cjs_BE4fABOp.js');
|
|
22
22
|
require('../hooks/useStyles/useStyles.js');
|
|
23
23
|
require('lodash/maxBy');
|
|
24
24
|
require('../hooks/useStyles/styleAttributes.js');
|
|
@@ -6,9 +6,9 @@ var React = require('react');
|
|
|
6
6
|
var clsx = require('clsx');
|
|
7
7
|
var luxon = require('luxon');
|
|
8
8
|
var common = require('@itcase/common');
|
|
9
|
-
var DatePicker = require('../../
|
|
9
|
+
var DatePicker = require('../../DatePicker_cjs_Cbv3ffoB.js');
|
|
10
10
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
11
|
-
var ChipsGroup = require('../../
|
|
11
|
+
var ChipsGroup = require('../../ChipsGroup_cjs_BCnPa9xv.js');
|
|
12
12
|
require('date-fns/locale');
|
|
13
13
|
require('react-datepicker');
|
|
14
14
|
require('../hooks/useStyles/useStyles.js');
|
|
@@ -22,27 +22,29 @@ require('../hooks/useMediaQueries/useMediaQueries.js');
|
|
|
22
22
|
require('react-responsive');
|
|
23
23
|
require('../utils/setViewportProperty.js');
|
|
24
24
|
require('../hooks/useStyles/styleAttributes.js');
|
|
25
|
-
require('../../
|
|
26
|
-
require('../../
|
|
25
|
+
require('../../Button_cjs_CnBP4mKv.js');
|
|
26
|
+
require('../../Tooltip_cjs_BE4fABOp.js');
|
|
27
27
|
require('../../Text_cjs_C9fOm0nd.js');
|
|
28
28
|
require('react-inlinesvg');
|
|
29
29
|
require('../../Link_cjs_DbRGq2Yk.js');
|
|
30
30
|
require('../../Loader_cjs_CCrbD8Em.js');
|
|
31
31
|
require('../../Input_cjs_BAVggtkk.js');
|
|
32
|
-
require('../../
|
|
32
|
+
require('../../Label_cjs_CqSZcFNk.js');
|
|
33
33
|
require('@itcase/icons/default');
|
|
34
34
|
require('lodash/castArray');
|
|
35
35
|
|
|
36
36
|
var datePeriodAppearanceSize = {
|
|
37
37
|
sizeL: {
|
|
38
38
|
size: 'm',
|
|
39
|
-
|
|
39
|
+
chipsAppearanceSize: 'sizeL',
|
|
40
|
+
datePickerAppearanceSize: 'sizeM',
|
|
40
41
|
datePickerInputSize: 'l',
|
|
41
42
|
datePickerInputTextSize: 'm',
|
|
42
43
|
},
|
|
43
44
|
sizeM: {
|
|
44
45
|
size: 'm',
|
|
45
|
-
|
|
46
|
+
chipsAppearanceSize: 'sizeL',
|
|
47
|
+
datePickerAppearanceSize: 'sizeM',
|
|
46
48
|
datePickerInputSize: 'm',
|
|
47
49
|
datePickerInputTextSize: 'm',
|
|
48
50
|
},
|
|
@@ -51,20 +53,18 @@ var datePeriodAppearanceSize = {
|
|
|
51
53
|
var datePeriodAppearanceSurface = {
|
|
52
54
|
surfacePrimary: {
|
|
53
55
|
fill: 'surfacePrimary',
|
|
54
|
-
chipsAppearance: 'surfacePrimary
|
|
56
|
+
chipsAppearance: 'surfacePrimary ghost',
|
|
55
57
|
chipsShape: 'rounded',
|
|
56
58
|
datePickerAppearance: 'surfacePrimary',
|
|
57
59
|
datePickerInputAppearance: 'defaultPrimary',
|
|
58
|
-
datePickerInputFillHover: 'surfaceHover',
|
|
59
60
|
shape: 'rounded',
|
|
60
61
|
},
|
|
61
62
|
surfaceSecondary: {
|
|
62
63
|
fill: 'surfaceSecondary',
|
|
63
|
-
chipsAppearance: 'surfacePrimary
|
|
64
|
+
chipsAppearance: 'surfacePrimary ghost',
|
|
64
65
|
chipsShape: 'rounded',
|
|
65
66
|
datePickerAppearance: 'surfacePrimary',
|
|
66
67
|
datePickerInputAppearance: 'defaultPrimary',
|
|
67
|
-
datePickerInputFillHover: 'surfaceHover',
|
|
68
68
|
shape: 'rounded',
|
|
69
69
|
},
|
|
70
70
|
};
|
|
@@ -84,7 +84,7 @@ function DatePeriod(props) {
|
|
|
84
84
|
return (tslib_es6.__assign(tslib_es6.__assign({}, resultConfig), (_a = datePeriodConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
85
85
|
}, {});
|
|
86
86
|
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
87
|
-
var _b = propsGenerator, fillClass = _b.fillClass, chipsAppearance = _b.chipsAppearance, chipsShape = _b.chipsShape, datePickerAppearance = _b.datePickerAppearance, datePickerInputAppearance = _b.datePickerInputAppearance, datePickerInputFillHover = _b.datePickerInputFillHover, datePickerInputSize = _b.datePickerInputSize, datePickerInputTextSize = _b.datePickerInputTextSize, shapeClass = _b.shapeClass, sizeClass = _b.sizeClass;
|
|
87
|
+
var _b = propsGenerator, fillClass = _b.fillClass, chipsAppearance = _b.chipsAppearance, chipsAppearanceSize = _b.chipsAppearanceSize, chipsShape = _b.chipsShape, datePickerAppearance = _b.datePickerAppearance, datePickerAppearanceSize = _b.datePickerAppearanceSize, datePickerInputAppearance = _b.datePickerInputAppearance, datePickerInputFillHover = _b.datePickerInputFillHover, datePickerInputSize = _b.datePickerInputSize, datePickerInputTextSize = _b.datePickerInputTextSize, shapeClass = _b.shapeClass, sizeClass = _b.sizeClass;
|
|
88
88
|
var onClickPeriodChips = React.useCallback(function (selectedPeriodItem) {
|
|
89
89
|
var dateStartIso = selectedPeriodItem.dateIntervalsList[0];
|
|
90
90
|
var dateEndIso = selectedPeriodItem.dateIntervalsList[1];
|
|
@@ -107,8 +107,8 @@ function DatePeriod(props) {
|
|
|
107
107
|
return (dateStartIso === datePeriodValueStart &&
|
|
108
108
|
dateEndIso === datePeriodValueEnd);
|
|
109
109
|
}, [datePeriodValueEnd, datePeriodValueStart]);
|
|
110
|
-
return (jsxRuntime.jsx("div", { className: clsx(className, 'date-period', shapeClass && "date-period_shape_".concat(shapeClass), sizeClass && "date-period_size_".concat(sizeClass), isSkeleton && "date-period_skeleton", fillClass && "fill_".concat(fillClass), 'cursor_type_pointer'), children: jsxRuntime.jsxs(ChipsGroup.ChipsGroup, { direction: "horizontal", children: [datePeriodIntervalsList.map(function (datePeriodItem) { return (jsxRuntime.jsx(ChipsGroup.Chips, { appearance: chipsAppearance, label: datePeriodItem.label, shape: chipsShape, isActive: checkIsChipsActive(datePeriodItem), onClick: function () { return onClickPeriodChips(datePeriodItem); } }, datePeriodItem.value)); }), jsxRuntime.jsx(DatePicker.DatePickerInput, { datePickerProps: {
|
|
111
|
-
appearance: datePickerAppearance,
|
|
110
|
+
return (jsxRuntime.jsx("div", { className: clsx(className, 'date-period', shapeClass && "date-period_shape_".concat(shapeClass), sizeClass && "date-period_size_".concat(sizeClass), isSkeleton && "date-period_skeleton", fillClass && "fill_".concat(fillClass), 'cursor_type_pointer'), children: jsxRuntime.jsxs(ChipsGroup.ChipsGroup, { direction: "horizontal", children: [datePeriodIntervalsList.map(function (datePeriodItem) { return (jsxRuntime.jsx(ChipsGroup.Chips, { appearance: "".concat(chipsAppearance, " ").concat(chipsAppearanceSize), label: datePeriodItem.label, shape: chipsShape, isActive: checkIsChipsActive(datePeriodItem), onClick: function () { return onClickPeriodChips(datePeriodItem); } }, datePeriodItem.value)); }), jsxRuntime.jsx(DatePicker.DatePickerInput, { datePickerProps: {
|
|
111
|
+
appearance: "".concat(datePickerAppearance, " ").concat(datePickerAppearanceSize),
|
|
112
112
|
dateFormat: 'dd/MM/yyyy',
|
|
113
113
|
selectsRange: true,
|
|
114
114
|
showWeekNumbers: true,
|