@dxc-technology/halstack-react 9.0.0 → 9.1.0
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/BackgroundColorContext.d.ts +2 -2
- package/BackgroundColorContext.js +1 -1
- package/HalstackContext.d.ts +1332 -5
- package/HalstackContext.js +59 -67
- package/accordion/Accordion.js +6 -11
- package/accordion/Accordion.stories.tsx +1 -1
- package/accordion/Accordion.test.js +1 -1
- package/accordion/types.d.ts +3 -3
- package/accordion-group/AccordionGroup.js +2 -2
- package/accordion-group/AccordionGroup.test.js +1 -1
- package/accordion-group/types.d.ts +2 -2
- package/alert/Alert.js +3 -5
- package/alert/Alert.test.js +1 -1
- package/bleed/Bleed.stories.tsx +1 -0
- package/box/Box.js +2 -2
- package/box/Box.test.js +1 -1
- package/button/Button.js +2 -3
- package/button/Button.stories.tsx +1 -1
- package/button/Button.test.js +1 -1
- package/button/types.d.ts +3 -3
- package/card/Card.js +12 -13
- package/card/Card.stories.tsx +12 -13
- package/card/Card.test.js +1 -1
- package/checkbox/Checkbox.js +3 -3
- package/checkbox/Checkbox.test.js +1 -1
- package/checkbox/types.d.ts +2 -2
- package/chip/Chip.js +2 -4
- package/chip/Chip.test.js +3 -5
- package/common/utils.d.ts +1 -0
- package/common/utils.js +4 -4
- package/common/variables.d.ts +1625 -0
- package/common/variables.js +2 -2
- package/dialog/Dialog.js +1 -1
- package/dialog/Dialog.test.js +24 -24
- package/dialog/types.d.ts +2 -2
- package/dropdown/Dropdown.js +2 -2
- package/dropdown/Dropdown.test.js +3 -2
- package/dropdown/DropdownMenuItem.js +0 -2
- package/dropdown/types.d.ts +3 -3
- package/file-input/FileInput.js +1 -2
- package/file-input/FileInput.test.js +1 -1
- package/flex/Flex.stories.tsx +19 -24
- package/footer/Footer.js +6 -8
- package/footer/Footer.test.js +14 -26
- package/grid/Grid.d.ts +7 -0
- package/grid/Grid.js +91 -0
- package/grid/Grid.stories.tsx +219 -0
- package/grid/types.d.ts +115 -0
- package/grid/types.js +5 -0
- package/header/Header.d.ts +3 -2
- package/header/Header.js +3 -3
- package/header/Header.test.js +2 -2
- package/header/types.d.ts +2 -2
- package/heading/Heading.js +1 -1
- package/heading/Heading.test.js +1 -1
- package/inset/Inset.stories.tsx +1 -0
- package/layout/ApplicationLayout.d.ts +3 -3
- package/layout/ApplicationLayout.js +1 -1
- package/layout/types.d.ts +2 -3
- package/link/Link.js +2 -2
- package/link/Link.test.js +2 -4
- package/link/types.d.ts +2 -2
- package/main.d.ts +2 -1
- package/main.js +8 -0
- package/nav-tabs/NavTabs.test.js +1 -1
- package/nav-tabs/Tab.js +7 -7
- package/number-input/NumberInput.test.js +1 -1
- package/package.json +2 -2
- package/paginator/Paginator.js +1 -3
- package/paginator/Paginator.test.js +27 -37
- package/paragraph/Paragraph.d.ts +3 -4
- package/paragraph/Paragraph.js +5 -5
- package/password-input/PasswordInput.test.js +1 -1
- package/progress-bar/ProgressBar.d.ts +2 -2
- package/progress-bar/ProgressBar.js +1 -1
- package/progress-bar/ProgressBar.test.js +1 -1
- package/progress-bar/types.d.ts +4 -3
- package/radio-group/RadioGroup.test.js +1 -1
- package/resultsetTable/ResultsetTable.js +2 -2
- package/resultsetTable/ResultsetTable.test.js +1 -1
- package/resultsetTable/types.d.ts +3 -3
- package/select/Select.js +13 -11
- package/select/Select.test.js +59 -59
- package/sidenav/Icons.d.ts +7 -0
- package/sidenav/Icons.js +51 -0
- package/sidenav/Sidenav.d.ts +2 -2
- package/sidenav/Sidenav.js +50 -76
- package/sidenav/Sidenav.stories.tsx +60 -60
- package/sidenav/types.d.ts +21 -18
- package/slider/Slider.js +2 -3
- package/slider/Slider.test.js +1 -1
- package/slider/types.d.ts +2 -2
- package/spinner/Spinner.js +15 -21
- package/spinner/Spinner.stories.jsx +28 -28
- package/spinner/Spinner.test.js +1 -1
- package/switch/Switch.js +2 -2
- package/switch/Switch.test.js +1 -1
- package/switch/types.d.ts +2 -2
- package/table/Table.js +2 -2
- package/table/Table.test.js +1 -1
- package/tabs/Tab.js +9 -10
- package/tabs/Tabs.js +11 -17
- package/tabs/Tabs.test.js +4 -5
- package/tabs/types.d.ts +2 -2
- package/tag/Tag.js +7 -9
- package/tag/Tag.test.js +1 -1
- package/text-input/Suggestion.js +2 -2
- package/text-input/TextInput.js +3 -3
- package/text-input/TextInput.test.js +1 -2
- package/textarea/Textarea.js +3 -4
- package/textarea/Textarea.test.js +2 -4
- package/toggle-group/ToggleGroup.js +7 -4
- package/toggle-group/ToggleGroup.test.js +1 -1
- package/toggle-group/types.d.ts +1 -1
- package/typography/Typography.d.ts +2 -2
- package/typography/Typography.js +14 -113
- package/typography/Typography.stories.tsx +1 -1
- package/useTheme.d.ts +1234 -1
- package/useTheme.js +1 -1
- package/useTranslatedLabels.d.ts +84 -1
- package/utils/BaseTypography.d.ts +21 -0
- package/utils/BaseTypography.js +108 -0
- package/utils/FocusLock.js +1 -1
- package/wizard/Wizard.js +2 -2
- package/wizard/Wizard.test.js +1 -1
- package/wizard/types.d.ts +5 -6
package/HalstackContext.js
CHANGED
|
@@ -15,11 +15,9 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _color = _interopRequireDefault(require("color"));
|
|
17
17
|
|
|
18
|
-
var _rgbHex = _interopRequireDefault(require("rgb-hex"));
|
|
19
|
-
|
|
20
18
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
21
19
|
|
|
22
|
-
var _variables = require("./common/variables
|
|
20
|
+
var _variables = require("./common/variables");
|
|
23
21
|
|
|
24
22
|
var _templateObject;
|
|
25
23
|
|
|
@@ -33,12 +31,12 @@ var HalstackLanguageContext = /*#__PURE__*/_react["default"].createContext(null)
|
|
|
33
31
|
|
|
34
32
|
exports.HalstackLanguageContext = HalstackLanguageContext;
|
|
35
33
|
|
|
36
|
-
var addLightness = function addLightness(
|
|
34
|
+
var addLightness = function addLightness(newLightness, hexColor) {
|
|
37
35
|
try {
|
|
38
36
|
if (hexColor) {
|
|
39
37
|
var color = (0, _color["default"])(hexColor);
|
|
40
38
|
var hslColor = color.hsl();
|
|
41
|
-
var lightnessColor = hslColor.
|
|
39
|
+
var lightnessColor = hslColor.lightness();
|
|
42
40
|
return hslColor.lightness(lightnessColor + newLightness).hex();
|
|
43
41
|
}
|
|
44
42
|
} catch (e) {
|
|
@@ -46,12 +44,12 @@ var addLightness = function addLightness(hexColor, newLightness) {
|
|
|
46
44
|
}
|
|
47
45
|
};
|
|
48
46
|
|
|
49
|
-
var subLightness = function subLightness(
|
|
47
|
+
var subLightness = function subLightness(newLightness, hexColor) {
|
|
50
48
|
try {
|
|
51
49
|
if (hexColor) {
|
|
52
50
|
var color = (0, _color["default"])(hexColor);
|
|
53
51
|
var hslColor = color.hsl();
|
|
54
|
-
var lightnessColor = hslColor.
|
|
52
|
+
var lightnessColor = hslColor.lightness();
|
|
55
53
|
return hslColor.lightness(lightnessColor - newLightness).hex();
|
|
56
54
|
}
|
|
57
55
|
} catch (e) {
|
|
@@ -59,17 +57,6 @@ var subLightness = function subLightness(hexColor, newLightness) {
|
|
|
59
57
|
}
|
|
60
58
|
};
|
|
61
59
|
|
|
62
|
-
var setOpacity = function setOpacity(hexColor, newOpacity) {
|
|
63
|
-
try {
|
|
64
|
-
if (hexColor) {
|
|
65
|
-
var color = (0, _color["default"])(hexColor);
|
|
66
|
-
return "#" + (0, _rgbHex["default"])(color.color[0], color.color[1], color.color[2], newOpacity);
|
|
67
|
-
}
|
|
68
|
-
} catch (e) {
|
|
69
|
-
return null;
|
|
70
|
-
}
|
|
71
|
-
};
|
|
72
|
-
|
|
73
60
|
var parseAdvancedTheme = function parseAdvancedTheme(advancedTheme) {
|
|
74
61
|
var allTokensCopy = JSON.parse(JSON.stringify(_variables.componentTokens));
|
|
75
62
|
Object.keys(allTokensCopy).map(function (component) {
|
|
@@ -98,7 +85,7 @@ var parseTheme = function parseTheme(theme) {
|
|
|
98
85
|
accordionTokens.titleLabelFontColor = (_theme$accordion$titl = theme === null || theme === void 0 ? void 0 : (_theme$accordion2 = theme.accordion) === null || _theme$accordion2 === void 0 ? void 0 : _theme$accordion2.titleFontColor) !== null && _theme$accordion$titl !== void 0 ? _theme$accordion$titl : accordionTokens.titleLabelFontColor;
|
|
99
86
|
accordionTokens.arrowColor = (_theme$accordion$acce = theme === null || theme === void 0 ? void 0 : (_theme$accordion3 = theme.accordion) === null || _theme$accordion3 === void 0 ? void 0 : _theme$accordion3.accentColor) !== null && _theme$accordion$acce !== void 0 ? _theme$accordion$acce : accordionTokens.arrowColor;
|
|
100
87
|
accordionTokens.iconColor = (_theme$accordion$acce2 = theme === null || theme === void 0 ? void 0 : (_theme$accordion4 = theme.accordion) === null || _theme$accordion4 === void 0 ? void 0 : _theme$accordion4.accentColor) !== null && _theme$accordion$acce2 !== void 0 ? _theme$accordion$acce2 : accordionTokens.iconColor;
|
|
101
|
-
accordionTokens.hoverBackgroundColor = (_addLightness = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$accordion5 = theme.accordion) === null || _theme$accordion5 === void 0 ? void 0 : _theme$accordion5.accentColor
|
|
88
|
+
accordionTokens.hoverBackgroundColor = (_addLightness = addLightness(57, theme === null || theme === void 0 ? void 0 : (_theme$accordion5 = theme.accordion) === null || _theme$accordion5 === void 0 ? void 0 : _theme$accordion5.accentColor)) !== null && _addLightness !== void 0 ? _addLightness : accordionTokens.hoverBackgroundColor;
|
|
102
89
|
var boxTokens = componentTokensCopy.box;
|
|
103
90
|
boxTokens.backgroundColor = (_theme$box$baseColor = theme === null || theme === void 0 ? void 0 : (_theme$box = theme.box) === null || _theme$box === void 0 ? void 0 : _theme$box.baseColor) !== null && _theme$box$baseColor !== void 0 ? _theme$box$baseColor : boxTokens.backgroundColor;
|
|
104
91
|
var buttonTokens = componentTokensCopy.button;
|
|
@@ -109,35 +96,35 @@ var parseTheme = function parseTheme(theme) {
|
|
|
109
96
|
buttonTokens.secondaryBorderColor = (_theme$button$baseCol3 = theme === null || theme === void 0 ? void 0 : (_theme$button5 = theme.button) === null || _theme$button5 === void 0 ? void 0 : _theme$button5.baseColor) !== null && _theme$button$baseCol3 !== void 0 ? _theme$button$baseCol3 : buttonTokens.secondaryBorderColor;
|
|
110
97
|
buttonTokens.secondaryHoverBackgroundColor = (_theme$button$baseCol4 = theme === null || theme === void 0 ? void 0 : (_theme$button6 = theme.button) === null || _theme$button6 === void 0 ? void 0 : _theme$button6.baseColor) !== null && _theme$button$baseCol4 !== void 0 ? _theme$button$baseCol4 : buttonTokens.secondaryHoverBackgroundColor;
|
|
111
98
|
buttonTokens.textFontColor = (_theme$button$baseCol5 = theme === null || theme === void 0 ? void 0 : (_theme$button7 = theme.button) === null || _theme$button7 === void 0 ? void 0 : _theme$button7.baseColor) !== null && _theme$button$baseCol5 !== void 0 ? _theme$button$baseCol5 : buttonTokens.textFontColor;
|
|
112
|
-
buttonTokens.primaryHoverBackgroundColor = (_subLightness = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$button8 = theme.button) === null || _theme$button8 === void 0 ? void 0 : _theme$button8.baseColor
|
|
113
|
-
buttonTokens.primaryActiveBackgroundColor = (_subLightness2 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$button9 = theme.button) === null || _theme$button9 === void 0 ? void 0 : _theme$button9.baseColor
|
|
114
|
-
buttonTokens.secondaryActiveBackgroundColor = (_subLightness3 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$button10 = theme.button) === null || _theme$button10 === void 0 ? void 0 : _theme$button10.baseColor
|
|
115
|
-
buttonTokens.textHoverBackgroundColor = (_addLightness2 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$button11 = theme.button) === null || _theme$button11 === void 0 ? void 0 : _theme$button11.baseColor
|
|
116
|
-
buttonTokens.textActiveBackgroundColor = (_addLightness3 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$button12 = theme.button) === null || _theme$button12 === void 0 ? void 0 : _theme$button12.baseColor
|
|
99
|
+
buttonTokens.primaryHoverBackgroundColor = (_subLightness = subLightness(8, theme === null || theme === void 0 ? void 0 : (_theme$button8 = theme.button) === null || _theme$button8 === void 0 ? void 0 : _theme$button8.baseColor)) !== null && _subLightness !== void 0 ? _subLightness : buttonTokens.primaryHoverBackgroundColor;
|
|
100
|
+
buttonTokens.primaryActiveBackgroundColor = (_subLightness2 = subLightness(18, theme === null || theme === void 0 ? void 0 : (_theme$button9 = theme.button) === null || _theme$button9 === void 0 ? void 0 : _theme$button9.baseColor)) !== null && _subLightness2 !== void 0 ? _subLightness2 : buttonTokens.primaryActiveBackgroundColor;
|
|
101
|
+
buttonTokens.secondaryActiveBackgroundColor = (_subLightness3 = subLightness(18, theme === null || theme === void 0 ? void 0 : (_theme$button10 = theme.button) === null || _theme$button10 === void 0 ? void 0 : _theme$button10.baseColor)) !== null && _subLightness3 !== void 0 ? _subLightness3 : buttonTokens.secondaryActiveBackgroundColor;
|
|
102
|
+
buttonTokens.textHoverBackgroundColor = (_addLightness2 = addLightness(57, theme === null || theme === void 0 ? void 0 : (_theme$button11 = theme.button) === null || _theme$button11 === void 0 ? void 0 : _theme$button11.baseColor)) !== null && _addLightness2 !== void 0 ? _addLightness2 : buttonTokens.textHoverBackgroundColor;
|
|
103
|
+
buttonTokens.textActiveBackgroundColor = (_addLightness3 = addLightness(52, theme === null || theme === void 0 ? void 0 : (_theme$button12 = theme.button) === null || _theme$button12 === void 0 ? void 0 : _theme$button12.baseColor)) !== null && _addLightness3 !== void 0 ? _addLightness3 : buttonTokens.textActiveBackgroundColor;
|
|
117
104
|
var checkboxTokens = componentTokensCopy.checkbox;
|
|
118
105
|
checkboxTokens.backgroundColorChecked = (_theme$checkbox$baseC = theme === null || theme === void 0 ? void 0 : (_theme$checkbox = theme.checkbox) === null || _theme$checkbox === void 0 ? void 0 : _theme$checkbox.baseColor) !== null && _theme$checkbox$baseC !== void 0 ? _theme$checkbox$baseC : checkboxTokens.backgroundColorChecked;
|
|
119
106
|
checkboxTokens.borderColor = (_theme$checkbox$baseC2 = theme === null || theme === void 0 ? void 0 : (_theme$checkbox2 = theme.checkbox) === null || _theme$checkbox2 === void 0 ? void 0 : _theme$checkbox2.baseColor) !== null && _theme$checkbox$baseC2 !== void 0 ? _theme$checkbox$baseC2 : checkboxTokens.borderColor;
|
|
120
107
|
checkboxTokens.checkColor = (_theme$checkbox$check = theme === null || theme === void 0 ? void 0 : (_theme$checkbox3 = theme.checkbox) === null || _theme$checkbox3 === void 0 ? void 0 : _theme$checkbox3.checkColor) !== null && _theme$checkbox$check !== void 0 ? _theme$checkbox$check : checkboxTokens.checkColor;
|
|
121
108
|
checkboxTokens.fontColor = (_theme$checkbox$fontC = theme === null || theme === void 0 ? void 0 : (_theme$checkbox4 = theme.checkbox) === null || _theme$checkbox4 === void 0 ? void 0 : _theme$checkbox4.fontColor) !== null && _theme$checkbox$fontC !== void 0 ? _theme$checkbox$fontC : checkboxTokens.fontColor;
|
|
122
|
-
checkboxTokens.hoverBackgroundColorChecked = (_subLightness4 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$checkbox5 = theme.checkbox) === null || _theme$checkbox5 === void 0 ? void 0 : _theme$checkbox5.baseColor
|
|
123
|
-
checkboxTokens.hoverBorderColor = (_subLightness5 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$checkbox6 = theme.checkbox) === null || _theme$checkbox6 === void 0 ? void 0 : _theme$checkbox6.baseColor
|
|
109
|
+
checkboxTokens.hoverBackgroundColorChecked = (_subLightness4 = subLightness(15, theme === null || theme === void 0 ? void 0 : (_theme$checkbox5 = theme.checkbox) === null || _theme$checkbox5 === void 0 ? void 0 : _theme$checkbox5.baseColor)) !== null && _subLightness4 !== void 0 ? _subLightness4 : checkboxTokens.hoverBackgroundColorChecked;
|
|
110
|
+
checkboxTokens.hoverBorderColor = (_subLightness5 = subLightness(15, theme === null || theme === void 0 ? void 0 : (_theme$checkbox6 = theme.checkbox) === null || _theme$checkbox6 === void 0 ? void 0 : _theme$checkbox6.baseColor)) !== null && _subLightness5 !== void 0 ? _subLightness5 : checkboxTokens.hoverBorderColor;
|
|
124
111
|
var chipTokens = componentTokensCopy.chip;
|
|
125
112
|
chipTokens.backgroundColor = (_theme$chip$baseColor = theme === null || theme === void 0 ? void 0 : (_theme$chip = theme.chip) === null || _theme$chip === void 0 ? void 0 : _theme$chip.baseColor) !== null && _theme$chip$baseColor !== void 0 ? _theme$chip$baseColor : chipTokens.backgroundColor;
|
|
126
113
|
chipTokens.fontColor = (_theme$chip$fontColor = theme === null || theme === void 0 ? void 0 : (_theme$chip2 = theme.chip) === null || _theme$chip2 === void 0 ? void 0 : _theme$chip2.fontColor) !== null && _theme$chip$fontColor !== void 0 ? _theme$chip$fontColor : chipTokens.fontColor;
|
|
127
114
|
chipTokens.iconColor = (_theme$chip$iconColor = theme === null || theme === void 0 ? void 0 : (_theme$chip3 = theme.chip) === null || _theme$chip3 === void 0 ? void 0 : _theme$chip3.iconColor) !== null && _theme$chip$iconColor !== void 0 ? _theme$chip$iconColor : chipTokens.iconColor;
|
|
128
|
-
chipTokens.hoverIconColor = (_subLightness6 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$chip4 = theme.chip) === null || _theme$chip4 === void 0 ? void 0 : _theme$chip4.iconColor
|
|
129
|
-
chipTokens.activeIconColor = (_subLightness7 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$chip5 = theme.chip) === null || _theme$chip5 === void 0 ? void 0 : _theme$chip5.iconColor
|
|
115
|
+
chipTokens.hoverIconColor = (_subLightness6 = subLightness(10, theme === null || theme === void 0 ? void 0 : (_theme$chip4 = theme.chip) === null || _theme$chip4 === void 0 ? void 0 : _theme$chip4.iconColor)) !== null && _subLightness6 !== void 0 ? _subLightness6 : chipTokens.hoverIconColor;
|
|
116
|
+
chipTokens.activeIconColor = (_subLightness7 = subLightness(30, theme === null || theme === void 0 ? void 0 : (_theme$chip5 = theme.chip) === null || _theme$chip5 === void 0 ? void 0 : _theme$chip5.iconColor)) !== null && _subLightness7 !== void 0 ? _subLightness7 : chipTokens.activeIconColor;
|
|
130
117
|
var dateTokens = componentTokensCopy.dateInput;
|
|
131
118
|
dateTokens.pickerSelectedBackgroundColor = (_theme$dateInput$base = theme === null || theme === void 0 ? void 0 : (_theme$dateInput = theme.dateInput) === null || _theme$dateInput === void 0 ? void 0 : _theme$dateInput.baseColor) !== null && _theme$dateInput$base !== void 0 ? _theme$dateInput$base : dateTokens.pickerSelectedBackgroundColor;
|
|
132
119
|
dateTokens.pickerSelectedFontColor = (_theme$dateInput$sele = theme === null || theme === void 0 ? void 0 : (_theme$dateInput2 = theme.dateInput) === null || _theme$dateInput2 === void 0 ? void 0 : _theme$dateInput2.selectedFontColor) !== null && _theme$dateInput$sele !== void 0 ? _theme$dateInput$sele : dateTokens.pickerSelectedFontColor;
|
|
133
|
-
dateTokens.pickerActiveBackgroundColor = (_subLightness8 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$dateInput3 = theme.dateInput) === null || _theme$dateInput3 === void 0 ? void 0 : _theme$dateInput3.baseColor
|
|
120
|
+
dateTokens.pickerActiveBackgroundColor = (_subLightness8 = subLightness(8, theme === null || theme === void 0 ? void 0 : (_theme$dateInput3 = theme.dateInput) === null || _theme$dateInput3 === void 0 ? void 0 : _theme$dateInput3.baseColor)) !== null && _subLightness8 !== void 0 ? _subLightness8 : dateTokens.pickerActiveBackgroundColor;
|
|
134
121
|
dateTokens.pickerActiveFontColor = (_theme$dateInput$sele2 = theme === null || theme === void 0 ? void 0 : (_theme$dateInput4 = theme.dateInput) === null || _theme$dateInput4 === void 0 ? void 0 : _theme$dateInput4.selectedFontColor) !== null && _theme$dateInput$sele2 !== void 0 ? _theme$dateInput$sele2 : dateTokens.pickerActiveFontColor;
|
|
135
122
|
dateTokens.pickerCurrentYearFontColor = (_theme$dateInput$base2 = theme === null || theme === void 0 ? void 0 : (_theme$dateInput5 = theme.dateInput) === null || _theme$dateInput5 === void 0 ? void 0 : _theme$dateInput5.baseColor) !== null && _theme$dateInput$base2 !== void 0 ? _theme$dateInput$base2 : dateTokens.pickerCurrentYearFontColor;
|
|
136
|
-
dateTokens.pickerHeaderActiveBackgroundColor = (_subLightness9 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$dateInput6 = theme.dateInput) === null || _theme$dateInput6 === void 0 ? void 0 : _theme$dateInput6.baseColor
|
|
123
|
+
dateTokens.pickerHeaderActiveBackgroundColor = (_subLightness9 = subLightness(8, theme === null || theme === void 0 ? void 0 : (_theme$dateInput6 = theme.dateInput) === null || _theme$dateInput6 === void 0 ? void 0 : _theme$dateInput6.baseColor)) !== null && _subLightness9 !== void 0 ? _subLightness9 : dateTokens.pickerHeaderActiveBackgroundColor;
|
|
137
124
|
dateTokens.pickerHeaderActiveFontColor = (_theme$dateInput$sele3 = theme === null || theme === void 0 ? void 0 : (_theme$dateInput7 = theme.dateInput) === null || _theme$dateInput7 === void 0 ? void 0 : _theme$dateInput7.selectedFontColor) !== null && _theme$dateInput$sele3 !== void 0 ? _theme$dateInput$sele3 : dateTokens.pickerHeaderActiveFontColor;
|
|
138
|
-
dateTokens.pickerHoverBackgroundColor = (_addLightness4 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$dateInput8 = theme.dateInput) === null || _theme$dateInput8 === void 0 ? void 0 : _theme$dateInput8.baseColor
|
|
139
|
-
dateTokens.pickerCurrentDateBorderColor = (_addLightness5 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$dateInput9 = theme.dateInput) === null || _theme$dateInput9 === void 0 ? void 0 : _theme$dateInput9.baseColor
|
|
140
|
-
dateTokens.pickerHeaderHoverBackgroundColor = (_addLightness6 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$dateInput10 = theme.dateInput) === null || _theme$dateInput10 === void 0 ? void 0 : _theme$dateInput10.baseColor
|
|
125
|
+
dateTokens.pickerHoverBackgroundColor = (_addLightness4 = addLightness(52, theme === null || theme === void 0 ? void 0 : (_theme$dateInput8 = theme.dateInput) === null || _theme$dateInput8 === void 0 ? void 0 : _theme$dateInput8.baseColor)) !== null && _addLightness4 !== void 0 ? _addLightness4 : dateTokens.pickerHoverBackgroundColor;
|
|
126
|
+
dateTokens.pickerCurrentDateBorderColor = (_addLightness5 = addLightness(42, theme === null || theme === void 0 ? void 0 : (_theme$dateInput9 = theme.dateInput) === null || _theme$dateInput9 === void 0 ? void 0 : _theme$dateInput9.baseColor)) !== null && _addLightness5 !== void 0 ? _addLightness5 : dateTokens.pickerCurrentDateBorderColor;
|
|
127
|
+
dateTokens.pickerHeaderHoverBackgroundColor = (_addLightness6 = addLightness(52, theme === null || theme === void 0 ? void 0 : (_theme$dateInput10 = theme.dateInput) === null || _theme$dateInput10 === void 0 ? void 0 : _theme$dateInput10.baseColor)) !== null && _addLightness6 !== void 0 ? _addLightness6 : dateTokens.pickerHeaderHoverBackgroundColor;
|
|
141
128
|
var dialogTokens = componentTokensCopy.dialog;
|
|
142
129
|
dialogTokens.backgroundColor = (_theme$dialog$baseCol = theme === null || theme === void 0 ? void 0 : (_theme$dialog = theme.dialog) === null || _theme$dialog === void 0 ? void 0 : _theme$dialog.baseColor) !== null && _theme$dialog$baseCol !== void 0 ? _theme$dialog$baseCol : dialogTokens.backgroundColor;
|
|
143
130
|
dialogTokens.closeIconColor = (_theme$dialog$closeIc = theme === null || theme === void 0 ? void 0 : (_theme$dialog2 = theme.dialog) === null || _theme$dialog2 === void 0 ? void 0 : _theme$dialog2.closeIconColor) !== null && _theme$dialog$closeIc !== void 0 ? _theme$dialog$closeIc : dialogTokens.closeIconColor;
|
|
@@ -149,10 +136,10 @@ var parseTheme = function parseTheme(theme) {
|
|
|
149
136
|
dropdownTokens.caretIconColor = (_theme$dropdown$fontC3 = theme === null || theme === void 0 ? void 0 : (_theme$dropdown4 = theme.dropdown) === null || _theme$dropdown4 === void 0 ? void 0 : _theme$dropdown4.fontColor) !== null && _theme$dropdown$fontC3 !== void 0 ? _theme$dropdown$fontC3 : dropdownTokens.caretIconColor;
|
|
150
137
|
dropdownTokens.optionFontColor = (_theme$dropdown$optio = theme === null || theme === void 0 ? void 0 : (_theme$dropdown5 = theme.dropdown) === null || _theme$dropdown5 === void 0 ? void 0 : _theme$dropdown5.optionFontColor) !== null && _theme$dropdown$optio !== void 0 ? _theme$dropdown$optio : dropdownTokens.optionFontColor;
|
|
151
138
|
dropdownTokens.optionIconColor = (_theme$dropdown$optio2 = theme === null || theme === void 0 ? void 0 : (_theme$dropdown6 = theme.dropdown) === null || _theme$dropdown6 === void 0 ? void 0 : _theme$dropdown6.optionFontColor) !== null && _theme$dropdown$optio2 !== void 0 ? _theme$dropdown$optio2 : dropdownTokens.optionIconColor;
|
|
152
|
-
dropdownTokens.hoverButtonBackgroundColor = (_subLightness10 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$dropdown7 = theme.dropdown) === null || _theme$dropdown7 === void 0 ? void 0 : _theme$dropdown7.baseColor
|
|
153
|
-
dropdownTokens.activeButtonBackgroundColor = (_subLightness11 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$dropdown8 = theme.dropdown) === null || _theme$dropdown8 === void 0 ? void 0 : _theme$dropdown8.baseColor
|
|
154
|
-
dropdownTokens.hoverOptionBackgroundColor = (_subLightness12 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$dropdown9 = theme.dropdown) === null || _theme$dropdown9 === void 0 ? void 0 : _theme$dropdown9.baseColor
|
|
155
|
-
dropdownTokens.activeOptionBackgroundColor = (_subLightness13 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$dropdown10 = theme.dropdown) === null || _theme$dropdown10 === void 0 ? void 0 : _theme$dropdown10.baseColor
|
|
139
|
+
dropdownTokens.hoverButtonBackgroundColor = (_subLightness10 = subLightness(5, theme === null || theme === void 0 ? void 0 : (_theme$dropdown7 = theme.dropdown) === null || _theme$dropdown7 === void 0 ? void 0 : _theme$dropdown7.baseColor)) !== null && _subLightness10 !== void 0 ? _subLightness10 : dropdownTokens.hoverButtonBackgroundColor;
|
|
140
|
+
dropdownTokens.activeButtonBackgroundColor = (_subLightness11 = subLightness(12, theme === null || theme === void 0 ? void 0 : (_theme$dropdown8 = theme.dropdown) === null || _theme$dropdown8 === void 0 ? void 0 : _theme$dropdown8.baseColor)) !== null && _subLightness11 !== void 0 ? _subLightness11 : dropdownTokens.activeButtonBackgroundColor;
|
|
141
|
+
dropdownTokens.hoverOptionBackgroundColor = (_subLightness12 = subLightness(5, theme === null || theme === void 0 ? void 0 : (_theme$dropdown9 = theme.dropdown) === null || _theme$dropdown9 === void 0 ? void 0 : _theme$dropdown9.baseColor)) !== null && _subLightness12 !== void 0 ? _subLightness12 : dropdownTokens.hoverOptionBackgroundColor;
|
|
142
|
+
dropdownTokens.activeOptionBackgroundColor = (_subLightness13 = subLightness(20, theme === null || theme === void 0 ? void 0 : (_theme$dropdown10 = theme.dropdown) === null || _theme$dropdown10 === void 0 ? void 0 : _theme$dropdown10.baseColor)) !== null && _subLightness13 !== void 0 ? _subLightness13 : dropdownTokens.activeOptionBackgroundColor;
|
|
156
143
|
var fileInputTokens = componentTokensCopy.fileInput;
|
|
157
144
|
fileInputTokens.labelFontColor = (_theme$fileInput$font = theme === null || theme === void 0 ? void 0 : (_theme$fileInput = theme.fileInput) === null || _theme$fileInput === void 0 ? void 0 : _theme$fileInput.fontColor) !== null && _theme$fileInput$font !== void 0 ? _theme$fileInput$font : fileInputTokens.labelFontColor;
|
|
158
145
|
fileInputTokens.helperTextFontColor = (_theme$fileInput$font2 = theme === null || theme === void 0 ? void 0 : (_theme$fileInput2 = theme.fileInput) === null || _theme$fileInput2 === void 0 ? void 0 : _theme$fileInput2.fontColor) !== null && _theme$fileInput$font2 !== void 0 ? _theme$fileInput$font2 : fileInputTokens.helperTextFontColor;
|
|
@@ -171,7 +158,7 @@ var parseTheme = function parseTheme(theme) {
|
|
|
171
158
|
headerTokens.menuBackgroundColor = (_theme$header$menuBas = theme === null || theme === void 0 ? void 0 : (_theme$header3 = theme.header) === null || _theme$header3 === void 0 ? void 0 : _theme$header3.menuBaseColor) !== null && _theme$header$menuBas !== void 0 ? _theme$header$menuBas : headerTokens.menuBackgroundColor;
|
|
172
159
|
headerTokens.hamburguerFontColor = (_theme$header$fontCol = theme === null || theme === void 0 ? void 0 : (_theme$header4 = theme.header) === null || _theme$header4 === void 0 ? void 0 : _theme$header4.fontColor) !== null && _theme$header$fontCol !== void 0 ? _theme$header$fontCol : headerTokens.hamburguerFontColor;
|
|
173
160
|
headerTokens.hamburguerIconColor = (_theme$header$hamburg = theme === null || theme === void 0 ? void 0 : (_theme$header5 = theme.header) === null || _theme$header5 === void 0 ? void 0 : _theme$header5.hamburguerColor) !== null && _theme$header$hamburg !== void 0 ? _theme$header$hamburg : headerTokens.hamburguerIconColor;
|
|
174
|
-
headerTokens.hamburguerHoverColor = (_addLightness7 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$header6 = theme.header) === null || _theme$header6 === void 0 ? void 0 : _theme$header6.hamburguerColor
|
|
161
|
+
headerTokens.hamburguerHoverColor = (_addLightness7 = addLightness(90, theme === null || theme === void 0 ? void 0 : (_theme$header6 = theme.header) === null || _theme$header6 === void 0 ? void 0 : _theme$header6.hamburguerColor)) !== null && _addLightness7 !== void 0 ? _addLightness7 : headerTokens.hamburguerHoverColor;
|
|
175
162
|
headerTokens.logo = (_theme$header$logo = theme === null || theme === void 0 ? void 0 : (_theme$header7 = theme.header) === null || _theme$header7 === void 0 ? void 0 : _theme$header7.logo) !== null && _theme$header$logo !== void 0 ? _theme$header$logo : headerTokens.logo;
|
|
176
163
|
headerTokens.logoResponsive = (_theme$header$logoRes = theme === null || theme === void 0 ? void 0 : (_theme$header8 = theme.header) === null || _theme$header8 === void 0 ? void 0 : _theme$header8.logoResponsive) !== null && _theme$header$logoRes !== void 0 ? _theme$header$logoRes : headerTokens.logoResponsive;
|
|
177
164
|
headerTokens.contentColor = (_theme$header$content = theme === null || theme === void 0 ? void 0 : (_theme$header9 = theme.header) === null || _theme$header9 === void 0 ? void 0 : _theme$header9.contentColor) !== null && _theme$header$content !== void 0 ? _theme$header$content : headerTokens.contentColor;
|
|
@@ -185,8 +172,8 @@ var parseTheme = function parseTheme(theme) {
|
|
|
185
172
|
navTabsTokens.selectedIconColor = (_theme$navTabs$baseCo3 = theme === null || theme === void 0 ? void 0 : (_theme$navTabs3 = theme.navTabs) === null || _theme$navTabs3 === void 0 ? void 0 : _theme$navTabs3.baseColor) !== null && _theme$navTabs$baseCo3 !== void 0 ? _theme$navTabs$baseCo3 : navTabsTokens.selectedIconColor;
|
|
186
173
|
navTabsTokens.unselectedIconColor = (_theme$navTabs$baseCo4 = theme === null || theme === void 0 ? void 0 : (_theme$navTabs4 = theme.navTabs) === null || _theme$navTabs4 === void 0 ? void 0 : _theme$navTabs4.baseColor) !== null && _theme$navTabs$baseCo4 !== void 0 ? _theme$navTabs$baseCo4 : navTabsTokens.selectedIconColor;
|
|
187
174
|
navTabsTokens.selectedUnderlineColor = (_theme$navTabs$accent = theme === null || theme === void 0 ? void 0 : (_theme$navTabs5 = theme.navTabs) === null || _theme$navTabs5 === void 0 ? void 0 : _theme$navTabs5.accentColor) !== null && _theme$navTabs$accent !== void 0 ? _theme$navTabs$accent : navTabsTokens.selectedUnderlineColor;
|
|
188
|
-
navTabsTokens.hoverBackgroundColor = (_addLightness8 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$navTabs6 = theme.navTabs) === null || _theme$navTabs6 === void 0 ? void 0 : _theme$navTabs6.baseColor
|
|
189
|
-
navTabsTokens.pressedBackgroundColor = (_addLightness9 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$navTabs7 = theme.navTabs) === null || _theme$navTabs7 === void 0 ? void 0 : _theme$navTabs7.baseColor
|
|
175
|
+
navTabsTokens.hoverBackgroundColor = (_addLightness8 = addLightness(55, theme === null || theme === void 0 ? void 0 : (_theme$navTabs6 = theme.navTabs) === null || _theme$navTabs6 === void 0 ? void 0 : _theme$navTabs6.baseColor)) !== null && _addLightness8 !== void 0 ? _addLightness8 : navTabsTokens.hoverBackgroundColor;
|
|
176
|
+
navTabsTokens.pressedBackgroundColor = (_addLightness9 = addLightness(50, theme === null || theme === void 0 ? void 0 : (_theme$navTabs7 = theme.navTabs) === null || _theme$navTabs7 === void 0 ? void 0 : _theme$navTabs7.baseColor)) !== null && _addLightness9 !== void 0 ? _addLightness9 : navTabsTokens.pressedBackgroundColor;
|
|
190
177
|
var paginatorTokens = componentTokensCopy.paginator;
|
|
191
178
|
paginatorTokens.backgroundColor = (_theme$paginator$base = theme === null || theme === void 0 ? void 0 : (_theme$paginator = theme.paginator) === null || _theme$paginator === void 0 ? void 0 : _theme$paginator.baseColor) !== null && _theme$paginator$base !== void 0 ? _theme$paginator$base : paginatorTokens.backgroundColor;
|
|
192
179
|
paginatorTokens.fontColor = (_theme$paginator$font = theme === null || theme === void 0 ? void 0 : (_theme$paginator2 = theme.paginator) === null || _theme$paginator2 === void 0 ? void 0 : _theme$paginator2.fontColor) !== null && _theme$paginator$font !== void 0 ? _theme$paginator$font : paginatorTokens.fontColor;
|
|
@@ -206,19 +193,19 @@ var parseTheme = function parseTheme(theme) {
|
|
|
206
193
|
radioGroupTokens.labelFontColor = (_theme$radioGroup$fon = theme === null || theme === void 0 ? void 0 : (_theme$radioGroup2 = theme.radioGroup) === null || _theme$radioGroup2 === void 0 ? void 0 : _theme$radioGroup2.fontColor) !== null && _theme$radioGroup$fon !== void 0 ? _theme$radioGroup$fon : radioGroupTokens.labelFontColor;
|
|
207
194
|
radioGroupTokens.helperTextFontColor = (_theme$radioGroup$fon2 = theme === null || theme === void 0 ? void 0 : (_theme$radioGroup3 = theme.radioGroup) === null || _theme$radioGroup3 === void 0 ? void 0 : _theme$radioGroup3.fontColor) !== null && _theme$radioGroup$fon2 !== void 0 ? _theme$radioGroup$fon2 : radioGroupTokens.helperTextFontColor;
|
|
208
195
|
radioGroupTokens.radioInputLabelFontColor = (_theme$radioGroup$fon3 = theme === null || theme === void 0 ? void 0 : (_theme$radioGroup4 = theme.radioGroup) === null || _theme$radioGroup4 === void 0 ? void 0 : _theme$radioGroup4.fontColor) !== null && _theme$radioGroup$fon3 !== void 0 ? _theme$radioGroup$fon3 : radioGroupTokens.radioInputLabelFontColor;
|
|
209
|
-
radioGroupTokens.hoverRadioInputColor = (_subLightness14 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$radioGroup5 = theme.radioGroup) === null || _theme$radioGroup5 === void 0 ? void 0 : _theme$radioGroup5.baseColor
|
|
210
|
-
radioGroupTokens.activeRadioInputColor = (_subLightness15 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$radioGroup6 = theme.radioGroup) === null || _theme$radioGroup6 === void 0 ? void 0 : _theme$radioGroup6.baseColor
|
|
196
|
+
radioGroupTokens.hoverRadioInputColor = (_subLightness14 = subLightness(10, theme === null || theme === void 0 ? void 0 : (_theme$radioGroup5 = theme.radioGroup) === null || _theme$radioGroup5 === void 0 ? void 0 : _theme$radioGroup5.baseColor)) !== null && _subLightness14 !== void 0 ? _subLightness14 : radioGroupTokens.radioInputColor;
|
|
197
|
+
radioGroupTokens.activeRadioInputColor = (_subLightness15 = subLightness(25, theme === null || theme === void 0 ? void 0 : (_theme$radioGroup6 = theme.radioGroup) === null || _theme$radioGroup6 === void 0 ? void 0 : _theme$radioGroup6.baseColor)) !== null && _subLightness15 !== void 0 ? _subLightness15 : radioGroupTokens.radioInputColor;
|
|
211
198
|
var selectTokens = componentTokensCopy.select;
|
|
212
199
|
selectTokens.selectedListOptionBackgroundColor = (_theme$select$selecte = theme === null || theme === void 0 ? void 0 : (_theme$select = theme.select) === null || _theme$select === void 0 ? void 0 : _theme$select.selectedOptionBackgroundColor) !== null && _theme$select$selecte !== void 0 ? _theme$select$selecte : selectTokens.selectedListOptionBackgroundColor;
|
|
213
200
|
selectTokens.valueFontColor = (_theme$select$fontCol = theme === null || theme === void 0 ? void 0 : (_theme$select2 = theme.select) === null || _theme$select2 === void 0 ? void 0 : _theme$select2.fontColor) !== null && _theme$select$fontCol !== void 0 ? _theme$select$fontCol : selectTokens.valueFontColor;
|
|
214
201
|
selectTokens.labelFontColor = (_theme$select$fontCol2 = theme === null || theme === void 0 ? void 0 : (_theme$select3 = theme.select) === null || _theme$select3 === void 0 ? void 0 : _theme$select3.fontColor) !== null && _theme$select$fontCol2 !== void 0 ? _theme$select$fontCol2 : selectTokens.labelFontColor;
|
|
215
202
|
selectTokens.helperTextFontColor = (_theme$select$fontCol3 = theme === null || theme === void 0 ? void 0 : (_theme$select4 = theme.select) === null || _theme$select4 === void 0 ? void 0 : _theme$select4.fontColor) !== null && _theme$select$fontCol3 !== void 0 ? _theme$select$fontCol3 : selectTokens.helperTextFontColor;
|
|
216
|
-
selectTokens.listOptionFontColor = (_theme$select$optionF = theme === null || theme === void 0 ? void 0 : (_theme$select5 = theme.select) === null || _theme$select5 === void 0 ? void 0 : _theme$select5.optionFontColor) !== null && _theme$select$optionF !== void 0 ? _theme$select$optionF : selectTokens.
|
|
217
|
-
selectTokens.placeholderFontColor = (_addLightness10 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$select6 = theme.select) === null || _theme$select6 === void 0 ? void 0 : _theme$select6.fontColor
|
|
203
|
+
selectTokens.listOptionFontColor = (_theme$select$optionF = theme === null || theme === void 0 ? void 0 : (_theme$select5 = theme.select) === null || _theme$select5 === void 0 ? void 0 : _theme$select5.optionFontColor) !== null && _theme$select$optionF !== void 0 ? _theme$select$optionF : selectTokens.listOptionFontColor;
|
|
204
|
+
selectTokens.placeholderFontColor = (_addLightness10 = addLightness(30, theme === null || theme === void 0 ? void 0 : (_theme$select6 = theme.select) === null || _theme$select6 === void 0 ? void 0 : _theme$select6.fontColor)) !== null && _addLightness10 !== void 0 ? _addLightness10 : selectTokens.placeholderFontColor;
|
|
218
205
|
selectTokens.collapseIndicatorColor = (_theme$select$fontCol4 = theme === null || theme === void 0 ? void 0 : (_theme$select7 = theme.select) === null || _theme$select7 === void 0 ? void 0 : _theme$select7.fontColor) !== null && _theme$select$fontCol4 !== void 0 ? _theme$select$fontCol4 : selectTokens.collapseIndicatorColor;
|
|
219
206
|
selectTokens.hoverInputBorderColor = (_theme$select$hoverBo = theme === null || theme === void 0 ? void 0 : (_theme$select8 = theme.select) === null || _theme$select8 === void 0 ? void 0 : _theme$select8.hoverBorderColor) !== null && _theme$select$hoverBo !== void 0 ? _theme$select$hoverBo : selectTokens.hoverInputBorderColor;
|
|
220
|
-
selectTokens.selectedHoverListOptionBackgroundColor = (_subLightness16 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$select9 = theme.select) === null || _theme$select9 === void 0 ? void 0 : _theme$select9.selectedOptionBackgroundColor
|
|
221
|
-
selectTokens.selectedActiveListOptionBackgroundColor = (_subLightness17 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$select10 = theme.select) === null || _theme$select10 === void 0 ? void 0 : _theme$select10.selectedOptionBackgroundColor
|
|
207
|
+
selectTokens.selectedHoverListOptionBackgroundColor = (_subLightness16 = subLightness(5, theme === null || theme === void 0 ? void 0 : (_theme$select9 = theme.select) === null || _theme$select9 === void 0 ? void 0 : _theme$select9.selectedOptionBackgroundColor)) !== null && _subLightness16 !== void 0 ? _subLightness16 : selectTokens.selectedHoverListOptionBackgroundColor;
|
|
208
|
+
selectTokens.selectedActiveListOptionBackgroundColor = (_subLightness17 = subLightness(15, theme === null || theme === void 0 ? void 0 : (_theme$select10 = theme.select) === null || _theme$select10 === void 0 ? void 0 : _theme$select10.selectedOptionBackgroundColor)) !== null && _subLightness17 !== void 0 ? _subLightness17 : selectTokens.selectedActiveListOptionBackgroundColor;
|
|
222
209
|
var sideNavTokens = componentTokensCopy.sidenav;
|
|
223
210
|
sideNavTokens.backgroundColor = (_theme$sidenav$baseCo = theme === null || theme === void 0 ? void 0 : (_theme$sidenav = theme.sidenav) === null || _theme$sidenav === void 0 ? void 0 : _theme$sidenav.baseColor) !== null && _theme$sidenav$baseCo !== void 0 ? _theme$sidenav$baseCo : sideNavTokens.backgroundColor;
|
|
224
211
|
var sliderTokens = componentTokensCopy.slider;
|
|
@@ -230,8 +217,8 @@ var parseTheme = function parseTheme(theme) {
|
|
|
230
217
|
sliderTokens.tickBackgroundColor = (_theme$slider$baseCol3 = theme === null || theme === void 0 ? void 0 : (_theme$slider6 = theme.slider) === null || _theme$slider6 === void 0 ? void 0 : _theme$slider6.baseColor) !== null && _theme$slider$baseCol3 !== void 0 ? _theme$slider$baseCol3 : sliderTokens.tickBackgroundColor;
|
|
231
218
|
sliderTokens.trackLineColor = (_theme$slider$baseCol4 = theme === null || theme === void 0 ? void 0 : (_theme$slider7 = theme.slider) === null || _theme$slider7 === void 0 ? void 0 : _theme$slider7.baseColor) !== null && _theme$slider$baseCol4 !== void 0 ? _theme$slider$baseCol4 : sliderTokens.trackLineColor;
|
|
232
219
|
sliderTokens.totalLineColor = (_theme$slider$totalLi = theme === null || theme === void 0 ? void 0 : (_theme$slider8 = theme.slider) === null || _theme$slider8 === void 0 ? void 0 : _theme$slider8.totalLineColor) !== null && _theme$slider$totalLi !== void 0 ? _theme$slider$totalLi : sliderTokens.totalLineColor;
|
|
233
|
-
sliderTokens.hoverThumbBackgroundColor = (_subLightness18 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$slider9 = theme.slider) === null || _theme$slider9 === void 0 ? void 0 : _theme$slider9.baseColor
|
|
234
|
-
sliderTokens.activeThumbBackgroundColor = (_subLightness19 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$slider10 = theme.slider) === null || _theme$slider10 === void 0 ? void 0 : _theme$slider10.baseColor
|
|
220
|
+
sliderTokens.hoverThumbBackgroundColor = (_subLightness18 = subLightness(15, theme === null || theme === void 0 ? void 0 : (_theme$slider9 = theme.slider) === null || _theme$slider9 === void 0 ? void 0 : _theme$slider9.baseColor)) !== null && _subLightness18 !== void 0 ? _subLightness18 : sliderTokens.thumbBackgroundColor;
|
|
221
|
+
sliderTokens.activeThumbBackgroundColor = (_subLightness19 = subLightness(15, theme === null || theme === void 0 ? void 0 : (_theme$slider10 = theme.slider) === null || _theme$slider10 === void 0 ? void 0 : _theme$slider10.baseColor)) !== null && _subLightness19 !== void 0 ? _subLightness19 : sliderTokens.thumbBackgroundColor;
|
|
235
222
|
var spinnerTokens = componentTokensCopy.spinner;
|
|
236
223
|
spinnerTokens.trackCircleColor = (_theme$spinner$accent = theme === null || theme === void 0 ? void 0 : (_theme$spinner = theme.spinner) === null || _theme$spinner === void 0 ? void 0 : _theme$spinner.accentColor) !== null && _theme$spinner$accent !== void 0 ? _theme$spinner$accent : spinnerTokens.trackCircleColor;
|
|
237
224
|
spinnerTokens.totalCircleColor = (_theme$spinner$baseCo = theme === null || theme === void 0 ? void 0 : (_theme$spinner2 = theme.spinner) === null || _theme$spinner2 === void 0 ? void 0 : _theme$spinner2.baseColor) !== null && _theme$spinner$baseCo !== void 0 ? _theme$spinner$baseCo : spinnerTokens.totalCircleColor;
|
|
@@ -243,7 +230,7 @@ var parseTheme = function parseTheme(theme) {
|
|
|
243
230
|
var switchTokens = componentTokensCopy["switch"];
|
|
244
231
|
switchTokens.checkedTrackBackgroundColor = (_theme$switch$checked = theme === null || theme === void 0 ? void 0 : (_theme$switch = theme["switch"]) === null || _theme$switch === void 0 ? void 0 : _theme$switch.checkedBaseColor) !== null && _theme$switch$checked !== void 0 ? _theme$switch$checked : switchTokens.checkedTrackBackgroundColor;
|
|
245
232
|
switchTokens.labelFontColor = (_theme$switch$fontCol = theme === null || theme === void 0 ? void 0 : (_theme$switch2 = theme["switch"]) === null || _theme$switch2 === void 0 ? void 0 : _theme$switch2.fontColor) !== null && _theme$switch$fontCol !== void 0 ? _theme$switch$fontCol : switchTokens.labelFontColor;
|
|
246
|
-
switchTokens.disabledCheckedTrackBackgroundColor = (_addLightness11 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$switch3 = theme["switch"]) === null || _theme$switch3 === void 0 ? void 0 : _theme$switch3.checkedBaseColor
|
|
233
|
+
switchTokens.disabledCheckedTrackBackgroundColor = (_addLightness11 = addLightness(57, theme === null || theme === void 0 ? void 0 : (_theme$switch3 = theme["switch"]) === null || _theme$switch3 === void 0 ? void 0 : _theme$switch3.checkedBaseColor)) !== null && _addLightness11 !== void 0 ? _addLightness11 : switchTokens.disabledCheckedTrackBackgroundColor;
|
|
247
234
|
var tableTokens = componentTokensCopy.table;
|
|
248
235
|
tableTokens.headerBackgroundColor = (_theme$table$baseColo = theme === null || theme === void 0 ? void 0 : (_theme$table = theme.table) === null || _theme$table === void 0 ? void 0 : _theme$table.baseColor) !== null && _theme$table$baseColo !== void 0 ? _theme$table$baseColo : tableTokens.headerBackgroundColor;
|
|
249
236
|
tableTokens.headerFontColor = (_theme$table$headerFo = theme === null || theme === void 0 ? void 0 : (_theme$table2 = theme.table) === null || _theme$table2 === void 0 ? void 0 : _theme$table2.headerFontColor) !== null && _theme$table$headerFo !== void 0 ? _theme$table$headerFo : tableTokens.headerFontColor;
|
|
@@ -254,8 +241,8 @@ var parseTheme = function parseTheme(theme) {
|
|
|
254
241
|
tabsTokens.selectedIconColor = (_theme$tabs$baseColor2 = theme === null || theme === void 0 ? void 0 : (_theme$tabs2 = theme.tabs) === null || _theme$tabs2 === void 0 ? void 0 : _theme$tabs2.baseColor) !== null && _theme$tabs$baseColor2 !== void 0 ? _theme$tabs$baseColor2 : tabsTokens.selectedIconColor;
|
|
255
242
|
tabsTokens.selectedUnderlineColor = (_theme$tabs$baseColor3 = theme === null || theme === void 0 ? void 0 : (_theme$tabs3 = theme.tabs) === null || _theme$tabs3 === void 0 ? void 0 : _theme$tabs3.baseColor) !== null && _theme$tabs$baseColor3 !== void 0 ? _theme$tabs$baseColor3 : tabsTokens.selectedUnderlineColor;
|
|
256
243
|
tabsTokens.focusOutline = (_theme$tabs$baseColor4 = theme === null || theme === void 0 ? void 0 : (_theme$tabs4 = theme.tabs) === null || _theme$tabs4 === void 0 ? void 0 : _theme$tabs4.baseColor) !== null && _theme$tabs$baseColor4 !== void 0 ? _theme$tabs$baseColor4 : tabsTokens.focusOutline;
|
|
257
|
-
tabsTokens.hoverBackgroundColor = (_addLightness12 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$tabs5 = theme.tabs) === null || _theme$tabs5 === void 0 ? void 0 : _theme$tabs5.baseColor
|
|
258
|
-
tabsTokens.pressedBackgroundColor = (_addLightness13 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$tabs6 = theme.tabs) === null || _theme$tabs6 === void 0 ? void 0 : _theme$tabs6.baseColor
|
|
244
|
+
tabsTokens.hoverBackgroundColor = (_addLightness12 = addLightness(57, theme === null || theme === void 0 ? void 0 : (_theme$tabs5 = theme.tabs) === null || _theme$tabs5 === void 0 ? void 0 : _theme$tabs5.baseColor)) !== null && _addLightness12 !== void 0 ? _addLightness12 : tabsTokens.hoverBackgroundColor;
|
|
245
|
+
tabsTokens.pressedBackgroundColor = (_addLightness13 = addLightness(52, theme === null || theme === void 0 ? void 0 : (_theme$tabs6 = theme.tabs) === null || _theme$tabs6 === void 0 ? void 0 : _theme$tabs6.baseColor)) !== null && _addLightness13 !== void 0 ? _addLightness13 : tabsTokens.pressedBackgroundColor;
|
|
259
246
|
var tagTokens = componentTokensCopy.tag;
|
|
260
247
|
tagTokens.fontColor = (_theme$tag$fontColor = theme === null || theme === void 0 ? void 0 : (_theme$tag = theme.tag) === null || _theme$tag === void 0 ? void 0 : _theme$tag.fontColor) !== null && _theme$tag$fontColor !== void 0 ? _theme$tag$fontColor : tagTokens.fontColor;
|
|
261
248
|
tagTokens.iconColor = (_theme$tag$iconColor = theme === null || theme === void 0 ? void 0 : (_theme$tag2 = theme.tag) === null || _theme$tag2 === void 0 ? void 0 : _theme$tag2.iconColor) !== null && _theme$tag$iconColor !== void 0 ? _theme$tag$iconColor : tagTokens.iconColor;
|
|
@@ -268,26 +255,26 @@ var parseTheme = function parseTheme(theme) {
|
|
|
268
255
|
textInputTokens.focusActionIconColor = (_theme$textInput$font6 = theme === null || theme === void 0 ? void 0 : (_theme$textInput6 = theme.textInput) === null || _theme$textInput6 === void 0 ? void 0 : _theme$textInput6.fontColor) !== null && _theme$textInput$font6 !== void 0 ? _theme$textInput$font6 : textInputTokens.focusActionIconColor;
|
|
269
256
|
textInputTokens.activeActionIconColor = (_theme$textInput$font7 = theme === null || theme === void 0 ? void 0 : (_theme$textInput7 = theme.textInput) === null || _theme$textInput7 === void 0 ? void 0 : _theme$textInput7.fontColor) !== null && _theme$textInput$font7 !== void 0 ? _theme$textInput$font7 : textInputTokens.activeActionIconColor;
|
|
270
257
|
textInputTokens.hoverBorderColor = (_theme$textInput$hove = theme === null || theme === void 0 ? void 0 : (_theme$textInput8 = theme.textInput) === null || _theme$textInput8 === void 0 ? void 0 : _theme$textInput8.hoverBorderColor) !== null && _theme$textInput$hove !== void 0 ? _theme$textInput$hove : textInputTokens.hoverBorderColor;
|
|
271
|
-
textInputTokens.suffixColor = (_addLightness14 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$textInput9 = theme.textInput) === null || _theme$textInput9 === void 0 ? void 0 : _theme$textInput9.fontColor
|
|
272
|
-
textInputTokens.prefixColor = (_addLightness15 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$textInput10 = theme.textInput) === null || _theme$textInput10 === void 0 ? void 0 : _theme$textInput10.fontColor
|
|
273
|
-
textInputTokens.placeholderFontColor = (_addLightness16 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$textInput11 = theme.textInput) === null || _theme$textInput11 === void 0 ? void 0 : _theme$textInput11.fontColor
|
|
258
|
+
textInputTokens.suffixColor = (_addLightness14 = addLightness(40, theme === null || theme === void 0 ? void 0 : (_theme$textInput9 = theme.textInput) === null || _theme$textInput9 === void 0 ? void 0 : _theme$textInput9.fontColor)) !== null && _addLightness14 !== void 0 ? _addLightness14 : textInputTokens.suffixColor;
|
|
259
|
+
textInputTokens.prefixColor = (_addLightness15 = addLightness(40, theme === null || theme === void 0 ? void 0 : (_theme$textInput10 = theme.textInput) === null || _theme$textInput10 === void 0 ? void 0 : _theme$textInput10.fontColor)) !== null && _addLightness15 !== void 0 ? _addLightness15 : textInputTokens.prefixColor;
|
|
260
|
+
textInputTokens.placeholderFontColor = (_addLightness16 = addLightness(30, theme === null || theme === void 0 ? void 0 : (_theme$textInput11 = theme.textInput) === null || _theme$textInput11 === void 0 ? void 0 : _theme$textInput11.fontColor)) !== null && _addLightness16 !== void 0 ? _addLightness16 : textInputTokens.placeholderFontColor;
|
|
274
261
|
var textareaTokens = componentTokensCopy.textarea;
|
|
275
262
|
textareaTokens.labelFontColor = (_theme$textarea$fontC = theme === null || theme === void 0 ? void 0 : (_theme$textarea = theme.textarea) === null || _theme$textarea === void 0 ? void 0 : _theme$textarea.fontColor) !== null && _theme$textarea$fontC !== void 0 ? _theme$textarea$fontC : textareaTokens.labelFontColor;
|
|
276
263
|
textareaTokens.helperTextFontColor = (_theme$textarea$fontC2 = theme === null || theme === void 0 ? void 0 : (_theme$textarea2 = theme.textarea) === null || _theme$textarea2 === void 0 ? void 0 : _theme$textarea2.fontColor) !== null && _theme$textarea$fontC2 !== void 0 ? _theme$textarea$fontC2 : textareaTokens.helperTextFontColor;
|
|
277
264
|
textareaTokens.valueFontColor = (_theme$textarea$fontC3 = theme === null || theme === void 0 ? void 0 : (_theme$textarea3 = theme.textarea) === null || _theme$textarea3 === void 0 ? void 0 : _theme$textarea3.fontColor) !== null && _theme$textarea$fontC3 !== void 0 ? _theme$textarea$fontC3 : textareaTokens.valueFontColor;
|
|
278
265
|
textareaTokens.hoverBorderColor = (_theme$textarea$hover = theme === null || theme === void 0 ? void 0 : (_theme$textarea4 = theme.textarea) === null || _theme$textarea4 === void 0 ? void 0 : _theme$textarea4.hoverBorderColor) !== null && _theme$textarea$hover !== void 0 ? _theme$textarea$hover : textareaTokens.hoverBorderColor;
|
|
279
|
-
textareaTokens.placeholderFontColor = (_addLightness17 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$textarea5 = theme.textarea) === null || _theme$textarea5 === void 0 ? void 0 : _theme$textarea5.fontColor
|
|
266
|
+
textareaTokens.placeholderFontColor = (_addLightness17 = addLightness(30, theme === null || theme === void 0 ? void 0 : (_theme$textarea5 = theme.textarea) === null || _theme$textarea5 === void 0 ? void 0 : _theme$textarea5.fontColor)) !== null && _addLightness17 !== void 0 ? _addLightness17 : textareaTokens.placeholderFontColor;
|
|
280
267
|
var toggleGroupTokens = componentTokensCopy.toggleGroup;
|
|
281
|
-
toggleGroupTokens.selectedBackgroundColor = (_theme$toggleGroup$se = theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup = theme.toggleGroup) === null || _theme$toggleGroup === void 0 ? void 0 : _theme$toggleGroup.selectedBaseColor) !== null && _theme$toggleGroup$se !== void 0 ? _theme$toggleGroup$se :
|
|
268
|
+
toggleGroupTokens.selectedBackgroundColor = (_theme$toggleGroup$se = theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup = theme.toggleGroup) === null || _theme$toggleGroup === void 0 ? void 0 : _theme$toggleGroup.selectedBaseColor) !== null && _theme$toggleGroup$se !== void 0 ? _theme$toggleGroup$se : toggleGroupTokens.selectedBackgroundColor;
|
|
282
269
|
toggleGroupTokens.selectedFontColor = (_theme$toggleGroup$se2 = theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup2 = theme.toggleGroup) === null || _theme$toggleGroup2 === void 0 ? void 0 : _theme$toggleGroup2.selectedFontColor) !== null && _theme$toggleGroup$se2 !== void 0 ? _theme$toggleGroup$se2 : toggleGroupTokens.selectedFontColor;
|
|
283
270
|
toggleGroupTokens.unselectedBackgroundColor = (_theme$toggleGroup$un = theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup3 = theme.toggleGroup) === null || _theme$toggleGroup3 === void 0 ? void 0 : _theme$toggleGroup3.unselectedBaseColor) !== null && _theme$toggleGroup$un !== void 0 ? _theme$toggleGroup$un : toggleGroupTokens.unselectedBackgroundColor;
|
|
284
271
|
toggleGroupTokens.unselectedActiveBackgroundColor = (_theme$toggleGroup$se3 = theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup4 = theme.toggleGroup) === null || _theme$toggleGroup4 === void 0 ? void 0 : _theme$toggleGroup4.selectedBaseColor) !== null && _theme$toggleGroup$se3 !== void 0 ? _theme$toggleGroup$se3 : toggleGroupTokens.unselectedActiveBackgroundColor;
|
|
285
272
|
toggleGroupTokens.unselectedFontColor = (_theme$toggleGroup$un2 = theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup5 = theme.toggleGroup) === null || _theme$toggleGroup5 === void 0 ? void 0 : _theme$toggleGroup5.unselectedFontColor) !== null && _theme$toggleGroup$un2 !== void 0 ? _theme$toggleGroup$un2 : toggleGroupTokens.unselectedFontColor;
|
|
286
|
-
toggleGroupTokens.selectedHoverBackgroundColor = (_subLightness20 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup6 = theme.toggleGroup) === null || _theme$toggleGroup6 === void 0 ? void 0 : _theme$toggleGroup6.selectedBaseColor
|
|
287
|
-
toggleGroupTokens.selectedActiveBackgroundColor = (_subLightness21 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup7 = theme.toggleGroup) === null || _theme$toggleGroup7 === void 0 ? void 0 : _theme$toggleGroup7.selectedBaseColor
|
|
288
|
-
toggleGroupTokens.selectedDisabledBackgroundColor = (_addLightness18 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup8 = theme.toggleGroup) === null || _theme$toggleGroup8 === void 0 ? void 0 : _theme$toggleGroup8.selectedBaseColor
|
|
289
|
-
toggleGroupTokens.selectedDisabledFontColor = (_addLightness19 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup9 = theme.toggleGroup) === null || _theme$toggleGroup9 === void 0 ? void 0 : _theme$toggleGroup9.selectedBaseColor
|
|
290
|
-
toggleGroupTokens.unselectedHoverBackgroundColor = (_subLightness22 = subLightness(theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup10 = theme.toggleGroup) === null || _theme$toggleGroup10 === void 0 ? void 0 : _theme$toggleGroup10.unselectedBaseColor
|
|
273
|
+
toggleGroupTokens.selectedHoverBackgroundColor = (_subLightness20 = subLightness(8, theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup6 = theme.toggleGroup) === null || _theme$toggleGroup6 === void 0 ? void 0 : _theme$toggleGroup6.selectedBaseColor)) !== null && _subLightness20 !== void 0 ? _subLightness20 : toggleGroupTokens.selectedHoverBackgroundColor;
|
|
274
|
+
toggleGroupTokens.selectedActiveBackgroundColor = (_subLightness21 = subLightness(18, theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup7 = theme.toggleGroup) === null || _theme$toggleGroup7 === void 0 ? void 0 : _theme$toggleGroup7.selectedBaseColor)) !== null && _subLightness21 !== void 0 ? _subLightness21 : toggleGroupTokens.selectedActiveBackgroundColor;
|
|
275
|
+
toggleGroupTokens.selectedDisabledBackgroundColor = (_addLightness18 = addLightness(57, theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup8 = theme.toggleGroup) === null || _theme$toggleGroup8 === void 0 ? void 0 : _theme$toggleGroup8.selectedBaseColor)) !== null && _addLightness18 !== void 0 ? _addLightness18 : toggleGroupTokens.selectedDisabledBackgroundColor;
|
|
276
|
+
toggleGroupTokens.selectedDisabledFontColor = (_addLightness19 = addLightness(42, theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup9 = theme.toggleGroup) === null || _theme$toggleGroup9 === void 0 ? void 0 : _theme$toggleGroup9.selectedBaseColor)) !== null && _addLightness19 !== void 0 ? _addLightness19 : toggleGroupTokens.selectedDisabledFontColor;
|
|
277
|
+
toggleGroupTokens.unselectedHoverBackgroundColor = (_subLightness22 = subLightness(10, theme === null || theme === void 0 ? void 0 : (_theme$toggleGroup10 = theme.toggleGroup) === null || _theme$toggleGroup10 === void 0 ? void 0 : _theme$toggleGroup10.unselectedBaseColor)) !== null && _subLightness22 !== void 0 ? _subLightness22 : toggleGroupTokens.unselectedHoverBackgroundColor;
|
|
291
278
|
var wizardTokens = componentTokensCopy.wizard;
|
|
292
279
|
wizardTokens.selectedStepBackgroundColor = (_theme$wizard$baseCol = theme === null || theme === void 0 ? void 0 : (_theme$wizard = theme.wizard) === null || _theme$wizard === void 0 ? void 0 : _theme$wizard.baseColor) !== null && _theme$wizard$baseCol !== void 0 ? _theme$wizard$baseCol : wizardTokens.selectedStepBackgroundColor;
|
|
293
280
|
wizardTokens.selectedStepFontColor = (_theme$wizard$selecte = theme === null || theme === void 0 ? void 0 : (_theme$wizard2 = theme.wizard) === null || _theme$wizard2 === void 0 ? void 0 : _theme$wizard2.selectedStepFontColor) !== null && _theme$wizard$selecte !== void 0 ? _theme$wizard$selecte : wizardTokens.selectedStepFontColor;
|
|
@@ -296,10 +283,10 @@ var parseTheme = function parseTheme(theme) {
|
|
|
296
283
|
wizardTokens.selectedLabelFontColor = (_theme$wizard$fontCol2 = theme === null || theme === void 0 ? void 0 : (_theme$wizard5 = theme.wizard) === null || _theme$wizard5 === void 0 ? void 0 : _theme$wizard5.fontColor) !== null && _theme$wizard$fontCol2 !== void 0 ? _theme$wizard$fontCol2 : wizardTokens.selectedLabelFontColor;
|
|
297
284
|
wizardTokens.visitedHelperTextFontColor = (_theme$wizard$fontCol3 = theme === null || theme === void 0 ? void 0 : (_theme$wizard6 = theme.wizard) === null || _theme$wizard6 === void 0 ? void 0 : _theme$wizard6.fontColor) !== null && _theme$wizard$fontCol3 !== void 0 ? _theme$wizard$fontCol3 : wizardTokens.visitedHelperTextFontColor;
|
|
298
285
|
wizardTokens.selectedHelperTextFontColor = (_theme$wizard$fontCol4 = theme === null || theme === void 0 ? void 0 : (_theme$wizard7 = theme.wizard) === null || _theme$wizard7 === void 0 ? void 0 : _theme$wizard7.fontColor) !== null && _theme$wizard$fontCol4 !== void 0 ? _theme$wizard$fontCol4 : wizardTokens.selectedHelperTextFontColor;
|
|
299
|
-
wizardTokens.unvisitedStepBorderColor = (_addLightness20 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$wizard8 = theme.wizard) === null || _theme$wizard8 === void 0 ? void 0 : _theme$wizard8.fontColor
|
|
300
|
-
wizardTokens.unvisitedStepFontColor = (_addLightness21 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$wizard9 = theme.wizard) === null || _theme$wizard9 === void 0 ? void 0 : _theme$wizard9.fontColor
|
|
301
|
-
wizardTokens.unvisitedLabelFontColor = (_addLightness22 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$wizard10 = theme.wizard) === null || _theme$wizard10 === void 0 ? void 0 : _theme$wizard10.fontColor
|
|
302
|
-
wizardTokens.unvisitedHelperTextFontColor = (_addLightness23 = addLightness(theme === null || theme === void 0 ? void 0 : (_theme$wizard11 = theme.wizard) === null || _theme$wizard11 === void 0 ? void 0 : _theme$wizard11.fontColor
|
|
286
|
+
wizardTokens.unvisitedStepBorderColor = (_addLightness20 = addLightness(40, theme === null || theme === void 0 ? void 0 : (_theme$wizard8 = theme.wizard) === null || _theme$wizard8 === void 0 ? void 0 : _theme$wizard8.fontColor)) !== null && _addLightness20 !== void 0 ? _addLightness20 : wizardTokens.unvisitedStepBorderColor;
|
|
287
|
+
wizardTokens.unvisitedStepFontColor = (_addLightness21 = addLightness(40, theme === null || theme === void 0 ? void 0 : (_theme$wizard9 = theme.wizard) === null || _theme$wizard9 === void 0 ? void 0 : _theme$wizard9.fontColor)) !== null && _addLightness21 !== void 0 ? _addLightness21 : wizardTokens.unvisitedStepFontColor;
|
|
288
|
+
wizardTokens.unvisitedLabelFontColor = (_addLightness22 = addLightness(40, theme === null || theme === void 0 ? void 0 : (_theme$wizard10 = theme.wizard) === null || _theme$wizard10 === void 0 ? void 0 : _theme$wizard10.fontColor)) !== null && _addLightness22 !== void 0 ? _addLightness22 : wizardTokens.unvisitedLabelFontColor;
|
|
289
|
+
wizardTokens.unvisitedHelperTextFontColor = (_addLightness23 = addLightness(40, theme === null || theme === void 0 ? void 0 : (_theme$wizard11 = theme.wizard) === null || _theme$wizard11 === void 0 ? void 0 : _theme$wizard11.fontColor)) !== null && _addLightness23 !== void 0 ? _addLightness23 : wizardTokens.unvisitedHelperTextFontColor;
|
|
303
290
|
return componentTokensCopy;
|
|
304
291
|
};
|
|
305
292
|
|
|
@@ -316,6 +303,11 @@ var parseLabels = function parseLabels(labels) {
|
|
|
316
303
|
});
|
|
317
304
|
return parsedLabels;
|
|
318
305
|
};
|
|
306
|
+
/**
|
|
307
|
+
* This type is used to allow partial themes and labels objects to be passed to the HalstackProvider.
|
|
308
|
+
* This is an extension of the already extisting Partial type, which only allows one level of partiality.
|
|
309
|
+
*/
|
|
310
|
+
|
|
319
311
|
|
|
320
312
|
var HalstackProvider = function HalstackProvider(_ref) {
|
|
321
313
|
var theme = _ref.theme,
|
|
@@ -323,10 +315,10 @@ var HalstackProvider = function HalstackProvider(_ref) {
|
|
|
323
315
|
labels = _ref.labels,
|
|
324
316
|
children = _ref.children;
|
|
325
317
|
var parsedTheme = (0, _react.useMemo)(function () {
|
|
326
|
-
return theme
|
|
318
|
+
return theme ? parseTheme(theme) : advancedTheme ? parseAdvancedTheme(advancedTheme) : _variables.componentTokens;
|
|
327
319
|
}, [theme, advancedTheme]);
|
|
328
320
|
var parsedLabels = (0, _react.useMemo)(function () {
|
|
329
|
-
return labels
|
|
321
|
+
return labels ? parseLabels(labels) : _variables.defaultTranslatedComponentLabels;
|
|
330
322
|
}, [labels]);
|
|
331
323
|
return /*#__PURE__*/_react["default"].createElement(Halstack, null, /*#__PURE__*/_react["default"].createElement(HalstackContext.Provider, {
|
|
332
324
|
value: parsedTheme
|
package/accordion/Accordion.js
CHANGED
|
@@ -19,15 +19,15 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
19
19
|
|
|
20
20
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
21
21
|
|
|
22
|
-
var _utils = require("../common/utils
|
|
22
|
+
var _utils = require("../common/utils");
|
|
23
23
|
|
|
24
|
-
var _variables = require("../common/variables
|
|
24
|
+
var _variables = require("../common/variables");
|
|
25
25
|
|
|
26
26
|
var _useTheme = _interopRequireDefault(require("../useTheme"));
|
|
27
27
|
|
|
28
28
|
var _BackgroundColorContext = require("../BackgroundColorContext");
|
|
29
29
|
|
|
30
|
-
var
|
|
30
|
+
var _BaseTypography = _interopRequireDefault(require("../utils/BaseTypography"));
|
|
31
31
|
|
|
32
32
|
var _uuid = require("uuid");
|
|
33
33
|
|
|
@@ -96,7 +96,6 @@ var DxcAccordion = function DxcAccordion(_ref) {
|
|
|
96
96
|
theme: colorsTheme.accordion
|
|
97
97
|
}, /*#__PURE__*/_react["default"].createElement(AccordionContainer, {
|
|
98
98
|
isExpanded: isExpanded !== null && isExpanded !== void 0 ? isExpanded : innerIsExpanded,
|
|
99
|
-
padding: padding,
|
|
100
99
|
margin: margin
|
|
101
100
|
}, /*#__PURE__*/_react["default"].createElement(AccordionHeader, null, /*#__PURE__*/_react["default"].createElement(AccordionTrigger, {
|
|
102
101
|
id: "accordion-".concat(id),
|
|
@@ -106,22 +105,18 @@ var DxcAccordion = function DxcAccordion(_ref) {
|
|
|
106
105
|
"aria-expanded": isExpanded !== null && isExpanded !== void 0 ? isExpanded : innerIsExpanded,
|
|
107
106
|
"aria-controls": "accordion-panel-".concat(id),
|
|
108
107
|
isExpanded: isExpanded !== null && isExpanded !== void 0 ? isExpanded : innerIsExpanded
|
|
109
|
-
}, /*#__PURE__*/_react["default"].createElement(AccordionInfo, {
|
|
110
|
-
disabled: disabled
|
|
111
|
-
}, /*#__PURE__*/_react["default"].createElement(AccordionLabel, null, icon && /*#__PURE__*/_react["default"].createElement(IconContainer, {
|
|
108
|
+
}, /*#__PURE__*/_react["default"].createElement(AccordionInfo, null, /*#__PURE__*/_react["default"].createElement(AccordionLabel, null, icon && /*#__PURE__*/_react["default"].createElement(IconContainer, {
|
|
112
109
|
disabled: disabled
|
|
113
110
|
}, typeof icon === "string" ? /*#__PURE__*/_react["default"].createElement("img", {
|
|
114
111
|
src: icon
|
|
115
|
-
}) : icon), /*#__PURE__*/_react["default"].createElement(
|
|
112
|
+
}) : icon), /*#__PURE__*/_react["default"].createElement(_BaseTypography["default"], {
|
|
116
113
|
color: disabled ? colorsTheme.accordion.disabledTitleLabelFontColor : colorsTheme.accordion.titleLabelFontColor,
|
|
117
114
|
fontFamily: colorsTheme.accordion.titleLabelFontFamily,
|
|
118
115
|
fontSize: colorsTheme.accordion.titleLabelFontSize,
|
|
119
116
|
fontStyle: colorsTheme.accordion.titleLabelFontStyle,
|
|
120
117
|
fontWeight: colorsTheme.accordion.titleLabelFontWeight,
|
|
121
118
|
lineHeight: "1.5em"
|
|
122
|
-
}, label)), assistiveText && /*#__PURE__*/_react["default"].createElement(AccordionAssistiveText, {
|
|
123
|
-
disabled: disabled
|
|
124
|
-
}, /*#__PURE__*/_react["default"].createElement(_Typography["default"], {
|
|
119
|
+
}, label)), assistiveText && /*#__PURE__*/_react["default"].createElement(AccordionAssistiveText, null, /*#__PURE__*/_react["default"].createElement(_BaseTypography["default"], {
|
|
125
120
|
color: disabled ? colorsTheme.accordion.disabledAssistiveTextFontColor : colorsTheme.accordion.assistiveTextFontColor,
|
|
126
121
|
fontFamily: colorsTheme.accordion.assistiveTextFontFamily,
|
|
127
122
|
fontSize: colorsTheme.accordion.assistiveTextFontSize,
|
|
@@ -131,7 +131,7 @@ export const Chromatic = () => (
|
|
|
131
131
|
<DxcAccordion
|
|
132
132
|
label="Accordion"
|
|
133
133
|
assistiveText="Assistive text"
|
|
134
|
-
icon="https://
|
|
134
|
+
icon="https://www.freepnglogos.com/uploads/facebook-logo-design-1.png"
|
|
135
135
|
>
|
|
136
136
|
<div>
|
|
137
137
|
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse malesuada lacus ex, sit amet blandit leo
|
|
@@ -6,7 +6,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
6
6
|
|
|
7
7
|
var _react2 = require("@testing-library/react");
|
|
8
8
|
|
|
9
|
-
var _Accordion = _interopRequireDefault(require("./Accordion"));
|
|
9
|
+
var _Accordion = _interopRequireDefault(require("./Accordion.tsx"));
|
|
10
10
|
|
|
11
11
|
describe("Accordion component tests", function () {
|
|
12
12
|
test("Renders with correct aria accessibility attributes", function () {
|
package/accordion/types.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
declare type Space = "xxsmall" | "xsmall" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
|
|
3
|
+
declare type Margin = {
|
|
4
4
|
top?: Space;
|
|
5
5
|
bottom?: Space;
|
|
6
6
|
left?: Space;
|
|
7
7
|
right?: Space;
|
|
8
8
|
};
|
|
9
|
-
|
|
9
|
+
declare type Padding = {
|
|
10
10
|
top?: Space;
|
|
11
11
|
bottom?: Space;
|
|
12
12
|
left?: Space;
|
|
@@ -25,9 +25,9 @@ var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
|
25
25
|
|
|
26
26
|
var _Accordion = _interopRequireDefault(require("../accordion/Accordion"));
|
|
27
27
|
|
|
28
|
-
var _utils = require("../common/utils
|
|
28
|
+
var _utils = require("../common/utils");
|
|
29
29
|
|
|
30
|
-
var _variables = require("../common/variables
|
|
30
|
+
var _variables = require("../common/variables");
|
|
31
31
|
|
|
32
32
|
var _useTheme = _interopRequireDefault(require("../useTheme"));
|
|
33
33
|
|
|
@@ -6,7 +6,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
6
6
|
|
|
7
7
|
var _react2 = require("@testing-library/react");
|
|
8
8
|
|
|
9
|
-
var _AccordionGroup = _interopRequireDefault(require("./AccordionGroup"));
|
|
9
|
+
var _AccordionGroup = _interopRequireDefault(require("./AccordionGroup.tsx"));
|
|
10
10
|
|
|
11
11
|
describe("Accordion component tests", function () {
|
|
12
12
|
test("Uncontrolled accordion group calls correct function on click", function () {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
declare type Space = "xxsmall" | "xsmall" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
|
|
3
|
+
declare type Margin = {
|
|
4
4
|
top?: Space;
|
|
5
5
|
bottom?: Space;
|
|
6
6
|
left?: Space;
|
package/alert/Alert.js
CHANGED
|
@@ -17,9 +17,9 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
17
17
|
|
|
18
18
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
19
19
|
|
|
20
|
-
var _variables = require("../common/variables
|
|
20
|
+
var _variables = require("../common/variables");
|
|
21
21
|
|
|
22
|
-
var _utils = require("../common/utils
|
|
22
|
+
var _utils = require("../common/utils");
|
|
23
23
|
|
|
24
24
|
var _useTheme = _interopRequireDefault(require("../useTheme"));
|
|
25
25
|
|
|
@@ -131,9 +131,7 @@ var DxcAlert = function DxcAlert(_ref) {
|
|
|
131
131
|
size: size
|
|
132
132
|
}, /*#__PURE__*/_react["default"].createElement(AlertInfo, null, /*#__PURE__*/_react["default"].createElement(AlertIcon, {
|
|
133
133
|
type: type
|
|
134
|
-
}, type === "info" && alertIcons.info || type === "confirm" && alertIcons.success || type === "warning" && alertIcons.warning || type === "error" && alertIcons.error), /*#__PURE__*/_react["default"].createElement(AlertText, null, /*#__PURE__*/_react["default"].createElement(AlertTitle, {
|
|
135
|
-
type: type
|
|
136
|
-
}, getTypeText()), inlineText && inlineText !== "" && "-", /*#__PURE__*/_react["default"].createElement(AlertInlineText, null, inlineText)), onClose && /*#__PURE__*/_react["default"].createElement(AlertCloseAction, {
|
|
134
|
+
}, type === "info" && alertIcons.info || type === "confirm" && alertIcons.success || type === "warning" && alertIcons.warning || type === "error" && alertIcons.error), /*#__PURE__*/_react["default"].createElement(AlertText, null, /*#__PURE__*/_react["default"].createElement(AlertTitle, null, getTypeText()), inlineText && inlineText !== "" && "-", /*#__PURE__*/_react["default"].createElement(AlertInlineText, null, inlineText)), onClose && /*#__PURE__*/_react["default"].createElement(AlertCloseAction, {
|
|
137
135
|
onClick: onClose,
|
|
138
136
|
tabIndex: tabIndex
|
|
139
137
|
}, alertIcons.close)), children && /*#__PURE__*/_react["default"].createElement(AlertContent, null, /*#__PURE__*/_react["default"].createElement(_BackgroundColorContext.BackgroundColorProvider, {
|
package/alert/Alert.test.js
CHANGED
|
@@ -6,7 +6,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
6
6
|
|
|
7
7
|
var _react2 = require("@testing-library/react");
|
|
8
8
|
|
|
9
|
-
var _Alert = _interopRequireDefault(require("./Alert"));
|
|
9
|
+
var _Alert = _interopRequireDefault(require("./Alert.tsx"));
|
|
10
10
|
|
|
11
11
|
describe("Alert component tests", function () {
|
|
12
12
|
test("Info alert renders with correct text", function () {
|
package/bleed/Bleed.stories.tsx
CHANGED
package/box/Box.js
CHANGED
|
@@ -17,9 +17,9 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
17
17
|
|
|
18
18
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
19
19
|
|
|
20
|
-
var _variables = require("../common/variables
|
|
20
|
+
var _variables = require("../common/variables");
|
|
21
21
|
|
|
22
|
-
var _utils = require("../common/utils
|
|
22
|
+
var _utils = require("../common/utils");
|
|
23
23
|
|
|
24
24
|
var _useTheme = _interopRequireDefault(require("../useTheme"));
|
|
25
25
|
|
package/box/Box.test.js
CHANGED
|
@@ -6,7 +6,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
6
6
|
|
|
7
7
|
var _react2 = require("@testing-library/react");
|
|
8
8
|
|
|
9
|
-
var _Card = _interopRequireDefault(require("../card/Card"));
|
|
9
|
+
var _Card = _interopRequireDefault(require("../card/Card.tsx"));
|
|
10
10
|
|
|
11
11
|
describe("Box component tests", function () {
|
|
12
12
|
test("Box renders with correct text", function () {
|
package/button/Button.js
CHANGED
|
@@ -17,9 +17,9 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
17
17
|
|
|
18
18
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
19
19
|
|
|
20
|
-
var _variables = require("../common/variables
|
|
20
|
+
var _variables = require("../common/variables");
|
|
21
21
|
|
|
22
|
-
var _utils = require("../common/utils
|
|
22
|
+
var _utils = require("../common/utils");
|
|
23
23
|
|
|
24
24
|
var _useTheme = _interopRequireDefault(require("../useTheme"));
|
|
25
25
|
|
|
@@ -75,7 +75,6 @@ var DxcButton = function DxcButton(_ref) {
|
|
|
75
75
|
type: type,
|
|
76
76
|
mode: mode !== "primary" && mode !== "secondary" && mode !== "text" ? "primary" : mode,
|
|
77
77
|
disabled: disabled,
|
|
78
|
-
"aria-disabled": disabled,
|
|
79
78
|
tabIndex: disabled ? -1 : tabIndex,
|
|
80
79
|
backgroundType: backgroundType,
|
|
81
80
|
size: size,
|
|
@@ -98,7 +98,7 @@ export const Chromatic = () => (
|
|
|
98
98
|
</ExampleContainer>
|
|
99
99
|
<ExampleContainer>
|
|
100
100
|
<Title title="Big icon (image)" theme="light" level={4} />
|
|
101
|
-
<DxcButton icon="https://
|
|
101
|
+
<DxcButton icon="https://www.freepnglogos.com/uploads/facebook-logo-design-1.png" />
|
|
102
102
|
</ExampleContainer>
|
|
103
103
|
<ExampleContainer>
|
|
104
104
|
<Title title="Small icon" theme="light" level={4} />
|
package/button/Button.test.js
CHANGED
|
@@ -6,7 +6,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
6
6
|
|
|
7
7
|
var _react2 = require("@testing-library/react");
|
|
8
8
|
|
|
9
|
-
var _Button = _interopRequireDefault(require("./Button"));
|
|
9
|
+
var _Button = _interopRequireDefault(require("./Button.tsx"));
|
|
10
10
|
|
|
11
11
|
describe("Button component tests", function () {
|
|
12
12
|
test("Button renders with correct text", function () {
|