@widergy/energy-ui 1.136.0 → 1.136.2
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/components/EnergyThemeProvider/index.js +13 -36
- package/dist/components/Loading/constants.js +1 -2
- package/dist/components/Loading/index.js +13 -12
- package/dist/components/Loading/theme.js +9 -11
- package/dist/components/UTAlert/AlertHandler.js +75 -101
- package/dist/components/UTAlert/index.js +65 -87
- package/dist/components/UTAlert/theme.js +29 -31
- package/dist/components/UTAttachment/components/Preview/index.js +8 -9
- package/dist/components/UTAttachment/constants.js +7 -13
- package/dist/components/UTAttachment/index.js +153 -232
- package/dist/components/UTAttachment/layout.js +25 -26
- package/dist/components/UTAttachment/theme.js +12 -14
- package/dist/components/UTAttachment/utils.js +34 -117
- package/dist/components/UTAutocomplete/components/ListBox/index.js +13 -21
- package/dist/components/UTAutocomplete/components/ListBox/utils.js +9 -11
- package/dist/components/UTAutocomplete/constants.js +12 -23
- package/dist/components/UTAutocomplete/index.js +45 -66
- package/dist/components/UTAutocomplete/theme.js +3 -3
- package/dist/components/UTAvatar/constants.js +2 -3
- package/dist/components/UTAvatar/index.js +15 -12
- package/dist/components/UTBarChart/components/Bars/components/Bar/components/Rect/index.js +22 -22
- package/dist/components/UTBarChart/components/Bars/components/Bar/constants.js +1 -1
- package/dist/components/UTBarChart/components/Bars/components/Bar/index.js +21 -22
- package/dist/components/UTBarChart/components/Bars/constants.js +3 -6
- package/dist/components/UTBarChart/components/Bars/index.js +70 -80
- package/dist/components/UTBarChart/components/Legend/constants.js +12 -18
- package/dist/components/UTBarChart/components/Legend/index.js +73 -91
- package/dist/components/UTBarChart/components/Legend/utils.js +1 -5
- package/dist/components/UTBarChart/components/Levels/index.js +16 -14
- package/dist/components/UTBarChart/components/Levels/utils.js +25 -27
- package/dist/components/UTBarChart/components/LinearPlot/constants.js +3 -5
- package/dist/components/UTBarChart/components/LinearPlot/index.js +25 -20
- package/dist/components/UTBarChart/components/LinearPlot/utils.js +37 -39
- package/dist/components/UTBarChart/components/Pagination/constants.js +1 -2
- package/dist/components/UTBarChart/components/Pagination/index.js +20 -24
- package/dist/components/UTBarChart/components/XAxis/components/AxisElement/index.js +21 -32
- package/dist/components/UTBarChart/components/XAxis/components/Decoration/constants.js +2 -4
- package/dist/components/UTBarChart/components/XAxis/components/Decoration/index.js +20 -19
- package/dist/components/UTBarChart/components/XAxis/constants.js +1 -2
- package/dist/components/UTBarChart/components/XAxis/index.js +54 -65
- package/dist/components/UTBarChart/components/YAxis/AxisElement/index.js +12 -11
- package/dist/components/UTBarChart/components/YAxis/constants.js +1 -2
- package/dist/components/UTBarChart/components/YAxis/index.js +24 -31
- package/dist/components/UTBarChart/components/YAxis/utils.js +4 -6
- package/dist/components/UTBarChart/constants.js +4 -8
- package/dist/components/UTBarChart/hooks/use-dynamic-margins.js +23 -40
- package/dist/components/UTBarChart/index.js +148 -162
- package/dist/components/UTBarChart/theme.js +102 -104
- package/dist/components/UTBarChart/types.js +9 -17
- package/dist/components/UTBarChart/utils.js +107 -111
- package/dist/components/UTBreadcrumbs/constants.js +3 -6
- package/dist/components/UTBreadcrumbs/index.js +79 -106
- package/dist/components/UTBreadcrumbs/theme.js +21 -23
- package/dist/components/UTButton/index.js +48 -71
- package/dist/components/UTButton/theme.js +172 -174
- package/dist/components/UTCBUInput/index.js +36 -40
- package/dist/components/UTCBUInput/theme.js +5 -7
- package/dist/components/UTCaptcha/index.js +19 -45
- package/dist/components/UTCard/components/UTCardFooter/index.js +16 -17
- package/dist/components/UTCard/index.js +87 -122
- package/dist/components/UTCard/theme.js +8 -11
- package/dist/components/UTCard/types.js +2 -3
- package/dist/components/UTCarousel/components/Button/index.js +13 -13
- package/dist/components/UTCarousel/components/Legend/index.js +14 -16
- package/dist/components/UTCarousel/components/Slider/component/Slide/index.js +16 -16
- package/dist/components/UTCarousel/components/Slider/constants.js +5 -10
- package/dist/components/UTCarousel/components/Slider/index.js +181 -252
- package/dist/components/UTCarousel/components/Slider/layout.js +66 -93
- package/dist/components/UTCarousel/index.js +14 -15
- package/dist/components/UTCarousel/theme.js +35 -37
- package/dist/components/UTCheckList/constants.js +1 -2
- package/dist/components/UTCheckList/index.js +72 -91
- package/dist/components/UTCheckList/theme.js +66 -70
- package/dist/components/UTCheckbox/constants.js +3 -6
- package/dist/components/UTCheckbox/index.js +31 -42
- package/dist/components/UTCheckbox/theme.js +49 -53
- package/dist/components/UTConsumptionBar/components/ConsumptionBarIndicator/index.js +9 -9
- package/dist/components/UTConsumptionBar/constants.js +3 -6
- package/dist/components/UTConsumptionBar/index.js +49 -74
- package/dist/components/UTCuit/index.js +109 -133
- package/dist/components/UTCuit/theme.js +47 -49
- package/dist/components/UTDatePicker/components/Day/constants.js +1 -2
- package/dist/components/UTDatePicker/components/Day/index.js +12 -12
- package/dist/components/UTDatePicker/constants.js +20 -31
- package/dist/components/UTDatePicker/index.js +59 -101
- package/dist/components/UTDatePicker/theme.js +173 -177
- package/dist/components/UTDatePicker/types.js +2 -3
- package/dist/components/UTDatePicker/utils.js +2 -6
- package/dist/components/UTDialog/components/ActionButton/index.js +10 -9
- package/dist/components/UTDialog/constants.js +2 -4
- package/dist/components/UTDialog/index.js +39 -38
- package/dist/components/UTDialog/theme.js +93 -95
- package/dist/components/UTDialog/types.js +2 -3
- package/dist/components/UTDotMenu/index.js +33 -57
- package/dist/components/UTEmojiPicker/constants.js +6 -11
- package/dist/components/UTEmojiPicker/index.js +45 -65
- package/dist/components/UTEmojiPicker/theme.js +1 -1
- package/dist/components/UTEmojiPicker/utils.js +21 -51
- package/dist/components/UTExternalLink/index.js +17 -14
- package/dist/components/UTFileInput/constants.js +2 -4
- package/dist/components/UTFileInput/index.js +7 -31
- package/dist/components/UTFileInput/layout.js +67 -96
- package/dist/components/UTIconButton/index.js +49 -72
- package/dist/components/UTIconButton/theme.js +53 -55
- package/dist/components/UTImageRadio/components/ImageRadioCard/index.js +53 -58
- package/dist/components/UTImageRadio/constants.js +3 -6
- package/dist/components/UTImageRadio/index.js +39 -47
- package/dist/components/UTImageRadio/theme.js +8 -11
- package/dist/components/UTImageRadio/types.js +2 -3
- package/dist/components/UTImageRadio/utils.js +2 -6
- package/dist/components/UTLabel/index.js +69 -90
- package/dist/components/UTLabel/theme.js +84 -86
- package/dist/components/UTList/index.js +15 -18
- package/dist/components/UTLoading/index.js +15 -15
- package/dist/components/UTMap/components/GoogleMaps/constants.js +8 -11
- package/dist/components/UTMap/components/GoogleMaps/index.js +63 -91
- package/dist/components/UTMap/components/GoogleMaps/styles.js +2 -3
- package/dist/components/UTMap/constants.js +6 -12
- package/dist/components/UTMap/index.js +163 -198
- package/dist/components/UTMap/types.js +4 -6
- package/dist/components/UTMap/utils.js +29 -46
- package/dist/components/UTMap/withGoogleMapScript.js +12 -17
- package/dist/components/UTMenu/index.js +52 -69
- package/dist/components/UTMenu/theme.js +2 -2
- package/dist/components/UTMenu/utils.js +5 -11
- package/dist/components/UTPagination/theme.js +4 -2
- package/dist/components/UTPanel/index.js +38 -44
- package/dist/components/UTPasswordField/components/PasswordValidations/components/Error/index.js +14 -11
- package/dist/components/UTPasswordField/components/PasswordValidations/components/Validation/index.js +24 -21
- package/dist/components/UTPasswordField/components/PasswordValidations/index.js +63 -50
- package/dist/components/UTPasswordField/components/PasswordWarning/index.js +26 -27
- package/dist/components/UTPasswordField/index.js +26 -23
- package/dist/components/UTPasswordField/theme.js +37 -39
- package/dist/components/UTPhoneInput/constants.js +3 -6
- package/dist/components/UTPhoneInput/index.js +180 -205
- package/dist/components/UTPhoneInput/theme.js +109 -113
- package/dist/components/UTPieChart/components/ArrowLabel/constants.js +4 -8
- package/dist/components/UTPieChart/components/ArrowLabel/index.js +24 -23
- package/dist/components/UTPieChart/components/Legend/contants.js +3 -6
- package/dist/components/UTPieChart/components/Legend/index.js +27 -24
- package/dist/components/UTPieChart/constants.js +13 -26
- package/dist/components/UTPieChart/hooks/use-animated-value/index.js +15 -33
- package/dist/components/UTPieChart/index.js +73 -76
- package/dist/components/UTPieChart/theme.js +23 -25
- package/dist/components/UTPieChart/utils.js +4 -2
- package/dist/components/UTProgressBar/constants.js +2 -4
- package/dist/components/UTProgressBar/index.js +12 -11
- package/dist/components/UTProgressBar/theme.js +25 -27
- package/dist/components/UTProgressBar/types.js +2 -3
- package/dist/components/UTRadioGroup/index.js +45 -71
- package/dist/components/UTRadioGroup/theme.js +82 -86
- package/dist/components/UTRating/components/Circle/index.js +41 -56
- package/dist/components/UTRating/components/Faces/constants.js +2 -4
- package/dist/components/UTRating/components/Faces/index.js +34 -36
- package/dist/components/UTRating/components/Star/index.js +36 -40
- package/dist/components/UTRating/constants.js +4 -8
- package/dist/components/UTRating/index.js +31 -46
- package/dist/components/UTRating/theme.js +77 -79
- package/dist/components/UTRipple/Ripple.js +22 -39
- package/dist/components/UTRipple/index.js +18 -37
- package/dist/components/UTSelect/components/Option/index.js +13 -13
- package/dist/components/UTSelect/constants.js +4 -8
- package/dist/components/UTSelect/index.js +61 -81
- package/dist/components/UTSelect/stylesJS.js +2 -3
- package/dist/components/UTSelect/theme.js +43 -45
- package/dist/components/UTSelect/utils.js +3 -13
- package/dist/components/UTSidebar/components/ListOption/index.js +32 -47
- package/dist/components/UTSidebar/components/LogosContainer/components/DynamicIcon/index.js +8 -8
- package/dist/components/UTSidebar/components/LogosContainer/index.js +14 -14
- package/dist/components/UTSidebar/components/Option/constants.js +2 -3
- package/dist/components/UTSidebar/components/Option/index.js +28 -32
- package/dist/components/UTSidebar/components/Toggler/index.js +11 -11
- package/dist/components/UTSidebar/index.js +42 -53
- package/dist/components/UTSidebar/theme.js +1 -1
- package/dist/components/UTSidebar/types.js +5 -10
- package/dist/components/UTSkeleton/index.js +10 -36
- package/dist/components/UTSwitch/constants.js +3 -6
- package/dist/components/UTSwitch/index.js +42 -57
- package/dist/components/UTSwitch/theme.js +115 -117
- package/dist/components/UTTable/components/ActionIcons/constants.js +1 -2
- package/dist/components/UTTable/components/ActionIcons/index.js +44 -81
- package/dist/components/UTTable/components/Cell/index.js +18 -23
- package/dist/components/UTTable/components/HeaderCell/constants.js +2 -3
- package/dist/components/UTTable/components/HeaderCell/index.js +23 -30
- package/dist/components/UTTable/components/HeaderCell/utils.js +3 -3
- package/dist/components/UTTable/components/PrimaryAction/index.js +12 -11
- package/dist/components/UTTable/components/ResponsiveCell/index.js +19 -20
- package/dist/components/UTTable/components/Status/index.js +18 -19
- package/dist/components/UTTable/components/TableFooter/components/PageSizeSelector/index.js +10 -9
- package/dist/components/UTTable/components/TableFooter/components/PageSizeSelector/utils.js +7 -13
- package/dist/components/UTTable/components/TableFooter/components/Pagination/components/NavigationButton/index.js +12 -12
- package/dist/components/UTTable/components/TableFooter/components/Pagination/index.js +21 -32
- package/dist/components/UTTable/components/TableFooter/components/Pagination/utils.js +8 -14
- package/dist/components/UTTable/components/TableFooter/constants.js +1 -2
- package/dist/components/UTTable/components/TableFooter/index.js +15 -15
- package/dist/components/UTTable/components/TableHeader/index.js +11 -11
- package/dist/components/UTTable/components/TableRow/constants.js +3 -6
- package/dist/components/UTTable/components/TableRow/index.js +79 -94
- package/dist/components/UTTable/constants.js +26 -43
- package/dist/components/UTTable/hook.js +11 -26
- package/dist/components/UTTable/index.js +125 -213
- package/dist/components/UTTable/theme.js +13 -16
- package/dist/components/UTTable/types.js +4 -8
- package/dist/components/UTTable/utils.js +70 -74
- package/dist/components/UTTabs/components/TooltipTab/index.js +20 -30
- package/dist/components/UTTabs/constants.js +4 -8
- package/dist/components/UTTabs/index.js +55 -84
- package/dist/components/UTTabs/theme.js +112 -114
- package/dist/components/UTTabs/utils.js +1 -1
- package/dist/components/UTTextArea/constants.js +4 -6
- package/dist/components/UTTextArea/index.js +40 -24
- package/dist/components/UTTextArea/styles.module.scss +20 -1
- package/dist/components/UTTextArea/theme.js +1 -1
- package/dist/components/UTTextInput/constants.js +2 -3
- package/dist/components/UTTextInput/index.js +116 -146
- package/dist/components/UTTextInput/theme.js +28 -30
- package/dist/components/UTThirdPartyCookieChecker/index.js +17 -21
- package/dist/components/UTToggle/components/ToggleOption/index.js +16 -17
- package/dist/components/UTToggle/index.js +25 -26
- package/dist/components/UTToggle/theme.js +47 -49
- package/dist/components/UTTooltip/index.js +23 -30
- package/dist/components/UTTooltip/theme.js +1 -1
- package/dist/components/UTTopbar/theme.js +4 -2
- package/dist/components/UTTouchableWithoutFeedback/index.js +14 -27
- package/dist/components/UTVirtualizedList/components/VirtualizedData/components/ListRow/constants.js +2 -4
- package/dist/components/UTVirtualizedList/components/VirtualizedData/components/ListRow/index.js +34 -31
- package/dist/components/UTVirtualizedList/components/VirtualizedData/components/ListRow/utils.js +4 -4
- package/dist/components/UTVirtualizedList/components/VirtualizedData/constants.js +6 -12
- package/dist/components/UTVirtualizedList/components/VirtualizedData/hooks/use-ledger.js +8 -18
- package/dist/components/UTVirtualizedList/components/VirtualizedData/hooks/use-virtualized-data.js +23 -47
- package/dist/components/UTVirtualizedList/components/VirtualizedData/index.js +31 -34
- package/dist/components/UTVirtualizedList/components/VirtualizedData/utils.js +81 -93
- package/dist/components/UTVirtualizedList/constants.js +4 -8
- package/dist/components/UTVirtualizedList/index.js +26 -38
- package/dist/components/UTWorkflowContainer/components/ActionButton/index.js +11 -11
- package/dist/components/UTWorkflowContainer/constants.js +5 -9
- package/dist/components/UTWorkflowContainer/hooks/use-previous.js +3 -3
- package/dist/components/UTWorkflowContainer/index.js +31 -50
- package/dist/components/UTWorkflowContainer/theme.js +70 -64
- package/dist/components/UTWorkflowContainer/types.js +2 -3
- package/dist/components/WithLoading/index.js +10 -15
- package/dist/components/WithTheme/index.js +10 -17
- package/dist/components/WithTheme/layout.js +18 -41
- package/dist/components/WithTouch/index.js +12 -19
- package/dist/index.js +54 -54
- package/dist/scss/variables/colors.module.scss +1 -0
- package/dist/theme.js +5 -3
- package/dist/types/commonTypes.js +3 -5
- package/dist/types/consumptionTypes.js +3 -5
- package/dist/types/formTypes.js +4 -7
- package/dist/types/tableTypes.js +2 -3
- package/dist/utils/classesUtils.js +4 -10
- package/dist/utils/componentUtils.js +10 -13
- package/dist/utils/helperFunctions.js +4 -4
- package/dist/utils/useScreenSize.js +2 -3
- package/package.json +1 -1
|
@@ -7,120 +7,118 @@ exports.retrieveStyle = void 0;
|
|
|
7
7
|
var _seamlessImmutable = require("seamless-immutable");
|
|
8
8
|
var _colorsModule = _interopRequireDefault(require("../../scss/variables/colors.module.scss"));
|
|
9
9
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
'&:hover:not($baseSelected)'
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
'&:hover:not($secondarySelected)'
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
'& > div'
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', '& > div', 'backgroundColor'], _colorsModule.default.black)
|
|
92
|
-
},
|
|
93
|
-
borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', 'borderRadius'])
|
|
94
|
-
},
|
|
95
|
-
secondaryIndicator: {
|
|
96
|
-
flex: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'flex']),
|
|
97
|
-
height: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'height'], 3),
|
|
98
|
-
bottom: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'bottom'], 'initial'),
|
|
99
|
-
display: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'display'], 'flex'),
|
|
100
|
-
justifyContent: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'justifyContent'], 'center'),
|
|
101
|
-
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'backgroundColor'], 'transparent'),
|
|
102
|
-
'& > div': {
|
|
103
|
-
borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', '& > div', 'borderRadius'], 0),
|
|
104
|
-
maxWidth: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', '& > div', 'maxWidth'], '100%'),
|
|
105
|
-
width: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', '& > div', 'width'], '100%'),
|
|
106
|
-
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', '& > div', 'backgroundColor'], _colorsModule.default.black)
|
|
107
|
-
},
|
|
108
|
-
borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'borderRadius'])
|
|
109
|
-
},
|
|
110
|
-
baseTextColorPrimary: {
|
|
111
|
-
color: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTextColorPrimary', 'color'])
|
|
112
|
-
},
|
|
113
|
-
secondaryTextColorPrimary: {
|
|
114
|
-
color: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTextColorPrimary', 'color'])
|
|
10
|
+
const retrieveStyle = theme => ({
|
|
11
|
+
baseTabsRoot: {
|
|
12
|
+
border: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabsRoot', 'border'], 0),
|
|
13
|
+
minHeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabsRoot', 'minHeight'], 0),
|
|
14
|
+
minWidth: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabsRoot', 'minWidth'], 0)
|
|
15
|
+
},
|
|
16
|
+
secondaryTabsRoot: {
|
|
17
|
+
border: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabsRoot', 'border'], 0),
|
|
18
|
+
minHeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabsRoot', 'minHeight'], 0),
|
|
19
|
+
minWidth: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabsRoot', 'minWidth'], 0)
|
|
20
|
+
},
|
|
21
|
+
baseTabRoot: {
|
|
22
|
+
flex: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'flex']),
|
|
23
|
+
fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'fontFamily']),
|
|
24
|
+
fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'fontSize'], '12px'),
|
|
25
|
+
fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'fontWeight'], 'normal'),
|
|
26
|
+
textTransform: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'textTransform'], 'none'),
|
|
27
|
+
padding: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'padding']),
|
|
28
|
+
maxHeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'maxHeight']),
|
|
29
|
+
minHeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'minHeight']),
|
|
30
|
+
maxWidth: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'maxWidth']),
|
|
31
|
+
minWidth: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'minWidth']),
|
|
32
|
+
width: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'width']),
|
|
33
|
+
height: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'height']),
|
|
34
|
+
color: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'color'], _colorsModule.default.black),
|
|
35
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'backgroundColor'], 'transparent'),
|
|
36
|
+
borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'borderRadius'], 0),
|
|
37
|
+
opacity: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'opacity']),
|
|
38
|
+
transition: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'transition'], "all 350ms cubic-bezier(0.4, 0, 0.2, 1) 0ms"),
|
|
39
|
+
willChange: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', 'willChange']),
|
|
40
|
+
'&:hover:not($baseSelected)': {
|
|
41
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', '&:hover:not($baseSelected)', 'backgroundColor'], 'transparent'),
|
|
42
|
+
transition: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTabRoot', '&:hover:not($baseSelected)', 'transition'], 'box-shadow 300ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;')
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
secondaryTabRoot: {
|
|
46
|
+
flex: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'flex']),
|
|
47
|
+
fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'fontFamily']),
|
|
48
|
+
fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'fontSize'], '12px'),
|
|
49
|
+
fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'fontWeight'], 'normal'),
|
|
50
|
+
textTransform: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'textTransform'], 'none'),
|
|
51
|
+
padding: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'padding']),
|
|
52
|
+
maxHeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'maxHeight']),
|
|
53
|
+
minHeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'minHeight']),
|
|
54
|
+
maxWidth: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'maxWidth']),
|
|
55
|
+
minWidth: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'minWidth']),
|
|
56
|
+
width: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'width']),
|
|
57
|
+
height: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'height']),
|
|
58
|
+
color: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'color'], _colorsModule.default.black),
|
|
59
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'backgroundColor'], 'transparent'),
|
|
60
|
+
borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'borderRadius'], 0),
|
|
61
|
+
opacity: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'opacity']),
|
|
62
|
+
transition: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'transition'], "all 350ms cubic-bezier(0.4, 0, 0.2, 1) 0ms"),
|
|
63
|
+
willChange: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', 'willChange']),
|
|
64
|
+
'&:hover:not($secondarySelected)': {
|
|
65
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', '&:hover:not($secondarySelected)', 'backgroundColor'], 'transparent'),
|
|
66
|
+
transition: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTabRoot', '&:hover:not($secondarySelected)', 'transition'], 'box-shadow 300ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;')
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
baseSelected: {
|
|
70
|
+
fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseSelected', 'fontWeight'], 'normal'),
|
|
71
|
+
color: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseSelected', 'color'], _colorsModule.default.black),
|
|
72
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseSelected', 'backgroundColor'], 'transparent')
|
|
73
|
+
},
|
|
74
|
+
secondarySelected: {
|
|
75
|
+
fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondarySelected', 'fontWeight'], 'normal'),
|
|
76
|
+
color: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondarySelected', 'color'], _colorsModule.default.black),
|
|
77
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondarySelected', 'backgroundColor'], 'transparent')
|
|
78
|
+
},
|
|
79
|
+
baseIndicator: {
|
|
80
|
+
flex: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', 'flex']),
|
|
81
|
+
height: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', 'height'], 3),
|
|
82
|
+
bottom: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', 'bottom'], 'initial'),
|
|
83
|
+
display: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', 'display'], 'flex'),
|
|
84
|
+
justifyContent: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', 'justifyContent'], 'center'),
|
|
85
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', 'backgroundColor'], 'transparent'),
|
|
86
|
+
'& > div': {
|
|
87
|
+
borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', '& > div', 'borderRadius'], 0),
|
|
88
|
+
maxWidth: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', '& > div', 'maxWidth'], '100%'),
|
|
89
|
+
width: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', '& > div', 'width'], '100%'),
|
|
90
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', '& > div', 'backgroundColor'], _colorsModule.default.black)
|
|
115
91
|
},
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
92
|
+
borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseIndicator', 'borderRadius'])
|
|
93
|
+
},
|
|
94
|
+
secondaryIndicator: {
|
|
95
|
+
flex: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'flex']),
|
|
96
|
+
height: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'height'], 3),
|
|
97
|
+
bottom: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'bottom'], 'initial'),
|
|
98
|
+
display: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'display'], 'flex'),
|
|
99
|
+
justifyContent: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'justifyContent'], 'center'),
|
|
100
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'backgroundColor'], 'transparent'),
|
|
101
|
+
'& > div': {
|
|
102
|
+
borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', '& > div', 'borderRadius'], 0),
|
|
103
|
+
maxWidth: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', '& > div', 'maxWidth'], '100%'),
|
|
104
|
+
width: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', '& > div', 'width'], '100%'),
|
|
105
|
+
backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', '& > div', 'backgroundColor'], _colorsModule.default.black)
|
|
119
106
|
},
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
}
|
|
125
|
-
|
|
107
|
+
borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryIndicator', 'borderRadius'])
|
|
108
|
+
},
|
|
109
|
+
baseTextColorPrimary: {
|
|
110
|
+
color: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseTextColorPrimary', 'color'])
|
|
111
|
+
},
|
|
112
|
+
secondaryTextColorPrimary: {
|
|
113
|
+
color: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryTextColorPrimary', 'color'])
|
|
114
|
+
},
|
|
115
|
+
baseLabel: {
|
|
116
|
+
fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseLabel', 'fontSize']),
|
|
117
|
+
fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'baseLabel', 'fontWeight'])
|
|
118
|
+
},
|
|
119
|
+
secondaryLabel: {
|
|
120
|
+
fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryLabel', 'fontSize']),
|
|
121
|
+
fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTTabs', 'secondaryLabel', 'fontWeight'])
|
|
122
|
+
}
|
|
123
|
+
});
|
|
126
124
|
exports.retrieveStyle = retrieveStyle;
|
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.retrieveClassNamesFromVariants = void 0;
|
|
7
7
|
var _constants = require("./constants");
|
|
8
|
-
|
|
8
|
+
const retrieveClassNamesFromVariants = (variant, classes) => {
|
|
9
9
|
switch (variant) {
|
|
10
10
|
case _constants.variants.SECONDARY:
|
|
11
11
|
return {
|
|
@@ -3,11 +3,9 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.tippyProps = void 0;
|
|
7
|
-
|
|
8
|
-
appendTo:
|
|
9
|
-
return document.body;
|
|
10
|
-
},
|
|
6
|
+
exports.tippyProps = exports.limitWarningFactor = void 0;
|
|
7
|
+
const tippyProps = exports.tippyProps = {
|
|
8
|
+
appendTo: () => document.body,
|
|
11
9
|
interactive: false
|
|
12
10
|
};
|
|
13
|
-
exports.
|
|
11
|
+
const limitWarningFactor = exports.limitWarningFactor = 0.9;
|
|
@@ -6,6 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _propTypes = require("prop-types");
|
|
9
|
+
var _normalize = require("@widergy/web-utils/lib/normalize");
|
|
9
10
|
var _HelpOutline = _interopRequireDefault(require("@material-ui/icons/HelpOutline"));
|
|
10
11
|
var _UTTooltip = _interopRequireDefault(require("../UTTooltip"));
|
|
11
12
|
var _WithTheme = _interopRequireDefault(require("../WithTheme"));
|
|
@@ -16,26 +17,37 @@ var _theme = require("./theme");
|
|
|
16
17
|
var _stylesModule = _interopRequireDefault(require("./styles.module.scss"));
|
|
17
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
18
19
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
classNames =
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
inputProps =
|
|
27
|
-
onBlur
|
|
28
|
-
onChange
|
|
29
|
-
onFocus
|
|
30
|
-
placeholder
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
20
|
+
const UTTextArea = _ref => {
|
|
21
|
+
let {
|
|
22
|
+
classes,
|
|
23
|
+
classNames = {},
|
|
24
|
+
field,
|
|
25
|
+
disabled,
|
|
26
|
+
HelpIcon,
|
|
27
|
+
inputProps = {},
|
|
28
|
+
onBlur,
|
|
29
|
+
onChange,
|
|
30
|
+
onFocus,
|
|
31
|
+
placeholder,
|
|
32
|
+
title = '',
|
|
33
|
+
tooltip,
|
|
34
|
+
value
|
|
35
|
+
} = _ref;
|
|
36
|
+
const {
|
|
37
|
+
container,
|
|
38
|
+
icon,
|
|
39
|
+
textarea,
|
|
40
|
+
label
|
|
41
|
+
} = classNames;
|
|
42
|
+
const {
|
|
43
|
+
character_count_limit: characterCountLimit
|
|
44
|
+
} = (field === null || field === void 0 ? void 0 : field.configuration) || {};
|
|
45
|
+
const handleOnChange = _ref2 => {
|
|
46
|
+
let {
|
|
47
|
+
target
|
|
48
|
+
} = _ref2;
|
|
49
|
+
return onChange(characterCountLimit ? (0, _normalize.maxLength)(characterCountLimit)(target.value) : target.value);
|
|
50
|
+
};
|
|
39
51
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
40
52
|
className: container
|
|
41
53
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
@@ -43,16 +55,20 @@ var UTTextArea = function UTTextArea(_ref) {
|
|
|
43
55
|
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
44
56
|
className: "".concat(label, " ").concat(_stylesModule.default.label)
|
|
45
57
|
}, title)), /*#__PURE__*/_react.default.createElement("div", {
|
|
58
|
+
className: _stylesModule.default.content
|
|
59
|
+
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
46
60
|
className: _stylesModule.default.textAreaContainer
|
|
47
61
|
}, /*#__PURE__*/_react.default.createElement("textarea", _extends({}, inputProps, {
|
|
48
62
|
className: "".concat(_stylesModule.default.textarea, " ").concat(textarea, " ").concat(classes.textarea),
|
|
49
|
-
onChange:
|
|
63
|
+
onChange: handleOnChange,
|
|
50
64
|
onBlur: onBlur,
|
|
51
65
|
onFocus: onFocus,
|
|
52
66
|
value: value,
|
|
53
67
|
disabled: disabled,
|
|
54
68
|
placeholder: placeholder
|
|
55
|
-
})),
|
|
69
|
+
})), characterCountLimit && /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
70
|
+
className: "\n ".concat(_stylesModule.default.characterCount, "\n ").concat(value.length === characterCountLimit ? _stylesModule.default.characterLimitReached : value.length >= characterCountLimit * _constants.limitWarningFactor ? _stylesModule.default.characterLimitWarning : '', "\n ")
|
|
71
|
+
}, "".concat(value.length, "/").concat(characterCountLimit))), tooltip && /*#__PURE__*/_react.default.createElement(_UTTooltip.default, {
|
|
56
72
|
content: tooltip,
|
|
57
73
|
tippyProps: _constants.tippyProps
|
|
58
74
|
}, /*#__PURE__*/_react.default.createElement("div", null, HelpIcon || /*#__PURE__*/_react.default.createElement(_HelpOutline.default, {
|
|
@@ -68,6 +84,7 @@ UTTextArea.propTypes = {
|
|
|
68
84
|
textarea: _propTypes.string
|
|
69
85
|
}),
|
|
70
86
|
disabled: _propTypes.bool,
|
|
87
|
+
field: _formTypes.fieldType,
|
|
71
88
|
HelpIcon: _propTypes.elementType,
|
|
72
89
|
inputProps: _formTypes.inputPropTypes,
|
|
73
90
|
onBlur: _propTypes.func,
|
|
@@ -78,5 +95,4 @@ UTTextArea.propTypes = {
|
|
|
78
95
|
tooltip: _propTypes.string,
|
|
79
96
|
value: _propTypes.string
|
|
80
97
|
};
|
|
81
|
-
var _default = (0, _WithTheme.default)(_theme.retrieveStyle)(UTTextArea);
|
|
82
|
-
exports.default = _default;
|
|
98
|
+
var _default = exports.default = (0, _WithTheme.default)(_theme.retrieveStyle)(UTTextArea);
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
@import '../../scss/variables/colors.module.scss';
|
|
2
|
+
|
|
1
3
|
.textarea {
|
|
2
4
|
height: 100px;
|
|
3
5
|
width: 100%;
|
|
@@ -13,8 +15,25 @@
|
|
|
13
15
|
padding-right: 5px;
|
|
14
16
|
}
|
|
15
17
|
|
|
16
|
-
.
|
|
18
|
+
.content {
|
|
17
19
|
column-gap: 8px;
|
|
18
20
|
display: flex;
|
|
19
21
|
margin: 10px 0;
|
|
20
22
|
}
|
|
23
|
+
|
|
24
|
+
.textAreaContainer {
|
|
25
|
+
height: 100px;
|
|
26
|
+
width: 100%;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.characterCount {
|
|
30
|
+
text-align: right;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.characterLimitWarning {
|
|
34
|
+
color: $warning;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.characterLimitReached {
|
|
38
|
+
color: $error;
|
|
39
|
+
}
|
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.retrieveStyle = void 0;
|
|
7
7
|
var _colorsModule = _interopRequireDefault(require("../../scss/variables/colors.module.scss"));
|
|
8
8
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
9
|
-
|
|
9
|
+
const retrieveStyle = theme => {
|
|
10
10
|
var _theme$UTTextArea, _theme$UTTextArea2, _theme$UTTextArea3, _theme$UTTextArea4, _theme$Fonts, _theme$UTTextArea5, _theme$Fonts2, _theme$UTTextArea6, _theme$UTTextArea7, _theme$UTTextArea8, _theme$UTTextArea9, _theme$UTTextArea10, _theme$UTTextArea11, _theme$UTTextArea12, _theme$UTTextArea13, _theme$UTTextArea14, _theme$UTTextArea15, _theme$UTTextArea16, _theme$UTTextArea17, _theme$UTTextArea18, _theme$UTTextArea19, _theme$UTTextArea20;
|
|
11
11
|
return {
|
|
12
12
|
textarea: {
|
|
@@ -4,9 +4,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.INPUT_TYPES = void 0;
|
|
7
|
-
|
|
7
|
+
const INPUT_TYPES = exports.INPUT_TYPES = {
|
|
8
8
|
PASSWORD: 'password',
|
|
9
9
|
TEXT: 'text',
|
|
10
10
|
NUMBER: 'number'
|
|
11
|
-
};
|
|
12
|
-
exports.INPUT_TYPES = INPUT_TYPES;
|
|
11
|
+
};
|