@hipay/hipay-material-ui 4.0.1-beta5 → 4.1.1-beta.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (439) hide show
  1. package/HiAccordion/HiAccordion.js +8 -26
  2. package/HiAccordion/index.js +1 -5
  3. package/HiAccordionActions/HiAccordionActions.js +1 -14
  4. package/HiAccordionActions/index.js +1 -5
  5. package/HiAccordionSummary/HiAccordionSummary.js +1 -15
  6. package/HiAccordionSummary/index.js +1 -5
  7. package/HiAlertModal/HiAlertModal.js +7 -22
  8. package/HiAlertModal/index.js +1 -5
  9. package/HiAppBar/HiAppBar.js +17 -51
  10. package/HiAppBar/index.js +0 -2
  11. package/HiAvatar/HiAvatar.js +3 -12
  12. package/HiAvatar/index.js +0 -2
  13. package/HiBadge/HiBadge.js +8 -24
  14. package/HiBadge/index.js +0 -2
  15. package/HiBreadcrumb/HiBreadcrumb.js +12 -38
  16. package/HiBreadcrumb/HiStep.js +19 -53
  17. package/HiBreadcrumb/HiStepConnector.js +20 -59
  18. package/HiBreadcrumb/HiStepContent.js +12 -38
  19. package/HiBreadcrumb/HiStepIcon.js +16 -43
  20. package/HiBreadcrumb/HiStepLabel.js +20 -52
  21. package/HiBreadcrumb/HiStepper.js +12 -38
  22. package/HiBreadcrumb/index.js +0 -2
  23. package/HiButton/HiButton.js +8 -33
  24. package/HiButton/index.js +1 -5
  25. package/HiCell/CellAddress.js +18 -41
  26. package/HiCell/CellDate.js +16 -44
  27. package/HiCell/CellHiddenContent.js +8 -30
  28. package/HiCell/CellIcon.js +18 -44
  29. package/HiCell/CellImage.js +18 -42
  30. package/HiCell/CellNumeric.js +19 -48
  31. package/HiCell/CellPinToAction.js +15 -41
  32. package/HiCell/CellRate.js +19 -55
  33. package/HiCell/CellSentinel.js +18 -41
  34. package/HiCell/CellSentinelScore.js +15 -39
  35. package/HiCell/CellText.js +23 -62
  36. package/HiCell/CellTextStyled.js +13 -24
  37. package/HiCell/index.js +0 -10
  38. package/HiCheckbox/HiCheckbox.js +21 -61
  39. package/HiCheckbox/index.js +0 -2
  40. package/HiChip/HiChip.js +24 -47
  41. package/HiChip/HiChipSwitch.js +25 -71
  42. package/HiChip/index.js +0 -3
  43. package/HiColoredLabel/HiColoredLabel.js +15 -49
  44. package/HiColoredLabel/index.js +0 -2
  45. package/HiDatePicker/Caption.js +9 -21
  46. package/HiDatePicker/HiDatePicker.js +22 -96
  47. package/HiDatePicker/HiDatePickerMobile.js +24 -51
  48. package/HiDatePicker/HiDateRangePicker.js +44 -142
  49. package/HiDatePicker/HiDateRangeSelector.js +55 -138
  50. package/HiDatePicker/ListPicker.js +14 -46
  51. package/HiDatePicker/NavBar.js +12 -31
  52. package/HiDatePicker/Overlays/CustomOverlayLayout.js +11 -28
  53. package/HiDatePicker/Overlays/CustomOverlayLayoutWithoutFooter.js +11 -28
  54. package/HiDatePicker/Overlays/MonthPickerOverlay.js +11 -36
  55. package/HiDatePicker/Overlays/Overlay.js +8 -25
  56. package/HiDatePicker/Overlays/TimePickerOverlay.js +16 -50
  57. package/HiDatePicker/Overlays/YearPickerOverlay.js +15 -42
  58. package/HiDatePicker/Overlays/index.js +0 -6
  59. package/HiDatePicker/Weekday.js +4 -9
  60. package/HiDatePicker/hiLocaleUtils.js +8 -20
  61. package/HiDatePicker/index.js +0 -2
  62. package/HiDatePicker/stylesheet.js +6 -13
  63. package/HiDialog/HiDialog.js +7 -19
  64. package/HiDialog/index.js +0 -2
  65. package/HiDotsStepper/HiDot.js +14 -45
  66. package/HiDotsStepper/HiDotsStepper.js +18 -48
  67. package/HiDotsStepper/index.js +0 -3
  68. package/HiExpansionPanel/HiExpansionPanel.js +16 -38
  69. package/HiExpansionPanel/index.js +1 -5
  70. package/HiForm/HiAddressField.js +20 -49
  71. package/HiForm/HiEmailField.js +11 -38
  72. package/HiForm/HiFormControl.js +37 -86
  73. package/HiForm/HiFormLabel.js +20 -48
  74. package/HiForm/HiInput.js +47 -109
  75. package/HiForm/HiPasswordField.js +18 -57
  76. package/HiForm/HiSearchField.js +12 -46
  77. package/HiForm/HiSlider.js +28 -65
  78. package/HiForm/HiTextField.js +30 -58
  79. package/HiForm/HiUpload.js +36 -98
  80. package/HiForm/HiUploadField.js +16 -40
  81. package/HiForm/HiUploadInput.js +27 -84
  82. package/HiForm/index.js +0 -12
  83. package/HiIcon/HiIcon.js +9 -34
  84. package/HiIcon/index.js +0 -2
  85. package/HiIconButton/HiIconButton.js +6 -21
  86. package/HiIconButton/index.js +0 -2
  87. package/HiListItemLink/HiListItemLink.js +6 -19
  88. package/HiListItemLink/index.js +0 -2
  89. package/HiLoader/HiLoader.js +6 -16
  90. package/HiLoader/index.js +0 -2
  91. package/HiNotice/HiKPI.js +23 -57
  92. package/HiNotice/HiKPINotice.js +6 -16
  93. package/HiNotice/index.js +0 -3
  94. package/HiPagination/HiPagination.js +1 -11
  95. package/HiPagination/index.js +0 -2
  96. package/HiPaymentMeans/HiPaymentMeans.js +31 -72
  97. package/HiPaymentMeans/index.js +0 -2
  98. package/HiPdfReader/HiPdfReader.js +29 -64
  99. package/HiPdfReader/index.js +0 -2
  100. package/HiPin/HiPin.js +7 -19
  101. package/HiPin/index.js +0 -2
  102. package/HiRadio/HiRadio.js +11 -22
  103. package/HiRadio/index.js +0 -2
  104. package/HiScrollStepper/HiScrollStepper.js +29 -67
  105. package/HiScrollStepper/index.js +0 -2
  106. package/HiSelect/HiDynamicSelect.js +39 -52
  107. package/HiSelect/HiDynamicSelectField.js +29 -55
  108. package/HiSelect/HiNestedSelect.js +71 -120
  109. package/HiSelect/HiNestedSelectContent.js +65 -93
  110. package/HiSelect/HiNestedSelectField.js +29 -55
  111. package/HiSelect/HiSelect.js +95 -195
  112. package/HiSelect/HiSelectContent.js +72 -110
  113. package/HiSelect/HiSelectField.js +30 -56
  114. package/HiSelect/HiSelectInput.js +27 -84
  115. package/HiSelect/HiSelectMobile.js +14 -53
  116. package/HiSelect/HiSuggestSelect.js +30 -88
  117. package/HiSelect/HiSuggestSelectField.js +20 -46
  118. package/HiSelect/index.js +2 -14
  119. package/HiSelectableList/HiSelectableList.js +42 -98
  120. package/HiSelectableList/HiSelectableListHierarchic.js +40 -68
  121. package/HiSelectableList/HiSelectableListItem.js +47 -89
  122. package/HiSelectableList/index.js +0 -4
  123. package/HiStepper/DefaultIndicator.js +1 -10
  124. package/HiStepper/HiStep.js +18 -48
  125. package/HiStepper/HiStepper.js +2 -15
  126. package/HiStepper/index.js +0 -3
  127. package/HiSwitch/HiSwitch.js +9 -33
  128. package/HiSwitch/HiSwitchState.js +15 -32
  129. package/HiSwitch/index.js +0 -3
  130. package/HiTable/HiCellBuilder.js +15 -72
  131. package/HiTable/HiTable.js +20 -48
  132. package/HiTable/HiTableBody.js +12 -31
  133. package/HiTable/HiTableHeader.js +23 -58
  134. package/HiTable/HiTableRow.js +18 -55
  135. package/HiTable/constants.js +48 -98
  136. package/HiTable/index.js +0 -2
  137. package/es/HiAccordion/HiAccordion.js +8 -26
  138. package/es/HiAccordion/index.js +1 -5
  139. package/es/HiAccordionActions/HiAccordionActions.js +1 -14
  140. package/es/HiAccordionActions/index.js +1 -5
  141. package/es/HiAccordionSummary/HiAccordionSummary.js +1 -15
  142. package/es/HiAccordionSummary/index.js +1 -5
  143. package/es/HiAlertModal/HiAlertModal.js +7 -22
  144. package/es/HiAlertModal/index.js +1 -5
  145. package/es/HiAppBar/HiAppBar.js +17 -51
  146. package/es/HiAppBar/index.js +0 -2
  147. package/es/HiAvatar/HiAvatar.js +3 -12
  148. package/es/HiAvatar/index.js +0 -2
  149. package/es/HiBadge/HiBadge.js +8 -24
  150. package/es/HiBadge/index.js +0 -2
  151. package/es/HiBreadcrumb/HiBreadcrumb.js +12 -38
  152. package/es/HiBreadcrumb/HiStep.js +19 -53
  153. package/es/HiBreadcrumb/HiStepConnector.js +20 -59
  154. package/es/HiBreadcrumb/HiStepContent.js +12 -38
  155. package/es/HiBreadcrumb/HiStepIcon.js +16 -43
  156. package/es/HiBreadcrumb/HiStepLabel.js +20 -52
  157. package/es/HiBreadcrumb/HiStepper.js +12 -38
  158. package/es/HiBreadcrumb/index.js +0 -2
  159. package/es/HiButton/HiButton.js +8 -33
  160. package/es/HiButton/index.js +1 -5
  161. package/es/HiCell/CellAddress.js +18 -41
  162. package/es/HiCell/CellDate.js +16 -44
  163. package/es/HiCell/CellHiddenContent.js +8 -30
  164. package/es/HiCell/CellIcon.js +18 -44
  165. package/es/HiCell/CellImage.js +18 -42
  166. package/es/HiCell/CellNumeric.js +19 -48
  167. package/es/HiCell/CellPinToAction.js +15 -41
  168. package/es/HiCell/CellRate.js +19 -55
  169. package/es/HiCell/CellSentinel.js +18 -41
  170. package/es/HiCell/CellSentinelScore.js +15 -39
  171. package/es/HiCell/CellText.js +23 -62
  172. package/es/HiCell/CellTextStyled.js +13 -24
  173. package/es/HiCell/index.js +0 -10
  174. package/es/HiCheckbox/HiCheckbox.js +21 -61
  175. package/es/HiCheckbox/index.js +0 -2
  176. package/es/HiChip/HiChip.js +24 -47
  177. package/es/HiChip/HiChipSwitch.js +25 -71
  178. package/es/HiChip/index.js +0 -3
  179. package/es/HiColoredLabel/HiColoredLabel.js +15 -49
  180. package/es/HiColoredLabel/index.js +0 -2
  181. package/es/HiDatePicker/Caption.js +9 -21
  182. package/es/HiDatePicker/HiDatePicker.js +22 -96
  183. package/es/HiDatePicker/HiDatePickerMobile.js +24 -51
  184. package/es/HiDatePicker/HiDateRangePicker.js +44 -142
  185. package/es/HiDatePicker/HiDateRangeSelector.js +55 -138
  186. package/es/HiDatePicker/ListPicker.js +14 -46
  187. package/es/HiDatePicker/NavBar.js +12 -31
  188. package/es/HiDatePicker/Overlays/CustomOverlayLayout.js +11 -28
  189. package/es/HiDatePicker/Overlays/CustomOverlayLayoutWithoutFooter.js +11 -28
  190. package/es/HiDatePicker/Overlays/MonthPickerOverlay.js +11 -36
  191. package/es/HiDatePicker/Overlays/Overlay.js +8 -25
  192. package/es/HiDatePicker/Overlays/TimePickerOverlay.js +16 -50
  193. package/es/HiDatePicker/Overlays/YearPickerOverlay.js +15 -42
  194. package/es/HiDatePicker/Overlays/index.js +0 -6
  195. package/es/HiDatePicker/Weekday.js +4 -9
  196. package/es/HiDatePicker/hiLocaleUtils.js +8 -20
  197. package/es/HiDatePicker/index.js +0 -2
  198. package/es/HiDatePicker/stylesheet.js +6 -13
  199. package/es/HiDialog/HiDialog.js +7 -19
  200. package/es/HiDialog/index.js +0 -2
  201. package/es/HiDotsStepper/HiDot.js +14 -45
  202. package/es/HiDotsStepper/HiDotsStepper.js +18 -48
  203. package/es/HiDotsStepper/index.js +0 -3
  204. package/es/HiExpansionPanel/HiExpansionPanel.js +16 -38
  205. package/es/HiExpansionPanel/index.js +1 -5
  206. package/es/HiForm/HiAddressField.js +20 -49
  207. package/es/HiForm/HiEmailField.js +11 -38
  208. package/es/HiForm/HiFormControl.js +37 -86
  209. package/es/HiForm/HiFormLabel.js +20 -48
  210. package/es/HiForm/HiInput.js +47 -109
  211. package/es/HiForm/HiPasswordField.js +18 -57
  212. package/es/HiForm/HiSearchField.js +12 -46
  213. package/es/HiForm/HiSlider.js +28 -65
  214. package/es/HiForm/HiTextField.js +30 -58
  215. package/es/HiForm/HiUpload.js +36 -98
  216. package/es/HiForm/HiUploadField.js +16 -40
  217. package/es/HiForm/HiUploadInput.js +27 -84
  218. package/es/HiForm/index.js +0 -12
  219. package/es/HiIcon/HiIcon.js +9 -34
  220. package/es/HiIcon/index.js +0 -2
  221. package/es/HiIconButton/HiIconButton.js +6 -21
  222. package/es/HiIconButton/index.js +0 -2
  223. package/es/HiListItemLink/HiListItemLink.js +6 -19
  224. package/es/HiListItemLink/index.js +0 -2
  225. package/es/HiLoader/HiLoader.js +6 -16
  226. package/es/HiLoader/index.js +0 -2
  227. package/es/HiNotice/HiKPI.js +23 -57
  228. package/es/HiNotice/HiKPINotice.js +6 -16
  229. package/es/HiNotice/index.js +0 -3
  230. package/es/HiPagination/HiPagination.js +1 -11
  231. package/es/HiPagination/index.js +0 -2
  232. package/es/HiPaymentMeans/HiPaymentMeans.js +31 -72
  233. package/es/HiPaymentMeans/index.js +0 -2
  234. package/es/HiPdfReader/HiPdfReader.js +29 -64
  235. package/es/HiPdfReader/index.js +0 -2
  236. package/es/HiPin/HiPin.js +7 -19
  237. package/es/HiPin/index.js +0 -2
  238. package/es/HiRadio/HiRadio.js +11 -22
  239. package/es/HiRadio/index.js +0 -2
  240. package/es/HiScrollStepper/HiScrollStepper.js +29 -67
  241. package/es/HiScrollStepper/index.js +0 -2
  242. package/es/HiSelect/HiDynamicSelect.js +39 -52
  243. package/es/HiSelect/HiDynamicSelectField.js +29 -55
  244. package/es/HiSelect/HiNestedSelect.js +71 -120
  245. package/es/HiSelect/HiNestedSelectContent.js +65 -93
  246. package/es/HiSelect/HiNestedSelectField.js +29 -55
  247. package/es/HiSelect/HiSelect.js +95 -195
  248. package/es/HiSelect/HiSelectContent.js +72 -110
  249. package/es/HiSelect/HiSelectField.js +30 -56
  250. package/es/HiSelect/HiSelectInput.js +27 -84
  251. package/es/HiSelect/HiSelectMobile.js +14 -53
  252. package/es/HiSelect/HiSuggestSelect.js +30 -88
  253. package/es/HiSelect/HiSuggestSelectField.js +20 -46
  254. package/es/HiSelect/index.js +2 -14
  255. package/es/HiSelectableList/HiSelectableList.js +42 -98
  256. package/es/HiSelectableList/HiSelectableListHierarchic.js +40 -68
  257. package/es/HiSelectableList/HiSelectableListItem.js +47 -89
  258. package/es/HiSelectableList/index.js +0 -4
  259. package/es/HiStepper/DefaultIndicator.js +1 -10
  260. package/es/HiStepper/HiStep.js +18 -48
  261. package/es/HiStepper/HiStepper.js +2 -15
  262. package/es/HiStepper/index.js +0 -3
  263. package/es/HiSwitch/HiSwitch.js +9 -33
  264. package/es/HiSwitch/HiSwitchState.js +15 -32
  265. package/es/HiSwitch/index.js +0 -3
  266. package/es/HiTable/HiCellBuilder.js +15 -72
  267. package/es/HiTable/HiTable.js +20 -48
  268. package/es/HiTable/HiTableBody.js +12 -31
  269. package/es/HiTable/HiTableHeader.js +23 -58
  270. package/es/HiTable/HiTableRow.js +18 -55
  271. package/es/HiTable/constants.js +48 -98
  272. package/es/HiTable/index.js +0 -2
  273. package/es/hi-svg-icons/HiAccount.js +4 -14
  274. package/es/hi-svg-icons/HiActivity.js +4 -14
  275. package/es/hi-svg-icons/HiAll.js +7 -18
  276. package/es/hi-svg-icons/HiBilling.js +4 -14
  277. package/es/hi-svg-icons/HiBriefcaseRescue.js +4 -14
  278. package/es/hi-svg-icons/HiBusiness.js +4 -14
  279. package/es/hi-svg-icons/HiCatalog.js +4 -14
  280. package/es/hi-svg-icons/HiCustomer.js +4 -14
  281. package/es/hi-svg-icons/HiDownload.js +4 -14
  282. package/es/hi-svg-icons/HiFinance.js +4 -14
  283. package/es/hi-svg-icons/HiFinanceMenu.js +4 -14
  284. package/es/hi-svg-icons/HiHostedPaymentPage.js +4 -14
  285. package/es/hi-svg-icons/HiHostedPaymentPageMenu.js +4 -14
  286. package/es/hi-svg-icons/HiIntegration.js +4 -14
  287. package/es/hi-svg-icons/HiIntegrationMenu.js +4 -14
  288. package/es/hi-svg-icons/HiIntelligence.js +4 -14
  289. package/es/hi-svg-icons/HiIntelligenceMenu.js +4 -14
  290. package/es/hi-svg-icons/HiInvoice.js +4 -14
  291. package/es/hi-svg-icons/HiInvoiceMenu.js +4 -14
  292. package/es/hi-svg-icons/HiLogoRounded.js +6 -17
  293. package/es/hi-svg-icons/HiOrder.js +4 -14
  294. package/es/hi-svg-icons/HiPaymentOrder.js +4 -14
  295. package/es/hi-svg-icons/HiPermission.js +4 -14
  296. package/es/hi-svg-icons/HiPriceGrid.js +4 -14
  297. package/es/hi-svg-icons/HiPrivate.js +4 -14
  298. package/es/hi-svg-icons/HiRoute.js +4 -14
  299. package/es/hi-svg-icons/HiRouteMenu.js +4 -14
  300. package/es/hi-svg-icons/HiRouteSwitch.js +7 -19
  301. package/es/hi-svg-icons/HiRouteSwitchMenu.js +7 -19
  302. package/es/hi-svg-icons/HiSettlement.js +4 -14
  303. package/es/hi-svg-icons/HiSizeLarge.js +4 -14
  304. package/es/hi-svg-icons/HiSizeMedium.js +4 -14
  305. package/es/hi-svg-icons/HiSizeSmall.js +4 -14
  306. package/es/hi-svg-icons/HiStore.js +4 -14
  307. package/es/hi-svg-icons/HiStoreMenu.js +4 -14
  308. package/es/hi-svg-icons/HiTransaction.js +4 -14
  309. package/es/hi-svg-icons/HiTransactionMenu.js +4 -14
  310. package/es/hi-svg-icons/HiUser.js +4 -14
  311. package/es/hi-svg-icons/HiVendor.js +4 -14
  312. package/es/hi-svg-icons/HiWidget.js +4 -14
  313. package/es/hi-svg-icons/index.js +0 -41
  314. package/es/hi-svg-images/HiLogo.js +4 -12
  315. package/es/hi-svg-images/HiLogoWhite.js +4 -12
  316. package/es/hi-svg-images/index.js +0 -3
  317. package/es/setupTest.js +2 -13
  318. package/es/styleguide/Wrapper.js +0 -6
  319. package/es/styles/MuiThemeProvider.js +20 -56
  320. package/es/styles/colorManipulator.js +15 -50
  321. package/es/styles/createBreakpoints.js +14 -29
  322. package/es/styles/createGenerateClassName.js +14 -24
  323. package/es/styles/createMixins.js +4 -10
  324. package/es/styles/createMuiTheme.js +11 -28
  325. package/es/styles/createPalette.js +66 -89
  326. package/es/styles/createStyles.js +0 -1
  327. package/es/styles/createTypography.js +15 -24
  328. package/es/styles/getStylesCreator.js +2 -14
  329. package/es/styles/getThemeProps.js +2 -7
  330. package/es/styles/index.js +0 -6
  331. package/es/styles/jssPreset.js +1 -11
  332. package/es/styles/makeStyles.js +2 -9
  333. package/es/styles/mergeClasses.js +5 -16
  334. package/es/styles/shadows.js +1 -4
  335. package/es/styles/shape.js +1 -2
  336. package/es/styles/spacing.js +1 -4
  337. package/es/styles/themeListener.js +2 -10
  338. package/es/styles/transitions.js +20 -35
  339. package/es/styles/withStyles.js +2 -9
  340. package/es/styles/zIndex.js +1 -2
  341. package/es/test-utils/createMount.js +2 -12
  342. package/es/test-utils/createRender.js +2 -9
  343. package/es/test-utils/createShallow.js +6 -17
  344. package/es/test-utils/getClasses.js +1 -4
  345. package/es/test-utils/index.js +0 -6
  346. package/es/test-utils/until.js +3 -14
  347. package/es/test-utils/unwrap.js +0 -1
  348. package/es/theme/palette.js +2 -7
  349. package/es/theme/typography.js +7 -15
  350. package/es/theme.js +2 -8
  351. package/es/transitions/utils.js +3 -7
  352. package/es/utils/exactProp.js +3 -13
  353. package/es/utils/helpers.js +19 -58
  354. package/es/withMobileDialog/index.js +0 -2
  355. package/es/withMobileDialog/withMobileDialog.js +3 -12
  356. package/hi-svg-icons/HiAccount.js +4 -14
  357. package/hi-svg-icons/HiActivity.js +4 -14
  358. package/hi-svg-icons/HiAll.js +7 -18
  359. package/hi-svg-icons/HiBilling.js +4 -14
  360. package/hi-svg-icons/HiBriefcaseRescue.js +4 -14
  361. package/hi-svg-icons/HiBusiness.js +4 -14
  362. package/hi-svg-icons/HiCatalog.js +4 -14
  363. package/hi-svg-icons/HiCustomer.js +4 -14
  364. package/hi-svg-icons/HiDownload.js +4 -14
  365. package/hi-svg-icons/HiFinance.js +4 -14
  366. package/hi-svg-icons/HiFinanceMenu.js +4 -14
  367. package/hi-svg-icons/HiHostedPaymentPage.js +4 -14
  368. package/hi-svg-icons/HiHostedPaymentPageMenu.js +4 -14
  369. package/hi-svg-icons/HiIntegration.js +4 -14
  370. package/hi-svg-icons/HiIntegrationMenu.js +4 -14
  371. package/hi-svg-icons/HiIntelligence.js +4 -14
  372. package/hi-svg-icons/HiIntelligenceMenu.js +4 -14
  373. package/hi-svg-icons/HiInvoice.js +4 -14
  374. package/hi-svg-icons/HiInvoiceMenu.js +4 -14
  375. package/hi-svg-icons/HiLogoRounded.js +6 -17
  376. package/hi-svg-icons/HiOrder.js +4 -14
  377. package/hi-svg-icons/HiPaymentOrder.js +4 -14
  378. package/hi-svg-icons/HiPermission.js +4 -14
  379. package/hi-svg-icons/HiPriceGrid.js +4 -14
  380. package/hi-svg-icons/HiPrivate.js +4 -14
  381. package/hi-svg-icons/HiRoute.js +4 -14
  382. package/hi-svg-icons/HiRouteMenu.js +4 -14
  383. package/hi-svg-icons/HiRouteSwitch.js +7 -19
  384. package/hi-svg-icons/HiRouteSwitchMenu.js +7 -19
  385. package/hi-svg-icons/HiSettlement.js +4 -14
  386. package/hi-svg-icons/HiSizeLarge.js +4 -14
  387. package/hi-svg-icons/HiSizeMedium.js +4 -14
  388. package/hi-svg-icons/HiSizeSmall.js +4 -14
  389. package/hi-svg-icons/HiStore.js +4 -14
  390. package/hi-svg-icons/HiStoreMenu.js +4 -14
  391. package/hi-svg-icons/HiTransaction.js +4 -14
  392. package/hi-svg-icons/HiTransactionMenu.js +4 -14
  393. package/hi-svg-icons/HiUser.js +4 -14
  394. package/hi-svg-icons/HiVendor.js +4 -14
  395. package/hi-svg-icons/HiWidget.js +4 -14
  396. package/hi-svg-icons/index.js +0 -41
  397. package/hi-svg-images/HiLogo.js +4 -12
  398. package/hi-svg-images/HiLogoWhite.js +4 -12
  399. package/hi-svg-images/index.js +0 -3
  400. package/package.json +2 -2
  401. package/setupTest.js +2 -13
  402. package/styleguide/Wrapper.js +0 -6
  403. package/styles/MuiThemeProvider.js +20 -56
  404. package/styles/colorManipulator.js +15 -50
  405. package/styles/createBreakpoints.js +14 -29
  406. package/styles/createGenerateClassName.js +14 -24
  407. package/styles/createMixins.js +4 -10
  408. package/styles/createMuiTheme.js +11 -28
  409. package/styles/createPalette.js +66 -89
  410. package/styles/createStyles.js +0 -1
  411. package/styles/createTypography.js +15 -24
  412. package/styles/getStylesCreator.js +2 -14
  413. package/styles/getThemeProps.js +2 -7
  414. package/styles/index.js +0 -6
  415. package/styles/jssPreset.js +1 -11
  416. package/styles/makeStyles.js +2 -9
  417. package/styles/mergeClasses.js +5 -16
  418. package/styles/shadows.js +1 -4
  419. package/styles/shape.js +1 -2
  420. package/styles/spacing.js +1 -4
  421. package/styles/themeListener.js +2 -10
  422. package/styles/transitions.js +20 -35
  423. package/styles/withStyles.js +2 -9
  424. package/styles/zIndex.js +1 -2
  425. package/test-utils/createMount.js +2 -12
  426. package/test-utils/createRender.js +2 -9
  427. package/test-utils/createShallow.js +6 -17
  428. package/test-utils/getClasses.js +1 -4
  429. package/test-utils/index.js +0 -6
  430. package/test-utils/until.js +3 -14
  431. package/test-utils/unwrap.js +0 -1
  432. package/theme/palette.js +2 -7
  433. package/theme/typography.js +7 -15
  434. package/theme.js +2 -8
  435. package/transitions/utils.js +3 -7
  436. package/utils/exactProp.js +3 -13
  437. package/utils/helpers.js +19 -58
  438. package/withMobileDialog/index.js +0 -2
  439. package/withMobileDialog/withMobileDialog.js +3 -12
@@ -1,30 +1,19 @@
1
1
  "use strict";
2
2
 
3
3
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
8
7
  exports.default = void 0;
9
-
10
8
  var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/typeof"));
11
-
12
9
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/extends"));
13
-
14
10
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/defineProperty"));
15
-
16
11
  var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
17
-
18
12
  var _react = _interopRequireDefault(require("react"));
19
-
20
13
  var _classnames = _interopRequireDefault(require("classnames"));
21
-
22
14
  var _keycode = _interopRequireDefault(require("keycode"));
23
-
24
15
  var _HiIcon = _interopRequireDefault(require("../HiIcon"));
25
-
26
16
  var _makeStyles = _interopRequireDefault(require("@mui/styles/makeStyles"));
27
-
28
17
  var useStyles = (0, _makeStyles.default)(function (theme) {
29
18
  return {
30
19
  root: (0, _objectSpread2.default)({}, theme.typography.body3, {
@@ -113,43 +102,38 @@ var useStyles = (0, _makeStyles.default)(function (theme) {
113
102
  }
114
103
  };
115
104
  });
116
-
117
105
  var handleKeyDown = function handleKeyDown(e, fn) {
118
106
  if ((0, _keycode.default)(e) === 'space' || (0, _keycode.default)(e) === 'enter') {
119
107
  e.preventDefault();
120
108
  fn();
121
109
  }
122
110
  };
123
-
124
111
  var HiChip = function HiChip(props) {
125
- var _classNames2;
126
-
127
112
  var className = props.className,
128
- fallbackImage = props.fallbackImage,
129
- icon = props.icon,
130
- _props$iconSize = props.iconSize,
131
- iconSize = _props$iconSize === void 0 ? 20 : _props$iconSize,
132
- id = props.id,
133
- img = props.img,
134
- label = props.label,
135
- labelIcon = props.labelIcon,
136
- onClick = props.onClick,
137
- onKeyDown = props.onKeyDown,
138
- onPrevious = props.onPrevious,
139
- onNext = props.onNext,
140
- onDelete = props.onDelete,
141
- prefix = props.prefix,
142
- onIconClick = props.onIconClick,
143
- title = props.title,
144
- titleDelete = props.titleDelete,
145
- titleIcon = props.titleIcon,
146
- titleImg = props.titleImg,
147
- titleNext = props.titleNext,
148
- titlePrevious = props.titlePrevious,
149
- style = props.style;
113
+ fallbackImage = props.fallbackImage,
114
+ icon = props.icon,
115
+ _props$iconSize = props.iconSize,
116
+ iconSize = _props$iconSize === void 0 ? 20 : _props$iconSize,
117
+ id = props.id,
118
+ img = props.img,
119
+ label = props.label,
120
+ labelIcon = props.labelIcon,
121
+ onClick = props.onClick,
122
+ onKeyDown = props.onKeyDown,
123
+ onPrevious = props.onPrevious,
124
+ onNext = props.onNext,
125
+ onDelete = props.onDelete,
126
+ prefix = props.prefix,
127
+ onIconClick = props.onIconClick,
128
+ title = props.title,
129
+ titleDelete = props.titleDelete,
130
+ titleIcon = props.titleIcon,
131
+ titleImg = props.titleImg,
132
+ titleNext = props.titleNext,
133
+ titlePrevious = props.titlePrevious,
134
+ style = props.style;
150
135
  var classes = useStyles(props);
151
136
  var chipIcon;
152
-
153
137
  if (icon) {
154
138
  var iconProps = {
155
139
  className: (0, _classnames.default)(classes.icon, (0, _defineProperty2.default)({}, classes.iconClickable, onIconClick)),
@@ -161,7 +145,6 @@ var HiChip = function HiChip(props) {
161
145
  title: titleIcon,
162
146
  tabIndex: onIconClick ? 0 : -1
163
147
  };
164
-
165
148
  if (typeof icon === 'string') {
166
149
  chipIcon = /*#__PURE__*/_react.default.createElement(_HiIcon.default, (0, _extends2.default)({
167
150
  icon: icon
@@ -171,9 +154,7 @@ var HiChip = function HiChip(props) {
171
154
  chipIcon.props = (0, _objectSpread2.default)({}, iconProps);
172
155
  }
173
156
  }
174
-
175
157
  var chipLabelIcon;
176
-
177
158
  if (labelIcon) {
178
159
  var _iconProps = {
179
160
  className: classes.icon,
@@ -182,7 +163,6 @@ var HiChip = function HiChip(props) {
182
163
  title: titleIcon,
183
164
  tabIndex: -1
184
165
  };
185
-
186
166
  if (typeof labelIcon === 'string') {
187
167
  chipLabelIcon = /*#__PURE__*/_react.default.createElement(_HiIcon.default, (0, _extends2.default)({
188
168
  icon: labelIcon
@@ -196,11 +176,10 @@ var HiChip = function HiChip(props) {
196
176
  });
197
177
  }
198
178
  }
199
-
200
179
  return /*#__PURE__*/_react.default.createElement("div", {
201
180
  id: id,
202
181
  role: 'button',
203
- className: (0, _classnames.default)(classes.root, className, (_classNames2 = {}, (0, _defineProperty2.default)(_classNames2, classes.leftNavigation, onPrevious), (0, _defineProperty2.default)(_classNames2, classes.rightNavigation, onNext), (0, _defineProperty2.default)(_classNames2, classes.deletable, onDelete), (0, _defineProperty2.default)(_classNames2, classes.leftIcon, icon), _classNames2)),
182
+ className: (0, _classnames.default)(classes.root, className, (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, classes.leftNavigation, onPrevious), classes.rightNavigation, onNext), classes.deletable, onDelete), classes.leftIcon, icon)),
204
183
  title: title,
205
184
  onClick: onClick,
206
185
  onKeyDown: onKeyDown,
@@ -262,6 +241,4 @@ var HiChip = function HiChip(props) {
262
241
  tabIndex: 0
263
242
  }));
264
243
  };
265
-
266
- var _default = HiChip;
267
- exports.default = _default;
244
+ var _default = exports.default = HiChip;
@@ -1,47 +1,27 @@
1
1
  "use strict";
2
2
 
3
3
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
8
7
  exports.styles = exports.default = void 0;
9
-
10
8
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/extends"));
11
-
12
9
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/defineProperty"));
13
-
14
10
  var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/classCallCheck"));
15
-
16
11
  var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/createClass"));
17
-
18
- var _assertThisInitialized2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/assertThisInitialized"));
19
-
20
- var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/inherits"));
21
-
22
12
  var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/possibleConstructorReturn"));
23
-
24
13
  var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/getPrototypeOf"));
25
-
14
+ var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/inherits"));
26
15
  var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
27
-
28
16
  var _react = _interopRequireDefault(require("react"));
29
-
30
17
  var _classnames = _interopRequireDefault(require("classnames"));
31
-
32
18
  var _index = _interopRequireDefault(require("keycode/index"));
33
-
34
19
  var _HiIcon = _interopRequireDefault(require("../HiIcon"));
35
-
36
20
  var _styles = require("@mui/material/styles");
37
-
38
21
  var _withStyles = _interopRequireDefault(require("@mui/styles/withStyles"));
39
-
40
- function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
41
-
42
- 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; } }
43
-
44
- var styles = function styles(theme) {
22
+ function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); }
23
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
24
+ var styles = exports.styles = function styles(theme) {
45
25
  return {
46
26
  root: (0, _objectSpread2.default)({}, theme.typography.body3, {
47
27
  display: 'inline-flex',
@@ -117,95 +97,75 @@ var styles = function styles(theme) {
117
97
  }
118
98
  };
119
99
  };
120
-
121
- exports.styles = styles;
122
-
123
100
  var HiChipSwitch = /*#__PURE__*/function (_React$PureComponent) {
124
- (0, _inherits2.default)(HiChipSwitch, _React$PureComponent);
125
-
126
- var _super = _createSuper(HiChipSwitch);
127
-
128
101
  function HiChipSwitch(props) {
129
102
  var _this;
130
-
131
103
  (0, _classCallCheck2.default)(this, HiChipSwitch);
132
- _this = _super.call(this, props);
104
+ _this = _callSuper(this, HiChipSwitch, [props]);
133
105
  _this.chipSwitchRef = null;
134
-
135
106
  _this.handleKeyDown = function (event) {
136
107
  // Ignore events from children of `Chip`.
137
108
  if (event.currentTarget !== event.target) {
138
109
  return;
139
110
  }
140
-
141
111
  var _this$props = _this.props,
142
- onClick = _this$props.onClick,
143
- onKeyDown = _this$props.onKeyDown;
112
+ onClick = _this$props.onClick,
113
+ onKeyDown = _this$props.onKeyDown;
144
114
  var key = (0, _index.default)(event);
145
-
146
115
  if (onClick && (key === 'space' || key === 'enter')) {
147
116
  event.preventDefault();
148
117
  onClick(event);
149
118
  } else if (key === 'esc') {
150
119
  event.preventDefault();
151
-
152
120
  if (_this.chipSwitchRef) {
153
121
  _this.chipSwitchRef.blur();
154
122
  }
155
123
  }
156
-
157
124
  if (onKeyDown) {
158
125
  onKeyDown(event);
159
126
  }
160
127
  };
161
-
162
128
  _this.handleKeyDownSelection = function (event) {
163
129
  var onSelectionClick = _this.props.onSelectionClick;
164
130
  var key = (0, _index.default)(event);
165
-
166
131
  if (onSelectionClick && (key === 'space' || key === 'enter')) {
167
132
  event.preventDefault();
168
133
  onSelectionClick(event);
169
134
  }
170
135
  };
171
-
172
- _this.handleClickSelection = _this.handleClickSelection.bind((0, _assertThisInitialized2.default)(_this));
173
- _this.handleKeyDown = _this.handleKeyDown.bind((0, _assertThisInitialized2.default)(_this));
174
- _this.handleKeyDownSelection = _this.handleKeyDownSelection.bind((0, _assertThisInitialized2.default)(_this));
136
+ _this.handleClickSelection = _this.handleClickSelection.bind(_this);
137
+ _this.handleKeyDown = _this.handleKeyDown.bind(_this);
138
+ _this.handleKeyDownSelection = _this.handleKeyDownSelection.bind(_this);
175
139
  return _this;
176
140
  }
177
-
178
- (0, _createClass2.default)(HiChipSwitch, [{
141
+ (0, _inherits2.default)(HiChipSwitch, _React$PureComponent);
142
+ return (0, _createClass2.default)(HiChipSwitch, [{
179
143
  key: "handleClickSelection",
180
144
  value: function handleClickSelection(event) {
181
145
  if (this.props.onSelectionClick) {
182
146
  if (event) {
183
147
  event.stopPropagation();
184
148
  }
185
-
186
149
  this.props.onSelectionClick();
187
150
  }
188
151
  }
189
152
  }, {
190
153
  key: "render",
191
154
  value: function render() {
192
- var _classNames,
193
- _this2 = this;
194
-
155
+ var _this2 = this;
195
156
  var _this$props2 = this.props,
196
- id = _this$props2.id,
197
- label = _this$props2.label,
198
- classes = _this$props2.classes,
199
- activeIcon = _this$props2.activeIcon,
200
- active = _this$props2.active,
201
- onClick = _this$props2.onClick,
202
- onSelectionClick = _this$props2.onSelectionClick,
203
- selection = _this$props2.selection,
204
- selectionTitle = _this$props2.selectionTitle;
157
+ id = _this$props2.id,
158
+ label = _this$props2.label,
159
+ classes = _this$props2.classes,
160
+ activeIcon = _this$props2.activeIcon,
161
+ active = _this$props2.active,
162
+ onClick = _this$props2.onClick,
163
+ onSelectionClick = _this$props2.onSelectionClick,
164
+ selection = _this$props2.selection,
165
+ selectionTitle = _this$props2.selectionTitle;
205
166
  var selectionProps = {
206
167
  tabIndex: '-1'
207
168
  };
208
-
209
169
  if (onSelectionClick && selection !== 0) {
210
170
  selectionProps = {
211
171
  onClick: this.handleClickSelection,
@@ -215,10 +175,9 @@ var HiChipSwitch = /*#__PURE__*/function (_React$PureComponent) {
215
175
  title: selectionTitle
216
176
  };
217
177
  }
218
-
219
178
  return /*#__PURE__*/_react.default.createElement("div", {
220
179
  id: id,
221
- className: (0, _classnames.default)(classes.root, (_classNames = {}, (0, _defineProperty2.default)(_classNames, classes.active, !!active), (0, _defineProperty2.default)(_classNames, classes.inactive, !active), _classNames)),
180
+ className: (0, _classnames.default)(classes.root, (0, _defineProperty2.default)((0, _defineProperty2.default)({}, classes.active, !!active), classes.inactive, !active)),
222
181
  onClick: onClick,
223
182
  role: "button",
224
183
  tabIndex: "0",
@@ -237,19 +196,14 @@ var HiChipSwitch = /*#__PURE__*/function (_React$PureComponent) {
237
196
  }, selectionProps), selection));
238
197
  }
239
198
  }]);
240
- return HiChipSwitch;
241
199
  }(_react.default.PureComponent);
242
-
243
200
  HiChipSwitch.defaultProps = {
244
201
  active: false,
245
202
  activeIcon: 'check',
246
203
  selection: null,
247
204
  selectionTitle: ''
248
205
  };
249
-
250
- var _default = (0, _withStyles.default)(styles, {
206
+ var _default = exports.default = (0, _withStyles.default)(styles, {
251
207
  hiComponent: true,
252
208
  name: 'HmuiHiChipSwitch'
253
- })(HiChipSwitch);
254
-
255
- exports.default = _default;
209
+ })(HiChipSwitch);
@@ -1,7 +1,6 @@
1
1
  "use strict";
2
2
 
3
3
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
@@ -17,7 +16,5 @@ Object.defineProperty(exports, "default", {
17
16
  return _HiChip.default;
18
17
  }
19
18
  });
20
-
21
19
  var _HiChip = _interopRequireDefault(require("./HiChip"));
22
-
23
20
  var _HiChipSwitch = _interopRequireDefault(require("./HiChipSwitch"));
@@ -1,31 +1,20 @@
1
1
  "use strict";
2
2
 
3
3
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
8
7
  exports.styles = exports.default = void 0;
9
-
10
8
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/extends"));
11
-
12
9
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/defineProperty"));
13
-
14
10
  var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectWithoutProperties"));
15
-
16
11
  var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
17
-
18
12
  var _react = _interopRequireDefault(require("react"));
19
-
20
13
  var _classnames = _interopRequireDefault(require("classnames"));
21
-
22
14
  var _styles = require("@mui/material/styles");
23
-
24
15
  var _withStyles = _interopRequireDefault(require("@mui/styles/withStyles"));
25
-
26
16
  var _helpers = require("../utils/helpers");
27
-
28
- var styles = function styles(theme) {
17
+ var styles = exports.styles = function styles(theme) {
29
18
  return {
30
19
  root: {
31
20
  display: 'inline-block',
@@ -46,43 +35,36 @@ var styles = function styles(theme) {
46
35
  color: {
47
36
  fontWeight: 400
48
37
  },
49
-
50
38
  /* Styles applied to the root element if `color="primary"`. */
51
39
  colorPrimary: {
52
40
  color: theme.palette.primary.main,
53
41
  backgroundColor: (0, _styles.alpha)(theme.palette.primary.main, 0.08)
54
42
  },
55
-
56
43
  /* Styles applied to the root element if `color="secondary"`. */
57
44
  colorSecondary: {
58
45
  color: theme.palette.secondary.main,
59
46
  backgroundColor: (0, _styles.alpha)(theme.palette.secondary.main, 0.08)
60
47
  },
61
-
62
48
  /* Styles applied to the root element if `color="positive"`. */
63
49
  colorSuccess: {
64
50
  color: theme.palette.success.main,
65
51
  backgroundColor: (0, _styles.alpha)(theme.palette.success.main, 0.08)
66
52
  },
67
-
68
53
  /* Styles applied to the root element if `color="negative"`. */
69
54
  colorError: {
70
55
  color: theme.palette.error.main,
71
56
  backgroundColor: (0, _styles.alpha)(theme.palette.error.main, 0.08)
72
57
  },
73
-
74
58
  /* Styles applied to the root element if `color="warning"`. */
75
59
  colorWarning: {
76
60
  color: theme.palette.warning.main,
77
61
  backgroundColor: (0, _styles.alpha)(theme.palette.warning.main, 0.08)
78
62
  },
79
-
80
63
  /* Styles applied to the root element if `color="neutral"`. */
81
64
  colorNeutral: {
82
65
  color: theme.palette.neutral.main,
83
66
  backgroundColor: (0, _styles.alpha)(theme.palette.neutral.main, 0.08)
84
67
  },
85
-
86
68
  /* Styles applied to the root element if `color="info"`. */
87
69
  colorInfo: {
88
70
  color: theme.palette.info.main,
@@ -91,43 +73,36 @@ var styles = function styles(theme) {
91
73
  activeColor: {
92
74
  fontWeight: 500
93
75
  },
94
-
95
76
  /* Styles applied to the root element if `color="primary"`. */
96
77
  activeColorPrimary: {
97
78
  color: theme.palette.primary.contrastText,
98
79
  backgroundColor: theme.palette.primary.main
99
80
  },
100
-
101
81
  /* Styles applied to the root element if `color="secondary"`. */
102
82
  activeColorSecondary: {
103
83
  color: theme.palette.secondary.contrastText,
104
84
  backgroundColor: theme.palette.secondary.main
105
85
  },
106
-
107
86
  /* Styles applied to the root element if `color="success"`. */
108
87
  activeColorSuccess: {
109
88
  color: theme.palette.success.contrastText,
110
89
  backgroundColor: theme.palette.success.main
111
90
  },
112
-
113
91
  /* Styles applied to the root element if `color="negative"`. */
114
92
  activeColorError: {
115
93
  color: theme.palette.error.contrastText,
116
94
  backgroundColor: theme.palette.error.main
117
95
  },
118
-
119
96
  /* Styles applied to the root element if `color="warning"`. */
120
97
  activeColorWarning: {
121
98
  color: theme.palette.warning.contrastText,
122
99
  backgroundColor: theme.palette.warning.main
123
100
  },
124
-
125
101
  /* Styles applied to the root element if `color="neutral"`. */
126
102
  activeColorNeutral: {
127
103
  color: theme.palette.neutral.contrastText,
128
104
  backgroundColor: theme.palette.neutral.main
129
105
  },
130
-
131
106
  /* Styles applied to the root element if `color="info"`. */
132
107
  activeColorInfo: {
133
108
  color: theme.palette.info.contrastText,
@@ -138,34 +113,29 @@ var styles = function styles(theme) {
138
113
  }
139
114
  };
140
115
  };
116
+
141
117
  /**
142
118
  * HiColoredLabel
143
119
  *
144
120
  * Label with background color & text color
145
121
  */
146
-
147
-
148
- exports.styles = styles;
149
-
150
122
  function HiColoredLabel(props) {
151
- var _classNames;
152
-
153
123
  var classes = props.classes,
154
- className = props.className,
155
- fontSize = props.fontSize,
156
- label = props.label,
157
- propsColor = props.color,
158
- active = props.active,
159
- outlined = props.outlined,
160
- fontWeight = props.fontWeight,
161
- style = props.style,
162
- theme = props.theme,
163
- other = (0, _objectWithoutProperties2.default)(props, ["classes", "className", "fontSize", "label", "color", "active", "outlined", "fontWeight", "style", "theme"]);
124
+ className = props.className,
125
+ fontSize = props.fontSize,
126
+ label = props.label,
127
+ propsColor = props.color,
128
+ active = props.active,
129
+ outlined = props.outlined,
130
+ fontWeight = props.fontWeight,
131
+ style = props.style,
132
+ theme = props.theme,
133
+ other = (0, _objectWithoutProperties2.default)(props, ["classes", "className", "fontSize", "label", "color", "active", "outlined", "fontWeight", "style", "theme"]);
164
134
  var color = propsColor || 'primary';
165
135
  var isHiColor = ['primary', 'secondary', 'success', 'error', 'warning', 'neutral', 'info'].includes(color);
166
136
  var isHexColor = !isHiColor && /(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)/i.test(color);
167
137
  return /*#__PURE__*/_react.default.createElement("div", (0, _extends2.default)({
168
- className: (0, _classnames.default)(classes.root, (_classNames = {}, (0, _defineProperty2.default)(_classNames, classes.color, !active), (0, _defineProperty2.default)(_classNames, classes.activeColor, active), (0, _defineProperty2.default)(_classNames, classes.outlined, outlined), (0, _defineProperty2.default)(_classNames, classes["activeColor".concat((0, _helpers.capitalize)(color))], active && isHiColor), (0, _defineProperty2.default)(_classNames, classes["color".concat((0, _helpers.capitalize)(color))], !active && isHiColor), (0, _defineProperty2.default)(_classNames, classes.body1, fontSize >= 15), (0, _defineProperty2.default)(_classNames, classes.body2, fontSize === 14), (0, _defineProperty2.default)(_classNames, classes.body3, fontSize === 13), (0, _defineProperty2.default)(_classNames, classes.body4, fontSize === 12), (0, _defineProperty2.default)(_classNames, classes.body5, fontSize <= 11), _classNames), className),
138
+ className: (0, _classnames.default)(classes.root, (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, classes.color, !active), classes.activeColor, active), classes.outlined, outlined), classes["activeColor".concat((0, _helpers.capitalize)(color))], active && isHiColor), classes["color".concat((0, _helpers.capitalize)(color))], !active && isHiColor), classes.body1, fontSize >= 15), classes.body2, fontSize === 14), classes.body3, fontSize === 13), classes.body4, fontSize === 12), classes.body5, fontSize <= 11), className),
169
139
  style: (0, _objectSpread2.default)({}, style, {}, isHexColor && {
170
140
  backgroundColor: active ? color : (0, _styles.alpha)(color, 0.08),
171
141
  color: active ? theme.palette.getContrastText(color) : color
@@ -174,18 +144,14 @@ function HiColoredLabel(props) {
174
144
  })
175
145
  }, other), label);
176
146
  }
177
-
178
147
  HiColoredLabel.defaultProps = {
179
148
  active: false,
180
149
  color: 'primary',
181
150
  fontSize: 15,
182
151
  outlined: false
183
152
  };
184
-
185
- var _default = (0, _withStyles.default)(styles, {
153
+ var _default = exports.default = (0, _withStyles.default)(styles, {
186
154
  hiComponent: true,
187
155
  withTheme: true,
188
156
  name: 'HmuiHiColoredLabel'
189
- })(HiColoredLabel);
190
-
191
- exports.default = _default;
157
+ })(HiColoredLabel);
@@ -1,7 +1,6 @@
1
1
  "use strict";
2
2
 
3
3
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
@@ -11,5 +10,4 @@ Object.defineProperty(exports, "default", {
11
10
  return _HiColoredLabel.default;
12
11
  }
13
12
  });
14
-
15
13
  var _HiColoredLabel = _interopRequireDefault(require("./HiColoredLabel"));
@@ -1,21 +1,15 @@
1
1
  "use strict";
2
2
 
3
3
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
8
7
  exports.styles = exports.default = void 0;
9
-
10
8
  var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
11
-
12
9
  var _react = _interopRequireDefault(require("react"));
13
-
14
10
  var _withStyles = _interopRequireDefault(require("@mui/styles/withStyles"));
15
-
16
11
  var _HiButton = _interopRequireDefault(require("../HiButton"));
17
-
18
- var styles = function styles(theme) {
12
+ var styles = exports.styles = function styles(theme) {
19
13
  return {
20
14
  caption: (0, _objectSpread2.default)({
21
15
  display: 'table-caption',
@@ -27,17 +21,14 @@ var styles = function styles(theme) {
27
21
  })
28
22
  };
29
23
  };
30
-
31
- exports.styles = styles;
32
-
33
24
  var Caption = function Caption(_ref) {
34
25
  var classes = _ref.classes,
35
- date = _ref.date,
36
- _ref$locale = _ref.locale,
37
- locale = _ref$locale === void 0 ? 'en_US' : _ref$locale,
38
- localeUtils = _ref.localeUtils,
39
- onMonthClick = _ref.onMonthClick,
40
- onYearClick = _ref.onYearClick;
26
+ date = _ref.date,
27
+ _ref$locale = _ref.locale,
28
+ locale = _ref$locale === void 0 ? 'en_US' : _ref$locale,
29
+ localeUtils = _ref.localeUtils,
30
+ onMonthClick = _ref.onMonthClick,
31
+ onYearClick = _ref.onYearClick;
41
32
  var months = localeUtils.getMonths(locale);
42
33
  return /*#__PURE__*/_react.default.createElement("div", {
43
34
  className: classes.caption
@@ -49,9 +40,6 @@ var Caption = function Caption(_ref) {
49
40
  onClick: onYearClick
50
41
  }, date.getFullYear()));
51
42
  };
52
-
53
- var _default = (0, _withStyles.default)(styles, {
43
+ var _default = exports.default = (0, _withStyles.default)(styles, {
54
44
  name: 'HmuiCaption'
55
- })(Caption);
56
-
57
- exports.default = _default;
45
+ })(Caption);