@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.
Files changed (256) 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 +9 -11
  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 +29 -31
  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 +153 -232
  11. package/dist/components/UTAttachment/layout.js +25 -26
  12. package/dist/components/UTAttachment/theme.js +12 -14
  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 +45 -66
  18. package/dist/components/UTAutocomplete/theme.js +3 -3
  19. package/dist/components/UTAvatar/constants.js +2 -3
  20. package/dist/components/UTAvatar/index.js +15 -12
  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 +73 -91
  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 +24 -31
  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 +148 -162
  48. package/dist/components/UTBarChart/theme.js +102 -104
  49. package/dist/components/UTBarChart/types.js +9 -17
  50. package/dist/components/UTBarChart/utils.js +107 -111
  51. package/dist/components/UTBreadcrumbs/constants.js +3 -6
  52. package/dist/components/UTBreadcrumbs/index.js +79 -106
  53. package/dist/components/UTBreadcrumbs/theme.js +21 -23
  54. package/dist/components/UTButton/index.js +48 -71
  55. package/dist/components/UTButton/theme.js +172 -174
  56. package/dist/components/UTCBUInput/index.js +36 -40
  57. package/dist/components/UTCBUInput/theme.js +5 -7
  58. package/dist/components/UTCaptcha/index.js +19 -45
  59. package/dist/components/UTCard/components/UTCardFooter/index.js +16 -17
  60. package/dist/components/UTCard/index.js +87 -122
  61. package/dist/components/UTCard/theme.js +8 -11
  62. package/dist/components/UTCard/types.js +2 -3
  63. package/dist/components/UTCarousel/components/Button/index.js +13 -13
  64. package/dist/components/UTCarousel/components/Legend/index.js +14 -16
  65. package/dist/components/UTCarousel/components/Slider/component/Slide/index.js +16 -16
  66. package/dist/components/UTCarousel/components/Slider/constants.js +5 -10
  67. package/dist/components/UTCarousel/components/Slider/index.js +181 -252
  68. package/dist/components/UTCarousel/components/Slider/layout.js +66 -93
  69. package/dist/components/UTCarousel/index.js +14 -15
  70. package/dist/components/UTCarousel/theme.js +35 -37
  71. package/dist/components/UTCheckList/constants.js +1 -2
  72. package/dist/components/UTCheckList/index.js +72 -91
  73. package/dist/components/UTCheckList/theme.js +66 -70
  74. package/dist/components/UTCheckbox/constants.js +3 -6
  75. package/dist/components/UTCheckbox/index.js +31 -42
  76. package/dist/components/UTCheckbox/theme.js +49 -53
  77. package/dist/components/UTConsumptionBar/components/ConsumptionBarIndicator/index.js +9 -9
  78. package/dist/components/UTConsumptionBar/constants.js +3 -6
  79. package/dist/components/UTConsumptionBar/index.js +49 -74
  80. package/dist/components/UTCuit/index.js +109 -133
  81. package/dist/components/UTCuit/theme.js +47 -49
  82. package/dist/components/UTDatePicker/components/Day/constants.js +1 -2
  83. package/dist/components/UTDatePicker/components/Day/index.js +12 -12
  84. package/dist/components/UTDatePicker/constants.js +20 -31
  85. package/dist/components/UTDatePicker/index.js +59 -101
  86. package/dist/components/UTDatePicker/theme.js +173 -177
  87. package/dist/components/UTDatePicker/types.js +2 -3
  88. package/dist/components/UTDatePicker/utils.js +2 -6
  89. package/dist/components/UTDialog/components/ActionButton/index.js +10 -9
  90. package/dist/components/UTDialog/constants.js +2 -4
  91. package/dist/components/UTDialog/index.js +39 -38
  92. package/dist/components/UTDialog/theme.js +93 -95
  93. package/dist/components/UTDialog/types.js +2 -3
  94. package/dist/components/UTDotMenu/index.js +33 -57
  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 +1 -1
  98. package/dist/components/UTEmojiPicker/utils.js +21 -51
  99. package/dist/components/UTExternalLink/index.js +17 -14
  100. package/dist/components/UTFileInput/constants.js +2 -4
  101. package/dist/components/UTFileInput/index.js +7 -31
  102. package/dist/components/UTFileInput/layout.js +67 -96
  103. package/dist/components/UTIconButton/index.js +49 -72
  104. package/dist/components/UTIconButton/theme.js +53 -55
  105. package/dist/components/UTImageRadio/components/ImageRadioCard/index.js +53 -58
  106. package/dist/components/UTImageRadio/constants.js +3 -6
  107. package/dist/components/UTImageRadio/index.js +39 -47
  108. package/dist/components/UTImageRadio/theme.js +8 -11
  109. package/dist/components/UTImageRadio/types.js +2 -3
  110. package/dist/components/UTImageRadio/utils.js +2 -6
  111. package/dist/components/UTLabel/index.js +69 -90
  112. package/dist/components/UTLabel/theme.js +84 -86
  113. package/dist/components/UTList/index.js +15 -18
  114. package/dist/components/UTLoading/index.js +15 -15
  115. package/dist/components/UTMap/components/GoogleMaps/constants.js +8 -11
  116. package/dist/components/UTMap/components/GoogleMaps/index.js +63 -91
  117. package/dist/components/UTMap/components/GoogleMaps/styles.js +2 -3
  118. package/dist/components/UTMap/constants.js +6 -12
  119. package/dist/components/UTMap/index.js +163 -198
  120. package/dist/components/UTMap/types.js +4 -6
  121. package/dist/components/UTMap/utils.js +29 -46
  122. package/dist/components/UTMap/withGoogleMapScript.js +12 -17
  123. package/dist/components/UTMenu/index.js +52 -69
  124. package/dist/components/UTMenu/theme.js +2 -2
  125. package/dist/components/UTMenu/utils.js +5 -11
  126. package/dist/components/UTPagination/theme.js +4 -2
  127. package/dist/components/UTPanel/index.js +38 -44
  128. package/dist/components/UTPasswordField/components/PasswordValidations/components/Error/index.js +14 -11
  129. package/dist/components/UTPasswordField/components/PasswordValidations/components/Validation/index.js +24 -21
  130. package/dist/components/UTPasswordField/components/PasswordValidations/index.js +63 -50
  131. package/dist/components/UTPasswordField/components/PasswordWarning/index.js +26 -27
  132. package/dist/components/UTPasswordField/index.js +26 -23
  133. package/dist/components/UTPasswordField/theme.js +37 -39
  134. package/dist/components/UTPhoneInput/constants.js +3 -6
  135. package/dist/components/UTPhoneInput/index.js +180 -205
  136. package/dist/components/UTPhoneInput/theme.js +109 -113
  137. package/dist/components/UTPieChart/components/ArrowLabel/constants.js +4 -8
  138. package/dist/components/UTPieChart/components/ArrowLabel/index.js +24 -23
  139. package/dist/components/UTPieChart/components/Legend/contants.js +3 -6
  140. package/dist/components/UTPieChart/components/Legend/index.js +27 -24
  141. package/dist/components/UTPieChart/constants.js +13 -26
  142. package/dist/components/UTPieChart/hooks/use-animated-value/index.js +15 -33
  143. package/dist/components/UTPieChart/index.js +73 -76
  144. package/dist/components/UTPieChart/theme.js +23 -25
  145. package/dist/components/UTPieChart/utils.js +4 -2
  146. package/dist/components/UTProgressBar/constants.js +2 -4
  147. package/dist/components/UTProgressBar/index.js +12 -11
  148. package/dist/components/UTProgressBar/theme.js +25 -27
  149. package/dist/components/UTProgressBar/types.js +2 -3
  150. package/dist/components/UTRadioGroup/index.js +45 -71
  151. package/dist/components/UTRadioGroup/theme.js +82 -86
  152. package/dist/components/UTRating/components/Circle/index.js +41 -56
  153. package/dist/components/UTRating/components/Faces/constants.js +2 -4
  154. package/dist/components/UTRating/components/Faces/index.js +34 -36
  155. package/dist/components/UTRating/components/Star/index.js +36 -40
  156. package/dist/components/UTRating/constants.js +4 -8
  157. package/dist/components/UTRating/index.js +31 -46
  158. package/dist/components/UTRating/theme.js +77 -79
  159. package/dist/components/UTRipple/Ripple.js +22 -39
  160. package/dist/components/UTRipple/index.js +18 -37
  161. package/dist/components/UTSelect/components/Option/index.js +13 -13
  162. package/dist/components/UTSelect/constants.js +4 -8
  163. package/dist/components/UTSelect/index.js +61 -81
  164. package/dist/components/UTSelect/stylesJS.js +2 -3
  165. package/dist/components/UTSelect/theme.js +43 -45
  166. package/dist/components/UTSelect/utils.js +3 -13
  167. package/dist/components/UTSidebar/components/ListOption/index.js +32 -47
  168. package/dist/components/UTSidebar/components/LogosContainer/components/DynamicIcon/index.js +8 -8
  169. package/dist/components/UTSidebar/components/LogosContainer/index.js +14 -14
  170. package/dist/components/UTSidebar/components/Option/constants.js +2 -3
  171. package/dist/components/UTSidebar/components/Option/index.js +28 -32
  172. package/dist/components/UTSidebar/components/Toggler/index.js +11 -11
  173. package/dist/components/UTSidebar/index.js +42 -53
  174. package/dist/components/UTSidebar/theme.js +1 -1
  175. package/dist/components/UTSidebar/types.js +5 -10
  176. package/dist/components/UTSkeleton/index.js +10 -36
  177. package/dist/components/UTSwitch/constants.js +3 -6
  178. package/dist/components/UTSwitch/index.js +42 -57
  179. package/dist/components/UTSwitch/theme.js +115 -117
  180. package/dist/components/UTTable/components/ActionIcons/constants.js +1 -2
  181. package/dist/components/UTTable/components/ActionIcons/index.js +44 -81
  182. package/dist/components/UTTable/components/Cell/index.js +18 -23
  183. package/dist/components/UTTable/components/HeaderCell/constants.js +2 -3
  184. package/dist/components/UTTable/components/HeaderCell/index.js +23 -30
  185. package/dist/components/UTTable/components/HeaderCell/utils.js +3 -3
  186. package/dist/components/UTTable/components/PrimaryAction/index.js +12 -11
  187. package/dist/components/UTTable/components/ResponsiveCell/index.js +19 -20
  188. package/dist/components/UTTable/components/Status/index.js +18 -19
  189. package/dist/components/UTTable/components/TableFooter/components/PageSizeSelector/index.js +10 -9
  190. package/dist/components/UTTable/components/TableFooter/components/PageSizeSelector/utils.js +7 -13
  191. package/dist/components/UTTable/components/TableFooter/components/Pagination/components/NavigationButton/index.js +12 -12
  192. package/dist/components/UTTable/components/TableFooter/components/Pagination/index.js +21 -32
  193. package/dist/components/UTTable/components/TableFooter/components/Pagination/utils.js +8 -14
  194. package/dist/components/UTTable/components/TableFooter/constants.js +1 -2
  195. package/dist/components/UTTable/components/TableFooter/index.js +15 -15
  196. package/dist/components/UTTable/components/TableHeader/index.js +11 -11
  197. package/dist/components/UTTable/components/TableRow/constants.js +3 -6
  198. package/dist/components/UTTable/components/TableRow/index.js +79 -94
  199. package/dist/components/UTTable/constants.js +26 -43
  200. package/dist/components/UTTable/hook.js +11 -26
  201. package/dist/components/UTTable/index.js +125 -213
  202. package/dist/components/UTTable/theme.js +13 -16
  203. package/dist/components/UTTable/types.js +4 -8
  204. package/dist/components/UTTable/utils.js +70 -74
  205. package/dist/components/UTTabs/components/TooltipTab/index.js +20 -30
  206. package/dist/components/UTTabs/constants.js +4 -8
  207. package/dist/components/UTTabs/index.js +55 -84
  208. package/dist/components/UTTabs/theme.js +112 -114
  209. package/dist/components/UTTabs/utils.js +1 -1
  210. package/dist/components/UTTextArea/constants.js +4 -6
  211. package/dist/components/UTTextArea/index.js +40 -24
  212. package/dist/components/UTTextArea/styles.module.scss +20 -1
  213. package/dist/components/UTTextArea/theme.js +1 -1
  214. package/dist/components/UTTextInput/constants.js +2 -3
  215. package/dist/components/UTTextInput/index.js +116 -146
  216. package/dist/components/UTTextInput/theme.js +28 -30
  217. package/dist/components/UTThirdPartyCookieChecker/index.js +17 -21
  218. package/dist/components/UTToggle/components/ToggleOption/index.js +16 -17
  219. package/dist/components/UTToggle/index.js +25 -26
  220. package/dist/components/UTToggle/theme.js +47 -49
  221. package/dist/components/UTTooltip/index.js +23 -30
  222. package/dist/components/UTTooltip/theme.js +1 -1
  223. package/dist/components/UTTopbar/theme.js +4 -2
  224. package/dist/components/UTTouchableWithoutFeedback/index.js +14 -27
  225. package/dist/components/UTVirtualizedList/components/VirtualizedData/components/ListRow/constants.js +2 -4
  226. package/dist/components/UTVirtualizedList/components/VirtualizedData/components/ListRow/index.js +34 -31
  227. package/dist/components/UTVirtualizedList/components/VirtualizedData/components/ListRow/utils.js +4 -4
  228. package/dist/components/UTVirtualizedList/components/VirtualizedData/constants.js +6 -12
  229. package/dist/components/UTVirtualizedList/components/VirtualizedData/hooks/use-ledger.js +8 -18
  230. package/dist/components/UTVirtualizedList/components/VirtualizedData/hooks/use-virtualized-data.js +23 -47
  231. package/dist/components/UTVirtualizedList/components/VirtualizedData/index.js +31 -34
  232. package/dist/components/UTVirtualizedList/components/VirtualizedData/utils.js +81 -93
  233. package/dist/components/UTVirtualizedList/constants.js +4 -8
  234. package/dist/components/UTVirtualizedList/index.js +26 -38
  235. package/dist/components/UTWorkflowContainer/components/ActionButton/index.js +11 -11
  236. package/dist/components/UTWorkflowContainer/constants.js +5 -9
  237. package/dist/components/UTWorkflowContainer/hooks/use-previous.js +3 -3
  238. package/dist/components/UTWorkflowContainer/index.js +31 -50
  239. package/dist/components/UTWorkflowContainer/theme.js +70 -64
  240. package/dist/components/UTWorkflowContainer/types.js +2 -3
  241. package/dist/components/WithLoading/index.js +10 -15
  242. package/dist/components/WithTheme/index.js +10 -17
  243. package/dist/components/WithTheme/layout.js +18 -41
  244. package/dist/components/WithTouch/index.js +12 -19
  245. package/dist/index.js +54 -54
  246. package/dist/scss/variables/colors.module.scss +1 -0
  247. package/dist/theme.js +5 -3
  248. package/dist/types/commonTypes.js +3 -5
  249. package/dist/types/consumptionTypes.js +3 -5
  250. package/dist/types/formTypes.js +4 -7
  251. package/dist/types/tableTypes.js +2 -3
  252. package/dist/utils/classesUtils.js +4 -10
  253. package/dist/utils/componentUtils.js +10 -13
  254. package/dist/utils/helperFunctions.js +4 -4
  255. package/dist/utils/useScreenSize.js +2 -3
  256. package/package.json +1 -1
@@ -22,31 +22,12 @@ var _types = require("./types");
22
22
  var _constants = require("./constants");
23
23
  var _utils = require("./utils");
24
24
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
25
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
26
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
27
- function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
25
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
26
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
28
27
  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); }
29
- function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
30
- function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
31
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
32
- function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
33
- 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); }
34
- 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; }
35
- function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
36
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
37
- function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
38
- function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
39
- function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
40
- function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
41
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
42
- function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
43
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
44
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
45
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
46
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
47
28
  function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
48
- function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
49
- function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
29
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
30
+ function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
50
31
  var CalendarIcon = function CalendarIcon(props) {
51
32
  return /*#__PURE__*/_react.default.createElement("svg", props, /*#__PURE__*/_react.default.createElement("defs", null, /*#__PURE__*/_react.default.createElement("path", {
52
33
  d: "M8 15c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1Zm8 0c.55 0 1 .45 1 1s-.45 1-1 1h-4c-.55 0-1-.45-1-1s.45-1 1-1Zm2 5H6c-.551 0-1-.449-1-1v-6h14v6c0 .551-.449 1-1 1M6 6h1v1c0 .55.45 1 1 1s1-.45 1-1V6h6v1c0 .55.45 1 1 1s1-.45 1-1V6h1c.551 0 1 .449 1 1v4H5V7c0-.551.449-1 1-1m12-2h-1V3c0-.55-.45-1-1-1s-1 .45-1 1v1H9V3c0-.55-.45-1-1-1s-1 .45-1 1v1H6C4.346 4 3 5.346 3 7v12c0 1.654 1.346 3 3 3h12c1.654 0 3-1.346 3-3V7c0-1.654-1.346-3-3-3",
@@ -65,85 +46,59 @@ CalendarIcon.defaultProps = {
65
46
  xmlnsXlink: "http://www.w3.org/1999/xlink"
66
47
  };
67
48
  _dayjs2.default.extend(_customParseFormat.default);
68
- var CustomUtils = /*#__PURE__*/function (_DayjsUtils) {
69
- _inherits(CustomUtils, _DayjsUtils);
70
- var _super = _createSuper(CustomUtils);
71
- function CustomUtils() {
72
- var _this;
73
- _classCallCheck(this, CustomUtils);
74
- for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
75
- args[_key] = arguments[_key];
76
- }
77
- _this = _super.call.apply(_super, [this].concat(args));
78
- _defineProperty(_assertThisInitialized(_this), "getCalendarHeaderText", function (date) {
79
- return date.format('MMMM');
80
- });
81
- return _this;
49
+ class CustomUtils extends _dayjs.default {
50
+ constructor() {
51
+ super(...arguments);
52
+ _defineProperty(this, "getCalendarHeaderText", date => date.format('MMMM'));
82
53
  }
83
- return _createClass(CustomUtils);
84
- }(_dayjs.default);
85
- var UTDatePicker = function UTDatePicker(_ref) {
54
+ }
55
+ const UTDatePicker = _ref => {
86
56
  var _field$configuration;
87
- var input = _ref.input,
88
- _ref$meta = _ref.meta,
89
- meta = _ref$meta === void 0 ? {} : _ref$meta,
90
- field = _ref.field,
91
- themeClasses = _ref.classes,
92
- classNames = _ref.classNames,
93
- CustomIcon = _ref.CustomIcon,
94
- dayFormat = _ref.dayFormat,
95
- pickerProps = _ref.pickerProps,
96
- inputProps = _ref.inputProps,
97
- popoverProps = _ref.popoverProps,
98
- placeholder = _ref.placeholder,
99
- _ref$disableToolbar = _ref.disableToolbar,
100
- disableToolbar = _ref$disableToolbar === void 0 ? true : _ref$disableToolbar,
101
- _ref$inputVariant = _ref.inputVariant,
102
- inputVariant = _ref$inputVariant === void 0 ? _constants.INPUT_VARIANT : _ref$inputVariant,
103
- maxDateMessage = _ref.maxDateMessage,
104
- minDateMessage = _ref.minDateMessage,
105
- invalidDateMessage = _ref.invalidDateMessage,
106
- variant = _ref.variant,
107
- iconAnchor = _ref.iconAnchor,
108
- withUpperTitle = _ref.withUpperTitle,
109
- disabled = _ref.disabled;
110
- var classes = (0, _react.useMemo)(function () {
111
- return (0, _classesUtils.mergeClasses)(themeClasses, classNames);
112
- }, [classNames]);
113
- var configMask = (field === null || field === void 0 || (_field$configuration = field.configuration) === null || _field$configuration === void 0 ? void 0 : _field$configuration.date_mask) || _constants.OUTPUT_LABEL_MASK;
114
- var _useState = (0, _react.useState)(null),
115
- _useState2 = _slicedToArray(_useState, 2),
116
- pickedDate = _useState2[0],
117
- setPickedDate = _useState2[1];
118
- var _useState3 = (0, _react.useState)(null),
119
- _useState4 = _slicedToArray(_useState3, 2),
120
- internalError = _useState4[0],
121
- setInternalError = _useState4[1];
122
- var handleChange = function handleChange(date) {
57
+ let {
58
+ input,
59
+ meta = {},
60
+ field,
61
+ classes: themeClasses,
62
+ classNames,
63
+ CustomIcon,
64
+ dayFormat,
65
+ pickerProps,
66
+ inputProps,
67
+ popoverProps,
68
+ placeholder,
69
+ disableToolbar = true,
70
+ inputVariant = _constants.INPUT_VARIANT,
71
+ maxDateMessage,
72
+ minDateMessage,
73
+ invalidDateMessage,
74
+ variant,
75
+ iconAnchor,
76
+ withUpperTitle,
77
+ disabled
78
+ } = _ref;
79
+ const classes = (0, _react.useMemo)(() => (0, _classesUtils.mergeClasses)(themeClasses, classNames), [classNames]);
80
+ const configMask = (field === null || field === void 0 || (_field$configuration = field.configuration) === null || _field$configuration === void 0 ? void 0 : _field$configuration.date_mask) || _constants.OUTPUT_LABEL_MASK;
81
+ const [pickedDate, setPickedDate] = (0, _react.useState)(null);
82
+ const [internalError, setInternalError] = (0, _react.useState)(null);
83
+ const handleChange = date => {
123
84
  setPickedDate(date);
124
- var newValue = (0, _dayjs2.default)(date, _constants.OUTPUT_LABEL_MASK, true);
85
+ const newValue = (0, _dayjs2.default)(date, _constants.OUTPUT_LABEL_MASK, true);
125
86
  if (newValue.isValid()) input.onChange(newValue.format(configMask));else input.onChange('');
126
87
  };
127
- (0, _react.useEffect)(function () {
88
+ (0, _react.useEffect)(() => {
128
89
  if (!input.value && pickedDate !== null && pickedDate !== void 0 && pickedDate.isValid()) setPickedDate(null);else if ((0, _utils.dateMatchesFormat)(input.value, configMask)) setPickedDate((0, _dayjs2.default)(input.value, configMask));
129
90
  }, [input.value]);
130
- var renderDay = function renderDay(date, _, dayInCurrentMonth) {
131
- return /*#__PURE__*/_react.default.createElement(_Day.default, {
132
- classes: classes,
133
- dayFormat: dayFormat,
134
- date: date,
135
- pickedDate: pickedDate,
136
- dayInCurrentMonth: dayInCurrentMonth
137
- });
138
- };
139
- var handleError = function handleError(error) {
140
- return setInternalError(error);
141
- };
142
- var handleRemoveError = function handleRemoveError() {
143
- return setInternalError(null);
144
- };
145
- var OpenerIcon = CustomIcon || CalendarIcon;
146
- var operenerIconReference = (0, _react.useRef)();
91
+ const renderDay = (date, _, dayInCurrentMonth) => /*#__PURE__*/_react.default.createElement(_Day.default, {
92
+ classes: classes,
93
+ dayFormat: dayFormat,
94
+ date: date,
95
+ pickedDate: pickedDate,
96
+ dayInCurrentMonth: dayInCurrentMonth
97
+ });
98
+ const handleError = error => setInternalError(error);
99
+ const handleRemoveError = () => setInternalError(null);
100
+ const OpenerIcon = CustomIcon || CalendarIcon;
101
+ const operenerIconReference = (0, _react.useRef)();
147
102
  return /*#__PURE__*/_react.default.createElement(_react.Fragment, null, withUpperTitle && /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
148
103
  className: classes.upperTitle
149
104
  }, field.title), /*#__PURE__*/_react.default.createElement(_pickers.MuiPickersUtilsProvider, {
@@ -164,13 +119,14 @@ var UTDatePicker = function UTDatePicker(_ref) {
164
119
  className: disabled ? classes.disabledOpenerIcon : classes.openerIcon
165
120
  })),
166
121
  variant: variant || _constants.VARIANT,
167
- InputProps: _objectSpread({
122
+ InputProps: {
168
123
  classes: {
169
124
  root: classes.input,
170
125
  notchedOutline: classes.notchedOutline
171
126
  },
172
- placeholder: inputVariant === 'outlined' && (placeholder || (field === null || field === void 0 ? void 0 : field.placeholder))
173
- }, inputProps),
127
+ placeholder: inputVariant === 'outlined' && (placeholder || (field === null || field === void 0 ? void 0 : field.placeholder)),
128
+ ...inputProps
129
+ },
174
130
  invalidDateMessage: invalidDateMessage || _constants.WRONG_DATE_FORMAT,
175
131
  inputVariant: inputVariant,
176
132
  format: _constants.OUTPUT_LABEL_MASK,
@@ -181,7 +137,10 @@ var UTDatePicker = function UTDatePicker(_ref) {
181
137
  },
182
138
  onChange: handleChange,
183
139
  renderDay: renderDay,
184
- PopoverProps: _objectSpread(_objectSpread({}, iconAnchor ? (0, _constants.iconAnchorProps)(operenerIconReference) : {}), popoverProps)
140
+ PopoverProps: {
141
+ ...(iconAnchor ? (0, _constants.iconAnchorProps)(operenerIconReference) : {}),
142
+ ...popoverProps
143
+ }
185
144
  }, pickerProps))));
186
145
  };
187
146
  UTDatePicker.propTypes = {
@@ -206,5 +165,4 @@ UTDatePicker.propTypes = {
206
165
  withUpperTitle: _propTypes.bool,
207
166
  iconAnchor: _propTypes.bool
208
167
  };
209
- var _default = (0, _WithTheme.default)(_theme.retrieveStyle, _theme.materialTheme)(UTDatePicker);
210
- exports.default = _default;
168
+ var _default = exports.default = (0, _WithTheme.default)(_theme.retrieveStyle, _theme.materialTheme)(UTDatePicker);
@@ -8,202 +8,198 @@ var _seamlessImmutable = require("seamless-immutable");
8
8
  var _core = require("@material-ui/core");
9
9
  var _colorsModule = _interopRequireDefault(require("../../scss/variables/colors.module.scss"));
10
10
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
11
- var retrieveStyle = function retrieveStyle(theme) {
12
- return {
13
- openerIcon: {
14
- fill: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'openerIcon', 'fill'], _colorsModule.default.orangeIcon)
11
+ const retrieveStyle = theme => ({
12
+ openerIcon: {
13
+ fill: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'openerIcon', 'fill'], _colorsModule.default.orangeIcon)
14
+ },
15
+ disabledOpenerIcon: {
16
+ fill: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'disabledOpenerIcon', 'fill'], _colorsModule.default.gray)
17
+ },
18
+ day: {
19
+ fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily'])),
20
+ fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'fontSize'], '14px'),
21
+ height: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'height'], '34px'),
22
+ margin: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'margin'], '0 1px'),
23
+ fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'fontWeight'], 500),
24
+ width: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'width'], '35px'),
25
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'color'], _colorsModule.default.gray4)
26
+ },
27
+ otherMonthDay: {
28
+ visibility: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'otherMonthDay', 'visibility'], 'hidden')
29
+ },
30
+ selectedDay: {
31
+ backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'backgroundColor'], _colorsModule.default.lightBlue),
32
+ '&:hover': {
33
+ backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'backgroundColor'], _colorsModule.default.blue)
15
34
  },
16
- disabledOpenerIcon: {
17
- fill: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'disabledOpenerIcon', 'fill'], _colorsModule.default.gray)
18
- },
19
- day: {
20
- fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily'])),
21
- fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'fontSize'], '14px'),
22
- height: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'height'], '34px'),
23
- margin: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'margin'], '0 1px'),
24
- fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'fontWeight'], 500),
25
- width: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'width'], '35px'),
26
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'day', 'color'], _colorsModule.default.gray4)
35
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'color'], _colorsModule.default.white),
36
+ padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'padding'], '1px 1px'),
37
+ backgroundClip: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'backgroundClip'], 'contentBox')
38
+ },
39
+ upperTitle: {
40
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'upperTitle', 'color'], _colorsModule.default.black),
41
+ fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'upperTitle', 'fontWeight']),
42
+ marginBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'upperTitle', 'marginBottom'])
43
+ }
44
+ });
45
+ exports.retrieveStyle = retrieveStyle;
46
+ const materialTheme = theme => (0, _core.createMuiTheme)({
47
+ overrides: {
48
+ MuiTypography: {
49
+ body1: {
50
+ fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'input', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily']))
51
+ }
27
52
  },
28
- otherMonthDay: {
29
- visibility: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'otherMonthDay', 'visibility'], 'hidden')
53
+ MuiToolbar: {
54
+ regular: {
55
+ minHeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'minHeight'], '0px !important')
56
+ }
30
57
  },
31
- selectedDay: {
32
- backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'backgroundColor'], _colorsModule.default.lightBlue),
33
- '&:hover': {
34
- backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'backgroundColor'], _colorsModule.default.blue)
35
- },
36
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'color'], _colorsModule.default.white),
37
- padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'padding'], '1px 1px'),
38
- backgroundClip: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'selectedDay', 'backgroundClip'], 'contentBox')
58
+ MuiPickersToolbar: {
59
+ toolbar: {
60
+ height: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'height'], 'fit-content'),
61
+ padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'padding'], '8px 12px 8px 12px'),
62
+ borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'borderRadious'], '4px'),
63
+ margin: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'margin'], '16px 16px 0px 16px'),
64
+ backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'backgroundColor'], _colorsModule.default.gray3)
65
+ }
39
66
  },
40
- upperTitle: {
41
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'upperTitle', 'color'], _colorsModule.default.black),
42
- fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'upperTitle', 'fontWeight']),
43
- marginBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'upperTitle', 'marginBottom'])
44
- }
45
- };
46
- };
47
- exports.retrieveStyle = retrieveStyle;
48
- var materialTheme = function materialTheme(theme) {
49
- return (0, _core.createMuiTheme)({
50
- overrides: {
51
- MuiTypography: {
52
- body1: {
53
- fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'input', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily']))
67
+ MuiPickersToolbarButton: {
68
+ toolbarBtn: {
69
+ alignSelf: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'alignSelf'], 'center'),
70
+ '&:not(:first-child)': {
71
+ display: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'displayDate'], 'none')
54
72
  }
73
+ }
74
+ },
75
+ MuiPickersToolbarText: {
76
+ toolbarTxt: {
77
+ fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'fontWeight'], '500'),
78
+ fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'fontSize'], '16px'),
79
+ lineHeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'lineHeight'], '22px'),
80
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'textColor'], _colorsModule.default.black)
55
81
  },
56
- MuiToolbar: {
57
- regular: {
58
- minHeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'minHeight'], '0px !important')
59
- }
82
+ toolbarBtnSelected: {
83
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'textColor'], _colorsModule.default.black)
84
+ }
85
+ },
86
+ MuiPickersYear: {
87
+ yearSelected: {
88
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'textColor'], _colorsModule.default.black),
89
+ marginLeft: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'year', 'marginLeft'], '10px')
60
90
  },
61
- MuiPickersToolbar: {
62
- toolbar: {
63
- height: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'height'], 'fit-content'),
64
- padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'padding'], '8px 12px 8px 12px'),
65
- borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'borderRadious'], '4px'),
66
- margin: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'margin'], '16px 16px 0px 16px'),
67
- backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'backgroundColor'], _colorsModule.default.gray3)
68
- }
91
+ root: {
92
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'year', 'color'], _colorsModule.default.black),
93
+ marginLeft: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'year', 'marginLeft'], '10px')
94
+ }
95
+ },
96
+ MuiPickersCalendarHeader: {
97
+ switchHeader: {
98
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'color'], _colorsModule.default.gray4),
99
+ textTransform: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'textTransform'], 'capitalize !important'),
100
+ fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'fontWeight'], "".concat(500, " !important")),
101
+ margin: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'margin'], '8px 17px'),
102
+ padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'padding'], '15px 0 0')
69
103
  },
70
- MuiPickersToolbarButton: {
71
- toolbarBtn: {
72
- alignSelf: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'alignSelf'], 'center'),
73
- '&:not(:first-child)': {
74
- display: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'displayDate'], 'none')
75
- }
76
- }
104
+ dayLabel: {
105
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'dayLabel', 'color'], _colorsModule.default.gray4),
106
+ width: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'dayLabel', 'width'], '33px'),
107
+ fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'dayLabel', 'fontWeight'], "".concat(500, " !important")),
108
+ fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'dayLabel', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily']))
77
109
  },
78
- MuiPickersToolbarText: {
79
- toolbarTxt: {
80
- fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'fontWeight'], '500'),
81
- fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'fontSize'], '16px'),
82
- lineHeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'lineHeight'], '22px'),
83
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'textColor'], _colorsModule.default.black)
110
+ daysHeader: {
111
+ marginTop: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'daysHeader', 'marginTop'], '15px')
112
+ }
113
+ },
114
+ MuiOutlinedInput: {
115
+ root: {
116
+ fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily'])),
117
+ backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'backgroundColor'], _colorsModule.default.white),
118
+ fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'fontWeight'], 500),
119
+ fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'fontSize'], '14px'),
120
+ borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'borderRadius'], '30px'),
121
+ height: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'height'], '40px'),
122
+ width: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'width'], '250px'),
123
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'color'], _colorsModule.default.gray4),
124
+ paddingLeft: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'paddingLeft'], '6px'),
125
+ paddingRight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'paddingLeft'], '12px !important'),
126
+ '&:hover:not($disabled):not($focused):not($error) $notchedOutline': {
127
+ borderColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'notchedOutline', 'hover', 'borderColor'], _colorsModule.default.gray3)
84
128
  },
85
- toolbarBtnSelected: {
86
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'textColor'], _colorsModule.default.black)
129
+ '&$focused $notchedOutline': {
130
+ borderColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'notchedOutline', 'focused', 'borderColor'], _colorsModule.default.gray3),
131
+ borderWidth: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'notchedOutline', 'focused', 'borderWidth'], 1)
87
132
  }
88
133
  },
89
- MuiPickersYear: {
90
- yearSelected: {
91
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'toolbar', 'text', 'textColor'], _colorsModule.default.black),
92
- marginLeft: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'year', 'marginLeft'], '10px')
93
- },
94
- root: {
95
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'year', 'color'], _colorsModule.default.black),
96
- marginLeft: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'year', 'marginLeft'], '10px')
97
- }
134
+ notchedOutline: {
135
+ borderColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'notchedOutline', 'borderColor'], _colorsModule.default.gray3)
136
+ }
137
+ },
138
+ MuiInput: {
139
+ input: {
140
+ border: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'border']),
141
+ borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'input', 'borderRadius']),
142
+ fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily'])),
143
+ fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'fontSize'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'medium'], 14)),
144
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'color']),
145
+ padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'padding'])
98
146
  },
99
- MuiPickersCalendarHeader: {
100
- switchHeader: {
101
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'color'], _colorsModule.default.gray4),
102
- textTransform: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'textTransform'], 'capitalize !important'),
103
- fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'fontWeight'], "".concat(500, " !important")),
104
- margin: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'margin'], '8px 17px'),
105
- padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'switchHeader', 'padding'], '15px 0 0')
147
+ underline: {
148
+ '&:hover:not($disabled):not($focused):not($error):before': {
149
+ borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'hover', 'borderBottom'], "1px solid ".concat(_colorsModule.default.gray))
106
150
  },
107
- dayLabel: {
108
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'dayLabel', 'color'], _colorsModule.default.gray4),
109
- width: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'dayLabel', 'width'], '33px'),
110
- fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'dayLabel', 'fontWeight'], "".concat(500, " !important")),
111
- fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'dayLabel', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily']))
151
+ '&:hover:not($disabled):before': {
152
+ borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'hover', 'borderBottom'], "1px solid ".concat(_colorsModule.default.gray))
112
153
  },
113
- daysHeader: {
114
- marginTop: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'daysHeader', 'marginTop'], '15px')
115
- }
116
- },
117
- MuiOutlinedInput: {
118
- root: {
119
- fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily'])),
120
- backgroundColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'backgroundColor'], _colorsModule.default.white),
121
- fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'fontWeight'], 500),
122
- fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'fontSize'], '14px'),
123
- borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'borderRadius'], '30px'),
124
- height: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'height'], '40px'),
125
- width: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'width'], '250px'),
126
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'color'], _colorsModule.default.gray4),
127
- paddingLeft: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'paddingLeft'], '6px'),
128
- paddingRight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'root', 'paddingLeft'], '12px !important'),
129
- '&:hover:not($disabled):not($focused):not($error) $notchedOutline': {
130
- borderColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'notchedOutline', 'hover', 'borderColor'], _colorsModule.default.gray3)
131
- },
132
- '&$focused $notchedOutline': {
133
- borderColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'notchedOutline', 'focused', 'borderColor'], _colorsModule.default.gray3),
134
- borderWidth: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'notchedOutline', 'focused', 'borderWidth'], 1)
135
- }
154
+ '&$disabled:before': {
155
+ borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'disabled', 'borderBottom'], "1px solid ".concat(_colorsModule.default.gray))
136
156
  },
137
- notchedOutline: {
138
- borderColor: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'outlinedInput', 'notchedOutline', 'borderColor'], _colorsModule.default.gray3)
139
- }
140
- },
141
- MuiInput: {
142
- input: {
143
- border: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'border']),
144
- borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'input', 'borderRadius']),
145
- fontFamily: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'fontFamily'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily'])),
146
- fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'fontSize'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'medium'], 14)),
147
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'color']),
148
- padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'input', 'padding'])
157
+ '&:before': {
158
+ borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'unfocused', 'borderBottom'], "1px solid ".concat(_colorsModule.default.gray))
149
159
  },
150
- underline: {
151
- '&:hover:not($disabled):not($focused):not($error):before': {
152
- borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'hover', 'borderBottom'], "1px solid ".concat(_colorsModule.default.gray))
153
- },
154
- '&:hover:not($disabled):before': {
155
- borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'hover', 'borderBottom'], "1px solid ".concat(_colorsModule.default.gray))
156
- },
157
- '&$disabled:before': {
158
- borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'disabled', 'borderBottom'], "1px solid ".concat(_colorsModule.default.gray))
159
- },
160
- '&:before': {
161
- borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'unfocused', 'borderBottom'], "1px solid ".concat(_colorsModule.default.gray))
162
- },
163
- '&$focused:after': {
164
- borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'focused', 'borderBottom'], "2px solid ".concat(_colorsModule.default.primary))
165
- },
166
- '&:after': {
167
- borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'base', 'borderBottom'], "2px solid ".concat(_colorsModule.default.primary))
168
- }
160
+ '&$focused:after': {
161
+ borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'focused', 'borderBottom'], "2px solid ".concat(_colorsModule.default.primary))
162
+ },
163
+ '&:after': {
164
+ borderBottom: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'underline', 'base', 'borderBottom'], "2px solid ".concat(_colorsModule.default.primary))
169
165
  }
170
- },
171
- MuiFormLabel: {
172
- root: {
173
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'color']),
166
+ }
167
+ },
168
+ MuiFormLabel: {
169
+ root: {
170
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'color']),
171
+ '&$error': {
172
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'errorColor'], _colorsModule.default.gray)
173
+ },
174
+ '&$focused': {
175
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'focusedColor'], _colorsModule.default.primary),
174
176
  '&$error': {
175
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'errorColor'], _colorsModule.default.gray)
176
- },
177
- '&$focused': {
178
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'focusedColor'], _colorsModule.default.primary),
179
- '&$error': {
180
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'focusedErrorColor'], _colorsModule.default.error)
181
- }
182
- },
183
- fontFamily: (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily']),
184
- fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'fontSize'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'medium'], 14)),
185
- fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'fontWeight'])
186
- }
187
- },
188
- MuiPopover: {
189
- paper: {
190
- borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'calendarPaper', 'borderRadius'], '10px'),
191
- boxShadow: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'calendarPaper', 'boxShadow'], 'none'),
192
- border: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'calendarPaper', 'border'], "1px solid ".concat(_colorsModule.default.gray3)),
193
- color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'calendarPaper', 'color'], _colorsModule.default.gray3)
194
- }
195
- },
196
- MuiIconButton: {
197
- root: {
198
- padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'openerIcon', 'padding'], '5px')
199
- }
200
- },
201
- MuiPickersBasePicker: {
202
- pickerView: {
203
- minWidth: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'pickerView', 'minWidth'], '290px')
204
- }
177
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'focusedErrorColor'], _colorsModule.default.error)
178
+ }
179
+ },
180
+ fontFamily: (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'fontFamily']),
181
+ fontSize: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'fontSize'], (0, _seamlessImmutable.getIn)(theme, ['Fonts', 'medium'], 14)),
182
+ fontWeight: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'standardInput', 'formLabel', 'fontWeight'])
183
+ }
184
+ },
185
+ MuiPopover: {
186
+ paper: {
187
+ borderRadius: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'calendarPaper', 'borderRadius'], '10px'),
188
+ boxShadow: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'calendarPaper', 'boxShadow'], 'none'),
189
+ border: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'calendarPaper', 'border'], "1px solid ".concat(_colorsModule.default.gray3)),
190
+ color: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'calendarPaper', 'color'], _colorsModule.default.gray3)
191
+ }
192
+ },
193
+ MuiIconButton: {
194
+ root: {
195
+ padding: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'openerIcon', 'padding'], '5px')
196
+ }
197
+ },
198
+ MuiPickersBasePicker: {
199
+ pickerView: {
200
+ minWidth: (0, _seamlessImmutable.getIn)(theme, ['UTDatePicker', 'pickerView', 'minWidth'], '290px')
205
201
  }
206
202
  }
207
- });
208
- };
203
+ }
204
+ });
209
205
  exports.materialTheme = materialTheme;