@hipay/hipay-material-ui 2.3.1-rc4 → 2.3.1-rc5
Sign up to get free protection for your applications and to get access to all the features.
- package/HiAlertModal/HiAlertModal.js +77 -48
- package/HiAlertModal/index.js +15 -1
- package/HiAppBar/HiAppBar.js +63 -34
- package/HiAppBar/index.js +15 -1
- package/HiBadge/HiBadge.js +29 -10
- package/HiBadge/index.js +15 -1
- package/HiBreadcrumb/HiBreadcrumb.js +41 -27
- package/HiBreadcrumb/HiStep.js +58 -35
- package/HiBreadcrumb/HiStepConnector.js +58 -33
- package/HiBreadcrumb/HiStepContent.js +47 -26
- package/HiBreadcrumb/HiStepIcon.js +47 -27
- package/HiBreadcrumb/HiStepLabel.js +62 -37
- package/HiBreadcrumb/HiStepper.js +44 -24
- package/HiBreadcrumb/index.js +15 -1
- package/HiButton/HiButton.js +27 -9
- package/HiButton/index.js +13 -2
- package/HiCell/CellAddress.js +39 -21
- package/HiCell/CellDate.js +44 -27
- package/HiCell/CellIcon.js +48 -29
- package/HiCell/CellImage.js +41 -24
- package/HiCell/CellNumeric.js +45 -26
- package/HiCell/CellPinToAction.js +41 -20
- package/HiCell/CellRate.js +56 -33
- package/HiCell/CellSentinel.js +41 -23
- package/HiCell/CellSentinelScore.js +43 -24
- package/HiCell/CellText.js +54 -37
- package/HiCell/CellTextStyled.js +21 -8
- package/HiCell/index.js +79 -9
- package/HiCheckbox/HiCheckbox.js +61 -36
- package/HiCheckbox/index.js +15 -1
- package/HiChip/HiChip.js +44 -24
- package/HiChip/HiChipSwitch.js +73 -47
- package/HiChip/index.js +23 -2
- package/HiColoredLabel/HiColoredLabel.js +52 -28
- package/HiColoredLabel/index.js +15 -1
- package/HiDatePicker/Caption.js +28 -11
- package/HiDatePicker/HiDatePicker.js +131 -101
- package/HiDatePicker/HiDatePickerMobile.js +54 -32
- package/HiDatePicker/HiDateRangePicker.js +168 -139
- package/HiDatePicker/HiDateRangeSelector.js +105 -71
- package/HiDatePicker/ListPicker.js +54 -34
- package/HiDatePicker/NavBar.js +45 -18
- package/HiDatePicker/Overlays/CustomOverlayLayout.js +40 -23
- package/HiDatePicker/Overlays/CustomOverlayLayoutWithoutFooter.js +39 -22
- package/HiDatePicker/Overlays/MonthPickerOverlay.js +44 -30
- package/HiDatePicker/Overlays/Overlay.js +35 -18
- package/HiDatePicker/Overlays/TimePickerOverlay.js +72 -48
- package/HiDatePicker/Overlays/YearPickerOverlay.js +44 -30
- package/HiDatePicker/Overlays/index.js +47 -5
- package/HiDatePicker/Weekday.js +13 -3
- package/HiDatePicker/hiLocaleUtils.js +8 -1
- package/HiDatePicker/index.js +15 -1
- package/HiDatePicker/stylesheet.js +22 -9
- package/HiDotsStepper/HiDot.js +56 -31
- package/HiDotsStepper/HiDotsStepper.js +47 -28
- package/HiDotsStepper/index.js +23 -2
- package/HiExpansionPanel/HiExpansionPanel.js +73 -43
- package/HiExpansionPanel/index.js +13 -2
- package/HiForm/HiAddressField.js +46 -29
- package/HiForm/HiEmailField.js +45 -27
- package/HiForm/HiFormControl.js +105 -72
- package/HiForm/HiFormLabel.js +53 -30
- package/HiForm/HiInput.js +89 -62
- package/HiForm/HiPasswordField.js +55 -29
- package/HiForm/HiSearchField.js +43 -28
- package/HiForm/HiSlider.js +64 -41
- package/HiForm/HiTextField.js +46 -29
- package/HiForm/HiUpload.js +76 -53
- package/HiForm/HiUploadField.js +40 -25
- package/HiForm/HiUploadInput.js +84 -56
- package/HiForm/index.js +95 -11
- package/HiIcon/HiIcon.js +44 -22
- package/HiIcon/index.js +15 -1
- package/HiIconButton/HiIconButton.js +40 -18
- package/HiIconButton/index.js +15 -1
- package/HiLoader/HiLoader.js +24 -9
- package/HiLoader/index.js +15 -1
- package/HiMap/HiMap.js +76 -51
- package/HiMap/HiMapExpand.js +64 -39
- package/HiMap/index.js +23 -2
- package/HiNotice/HiKPI.js +56 -33
- package/HiNotice/HiKPINotice.js +21 -7
- package/HiNotice/index.js +23 -2
- package/HiPaymentMeans/HiPaymentMeans.js +133 -112
- package/HiPaymentMeans/index.js +15 -1
- package/HiPdfReader/HiPdfReader.js +78 -52
- package/HiPdfReader/index.js +15 -1
- package/HiPin/HiPin.js +30 -9
- package/HiPin/index.js +15 -1
- package/HiRadio/HiRadio.js +24 -7
- package/HiRadio/index.js +15 -1
- package/HiSelect/HiDynamicSelect.js +58 -40
- package/HiSelect/HiDynamicSelectField.js +40 -22
- package/HiSelect/HiNestedSelect.js +85 -55
- package/HiSelect/HiNestedSelectContent.js +72 -46
- package/HiSelect/HiNestedSelectField.js +40 -22
- package/HiSelect/HiSelect.js +161 -123
- package/HiSelect/HiSelectContent.js +104 -73
- package/HiSelect/HiSelectField.js +40 -22
- package/HiSelect/HiSelectInput.js +94 -63
- package/HiSelect/HiSelectMobile.js +54 -35
- package/HiSelect/HiSuggestSelect.js +83 -56
- package/HiSelect/HiSuggestSelectField.js +40 -22
- package/HiSelect/index.js +85 -8
- package/HiSelectableList/HiSelectableList.js +80 -49
- package/HiSelectableList/HiSelectableListHierarchic.js +55 -35
- package/HiSelectableList/HiSelectableListItem.js +101 -66
- package/HiSelectableList/index.js +31 -3
- package/HiSwitch/HiSwitch.js +45 -20
- package/HiSwitch/HiSwitchState.js +36 -15
- package/HiSwitch/index.js +23 -2
- package/HiTable/HiCellBuilder.js +69 -43
- package/HiTable/HiTable.js +46 -28
- package/HiTable/HiTableBody.js +34 -19
- package/HiTable/HiTableHeader.js +50 -29
- package/HiTable/HiTableRow.js +56 -29
- package/HiTable/constants.js +94 -43
- package/HiTable/index.js +15 -1
- package/es/HiAlertModal/HiAlertModal.js +77 -48
- package/es/HiAlertModal/index.js +15 -1
- package/es/HiAppBar/HiAppBar.js +63 -34
- package/es/HiAppBar/index.js +15 -1
- package/es/HiBadge/HiBadge.js +29 -10
- package/es/HiBadge/index.js +15 -1
- package/es/HiBreadcrumb/HiBreadcrumb.js +41 -27
- package/es/HiBreadcrumb/HiStep.js +58 -35
- package/es/HiBreadcrumb/HiStepConnector.js +58 -33
- package/es/HiBreadcrumb/HiStepContent.js +47 -26
- package/es/HiBreadcrumb/HiStepIcon.js +47 -27
- package/es/HiBreadcrumb/HiStepLabel.js +62 -37
- package/es/HiBreadcrumb/HiStepper.js +44 -24
- package/es/HiBreadcrumb/index.js +15 -1
- package/es/HiButton/HiButton.js +27 -9
- package/es/HiButton/index.js +13 -2
- package/es/HiCell/CellAddress.js +39 -21
- package/es/HiCell/CellDate.js +44 -27
- package/es/HiCell/CellIcon.js +48 -29
- package/es/HiCell/CellImage.js +41 -24
- package/es/HiCell/CellNumeric.js +45 -26
- package/es/HiCell/CellPinToAction.js +41 -20
- package/es/HiCell/CellRate.js +56 -33
- package/es/HiCell/CellSentinel.js +41 -23
- package/es/HiCell/CellSentinelScore.js +43 -24
- package/es/HiCell/CellText.js +54 -37
- package/es/HiCell/CellTextStyled.js +21 -8
- package/es/HiCell/index.js +79 -9
- package/es/HiCheckbox/HiCheckbox.js +61 -36
- package/es/HiCheckbox/index.js +15 -1
- package/es/HiChip/HiChip.js +44 -24
- package/es/HiChip/HiChipSwitch.js +73 -47
- package/es/HiChip/index.js +23 -2
- package/es/HiColoredLabel/HiColoredLabel.js +52 -28
- package/es/HiColoredLabel/index.js +15 -1
- package/es/HiDatePicker/Caption.js +28 -11
- package/es/HiDatePicker/HiDatePicker.js +131 -101
- package/es/HiDatePicker/HiDatePickerMobile.js +54 -32
- package/es/HiDatePicker/HiDateRangePicker.js +168 -139
- package/es/HiDatePicker/HiDateRangeSelector.js +105 -71
- package/es/HiDatePicker/ListPicker.js +54 -34
- package/es/HiDatePicker/NavBar.js +45 -18
- package/es/HiDatePicker/Overlays/CustomOverlayLayout.js +40 -23
- package/es/HiDatePicker/Overlays/CustomOverlayLayoutWithoutFooter.js +39 -22
- package/es/HiDatePicker/Overlays/MonthPickerOverlay.js +44 -30
- package/es/HiDatePicker/Overlays/Overlay.js +35 -18
- package/es/HiDatePicker/Overlays/TimePickerOverlay.js +72 -48
- package/es/HiDatePicker/Overlays/YearPickerOverlay.js +44 -30
- package/es/HiDatePicker/Overlays/index.js +47 -5
- package/es/HiDatePicker/Weekday.js +13 -3
- package/es/HiDatePicker/hiLocaleUtils.js +8 -1
- package/es/HiDatePicker/index.js +15 -1
- package/es/HiDatePicker/stylesheet.js +22 -9
- package/es/HiDotsStepper/HiDot.js +56 -31
- package/es/HiDotsStepper/HiDotsStepper.js +47 -28
- package/es/HiDotsStepper/index.js +23 -2
- package/es/HiExpansionPanel/HiExpansionPanel.js +73 -43
- package/es/HiExpansionPanel/index.js +13 -2
- package/es/HiForm/HiAddressField.js +46 -29
- package/es/HiForm/HiEmailField.js +45 -27
- package/es/HiForm/HiFormControl.js +105 -72
- package/es/HiForm/HiFormLabel.js +53 -30
- package/es/HiForm/HiInput.js +89 -62
- package/es/HiForm/HiPasswordField.js +55 -29
- package/es/HiForm/HiSearchField.js +43 -28
- package/es/HiForm/HiSlider.js +64 -41
- package/es/HiForm/HiTextField.js +46 -29
- package/es/HiForm/HiUpload.js +76 -53
- package/es/HiForm/HiUploadField.js +40 -25
- package/es/HiForm/HiUploadInput.js +84 -56
- package/es/HiForm/index.js +95 -11
- package/es/HiIcon/HiIcon.js +44 -22
- package/es/HiIcon/index.js +15 -1
- package/es/HiIconButton/HiIconButton.js +40 -18
- package/es/HiIconButton/index.js +15 -1
- package/es/HiLoader/HiLoader.js +24 -9
- package/es/HiLoader/index.js +15 -1
- package/es/HiMap/HiMap.js +76 -51
- package/es/HiMap/HiMapExpand.js +64 -39
- package/es/HiMap/index.js +23 -2
- package/es/HiNotice/HiKPI.js +56 -33
- package/es/HiNotice/HiKPINotice.js +21 -7
- package/es/HiNotice/index.js +23 -2
- package/es/HiPaymentMeans/HiPaymentMeans.js +133 -112
- package/es/HiPaymentMeans/index.js +15 -1
- package/es/HiPdfReader/HiPdfReader.js +78 -52
- package/es/HiPdfReader/index.js +15 -1
- package/es/HiPin/HiPin.js +30 -9
- package/es/HiPin/index.js +15 -1
- package/es/HiRadio/HiRadio.js +24 -7
- package/es/HiRadio/index.js +15 -1
- package/es/HiSelect/HiDynamicSelect.js +58 -40
- package/es/HiSelect/HiDynamicSelectField.js +40 -22
- package/es/HiSelect/HiNestedSelect.js +85 -55
- package/es/HiSelect/HiNestedSelectContent.js +72 -46
- package/es/HiSelect/HiNestedSelectField.js +40 -22
- package/es/HiSelect/HiSelect.js +161 -123
- package/es/HiSelect/HiSelectContent.js +104 -73
- package/es/HiSelect/HiSelectField.js +40 -22
- package/es/HiSelect/HiSelectInput.js +94 -63
- package/es/HiSelect/HiSelectMobile.js +54 -35
- package/es/HiSelect/HiSuggestSelect.js +83 -56
- package/es/HiSelect/HiSuggestSelectField.js +40 -22
- package/es/HiSelect/index.js +85 -8
- package/es/HiSelectableList/HiSelectableList.js +80 -49
- package/es/HiSelectableList/HiSelectableListHierarchic.js +55 -35
- package/es/HiSelectableList/HiSelectableListItem.js +101 -66
- package/es/HiSelectableList/index.js +31 -3
- package/es/HiSwitch/HiSwitch.js +45 -20
- package/es/HiSwitch/HiSwitchState.js +36 -15
- package/es/HiSwitch/index.js +23 -2
- package/es/HiTable/HiCellBuilder.js +69 -43
- package/es/HiTable/HiTable.js +46 -28
- package/es/HiTable/HiTableBody.js +34 -19
- package/es/HiTable/HiTableHeader.js +50 -29
- package/es/HiTable/HiTableRow.js +56 -29
- package/es/HiTable/constants.js +94 -43
- package/es/HiTable/index.js +15 -1
- package/es/hi-svg-icons/HiAccount.js +36 -18
- package/es/hi-svg-icons/HiActivity.js +35 -17
- package/es/hi-svg-icons/HiAll.js +42 -22
- package/es/hi-svg-icons/HiBilling.js +36 -18
- package/es/hi-svg-icons/HiBriefcaseRescue.js +26 -10
- package/es/hi-svg-icons/HiCatalog.js +36 -18
- package/es/hi-svg-icons/HiCustomer.js +36 -18
- package/es/hi-svg-icons/HiDownload.js +25 -11
- package/es/hi-svg-icons/HiFinance.js +36 -18
- package/es/hi-svg-icons/HiPermission.js +35 -17
- package/es/hi-svg-icons/HiRoute.js +36 -18
- package/es/hi-svg-icons/HiSettlement.js +36 -18
- package/es/hi-svg-icons/HiSizeLarge.js +27 -12
- package/es/hi-svg-icons/HiSizeMedium.js +25 -11
- package/es/hi-svg-icons/HiSizeSmall.js +25 -11
- package/es/hi-svg-icons/HiTransaction.js +36 -18
- package/es/hi-svg-icons/HiUser.js +36 -18
- package/es/hi-svg-icons/HiWidget.js +42 -22
- package/es/hi-svg-icons/index.js +151 -18
- package/es/hi-svg-icons/index.text.js +21 -11
- package/es/styleguide/Wrapper.js +36 -19
- package/es/styles/MuiThemeProvider.js +57 -39
- package/es/styles/colorManipulator.js +44 -16
- package/es/styles/createBreakpoints.js +20 -6
- package/es/styles/createGenerateClassName.js +15 -5
- package/es/styles/createMixins.js +19 -8
- package/es/styles/createMuiTheme.js +53 -34
- package/es/styles/createPalette.js +50 -30
- package/es/styles/createStyles.js +8 -1
- package/es/styles/createTypography.js +30 -18
- package/es/styles/getStylesCreator.js +24 -11
- package/es/styles/getThemeProps.js +9 -1
- package/es/styles/index.js +47 -5
- package/es/styles/jssPreset.js +25 -9
- package/es/styles/mergeClasses.js +19 -7
- package/es/styles/shadows.js +8 -1
- package/es/styles/shape.js +8 -1
- package/es/styles/spacing.js +9 -1
- package/es/styles/themeListener.js +18 -5
- package/es/styles/transitions.js +38 -18
- package/es/styles/zIndex.js +8 -1
- package/es/test-utils/createMount.js +22 -11
- package/es/test-utils/createRender.js +19 -8
- package/es/test-utils/createShallow.js +23 -13
- package/es/test-utils/getClasses.js +11 -2
- package/es/test-utils/index.js +47 -5
- package/es/test-utils/until.js +16 -6
- package/es/test-utils/unwrap.js +8 -1
- package/es/theme/palette.js +10 -2
- package/es/theme/typography.js +11 -3
- package/es/theme.js +13 -4
- package/es/transitions/utils.js +13 -2
- package/es/utils/exactProp.js +18 -5
- package/es/utils/helpers.js +55 -18
- package/es/withMobileDialog/index.js +15 -1
- package/es/withMobileDialog/withMobileDialog.js +22 -7
- package/hi-svg-icons/HiAccount.js +36 -18
- package/hi-svg-icons/HiActivity.js +35 -17
- package/hi-svg-icons/HiAll.js +42 -22
- package/hi-svg-icons/HiBilling.js +36 -18
- package/hi-svg-icons/HiBriefcaseRescue.js +26 -10
- package/hi-svg-icons/HiCatalog.js +36 -18
- package/hi-svg-icons/HiCustomer.js +36 -18
- package/hi-svg-icons/HiDownload.js +25 -11
- package/hi-svg-icons/HiFinance.js +36 -18
- package/hi-svg-icons/HiPermission.js +35 -17
- package/hi-svg-icons/HiRoute.js +36 -18
- package/hi-svg-icons/HiSettlement.js +36 -18
- package/hi-svg-icons/HiSizeLarge.js +27 -12
- package/hi-svg-icons/HiSizeMedium.js +25 -11
- package/hi-svg-icons/HiSizeSmall.js +25 -11
- package/hi-svg-icons/HiTransaction.js +36 -18
- package/hi-svg-icons/HiUser.js +36 -18
- package/hi-svg-icons/HiWidget.js +42 -22
- package/hi-svg-icons/index.js +151 -18
- package/hi-svg-icons/index.text.js +21 -11
- package/package.json +2 -1
- package/styleguide/Wrapper.js +36 -19
- package/styles/MuiThemeProvider.js +57 -39
- package/styles/colorManipulator.js +44 -16
- package/styles/createBreakpoints.js +20 -6
- package/styles/createGenerateClassName.js +15 -5
- package/styles/createMixins.js +19 -8
- package/styles/createMuiTheme.js +53 -34
- package/styles/createPalette.js +50 -30
- package/styles/createStyles.js +8 -1
- package/styles/createTypography.js +30 -18
- package/styles/getStylesCreator.js +24 -11
- package/styles/getThemeProps.js +9 -1
- package/styles/index.js +47 -5
- package/styles/jssPreset.js +25 -9
- package/styles/mergeClasses.js +19 -7
- package/styles/shadows.js +8 -1
- package/styles/shape.js +8 -1
- package/styles/spacing.js +9 -1
- package/styles/themeListener.js +18 -5
- package/styles/transitions.js +38 -18
- package/styles/zIndex.js +8 -1
- package/test-utils/createMount.js +22 -11
- package/test-utils/createRender.js +19 -8
- package/test-utils/createShallow.js +23 -13
- package/test-utils/getClasses.js +11 -2
- package/test-utils/index.js +47 -5
- package/test-utils/until.js +16 -6
- package/test-utils/unwrap.js +8 -1
- package/theme/palette.js +10 -2
- package/theme/typography.js +11 -3
- package/theme.js +13 -4
- package/transitions/utils.js +13 -2
- package/utils/exactProp.js +18 -5
- package/utils/helpers.js +55 -18
- package/withMobileDialog/index.js +15 -1
- package/withMobileDialog/withMobileDialog.js +22 -7
- package/App.test.js +0 -8
- package/HiAlertModal/HiAlertModal.test.js +0 -189
- package/HiBadge/HiBadge.test.js +0 -49
- package/HiBreadcrumb/HiBreadcrumb.test.js +0 -44
- package/HiBreadcrumb/HiStep.test.js +0 -47
- package/HiBreadcrumb/HiStepConnector.test.js +0 -113
- package/HiBreadcrumb/HiStepContent.test.js +0 -32
- package/HiBreadcrumb/HiStepIcon.test.js +0 -65
- package/HiBreadcrumb/HiStepLabel.test.js +0 -30
- package/HiBreadcrumb/HiStepper.test.js +0 -33
- package/HiCell/CellAddress.test.js +0 -75
- package/HiCell/CellDate.test.js +0 -173
- package/HiCell/CellIcon.test.js +0 -57
- package/HiCell/CellImage.test.js +0 -49
- package/HiCell/CellNumeric.test.js +0 -46
- package/HiCell/CellRate.test.js +0 -73
- package/HiCell/CellSentinel.test.js +0 -48
- package/HiCell/CellText.test.js +0 -76
- package/HiCheckbox/HiCheckbox.test.js +0 -55
- package/HiChip/HiChip.test.js +0 -136
- package/HiChip/HiChipSwitch.test.js +0 -99
- package/HiColoredLabel/HiColoredLabel.test.js +0 -96
- package/HiDatePicker/Caption.test.js +0 -65
- package/HiDatePicker/HiDatePicker.test.js +0 -370
- package/HiDatePicker/HiDateRangePicker.test.js +0 -703
- package/HiDatePicker/HiDateRangeSelector.test.js +0 -193
- package/HiDatePicker/ListPicker.test.js +0 -53
- package/HiDatePicker/NavBar.test.js +0 -39
- package/HiDatePicker/Overlays/MonthPickerOverlay.test.js +0 -50
- package/HiDatePicker/Overlays/Overlay.test.js +0 -20
- package/HiDatePicker/Overlays/TimePickerOverlay.test.js +0 -48
- package/HiDatePicker/Overlays/YearPickerOverlay.test.js +0 -79
- package/HiDatePicker/hiLocaleUtils.test.js +0 -51
- package/HiDotsStepper/HiDot.test.js +0 -55
- package/HiDotsStepper/HiDotsStepper.test.js +0 -90
- package/HiForm/HiAddressField.test.js +0 -79
- package/HiForm/HiEmailField.test.js +0 -19
- package/HiForm/HiFormControl.test.js +0 -195
- package/HiForm/HiFormLabel.test.js +0 -66
- package/HiForm/HiInput.test.js +0 -202
- package/HiForm/HiPasswordField.test.js +0 -60
- package/HiForm/HiSearchField.test.js +0 -193
- package/HiForm/HiSlider.test.js +0 -99
- package/HiForm/HiTextField.test.js +0 -254
- package/HiForm/HiUpload.test.js +0 -241
- package/HiForm/HiUploadField.test.js +0 -55
- package/HiForm/HiUploadInput.test.js +0 -148
- package/HiIconButton/HiIconButton.test.js +0 -69
- package/HiLoader/HiLoader.test.js +0 -18
- package/HiMap/HiMap.test.js +0 -29
- package/HiMap/HiMapExpand.test.js +0 -48
- package/HiNotice/HiKPI.test.js +0 -171
- package/HiNotice/HiKPINotice.test.js +0 -88
- package/HiPaymentMeans/HiPaymentMeans.test.js +0 -162
- package/HiPin/HiPin.test.js +0 -61
- package/HiRadio/HiRadio.test.js +0 -57
- package/HiSelect/HiSelect.test.js +0 -1092
- package/HiSelect/HiSelectInput.test.js +0 -21
- package/HiSelectableList/HiSelectableList.test.js +0 -173
- package/HiSelectableList/HiSelectableListItem.test.js +0 -97
- package/HiSwitch/HiSwitch.test.js +0 -41
- package/HiSwitch/HiSwitchState.test.js +0 -76
- package/HiTable/HiTable.test.js +0 -29
- package/es/App.test.js +0 -8
- package/es/HiAlertModal/HiAlertModal.test.js +0 -189
- package/es/HiBadge/HiBadge.test.js +0 -49
- package/es/HiBreadcrumb/HiBreadcrumb.test.js +0 -44
- package/es/HiBreadcrumb/HiStep.test.js +0 -47
- package/es/HiBreadcrumb/HiStepConnector.test.js +0 -113
- package/es/HiBreadcrumb/HiStepContent.test.js +0 -32
- package/es/HiBreadcrumb/HiStepIcon.test.js +0 -65
- package/es/HiBreadcrumb/HiStepLabel.test.js +0 -30
- package/es/HiBreadcrumb/HiStepper.test.js +0 -33
- package/es/HiCell/CellAddress.test.js +0 -75
- package/es/HiCell/CellDate.test.js +0 -173
- package/es/HiCell/CellIcon.test.js +0 -57
- package/es/HiCell/CellImage.test.js +0 -49
- package/es/HiCell/CellNumeric.test.js +0 -46
- package/es/HiCell/CellRate.test.js +0 -73
- package/es/HiCell/CellSentinel.test.js +0 -48
- package/es/HiCell/CellText.test.js +0 -76
- package/es/HiCheckbox/HiCheckbox.test.js +0 -55
- package/es/HiChip/HiChip.test.js +0 -136
- package/es/HiChip/HiChipSwitch.test.js +0 -99
- package/es/HiColoredLabel/HiColoredLabel.test.js +0 -96
- package/es/HiDatePicker/Caption.test.js +0 -65
- package/es/HiDatePicker/HiDatePicker.test.js +0 -370
- package/es/HiDatePicker/HiDateRangePicker.test.js +0 -703
- package/es/HiDatePicker/HiDateRangeSelector.test.js +0 -193
- package/es/HiDatePicker/ListPicker.test.js +0 -53
- package/es/HiDatePicker/NavBar.test.js +0 -39
- package/es/HiDatePicker/Overlays/MonthPickerOverlay.test.js +0 -50
- package/es/HiDatePicker/Overlays/Overlay.test.js +0 -20
- package/es/HiDatePicker/Overlays/TimePickerOverlay.test.js +0 -48
- package/es/HiDatePicker/Overlays/YearPickerOverlay.test.js +0 -79
- package/es/HiDatePicker/hiLocaleUtils.test.js +0 -51
- package/es/HiDotsStepper/HiDot.test.js +0 -55
- package/es/HiDotsStepper/HiDotsStepper.test.js +0 -90
- package/es/HiForm/HiAddressField.test.js +0 -79
- package/es/HiForm/HiEmailField.test.js +0 -19
- package/es/HiForm/HiFormControl.test.js +0 -195
- package/es/HiForm/HiFormLabel.test.js +0 -66
- package/es/HiForm/HiInput.test.js +0 -202
- package/es/HiForm/HiPasswordField.test.js +0 -60
- package/es/HiForm/HiSearchField.test.js +0 -193
- package/es/HiForm/HiSlider.test.js +0 -99
- package/es/HiForm/HiTextField.test.js +0 -254
- package/es/HiForm/HiUpload.test.js +0 -241
- package/es/HiForm/HiUploadField.test.js +0 -55
- package/es/HiForm/HiUploadInput.test.js +0 -148
- package/es/HiIconButton/HiIconButton.test.js +0 -69
- package/es/HiLoader/HiLoader.test.js +0 -18
- package/es/HiMap/HiMap.test.js +0 -29
- package/es/HiMap/HiMapExpand.test.js +0 -48
- package/es/HiNotice/HiKPI.test.js +0 -171
- package/es/HiNotice/HiKPINotice.test.js +0 -88
- package/es/HiPaymentMeans/HiPaymentMeans.test.js +0 -162
- package/es/HiPin/HiPin.test.js +0 -61
- package/es/HiRadio/HiRadio.test.js +0 -57
- package/es/HiSelect/HiSelect.test.js +0 -1092
- package/es/HiSelect/HiSelectInput.test.js +0 -21
- package/es/HiSelectableList/HiSelectableList.test.js +0 -173
- package/es/HiSelectableList/HiSelectableListItem.test.js +0 -97
- package/es/HiSwitch/HiSwitch.test.js +0 -41
- package/es/HiSwitch/HiSwitchState.test.js +0 -76
- package/es/HiTable/HiTable.test.js +0 -29
- package/es/styles/colorManipulator.test.js +0 -242
- package/es/styles/createBreakpoints.test.js +0 -48
- package/es/styles/createGenerateClassName.test.js +0 -141
- package/es/styles/createMixins.test.js +0 -24
- package/es/styles/createMuiTheme.test.js +0 -67
- package/es/styles/createPalette.test.js +0 -159
- package/es/styles/createStyles.test.js +0 -8
- package/es/styles/createTypography.test.js +0 -60
- package/es/styles/getStylesCreator.test.js +0 -92
- package/es/styles/getThemeProps.test.js +0 -39
- package/es/styles/themeListener.test.js +0 -26
- package/es/styles/transitions.test.js +0 -208
- package/es/test-utils/until.test.js +0 -157
- package/es/withMobileDialog/withMobileDialog.test.js +0 -67
- package/styles/colorManipulator.test.js +0 -242
- package/styles/createBreakpoints.test.js +0 -48
- package/styles/createGenerateClassName.test.js +0 -141
- package/styles/createMixins.test.js +0 -24
- package/styles/createMuiTheme.test.js +0 -67
- package/styles/createPalette.test.js +0 -159
- package/styles/createStyles.test.js +0 -8
- package/styles/createTypography.test.js +0 -60
- package/styles/getStylesCreator.test.js +0 -92
- package/styles/getThemeProps.test.js +0 -39
- package/styles/themeListener.test.js +0 -26
- package/styles/transitions.test.js +0 -208
- package/test-utils/until.test.js +0 -157
- package/withMobileDialog/withMobileDialog.test.js +0 -67
@@ -1,45 +1,80 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4
|
+
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
6
|
+
value: true
|
7
|
+
});
|
8
|
+
exports.default = void 0;
|
9
|
+
|
10
|
+
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/defineProperty"));
|
11
|
+
|
12
|
+
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectWithoutProperties"));
|
13
|
+
|
14
|
+
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
|
15
|
+
|
16
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/extends"));
|
17
|
+
|
18
|
+
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/classCallCheck"));
|
19
|
+
|
20
|
+
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/createClass"));
|
21
|
+
|
22
|
+
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/possibleConstructorReturn"));
|
23
|
+
|
24
|
+
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/getPrototypeOf"));
|
25
|
+
|
26
|
+
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/inherits"));
|
27
|
+
|
28
|
+
var _react = _interopRequireDefault(require("react"));
|
29
|
+
|
30
|
+
var _momentTimezone = _interopRequireDefault(require("moment-timezone"));
|
31
|
+
|
32
|
+
var _moment = _interopRequireDefault(require("react-day-picker/moment"));
|
33
|
+
|
34
|
+
var _hiLocaleUtils = _interopRequireDefault(require("./hiLocaleUtils"));
|
35
|
+
|
36
|
+
var _DayPickerInput = _interopRequireDefault(require("react-day-picker/DayPickerInput"));
|
37
|
+
|
38
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
39
|
+
|
40
|
+
var _styles = require("@material-ui/core/styles");
|
41
|
+
|
42
|
+
var _Caption = _interopRequireDefault(require("./Caption"));
|
43
|
+
|
44
|
+
var _Overlay = _interopRequireDefault(require("./Overlays/Overlay"));
|
45
|
+
|
46
|
+
var _TimePickerOverlay = _interopRequireDefault(require("./Overlays/TimePickerOverlay"));
|
47
|
+
|
48
|
+
var _MonthPickerOverlay = _interopRequireDefault(require("./Overlays/MonthPickerOverlay"));
|
49
|
+
|
50
|
+
var _YearPickerOverlay = _interopRequireDefault(require("./Overlays/YearPickerOverlay"));
|
51
|
+
|
52
|
+
var _NavBar = _interopRequireDefault(require("./NavBar"));
|
53
|
+
|
54
|
+
var _Weekday = _interopRequireDefault(require("./Weekday"));
|
55
|
+
|
56
|
+
var _HiForm = require("../HiForm");
|
57
|
+
|
58
|
+
var _stylesheet = _interopRequireDefault(require("./stylesheet"));
|
59
|
+
|
60
|
+
var _HiFormControl = _interopRequireDefault(require("../HiForm/HiFormControl"));
|
61
|
+
|
62
|
+
var _reactDeviceDetect = require("react-device-detect");
|
63
|
+
|
64
|
+
var _HiDatePickerMobile = _interopRequireDefault(require("./HiDatePickerMobile"));
|
29
65
|
|
30
66
|
var HiDateRangePicker =
|
31
67
|
/*#__PURE__*/
|
32
68
|
function (_React$Component) {
|
33
|
-
|
69
|
+
(0, _inherits2.default)(HiDateRangePicker, _React$Component);
|
34
70
|
|
35
71
|
function HiDateRangePicker(props) {
|
36
72
|
var _this;
|
37
73
|
|
38
|
-
|
74
|
+
(0, _classCallCheck2.default)(this, HiDateRangePicker);
|
75
|
+
_this = (0, _possibleConstructorReturn2.default)(this, (0, _getPrototypeOf2.default)(HiDateRangePicker).call(this, props));
|
39
76
|
|
40
|
-
_this =
|
41
|
-
|
42
|
-
_defineProperty(_assertThisInitialized(_this), "handleDayChange", function (name, day) {
|
77
|
+
_this.handleDayChange = function (name, day) {
|
43
78
|
if (day) {
|
44
79
|
// if time disabled, focus TO input
|
45
80
|
// else focus current input
|
@@ -65,17 +100,17 @@ function (_React$Component) {
|
|
65
100
|
_this.openPanel('time');
|
66
101
|
}
|
67
102
|
}
|
68
|
-
}
|
103
|
+
};
|
69
104
|
|
70
|
-
|
105
|
+
_this.handleInputChange = function (inputName) {
|
71
106
|
return function (event) {
|
72
107
|
_this.handleChange(inputName, event.target.value);
|
73
108
|
};
|
74
|
-
}
|
109
|
+
};
|
75
110
|
|
76
|
-
|
77
|
-
var change =
|
78
|
-
var today =
|
111
|
+
_this.onDayToClick = function (day) {
|
112
|
+
var change = (0, _momentTimezone.default)(day) >= (0, _momentTimezone.default)(_this.props.from);
|
113
|
+
var today = (0, _momentTimezone.default)().tz(_this.props.timezoneName);
|
79
114
|
var todayDate = new Date(today.year(), today.month(), today.date(), 23, 59, 59);
|
80
115
|
|
81
116
|
if (change && day > todayDate) {
|
@@ -87,9 +122,9 @@ function (_React$Component) {
|
|
87
122
|
|
88
123
|
document.activeElement.blur();
|
89
124
|
}
|
90
|
-
}
|
125
|
+
};
|
91
126
|
|
92
|
-
|
127
|
+
_this.handleTimeChange = function (name, date, precision) {
|
93
128
|
_this.handleChange(name, date);
|
94
129
|
|
95
130
|
if (name === 'from' && precision === 'minute') {
|
@@ -105,15 +140,15 @@ function (_React$Component) {
|
|
105
140
|
|
106
141
|
document.activeElement.blur();
|
107
142
|
}
|
108
|
-
}
|
143
|
+
};
|
109
144
|
|
110
|
-
|
145
|
+
_this.handleChange = function (name, day) {
|
111
146
|
var _this$props = _this.props,
|
112
147
|
translations = _this$props.translations,
|
113
148
|
timezoneName = _this$props.timezoneName;
|
114
149
|
var date;
|
115
150
|
var error;
|
116
|
-
var today =
|
151
|
+
var today = (0, _momentTimezone.default)().tz(timezoneName);
|
117
152
|
var now = new Date(today.year(), today.month(), today.date(), 23, 59, 59);
|
118
153
|
var _this$props2 = _this.props,
|
119
154
|
minimumDate = _this$props2.minimumDate,
|
@@ -123,7 +158,7 @@ function (_React$Component) {
|
|
123
158
|
if (day instanceof Date) {
|
124
159
|
date = day;
|
125
160
|
} else if (day) {
|
126
|
-
var parsedValue =
|
161
|
+
var parsedValue = (0, _momentTimezone.default)(day, _this.props.format, true);
|
127
162
|
|
128
163
|
if (parsedValue.isValid()) {
|
129
164
|
date = parsedValue.toDate();
|
@@ -133,14 +168,14 @@ function (_React$Component) {
|
|
133
168
|
}
|
134
169
|
|
135
170
|
if (date) {
|
136
|
-
var comparativeDate = name === 'to' ?
|
171
|
+
var comparativeDate = name === 'to' ? (0, _momentTimezone.default)(_this.props.from) : (0, _momentTimezone.default)(_this.props.to);
|
137
172
|
|
138
|
-
if (name === 'to' && comparativeDate >
|
173
|
+
if (name === 'to' && comparativeDate > (0, _momentTimezone.default)(date) || name === 'from' && comparativeDate < (0, _momentTimezone.default)(date)) {
|
139
174
|
error = translations.to_superior_from;
|
140
|
-
} else if (
|
141
|
-
error = translations.date_inferior_min_date.replace('%s',
|
175
|
+
} else if ((0, _momentTimezone.default)(date).utc() < (0, _momentTimezone.default)(minimumDate).utc().startOf('day')) {
|
176
|
+
error = translations.date_inferior_min_date.replace('%s', (0, _momentTimezone.default)(minimumDate).format(format));
|
142
177
|
} else if (disableFutureDays && date > now) {
|
143
|
-
error = translations.date_superior_max_date.replace('%s',
|
178
|
+
error = translations.date_superior_max_date.replace('%s', (0, _momentTimezone.default)().tz(timezoneName).format(format));
|
144
179
|
}
|
145
180
|
|
146
181
|
if (!_this.props.enableTime) {
|
@@ -155,9 +190,9 @@ function (_React$Component) {
|
|
155
190
|
_this.props.onChange(name, date);
|
156
191
|
|
157
192
|
_this.props.onChange("".concat(name, "Error"), error);
|
158
|
-
}
|
193
|
+
};
|
159
194
|
|
160
|
-
|
195
|
+
_this.handleChangeMobile = function (inputName) {
|
161
196
|
return function (event) {
|
162
197
|
var date;
|
163
198
|
|
@@ -167,22 +202,22 @@ function (_React$Component) {
|
|
167
202
|
|
168
203
|
_this.props.onChange(inputName, date);
|
169
204
|
};
|
170
|
-
}
|
205
|
+
};
|
171
206
|
|
172
|
-
|
207
|
+
_this.handleCurrentMonthChange = function (day) {
|
173
208
|
_this.setState({
|
174
209
|
currentMonth: day,
|
175
210
|
openedPanel: 'calendar'
|
176
211
|
});
|
177
|
-
}
|
212
|
+
};
|
178
213
|
|
179
|
-
|
214
|
+
_this.handleDayPickerFocus = function (name) {
|
180
215
|
_this.setState({
|
181
216
|
focusedInput: name
|
182
217
|
});
|
183
|
-
}
|
218
|
+
};
|
184
219
|
|
185
|
-
|
220
|
+
_this.handleDayPickerBlur = function (name) {
|
186
221
|
_this.setState({
|
187
222
|
focusedInput: ''
|
188
223
|
});
|
@@ -198,13 +233,13 @@ function (_React$Component) {
|
|
198
233
|
});
|
199
234
|
}
|
200
235
|
}, 100);
|
201
|
-
}
|
236
|
+
};
|
202
237
|
|
203
|
-
|
238
|
+
_this.handleReset = function (name) {
|
204
239
|
_this.handleChange(name, undefined);
|
205
|
-
}
|
240
|
+
};
|
206
241
|
|
207
|
-
|
242
|
+
_this.handleKeyDown = function (name) {
|
208
243
|
return function (event) {
|
209
244
|
if (event.key === 'Tab' && !event.shiftKey) {
|
210
245
|
var nodeName = document.activeElement.nodeName;
|
@@ -240,16 +275,16 @@ function (_React$Component) {
|
|
240
275
|
event.stopPropagation();
|
241
276
|
}
|
242
277
|
};
|
243
|
-
}
|
278
|
+
};
|
244
279
|
|
245
|
-
|
280
|
+
_this.openPanel = function (panel) {
|
246
281
|
_this.setState({
|
247
282
|
openedPanel: panel
|
248
283
|
});
|
249
|
-
}
|
284
|
+
};
|
250
285
|
|
251
|
-
|
252
|
-
return
|
286
|
+
_this.renderCaption = function (propsCaption) {
|
287
|
+
return _react.default.createElement(_Caption.default, (0, _extends2.default)({
|
253
288
|
onMonthClick: function onMonthClick() {
|
254
289
|
return _this.openPanel('months');
|
255
290
|
},
|
@@ -257,19 +292,19 @@ function (_React$Component) {
|
|
257
292
|
return _this.openPanel('years');
|
258
293
|
}
|
259
294
|
}, propsCaption));
|
260
|
-
}
|
295
|
+
};
|
261
296
|
|
262
|
-
|
263
|
-
return
|
297
|
+
_this.renderNavBar = function (propsNavBar) {
|
298
|
+
return _react.default.createElement(_NavBar.default, (0, _extends2.default)({
|
264
299
|
showClockButton: _this.props.enableTime,
|
265
300
|
onClockClick: function onClockClick() {
|
266
301
|
return _this.openPanel('time');
|
267
302
|
}
|
268
303
|
}, propsNavBar));
|
269
|
-
}
|
304
|
+
};
|
270
305
|
|
271
|
-
|
272
|
-
var rangeOverlayProps =
|
306
|
+
_this.renderOverlay = function (name, propsOverlay, staticPosition) {
|
307
|
+
var rangeOverlayProps = (0, _objectSpread2.default)({}, propsOverlay, {
|
273
308
|
side: name,
|
274
309
|
staticPosition: staticPosition
|
275
310
|
});
|
@@ -286,29 +321,29 @@ function (_React$Component) {
|
|
286
321
|
|
287
322
|
case 'calendar':
|
288
323
|
default:
|
289
|
-
return
|
324
|
+
return _react.default.createElement(_Overlay.default, rangeOverlayProps);
|
290
325
|
}
|
291
|
-
}
|
326
|
+
};
|
292
327
|
|
293
|
-
|
328
|
+
_this.renderOverlayFrom = function (propsOverlay) {
|
294
329
|
return _this.renderOverlay('from', propsOverlay, _this.props.staticPosition);
|
295
|
-
}
|
330
|
+
};
|
296
331
|
|
297
|
-
|
332
|
+
_this.renderOverlayTo = function (propsOverlay) {
|
298
333
|
return _this.renderOverlay('to', propsOverlay, _this.props.staticPosition);
|
299
|
-
}
|
334
|
+
};
|
300
335
|
|
301
|
-
|
336
|
+
_this.renderMonthPickerOverlay = function (name, propsOverlay) {
|
302
337
|
var monthPickerProps = {
|
303
338
|
value: _this.state.currentMonth,
|
304
339
|
onChange: _this.handleCurrentMonthChange
|
305
340
|
};
|
306
|
-
return
|
341
|
+
return _react.default.createElement(_MonthPickerOverlay.default, (0, _extends2.default)({
|
307
342
|
key: "".concat(name, "-month-picker-overlay")
|
308
343
|
}, monthPickerProps, propsOverlay));
|
309
|
-
}
|
344
|
+
};
|
310
345
|
|
311
|
-
|
346
|
+
_this.renderTimePickerOverlay = function (name, propsOverlay) {
|
312
347
|
var timePickerProps = {
|
313
348
|
value: _this.props[name],
|
314
349
|
onChange: function onChange(date, precision) {
|
@@ -318,23 +353,23 @@ function (_React$Component) {
|
|
318
353
|
return _this.openPanel('calendar');
|
319
354
|
}
|
320
355
|
};
|
321
|
-
return
|
356
|
+
return _react.default.createElement(_TimePickerOverlay.default, (0, _extends2.default)({
|
322
357
|
key: "".concat(name, "-time-picker-overlay")
|
323
358
|
}, timePickerProps, propsOverlay));
|
324
|
-
}
|
359
|
+
};
|
325
360
|
|
326
|
-
|
361
|
+
_this.renderYearPickerOverlay = function (name, propsOverlay) {
|
327
362
|
var yearPickerProps = {
|
328
363
|
value: _this.state.currentMonth,
|
329
364
|
onChange: _this.handleCurrentMonthChange,
|
330
365
|
disableFutureDays: _this.props.disableFutureDays
|
331
366
|
};
|
332
|
-
return
|
367
|
+
return _react.default.createElement(_YearPickerOverlay.default, (0, _extends2.default)({
|
333
368
|
key: "".concat(name, "-year-picker-overlay")
|
334
369
|
}, yearPickerProps, propsOverlay));
|
335
|
-
}
|
370
|
+
};
|
336
371
|
|
337
|
-
var _today =
|
372
|
+
var _today = (0, _momentTimezone.default)().tz(_this.props.timezoneName);
|
338
373
|
|
339
374
|
_this.state = {
|
340
375
|
currentMonth: new Date(_today.year(), _today.month(), _today.date()),
|
@@ -344,7 +379,7 @@ function (_React$Component) {
|
|
344
379
|
return _this;
|
345
380
|
}
|
346
381
|
|
347
|
-
|
382
|
+
(0, _createClass2.default)(HiDateRangePicker, [{
|
348
383
|
key: "componentWillUnmount",
|
349
384
|
value: function componentWillUnmount() {
|
350
385
|
clearTimeout(this.timeout);
|
@@ -379,16 +414,13 @@ function (_React$Component) {
|
|
379
414
|
helperIcon = _this$props3.helperIcon,
|
380
415
|
helperText = _this$props3.helperText,
|
381
416
|
timezoneName = _this$props3.timezoneName,
|
382
|
-
props =
|
383
|
-
|
384
|
-
var today = moment().tz(timezoneName);
|
417
|
+
props = (0, _objectWithoutProperties2.default)(_this$props3, ["classes", "disabled", "disabledDays", "disableFutureDays", "enableTime", "labelFrom", "labelTo", "locale", "format", "from", "fromError", "minimumDate", "onReset", "to", "toError", "translations", "id", "staticPosition", "errorText", "hasSelector", "helperIcon", "helperText", "timezoneName"]);
|
418
|
+
var today = (0, _momentTimezone.default)().tz(timezoneName);
|
385
419
|
var now = new Date(today.year(), today.month(), today.date(), 23, 59, 59, 999);
|
386
|
-
|
387
|
-
var modifiers = _defineProperty({
|
420
|
+
var modifiers = (0, _defineProperty2.default)({
|
388
421
|
start: from,
|
389
422
|
end: to
|
390
423
|
}, classes.currentDay, new Date(today.year(), today.month(), today.date()));
|
391
|
-
|
392
424
|
var modifiersStyles = {
|
393
425
|
start: {
|
394
426
|
borderTopLeftRadius: '50%',
|
@@ -416,7 +448,7 @@ function (_React$Component) {
|
|
416
448
|
selectedDays.push(selected);
|
417
449
|
}
|
418
450
|
|
419
|
-
var dayPickerProps =
|
451
|
+
var dayPickerProps = (0, _objectSpread2.default)({
|
420
452
|
classNames: classes,
|
421
453
|
disabledDays: disabledDays,
|
422
454
|
firstDayOfWeek: 1,
|
@@ -427,14 +459,13 @@ function (_React$Component) {
|
|
427
459
|
// Both are required ?
|
428
460
|
selectedDays: selectedDays,
|
429
461
|
todayButton: translations.today,
|
430
|
-
weekdayElement:
|
462
|
+
weekdayElement: _Weekday.default
|
431
463
|
}, props);
|
432
|
-
|
433
|
-
var fromDayPickerProps = _objectSpread({}, dayPickerProps, {
|
464
|
+
var fromDayPickerProps = (0, _objectSpread2.default)({}, dayPickerProps, {
|
434
465
|
onTodayButtonClick: this.handleCurrentMonthChange,
|
435
466
|
navbarElement: this.renderNavBar,
|
436
467
|
captionElement: this.renderCaption,
|
437
|
-
disabledDays:
|
468
|
+
disabledDays: (0, _objectSpread2.default)({}, dayPickerProps.disabledDays, {
|
438
469
|
before: minimumDate
|
439
470
|
}, disableFutureDays && {
|
440
471
|
after: now
|
@@ -442,17 +473,16 @@ function (_React$Component) {
|
|
442
473
|
after: to
|
443
474
|
}),
|
444
475
|
locale: locale,
|
445
|
-
localeUtils:
|
476
|
+
localeUtils: _hiLocaleUtils.default,
|
446
477
|
month: this.state.currentMonth,
|
447
|
-
modifiers:
|
478
|
+
modifiers: (0, _objectSpread2.default)({}, modifiers)
|
448
479
|
});
|
449
|
-
|
450
|
-
var toDayPickerProps = _objectSpread({}, dayPickerProps, {
|
480
|
+
var toDayPickerProps = (0, _objectSpread2.default)({}, dayPickerProps, {
|
451
481
|
onTodayButtonClick: this.handleCurrentMonthChange,
|
452
482
|
navbarElement: this.renderNavBar,
|
453
483
|
onDayClick: this.onDayToClick,
|
454
484
|
captionElement: this.renderCaption,
|
455
|
-
disabledDays:
|
485
|
+
disabledDays: (0, _objectSpread2.default)({}, dayPickerProps.disabledDays, {
|
456
486
|
before: minimumDate
|
457
487
|
}, disableFutureDays && {
|
458
488
|
after: now
|
@@ -460,13 +490,12 @@ function (_React$Component) {
|
|
460
490
|
before: from
|
461
491
|
}),
|
462
492
|
locale: locale,
|
463
|
-
localeUtils:
|
493
|
+
localeUtils: _hiLocaleUtils.default,
|
464
494
|
month: this.state.currentMonth,
|
465
|
-
modifiers:
|
495
|
+
modifiers: (0, _objectSpread2.default)({}, modifiers)
|
466
496
|
}); // From & To InputProps
|
467
497
|
|
468
|
-
|
469
|
-
var fromInputProps = _objectSpread({}, onReset && {
|
498
|
+
var fromInputProps = (0, _objectSpread2.default)({}, onReset && {
|
470
499
|
onReset: function onReset() {
|
471
500
|
return _this2.handleReset('from');
|
472
501
|
}
|
@@ -482,8 +511,7 @@ function (_React$Component) {
|
|
482
511
|
onSubmit: this.props.onSubmit
|
483
512
|
}
|
484
513
|
});
|
485
|
-
|
486
|
-
var toInputProps = _objectSpread({}, onReset && {
|
514
|
+
var toInputProps = (0, _objectSpread2.default)({}, onReset && {
|
487
515
|
onReset: function onReset() {
|
488
516
|
return _this2.handleReset('to');
|
489
517
|
}
|
@@ -499,17 +527,17 @@ function (_React$Component) {
|
|
499
527
|
onSubmit: this.props.onSubmit
|
500
528
|
}
|
501
529
|
});
|
530
|
+
var toClass = (0, _classnames.default)(classes.toInput, (_classNames = {}, (0, _defineProperty2.default)(_classNames, classes.absolute, !_reactDeviceDetect.isMobile && staticPosition === true && this.state.focusedInput === 'from'), (0, _defineProperty2.default)(_classNames, classes.right4, !_reactDeviceDetect.isMobile && staticPosition === true && this.state.focusedInput === 'from'), _classNames));
|
502
531
|
|
503
|
-
var
|
504
|
-
|
505
|
-
|
506
|
-
}, React.createElement("div", {
|
532
|
+
var content = _react.default.createElement("div", {
|
533
|
+
className: (0, _classnames.default)(classes.root, classes.rangePickerContainer)
|
534
|
+
}, _react.default.createElement("div", {
|
507
535
|
className: classes.fromInput,
|
508
|
-
onFocus: !isMobile ? function () {
|
536
|
+
onFocus: !_reactDeviceDetect.isMobile ? function () {
|
509
537
|
return _this2.handleDayPickerFocus('from');
|
510
538
|
} : undefined,
|
511
|
-
onKeyDown: !isMobile ? this.handleKeyDown('from') : undefined
|
512
|
-
},
|
539
|
+
onKeyDown: !_reactDeviceDetect.isMobile ? this.handleKeyDown('from') : undefined
|
540
|
+
}, _react.default.createElement("div", null, !_reactDeviceDetect.isMobile ? _react.default.createElement(_DayPickerInput.default, {
|
513
541
|
key: '1',
|
514
542
|
ref: function ref(el) {
|
515
543
|
_this2.fromInput = el;
|
@@ -518,16 +546,16 @@ function (_React$Component) {
|
|
518
546
|
hideOnDayClick: false,
|
519
547
|
overlayComponent: this.renderOverlayFrom,
|
520
548
|
dayPickerProps: fromDayPickerProps,
|
521
|
-
component: HiTextField,
|
549
|
+
component: _HiForm.HiTextField,
|
522
550
|
inputProps: fromInputProps,
|
523
551
|
format: enableTime ? "".concat(format, " HH:mm") : format,
|
524
|
-
formatDate:
|
525
|
-
parseDate:
|
552
|
+
formatDate: _moment.default.formatDate,
|
553
|
+
parseDate: _moment.default.parseDate,
|
526
554
|
onDayChange: function onDayChange(day) {
|
527
555
|
return _this2.handleDayChange('from', day);
|
528
556
|
},
|
529
557
|
placeholder: ''
|
530
|
-
}) :
|
558
|
+
}) : _react.default.createElement(_HiDatePickerMobile.default, {
|
531
559
|
id: this.props.id,
|
532
560
|
label: labelFrom,
|
533
561
|
range: true,
|
@@ -540,16 +568,16 @@ function (_React$Component) {
|
|
540
568
|
today: today,
|
541
569
|
minimumDate: minimumDate,
|
542
570
|
format: enableTime ? "".concat(format, " HH:mm") : format
|
543
|
-
}))),
|
571
|
+
}))), _react.default.createElement("div", {
|
544
572
|
className: toClass,
|
545
|
-
onFocus: !isMobile ? function () {
|
573
|
+
onFocus: !_reactDeviceDetect.isMobile ? function () {
|
546
574
|
return _this2.handleDayPickerFocus('to');
|
547
575
|
} : undefined,
|
548
|
-
onBlur: !isMobile ? function () {
|
576
|
+
onBlur: !_reactDeviceDetect.isMobile ? function () {
|
549
577
|
return _this2.handleDayPickerBlur('to');
|
550
578
|
} : undefined,
|
551
|
-
onKeyDown: !isMobile ? this.handleKeyDown('to') : undefined
|
552
|
-
}, !isMobile ?
|
579
|
+
onKeyDown: !_reactDeviceDetect.isMobile ? this.handleKeyDown('to') : undefined
|
580
|
+
}, !_reactDeviceDetect.isMobile ? _react.default.createElement(_DayPickerInput.default, {
|
553
581
|
key: '1',
|
554
582
|
ref: function ref(el) {
|
555
583
|
_this2.toInput = el;
|
@@ -558,13 +586,13 @@ function (_React$Component) {
|
|
558
586
|
hideOnDayClick: false,
|
559
587
|
overlayComponent: this.renderOverlayTo,
|
560
588
|
dayPickerProps: toDayPickerProps,
|
561
|
-
component: HiTextField,
|
589
|
+
component: _HiForm.HiTextField,
|
562
590
|
inputProps: toInputProps,
|
563
591
|
format: enableTime ? "".concat(format, " HH:mm") : format,
|
564
|
-
formatDate:
|
565
|
-
parseDate:
|
592
|
+
formatDate: _moment.default.formatDate,
|
593
|
+
parseDate: _moment.default.parseDate,
|
566
594
|
placeholder: ''
|
567
|
-
}) :
|
595
|
+
}) : _react.default.createElement(_HiDatePickerMobile.default, {
|
568
596
|
id: this.props.id,
|
569
597
|
label: labelTo,
|
570
598
|
range: true,
|
@@ -580,7 +608,7 @@ function (_React$Component) {
|
|
580
608
|
})));
|
581
609
|
|
582
610
|
if (!hasSelector) {
|
583
|
-
content =
|
611
|
+
content = _react.default.createElement(_HiFormControl.default, {
|
584
612
|
disabled: disabled,
|
585
613
|
helperIcon: helperIcon,
|
586
614
|
helperText: helperText,
|
@@ -593,11 +621,10 @@ function (_React$Component) {
|
|
593
621
|
return content;
|
594
622
|
}
|
595
623
|
}]);
|
596
|
-
|
597
624
|
return HiDateRangePicker;
|
598
|
-
}(
|
625
|
+
}(_react.default.Component);
|
599
626
|
|
600
|
-
|
627
|
+
HiDateRangePicker.defaultProps = {
|
601
628
|
disabledDays: {},
|
602
629
|
disableFutureDays: true,
|
603
630
|
staticPosition: false,
|
@@ -623,8 +650,10 @@ _defineProperty(HiDateRangePicker, "defaultProps", {
|
|
623
650
|
date_superior_max_date: 'Date from cannot be greater than %s',
|
624
651
|
date_inferior_min_date: 'Date from cannot be before than %s'
|
625
652
|
}
|
626
|
-
}
|
653
|
+
};
|
627
654
|
|
628
|
-
|
655
|
+
var _default = (0, _styles.withStyles)(_stylesheet.default, {
|
629
656
|
name: 'HmuiHiDateRangePicker'
|
630
|
-
})(HiDateRangePicker);
|
657
|
+
})(HiDateRangePicker);
|
658
|
+
|
659
|
+
exports.default = _default;
|