@hitachivantara/uikit-react-lab 4.0.2 → 4.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ColorPicker/ColorPicker.js +25 -78
- package/dist/ColorPicker/ColorPicker.js.map +1 -1
- package/dist/ColorPicker/Fields/Fields.js +15 -47
- package/dist/ColorPicker/Fields/Fields.js.map +1 -1
- package/dist/ColorPicker/Fields/index.js +0 -2
- package/dist/ColorPicker/Fields/index.js.map +1 -1
- package/dist/ColorPicker/Fields/styles.js +0 -2
- package/dist/ColorPicker/Fields/styles.js.map +1 -1
- package/dist/ColorPicker/Picker/Picker.js +5 -23
- package/dist/ColorPicker/Picker/Picker.js.map +1 -1
- package/dist/ColorPicker/Picker/index.js +0 -2
- package/dist/ColorPicker/Picker/index.js.map +1 -1
- package/dist/ColorPicker/Picker/styles.js +0 -2
- package/dist/ColorPicker/Picker/styles.js.map +1 -1
- package/dist/ColorPicker/PresetColors/PresetColors.js +2 -24
- package/dist/ColorPicker/PresetColors/PresetColors.js.map +1 -1
- package/dist/ColorPicker/PresetColors/index.js +0 -2
- package/dist/ColorPicker/PresetColors/index.js.map +1 -1
- package/dist/ColorPicker/PresetColors/styles.js +0 -2
- package/dist/ColorPicker/PresetColors/styles.js.map +1 -1
- package/dist/ColorPicker/index.js +0 -2
- package/dist/ColorPicker/index.js.map +1 -1
- package/dist/ColorPicker/styles.js +0 -2
- package/dist/ColorPicker/styles.js.map +1 -1
- package/dist/Drawer/Drawer.js +10 -50
- package/dist/Drawer/Drawer.js.map +1 -1
- package/dist/Drawer/index.js +0 -2
- package/dist/Drawer/index.js.map +1 -1
- package/dist/Drawer/styles.js +0 -3
- package/dist/Drawer/styles.js.map +1 -1
- package/dist/ImageCarousel/ImageCarousel.js +46 -149
- package/dist/ImageCarousel/ImageCarousel.js.map +1 -1
- package/dist/ImageCarousel/index.js +0 -2
- package/dist/ImageCarousel/index.js.map +1 -1
- package/dist/ImageCarousel/styles.js +0 -5
- package/dist/ImageCarousel/styles.js.map +1 -1
- package/dist/InlineEditor/InlineEditor.js +25 -82
- package/dist/InlineEditor/InlineEditor.js.map +1 -1
- package/dist/InlineEditor/index.js +0 -2
- package/dist/InlineEditor/index.js.map +1 -1
- package/dist/InlineEditor/styles.js +0 -14
- package/dist/InlineEditor/styles.js.map +1 -1
- package/dist/NavigationAnchors/NavigationAnchors.js +44 -116
- package/dist/NavigationAnchors/NavigationAnchors.js.map +1 -1
- package/dist/NavigationAnchors/NavigationOption.js +0 -10
- package/dist/NavigationAnchors/NavigationOption.js.map +1 -1
- package/dist/NavigationAnchors/index.js +0 -2
- package/dist/NavigationAnchors/index.js.map +1 -1
- package/dist/NavigationAnchors/styles.js +0 -2
- package/dist/NavigationAnchors/styles.js.map +1 -1
- package/dist/NotificationPanel/EmptyStatePanel/EmptyStatePanel.js +5 -26
- package/dist/NotificationPanel/EmptyStatePanel/EmptyStatePanel.js.map +1 -1
- package/dist/NotificationPanel/EmptyStatePanel/index.js +0 -2
- package/dist/NotificationPanel/EmptyStatePanel/index.js.map +1 -1
- package/dist/NotificationPanel/EmptyStatePanel/styles.js +0 -2
- package/dist/NotificationPanel/EmptyStatePanel/styles.js.map +1 -1
- package/dist/NotificationPanel/Notification/Notification.js +12 -57
- package/dist/NotificationPanel/Notification/Notification.js.map +1 -1
- package/dist/NotificationPanel/Notification/index.js +0 -2
- package/dist/NotificationPanel/Notification/index.js.map +1 -1
- package/dist/NotificationPanel/Notification/styles.js +0 -14
- package/dist/NotificationPanel/Notification/styles.js.map +1 -1
- package/dist/NotificationPanel/NotificationPanel.js +23 -92
- package/dist/NotificationPanel/NotificationPanel.js.map +1 -1
- package/dist/NotificationPanel/NotificationsIndicator/NotificationsIndicator.js +4 -35
- package/dist/NotificationPanel/NotificationsIndicator/NotificationsIndicator.js.map +1 -1
- package/dist/NotificationPanel/NotificationsIndicator/index.js +0 -2
- package/dist/NotificationPanel/NotificationsIndicator/index.js.map +1 -1
- package/dist/NotificationPanel/NotificationsIndicator/styles.js +0 -2
- package/dist/NotificationPanel/NotificationsIndicator/styles.js.map +1 -1
- package/dist/NotificationPanel/index.js +0 -2
- package/dist/NotificationPanel/index.js.map +1 -1
- package/dist/NotificationPanel/styles.js +0 -2
- package/dist/NotificationPanel/styles.js.map +1 -1
- package/dist/StepNavigation/DefaultNavigation/DefaultNavigation.js +15 -44
- package/dist/StepNavigation/DefaultNavigation/DefaultNavigation.js.map +1 -1
- package/dist/StepNavigation/DefaultNavigation/Step/Step.js +9 -41
- package/dist/StepNavigation/DefaultNavigation/Step/Step.js.map +1 -1
- package/dist/StepNavigation/DefaultNavigation/Step/index.js +0 -2
- package/dist/StepNavigation/DefaultNavigation/Step/index.js.map +1 -1
- package/dist/StepNavigation/DefaultNavigation/Step/styles.js +0 -2
- package/dist/StepNavigation/DefaultNavigation/Step/styles.js.map +1 -1
- package/dist/StepNavigation/DefaultNavigation/index.js +0 -2
- package/dist/StepNavigation/DefaultNavigation/index.js.map +1 -1
- package/dist/StepNavigation/DefaultNavigation/styles.js +0 -2
- package/dist/StepNavigation/DefaultNavigation/styles.js.map +1 -1
- package/dist/StepNavigation/DefaultNavigation/utils.js +0 -3
- package/dist/StepNavigation/DefaultNavigation/utils.js.map +1 -1
- package/dist/StepNavigation/SimpleNavigation/Dot/Dot.js +6 -47
- package/dist/StepNavigation/SimpleNavigation/Dot/Dot.js.map +1 -1
- package/dist/StepNavigation/SimpleNavigation/Dot/index.js +0 -2
- package/dist/StepNavigation/SimpleNavigation/Dot/index.js.map +1 -1
- package/dist/StepNavigation/SimpleNavigation/Dot/styles.js.map +1 -1
- package/dist/StepNavigation/SimpleNavigation/SimpleNavigation.js +14 -44
- package/dist/StepNavigation/SimpleNavigation/SimpleNavigation.js.map +1 -1
- package/dist/StepNavigation/SimpleNavigation/index.js +0 -2
- package/dist/StepNavigation/SimpleNavigation/index.js.map +1 -1
- package/dist/StepNavigation/SimpleNavigation/styles.js +0 -2
- package/dist/StepNavigation/SimpleNavigation/styles.js.map +1 -1
- package/dist/StepNavigation/SimpleNavigation/utils.js +0 -6
- package/dist/StepNavigation/SimpleNavigation/utils.js.map +1 -1
- package/dist/StepNavigation/StepNavigation.js +39 -106
- package/dist/StepNavigation/StepNavigation.js.map +1 -1
- package/dist/StepNavigation/index.js +0 -2
- package/dist/StepNavigation/index.js.map +1 -1
- package/dist/StepNavigation/styles.js +0 -2
- package/dist/StepNavigation/styles.js.map +1 -1
- package/dist/StepNavigation/utils.js.map +1 -1
- package/dist/TimeAgo/TimeAgo.js +13 -44
- package/dist/TimeAgo/TimeAgo.js.map +1 -1
- package/dist/TimeAgo/formatUtils.js +15 -35
- package/dist/TimeAgo/formatUtils.js.map +1 -1
- package/dist/TimeAgo/index.js +0 -3
- package/dist/TimeAgo/index.js.map +1 -1
- package/dist/TimeAgo/styles.js.map +1 -1
- package/dist/TimeAgo/useTimeAgo.js +7 -16
- package/dist/TimeAgo/useTimeAgo.js.map +1 -1
- package/dist/TimeAgo/useTimeout.js +0 -2
- package/dist/TimeAgo/useTimeout.js.map +1 -1
- package/dist/Wizard/Wizard.d.ts +5 -5
- package/dist/Wizard/Wizard.js +33 -85
- package/dist/Wizard/Wizard.js.map +1 -1
- package/dist/Wizard/WizardActions/WizardActions.d.ts +2 -2
- package/dist/Wizard/WizardActions/WizardActions.js +31 -86
- package/dist/Wizard/WizardActions/WizardActions.js.map +1 -1
- package/dist/Wizard/WizardActions/index.js +0 -2
- package/dist/Wizard/WizardActions/index.js.map +1 -1
- package/dist/Wizard/WizardActions/styles.js +0 -2
- package/dist/Wizard/WizardActions/styles.js.map +1 -1
- package/dist/Wizard/WizardContainer/WizardContainer.js +5 -35
- package/dist/Wizard/WizardContainer/WizardContainer.js.map +1 -1
- package/dist/Wizard/WizardContainer/index.js +0 -2
- package/dist/Wizard/WizardContainer/index.js.map +1 -1
- package/dist/Wizard/WizardContainer/styles.js +0 -2
- package/dist/Wizard/WizardContainer/styles.js.map +1 -1
- package/dist/Wizard/WizardContent/LoadingContainer.js +2 -25
- package/dist/Wizard/WizardContent/LoadingContainer.js.map +1 -1
- package/dist/Wizard/WizardContent/WizardContent.d.ts +1 -1
- package/dist/Wizard/WizardContent/WizardContent.js +12 -55
- package/dist/Wizard/WizardContent/WizardContent.js.map +1 -1
- package/dist/Wizard/WizardContent/index.js +0 -2
- package/dist/Wizard/WizardContent/index.js.map +1 -1
- package/dist/Wizard/WizardContent/styles.js +0 -2
- package/dist/Wizard/WizardContent/styles.js.map +1 -1
- package/dist/Wizard/WizardContext/WizardContext.d.ts +12 -0
- package/dist/Wizard/WizardContext/WizardContext.js +0 -4
- package/dist/Wizard/WizardContext/WizardContext.js.map +1 -1
- package/dist/Wizard/WizardContext/WizardContextProvider.d.ts +28 -0
- package/dist/Wizard/WizardContext/WizardContextProvider.js +41 -0
- package/dist/Wizard/WizardContext/WizardContextProvider.js.map +1 -0
- package/dist/Wizard/WizardContext/index.d.ts +5 -0
- package/dist/Wizard/WizardContext/index.js +7 -2
- package/dist/Wizard/WizardContext/index.js.map +1 -1
- package/dist/Wizard/WizardTitle/WizardTitle.d.ts +7 -9
- package/dist/Wizard/WizardTitle/WizardTitle.js +18 -59
- package/dist/Wizard/WizardTitle/WizardTitle.js.map +1 -1
- package/dist/Wizard/WizardTitle/index.js +0 -2
- package/dist/Wizard/WizardTitle/index.js.map +1 -1
- package/dist/Wizard/WizardTitle/styles.js +0 -2
- package/dist/Wizard/WizardTitle/styles.js.map +1 -1
- package/dist/Wizard/index.d.ts +15 -0
- package/dist/Wizard/index.js +7 -7
- package/dist/Wizard/index.js.map +1 -1
- package/dist/Wizard/styles.js +0 -2
- package/dist/Wizard/styles.js.map +1 -1
- package/dist/index.js +12 -23
- package/dist/index.js.map +1 -1
- package/dist/legacy/ColorPicker/ColorPicker.js +26 -51
- package/dist/legacy/ColorPicker/ColorPicker.js.map +1 -1
- package/dist/legacy/ColorPicker/Fields/Fields.js +17 -27
- package/dist/legacy/ColorPicker/Fields/Fields.js.map +1 -1
- package/dist/legacy/ColorPicker/Fields/index.js.map +1 -1
- package/dist/legacy/ColorPicker/Fields/styles.js.map +1 -1
- package/dist/legacy/ColorPicker/Picker/Picker.js +7 -7
- package/dist/legacy/ColorPicker/Picker/Picker.js.map +1 -1
- package/dist/legacy/ColorPicker/Picker/index.js.map +1 -1
- package/dist/legacy/ColorPicker/Picker/styles.js.map +1 -1
- package/dist/legacy/ColorPicker/PresetColors/PresetColors.js +2 -7
- package/dist/legacy/ColorPicker/PresetColors/PresetColors.js.map +1 -1
- package/dist/legacy/ColorPicker/PresetColors/index.js.map +1 -1
- package/dist/legacy/ColorPicker/PresetColors/styles.js.map +1 -1
- package/dist/legacy/ColorPicker/index.js.map +1 -1
- package/dist/legacy/ColorPicker/styles.js +0 -1
- package/dist/legacy/ColorPicker/styles.js.map +1 -1
- package/dist/legacy/Drawer/Drawer.js +11 -30
- package/dist/legacy/Drawer/Drawer.js.map +1 -1
- package/dist/legacy/Drawer/index.js.map +1 -1
- package/dist/legacy/Drawer/styles.js +0 -2
- package/dist/legacy/Drawer/styles.js.map +1 -1
- package/dist/legacy/ImageCarousel/ImageCarousel.js +46 -120
- package/dist/legacy/ImageCarousel/ImageCarousel.js.map +1 -1
- package/dist/legacy/ImageCarousel/index.js.map +1 -1
- package/dist/legacy/ImageCarousel/styles.js +0 -3
- package/dist/legacy/ImageCarousel/styles.js.map +1 -1
- package/dist/legacy/InlineEditor/InlineEditor.js +26 -55
- package/dist/legacy/InlineEditor/InlineEditor.js.map +1 -1
- package/dist/legacy/InlineEditor/index.js.map +1 -1
- package/dist/legacy/InlineEditor/styles.js +0 -5
- package/dist/legacy/InlineEditor/styles.js.map +1 -1
- package/dist/legacy/NavigationAnchors/NavigationAnchors.js +44 -82
- package/dist/legacy/NavigationAnchors/NavigationAnchors.js.map +1 -1
- package/dist/legacy/NavigationAnchors/NavigationOption.js +0 -5
- package/dist/legacy/NavigationAnchors/NavigationOption.js.map +1 -1
- package/dist/legacy/NavigationAnchors/index.js.map +1 -1
- package/dist/legacy/NavigationAnchors/styles.js +0 -1
- package/dist/legacy/NavigationAnchors/styles.js.map +1 -1
- package/dist/legacy/NotificationPanel/EmptyStatePanel/EmptyStatePanel.js +5 -16
- package/dist/legacy/NotificationPanel/EmptyStatePanel/EmptyStatePanel.js.map +1 -1
- package/dist/legacy/NotificationPanel/EmptyStatePanel/index.js.map +1 -1
- package/dist/legacy/NotificationPanel/EmptyStatePanel/styles.js +0 -1
- package/dist/legacy/NotificationPanel/EmptyStatePanel/styles.js.map +1 -1
- package/dist/legacy/NotificationPanel/Notification/Notification.js +12 -44
- package/dist/legacy/NotificationPanel/Notification/Notification.js.map +1 -1
- package/dist/legacy/NotificationPanel/Notification/index.js.map +1 -1
- package/dist/legacy/NotificationPanel/Notification/styles.js +0 -5
- package/dist/legacy/NotificationPanel/Notification/styles.js.map +1 -1
- package/dist/legacy/NotificationPanel/NotificationPanel.js +23 -61
- package/dist/legacy/NotificationPanel/NotificationPanel.js.map +1 -1
- package/dist/legacy/NotificationPanel/NotificationsIndicator/NotificationsIndicator.js +4 -17
- package/dist/legacy/NotificationPanel/NotificationsIndicator/NotificationsIndicator.js.map +1 -1
- package/dist/legacy/NotificationPanel/NotificationsIndicator/index.js.map +1 -1
- package/dist/legacy/NotificationPanel/NotificationsIndicator/styles.js +0 -1
- package/dist/legacy/NotificationPanel/NotificationsIndicator/styles.js.map +1 -1
- package/dist/legacy/NotificationPanel/index.js.map +1 -1
- package/dist/legacy/NotificationPanel/styles.js +0 -1
- package/dist/legacy/NotificationPanel/styles.js.map +1 -1
- package/dist/legacy/StepNavigation/DefaultNavigation/DefaultNavigation.js +16 -27
- package/dist/legacy/StepNavigation/DefaultNavigation/DefaultNavigation.js.map +1 -1
- package/dist/legacy/StepNavigation/DefaultNavigation/Step/Step.js +10 -29
- package/dist/legacy/StepNavigation/DefaultNavigation/Step/Step.js.map +1 -1
- package/dist/legacy/StepNavigation/DefaultNavigation/Step/index.js.map +1 -1
- package/dist/legacy/StepNavigation/DefaultNavigation/Step/styles.js +0 -1
- package/dist/legacy/StepNavigation/DefaultNavigation/Step/styles.js.map +1 -1
- package/dist/legacy/StepNavigation/DefaultNavigation/index.js.map +1 -1
- package/dist/legacy/StepNavigation/DefaultNavigation/styles.js +0 -1
- package/dist/legacy/StepNavigation/DefaultNavigation/styles.js.map +1 -1
- package/dist/legacy/StepNavigation/DefaultNavigation/utils.js +0 -2
- package/dist/legacy/StepNavigation/DefaultNavigation/utils.js.map +1 -1
- package/dist/legacy/StepNavigation/SimpleNavigation/Dot/Dot.js +7 -21
- package/dist/legacy/StepNavigation/SimpleNavigation/Dot/Dot.js.map +1 -1
- package/dist/legacy/StepNavigation/SimpleNavigation/Dot/index.js.map +1 -1
- package/dist/legacy/StepNavigation/SimpleNavigation/Dot/styles.js.map +1 -1
- package/dist/legacy/StepNavigation/SimpleNavigation/SimpleNavigation.js +15 -26
- package/dist/legacy/StepNavigation/SimpleNavigation/SimpleNavigation.js.map +1 -1
- package/dist/legacy/StepNavigation/SimpleNavigation/index.js.map +1 -1
- package/dist/legacy/StepNavigation/SimpleNavigation/styles.js +0 -1
- package/dist/legacy/StepNavigation/SimpleNavigation/styles.js.map +1 -1
- package/dist/legacy/StepNavigation/SimpleNavigation/utils.js +0 -6
- package/dist/legacy/StepNavigation/SimpleNavigation/utils.js.map +1 -1
- package/dist/legacy/StepNavigation/StepNavigation.js +40 -78
- package/dist/legacy/StepNavigation/StepNavigation.js.map +1 -1
- package/dist/legacy/StepNavigation/index.js.map +1 -1
- package/dist/legacy/StepNavigation/styles.js +0 -1
- package/dist/legacy/StepNavigation/styles.js.map +1 -1
- package/dist/legacy/StepNavigation/utils.js.map +1 -1
- package/dist/legacy/TimeAgo/TimeAgo.js +14 -27
- package/dist/legacy/TimeAgo/TimeAgo.js.map +1 -1
- package/dist/legacy/TimeAgo/formatUtils.js +16 -18
- package/dist/legacy/TimeAgo/formatUtils.js.map +1 -1
- package/dist/legacy/TimeAgo/index.js.map +1 -1
- package/dist/legacy/TimeAgo/styles.js.map +1 -1
- package/dist/legacy/TimeAgo/useTimeAgo.js +8 -11
- package/dist/legacy/TimeAgo/useTimeAgo.js.map +1 -1
- package/dist/legacy/TimeAgo/useTimeout.js.map +1 -1
- package/dist/legacy/Wizard/Wizard.d.ts +5 -5
- package/dist/legacy/Wizard/Wizard.js +33 -59
- package/dist/legacy/Wizard/Wizard.js.map +1 -1
- package/dist/legacy/Wizard/WizardActions/WizardActions.d.ts +2 -2
- package/dist/legacy/Wizard/WizardActions/WizardActions.js +33 -62
- package/dist/legacy/Wizard/WizardActions/WizardActions.js.map +1 -1
- package/dist/legacy/Wizard/WizardActions/index.js.map +1 -1
- package/dist/legacy/Wizard/WizardActions/styles.js +0 -1
- package/dist/legacy/Wizard/WizardActions/styles.js.map +1 -1
- package/dist/legacy/Wizard/WizardContainer/WizardContainer.js +5 -17
- package/dist/legacy/Wizard/WizardContainer/WizardContainer.js.map +1 -1
- package/dist/legacy/Wizard/WizardContainer/index.js.map +1 -1
- package/dist/legacy/Wizard/WizardContainer/styles.js +0 -1
- package/dist/legacy/Wizard/WizardContainer/styles.js.map +1 -1
- package/dist/legacy/Wizard/WizardContent/LoadingContainer.js +2 -8
- package/dist/legacy/Wizard/WizardContent/LoadingContainer.js.map +1 -1
- package/dist/legacy/Wizard/WizardContent/WizardContent.d.ts +1 -1
- package/dist/legacy/Wizard/WizardContent/WizardContent.js +11 -27
- package/dist/legacy/Wizard/WizardContent/WizardContent.js.map +1 -1
- package/dist/legacy/Wizard/WizardContent/index.js.map +1 -1
- package/dist/legacy/Wizard/WizardContent/styles.js +0 -1
- package/dist/legacy/Wizard/WizardContent/styles.js.map +1 -1
- package/dist/legacy/Wizard/WizardContext/WizardContext.d.ts +12 -0
- package/dist/legacy/Wizard/WizardContext/WizardContext.js +0 -2
- package/dist/legacy/Wizard/WizardContext/WizardContext.js.map +1 -1
- package/dist/legacy/Wizard/WizardContext/WizardContextProvider.d.ts +28 -0
- package/dist/legacy/Wizard/WizardContext/WizardContextProvider.js +33 -0
- package/dist/legacy/Wizard/WizardContext/WizardContextProvider.js.map +1 -0
- package/dist/legacy/Wizard/WizardContext/index.d.ts +5 -0
- package/dist/legacy/Wizard/WizardContext/index.js +1 -0
- package/dist/legacy/Wizard/WizardContext/index.js.map +1 -1
- package/dist/legacy/Wizard/WizardTitle/WizardTitle.d.ts +7 -9
- package/dist/legacy/Wizard/WizardTitle/WizardTitle.js +17 -42
- package/dist/legacy/Wizard/WizardTitle/WizardTitle.js.map +1 -1
- package/dist/legacy/Wizard/WizardTitle/index.js.map +1 -1
- package/dist/legacy/Wizard/WizardTitle/styles.js +0 -1
- package/dist/legacy/Wizard/WizardTitle/styles.js.map +1 -1
- package/dist/legacy/Wizard/index.d.ts +15 -0
- package/dist/legacy/Wizard/index.js +1 -0
- package/dist/legacy/Wizard/index.js.map +1 -1
- package/dist/legacy/Wizard/styles.js +0 -1
- package/dist/legacy/Wizard/styles.js.map +1 -1
- package/dist/legacy/index.js +1 -0
- package/dist/legacy/index.js.map +1 -1
- package/dist/modern/ColorPicker/ColorPicker.js +1 -25
- package/dist/modern/ColorPicker/ColorPicker.js.map +1 -1
- package/dist/modern/ColorPicker/Fields/Fields.js +3 -10
- package/dist/modern/ColorPicker/Fields/Fields.js.map +1 -1
- package/dist/modern/ColorPicker/Fields/index.js.map +1 -1
- package/dist/modern/ColorPicker/Fields/styles.js.map +1 -1
- package/dist/modern/ColorPicker/Picker/Picker.js +3 -3
- package/dist/modern/ColorPicker/Picker/Picker.js.map +1 -1
- package/dist/modern/ColorPicker/Picker/index.js.map +1 -1
- package/dist/modern/ColorPicker/Picker/styles.js.map +1 -1
- package/dist/modern/ColorPicker/PresetColors/PresetColors.js +0 -5
- package/dist/modern/ColorPicker/PresetColors/PresetColors.js.map +1 -1
- package/dist/modern/ColorPicker/PresetColors/index.js.map +1 -1
- package/dist/modern/ColorPicker/PresetColors/styles.js.map +1 -1
- package/dist/modern/ColorPicker/index.js.map +1 -1
- package/dist/modern/ColorPicker/styles.js +0 -1
- package/dist/modern/ColorPicker/styles.js.map +1 -1
- package/dist/modern/Drawer/Drawer.js +11 -30
- package/dist/modern/Drawer/Drawer.js.map +1 -1
- package/dist/modern/Drawer/index.js.map +1 -1
- package/dist/modern/Drawer/styles.js +0 -2
- package/dist/modern/Drawer/styles.js.map +1 -1
- package/dist/modern/ImageCarousel/ImageCarousel.js +18 -83
- package/dist/modern/ImageCarousel/ImageCarousel.js.map +1 -1
- package/dist/modern/ImageCarousel/index.js.map +1 -1
- package/dist/modern/ImageCarousel/styles.js +0 -1
- package/dist/modern/ImageCarousel/styles.js.map +1 -1
- package/dist/modern/InlineEditor/InlineEditor.js +16 -43
- package/dist/modern/InlineEditor/InlineEditor.js.map +1 -1
- package/dist/modern/InlineEditor/index.js.map +1 -1
- package/dist/modern/InlineEditor/styles.js +0 -5
- package/dist/modern/InlineEditor/styles.js.map +1 -1
- package/dist/modern/NavigationAnchors/NavigationAnchors.js +40 -74
- package/dist/modern/NavigationAnchors/NavigationAnchors.js.map +1 -1
- package/dist/modern/NavigationAnchors/NavigationOption.js +0 -6
- package/dist/modern/NavigationAnchors/NavigationOption.js.map +1 -1
- package/dist/modern/NavigationAnchors/index.js.map +1 -1
- package/dist/modern/NavigationAnchors/styles.js +0 -1
- package/dist/modern/NavigationAnchors/styles.js.map +1 -1
- package/dist/modern/NotificationPanel/EmptyStatePanel/EmptyStatePanel.js +0 -11
- package/dist/modern/NotificationPanel/EmptyStatePanel/EmptyStatePanel.js.map +1 -1
- package/dist/modern/NotificationPanel/EmptyStatePanel/index.js.map +1 -1
- package/dist/modern/NotificationPanel/EmptyStatePanel/styles.js +0 -1
- package/dist/modern/NotificationPanel/EmptyStatePanel/styles.js.map +1 -1
- package/dist/modern/NotificationPanel/Notification/Notification.js +2 -33
- package/dist/modern/NotificationPanel/Notification/Notification.js.map +1 -1
- package/dist/modern/NotificationPanel/Notification/index.js.map +1 -1
- package/dist/modern/NotificationPanel/Notification/styles.js +0 -5
- package/dist/modern/NotificationPanel/Notification/styles.js.map +1 -1
- package/dist/modern/NotificationPanel/NotificationPanel.js +16 -50
- package/dist/modern/NotificationPanel/NotificationPanel.js.map +1 -1
- package/dist/modern/NotificationPanel/NotificationsIndicator/NotificationsIndicator.js +6 -19
- package/dist/modern/NotificationPanel/NotificationsIndicator/NotificationsIndicator.js.map +1 -1
- package/dist/modern/NotificationPanel/NotificationsIndicator/index.js.map +1 -1
- package/dist/modern/NotificationPanel/NotificationsIndicator/styles.js +0 -1
- package/dist/modern/NotificationPanel/NotificationsIndicator/styles.js.map +1 -1
- package/dist/modern/NotificationPanel/index.js.map +1 -1
- package/dist/modern/NotificationPanel/styles.js +0 -1
- package/dist/modern/NotificationPanel/styles.js.map +1 -1
- package/dist/modern/StepNavigation/DefaultNavigation/DefaultNavigation.js +14 -23
- package/dist/modern/StepNavigation/DefaultNavigation/DefaultNavigation.js.map +1 -1
- package/dist/modern/StepNavigation/DefaultNavigation/Step/Step.js +1 -20
- package/dist/modern/StepNavigation/DefaultNavigation/Step/Step.js.map +1 -1
- package/dist/modern/StepNavigation/DefaultNavigation/Step/index.js.map +1 -1
- package/dist/modern/StepNavigation/DefaultNavigation/Step/styles.js +0 -1
- package/dist/modern/StepNavigation/DefaultNavigation/Step/styles.js.map +1 -1
- package/dist/modern/StepNavigation/DefaultNavigation/index.js.map +1 -1
- package/dist/modern/StepNavigation/DefaultNavigation/styles.js +0 -1
- package/dist/modern/StepNavigation/DefaultNavigation/styles.js.map +1 -1
- package/dist/modern/StepNavigation/DefaultNavigation/utils.js +0 -2
- package/dist/modern/StepNavigation/DefaultNavigation/utils.js.map +1 -1
- package/dist/modern/StepNavigation/SimpleNavigation/Dot/Dot.js +1 -15
- package/dist/modern/StepNavigation/SimpleNavigation/Dot/Dot.js.map +1 -1
- package/dist/modern/StepNavigation/SimpleNavigation/Dot/index.js.map +1 -1
- package/dist/modern/StepNavigation/SimpleNavigation/Dot/styles.js.map +1 -1
- package/dist/modern/StepNavigation/SimpleNavigation/SimpleNavigation.js +14 -23
- package/dist/modern/StepNavigation/SimpleNavigation/SimpleNavigation.js.map +1 -1
- package/dist/modern/StepNavigation/SimpleNavigation/index.js.map +1 -1
- package/dist/modern/StepNavigation/SimpleNavigation/styles.js +0 -1
- package/dist/modern/StepNavigation/SimpleNavigation/styles.js.map +1 -1
- package/dist/modern/StepNavigation/SimpleNavigation/utils.js +0 -6
- package/dist/modern/StepNavigation/SimpleNavigation/utils.js.map +1 -1
- package/dist/modern/StepNavigation/StepNavigation.js +25 -62
- package/dist/modern/StepNavigation/StepNavigation.js.map +1 -1
- package/dist/modern/StepNavigation/index.js.map +1 -1
- package/dist/modern/StepNavigation/styles.js +0 -1
- package/dist/modern/StepNavigation/styles.js.map +1 -1
- package/dist/modern/StepNavigation/utils.js.map +1 -1
- package/dist/modern/TimeAgo/TimeAgo.js +11 -24
- package/dist/modern/TimeAgo/TimeAgo.js.map +1 -1
- package/dist/modern/TimeAgo/formatUtils.js +16 -18
- package/dist/modern/TimeAgo/formatUtils.js.map +1 -1
- package/dist/modern/TimeAgo/index.js.map +1 -1
- package/dist/modern/TimeAgo/styles.js.map +1 -1
- package/dist/modern/TimeAgo/useTimeAgo.js +1 -3
- package/dist/modern/TimeAgo/useTimeAgo.js.map +1 -1
- package/dist/modern/TimeAgo/useTimeout.js.map +1 -1
- package/dist/modern/Wizard/Wizard.d.ts +5 -5
- package/dist/modern/Wizard/Wizard.js +24 -49
- package/dist/modern/Wizard/Wizard.js.map +1 -1
- package/dist/modern/Wizard/WizardActions/WizardActions.d.ts +2 -2
- package/dist/modern/Wizard/WizardActions/WizardActions.js +6 -30
- package/dist/modern/Wizard/WizardActions/WizardActions.js.map +1 -1
- package/dist/modern/Wizard/WizardActions/index.js.map +1 -1
- package/dist/modern/Wizard/WizardActions/styles.js +0 -1
- package/dist/modern/Wizard/WizardActions/styles.js.map +1 -1
- package/dist/modern/Wizard/WizardContainer/WizardContainer.js +7 -19
- package/dist/modern/Wizard/WizardContainer/WizardContainer.js.map +1 -1
- package/dist/modern/Wizard/WizardContainer/index.js.map +1 -1
- package/dist/modern/Wizard/WizardContainer/styles.js +0 -1
- package/dist/modern/Wizard/WizardContainer/styles.js.map +1 -1
- package/dist/modern/Wizard/WizardContent/LoadingContainer.js +4 -10
- package/dist/modern/Wizard/WizardContent/LoadingContainer.js.map +1 -1
- package/dist/modern/Wizard/WizardContent/WizardContent.d.ts +1 -1
- package/dist/modern/Wizard/WizardContent/WizardContent.js +1 -15
- package/dist/modern/Wizard/WizardContent/WizardContent.js.map +1 -1
- package/dist/modern/Wizard/WizardContent/index.js.map +1 -1
- package/dist/modern/Wizard/WizardContent/styles.js +0 -1
- package/dist/modern/Wizard/WizardContent/styles.js.map +1 -1
- package/dist/modern/Wizard/WizardContext/WizardContext.d.ts +12 -0
- package/dist/modern/Wizard/WizardContext/WizardContext.js +0 -2
- package/dist/modern/Wizard/WizardContext/WizardContext.js.map +1 -1
- package/dist/modern/Wizard/WizardContext/WizardContextProvider.d.ts +28 -0
- package/dist/modern/Wizard/WizardContext/WizardContextProvider.js +34 -0
- package/dist/modern/Wizard/WizardContext/WizardContextProvider.js.map +1 -0
- package/dist/modern/Wizard/WizardContext/index.d.ts +5 -0
- package/dist/modern/Wizard/WizardContext/index.js +1 -0
- package/dist/modern/Wizard/WizardContext/index.js.map +1 -1
- package/dist/modern/Wizard/WizardTitle/WizardTitle.d.ts +7 -9
- package/dist/modern/Wizard/WizardTitle/WizardTitle.js +3 -24
- package/dist/modern/Wizard/WizardTitle/WizardTitle.js.map +1 -1
- package/dist/modern/Wizard/WizardTitle/index.js.map +1 -1
- package/dist/modern/Wizard/WizardTitle/styles.js +0 -1
- package/dist/modern/Wizard/WizardTitle/styles.js.map +1 -1
- package/dist/modern/Wizard/index.d.ts +15 -0
- package/dist/modern/Wizard/index.js +1 -0
- package/dist/modern/Wizard/index.js.map +1 -1
- package/dist/modern/Wizard/styles.js +0 -1
- package/dist/modern/Wizard/styles.js.map +1 -1
- package/dist/modern/index.js +1 -0
- package/dist/modern/index.js.map +1 -1
- package/package.json +4 -4
|
@@ -5,13 +5,13 @@ import localeData from "dayjs/plugin/localeData";
|
|
|
5
5
|
import localizedFormat from "dayjs/plugin/localizedFormat";
|
|
6
6
|
import relativeTime from "dayjs/plugin/relativeTime";
|
|
7
7
|
import updateLocale from "dayjs/plugin/updateLocale";
|
|
8
|
+
|
|
8
9
|
/**
|
|
9
10
|
* Relative time thresholds defined by
|
|
10
11
|
* {@link https://xd.adobe.com/view/1b7df235-5cf8-4b51-a2f0-0be1bb591c55-4e2e/ Design System}
|
|
11
12
|
*
|
|
12
13
|
* Implementation using day.js {@link https://day.js.org/docs/en/customization/relative-time relativeTime}
|
|
13
14
|
*/
|
|
14
|
-
|
|
15
15
|
var thresholds = [{
|
|
16
16
|
l: "s",
|
|
17
17
|
r: 119,
|
|
@@ -69,7 +69,6 @@ export var secondsUntilNextDay = function secondsUntilNextDay() {
|
|
|
69
69
|
midnight.setMilliseconds(0);
|
|
70
70
|
return (midnight.getTime() - date.getTime()) / 1000;
|
|
71
71
|
};
|
|
72
|
-
|
|
73
72
|
var secondsUntilNextWeek = function secondsUntilNextWeek() {
|
|
74
73
|
var date = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : new Date();
|
|
75
74
|
var firstMonthDayOfWeek = date.getDate() - date.getDay();
|
|
@@ -83,6 +82,7 @@ var secondsUntilNextWeek = function secondsUntilNextWeek() {
|
|
|
83
82
|
firstDayNextWeek.setMilliseconds(0);
|
|
84
83
|
return (firstDayNextWeek.getTime() - date.getTime()) / 1000;
|
|
85
84
|
};
|
|
85
|
+
|
|
86
86
|
/**
|
|
87
87
|
* @typedef {Object} TimeAgo
|
|
88
88
|
* @property {string} timeAgo - the formatted date using the "time ago format"
|
|
@@ -99,66 +99,64 @@ var secondsUntilNextWeek = function secondsUntilNextWeek() {
|
|
|
99
99
|
*
|
|
100
100
|
* @return {TimeAgo} the formatted date using the "time ago format" and the time until it needs to be updated
|
|
101
101
|
*/
|
|
102
|
-
|
|
103
|
-
|
|
104
102
|
export var formatTimeAgo = function formatTimeAgo(date, locale) {
|
|
105
103
|
var showSeconds = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
|
|
106
104
|
var referenceDate = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : new Date();
|
|
107
105
|
var dayReferenceDate = dayjs(referenceDate);
|
|
108
106
|
var dayDate = dayjs(date).locale(locale);
|
|
109
107
|
var dayDiffSeconds = dayReferenceDate.diff(dayDate, "second");
|
|
110
|
-
var formatUseSeconds = showSeconds ? "LTS" : "LT";
|
|
108
|
+
var formatUseSeconds = showSeconds ? "LTS" : "LT";
|
|
111
109
|
|
|
110
|
+
// check if the date is after the reference date
|
|
112
111
|
if (date.getTime() > referenceDate.getTime()) {
|
|
113
112
|
return {
|
|
114
113
|
timeAgo: dayDate.format("L ".concat(formatUseSeconds)),
|
|
115
114
|
delay: (date.getTime() - referenceDate.getTime()) / 1000
|
|
116
115
|
};
|
|
117
|
-
}
|
|
118
|
-
|
|
116
|
+
}
|
|
119
117
|
|
|
118
|
+
// just now, until the 2 minutes
|
|
120
119
|
if (dayDiffSeconds < 120) {
|
|
121
120
|
return {
|
|
122
121
|
timeAgo: dayjs.duration(dayDiffSeconds, "second").locale(locale).humanize(),
|
|
123
122
|
delay: 120 - dayDiffSeconds
|
|
124
123
|
};
|
|
125
|
-
}
|
|
126
|
-
|
|
124
|
+
}
|
|
127
125
|
|
|
126
|
+
// ago in minutes, until the 1 hour mark
|
|
128
127
|
var dayDiffMinutes = dayReferenceDate.diff(dayDate, "minute");
|
|
129
|
-
|
|
130
128
|
if (dayDiffMinutes < 60) {
|
|
131
129
|
return {
|
|
132
130
|
timeAgo: dayjs.duration(-dayDiffMinutes, "minute").locale(locale).humanize(true),
|
|
133
131
|
delay: 60 * (dayDiffMinutes + 1) - dayDiffSeconds
|
|
134
132
|
};
|
|
135
|
-
}
|
|
136
|
-
|
|
133
|
+
}
|
|
137
134
|
|
|
135
|
+
// formatted date with text description for today
|
|
138
136
|
if (dayReferenceDate.isSame(dayDate, "day")) {
|
|
139
137
|
return {
|
|
140
138
|
timeAgo: "".concat(dayDate.calendar(dayReferenceDate)),
|
|
141
139
|
delay: secondsUntilNextDay(referenceDate)
|
|
142
140
|
};
|
|
143
|
-
}
|
|
144
|
-
|
|
141
|
+
}
|
|
145
142
|
|
|
143
|
+
// formatted date with text description for yesterday
|
|
146
144
|
if (dayReferenceDate.subtract(1, "day").isSame(dayDate, "day")) {
|
|
147
145
|
return {
|
|
148
146
|
timeAgo: "".concat(dayDate.calendar(dayReferenceDate)),
|
|
149
147
|
delay: secondsUntilNextDay(referenceDate)
|
|
150
148
|
};
|
|
151
|
-
}
|
|
152
|
-
|
|
149
|
+
}
|
|
153
150
|
|
|
151
|
+
// formatted date with week during the current week
|
|
154
152
|
if (dayDate.isSame(dayReferenceDate, "week")) {
|
|
155
153
|
return {
|
|
156
154
|
timeAgo: dayDate.format("ddd, ".concat(formatUseSeconds)),
|
|
157
155
|
delay: secondsUntilNextWeek(date)
|
|
158
156
|
};
|
|
159
|
-
}
|
|
160
|
-
|
|
157
|
+
}
|
|
161
158
|
|
|
159
|
+
// formatted without special gimmicks
|
|
162
160
|
return {
|
|
163
161
|
timeAgo: dayDate.format("L ".concat(formatUseSeconds)),
|
|
164
162
|
delay: 0
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"formatUtils.js","names":["dayjs","calendar","duration","localeData","localizedFormat","relativeTime","updateLocale","thresholds","l","r","d","extend","secondsUntilNextDay","date","Date","midnight","getTime","setDate","getDate","setHours","setMinutes","setSeconds","setMilliseconds","secondsUntilNextWeek","firstMonthDayOfWeek","getDay","firstMonthDayOfNextWeek","firstDayNextWeek","formatTimeAgo","locale","showSeconds","referenceDate","dayReferenceDate","dayDate","dayDiffSeconds","diff","formatUseSeconds","timeAgo","format","delay","humanize","dayDiffMinutes","isSame","subtract"],"sources":["../../../src/TimeAgo/formatUtils.js"],"sourcesContent":["import dayjs from \"dayjs\";\nimport calendar from \"dayjs/plugin/calendar\";\nimport duration from \"dayjs/plugin/duration\";\nimport localeData from \"dayjs/plugin/localeData\";\nimport localizedFormat from \"dayjs/plugin/localizedFormat\";\nimport relativeTime from \"dayjs/plugin/relativeTime\";\nimport updateLocale from \"dayjs/plugin/updateLocale\";\n\n/**\n * Relative time thresholds defined by\n * {@link https://xd.adobe.com/view/1b7df235-5cf8-4b51-a2f0-0be1bb591c55-4e2e/ Design System}\n *\n * Implementation using day.js {@link https://day.js.org/docs/en/customization/relative-time relativeTime}\n */\nconst thresholds = [\n { l: \"s\", r: 119, d: \"second\" },\n { l: \"m\", r: 1 },\n { l: \"mm\", r: 59, d: \"minute\" },\n { l: \"h\", r: 1 },\n { l: \"hh\", r: 23, d: \"hour\" },\n { l: \"d\", r: 1 },\n { l: \"dd\", r: 29, d: \"day\" },\n { l: \"M\", r: 1 },\n { l: \"MM\", r: 11, d: \"month\" },\n { l: \"y\", r: 17 },\n { l: \"yy\", d: \"year\" },\n];\n\ndayjs.extend(localeData);\ndayjs.extend(duration);\ndayjs.extend(calendar);\ndayjs.extend(localizedFormat);\ndayjs.extend(relativeTime, { thresholds });\ndayjs.extend(updateLocale);\n\nexport const secondsUntilNextDay = (date = new Date()) => {\n const midnight = new Date(date.getTime());\n\n midnight.setDate(midnight.getDate() + 1);\n midnight.setHours(0);\n midnight.setMinutes(0);\n midnight.setSeconds(0);\n midnight.setMilliseconds(0);\n\n return (midnight.getTime() - date.getTime()) / 1000;\n};\n\nconst secondsUntilNextWeek = (date = new Date()) => {\n const firstMonthDayOfWeek = date.getDate() - date.getDay();\n const firstMonthDayOfNextWeek = firstMonthDayOfWeek + 7; // auto roll over to next month if needed\n\n const firstDayNextWeek = new Date(date.getTime());\n\n firstDayNextWeek.setDate(firstMonthDayOfNextWeek);\n firstDayNextWeek.setHours(0);\n firstDayNextWeek.setMinutes(0);\n firstDayNextWeek.setSeconds(0);\n firstDayNextWeek.setMilliseconds(0);\n\n return (firstDayNextWeek.getTime() - date.getTime()) / 1000;\n};\n\n/**\n * @typedef {Object} TimeAgo\n * @property {string} timeAgo - the formatted date using the \"time ago format\"\n * @property {number} delay - the time until the date needs to be updated\n */\n\n/**\n * Formats a date to the a relative time format using dayjs.\n *\n * @param {Date} date - date to format.\n * @param {String} locale - locale to use.\n * @param {Boolean} [showSeconds=false] - if seconds should be part of the result.\n * @param {Date} referenceDate - reference date to use when formatting (defaults to current date).\n *\n * @return {TimeAgo} the formatted date using the \"time ago format\" and the time until it needs to be updated\n */\nexport const formatTimeAgo = (date, locale, showSeconds = false, referenceDate = new Date()) => {\n const dayReferenceDate = dayjs(referenceDate);\n const dayDate = dayjs(date).locale(locale);\n\n const dayDiffSeconds = dayReferenceDate.diff(dayDate, \"second\");\n\n const formatUseSeconds = showSeconds ? \"LTS\" : \"LT\";\n\n // check if the date is after the reference date\n if (date.getTime() > referenceDate.getTime()) {\n return {\n timeAgo: dayDate.format(`L ${formatUseSeconds}`),\n delay: (date.getTime() - referenceDate.getTime()) / 1000,\n };\n }\n\n // just now, until the 2 minutes\n if (dayDiffSeconds < 120) {\n return {\n timeAgo: dayjs.duration(dayDiffSeconds, \"second\").locale(locale).humanize(),\n delay: 120 - dayDiffSeconds,\n };\n }\n\n // ago in minutes, until the 1 hour mark\n const dayDiffMinutes = dayReferenceDate.diff(dayDate, \"minute\");\n\n if (dayDiffMinutes < 60) {\n return {\n timeAgo: dayjs.duration(-dayDiffMinutes, \"minute\").locale(locale).humanize(true),\n delay: 60 * (dayDiffMinutes + 1) - dayDiffSeconds,\n };\n }\n\n // formatted date with text description for today\n if (dayReferenceDate.isSame(dayDate, \"day\")) {\n return {\n timeAgo: `${dayDate.calendar(dayReferenceDate)}`,\n delay: secondsUntilNextDay(referenceDate),\n };\n }\n\n // formatted date with text description for yesterday\n if (dayReferenceDate.subtract(1, \"day\").isSame(dayDate, \"day\")) {\n return {\n timeAgo: `${dayDate.calendar(dayReferenceDate)}`,\n delay: secondsUntilNextDay(referenceDate),\n };\n }\n\n // formatted date with week during the current week\n if (dayDate.isSame(dayReferenceDate, \"week\")) {\n return {\n timeAgo: dayDate.format(`ddd, ${formatUseSeconds}`),\n delay: secondsUntilNextWeek(date),\n };\n }\n\n // formatted without special gimmicks\n return {\n timeAgo: dayDate.format(`L ${formatUseSeconds}`),\n delay: 0,\n };\n};\n"],"mappings":"AAAA,OAAOA,
|
|
1
|
+
{"version":3,"file":"formatUtils.js","names":["dayjs","calendar","duration","localeData","localizedFormat","relativeTime","updateLocale","thresholds","l","r","d","extend","secondsUntilNextDay","date","Date","midnight","getTime","setDate","getDate","setHours","setMinutes","setSeconds","setMilliseconds","secondsUntilNextWeek","firstMonthDayOfWeek","getDay","firstMonthDayOfNextWeek","firstDayNextWeek","formatTimeAgo","locale","showSeconds","referenceDate","dayReferenceDate","dayDate","dayDiffSeconds","diff","formatUseSeconds","timeAgo","format","delay","humanize","dayDiffMinutes","isSame","subtract"],"sources":["../../../src/TimeAgo/formatUtils.js"],"sourcesContent":["import dayjs from \"dayjs\";\nimport calendar from \"dayjs/plugin/calendar\";\nimport duration from \"dayjs/plugin/duration\";\nimport localeData from \"dayjs/plugin/localeData\";\nimport localizedFormat from \"dayjs/plugin/localizedFormat\";\nimport relativeTime from \"dayjs/plugin/relativeTime\";\nimport updateLocale from \"dayjs/plugin/updateLocale\";\n\n/**\n * Relative time thresholds defined by\n * {@link https://xd.adobe.com/view/1b7df235-5cf8-4b51-a2f0-0be1bb591c55-4e2e/ Design System}\n *\n * Implementation using day.js {@link https://day.js.org/docs/en/customization/relative-time relativeTime}\n */\nconst thresholds = [\n { l: \"s\", r: 119, d: \"second\" },\n { l: \"m\", r: 1 },\n { l: \"mm\", r: 59, d: \"minute\" },\n { l: \"h\", r: 1 },\n { l: \"hh\", r: 23, d: \"hour\" },\n { l: \"d\", r: 1 },\n { l: \"dd\", r: 29, d: \"day\" },\n { l: \"M\", r: 1 },\n { l: \"MM\", r: 11, d: \"month\" },\n { l: \"y\", r: 17 },\n { l: \"yy\", d: \"year\" },\n];\n\ndayjs.extend(localeData);\ndayjs.extend(duration);\ndayjs.extend(calendar);\ndayjs.extend(localizedFormat);\ndayjs.extend(relativeTime, { thresholds });\ndayjs.extend(updateLocale);\n\nexport const secondsUntilNextDay = (date = new Date()) => {\n const midnight = new Date(date.getTime());\n\n midnight.setDate(midnight.getDate() + 1);\n midnight.setHours(0);\n midnight.setMinutes(0);\n midnight.setSeconds(0);\n midnight.setMilliseconds(0);\n\n return (midnight.getTime() - date.getTime()) / 1000;\n};\n\nconst secondsUntilNextWeek = (date = new Date()) => {\n const firstMonthDayOfWeek = date.getDate() - date.getDay();\n const firstMonthDayOfNextWeek = firstMonthDayOfWeek + 7; // auto roll over to next month if needed\n\n const firstDayNextWeek = new Date(date.getTime());\n\n firstDayNextWeek.setDate(firstMonthDayOfNextWeek);\n firstDayNextWeek.setHours(0);\n firstDayNextWeek.setMinutes(0);\n firstDayNextWeek.setSeconds(0);\n firstDayNextWeek.setMilliseconds(0);\n\n return (firstDayNextWeek.getTime() - date.getTime()) / 1000;\n};\n\n/**\n * @typedef {Object} TimeAgo\n * @property {string} timeAgo - the formatted date using the \"time ago format\"\n * @property {number} delay - the time until the date needs to be updated\n */\n\n/**\n * Formats a date to the a relative time format using dayjs.\n *\n * @param {Date} date - date to format.\n * @param {String} locale - locale to use.\n * @param {Boolean} [showSeconds=false] - if seconds should be part of the result.\n * @param {Date} referenceDate - reference date to use when formatting (defaults to current date).\n *\n * @return {TimeAgo} the formatted date using the \"time ago format\" and the time until it needs to be updated\n */\nexport const formatTimeAgo = (date, locale, showSeconds = false, referenceDate = new Date()) => {\n const dayReferenceDate = dayjs(referenceDate);\n const dayDate = dayjs(date).locale(locale);\n\n const dayDiffSeconds = dayReferenceDate.diff(dayDate, \"second\");\n\n const formatUseSeconds = showSeconds ? \"LTS\" : \"LT\";\n\n // check if the date is after the reference date\n if (date.getTime() > referenceDate.getTime()) {\n return {\n timeAgo: dayDate.format(`L ${formatUseSeconds}`),\n delay: (date.getTime() - referenceDate.getTime()) / 1000,\n };\n }\n\n // just now, until the 2 minutes\n if (dayDiffSeconds < 120) {\n return {\n timeAgo: dayjs.duration(dayDiffSeconds, \"second\").locale(locale).humanize(),\n delay: 120 - dayDiffSeconds,\n };\n }\n\n // ago in minutes, until the 1 hour mark\n const dayDiffMinutes = dayReferenceDate.diff(dayDate, \"minute\");\n\n if (dayDiffMinutes < 60) {\n return {\n timeAgo: dayjs.duration(-dayDiffMinutes, \"minute\").locale(locale).humanize(true),\n delay: 60 * (dayDiffMinutes + 1) - dayDiffSeconds,\n };\n }\n\n // formatted date with text description for today\n if (dayReferenceDate.isSame(dayDate, \"day\")) {\n return {\n timeAgo: `${dayDate.calendar(dayReferenceDate)}`,\n delay: secondsUntilNextDay(referenceDate),\n };\n }\n\n // formatted date with text description for yesterday\n if (dayReferenceDate.subtract(1, \"day\").isSame(dayDate, \"day\")) {\n return {\n timeAgo: `${dayDate.calendar(dayReferenceDate)}`,\n delay: secondsUntilNextDay(referenceDate),\n };\n }\n\n // formatted date with week during the current week\n if (dayDate.isSame(dayReferenceDate, \"week\")) {\n return {\n timeAgo: dayDate.format(`ddd, ${formatUseSeconds}`),\n delay: secondsUntilNextWeek(date),\n };\n }\n\n // formatted without special gimmicks\n return {\n timeAgo: dayDate.format(`L ${formatUseSeconds}`),\n delay: 0,\n };\n};\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,QAAQ,MAAM,uBAAuB;AAC5C,OAAOC,QAAQ,MAAM,uBAAuB;AAC5C,OAAOC,UAAU,MAAM,yBAAyB;AAChD,OAAOC,eAAe,MAAM,8BAA8B;AAC1D,OAAOC,YAAY,MAAM,2BAA2B;AACpD,OAAOC,YAAY,MAAM,2BAA2B;;AAEpD;AACA;AACA;AACA;AACA;AACA;AACA,IAAMC,UAAU,GAAG,CACjB;EAAEC,CAAC,EAAE,GAAG;EAA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CAACT,OAAO,EAAE,KAAK,CAAC,EAAE;IAC3C,OAAO;MACLI,OAAO,YAAKJ,OAAO,CAAChC,QAAQ,CAAC+B,gBAAgB,CAAC,CAAE;MAChDO,KAAK,EAAE3B,mBAAmB,CAACmB,aAAa;IAC1C,CAAC;EACH;;EAEA;EACA,IAAIC,gBAAgB,CAACW,QAAQ,CAAC,CAAC,EAAE,KAAK,CAAC,CAACD,MAAM,CAACT,OAAO,EAAE,KAAK,CAAC,EAAE;IAC9D,OAAO;MACLI,OAAO,YAAKJ,OAAO,CAAChC,QAAQ,CAAC+B,gBAAgB,CAAC,CAAE;MAChDO,KAAK,EAAE3B,mBAAmB,CAACmB,aAAa;IAC1C,CAAC;EACH;;EAEA;EACA,IAAIE,OAAO,CAACS,MAAM,CAACV,gBAAgB,EAAE,MAAM,CAAC,EAAE;IAC5C,OAAO;MACLK,OAAO,EAAEJ,OAAO,CAACK,MAAM,gBAASF,gBAAgB,EAAG;MACnDG,KAAK,EAAEhB,oBAAoB,CAACV,IAAI;IAClC,CAAC;EACH;;EAEA;EACA,OAAO;IACLwB,OAAO,EAAEJ,OAAO,CAACK,MAAM,aAAMF,gBAAgB,EAAG;IAChDG,KAAK,EAAE;EACT,CAAC;AACH,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["default","useTimeAgo"],"sources":["../../../src/TimeAgo/index.js"],"sourcesContent":["export { default } from \"./TimeAgo\";\nexport { default as useTimeAgo } from \"./useTimeAgo\";\n"],"mappings":"AAAA,SAASA,
|
|
1
|
+
{"version":3,"file":"index.js","names":["default","useTimeAgo"],"sources":["../../../src/TimeAgo/index.js"],"sourcesContent":["export { default } from \"./TimeAgo\";\nexport { default as useTimeAgo } from \"./useTimeAgo\";\n"],"mappings":"AAAA,SAASA,OAAO,QAAQ,WAAW;AACnC,SAASA,OAAO,IAAIC,UAAU,QAAQ,cAAc"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styles.js","names":["styles","root"],"sources":["../../../src/TimeAgo/styles.js"],"sourcesContent":["const styles = {\n root: {},\n};\n\nexport default styles;\n"],"mappings":"AAAA,IAAMA,MAAM,GAAG;EACbC,IAAI,EAAE;
|
|
1
|
+
{"version":3,"file":"styles.js","names":["styles","root"],"sources":["../../../src/TimeAgo/styles.js"],"sourcesContent":["const styles = {\n root: {},\n};\n\nexport default styles;\n"],"mappings":"AAAA,IAAMA,MAAM,GAAG;EACbC,IAAI,EAAE,CAAC;AACT,CAAC;AAED,eAAeD,MAAM"}
|
|
@@ -2,27 +2,24 @@ import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
|
2
2
|
import { useEffect, useState } from "react";
|
|
3
3
|
import useTimeout from "./useTimeout";
|
|
4
4
|
import { formatTimeAgo } from "./formatUtils";
|
|
5
|
+
|
|
5
6
|
/**
|
|
6
7
|
* Calls `formatTimeAgo` with timestamp conversion
|
|
7
8
|
*/
|
|
8
|
-
|
|
9
9
|
var fmt = function fmt(timestamp, locale, showSeconds) {
|
|
10
10
|
var timestampMs = String(timestamp).length > 11 ? timestamp : timestamp * 1000;
|
|
11
11
|
return formatTimeAgo(new Date(timestampMs), locale, showSeconds);
|
|
12
12
|
};
|
|
13
|
-
|
|
14
13
|
export default function useTimeAgo(timestamp, options) {
|
|
15
14
|
var locale = options.locale,
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
15
|
+
_options$disableRefre = options.disableRefresh,
|
|
16
|
+
disableRefresh = _options$disableRefre === void 0 ? false : _options$disableRefre,
|
|
17
|
+
_options$showSeconds = options.showSeconds,
|
|
18
|
+
showSeconds = _options$showSeconds === void 0 ? false : _options$showSeconds;
|
|
21
19
|
var _useState = useState(fmt(timestamp, locale, showSeconds)),
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
20
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
21
|
+
timeAgo = _useState2[0],
|
|
22
|
+
setTimeAgo = _useState2[1];
|
|
26
23
|
var refreshTime = disableRefresh ? 0 : timeAgo.delay * 1000;
|
|
27
24
|
useEffect(function () {
|
|
28
25
|
var newTimeAgo = fmt(timestamp, locale, showSeconds);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useTimeAgo.js","names":["useEffect","useState","useTimeout","formatTimeAgo","fmt","timestamp","locale","showSeconds","timestampMs","String","length","Date","useTimeAgo","options","disableRefresh","timeAgo","setTimeAgo","refreshTime","delay","newTimeAgo"],"sources":["../../../src/TimeAgo/useTimeAgo.js"],"sourcesContent":["import { useEffect, useState } from \"react\";\nimport useTimeout from \"./useTimeout\";\nimport { formatTimeAgo } from \"./formatUtils\";\n\n/**\n * Calls `formatTimeAgo` with timestamp conversion\n */\nconst fmt = (timestamp, locale, showSeconds) => {\n const timestampMs = String(timestamp).length > 11 ? timestamp : timestamp * 1000;\n return formatTimeAgo(new Date(timestampMs), locale, showSeconds);\n};\n\nexport default function useTimeAgo(timestamp, options) {\n const { locale, disableRefresh = false, showSeconds = false } = options;\n const [timeAgo, setTimeAgo] = useState(fmt(timestamp, locale, showSeconds));\n const refreshTime = disableRefresh ? 0 : timeAgo.delay * 1000;\n\n useEffect(() => {\n const newTimeAgo = fmt(timestamp, locale, showSeconds);\n setTimeAgo(newTimeAgo);\n }, [timestamp, locale, showSeconds]);\n\n useTimeout(() => {\n const newTimeAgo = fmt(timestamp, locale, showSeconds);\n setTimeAgo(newTimeAgo);\n }, refreshTime);\n\n return timeAgo.timeAgo;\n}\n"],"mappings":";AAAA,SAASA,
|
|
1
|
+
{"version":3,"file":"useTimeAgo.js","names":["useEffect","useState","useTimeout","formatTimeAgo","fmt","timestamp","locale","showSeconds","timestampMs","String","length","Date","useTimeAgo","options","disableRefresh","timeAgo","setTimeAgo","refreshTime","delay","newTimeAgo"],"sources":["../../../src/TimeAgo/useTimeAgo.js"],"sourcesContent":["import { useEffect, useState } from \"react\";\nimport useTimeout from \"./useTimeout\";\nimport { formatTimeAgo } from \"./formatUtils\";\n\n/**\n * Calls `formatTimeAgo` with timestamp conversion\n */\nconst fmt = (timestamp, locale, showSeconds) => {\n const timestampMs = String(timestamp).length > 11 ? timestamp : timestamp * 1000;\n return formatTimeAgo(new Date(timestampMs), locale, showSeconds);\n};\n\nexport default function useTimeAgo(timestamp, options) {\n const { locale, disableRefresh = false, showSeconds = false } = options;\n const [timeAgo, setTimeAgo] = useState(fmt(timestamp, locale, showSeconds));\n const refreshTime = disableRefresh ? 0 : timeAgo.delay * 1000;\n\n useEffect(() => {\n const newTimeAgo = fmt(timestamp, locale, showSeconds);\n setTimeAgo(newTimeAgo);\n }, [timestamp, locale, showSeconds]);\n\n useTimeout(() => {\n const newTimeAgo = fmt(timestamp, locale, showSeconds);\n setTimeAgo(newTimeAgo);\n }, refreshTime);\n\n return timeAgo.timeAgo;\n}\n"],"mappings":";AAAA,SAASA,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAC3C,OAAOC,UAAU,MAAM,cAAc;AACrC,SAASC,aAAa,QAAQ,eAAe;;AAE7C;AACA;AACA;AACA,IAAMC,GAAG,GAAG,SAANA,GAAG,CAAIC,SAAS,EAAEC,MAAM,EAAEC,WAAW,EAAK;EAC9C,IAAMC,WAAW,GAAGC,MAAM,CAACJ,SAAS,CAAC,CAACK,MAAM,GAAG,EAAE,GAAGL,SAAS,GAAGA,SAAS,GAAG,IAAI;EAChF,OAAOF,aAAa,CAAC,IAAIQ,IAAI,CAACH,WAAW,CAAC,EAAEF,MAAM,EAAEC,WAAW,CAAC;AAClE,CAAC;AAED,eAAe,SAASK,UAAU,CAACP,SAAS,EAAEQ,OAAO,EAAE;EACrD,IAAQP,MAAM,GAAkDO,OAAO,CAA/DP,MAAM;IAAA,wBAAkDO,OAAO,CAAvDC,cAAc;IAAdA,cAAc,sCAAG,KAAK;IAAA,uBAA0BD,OAAO,CAA/BN,WAAW;IAAXA,WAAW,qCAAG,KAAK;EAC3D,gBAA8BN,QAAQ,CAACG,GAAG,CAACC,SAAS,EAAEC,MAAM,EAAEC,WAAW,CAAC,CAAC;IAAA;IAApEQ,OAAO;IAAEC,UAAU;EAC1B,IAAMC,WAAW,GAAGH,cAAc,GAAG,CAAC,GAAGC,OAAO,CAACG,KAAK,GAAG,IAAI;EAE7DlB,SAAS,CAAC,YAAM;IACd,IAAMmB,UAAU,GAAGf,GAAG,CAACC,SAAS,EAAEC,MAAM,EAAEC,WAAW,CAAC;IACtDS,UAAU,CAACG,UAAU,CAAC;EACxB,CAAC,EAAE,CAACd,SAAS,EAAEC,MAAM,EAAEC,WAAW,CAAC,CAAC;EAEpCL,UAAU,CAAC,YAAM;IACf,IAAMiB,UAAU,GAAGf,GAAG,CAACC,SAAS,EAAEC,MAAM,EAAEC,WAAW,CAAC;IACtDS,UAAU,CAACG,UAAU,CAAC;EACxB,CAAC,EAAEF,WAAW,CAAC;EAEf,OAAOF,OAAO,CAACA,OAAO;AACxB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useTimeout.js","names":["useEffect","useRef","useTimeout","callback","delay","savedCallback","current","undefined","id","setTimeout","clearTimeout"],"sources":["../../../src/TimeAgo/useTimeout.js"],"sourcesContent":["import { useEffect, useRef } from \"react\";\n\nexport default function useTimeout(callback, delay) {\n const savedCallback = useRef(callback);\n\n useEffect(() => {\n savedCallback.current = callback;\n }, [callback]);\n\n useEffect(() => {\n if (!delay) return undefined;\n\n const id = setTimeout(() => savedCallback.current(), delay);\n return () => clearTimeout(id);\n }, [delay]);\n}\n"],"mappings":"AAAA,SAASA,
|
|
1
|
+
{"version":3,"file":"useTimeout.js","names":["useEffect","useRef","useTimeout","callback","delay","savedCallback","current","undefined","id","setTimeout","clearTimeout"],"sources":["../../../src/TimeAgo/useTimeout.js"],"sourcesContent":["import { useEffect, useRef } from \"react\";\n\nexport default function useTimeout(callback, delay) {\n const savedCallback = useRef(callback);\n\n useEffect(() => {\n savedCallback.current = callback;\n }, [callback]);\n\n useEffect(() => {\n if (!delay) return undefined;\n\n const id = setTimeout(() => savedCallback.current(), delay);\n return () => clearTimeout(id);\n }, [delay]);\n}\n"],"mappings":"AAAA,SAASA,SAAS,EAAEC,MAAM,QAAQ,OAAO;AAEzC,eAAe,SAASC,UAAU,CAACC,QAAQ,EAAEC,KAAK,EAAE;EAClD,IAAMC,aAAa,GAAGJ,MAAM,CAACE,QAAQ,CAAC;EAEtCH,SAAS,CAAC,YAAM;IACdK,aAAa,CAACC,OAAO,GAAGH,QAAQ;EAClC,CAAC,EAAE,CAACA,QAAQ,CAAC,CAAC;EAEdH,SAAS,CAAC,YAAM;IACd,IAAI,CAACI,KAAK,EAAE,OAAOG,SAAS;IAE5B,IAAMC,EAAE,GAAGC,UAAU,CAAC;MAAA,OAAMJ,aAAa,CAACC,OAAO,EAAE;IAAA,GAAEF,KAAK,CAAC;IAC3D,OAAO;MAAA,OAAMM,YAAY,CAACF,EAAE,CAAC;IAAA;EAC/B,CAAC,EAAE,CAACJ,KAAK,CAAC,CAAC;AACb"}
|
|
@@ -13,7 +13,7 @@ export type HvWizardProps = StandardProps<
|
|
|
13
13
|
/**
|
|
14
14
|
* Class names to be applied.
|
|
15
15
|
*/
|
|
16
|
-
className
|
|
16
|
+
className?: string;
|
|
17
17
|
/**
|
|
18
18
|
* Current state of the Wizard.
|
|
19
19
|
*/
|
|
@@ -25,19 +25,19 @@ export type HvWizardProps = StandardProps<
|
|
|
25
25
|
/**
|
|
26
26
|
* Function executed on submit.
|
|
27
27
|
*/
|
|
28
|
-
|
|
28
|
+
handleSubmit: any;
|
|
29
29
|
/**
|
|
30
30
|
* Title for the wizard.
|
|
31
31
|
*/
|
|
32
|
-
title
|
|
32
|
+
title?: string;
|
|
33
33
|
/**
|
|
34
34
|
* The content of the component.
|
|
35
35
|
*/
|
|
36
|
-
children
|
|
36
|
+
children?: React.ReactNode;
|
|
37
37
|
/**
|
|
38
38
|
* An object containing all the labels for the wizard.
|
|
39
39
|
*/
|
|
40
|
-
labels
|
|
40
|
+
labels?: HvWizardActionsProps["labels"] & HvWizardTitleProps["labels"];
|
|
41
41
|
/**
|
|
42
42
|
* Shows the summary button.
|
|
43
43
|
*/
|
|
@@ -8,12 +8,9 @@ import "core-js/modules/es.object.get-own-property-descriptors.js";
|
|
|
8
8
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
9
9
|
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
10
10
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
11
|
-
var _excluded = ["className", "children", "onClose", "
|
|
12
|
-
|
|
11
|
+
var _excluded = ["className", "children", "onClose", "handleSubmit", "title", "open", "skippable", "loading", "hasSummary", "labels", "fixedHeight", "customStep"];
|
|
13
12
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
14
|
-
|
|
15
13
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
16
|
-
|
|
17
14
|
import React from "react";
|
|
18
15
|
import PropTypes from "prop-types";
|
|
19
16
|
import { withStyles } from "@mui/styles";
|
|
@@ -25,44 +22,40 @@ import WizardActions from "./WizardActions";
|
|
|
25
22
|
import styles from "./styles";
|
|
26
23
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
27
24
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
28
|
-
|
|
29
25
|
var HvWizard = function HvWizard(_ref) {
|
|
30
26
|
var className = _ref.className,
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
27
|
+
children = _ref.children,
|
|
28
|
+
onClose = _ref.onClose,
|
|
29
|
+
handleSubmit = _ref.handleSubmit,
|
|
30
|
+
title = _ref.title,
|
|
31
|
+
open = _ref.open,
|
|
32
|
+
_ref$skippable = _ref.skippable,
|
|
33
|
+
skippable = _ref$skippable === void 0 ? true : _ref$skippable,
|
|
34
|
+
_ref$loading = _ref.loading,
|
|
35
|
+
loading = _ref$loading === void 0 ? false : _ref$loading,
|
|
36
|
+
_ref$hasSummary = _ref.hasSummary,
|
|
37
|
+
hasSummary = _ref$hasSummary === void 0 ? false : _ref$hasSummary,
|
|
38
|
+
_ref$labels = _ref.labels,
|
|
39
|
+
labels = _ref$labels === void 0 ? {
|
|
40
|
+
cancel: "Cancel",
|
|
41
|
+
next: "Next",
|
|
42
|
+
previous: "Previous",
|
|
43
|
+
skip: "Skip",
|
|
44
|
+
submit: "Submit",
|
|
45
|
+
summary: "Summary"
|
|
46
|
+
} : _ref$labels,
|
|
47
|
+
_ref$fixedHeight = _ref.fixedHeight,
|
|
48
|
+
fixedHeight = _ref$fixedHeight === void 0 ? false : _ref$fixedHeight,
|
|
49
|
+
customStep = _ref.customStep,
|
|
50
|
+
others = _objectWithoutProperties(_ref, _excluded);
|
|
56
51
|
var _React$useState = React.useState({}),
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
52
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
53
|
+
context = _React$useState2[0],
|
|
54
|
+
setContext = _React$useState2[1];
|
|
61
55
|
var _React$useState3 = React.useState(0),
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
56
|
+
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
|
57
|
+
tab = _React$useState4[0],
|
|
58
|
+
setTab = _React$useState4[1];
|
|
66
59
|
var contextValue = React.useMemo(function () {
|
|
67
60
|
return {
|
|
68
61
|
context: context,
|
|
@@ -105,53 +98,44 @@ var HvWizard = function HvWizard(_ref) {
|
|
|
105
98
|
tab: tab,
|
|
106
99
|
changeTab: setTab,
|
|
107
100
|
handleClose: handleClose,
|
|
108
|
-
|
|
101
|
+
handleSubmit: handleSubmit
|
|
109
102
|
})]
|
|
110
103
|
}))
|
|
111
104
|
});
|
|
112
105
|
};
|
|
113
|
-
|
|
114
106
|
process.env.NODE_ENV !== "production" ? HvWizard.propTypes = {
|
|
115
107
|
/**
|
|
116
108
|
* Class names to be applied.
|
|
117
109
|
*/
|
|
118
110
|
className: PropTypes.string,
|
|
119
|
-
|
|
120
111
|
/**
|
|
121
112
|
* Current state of the Wizard.
|
|
122
113
|
*/
|
|
123
114
|
open: PropTypes.bool.isRequired,
|
|
124
|
-
|
|
125
115
|
/**
|
|
126
116
|
* Function executed on close.
|
|
127
117
|
*/
|
|
128
118
|
onClose: PropTypes.func.isRequired,
|
|
129
|
-
|
|
130
119
|
/**
|
|
131
120
|
* Function executed on submit.
|
|
132
121
|
*/
|
|
133
|
-
|
|
134
|
-
|
|
122
|
+
handleSubmit: PropTypes.func.isRequired,
|
|
135
123
|
/**
|
|
136
124
|
* Enables the skip button.
|
|
137
125
|
*/
|
|
138
126
|
skippable: PropTypes.bool,
|
|
139
|
-
|
|
140
127
|
/**
|
|
141
128
|
* Title for the wizard.
|
|
142
129
|
*/
|
|
143
130
|
title: PropTypes.string,
|
|
144
|
-
|
|
145
131
|
/**
|
|
146
132
|
* Shows the summary button.
|
|
147
133
|
*/
|
|
148
134
|
hasSummary: PropTypes.bool,
|
|
149
|
-
|
|
150
135
|
/**
|
|
151
136
|
* The content of the component.
|
|
152
137
|
*/
|
|
153
138
|
children: PropTypes.node,
|
|
154
|
-
|
|
155
139
|
/**
|
|
156
140
|
* An object containing all the labels for the wizard.
|
|
157
141
|
*/
|
|
@@ -160,43 +144,35 @@ process.env.NODE_ENV !== "production" ? HvWizard.propTypes = {
|
|
|
160
144
|
* Cancel button label.
|
|
161
145
|
*/
|
|
162
146
|
cancel: PropTypes.string,
|
|
163
|
-
|
|
164
147
|
/**
|
|
165
148
|
* Skip button label.
|
|
166
149
|
*/
|
|
167
150
|
skip: PropTypes.string,
|
|
168
|
-
|
|
169
151
|
/**
|
|
170
152
|
* Previous button label.
|
|
171
153
|
*/
|
|
172
154
|
previous: PropTypes.string,
|
|
173
|
-
|
|
174
155
|
/**
|
|
175
156
|
* Next button label.
|
|
176
157
|
*/
|
|
177
158
|
next: PropTypes.string,
|
|
178
|
-
|
|
179
159
|
/**
|
|
180
160
|
* Submit button label.
|
|
181
161
|
*/
|
|
182
162
|
submit: PropTypes.string,
|
|
183
|
-
|
|
184
163
|
/**
|
|
185
164
|
* Summary button label.
|
|
186
165
|
*/
|
|
187
166
|
summary: PropTypes.string
|
|
188
167
|
}),
|
|
189
|
-
|
|
190
168
|
/**
|
|
191
169
|
* Forces minimum height to the component.
|
|
192
170
|
*/
|
|
193
171
|
fixedHeight: PropTypes.bool,
|
|
194
|
-
|
|
195
172
|
/**
|
|
196
173
|
* Whether the loading animation is shown.
|
|
197
174
|
*/
|
|
198
175
|
loading: PropTypes.bool,
|
|
199
|
-
|
|
200
176
|
/**
|
|
201
177
|
* Custom object to define type, size and width of the StepNavigation component
|
|
202
178
|
*/
|
|
@@ -205,12 +181,10 @@ process.env.NODE_ENV !== "production" ? HvWizard.propTypes = {
|
|
|
205
181
|
* Type of step navigation. Values = {"Simple", "Default"}.
|
|
206
182
|
*/
|
|
207
183
|
type: PropTypes.oneOf(["Simple", "Default"]),
|
|
208
|
-
|
|
209
184
|
/**
|
|
210
185
|
* Sets one of the standard sizes of the steps. Values = {"XS", "SM", "MD", "LG", "XL"}
|
|
211
186
|
*/
|
|
212
187
|
stepSize: PropTypes.oneOf(["XS", "SM", "MD", "LG", "XL"]),
|
|
213
|
-
|
|
214
188
|
/**
|
|
215
189
|
* Width of the component element on each breakpoint screen resolution.
|
|
216
190
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Wizard.js","names":["React","PropTypes","withStyles","WizardContext","WizardContainer","WizardTitle","WizardContent","WizardActions","styles","HvWizard","className","children","onClose","
|
|
1
|
+
{"version":3,"file":"Wizard.js","names":["React","PropTypes","withStyles","WizardContext","WizardContainer","WizardTitle","WizardContent","WizardActions","styles","HvWizard","className","children","onClose","handleSubmit","title","open","skippable","loading","hasSummary","labels","cancel","next","previous","skip","submit","summary","fixedHeight","customStep","others","useState","context","setContext","tab","setTab","contextValue","useMemo","useEffect","handleClose","useCallback","evt","reason","propTypes","string","bool","isRequired","func","node","shape","type","oneOf","stepSize","width","xs","number","sm","md","lg","xl","name"],"sources":["../../../src/Wizard/Wizard.js"],"sourcesContent":["import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport { withStyles } from \"@mui/styles\";\nimport WizardContext from \"./WizardContext\";\nimport WizardContainer from \"./WizardContainer\";\nimport WizardTitle from \"./WizardTitle\";\nimport WizardContent from \"./WizardContent\";\nimport WizardActions from \"./WizardActions\";\n\nimport styles from \"./styles\";\n\nconst HvWizard = ({\n className,\n children,\n onClose,\n handleSubmit,\n title,\n open,\n skippable = true,\n loading = false,\n hasSummary = false,\n labels = {\n cancel: \"Cancel\",\n next: \"Next\",\n previous: \"Previous\",\n skip: \"Skip\",\n submit: \"Submit\",\n summary: \"Summary\",\n },\n fixedHeight = false,\n customStep,\n ...others\n}) => {\n const [context, setContext] = React.useState({});\n const [tab, setTab] = React.useState(0);\n\n const contextValue = React.useMemo(\n () => ({\n context,\n setContext,\n }),\n [context, setContext]\n );\n\n React.useEffect(() => {\n if (!open) {\n setTab(0);\n }\n }, [open]);\n\n const handleClose = React.useCallback(\n (evt, reason) => {\n if (reason !== \"backdropClick\") {\n onClose(evt, reason);\n }\n },\n [onClose]\n );\n\n return (\n <WizardContext.Provider value={contextValue}>\n <WizardContainer className={className} handleClose={handleClose} open={open} {...others}>\n <WizardTitle\n title={title}\n hasSummary={hasSummary}\n labels={labels}\n tab={tab}\n changeTab={setTab}\n customStep={customStep}\n />\n <WizardContent loading={loading} fixedHeight={fixedHeight} tab={tab}>\n {children}\n </WizardContent>\n <WizardActions\n loading={loading}\n skippable={skippable}\n labels={labels}\n tab={tab}\n changeTab={setTab}\n handleClose={handleClose}\n handleSubmit={handleSubmit}\n />\n </WizardContainer>\n </WizardContext.Provider>\n );\n};\n\nHvWizard.propTypes = {\n /**\n * Class names to be applied.\n */\n className: PropTypes.string,\n /**\n * Current state of the Wizard.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Function executed on close.\n */\n onClose: PropTypes.func.isRequired,\n /**\n * Function executed on submit.\n */\n handleSubmit: PropTypes.func.isRequired,\n /**\n * Enables the skip button.\n */\n skippable: PropTypes.bool,\n /**\n * Title for the wizard.\n */\n title: PropTypes.string,\n /**\n * Shows the summary button.\n */\n hasSummary: PropTypes.bool,\n /**\n * The content of the component.\n */\n children: PropTypes.node,\n /**\n * An object containing all the labels for the wizard.\n */\n labels: PropTypes.shape({\n /**\n * Cancel button label.\n */\n cancel: PropTypes.string,\n /**\n * Skip button label.\n */\n skip: PropTypes.string,\n /**\n * Previous button label.\n */\n previous: PropTypes.string,\n /**\n * Next button label.\n */\n next: PropTypes.string,\n /**\n * Submit button label.\n */\n submit: PropTypes.string,\n /**\n * Summary button label.\n */\n summary: PropTypes.string,\n }),\n /**\n * Forces minimum height to the component.\n */\n fixedHeight: PropTypes.bool,\n /**\n * Whether the loading animation is shown.\n */\n loading: PropTypes.bool,\n /**\n * Custom object to define type, size and width of the StepNavigation component\n */\n customStep: PropTypes.shape({\n /**\n * Type of step navigation. Values = {\"Simple\", \"Default\"}.\n */\n type: PropTypes.oneOf([\"Simple\", \"Default\"]),\n /**\n * Sets one of the standard sizes of the steps. Values = {\"XS\", \"SM\", \"MD\", \"LG\", \"XL\"}\n */\n stepSize: PropTypes.oneOf([\"XS\", \"SM\", \"MD\", \"LG\", \"XL\"]),\n /**\n * Width of the component element on each breakpoint screen resolution.\n */\n width: PropTypes.shape({\n xs: PropTypes.number,\n sm: PropTypes.number,\n md: PropTypes.number,\n lg: PropTypes.number,\n xl: PropTypes.number,\n }),\n }),\n};\n\nexport default withStyles(styles, { name: \"HvWizard\" })(HvWizard);\n"],"mappings":";;;;;;;;;;;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,SAAS,MAAM,YAAY;AAClC,SAASC,UAAU,QAAQ,aAAa;AACxC,OAAOC,aAAa,MAAM,iBAAiB;AAC3C,OAAOC,eAAe,MAAM,mBAAmB;AAC/C,OAAOC,WAAW,MAAM,eAAe;AACvC,OAAOC,aAAa,MAAM,iBAAiB;AAC3C,OAAOC,aAAa,MAAM,iBAAiB;AAE3C,OAAOC,MAAM,MAAM,UAAU;AAAC;AAAA;AAE9B,IAAMC,QAAQ,GAAG,SAAXA,QAAQ,OAqBR;EAAA,IApBJC,SAAS,QAATA,SAAS;IACTC,QAAQ,QAARA,QAAQ;IACRC,OAAO,QAAPA,OAAO;IACPC,YAAY,QAAZA,YAAY;IACZC,KAAK,QAALA,KAAK;IACLC,IAAI,QAAJA,IAAI;IAAA,sBACJC,SAAS;IAATA,SAAS,+BAAG,IAAI;IAAA,oBAChBC,OAAO;IAAPA,OAAO,6BAAG,KAAK;IAAA,uBACfC,UAAU;IAAVA,UAAU,gCAAG,KAAK;IAAA,mBAClBC,MAAM;IAANA,MAAM,4BAAG;MACPC,MAAM,EAAE,QAAQ;MAChBC,IAAI,EAAE,MAAM;MACZC,QAAQ,EAAE,UAAU;MACpBC,IAAI,EAAE,M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;AACJ;AACA;IACIjB,OAAO,EAAExB,SAAS,CAACyC;EACrB,CAAC,CAAC;EACF;AACF;AACA;EACEhB,WAAW,EAAEzB,SAAS,CAAC0C,IAAI;EAC3B;AACF;AACA;EACE1B,OAAO,EAAEhB,SAAS,CAAC0C,IAAI;EACvB;AACF;AACA;EACEhB,UAAU,EAAE1B,SAAS,CAAC8C,KAAK,CAAC;IAC1B;AACJ;AACA;IACIC,IAAI,EAAE/C,SAAS,CAACgD,KAAK,CAAC,CAAC,QAAQ,EAAE,SAAS,CAAC,CAAC;IAC5C;AACJ;AACA;IACIC,QAAQ,EAAEjD,SAAS,CAACgD,KAAK,CAAC,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;IACzD;AACJ;AACA;IACIE,KAAK,EAAElD,SAAS,CAAC8C,KAAK,CAAC;MACrBK,EAAE,EAAEnD,SAAS,CAACoD,MAAM;MACpBC,EAAE,EAAErD,SAAS,CAACoD,MAAM;MACpBE,EAAE,EAAEtD,SAAS,CAACoD,MAAM;MACpBG,EAAE,EAAEvD,SAAS,CAACoD,MAAM;MACpBI,EAAE,EAAExD,SAAS,CAACoD;IAChB,CAAC;EACH,CAAC;AACH,CAAC;AAED,eAAenD,UAAU,CAACM,MAAM,EAAE;EAAEkD,IAAI,EAAE;AAAW,CAAC,CAAC,CAACjD,QAAQ,CAAC"}
|
|
@@ -22,11 +22,11 @@ export type HvWizardActionsProps = StandardProps<
|
|
|
22
22
|
/**
|
|
23
23
|
* Function to handle the submit button. Also sends the current context state.
|
|
24
24
|
*/
|
|
25
|
-
|
|
25
|
+
handleSubmit: (context: any) => void;
|
|
26
26
|
/**
|
|
27
27
|
* An object containing all the labels for the wizard actions component.
|
|
28
28
|
*/
|
|
29
|
-
labels
|
|
29
|
+
labels?: {
|
|
30
30
|
/**
|
|
31
31
|
* Cancel button label.
|
|
32
32
|
*/
|