@widergy/energy-ui 2.12.2 → 2.12.3

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.
Files changed (279) hide show
  1. package/dist/components/EnergyThemeProvider/index.js +13 -36
  2. package/dist/components/Loading/constants.js +1 -2
  3. package/dist/components/Loading/index.js +13 -12
  4. package/dist/components/Loading/theme.js +4 -2
  5. package/dist/components/UTAlert/AlertHandler.js +75 -101
  6. package/dist/components/UTAlert/index.js +65 -87
  7. package/dist/components/UTAlert/theme.js +32 -32
  8. package/dist/components/UTAttachment/components/Preview/index.js +8 -9
  9. package/dist/components/UTAttachment/constants.js +7 -13
  10. package/dist/components/UTAttachment/index.js +159 -250
  11. package/dist/components/UTAttachment/layout.js +26 -27
  12. package/dist/components/UTAttachment/theme.js +4 -2
  13. package/dist/components/UTAttachment/utils.js +34 -117
  14. package/dist/components/UTAutocomplete/components/ListBox/index.js +13 -21
  15. package/dist/components/UTAutocomplete/components/ListBox/utils.js +9 -11
  16. package/dist/components/UTAutocomplete/constants.js +12 -23
  17. package/dist/components/UTAutocomplete/index.js +54 -94
  18. package/dist/components/UTAutocomplete/theme.js +6 -4
  19. package/dist/components/UTAvatar/constants.js +2 -3
  20. package/dist/components/UTAvatar/index.js +18 -17
  21. package/dist/components/UTBarChart/components/Bars/components/Bar/components/Rect/index.js +22 -22
  22. package/dist/components/UTBarChart/components/Bars/components/Bar/constants.js +1 -1
  23. package/dist/components/UTBarChart/components/Bars/components/Bar/index.js +21 -22
  24. package/dist/components/UTBarChart/components/Bars/constants.js +3 -6
  25. package/dist/components/UTBarChart/components/Bars/index.js +70 -80
  26. package/dist/components/UTBarChart/components/Legend/constants.js +12 -18
  27. package/dist/components/UTBarChart/components/Legend/index.js +75 -93
  28. package/dist/components/UTBarChart/components/Legend/utils.js +1 -5
  29. package/dist/components/UTBarChart/components/Levels/index.js +16 -14
  30. package/dist/components/UTBarChart/components/Levels/utils.js +25 -27
  31. package/dist/components/UTBarChart/components/LinearPlot/constants.js +3 -5
  32. package/dist/components/UTBarChart/components/LinearPlot/index.js +25 -20
  33. package/dist/components/UTBarChart/components/LinearPlot/utils.js +37 -39
  34. package/dist/components/UTBarChart/components/Pagination/constants.js +1 -2
  35. package/dist/components/UTBarChart/components/Pagination/index.js +20 -24
  36. package/dist/components/UTBarChart/components/XAxis/components/AxisElement/index.js +21 -32
  37. package/dist/components/UTBarChart/components/XAxis/components/Decoration/constants.js +2 -4
  38. package/dist/components/UTBarChart/components/XAxis/components/Decoration/index.js +20 -19
  39. package/dist/components/UTBarChart/components/XAxis/constants.js +1 -2
  40. package/dist/components/UTBarChart/components/XAxis/index.js +54 -65
  41. package/dist/components/UTBarChart/components/YAxis/AxisElement/index.js +12 -11
  42. package/dist/components/UTBarChart/components/YAxis/constants.js +1 -2
  43. package/dist/components/UTBarChart/components/YAxis/index.js +30 -37
  44. package/dist/components/UTBarChart/components/YAxis/utils.js +4 -6
  45. package/dist/components/UTBarChart/constants.js +4 -8
  46. package/dist/components/UTBarChart/hooks/use-dynamic-margins.js +23 -40
  47. package/dist/components/UTBarChart/index.js +152 -166
  48. package/dist/components/UTBarChart/theme.js +4 -2
  49. package/dist/components/UTBarChart/types.js +10 -19
  50. package/dist/components/UTBarChart/utils.js +107 -111
  51. package/dist/components/UTBreadcrumbs/constants.js +23 -31
  52. package/dist/components/UTBreadcrumbs/index.js +76 -101
  53. package/dist/components/UTBreadcrumbs/theme.js +4 -2
  54. package/dist/components/UTButton/constants.js +11 -17
  55. package/dist/components/UTButton/index.js +28 -31
  56. package/dist/components/UTButton/theme.js +23 -23
  57. package/dist/components/UTCBUInput/index.js +36 -40
  58. package/dist/components/UTCBUInput/theme.js +4 -2
  59. package/dist/components/UTCaptcha/index.js +19 -45
  60. package/dist/components/UTCard/components/UTCardFooter/index.js +15 -16
  61. package/dist/components/UTCard/index.js +85 -120
  62. package/dist/components/UTCard/theme.js +11 -12
  63. package/dist/components/UTCard/types.js +2 -3
  64. package/dist/components/UTCarousel/components/Button/index.js +13 -13
  65. package/dist/components/UTCarousel/components/Legend/index.js +13 -15
  66. package/dist/components/UTCarousel/components/Slider/component/Slide/index.js +16 -16
  67. package/dist/components/UTCarousel/components/Slider/constants.js +5 -10
  68. package/dist/components/UTCarousel/components/Slider/index.js +204 -273
  69. package/dist/components/UTCarousel/components/Slider/layout.js +67 -94
  70. package/dist/components/UTCarousel/index.js +14 -15
  71. package/dist/components/UTCarousel/theme.js +4 -2
  72. package/dist/components/UTCheckList/constants.js +1 -2
  73. package/dist/components/UTCheckList/index.js +72 -93
  74. package/dist/components/UTCheckList/theme.js +31 -31
  75. package/dist/components/UTCheckbox/constants.js +3 -6
  76. package/dist/components/UTCheckbox/index.js +32 -44
  77. package/dist/components/UTCheckbox/theme.js +35 -35
  78. package/dist/components/UTConsumptionBar/components/ConsumptionBarIndicator/index.js +9 -9
  79. package/dist/components/UTConsumptionBar/constants.js +3 -6
  80. package/dist/components/UTConsumptionBar/index.js +53 -80
  81. package/dist/components/UTCuit/index.js +109 -133
  82. package/dist/components/UTCuit/theme.js +51 -53
  83. package/dist/components/UTDatePicker/components/Day/constants.js +1 -2
  84. package/dist/components/UTDatePicker/components/Day/index.js +12 -12
  85. package/dist/components/UTDatePicker/constants.js +20 -31
  86. package/dist/components/UTDatePicker/index.js +60 -102
  87. package/dist/components/UTDatePicker/theme.js +5 -3
  88. package/dist/components/UTDatePicker/types.js +2 -3
  89. package/dist/components/UTDatePicker/utils.js +2 -6
  90. package/dist/components/UTDialog/constants.js +2 -4
  91. package/dist/components/UTDialog/index.js +38 -37
  92. package/dist/components/UTDialog/theme.js +4 -2
  93. package/dist/components/UTDialog/types.js +2 -3
  94. package/dist/components/UTDotMenu/index.js +39 -61
  95. package/dist/components/UTEmojiPicker/constants.js +6 -11
  96. package/dist/components/UTEmojiPicker/index.js +45 -65
  97. package/dist/components/UTEmojiPicker/theme.js +4 -2
  98. package/dist/components/UTEmojiPicker/utils.js +21 -51
  99. package/dist/components/UTExternalLink/constants.js +3 -5
  100. package/dist/components/UTExternalLink/index.js +18 -15
  101. package/dist/components/UTExternalLink/theme.js +8 -6
  102. package/dist/components/UTFileInput/constants.js +2 -4
  103. package/dist/components/UTFileInput/index.js +7 -31
  104. package/dist/components/UTFileInput/layout.js +68 -97
  105. package/dist/components/UTIconButton/index.js +49 -72
  106. package/dist/components/UTIconButton/theme.js +4 -2
  107. package/dist/components/UTImageRadio/components/ImageRadioCard/index.js +53 -58
  108. package/dist/components/UTImageRadio/constants.js +3 -6
  109. package/dist/components/UTImageRadio/index.js +39 -47
  110. package/dist/components/UTImageRadio/theme.js +11 -12
  111. package/dist/components/UTImageRadio/types.js +2 -3
  112. package/dist/components/UTImageRadio/utils.js +2 -6
  113. package/dist/components/UTLabel/constants.js +14 -20
  114. package/dist/components/UTLabel/index.js +18 -20
  115. package/dist/components/UTLabel/theme.js +15 -15
  116. package/dist/components/UTList/index.js +15 -18
  117. package/dist/components/UTLoading/index.js +15 -15
  118. package/dist/components/UTMap/components/GoogleMaps/constants.js +8 -11
  119. package/dist/components/UTMap/components/GoogleMaps/index.js +63 -91
  120. package/dist/components/UTMap/components/GoogleMaps/styles.js +2 -3
  121. package/dist/components/UTMap/constants.js +6 -12
  122. package/dist/components/UTMap/index.js +163 -198
  123. package/dist/components/UTMap/types.js +4 -6
  124. package/dist/components/UTMap/utils.js +29 -46
  125. package/dist/components/UTMap/withGoogleMapScript.js +18 -22
  126. package/dist/components/UTMenu/index.js +52 -69
  127. package/dist/components/UTMenu/theme.js +5 -3
  128. package/dist/components/UTMenu/utils.js +5 -11
  129. package/dist/components/UTModal/constants.js +9 -13
  130. package/dist/components/UTModal/index.js +26 -30
  131. package/dist/components/UTModal/theme.js +4 -2
  132. package/dist/components/UTPagination/components/PageSizeSelector/index.js +11 -10
  133. package/dist/components/UTPagination/components/PageSizeSelector/utils.js +7 -13
  134. package/dist/components/UTPagination/components/Pagination/components/NavigationButton/index.js +12 -12
  135. package/dist/components/UTPagination/components/Pagination/index.js +28 -39
  136. package/dist/components/UTPagination/components/Pagination/utils.js +8 -14
  137. package/dist/components/UTPagination/constants.js +3 -6
  138. package/dist/components/UTPagination/index.js +16 -17
  139. package/dist/components/UTPagination/theme.js +4 -2
  140. package/dist/components/UTPanel/index.js +38 -44
  141. package/dist/components/UTPasswordField/components/PasswordValidations/components/Error/index.js +13 -10
  142. package/dist/components/UTPasswordField/components/PasswordValidations/components/Validation/index.js +22 -19
  143. package/dist/components/UTPasswordField/components/PasswordValidations/index.js +63 -50
  144. package/dist/components/UTPasswordField/components/PasswordWarning/index.js +25 -26
  145. package/dist/components/UTPasswordField/index.js +26 -23
  146. package/dist/components/UTPasswordField/theme.js +4 -2
  147. package/dist/components/UTPhoneInput/constants.js +3 -6
  148. package/dist/components/UTPhoneInput/index.js +180 -205
  149. package/dist/components/UTPhoneInput/theme.js +77 -77
  150. package/dist/components/UTPieChart/components/ArrowLabel/constants.js +4 -8
  151. package/dist/components/UTPieChart/components/ArrowLabel/index.js +24 -23
  152. package/dist/components/UTPieChart/components/Legend/contants.js +3 -6
  153. package/dist/components/UTPieChart/components/Legend/index.js +27 -24
  154. package/dist/components/UTPieChart/constants.js +13 -26
  155. package/dist/components/UTPieChart/hooks/use-animated-value/index.js +15 -33
  156. package/dist/components/UTPieChart/index.js +73 -76
  157. package/dist/components/UTPieChart/theme.js +4 -2
  158. package/dist/components/UTPieChart/utils.js +4 -2
  159. package/dist/components/UTProgressBar/constants.js +2 -4
  160. package/dist/components/UTProgressBar/index.js +15 -17
  161. package/dist/components/UTProgressBar/theme.js +4 -2
  162. package/dist/components/UTProgressBar/types.js +2 -3
  163. package/dist/components/UTRadioGroup/index.js +56 -83
  164. package/dist/components/UTRadioGroup/theme.js +52 -52
  165. package/dist/components/UTRating/components/Circle/index.js +41 -56
  166. package/dist/components/UTRating/components/Faces/constants.js +2 -4
  167. package/dist/components/UTRating/components/Faces/index.js +34 -36
  168. package/dist/components/UTRating/components/Star/index.js +36 -40
  169. package/dist/components/UTRating/constants.js +4 -8
  170. package/dist/components/UTRating/index.js +31 -46
  171. package/dist/components/UTRating/theme.js +4 -2
  172. package/dist/components/UTRipple/Ripple.js +22 -39
  173. package/dist/components/UTRipple/index.js +18 -37
  174. package/dist/components/UTSelect/components/Option/index.js +13 -13
  175. package/dist/components/UTSelect/constants.js +4 -8
  176. package/dist/components/UTSelect/index.js +63 -85
  177. package/dist/components/UTSelect/stylesJS.js +2 -3
  178. package/dist/components/UTSelect/theme.js +6 -4
  179. package/dist/components/UTSelect/utils.js +3 -13
  180. package/dist/components/UTSidebar/components/ListOption/index.js +34 -49
  181. package/dist/components/UTSidebar/components/LogosContainer/components/DynamicIcon/index.js +8 -8
  182. package/dist/components/UTSidebar/components/LogosContainer/index.js +14 -14
  183. package/dist/components/UTSidebar/components/Option/constants.js +2 -3
  184. package/dist/components/UTSidebar/components/Option/index.js +28 -32
  185. package/dist/components/UTSidebar/components/Toggler/index.js +11 -11
  186. package/dist/components/UTSidebar/index.js +42 -53
  187. package/dist/components/UTSidebar/theme.js +4 -2
  188. package/dist/components/UTSidebar/types.js +5 -10
  189. package/dist/components/UTSkeleton/index.js +10 -36
  190. package/dist/components/UTStatus/constants.js +5 -9
  191. package/dist/components/UTStatus/index.js +16 -15
  192. package/dist/components/UTStatus/theme.js +66 -49
  193. package/dist/components/UTSwitch/constants.js +3 -6
  194. package/dist/components/UTSwitch/index.js +42 -57
  195. package/dist/components/UTSwitch/theme.js +4 -2
  196. package/dist/components/UTTable/components/ActionIcons/constants.js +1 -2
  197. package/dist/components/UTTable/components/ActionIcons/index.js +47 -85
  198. package/dist/components/UTTable/components/Cell/components/ActionButton/index.js +10 -12
  199. package/dist/components/UTTable/components/Cell/index.js +18 -23
  200. package/dist/components/UTTable/components/HeaderCell/constants.js +2 -3
  201. package/dist/components/UTTable/components/HeaderCell/index.js +23 -30
  202. package/dist/components/UTTable/components/HeaderCell/utils.js +3 -3
  203. package/dist/components/UTTable/components/PrimaryAction/index.js +12 -11
  204. package/dist/components/UTTable/components/ResponsiveCell/index.js +19 -20
  205. package/dist/components/UTTable/components/Status/index.js +18 -19
  206. package/dist/components/UTTable/components/TableFooter/components/PageSizeSelector/index.js +10 -9
  207. package/dist/components/UTTable/components/TableFooter/components/PageSizeSelector/utils.js +7 -13
  208. package/dist/components/UTTable/components/TableFooter/components/Pagination/components/NavigationButton/index.js +12 -12
  209. package/dist/components/UTTable/components/TableFooter/components/Pagination/index.js +21 -32
  210. package/dist/components/UTTable/components/TableFooter/components/Pagination/utils.js +8 -14
  211. package/dist/components/UTTable/components/TableFooter/constants.js +1 -2
  212. package/dist/components/UTTable/components/TableFooter/index.js +15 -15
  213. package/dist/components/UTTable/components/TableHeader/index.js +11 -11
  214. package/dist/components/UTTable/components/TableRow/constants.js +3 -6
  215. package/dist/components/UTTable/components/TableRow/index.js +82 -95
  216. package/dist/components/UTTable/components/TableRow/styles.module.scss +8 -1
  217. package/dist/components/UTTable/components/TableRow/utils.js +15 -0
  218. package/dist/components/UTTable/constants.js +26 -43
  219. package/dist/components/UTTable/hook.js +11 -26
  220. package/dist/components/UTTable/index.js +129 -220
  221. package/dist/components/UTTable/theme.js +17 -17
  222. package/dist/components/UTTable/types.js +4 -8
  223. package/dist/components/UTTable/utils.js +70 -74
  224. package/dist/components/UTTabs/components/TooltipTab/index.js +20 -30
  225. package/dist/components/UTTabs/constants.js +4 -8
  226. package/dist/components/UTTabs/index.js +57 -86
  227. package/dist/components/UTTabs/theme.js +4 -2
  228. package/dist/components/UTTabs/utils.js +1 -1
  229. package/dist/components/UTTextArea/constants.js +3 -6
  230. package/dist/components/UTTextArea/index.js +23 -23
  231. package/dist/components/UTTextArea/theme.js +4 -2
  232. package/dist/components/UTTextInput/constants.js +2 -3
  233. package/dist/components/UTTextInput/index.js +137 -165
  234. package/dist/components/UTTextInput/theme.js +6 -4
  235. package/dist/components/UTThirdPartyCookieChecker/index.js +17 -21
  236. package/dist/components/UTToggle/components/ToggleOption/index.js +16 -17
  237. package/dist/components/UTToggle/index.js +25 -26
  238. package/dist/components/UTToggle/theme.js +4 -2
  239. package/dist/components/UTTooltip/index.js +23 -30
  240. package/dist/components/UTTooltip/theme.js +4 -2
  241. package/dist/components/UTTopbar/components/Notifications/index.js +11 -14
  242. package/dist/components/UTTopbar/components/UserMenu/index.js +15 -15
  243. package/dist/components/UTTopbar/index.js +28 -31
  244. package/dist/components/UTTopbar/theme.js +4 -2
  245. package/dist/components/UTTopbar/types.js +5 -9
  246. package/dist/components/UTTouchableWithoutFeedback/index.js +14 -27
  247. package/dist/components/UTVirtualizedList/components/VirtualizedData/components/ListRow/constants.js +2 -4
  248. package/dist/components/UTVirtualizedList/components/VirtualizedData/components/ListRow/index.js +34 -31
  249. package/dist/components/UTVirtualizedList/components/VirtualizedData/components/ListRow/utils.js +4 -4
  250. package/dist/components/UTVirtualizedList/components/VirtualizedData/constants.js +6 -12
  251. package/dist/components/UTVirtualizedList/components/VirtualizedData/hooks/use-ledger.js +8 -18
  252. package/dist/components/UTVirtualizedList/components/VirtualizedData/hooks/use-virtualized-data.js +23 -47
  253. package/dist/components/UTVirtualizedList/components/VirtualizedData/index.js +31 -34
  254. package/dist/components/UTVirtualizedList/components/VirtualizedData/utils.js +81 -93
  255. package/dist/components/UTVirtualizedList/constants.js +4 -8
  256. package/dist/components/UTVirtualizedList/index.js +26 -38
  257. package/dist/components/UTWorkflowContainer/components/ActionButton/index.js +17 -21
  258. package/dist/components/UTWorkflowContainer/constants.js +3 -6
  259. package/dist/components/UTWorkflowContainer/hooks/use-previous.js +3 -3
  260. package/dist/components/UTWorkflowContainer/index.js +32 -51
  261. package/dist/components/UTWorkflowContainer/theme.js +60 -53
  262. package/dist/components/UTWorkflowContainer/types.js +2 -3
  263. package/dist/components/WithLoading/index.js +10 -15
  264. package/dist/components/WithTheme/index.js +10 -17
  265. package/dist/components/WithTheme/layout.js +22 -28
  266. package/dist/components/WithTouch/index.js +12 -19
  267. package/dist/constants/UTTable.js +2 -3
  268. package/dist/index.js +58 -58
  269. package/dist/theme.js +6 -5
  270. package/dist/types/commonTypes.js +3 -5
  271. package/dist/types/consumptionTypes.js +3 -5
  272. package/dist/types/formTypes.js +4 -7
  273. package/dist/types/tableTypes.js +2 -3
  274. package/dist/utils/classesUtils.js +5 -13
  275. package/dist/utils/componentUtils.js +10 -13
  276. package/dist/utils/helperFunctions.js +4 -4
  277. package/dist/utils/shadowUtils.js +13 -11
  278. package/dist/utils/useScreenSize.js +2 -3
  279. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -5,349 +5,349 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  Object.defineProperty(exports, "AlertHandler", {
7
7
  enumerable: true,
8
- get: function get() {
8
+ get: function () {
9
9
  return _AlertHandler.default;
10
10
  }
11
11
  });
12
12
  Object.defineProperty(exports, "EnergyThemeProvider", {
13
13
  enumerable: true,
14
- get: function get() {
14
+ get: function () {
15
15
  return _EnergyThemeProvider.default;
16
16
  }
17
17
  });
18
18
  Object.defineProperty(exports, "UTAlert", {
19
19
  enumerable: true,
20
- get: function get() {
20
+ get: function () {
21
21
  return _UTAlert.default;
22
22
  }
23
23
  });
24
24
  Object.defineProperty(exports, "UTAttachment", {
25
25
  enumerable: true,
26
- get: function get() {
26
+ get: function () {
27
27
  return _UTAttachment.default;
28
28
  }
29
29
  });
30
30
  Object.defineProperty(exports, "UTAutocomplete", {
31
31
  enumerable: true,
32
- get: function get() {
32
+ get: function () {
33
33
  return _UTAutocomplete.default;
34
34
  }
35
35
  });
36
36
  Object.defineProperty(exports, "UTAvatar", {
37
37
  enumerable: true,
38
- get: function get() {
38
+ get: function () {
39
39
  return _UTAvatar.default;
40
40
  }
41
41
  });
42
42
  Object.defineProperty(exports, "UTBarChart", {
43
43
  enumerable: true,
44
- get: function get() {
44
+ get: function () {
45
45
  return _UTBarChart.default;
46
46
  }
47
47
  });
48
48
  Object.defineProperty(exports, "UTBreadcrumbs", {
49
49
  enumerable: true,
50
- get: function get() {
50
+ get: function () {
51
51
  return _UTBreadcrumbs.default;
52
52
  }
53
53
  });
54
54
  Object.defineProperty(exports, "UTButton", {
55
55
  enumerable: true,
56
- get: function get() {
56
+ get: function () {
57
57
  return _UTButton.default;
58
58
  }
59
59
  });
60
60
  Object.defineProperty(exports, "UTCBUInput", {
61
61
  enumerable: true,
62
- get: function get() {
62
+ get: function () {
63
63
  return _UTCBUInput.default;
64
64
  }
65
65
  });
66
66
  Object.defineProperty(exports, "UTCaptcha", {
67
67
  enumerable: true,
68
- get: function get() {
68
+ get: function () {
69
69
  return _UTCaptcha.default;
70
70
  }
71
71
  });
72
72
  Object.defineProperty(exports, "UTCard", {
73
73
  enumerable: true,
74
- get: function get() {
74
+ get: function () {
75
75
  return _UTCard.default;
76
76
  }
77
77
  });
78
78
  Object.defineProperty(exports, "UTCarousel", {
79
79
  enumerable: true,
80
- get: function get() {
80
+ get: function () {
81
81
  return _UTCarousel.default;
82
82
  }
83
83
  });
84
84
  Object.defineProperty(exports, "UTCheckList", {
85
85
  enumerable: true,
86
- get: function get() {
86
+ get: function () {
87
87
  return _UTCheckList.default;
88
88
  }
89
89
  });
90
90
  Object.defineProperty(exports, "UTCheckbox", {
91
91
  enumerable: true,
92
- get: function get() {
92
+ get: function () {
93
93
  return _UTCheckbox.default;
94
94
  }
95
95
  });
96
96
  Object.defineProperty(exports, "UTConsumptionBar", {
97
97
  enumerable: true,
98
- get: function get() {
98
+ get: function () {
99
99
  return _UTConsumptionBar.default;
100
100
  }
101
101
  });
102
102
  Object.defineProperty(exports, "UTCuit", {
103
103
  enumerable: true,
104
- get: function get() {
104
+ get: function () {
105
105
  return _UTCuit.default;
106
106
  }
107
107
  });
108
108
  Object.defineProperty(exports, "UTDatePicker", {
109
109
  enumerable: true,
110
- get: function get() {
110
+ get: function () {
111
111
  return _UTDatePicker.default;
112
112
  }
113
113
  });
114
114
  Object.defineProperty(exports, "UTDialog", {
115
115
  enumerable: true,
116
- get: function get() {
116
+ get: function () {
117
117
  return _UTDialog.default;
118
118
  }
119
119
  });
120
120
  Object.defineProperty(exports, "UTDotMenu", {
121
121
  enumerable: true,
122
- get: function get() {
122
+ get: function () {
123
123
  return _UTDotMenu.default;
124
124
  }
125
125
  });
126
126
  Object.defineProperty(exports, "UTEmojiPicker", {
127
127
  enumerable: true,
128
- get: function get() {
128
+ get: function () {
129
129
  return _UTEmojiPicker.default;
130
130
  }
131
131
  });
132
132
  Object.defineProperty(exports, "UTExternalLink", {
133
133
  enumerable: true,
134
- get: function get() {
134
+ get: function () {
135
135
  return _UTExternalLink.default;
136
136
  }
137
137
  });
138
138
  Object.defineProperty(exports, "UTFileInput", {
139
139
  enumerable: true,
140
- get: function get() {
140
+ get: function () {
141
141
  return _UTFileInput.default;
142
142
  }
143
143
  });
144
144
  Object.defineProperty(exports, "UTIconButton", {
145
145
  enumerable: true,
146
- get: function get() {
146
+ get: function () {
147
147
  return _UTIconButton.default;
148
148
  }
149
149
  });
150
150
  Object.defineProperty(exports, "UTImageRadio", {
151
151
  enumerable: true,
152
- get: function get() {
152
+ get: function () {
153
153
  return _UTImageRadio.default;
154
154
  }
155
155
  });
156
156
  Object.defineProperty(exports, "UTLabel", {
157
157
  enumerable: true,
158
- get: function get() {
158
+ get: function () {
159
159
  return _UTLabel.default;
160
160
  }
161
161
  });
162
162
  Object.defineProperty(exports, "UTList", {
163
163
  enumerable: true,
164
- get: function get() {
164
+ get: function () {
165
165
  return _UTList.default;
166
166
  }
167
167
  });
168
168
  Object.defineProperty(exports, "UTLoading", {
169
169
  enumerable: true,
170
- get: function get() {
170
+ get: function () {
171
171
  return _UTLoading.default;
172
172
  }
173
173
  });
174
174
  Object.defineProperty(exports, "UTMap", {
175
175
  enumerable: true,
176
- get: function get() {
176
+ get: function () {
177
177
  return _UTMap.default;
178
178
  }
179
179
  });
180
180
  Object.defineProperty(exports, "UTMenu", {
181
181
  enumerable: true,
182
- get: function get() {
182
+ get: function () {
183
183
  return _UTMenu.default;
184
184
  }
185
185
  });
186
186
  Object.defineProperty(exports, "UTModal", {
187
187
  enumerable: true,
188
- get: function get() {
188
+ get: function () {
189
189
  return _UTModal.default;
190
190
  }
191
191
  });
192
192
  Object.defineProperty(exports, "UTPagination", {
193
193
  enumerable: true,
194
- get: function get() {
194
+ get: function () {
195
195
  return _UTPagination.default;
196
196
  }
197
197
  });
198
198
  Object.defineProperty(exports, "UTPanel", {
199
199
  enumerable: true,
200
- get: function get() {
200
+ get: function () {
201
201
  return _UTPanel.default;
202
202
  }
203
203
  });
204
204
  Object.defineProperty(exports, "UTPasswordField", {
205
205
  enumerable: true,
206
- get: function get() {
206
+ get: function () {
207
207
  return _UTPasswordField.default;
208
208
  }
209
209
  });
210
210
  Object.defineProperty(exports, "UTPhoneInput", {
211
211
  enumerable: true,
212
- get: function get() {
212
+ get: function () {
213
213
  return _UTPhoneInput.default;
214
214
  }
215
215
  });
216
216
  Object.defineProperty(exports, "UTPieChart", {
217
217
  enumerable: true,
218
- get: function get() {
218
+ get: function () {
219
219
  return _UTPieChart.default;
220
220
  }
221
221
  });
222
222
  Object.defineProperty(exports, "UTProgressBar", {
223
223
  enumerable: true,
224
- get: function get() {
224
+ get: function () {
225
225
  return _UTProgressBar.default;
226
226
  }
227
227
  });
228
228
  Object.defineProperty(exports, "UTRadioGroup", {
229
229
  enumerable: true,
230
- get: function get() {
230
+ get: function () {
231
231
  return _UTRadioGroup.default;
232
232
  }
233
233
  });
234
234
  Object.defineProperty(exports, "UTRating", {
235
235
  enumerable: true,
236
- get: function get() {
236
+ get: function () {
237
237
  return _UTRating.default;
238
238
  }
239
239
  });
240
240
  Object.defineProperty(exports, "UTSelect", {
241
241
  enumerable: true,
242
- get: function get() {
242
+ get: function () {
243
243
  return _UTSelect.default;
244
244
  }
245
245
  });
246
246
  Object.defineProperty(exports, "UTSidebar", {
247
247
  enumerable: true,
248
- get: function get() {
248
+ get: function () {
249
249
  return _UTSidebar.default;
250
250
  }
251
251
  });
252
252
  Object.defineProperty(exports, "UTSkeleton", {
253
253
  enumerable: true,
254
- get: function get() {
254
+ get: function () {
255
255
  return _UTSkeleton.default;
256
256
  }
257
257
  });
258
258
  Object.defineProperty(exports, "UTStatus", {
259
259
  enumerable: true,
260
- get: function get() {
260
+ get: function () {
261
261
  return _UTStatus.default;
262
262
  }
263
263
  });
264
264
  Object.defineProperty(exports, "UTSwitch", {
265
265
  enumerable: true,
266
- get: function get() {
266
+ get: function () {
267
267
  return _UTSwitch.default;
268
268
  }
269
269
  });
270
270
  Object.defineProperty(exports, "UTTable", {
271
271
  enumerable: true,
272
- get: function get() {
272
+ get: function () {
273
273
  return _UTTable.default;
274
274
  }
275
275
  });
276
276
  Object.defineProperty(exports, "UTTabs", {
277
277
  enumerable: true,
278
- get: function get() {
278
+ get: function () {
279
279
  return _UTTabs.default;
280
280
  }
281
281
  });
282
282
  Object.defineProperty(exports, "UTTextArea", {
283
283
  enumerable: true,
284
- get: function get() {
284
+ get: function () {
285
285
  return _UTTextArea.default;
286
286
  }
287
287
  });
288
288
  Object.defineProperty(exports, "UTTextInput", {
289
289
  enumerable: true,
290
- get: function get() {
290
+ get: function () {
291
291
  return _UTTextInput.default;
292
292
  }
293
293
  });
294
294
  Object.defineProperty(exports, "UTThirdPartyCookieChecker", {
295
295
  enumerable: true,
296
- get: function get() {
296
+ get: function () {
297
297
  return _UTThirdPartyCookieChecker.default;
298
298
  }
299
299
  });
300
300
  Object.defineProperty(exports, "UTToggle", {
301
301
  enumerable: true,
302
- get: function get() {
302
+ get: function () {
303
303
  return _UTToggle.default;
304
304
  }
305
305
  });
306
306
  Object.defineProperty(exports, "UTTooltip", {
307
307
  enumerable: true,
308
- get: function get() {
308
+ get: function () {
309
309
  return _UTTooltip.default;
310
310
  }
311
311
  });
312
312
  Object.defineProperty(exports, "UTTopbar", {
313
313
  enumerable: true,
314
- get: function get() {
314
+ get: function () {
315
315
  return _UTTopbar.default;
316
316
  }
317
317
  });
318
318
  Object.defineProperty(exports, "UTTouchableWithoutFeedback", {
319
319
  enumerable: true,
320
- get: function get() {
320
+ get: function () {
321
321
  return _UTTouchableWithoutFeedback.default;
322
322
  }
323
323
  });
324
324
  Object.defineProperty(exports, "UTVirtualizedList", {
325
325
  enumerable: true,
326
- get: function get() {
326
+ get: function () {
327
327
  return _UTVirtualizedList.default;
328
328
  }
329
329
  });
330
330
  Object.defineProperty(exports, "UTWorkflowContainer", {
331
331
  enumerable: true,
332
- get: function get() {
332
+ get: function () {
333
333
  return _UTWorkflowContainer.default;
334
334
  }
335
335
  });
336
336
  Object.defineProperty(exports, "WithLoading", {
337
337
  enumerable: true,
338
- get: function get() {
338
+ get: function () {
339
339
  return _WithLoading.default;
340
340
  }
341
341
  });
342
342
  Object.defineProperty(exports, "WithTouch", {
343
343
  enumerable: true,
344
- get: function get() {
344
+ get: function () {
345
345
  return _WithTouch.default;
346
346
  }
347
347
  });
348
348
  Object.defineProperty(exports, "componentUtils", {
349
349
  enumerable: true,
350
- get: function get() {
350
+ get: function () {
351
351
  return _componentUtils.default;
352
352
  }
353
353
  });
package/dist/theme.js CHANGED
@@ -7,10 +7,11 @@ exports.manager = exports.EnergyThemeProvider = exports.EnergyThemeConsumer = vo
7
7
  var _react = _interopRequireDefault(require("react"));
8
8
  var _jss = require("jss");
9
9
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
10
- var ThemeContext = /*#__PURE__*/_react.default.createContext({});
11
- var manager = new _jss.SheetsManager();
12
- exports.manager = manager;
13
- var EnergyThemeProvider = ThemeContext.Provider,
14
- EnergyThemeConsumer = ThemeContext.Consumer;
10
+ const ThemeContext = /*#__PURE__*/_react.default.createContext({});
11
+ const manager = exports.manager = new _jss.SheetsManager();
12
+ const {
13
+ Provider: EnergyThemeProvider,
14
+ Consumer: EnergyThemeConsumer
15
+ } = ThemeContext;
15
16
  exports.EnergyThemeConsumer = EnergyThemeConsumer;
16
17
  exports.EnergyThemeProvider = EnergyThemeProvider;
@@ -5,15 +5,13 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.refType = exports.classesType = void 0;
7
7
  var _propTypes = require("prop-types");
8
- var classesType = (0, _propTypes.shape)({
8
+ const classesType = exports.classesType = (0, _propTypes.shape)({
9
9
  container: _propTypes.string,
10
10
  root: _propTypes.string,
11
11
  colorPrimary: _propTypes.string,
12
12
  barColorPrimary: _propTypes.string,
13
13
  label: _propTypes.string
14
14
  });
15
- exports.classesType = classesType;
16
- var refType = (0, _propTypes.oneOfType)([_propTypes.func, (0, _propTypes.shape)({
15
+ const refType = exports.refType = (0, _propTypes.oneOfType)([_propTypes.func, (0, _propTypes.shape)({
17
16
  current: _propTypes.any
18
- })]);
19
- exports.refType = refType;
17
+ })]);
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.consumptionLevelsTypes = exports.consumptionCategoriesTypes = void 0;
7
7
  var _propTypes = require("prop-types");
8
- var consumptionLevelsTypes = (0, _propTypes.arrayOf)((0, _propTypes.shape)({
8
+ const consumptionLevelsTypes = exports.consumptionLevelsTypes = (0, _propTypes.arrayOf)((0, _propTypes.shape)({
9
9
  charge: (0, _propTypes.arrayOf)((0, _propTypes.shape)({
10
10
  date: _propTypes.string,
11
11
  value: _propTypes.number
@@ -14,8 +14,7 @@ var consumptionLevelsTypes = (0, _propTypes.arrayOf)((0, _propTypes.shape)({
14
14
  name: _propTypes.string,
15
15
  range: (0, _propTypes.arrayOf)(_propTypes.number)
16
16
  }));
17
- exports.consumptionLevelsTypes = consumptionLevelsTypes;
18
- var consumptionCategoriesTypes = (0, _propTypes.arrayOf)((0, _propTypes.shape)({
17
+ const consumptionCategoriesTypes = exports.consumptionCategoriesTypes = (0, _propTypes.arrayOf)((0, _propTypes.shape)({
19
18
  name: _propTypes.string,
20
19
  title: _propTypes.string,
21
20
  usage: _propTypes.any,
@@ -26,5 +25,4 @@ var consumptionCategoriesTypes = (0, _propTypes.arrayOf)((0, _propTypes.shape)({
26
25
  kWh: _propTypes.number,
27
26
  name: _propTypes.string
28
27
  }))
29
- }));
30
- exports.consumptionCategoriesTypes = consumptionCategoriesTypes;
28
+ }));
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.metaPropTypes = exports.inputPropTypes = exports.fieldType = void 0;
7
7
  var _propTypes = require("prop-types");
8
- var inputPropTypes = (0, _propTypes.shape)({
8
+ const inputPropTypes = exports.inputPropTypes = (0, _propTypes.shape)({
9
9
  name: _propTypes.string,
10
10
  onBlur: _propTypes.func,
11
11
  onChange: _propTypes.func,
@@ -14,8 +14,7 @@ var inputPropTypes = (0, _propTypes.shape)({
14
14
  onFocus: _propTypes.func,
15
15
  value: (0, _propTypes.oneOfType)([_propTypes.array, _propTypes.bool, _propTypes.number, _propTypes.object, _propTypes.string])
16
16
  });
17
- exports.inputPropTypes = inputPropTypes;
18
- var metaPropTypes = (0, _propTypes.shape)({
17
+ const metaPropTypes = exports.metaPropTypes = (0, _propTypes.shape)({
19
18
  active: _propTypes.bool,
20
19
  asyncValidating: _propTypes.bool,
21
20
  autofilled: _propTypes.bool,
@@ -31,8 +30,7 @@ var metaPropTypes = (0, _propTypes.shape)({
31
30
  valid: _propTypes.bool,
32
31
  visited: _propTypes.bool
33
32
  });
34
- exports.metaPropTypes = metaPropTypes;
35
- var fieldType = (0, _propTypes.shape)({
33
+ const fieldType = exports.fieldType = (0, _propTypes.shape)({
36
34
  id: _propTypes.number,
37
35
  type: _propTypes.string,
38
36
  order: _propTypes.number,
@@ -73,5 +71,4 @@ var fieldType = (0, _propTypes.shape)({
73
71
  editable: _propTypes.bool,
74
72
  linked_default_value_key: _propTypes.string,
75
73
  external_field_options: _propTypes.bool
76
- });
77
- exports.fieldType = fieldType;
74
+ });
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.columnsType = void 0;
7
7
  var _propTypes = require("prop-types");
8
- var columnsType = (0, _propTypes.arrayOf)((0, _propTypes.shape)({
8
+ const columnsType = exports.columnsType = (0, _propTypes.arrayOf)((0, _propTypes.shape)({
9
9
  key: _propTypes.string.isRequired,
10
10
  label: _propTypes.string,
11
11
  headerRender: _propTypes.node,
@@ -13,5 +13,4 @@ var columnsType = (0, _propTypes.arrayOf)((0, _propTypes.shape)({
13
13
  sortable: _propTypes.bool,
14
14
  sortKey: _propTypes.string,
15
15
  align: _propTypes.string
16
- }));
17
- exports.columnsType = columnsType;
16
+ }));
@@ -4,23 +4,15 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.withImportant = exports.mergeClasses = void 0;
7
- function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
8
- function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
9
- function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
10
- function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
11
- function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
12
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
13
- var mergeClasses = function mergeClasses(themeClasses, classNames) {
7
+ const mergeClasses = (themeClasses, classNames) => {
14
8
  if (!classNames) return themeClasses;
15
- var classes = {};
16
- var allClassNames = [].concat(_toConsumableArray(Object.keys(classNames)), _toConsumableArray(Object.keys(themeClasses)));
17
- allClassNames.forEach(function (name) {
9
+ const classes = {};
10
+ const allClassNames = [...Object.keys(classNames), ...Object.keys(themeClasses)];
11
+ allClassNames.forEach(name => {
18
12
  classes[name] = "".concat(themeClasses[name] || '', " ").concat(classNames[name] || '').trim();
19
13
  });
20
14
  return classes;
21
15
  };
22
16
  exports.mergeClasses = mergeClasses;
23
- var withImportant = function withImportant(style) {
24
- return style && "".concat(style, " !important");
25
- };
17
+ const withImportant = style => style && "".concat(style, " !important");
26
18
  exports.withImportant = withImportant;
@@ -4,20 +4,17 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
- var A_CHAR_CODE = 65;
8
- var Z_CHAR_CODE = 90;
9
- var getFirstLetter = function getFirstLetter(userName) {
10
- return (userName === null || userName === void 0 ? void 0 : userName.trim().slice(0, 1).toUpperCase()) || 'A';
11
- };
12
- var getAvatarColors = function getAvatarColors(userName, colors) {
13
- var hashIndex = (userName === null || userName === void 0 ? void 0 : userName.split('').reduce(function (acum, _letter, index) {
14
- var letterCode = userName.toUpperCase().charCodeAt(index);
7
+ const A_CHAR_CODE = 65;
8
+ const Z_CHAR_CODE = 90;
9
+ const getFirstLetter = userName => (userName === null || userName === void 0 ? void 0 : userName.trim().slice(0, 1).toUpperCase()) || 'A';
10
+ const getAvatarColors = (userName, colors) => {
11
+ const hashIndex = (userName === null || userName === void 0 ? void 0 : userName.split('').reduce((acum, _letter, index) => {
12
+ const letterCode = userName.toUpperCase().charCodeAt(index);
15
13
  return letterCode >= A_CHAR_CODE && letterCode <= Z_CHAR_CODE ? acum + letterCode - A_CHAR_CODE + 1 : acum;
16
14
  }, 0)) || 0;
17
15
  return colors[hashIndex % colors.length];
18
16
  };
19
- var _default = {
20
- getFirstLetter: getFirstLetter,
21
- getAvatarColors: getAvatarColors
22
- };
23
- exports.default = _default;
17
+ var _default = exports.default = {
18
+ getFirstLetter,
19
+ getAvatarColors
20
+ };
@@ -4,17 +4,17 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.throttle = void 0;
7
- var throttle = function throttle(func, limit) {
8
- var inThrottle;
7
+ const throttle = (func, limit) => {
8
+ let inThrottle;
9
9
  return function throttled() {
10
- var context = this;
10
+ const context = this;
11
11
  if (!inThrottle) {
12
12
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
13
13
  args[_key] = arguments[_key];
14
14
  }
15
15
  func.apply(context, args);
16
16
  inThrottle = true;
17
- setTimeout(function () {
17
+ setTimeout(() => {
18
18
  inThrottle = false;
19
19
  }, limit);
20
20
  }
@@ -4,14 +4,14 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.getShadow = void 0;
7
- var defaultOrientation = 'bottom';
8
- var defaultLevel = 1;
9
- var levels = {
7
+ const defaultOrientation = 'bottom';
8
+ const defaultLevel = 1;
9
+ const levels = {
10
10
  1: 6,
11
11
  2: 12,
12
12
  3: 24
13
13
  };
14
- var orientations = {
14
+ const orientations = {
15
15
  bottom: {
16
16
  1: 3,
17
17
  2: 6,
@@ -28,13 +28,15 @@ var orientations = {
28
28
  3: -24
29
29
  }
30
30
  };
31
- var getShadow = function getShadow(_ref) {
32
- var color = _ref.color,
33
- level = _ref.level,
34
- orientation = _ref.orientation;
35
- var shadowLevel = levels[level] || levels[defaultLevel];
36
- var shadowOrientation = orientations[orientation] || orientations[defaultOrientation];
37
- var shadowOrientationLevel = shadowOrientation[level] || shadowOrientation[defaultLevel];
31
+ const getShadow = _ref => {
32
+ let {
33
+ color,
34
+ level,
35
+ orientation
36
+ } = _ref;
37
+ const shadowLevel = levels[level] || levels[defaultLevel];
38
+ const shadowOrientation = orientations[orientation] || orientations[defaultOrientation];
39
+ const shadowOrientationLevel = shadowOrientation[level] || shadowOrientation[defaultLevel];
38
40
  return "0 ".concat(shadowOrientationLevel, "px ").concat(shadowLevel, "px 0 ").concat(color);
39
41
  };
40
42
  exports.getShadow = getShadow;
@@ -5,8 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.useScreenSize = void 0;
7
7
  var _energyHooks = require("@widergy/energy-hooks");
8
- var useScreenSize = (0, _energyHooks.createUseScreenSize)({
8
+ const useScreenSize = exports.useScreenSize = (0, _energyHooks.createUseScreenSize)({
9
9
  mobileBP: 767,
10
10
  tabletBP: 1024
11
- });
12
- exports.useScreenSize = useScreenSize;
11
+ });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@widergy/energy-ui",
3
- "version": "2.12.2",
3
+ "version": "2.12.3",
4
4
  "description": "Widergy Web Components",
5
5
  "author": "widergy",
6
6
  "license": "MIT",