@quidgest/ui 0.28.0 → 0.30.0
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/CHANGELOG.md +110 -8
- package/README.md +15 -14
- package/dist/json/api.json +2692 -1005
- package/dist/manifest/components.json +0 -1
- package/dist/ui.css +136 -97
- package/dist/ui.esm.js +1246 -1159
- package/dist/ui.min.css +1 -1
- package/dist/ui.scss +157 -50
- package/esm/components/QAccordion/QAccordion.d.ts +3 -3
- package/esm/components/QAccordion/QAccordion.d.ts.map +1 -1
- package/esm/components/QAccordion/QAccordion.vue.js +35 -30
- package/esm/components/QAccordion/QAccordionItem.d.ts +4 -1
- package/esm/components/QAccordion/QAccordionItem.d.ts.map +1 -1
- package/esm/components/QAccordion/QAccordionItem.vue.js +40 -6
- package/esm/components/QAccordion/index.d.ts +23 -11
- package/esm/components/QAccordion/index.d.ts.map +1 -1
- package/esm/components/QAccordion/types.d.ts +8 -0
- package/esm/components/QAccordion/types.d.ts.map +1 -1
- package/esm/components/QAlert/QAlert.d.ts +1 -1
- package/esm/components/QAlert/index.d.ts +3 -3
- package/esm/components/QAvatar/QAvatar.d.ts +1 -1
- package/esm/components/QAvatar/QAvatar.d.ts.map +1 -1
- package/esm/components/QAvatar/QAvatar.vue.js +19 -12
- package/esm/components/QAvatar/index.d.ts +3 -3
- package/esm/components/QAvatar/types.d.ts +2 -1
- package/esm/components/QAvatar/types.d.ts.map +1 -1
- package/esm/components/QBadge/QBadge.d.ts.map +1 -1
- package/esm/components/QBadge/QBadge.vue.js +36 -37
- package/esm/components/QBadgeIndicator/QBadgeIndicator.d.ts.map +1 -1
- package/esm/components/QBadgeIndicator/QBadgeIndicator.vue.js +23 -13
- package/esm/components/QBadgeIndicator/types.d.ts +13 -0
- package/esm/components/QBadgeIndicator/types.d.ts.map +1 -1
- package/esm/components/QBreadcrumbs/QBreadcrumbs.d.ts.map +1 -1
- package/esm/components/QBreadcrumbs/QBreadcrumbs.vue.js +31 -31
- package/esm/components/QButton/QButton.d.ts.map +1 -1
- package/esm/components/QButton/QButton.vue.js +54 -48
- package/esm/components/QButtonGroup/QButtonGroup.d.ts.map +1 -1
- package/esm/components/QButtonGroup/QButtonGroup.vue.js +18 -18
- package/esm/components/QCard/QCard.d.ts.map +1 -1
- package/esm/components/QCard/QCard.vue.js +48 -32
- package/esm/components/QCard/types.d.ts +9 -0
- package/esm/components/QCard/types.d.ts.map +1 -1
- package/esm/components/QCarousel/QCarousel.d.ts +2 -1
- package/esm/components/QCarousel/QCarousel.d.ts.map +1 -1
- package/esm/components/QCarousel/QCarousel.vue.js +120 -112
- package/esm/components/QCarousel/constants.d.ts +1 -0
- package/esm/components/QCarousel/constants.d.ts.map +1 -1
- package/esm/components/QCarousel/constants.js +2 -1
- package/esm/components/QCarousel/index.d.ts +9 -3
- package/esm/components/QCarousel/index.d.ts.map +1 -1
- package/esm/components/QCarousel/types.d.ts +9 -1
- package/esm/components/QCarousel/types.d.ts.map +1 -1
- package/esm/components/QCheckbox/QCheckbox.d.ts +0 -2
- package/esm/components/QCheckbox/QCheckbox.d.ts.map +1 -1
- package/esm/components/QCheckbox/QCheckbox.vue.js +41 -36
- package/esm/components/QCheckbox/index.d.ts +3 -1
- package/esm/components/QCheckbox/index.d.ts.map +1 -1
- package/esm/components/QCheckbox/types.d.ts +8 -0
- package/esm/components/QCheckbox/types.d.ts.map +1 -1
- package/esm/components/QCollapsible/QCollapsible.d.ts +1 -0
- package/esm/components/QCollapsible/QCollapsible.d.ts.map +1 -1
- package/esm/components/QCollapsible/QCollapsible.vue.js +55 -47
- package/esm/components/QCollapsible/index.d.ts +6 -0
- package/esm/components/QCollapsible/index.d.ts.map +1 -1
- package/esm/components/QCollapsible/types.d.ts +9 -0
- package/esm/components/QCollapsible/types.d.ts.map +1 -1
- package/esm/components/QColorPicker/QColorPicker.d.ts.map +1 -1
- package/esm/components/QColorPicker/QColorPicker.vue.js +5 -3
- package/esm/components/QColorPicker/index.d.ts +3 -0
- package/esm/components/QColorPicker/index.d.ts.map +1 -1
- package/esm/components/QColorPicker/types.d.ts +7 -0
- package/esm/components/QColorPicker/types.d.ts.map +1 -1
- package/esm/components/QCombobox/QCombobox.d.ts +16 -0
- package/esm/components/QCombobox/QCombobox.d.ts.map +1 -1
- package/esm/components/QCombobox/QCombobox.vue.js +264 -233
- package/esm/components/QCombobox/constants.d.ts +1 -0
- package/esm/components/QCombobox/constants.d.ts.map +1 -1
- package/esm/components/QCombobox/constants.js +1 -0
- package/esm/components/QCombobox/index.d.ts +21 -0
- package/esm/components/QCombobox/index.d.ts.map +1 -1
- package/esm/components/QCombobox/types.d.ts +8 -0
- package/esm/components/QCombobox/types.d.ts.map +1 -1
- package/esm/components/QDateTimePicker/QDateTimePicker.d.ts +180 -0
- package/esm/components/QDateTimePicker/QDateTimePicker.d.ts.map +1 -1
- package/esm/components/QDateTimePicker/QDateTimePicker.vue.js +636 -561
- package/esm/components/QDateTimePicker/index.d.ts +90 -0
- package/esm/components/QDateTimePicker/index.d.ts.map +1 -1
- package/esm/components/QDialog/QDialog.d.ts +1 -1
- package/esm/components/QDialog/QDialog.d.ts.map +1 -1
- package/esm/components/QDialog/QDialog.vue.js +6 -4
- package/esm/components/QDialog/QDialogProvider.d.ts.map +1 -1
- package/esm/components/QDialog/index.d.ts +6 -6
- package/esm/components/QDialog/types.d.ts +6 -4
- package/esm/components/QDialog/types.d.ts.map +1 -1
- package/esm/components/QDropdownMenu/QDropdownMenu.d.ts +3 -1
- package/esm/components/QDropdownMenu/QDropdownMenu.d.ts.map +1 -1
- package/esm/components/QDropdownMenu/QDropdownMenu.vue.js +84 -27
- package/esm/components/QDropdownMenu/QDropdownMenuContent.d.ts +17 -2
- package/esm/components/QDropdownMenu/QDropdownMenuContent.d.ts.map +1 -1
- package/esm/components/QDropdownMenu/QDropdownMenuContent.vue.js +218 -173
- package/esm/components/QDropdownMenu/ids.d.ts +8 -0
- package/esm/components/QDropdownMenu/ids.d.ts.map +1 -0
- package/esm/components/QDropdownMenu/ids.js +6 -0
- package/esm/components/QDropdownMenu/index.d.ts +9 -3
- package/esm/components/QDropdownMenu/index.d.ts.map +1 -1
- package/esm/components/QDropdownMenu/types.d.ts +3 -1
- package/esm/components/QDropdownMenu/types.d.ts.map +1 -1
- package/esm/components/QField/QField.d.ts +2 -0
- package/esm/components/QField/QField.d.ts.map +1 -1
- package/esm/components/QField/QField.vue.js +68 -61
- package/esm/components/QField/ids.d.ts +15 -0
- package/esm/components/QField/ids.d.ts.map +1 -0
- package/esm/components/QField/ids.js +10 -0
- package/esm/components/QField/index.d.ts +2 -0
- package/esm/components/QField/index.d.ts.map +1 -1
- package/esm/components/QFileUpload/QFileUpload.d.ts +355 -0
- package/esm/components/QFileUpload/QFileUpload.d.ts.map +1 -1
- package/esm/components/QFileUpload/QFileUpload.vue.js +137 -104
- package/esm/components/QFileUpload/constants.d.ts +2 -0
- package/esm/components/QFileUpload/constants.d.ts.map +1 -1
- package/esm/components/QFileUpload/constants.js +3 -1
- package/esm/components/QFileUpload/index.d.ts +182 -0
- package/esm/components/QFileUpload/index.d.ts.map +1 -1
- package/esm/components/QFocusWrap/QFocusWrap.d.ts.map +1 -1
- package/esm/components/QIcon/QIconFont.vue.js +2 -1
- package/esm/components/QIcon/QIconImg.d.ts.map +1 -1
- package/esm/components/QIcon/QIconImg.vue.js +1 -0
- package/esm/components/QIcon/QIconSvg.d.ts.map +1 -1
- package/esm/components/QIcon/QSvgSymbol.d.ts.map +1 -1
- package/esm/components/QIcon/QSvgSymbol.vue.js +31 -31
- package/esm/components/QInputGroup/QInputGroup.d.ts +5 -0
- package/esm/components/QInputGroup/QInputGroup.d.ts.map +1 -1
- package/esm/components/QInputGroup/QInputGroup.vue.js +74 -41
- package/esm/components/QInputGroup/index.d.ts +3 -0
- package/esm/components/QInputGroup/index.d.ts.map +1 -1
- package/esm/components/QInputGroup/types.d.ts +15 -1
- package/esm/components/QInputGroup/types.d.ts.map +1 -1
- package/esm/components/QLabel/QLabel.d.ts.map +1 -1
- package/esm/components/QLabel/QLabel.vue.js +21 -19
- package/esm/components/QLabel/ids.d.ts +9 -0
- package/esm/components/QLabel/ids.d.ts.map +1 -0
- package/esm/components/QLabel/ids.js +6 -0
- package/esm/components/QLineLoader/QLineLoader.d.ts.map +1 -1
- package/esm/components/QLineLoader/QLineLoader.vue.js +15 -14
- package/esm/components/QList/QList.d.ts +9 -3
- package/esm/components/QList/QList.d.ts.map +1 -1
- package/esm/components/QList/QList.vue.js +137 -116
- package/esm/components/QList/QListItem.d.ts +6 -2
- package/esm/components/QList/QListItem.d.ts.map +1 -1
- package/esm/components/QList/QListItem.vue.js +61 -44
- package/esm/components/QList/context.d.ts +8 -0
- package/esm/components/QList/context.d.ts.map +1 -0
- package/esm/components/QList/context.js +4 -0
- package/esm/components/QList/index.d.ts +6 -1
- package/esm/components/QList/index.d.ts.map +1 -1
- package/esm/components/QList/types.d.ts +16 -0
- package/esm/components/QList/types.d.ts.map +1 -1
- package/esm/components/QMeter/QMeter.d.ts.map +1 -1
- package/esm/components/QMeter/QMeter.vue.js +38 -19
- package/esm/components/QMeter/index.d.ts +2 -10
- package/esm/components/QMeter/index.d.ts.map +1 -1
- package/esm/components/QMeter/types.d.ts +9 -1
- package/esm/components/QMeter/types.d.ts.map +1 -1
- package/esm/components/QObfuscation/QObfuscation.d.ts.map +1 -1
- package/esm/components/QObfuscation/QObfuscation.vue.js +42 -26
- package/esm/components/QObfuscation/index.d.ts.map +1 -1
- package/esm/components/QOverflow/QOverflow.d.ts +6 -1
- package/esm/components/QOverflow/QOverflow.d.ts.map +1 -1
- package/esm/components/QOverflow/QOverflow.vue.js +142 -126
- package/esm/components/QOverflow/index.d.ts +3 -3
- package/esm/components/QOverlay/QOverlay.d.ts.map +1 -1
- package/esm/components/QOverlay/QOverlay.vue.js +193 -155
- package/esm/components/QOverlay/types.d.ts +9 -2
- package/esm/components/QOverlay/types.d.ts.map +1 -1
- package/esm/components/QPasswordField/QPasswordField.d.ts +5 -0
- package/esm/components/QPasswordField/QPasswordField.d.ts.map +1 -1
- package/esm/components/QPasswordField/QPasswordField.vue.js +75 -64
- package/esm/components/QPasswordField/QPasswordFieldMeterOverlay.d.ts.map +1 -1
- package/esm/components/QPasswordField/QPasswordFieldMeterOverlay.vue.js +5 -2
- package/esm/components/QPasswordField/index.d.ts +8 -0
- package/esm/components/QPasswordField/index.d.ts.map +1 -1
- package/esm/components/QPasswordField/types.d.ts +14 -0
- package/esm/components/QPasswordField/types.d.ts.map +1 -1
- package/esm/components/QPhoneField/QPhoneField.d.ts +218 -21
- package/esm/components/QPhoneField/QPhoneField.d.ts.map +1 -1
- package/esm/components/QPhoneField/QPhoneField.vue.js +98 -102
- package/esm/components/QPhoneField/constants.d.ts +2 -1
- package/esm/components/QPhoneField/constants.d.ts.map +1 -1
- package/esm/components/QPhoneField/constants.js +1 -1
- package/esm/components/QPhoneField/index.d.ts +118 -17
- package/esm/components/QPhoneField/index.d.ts.map +1 -1
- package/esm/components/QPhoneField/types.d.ts +5 -2
- package/esm/components/QPhoneField/types.d.ts.map +1 -1
- package/esm/components/QPopover/QPopover.d.ts +1 -1
- package/esm/components/QPopover/index.d.ts +3 -3
- package/esm/components/QProgress/QProgress.d.ts.map +1 -1
- package/esm/components/QProgress/QProgress.vue.js +1 -1
- package/esm/components/QPropertyList/QPropertyList.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyList.vue.js +63 -61
- package/esm/components/QPropertyList/QPropertyListRow.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyListRow.vue.js +2 -2
- package/esm/components/QPropertyList/index.d.ts.map +1 -1
- package/esm/components/QRadioGroup/QRadioButton.d.ts.map +1 -1
- package/esm/components/QRadioGroup/QRadioButton.vue.js +2 -2
- package/esm/components/QRadioGroup/QRadioGroup.d.ts.map +1 -1
- package/esm/components/QRadioGroup/QRadioGroup.vue.js +58 -46
- package/esm/components/QRemoveScrollBar/QRemoveScrollBar.d.ts.map +1 -1
- package/esm/components/QRemoveScrollBar/QRemoveScrollBar.vue.js +7 -7
- package/esm/components/QRemoveScrollBar/utils/gap.d.ts +0 -6
- package/esm/components/QRemoveScrollBar/utils/gap.d.ts.map +1 -1
- package/esm/components/QRemoveScrollBar/utils/gap.js +12 -18
- package/esm/components/QRemoveScrollBar/utils/stylesheet.d.ts +11 -0
- package/esm/components/QRemoveScrollBar/utils/stylesheet.d.ts.map +1 -1
- package/esm/components/QRemoveScrollBar/utils/stylesheet.js +5 -5
- package/esm/components/QSection/QSection.d.ts.map +1 -1
- package/esm/components/QSection/QSection.vue.js +3 -2
- package/esm/components/QSection/types.d.ts +3 -4
- package/esm/components/QSection/types.d.ts.map +1 -1
- package/esm/components/QSelect/QSelect.d.ts +163 -0
- package/esm/components/QSelect/QSelect.d.ts.map +1 -1
- package/esm/components/QSelect/QSelect.vue.js +422 -344
- package/esm/components/QSelect/constants.d.ts +2 -0
- package/esm/components/QSelect/constants.d.ts.map +1 -1
- package/esm/components/QSelect/constants.js +3 -1
- package/esm/components/QSelect/index.d.ts +92 -0
- package/esm/components/QSelect/index.d.ts.map +1 -1
- package/esm/components/QSelect/types.d.ts +8 -0
- package/esm/components/QSelect/types.d.ts.map +1 -1
- package/esm/components/QSidebar/QSidebar.d.ts.map +1 -1
- package/esm/components/QSidebar/QSidebar.vue.js +1 -2
- package/esm/components/QSidebar/QSidebarAnchor.vue.js +1 -1
- package/esm/components/QSidebar/QSidebarItem.d.ts +1 -0
- package/esm/components/QSidebar/QSidebarItem.d.ts.map +1 -1
- package/esm/components/QSidebar/QSidebarItem.vue.js +4 -1
- package/esm/components/QSidebar/QSidebarPanel.d.ts.map +1 -1
- package/esm/components/QSidebar/QSidebarPanel.vue.js +93 -32
- package/esm/components/QSidebar/context.d.ts +3 -3
- package/esm/components/QSidebar/context.d.ts.map +1 -1
- package/esm/components/QSidebar/index.d.ts +3 -0
- package/esm/components/QSidebar/index.d.ts.map +1 -1
- package/esm/components/QSidebar/types.d.ts +20 -1
- package/esm/components/QSidebar/types.d.ts.map +1 -1
- package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts.map +1 -1
- package/esm/components/QSkeletonLoader/QSkeletonLoader.vue.js +16 -15
- package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts.map +1 -1
- package/esm/components/QSpinnerLoader/QSpinnerLoader.vue.js +11 -10
- package/esm/components/QSteps/QSteps.d.ts +7 -6
- package/esm/components/QSteps/QSteps.d.ts.map +1 -1
- package/esm/components/QSteps/QSteps.vue.js +175 -162
- package/esm/components/QSteps/QStepsNav.d.ts +7 -0
- package/esm/components/QSteps/QStepsNav.d.ts.map +1 -1
- package/esm/components/QSteps/QStepsNav.vue.js +29 -15
- package/esm/components/QSteps/constants.d.ts +4 -2
- package/esm/components/QSteps/constants.d.ts.map +1 -1
- package/esm/components/QSteps/constants.js +2 -0
- package/esm/components/QSteps/index.d.ts +2 -2
- package/esm/components/QSteps/types.d.ts +2 -1
- package/esm/components/QSteps/types.d.ts.map +1 -1
- package/esm/components/QSwitch/QSwitch.d.ts +2 -0
- package/esm/components/QSwitch/QSwitch.d.ts.map +1 -1
- package/esm/components/QSwitch/QSwitch.vue.js +12 -2
- package/esm/components/QSwitch/index.d.ts +4 -0
- package/esm/components/QSwitch/index.d.ts.map +1 -1
- package/esm/components/QSwitch/types.d.ts +8 -0
- package/esm/components/QSwitch/types.d.ts.map +1 -1
- package/esm/components/QTabs/QTab.d.ts.map +1 -1
- package/esm/components/QTabs/QTab.vue.js +3 -2
- package/esm/components/QTabs/QTabs.d.ts +4 -4
- package/esm/components/QTabs/QTabs.d.ts.map +1 -1
- package/esm/components/QTabs/QTabs.vue.js +86 -85
- package/esm/components/QTabs/context.d.ts +3 -3
- package/esm/components/QTabs/context.d.ts.map +1 -1
- package/esm/components/QTabs/index.d.ts +2 -2
- package/esm/components/QTextArea/QTextArea.d.ts +1 -1
- package/esm/components/QTextArea/QTextArea.d.ts.map +1 -1
- package/esm/components/QTextArea/QTextArea.vue.js +30 -25
- package/esm/components/QTextArea/index.d.ts +3 -3
- package/esm/components/QTextField/QTextField.d.ts +4 -0
- package/esm/components/QTextField/QTextField.d.ts.map +1 -1
- package/esm/components/QTextField/QTextField.vue.js +5 -3
- package/esm/components/QTextField/index.d.ts +2 -0
- package/esm/components/QTextField/index.d.ts.map +1 -1
- package/esm/components/QThemeProvider/QThemeProvider.d.ts.map +1 -1
- package/esm/components/QToast/QToast.d.ts +1 -0
- package/esm/components/QToast/QToast.d.ts.map +1 -1
- package/esm/components/QToast/QToast.vue.js +92 -85
- package/esm/components/QToast/QToaster.d.ts.map +1 -1
- package/esm/components/QToast/index.d.ts +6 -0
- package/esm/components/QToast/index.d.ts.map +1 -1
- package/esm/components/QToast/types.d.ts +11 -3
- package/esm/components/QToast/types.d.ts.map +1 -1
- package/esm/components/QToggleGroup/QToggleGroup.d.ts +3 -3
- package/esm/components/QToggleGroup/QToggleGroup.d.ts.map +1 -1
- package/esm/components/QToggleGroup/QToggleGroup.vue.js +34 -31
- package/esm/components/QToggleGroup/index.d.ts +8 -8
- package/esm/components/QTooltip/QTooltip.d.ts.map +1 -1
- package/esm/components/QTooltip/QTooltip.vue.js +19 -11
- package/esm/components/__internal__/QClearButton/QClearButton.d.ts.map +1 -1
- package/esm/components/__internal__/QHelpPopover/QHelpPopover.d.ts.map +1 -1
- package/esm/composables/defaults.d.ts +10 -0
- package/esm/composables/defaults.d.ts.map +1 -1
- package/esm/composables/defaults.js +8 -5
- package/esm/composables/useDialog/_internal.js +8 -11
- package/esm/composables/useDialog/index.js +1 -2
- package/esm/composables/useDialog/types.d.ts.map +1 -1
- package/esm/composables/useDropZone/index.d.ts +1 -11
- package/esm/composables/useDropZone/index.d.ts.map +1 -1
- package/esm/composables/useDropZone/index.js +23 -26
- package/esm/composables/useGroup/index.d.ts.map +1 -1
- package/esm/composables/useGroup/index.js +15 -15
- package/esm/composables/useOverlayScope/index.d.ts +29 -0
- package/esm/composables/useOverlayScope/index.d.ts.map +1 -0
- package/esm/composables/useOverlayScope/index.js +23 -0
- package/esm/composables/useTextareaAutosize/index.d.ts +3 -1
- package/esm/composables/useTextareaAutosize/index.d.ts.map +1 -1
- package/esm/composables/useTextareaAutosize/index.js +6 -6
- package/esm/composables/useToast/_internal.js +10 -15
- package/esm/composables/useToast/index.js +1 -2
- package/esm/composables/useToast/types.d.ts.map +1 -1
- package/esm/framework.js +14 -12
- package/esm/index.d.ts +1 -2
- package/esm/index.d.ts.map +1 -1
- package/esm/symbols/overlayScope.d.ts +4 -0
- package/esm/symbols/overlayScope.d.ts.map +1 -0
- package/esm/symbols/overlayScope.js +4 -0
- package/esm/types/component.d.ts +8 -0
- package/esm/types/component.d.ts.map +1 -1
- package/esm/types/index.d.ts +1 -1
- package/esm/types/index.d.ts.map +1 -1
- package/esm/utils/color/parse.d.ts.map +1 -1
- package/esm/utils/color/parse.js +3 -10
- package/esm/utils/date.d.ts +35 -13
- package/esm/utils/date.d.ts.map +1 -1
- package/esm/utils/date.js +313 -253
- package/esm/utils/focus.d.ts +10 -0
- package/esm/utils/focus.d.ts.map +1 -1
- package/esm/utils/focus.js +5 -2
- package/esm/utils/loader.d.ts +19 -0
- package/esm/utils/loader.d.ts.map +1 -0
- package/esm/utils/loader.js +6 -0
- package/esm/utils/mask.d.ts +1 -0
- package/esm/utils/mask.d.ts.map +1 -1
- package/esm/utils/mask.js +42 -100
- package/esm/utils/overlay.d.ts +13 -1
- package/esm/utils/overlay.d.ts.map +1 -1
- package/esm/utils/overlay.js +55 -41
- package/esm/utils/safeTriangle.d.ts.map +1 -1
- package/esm/utils/safeTriangle.js +2 -2
- package/esm/utils/setupPropsProxy.d.ts +3 -1
- package/esm/utils/setupPropsProxy.d.ts.map +1 -1
- package/esm/utils/setupPropsProxy.js +2 -2
- package/package.json +28 -24
- package/dist/ui.js +0 -1859
- package/dist/ui.min.js +0 -1859
|
@@ -1,25 +1,29 @@
|
|
|
1
1
|
import { useId as e } from "../../composables/useId/index.js";
|
|
2
2
|
import { QIcon as t } from "../QIcon/index.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
3
|
+
import { getNextTabbable as n, getTabbableElements as r } from "../../utils/focus.js";
|
|
4
|
+
import { QOverlay as i } from "../QOverlay/index.js";
|
|
5
|
+
import { QButton as a } from "../QButton/index.js";
|
|
6
|
+
import { QTextField as o } from "../QTextField/index.js";
|
|
7
|
+
import { DEFAULT_ICONS as s, DEFAULT_TEXTS as ee, MONTH_NAMES as te, WEEKDAY_NAMES as ne } from "./constants.js";
|
|
8
|
+
import { QSwitch as re } from "../QSwitch/index.js";
|
|
9
|
+
import { addDays as c, clampNumericSegments as ie, convertDatePatternToMask as ae, formatDate as oe, formatUsesSeconds as se, formatUsesTime as ce, getDaysInMonth as le, getFirstDayOfMonth as ue, inputIncludesTimePortion as de, isBetween as fe, isSameDay as pe, isTimeOnlyFormat as me, padNumber as he, parseDate as ge, parseDateWithCompletion as _e, parseIsoDate as ve, uses12HourFormat as ye } from "../../utils/date.js";
|
|
10
|
+
import { applyMask as be } from "../../utils/mask.js";
|
|
11
|
+
import { Fragment as l, computed as u, createBlock as d, createCommentVNode as f, createElementBlock as p, createElementVNode as m, createSlots as xe, createVNode as h, defineComponent as g, guardReactiveProps as _, mergeModels as Se, mergeProps as v, nextTick as y, normalizeClass as Ce, normalizeProps as b, onBeforeUnmount as we, openBlock as x, ref as S, renderList as Te, renderSlot as Ee, toDisplayString as De, toRef as Oe, unref as C, useModel as ke, useTemplateRef as w, watch as T, withCtx as E } from "vue";
|
|
11
12
|
//#region src/components/QDateTimePicker/QDateTimePicker.vue?vue&type=script&setup=true&lang.ts
|
|
12
|
-
var
|
|
13
|
+
var Ae = {
|
|
13
14
|
key: 0,
|
|
14
15
|
ref: "calendar",
|
|
15
16
|
class: "q-date-time-picker__calendar"
|
|
16
|
-
},
|
|
17
|
+
}, je = { class: "q-date-time-picker__header" }, Me = ["aria-label"], Ne = {
|
|
18
|
+
role: "row",
|
|
19
|
+
class: "q-date-time-picker__weekdays"
|
|
20
|
+
}, Pe = ["aria-label"], Fe = { class: "q-date-time-picker__time" }, Ie = ["role", "aria-label"], Le = {
|
|
17
21
|
key: 0,
|
|
18
22
|
class: "q-date-time-picker__time-period"
|
|
19
|
-
},
|
|
23
|
+
}, Re = { class: "q-date-time-picker__time-inputs" }, ze = { class: "q-date-time-picker__time-input-group" }, Be = { class: "q-date-time-picker__time-input-group" }, Ve = { class: "q-date-time-picker__time-input-group" }, He = { class: "q-date-time-picker__month-grid" }, Ue = { class: "q-date-time-picker__year" }, We = { class: "q-date-time-picker__year-change" }, Ge = { class: "q-date-time-picker__year-interval" }, Ke = { class: "q-date-time-picker__year-grid" }, qe = { class: "q-date-time-picker__bottom-bar" }, D = 1001, O = 9999, k = 26, Je = /*@__PURE__*/ g({
|
|
20
24
|
inheritAttrs: !1,
|
|
21
25
|
__name: "QDateTimePicker",
|
|
22
|
-
props: /*@__PURE__*/
|
|
26
|
+
props: /*@__PURE__*/ Se({
|
|
23
27
|
id: {},
|
|
24
28
|
class: {},
|
|
25
29
|
label: {},
|
|
@@ -28,8 +32,8 @@ var Oe = {
|
|
|
28
32
|
labelPosition: {},
|
|
29
33
|
help: {},
|
|
30
34
|
helpDisplay: {},
|
|
31
|
-
icons: { default: () =>
|
|
32
|
-
texts: { default: () =>
|
|
35
|
+
icons: { default: () => s },
|
|
36
|
+
texts: { default: () => ee },
|
|
33
37
|
size: {},
|
|
34
38
|
readonly: { type: Boolean },
|
|
35
39
|
disabled: { type: Boolean },
|
|
@@ -46,22 +50,22 @@ var Oe = {
|
|
|
46
50
|
modelValue: {},
|
|
47
51
|
modelModifiers: {}
|
|
48
52
|
}),
|
|
49
|
-
emits: /*@__PURE__*/
|
|
50
|
-
setup(
|
|
51
|
-
let
|
|
52
|
-
get: () =>
|
|
53
|
-
set: (e) =>
|
|
54
|
-
}),
|
|
55
|
-
function
|
|
53
|
+
emits: /*@__PURE__*/ Se(["open", "close"], ["update:modelValue"]),
|
|
54
|
+
setup(s, { emit: ee }) {
|
|
55
|
+
let g = s, Se = ee, Je = { ignoreWeekday: !0 }, Ye = e(Oe(g, "id")), Xe = ke(s, "modelValue"), A = u({
|
|
56
|
+
get: () => Xe.value,
|
|
57
|
+
set: (e) => Xe.value = e || void 0
|
|
58
|
+
}), Ze = u(() => g.readonly || g.disabled ? void 0 : g.placeholder), j = u(() => ce(g.format)), Qe = u(() => se(g.format)), M = u(() => ye(g.format)), N = u(() => me(g.format)), $e = u(() => R.value === (/* @__PURE__ */ new Date()).getMonth() && z.value === (/* @__PURE__ */ new Date()).getFullYear()), P = S(!1), et = S(!1), F = S(""), I = S(null), L = S("date"), R = S((/* @__PURE__ */ new Date()).getMonth()), z = S((/* @__PURE__ */ new Date()).getFullYear()), B = S((/* @__PURE__ */ new Date()).getFullYear()), tt = null, V = !1, nt = !1, rt = !1, H = null;
|
|
59
|
+
function it() {
|
|
56
60
|
queueMicrotask(() => {
|
|
57
61
|
requestAnimationFrame(() => {
|
|
58
|
-
let e =
|
|
59
|
-
e && (t === e || t instanceof Node && U.value?.contains(t)) && (
|
|
62
|
+
let e = cr(), t = document.activeElement;
|
|
63
|
+
e && (t === e || t instanceof Node && U.value?.contains(t)) && (V = !0);
|
|
60
64
|
});
|
|
61
65
|
});
|
|
62
66
|
}
|
|
63
|
-
let
|
|
64
|
-
function
|
|
67
|
+
let at = w("field"), U = w("menu"), ot = w("calendar"), st = w("monthHeader"), ct = w("yearHeader"), lt = w("toggleTime"), ut = w("toggleDate"), dt = /* @__PURE__ */ new Map(), ft = /* @__PURE__ */ new Map();
|
|
68
|
+
function pt(e) {
|
|
65
69
|
if (!e) return null;
|
|
66
70
|
if (e instanceof HTMLElement) return e;
|
|
67
71
|
if (typeof e == "object" && "$el" in e) {
|
|
@@ -70,361 +74,397 @@ var Oe = {
|
|
|
70
74
|
}
|
|
71
75
|
return null;
|
|
72
76
|
}
|
|
73
|
-
function
|
|
74
|
-
let n =
|
|
75
|
-
n ?
|
|
77
|
+
function mt(e, t) {
|
|
78
|
+
let n = pt(e);
|
|
79
|
+
n ? dt.set(t, n) : dt.delete(t);
|
|
76
80
|
}
|
|
77
|
-
function
|
|
78
|
-
let n =
|
|
79
|
-
n ?
|
|
81
|
+
function ht(e, t) {
|
|
82
|
+
let n = pt(e);
|
|
83
|
+
n ? ft.set(t, n) : ft.delete(t);
|
|
80
84
|
}
|
|
81
|
-
function
|
|
82
|
-
|
|
85
|
+
function gt(e) {
|
|
86
|
+
pt(e)?.focus();
|
|
83
87
|
}
|
|
84
|
-
let
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
return (t ? r.substring(0, 3) : r).toLowerCase() === n;
|
|
90
|
-
});
|
|
91
|
-
},
|
|
92
|
-
getWeekdayIndex: (e, t) => {
|
|
93
|
-
let n = e.toLowerCase();
|
|
94
|
-
for (let e = 0; e < 7; e++) {
|
|
95
|
-
let r = ee[(e + 6) % 7], i = h.texts[r] ?? r;
|
|
96
|
-
if ((t ? i.substring(0, 3) : i).toLowerCase() === n) return e;
|
|
97
|
-
}
|
|
98
|
-
return null;
|
|
99
|
-
}
|
|
100
|
-
})), W = l(() => {
|
|
101
|
-
let e = k.value;
|
|
102
|
-
return e ? e instanceof Date ? e : Array.isArray(e) && e.length > 0 ? e[0] : typeof e == "string" ? wn(e) : null : null;
|
|
103
|
-
}), ft = l(() => {
|
|
104
|
-
let e = k.value;
|
|
88
|
+
let W = u(() => {
|
|
89
|
+
let e = A.value;
|
|
90
|
+
return e ? e instanceof Date ? e : Array.isArray(e) && e.length > 0 ? e[0] : typeof e == "string" ? Bn(e) : null : null;
|
|
91
|
+
}), _t = u(() => {
|
|
92
|
+
let e = A.value;
|
|
105
93
|
return Array.isArray(e) && e.length > 1 ? e[1] : null;
|
|
106
|
-
}), G =
|
|
107
|
-
if (!
|
|
108
|
-
if (!J.value || !G.value) return
|
|
94
|
+
}), G = S(null), K = S(null), q = S(null), J = S(!1), vt = u(() => !J.value || !G.value ? W.value : q.value && q.value < G.value ? q.value : G.value), yt = u(() => {
|
|
95
|
+
if (!g.range) return W.value;
|
|
96
|
+
if (!J.value || !G.value) return _t.value;
|
|
109
97
|
let e = q.value ?? K.value;
|
|
110
98
|
return e ? e < G.value ? G.value : e : null;
|
|
111
|
-
}),
|
|
99
|
+
}), bt = u(() => ({
|
|
112
100
|
getMonthName: (e, t) => {
|
|
113
|
-
let n =
|
|
101
|
+
let n = Rt(e);
|
|
114
102
|
return t ? n.substring(0, 3) : n;
|
|
115
103
|
},
|
|
116
104
|
getWeekdayName: (e, t) => {
|
|
117
|
-
let n =
|
|
105
|
+
let n = ne[(e + 6) % 7], r = g.texts[n] ?? n;
|
|
118
106
|
return t ? r.substring(0, 3) : r;
|
|
119
107
|
}
|
|
120
|
-
})),
|
|
121
|
-
let e =
|
|
108
|
+
})), xt = u(() => bt.value), St = u(() => {
|
|
109
|
+
let e = A.value;
|
|
122
110
|
if (!e) return "";
|
|
123
|
-
if (Array.isArray(e)) return e.map((e) => e instanceof Date ?
|
|
124
|
-
if (e instanceof Date) return
|
|
111
|
+
if (Array.isArray(e)) return e.map((e) => e instanceof Date ? oe(e, g.format, bt.value) : e).join(" - ");
|
|
112
|
+
if (e instanceof Date) return oe(e, g.format, bt.value);
|
|
125
113
|
if (typeof e == "string") {
|
|
126
|
-
let t =
|
|
127
|
-
return t ?
|
|
114
|
+
let t = Bn(e);
|
|
115
|
+
return t ? oe(t, g.format, bt.value) : String(e);
|
|
128
116
|
}
|
|
129
117
|
return String(e);
|
|
130
|
-
}),
|
|
131
|
-
function
|
|
132
|
-
|
|
118
|
+
}), Ct = u(() => I.value ?? St.value);
|
|
119
|
+
function wt() {
|
|
120
|
+
F.value = Ct.value;
|
|
133
121
|
}
|
|
134
|
-
|
|
135
|
-
|
|
122
|
+
T(Ct, () => {
|
|
123
|
+
et.value || wt();
|
|
136
124
|
}, { immediate: !0 });
|
|
137
|
-
let
|
|
138
|
-
let e =
|
|
139
|
-
for (let e = n - 1; e >= 0; e--)
|
|
140
|
-
for (let e = 1; e <= t; e++)
|
|
125
|
+
let Tt = u(() => {
|
|
126
|
+
let e = ue(new Date(z.value, R.value, 1)), t = le(R.value, z.value), n = (e.getDay() + 6) % 7, r = [], i = R.value === 0 ? 11 : R.value - 1, a = R.value === 0 ? z.value - 1 : z.value, o = le(i, a);
|
|
127
|
+
for (let e = n - 1; e >= 0; e--) Et(r, new Date(a, i, o - e), !1);
|
|
128
|
+
for (let e = 1; e <= t; e++) Et(r, new Date(z.value, R.value, e), !0);
|
|
141
129
|
let s = 7 - r.length % 7, ee = s === 7 ? 0 : s;
|
|
142
|
-
for (let e = 1; e <= ee; e++)
|
|
130
|
+
for (let e = 1; e <= ee; e++) Et(r, new Date(z.value, R.value + 1, e), !1);
|
|
143
131
|
return r;
|
|
144
132
|
});
|
|
145
|
-
function
|
|
146
|
-
let r =
|
|
133
|
+
function Et(e, t, n) {
|
|
134
|
+
let r = vt.value, i = yt.value, a = t.getFullYear(), o = a < D || a > O;
|
|
147
135
|
e.push({
|
|
148
136
|
date: t,
|
|
149
137
|
isCurrentMonth: n,
|
|
150
|
-
isToday:
|
|
151
|
-
isSelected: r ?
|
|
152
|
-
isRangeStart: !!r &&
|
|
153
|
-
isRangeEnd: !!i &&
|
|
154
|
-
isInRange: r && i ?
|
|
138
|
+
isToday: pe(t, /* @__PURE__ */ new Date()),
|
|
139
|
+
isSelected: r ? pe(t, r) : !1,
|
|
140
|
+
isRangeStart: !!r && pe(t, r),
|
|
141
|
+
isRangeEnd: !!i && pe(t, i),
|
|
142
|
+
isInRange: r && i ? fe(t, r, i) : !1,
|
|
155
143
|
isDisabled: o
|
|
156
144
|
});
|
|
157
145
|
}
|
|
158
|
-
let
|
|
146
|
+
let Dt = u(() => ne.map((e) => {
|
|
159
147
|
let t = e;
|
|
160
|
-
return
|
|
161
|
-
})),
|
|
162
|
-
|
|
163
|
-
|
|
148
|
+
return g.texts[t]?.substring(0, 2) ?? e;
|
|
149
|
+
})), Ot = u(() => {
|
|
150
|
+
let e = [];
|
|
151
|
+
return Tt.value.forEach((t, n) => {
|
|
152
|
+
n % 7 == 0 && e.push([]), e[e.length - 1].push({
|
|
153
|
+
day: t,
|
|
154
|
+
index: n
|
|
155
|
+
});
|
|
156
|
+
}), e;
|
|
157
|
+
});
|
|
158
|
+
function kt(e) {
|
|
159
|
+
let t = ne[e];
|
|
160
|
+
return g.texts[t] ?? t;
|
|
161
|
+
}
|
|
162
|
+
let At = u(() => `${Rt(R.value)} ${z.value}`);
|
|
163
|
+
function jt(e) {
|
|
164
|
+
return `${kt((e.getDay() + 6) % 7)}, ${e.getDate()} ${Rt(e.getMonth())} ${e.getFullYear()}`;
|
|
165
|
+
}
|
|
166
|
+
let Mt = S(null), Nt = u(() => {
|
|
167
|
+
let e = Tt.value;
|
|
168
|
+
for (let t of [
|
|
169
|
+
Mt.value,
|
|
170
|
+
vt.value,
|
|
171
|
+
/* @__PURE__ */ new Date()
|
|
172
|
+
]) {
|
|
173
|
+
if (!t) continue;
|
|
174
|
+
let n = e.findIndex((e) => e.isCurrentMonth && !e.isDisabled && pe(e.date, t));
|
|
175
|
+
if (n >= 0) return n;
|
|
176
|
+
}
|
|
177
|
+
return e.findIndex((e) => e.isCurrentMonth && !e.isDisabled);
|
|
178
|
+
});
|
|
179
|
+
function Pt(e, t) {
|
|
180
|
+
let n = new Date(e.getFullYear(), e.getMonth() + t, 1), r = le(n.getMonth(), n.getFullYear());
|
|
181
|
+
return new Date(n.getFullYear(), n.getMonth(), Math.min(e.getDate(), r));
|
|
182
|
+
}
|
|
183
|
+
function Ft(e) {
|
|
184
|
+
if (e.ctrlKey || e.altKey || e.metaKey) return;
|
|
185
|
+
let t = e.target.closest("[data-day-index]"), n = Tt.value[Number(t?.getAttribute("data-day-index"))];
|
|
186
|
+
if (!n) return;
|
|
187
|
+
let { date: r } = n, i = (r.getDay() + 6) % 7, a = e.shiftKey ? 12 : 1, o = {
|
|
188
|
+
ArrowLeft: () => c(r, -1),
|
|
189
|
+
ArrowRight: () => c(r, 1),
|
|
190
|
+
ArrowUp: () => c(r, -7),
|
|
191
|
+
ArrowDown: () => c(r, 7),
|
|
192
|
+
Home: () => c(r, -i),
|
|
193
|
+
End: () => c(r, 6 - i),
|
|
194
|
+
PageUp: () => Pt(r, -a),
|
|
195
|
+
PageDown: () => Pt(r, a)
|
|
196
|
+
}[e.key];
|
|
197
|
+
o && (e.preventDefault(), It(o()));
|
|
198
|
+
}
|
|
199
|
+
async function It(e) {
|
|
200
|
+
let t = e.getFullYear();
|
|
201
|
+
t < D || t > O || (Mt.value = e, (e.getMonth() !== R.value || t !== z.value) && (X(e.getMonth()), Y(t)), await y(), U.value?.querySelector(`[data-day-index="${Nt.value}"]`)?.focus());
|
|
202
|
+
}
|
|
203
|
+
let Lt = u(() => Array.from({ length: 12 }, (e, t) => Rt(t, 3)));
|
|
204
|
+
function Rt(e, t = 0) {
|
|
205
|
+
let n = te[e], r = g.texts[n] ?? te[e];
|
|
164
206
|
return t <= 0 ? r : r.substring(0, t);
|
|
165
207
|
}
|
|
166
|
-
function
|
|
167
|
-
let t = e - Math.floor(
|
|
168
|
-
return t <
|
|
208
|
+
function zt(e) {
|
|
209
|
+
let t = e - Math.floor(k / 2), n = t + k;
|
|
210
|
+
return t < D && (t = D, n = Math.min(t + k, O)), n > O && (n = O, t = Math.max(D, n - k)), {
|
|
169
211
|
startYear: t,
|
|
170
212
|
endYear: n
|
|
171
213
|
};
|
|
172
214
|
}
|
|
173
|
-
function
|
|
174
|
-
let { startYear: t, endYear: n } =
|
|
215
|
+
function Bt(e) {
|
|
216
|
+
let { startYear: t, endYear: n } = zt(e);
|
|
175
217
|
return Array.from({ length: n - t + 1 }, (e, n) => t + n);
|
|
176
218
|
}
|
|
177
|
-
function
|
|
178
|
-
|
|
219
|
+
function Vt() {
|
|
220
|
+
B.value -= k;
|
|
179
221
|
}
|
|
180
|
-
function
|
|
181
|
-
|
|
222
|
+
function Ht() {
|
|
223
|
+
B.value += k;
|
|
182
224
|
}
|
|
183
|
-
let
|
|
184
|
-
|
|
185
|
-
let r =
|
|
186
|
-
H = r, r && (r.addEventListener("click",
|
|
187
|
-
H = null, r.removeEventListener("click",
|
|
225
|
+
let Ut = u(() => zt(B.value)), Wt = u(() => Ut.value.startYear > D), Gt = u(() => Ut.value.endYear < O), Kt = u(() => R.value === 0 ? z.value - 1 : z.value), qt = u(() => R.value === 11 ? z.value + 1 : z.value), Jt = u(() => Kt.value >= D), Yt = u(() => qt.value <= O), Xt = u(() => Bt(B.value)), Zt = u(() => N.value ? g.icons.clock : g.icons.calendar), Qt = u(() => `${g.format} - ${g.format}`), $t = u(() => ae(g.format)), en = u(() => `${$t.value} - ${$t.value}`);
|
|
226
|
+
T(() => at?.value?.inputRef, (e, t, n) => {
|
|
227
|
+
let r = sr(e);
|
|
228
|
+
H = r, r && (r.addEventListener("click", ir), n(() => {
|
|
229
|
+
H = null, r.removeEventListener("click", ir);
|
|
188
230
|
}));
|
|
189
|
-
}, { flush: "post" }),
|
|
190
|
-
|
|
231
|
+
}, { flush: "post" }), T(A, () => {
|
|
232
|
+
I.value = null, wt();
|
|
191
233
|
});
|
|
192
|
-
function
|
|
234
|
+
function tn(e) {
|
|
193
235
|
return e === void 0 ? !1 : typeof e == "string" ? e.trim().length > 0 : e instanceof Date ? !0 : Array.isArray(e) ? e.length > 0 : !1;
|
|
194
236
|
}
|
|
195
|
-
let
|
|
196
|
-
function
|
|
197
|
-
|
|
237
|
+
let nn = u(() => g.clearable && !g.readonly && !g.disabled && tn(A.value));
|
|
238
|
+
function rn() {
|
|
239
|
+
nn.value && (_n(), A.value = void 0, F.value = "", Sr());
|
|
198
240
|
}
|
|
199
|
-
function
|
|
200
|
-
!
|
|
241
|
+
function an(e) {
|
|
242
|
+
!g.range || !J.value || !G.value || e.getFullYear() < D || e.getFullYear() > O || (q.value = new Date(e));
|
|
201
243
|
}
|
|
202
|
-
function
|
|
244
|
+
function on() {
|
|
203
245
|
q.value = null;
|
|
204
246
|
}
|
|
205
|
-
function
|
|
247
|
+
function sn(e) {
|
|
206
248
|
let t = e.currentTarget, n = e.relatedTarget;
|
|
207
|
-
!t || n && t.contains(n) ||
|
|
249
|
+
!t || n && t.contains(n) || on();
|
|
208
250
|
}
|
|
209
|
-
function
|
|
210
|
-
if (!
|
|
251
|
+
function cn(e) {
|
|
252
|
+
if (!g.range || !J.value || !G.value) return;
|
|
211
253
|
let t = e.touches.item(0);
|
|
212
254
|
if (!t) return;
|
|
213
255
|
let n = document.elementFromPoint(t.clientX, t.clientY)?.closest("[data-day-index]");
|
|
214
256
|
if (!n) return;
|
|
215
257
|
let r = Number(n.dataset.dayIndex);
|
|
216
258
|
if (Number.isNaN(r)) return;
|
|
217
|
-
let i =
|
|
218
|
-
i &&
|
|
219
|
-
}
|
|
220
|
-
function
|
|
221
|
-
if (!(
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
let t = new Date(e);
|
|
226
|
-
A.value && G.value && t.setHours(G.value.getHours(), G.value.getMinutes(), G.value.getSeconds(), G.value.getMilliseconds()), G.value = t, K.value = null, q.value = null, J.value = !0;
|
|
259
|
+
let i = Tt.value[r];
|
|
260
|
+
i && an(i.date);
|
|
261
|
+
}
|
|
262
|
+
function ln(e) {
|
|
263
|
+
if (!(g.readonly || g.disabled) && !(e.getFullYear() < D || e.getFullYear() > O)) if (g.range) if (!J.value) G.value = new Date(e), K.value = null, q.value = null, J.value = !0;
|
|
264
|
+
else {
|
|
265
|
+
let t = G.value, n = new Date(e), [r, i] = n < t ? [n, t] : [t, n];
|
|
266
|
+
j.value && i.setHours(23, 59, Qe.value ? 59 : 0, 0), A.value = [r, i], G.value = null, K.value = null, q.value = null, J.value = !1;
|
|
227
267
|
}
|
|
228
268
|
else {
|
|
229
269
|
let t = new Date(e);
|
|
230
|
-
W.value && !
|
|
270
|
+
W.value && !qn(W.value) ? t.setHours(W.value.getHours(), W.value.getMinutes(), W.value.getSeconds()) : j.value && Jn(t), A.value = t;
|
|
231
271
|
}
|
|
232
272
|
}
|
|
273
|
+
function un(e) {
|
|
274
|
+
e !== R.value && X(e, !0);
|
|
275
|
+
}
|
|
276
|
+
function dn(e) {
|
|
277
|
+
e !== z.value && Y(e, !0);
|
|
278
|
+
}
|
|
233
279
|
function Y(e, t) {
|
|
234
|
-
|
|
280
|
+
z.value = e, t && gr("year");
|
|
235
281
|
}
|
|
236
282
|
function X(e, t) {
|
|
237
|
-
|
|
283
|
+
R.value = e, t && gr("month");
|
|
238
284
|
}
|
|
239
|
-
function
|
|
240
|
-
|
|
285
|
+
function fn() {
|
|
286
|
+
R.value === 0 ? (X(11), Y(z.value - 1)) : X(R.value - 1);
|
|
241
287
|
}
|
|
242
|
-
function
|
|
243
|
-
|
|
288
|
+
function pn() {
|
|
289
|
+
R.value === 11 ? (X(0), Y(z.value + 1)) : X(R.value + 1);
|
|
244
290
|
}
|
|
245
|
-
function
|
|
246
|
-
X((/* @__PURE__ */ new Date()).getMonth()), Y((/* @__PURE__ */ new Date()).getFullYear()),
|
|
291
|
+
function mn() {
|
|
292
|
+
X((/* @__PURE__ */ new Date()).getMonth()), Y((/* @__PURE__ */ new Date()).getFullYear()), hr();
|
|
247
293
|
}
|
|
248
|
-
function
|
|
249
|
-
let e = W.value
|
|
250
|
-
|
|
251
|
-
let n = t[0];
|
|
252
|
-
n instanceof Date ? e = n : typeof n == "string" && (e = me(n, h.format, dt.value));
|
|
253
|
-
}
|
|
254
|
-
e ??= /* @__PURE__ */ new Date(), X(e.getMonth()), Y(e.getFullYear()), Qn();
|
|
294
|
+
function hn() {
|
|
295
|
+
let e = W.value ?? /* @__PURE__ */ new Date();
|
|
296
|
+
X(e.getMonth()), Y(e.getFullYear()), hr();
|
|
255
297
|
}
|
|
256
|
-
function
|
|
257
|
-
return
|
|
298
|
+
function gn(e) {
|
|
299
|
+
return g.range ? J.value ? e === 1 ? K.value : G.value : e === 1 ? _t.value ?? K.value : W.value ?? G.value : W.value;
|
|
258
300
|
}
|
|
259
|
-
function
|
|
301
|
+
function _n() {
|
|
260
302
|
G.value = null, K.value = null, q.value = null, J.value = !1;
|
|
261
303
|
}
|
|
262
|
-
function
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
function tn() {
|
|
266
|
-
if (!h.range || !M.value) return;
|
|
267
|
-
let e = k.value;
|
|
304
|
+
function vn() {
|
|
305
|
+
if (!g.range || !N.value) return;
|
|
306
|
+
let e = A.value;
|
|
268
307
|
if (!Array.isArray(e) || e.length < 2) return;
|
|
269
308
|
let t = e[0], n = e[1];
|
|
270
|
-
!(t instanceof Date) || !(n instanceof Date) || n >= t || (
|
|
309
|
+
!(t instanceof Date) || !(n instanceof Date) || n >= t || (A.value = [new Date(n), new Date(t)]);
|
|
271
310
|
}
|
|
272
|
-
function
|
|
273
|
-
if (!
|
|
274
|
-
|
|
311
|
+
function yn(e, t) {
|
|
312
|
+
if (!g.range) {
|
|
313
|
+
A.value = t;
|
|
275
314
|
return;
|
|
276
315
|
}
|
|
277
|
-
if (
|
|
316
|
+
if (N.value) {
|
|
278
317
|
e === 0 ? G.value = t : K.value = t;
|
|
279
|
-
let n = e === 0 ? t : W.value ?? G.value, r = e === 1 ? t :
|
|
318
|
+
let n = e === 0 ? t : W.value ?? G.value, r = e === 1 ? t : _t.value;
|
|
280
319
|
if (!n || !r) return;
|
|
281
|
-
|
|
320
|
+
A.value = [new Date(n), new Date(r)], _n();
|
|
282
321
|
return;
|
|
283
322
|
}
|
|
284
323
|
if (J.value) {
|
|
285
324
|
e === 0 && (G.value = t);
|
|
286
325
|
return;
|
|
287
326
|
}
|
|
288
|
-
let n = W.value, r =
|
|
289
|
-
!n || !r || (
|
|
327
|
+
let n = W.value, r = _t.value;
|
|
328
|
+
!n || !r || (A.value = e === 1 ? [n, t] : [t, r]);
|
|
290
329
|
}
|
|
291
330
|
function Z(e, t) {
|
|
292
|
-
let n =
|
|
331
|
+
let n = gn(e) ?? (() => {
|
|
293
332
|
let e = /* @__PURE__ */ new Date();
|
|
294
333
|
return e.setHours(0, 0, 0, 0), e;
|
|
295
334
|
})(), r = new Date(n);
|
|
296
|
-
t(r),
|
|
335
|
+
t(r), yn(e, r);
|
|
297
336
|
}
|
|
298
|
-
function
|
|
299
|
-
let t =
|
|
300
|
-
if (!t) return
|
|
337
|
+
function bn(e) {
|
|
338
|
+
let t = gn(e);
|
|
339
|
+
if (!t) return M.value ? 12 : 0;
|
|
301
340
|
let n = t.getHours();
|
|
302
|
-
return
|
|
341
|
+
return M.value ? n % 12 || 12 : n;
|
|
303
342
|
}
|
|
304
|
-
function
|
|
305
|
-
return
|
|
343
|
+
function xn(e) {
|
|
344
|
+
return gn(e)?.getMinutes() ?? 0;
|
|
306
345
|
}
|
|
307
|
-
function
|
|
308
|
-
return
|
|
346
|
+
function Sn(e) {
|
|
347
|
+
return gn(e)?.getSeconds() ?? 0;
|
|
309
348
|
}
|
|
310
|
-
function
|
|
311
|
-
let t =
|
|
349
|
+
function Cn(e) {
|
|
350
|
+
let t = gn(e);
|
|
312
351
|
return t ? t.getHours() >= 12 : !1;
|
|
313
352
|
}
|
|
314
353
|
function Q(e, t) {
|
|
315
354
|
return t ? e === 12 ? 12 : e + 12 : e === 12 ? 0 : e;
|
|
316
355
|
}
|
|
317
|
-
function
|
|
356
|
+
function wn(e, t) {
|
|
318
357
|
let n = e >= 12, r = e % 12 || 12;
|
|
319
358
|
return t === 1 ? r >= 12 ? Q(1, n) : r === 11 ? Q(12, !n) : Q(r + 1, n) : r <= 1 ? Q(12, n) : r === 12 ? Q(11, !n) : Q(r - 1, n);
|
|
320
359
|
}
|
|
321
|
-
function
|
|
360
|
+
function Tn(e) {
|
|
322
361
|
Z(e, (e) => {
|
|
323
|
-
|
|
362
|
+
M.value ? e.setHours(wn(e.getHours(), 1)) : e.setHours(e.getHours() >= 23 ? 0 : e.getHours() + 1);
|
|
324
363
|
});
|
|
325
364
|
}
|
|
326
|
-
function
|
|
365
|
+
function En(e) {
|
|
327
366
|
Z(e, (e) => {
|
|
328
|
-
|
|
367
|
+
M.value ? e.setHours(wn(e.getHours(), -1)) : e.setHours(e.getHours() <= 0 ? 23 : e.getHours() - 1);
|
|
329
368
|
});
|
|
330
369
|
}
|
|
331
|
-
function
|
|
370
|
+
function Dn(e) {
|
|
332
371
|
Z(e, (e) => {
|
|
333
372
|
e.setMinutes(e.getMinutes() >= 59 ? 0 : e.getMinutes() + 1);
|
|
334
373
|
});
|
|
335
374
|
}
|
|
336
|
-
function
|
|
375
|
+
function On(e) {
|
|
337
376
|
Z(e, (e) => {
|
|
338
377
|
e.setMinutes(e.getMinutes() <= 0 ? 59 : e.getMinutes() - 1);
|
|
339
378
|
});
|
|
340
379
|
}
|
|
341
|
-
function
|
|
380
|
+
function kn(e) {
|
|
342
381
|
Z(e, (e) => {
|
|
343
382
|
e.setSeconds(e.getSeconds() >= 59 ? 0 : e.getSeconds() + 1);
|
|
344
383
|
});
|
|
345
384
|
}
|
|
346
|
-
function
|
|
385
|
+
function An(e) {
|
|
347
386
|
Z(e, (e) => {
|
|
348
387
|
e.setSeconds(e.getSeconds() <= 0 ? 59 : e.getSeconds() - 1);
|
|
349
388
|
});
|
|
350
389
|
}
|
|
351
|
-
function
|
|
390
|
+
function jn(e) {
|
|
352
391
|
return (e ?? "").replace(/\D/g, "");
|
|
353
392
|
}
|
|
354
|
-
function
|
|
393
|
+
function Mn(e) {
|
|
355
394
|
return Math.min(23, Math.max(0, e));
|
|
356
395
|
}
|
|
357
|
-
function
|
|
396
|
+
function Nn(e) {
|
|
358
397
|
return Math.min(12, Math.max(1, e));
|
|
359
398
|
}
|
|
360
|
-
function
|
|
399
|
+
function Pn(e) {
|
|
361
400
|
return Math.min(59, Math.max(0, e));
|
|
362
401
|
}
|
|
363
|
-
function
|
|
364
|
-
let n =
|
|
402
|
+
function Fn(e, t) {
|
|
403
|
+
let n = jn(e).slice(0, 2);
|
|
365
404
|
if (n === "") return;
|
|
366
|
-
let r = Number.parseInt(n, 10);
|
|
367
|
-
if (Number.isNaN(r)) return;
|
|
368
|
-
let i = j.value ? _n(r) : gn(r);
|
|
405
|
+
let r = Number.parseInt(n, 10), i = M.value ? Nn(r) : Mn(r);
|
|
369
406
|
Z(t, (e) => {
|
|
370
|
-
|
|
407
|
+
M.value ? e.setHours(Q(i, e.getHours() >= 12)) : e.setHours(i);
|
|
371
408
|
});
|
|
372
409
|
}
|
|
373
|
-
function
|
|
374
|
-
let n =
|
|
410
|
+
function In(e, t) {
|
|
411
|
+
let n = jn(e).slice(0, 2);
|
|
375
412
|
if (n === "") return;
|
|
376
|
-
let r = Number.parseInt(n, 10);
|
|
377
|
-
if (Number.isNaN(r)) return;
|
|
378
|
-
let i = vn(r);
|
|
413
|
+
let r = Pn(Number.parseInt(n, 10));
|
|
379
414
|
Z(t, (e) => {
|
|
380
|
-
e.setMinutes(
|
|
415
|
+
e.setMinutes(r);
|
|
381
416
|
});
|
|
382
417
|
}
|
|
383
|
-
function
|
|
384
|
-
let n =
|
|
418
|
+
function Ln(e, t) {
|
|
419
|
+
let n = jn(e).slice(0, 2);
|
|
385
420
|
if (n === "") return;
|
|
386
|
-
let r = Number.parseInt(n, 10);
|
|
387
|
-
if (Number.isNaN(r)) return;
|
|
388
|
-
let i = vn(r);
|
|
421
|
+
let r = Pn(Number.parseInt(n, 10));
|
|
389
422
|
Z(t, (e) => {
|
|
390
|
-
e.setSeconds(
|
|
423
|
+
e.setSeconds(r);
|
|
391
424
|
});
|
|
392
425
|
}
|
|
393
|
-
async function
|
|
426
|
+
async function Rn(e, t, n) {
|
|
394
427
|
if (e.ctrlKey || e.altKey || e.metaKey || !/^\d$/.test(e.key)) return;
|
|
395
|
-
let r = e.target;
|
|
396
|
-
if (!r) return;
|
|
397
|
-
let i = r.selectionStart, a = r.selectionEnd;
|
|
428
|
+
let r = e.target, i = r.selectionStart, a = r.selectionEnd;
|
|
398
429
|
if (i === null || a === null || i !== a || r.maxLength <= 0 || r.value.length < r.maxLength || i >= r.value.length) return;
|
|
399
430
|
e.preventDefault();
|
|
400
431
|
let o = `${r.value.slice(0, i)}${e.key}${r.value.slice(i + 1)}`;
|
|
401
|
-
t === "hours" ?
|
|
432
|
+
t === "hours" ? Fn(o, n) : t === "minutes" ? In(o, n) : Ln(o, n);
|
|
402
433
|
let s = Math.min(i + 1, r.maxLength);
|
|
403
|
-
await
|
|
434
|
+
await y(), r.setSelectionRange(s, s);
|
|
404
435
|
}
|
|
405
|
-
function
|
|
436
|
+
function zn(e, t) {
|
|
406
437
|
Z(t, (t) => {
|
|
407
438
|
let n = t.getHours() % 12 || 12;
|
|
408
439
|
t.setHours(Q(n, e));
|
|
409
440
|
});
|
|
410
441
|
}
|
|
411
|
-
function
|
|
442
|
+
function Bn(e, t) {
|
|
412
443
|
let n = e.trim();
|
|
413
|
-
|
|
444
|
+
if (!n) return null;
|
|
445
|
+
let r = ge(n, g.format, xt.value, Je);
|
|
446
|
+
if (r) return r;
|
|
447
|
+
let i = ve(n);
|
|
448
|
+
if (i) return i;
|
|
449
|
+
if (t?.complete) {
|
|
450
|
+
let e = _e(n, g.format, xt.value, Je);
|
|
451
|
+
if (e) return e;
|
|
452
|
+
}
|
|
453
|
+
return or(n);
|
|
414
454
|
}
|
|
415
|
-
function
|
|
416
|
-
if (
|
|
417
|
-
|
|
455
|
+
function Vn(e) {
|
|
456
|
+
if (g.readonly || g.disabled) {
|
|
457
|
+
wt();
|
|
418
458
|
return;
|
|
419
459
|
}
|
|
420
460
|
let t = e ?? "";
|
|
421
|
-
|
|
461
|
+
I.value = t, F.value = t;
|
|
422
462
|
}
|
|
423
|
-
function
|
|
463
|
+
function Hn(e, t) {
|
|
424
464
|
let n = e.split(" - ");
|
|
425
465
|
if (n.length !== 2) return null;
|
|
426
|
-
let r = n[0]?.trim() ?? "", i = n[1]?.trim() ?? "", a =
|
|
427
|
-
return !a || !o ? null : (
|
|
466
|
+
let r = n[0]?.trim() ?? "", i = n[1]?.trim() ?? "", a = Bn(r, t), o = Bn(i, t);
|
|
467
|
+
return !a || !o ? null : (Wn(r) && Wn(i) ? o < a : Date.UTC(o.getFullYear(), o.getMonth(), o.getDate()) < Date.UTC(a.getFullYear(), a.getMonth(), a.getDate())) ? {
|
|
428
468
|
range: [o, a],
|
|
429
469
|
startSource: i,
|
|
430
470
|
endSource: r
|
|
@@ -434,269 +474,281 @@ var Oe = {
|
|
|
434
474
|
endSource: i
|
|
435
475
|
};
|
|
436
476
|
}
|
|
437
|
-
function
|
|
438
|
-
if (
|
|
439
|
-
let e =
|
|
440
|
-
if (!e) return
|
|
441
|
-
if (
|
|
442
|
-
let t =
|
|
477
|
+
function Un() {
|
|
478
|
+
if (g.readonly || g.disabled) return !1;
|
|
479
|
+
let e = ie(I.value ?? F.value, g.range ? Qt.value : g.format, { padMaxDigits: !0 });
|
|
480
|
+
if (!e) return I.value = null, tn(A.value) && (A.value = void 0), F.value = "", !1;
|
|
481
|
+
if (g.range) {
|
|
482
|
+
let t = be(e, en.value), n = Hn(e, { complete: !0 }) ?? Hn(t, { complete: !0 });
|
|
443
483
|
if (n) {
|
|
444
|
-
let e =
|
|
445
|
-
return
|
|
484
|
+
let e = Kn(n.range, n.startSource, n.endSource);
|
|
485
|
+
return A.value = e, I.value = null, F.value = e.map((e) => oe(e, g.format, bt.value)).join(" - "), !0;
|
|
446
486
|
}
|
|
447
|
-
return
|
|
487
|
+
return I.value = null, wt(), !1;
|
|
448
488
|
}
|
|
449
|
-
let t =
|
|
450
|
-
if (!n) return
|
|
451
|
-
let r =
|
|
452
|
-
return
|
|
489
|
+
let t = ie(be(e, $t.value), g.format), n = Bn(e, { complete: !0 }) ?? _e(t, g.format, xt.value, Je);
|
|
490
|
+
if (!n) return I.value = null, wt(), !1;
|
|
491
|
+
let r = Gn(n, e, t);
|
|
492
|
+
return A.value = r, I.value = null, F.value = oe(r, g.format, bt.value), !0;
|
|
453
493
|
}
|
|
454
|
-
function
|
|
455
|
-
return !
|
|
494
|
+
function Wn(e) {
|
|
495
|
+
return !j.value || de(e, g.format) ? !0 : /\dT\d/i.test(e) || /\d{1,2}:\d{2}/.test(e);
|
|
456
496
|
}
|
|
457
|
-
function
|
|
458
|
-
if (!
|
|
497
|
+
function Gn(e, ...t) {
|
|
498
|
+
if (!j.value || g.range || t.some((e) => Wn(e))) return e;
|
|
459
499
|
let n = new Date(e);
|
|
460
|
-
return
|
|
500
|
+
return Jn(n), n;
|
|
461
501
|
}
|
|
462
|
-
function
|
|
463
|
-
if (!
|
|
502
|
+
function Kn(e, t, n) {
|
|
503
|
+
if (!j.value) return e;
|
|
464
504
|
let [r, i] = e, a = new Date(r), o = new Date(i);
|
|
465
|
-
return
|
|
505
|
+
return Wn(t) || a.setHours(0, 0, 0, 0), Wn(n) || o.setHours(23, 59, Qe.value ? 59 : 0, 0), [a, o];
|
|
466
506
|
}
|
|
467
|
-
function
|
|
507
|
+
function qn(e) {
|
|
468
508
|
return e.getHours() === 0 && e.getMinutes() === 0 && e.getSeconds() === 0 && e.getMilliseconds() === 0;
|
|
469
509
|
}
|
|
470
|
-
function
|
|
510
|
+
function Jn(e) {
|
|
471
511
|
let t = /* @__PURE__ */ new Date();
|
|
472
|
-
e.setHours(t.getHours(), t.getMinutes(),
|
|
512
|
+
e.setHours(t.getHours(), t.getMinutes(), Qe.value ? t.getSeconds() : 0, Qe.value ? t.getMilliseconds() : 0);
|
|
473
513
|
}
|
|
474
|
-
function
|
|
514
|
+
function Yn(e) {
|
|
475
515
|
let t = e.target;
|
|
476
516
|
if (!(t instanceof Element) || !U.value) return null;
|
|
477
517
|
let n = t.closest("button, input, select, textarea, a[href], [tabindex], [contenteditable]");
|
|
478
518
|
return n && U.value.contains(n) ? n : null;
|
|
479
519
|
}
|
|
480
|
-
function
|
|
520
|
+
function Xn(e) {
|
|
481
521
|
return !(e.matches(":disabled") || e.getAttribute("aria-disabled") === "true" || e.getAttribute("tabindex") === "-1");
|
|
482
522
|
}
|
|
483
|
-
function
|
|
523
|
+
function Zn(e) {
|
|
484
524
|
if (!(e.target instanceof Node) || !U.value?.contains(e.target)) return;
|
|
485
|
-
|
|
486
|
-
let t =
|
|
487
|
-
t && !
|
|
525
|
+
nt = !0;
|
|
526
|
+
let t = Yn(e);
|
|
527
|
+
t && !Xn(t) && e.preventDefault();
|
|
488
528
|
}
|
|
489
|
-
function
|
|
490
|
-
return U.value ?
|
|
529
|
+
function Qn() {
|
|
530
|
+
return U.value ? r(U.value).filter((e) => !(Number(e.getAttribute("tabindex")) < 0)) : [];
|
|
491
531
|
}
|
|
492
|
-
async function
|
|
493
|
-
if (!(
|
|
532
|
+
async function $n(e) {
|
|
533
|
+
if (!(g.readonly || g.disabled)) {
|
|
494
534
|
if (e.key === "Enter") {
|
|
495
|
-
e.preventDefault(),
|
|
535
|
+
e.preventDefault(), Un();
|
|
496
536
|
return;
|
|
497
|
-
} else if (e.key === "Tab") U.value?.setAttribute("inert", ""),
|
|
537
|
+
} else if (e.key === "Tab") U.value?.setAttribute("inert", ""), rt = !0, P.value = !1;
|
|
498
538
|
else if (e.key === "ArrowDown") {
|
|
499
|
-
|
|
500
|
-
let [t] =
|
|
539
|
+
P.value = !0, await y();
|
|
540
|
+
let [t] = Qn();
|
|
501
541
|
if (!t) return;
|
|
502
|
-
e.preventDefault(),
|
|
542
|
+
e.preventDefault(), nt = !0, t.focus();
|
|
503
543
|
}
|
|
504
544
|
}
|
|
505
545
|
}
|
|
506
|
-
function
|
|
507
|
-
|
|
546
|
+
function er() {
|
|
547
|
+
Sr();
|
|
508
548
|
}
|
|
509
|
-
function
|
|
549
|
+
function tr(e) {
|
|
510
550
|
if (e.key !== "Tab") return;
|
|
511
|
-
let t =
|
|
551
|
+
let t = Qn();
|
|
512
552
|
if (!t.length) return;
|
|
513
|
-
let
|
|
553
|
+
let r = t[0], i = t[t.length - 1], a = document.activeElement;
|
|
514
554
|
if (e.shiftKey) {
|
|
515
|
-
if (
|
|
516
|
-
e.preventDefault(),
|
|
555
|
+
if (a !== r) return;
|
|
556
|
+
e.preventDefault(), nt = !1, Sr();
|
|
517
557
|
return;
|
|
518
558
|
}
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
559
|
+
if (a !== i) return;
|
|
560
|
+
e.preventDefault(), rt = !1, P.value = !1;
|
|
561
|
+
let o = at.value?.$el, s = o ? n(o, U.value) : void 0;
|
|
562
|
+
s ? s.focus() : Sr();
|
|
563
|
+
}
|
|
564
|
+
async function nr(e) {
|
|
565
|
+
if (Un(), nt) {
|
|
566
|
+
nt = !1;
|
|
524
567
|
return;
|
|
525
568
|
}
|
|
526
569
|
let t = e?.relatedTarget;
|
|
527
570
|
if (t instanceof Node && U.value?.contains(t)) return;
|
|
528
|
-
await
|
|
529
|
-
let n =
|
|
530
|
-
n !== r && (r instanceof Node && U.value?.contains(r) || (
|
|
531
|
-
}
|
|
532
|
-
function
|
|
533
|
-
if (!(
|
|
534
|
-
if (
|
|
535
|
-
|
|
571
|
+
await y();
|
|
572
|
+
let n = cr(), r = document.activeElement;
|
|
573
|
+
n !== r && (r instanceof Node && U.value?.contains(r) || (V = !1, P.value = !1, et.value = !1));
|
|
574
|
+
}
|
|
575
|
+
function rr() {
|
|
576
|
+
if (!(g.readonly || g.disabled)) {
|
|
577
|
+
if (et.value = !0, V) {
|
|
578
|
+
V = !1;
|
|
536
579
|
return;
|
|
537
580
|
}
|
|
538
|
-
|
|
581
|
+
P.value ||= !0;
|
|
539
582
|
}
|
|
540
583
|
}
|
|
541
|
-
function
|
|
542
|
-
|
|
584
|
+
function ir() {
|
|
585
|
+
g.readonly || g.disabled || (V = !1, P.value = !0);
|
|
543
586
|
}
|
|
544
|
-
function
|
|
545
|
-
e ||
|
|
587
|
+
function ar(e) {
|
|
588
|
+
e || it(), P.value = e;
|
|
546
589
|
}
|
|
547
|
-
function
|
|
548
|
-
let t =
|
|
590
|
+
function or(e) {
|
|
591
|
+
let t = ve(e);
|
|
549
592
|
if (t) return t;
|
|
550
|
-
let n = /[A-Za-z]/.test(e), r =
|
|
593
|
+
let n = /[A-Za-z]/.test(e), r = e.match(/^(\d{4})[-/](\d{1,2})[-/](\d{1,2})(?:[ T]\d{1,2}:\d{2}(?::\d{2})?)?$/);
|
|
551
594
|
if (!n && !r) return null;
|
|
595
|
+
if (r) {
|
|
596
|
+
let [, e, t, n] = r.map(Number);
|
|
597
|
+
if (n > le(t - 1, e)) return null;
|
|
598
|
+
}
|
|
552
599
|
let i = new Date(e);
|
|
553
600
|
return Number.isNaN(i.getTime()) ? null : i;
|
|
554
601
|
}
|
|
555
|
-
function
|
|
602
|
+
function sr(e) {
|
|
556
603
|
return e instanceof HTMLInputElement ? e : typeof e == "object" && e && "value" in e && e.value instanceof HTMLInputElement ? e.value : null;
|
|
557
604
|
}
|
|
558
|
-
function
|
|
605
|
+
function cr() {
|
|
559
606
|
if (H) return H;
|
|
560
|
-
let e =
|
|
607
|
+
let e = sr(at.value?.inputRef);
|
|
561
608
|
if (e) return H = e, e;
|
|
562
|
-
let t =
|
|
609
|
+
let t = pt(at.value?.fieldRef)?.querySelector(".q-text-field__input") ?? null;
|
|
563
610
|
return t ? (H = t, t) : null;
|
|
564
611
|
}
|
|
565
|
-
function
|
|
612
|
+
function lr(e) {
|
|
566
613
|
return e.isSelected || e.isRangeStart || e.isRangeEnd ? "bold" : e.isInRange ? "tonal" : "ghost";
|
|
567
614
|
}
|
|
568
|
-
function
|
|
615
|
+
function ur(e) {
|
|
569
616
|
U.value?.style.setProperty("--q-date-view-height", `${Math.max(0, e)}px`);
|
|
570
617
|
}
|
|
571
|
-
async function
|
|
572
|
-
if (!
|
|
573
|
-
|
|
618
|
+
async function dr() {
|
|
619
|
+
if (!P.value || N.value) {
|
|
620
|
+
ur(0);
|
|
574
621
|
return;
|
|
575
622
|
}
|
|
576
|
-
|
|
623
|
+
L.value === "date" && (await y(), ur(ot.value?.getBoundingClientRect().height ?? 0));
|
|
577
624
|
}
|
|
578
625
|
function $() {
|
|
579
|
-
|
|
626
|
+
tt?.disconnect(), tt = null;
|
|
580
627
|
}
|
|
581
|
-
async function
|
|
582
|
-
!
|
|
583
|
-
|
|
584
|
-
}),
|
|
628
|
+
async function fr() {
|
|
629
|
+
!P.value || N.value || L.value !== "date" || (await y(), ot.value && ($(), tt = new MutationObserver(() => {
|
|
630
|
+
dr();
|
|
631
|
+
}), tt.observe(ot.value, {
|
|
585
632
|
childList: !0,
|
|
586
633
|
subtree: !0,
|
|
587
634
|
attributes: !0,
|
|
588
635
|
characterData: !0
|
|
589
|
-
}),
|
|
636
|
+
}), dr()));
|
|
590
637
|
}
|
|
591
|
-
function
|
|
592
|
-
|
|
638
|
+
function pr() {
|
|
639
|
+
L.value = "time", $();
|
|
593
640
|
}
|
|
594
|
-
function
|
|
595
|
-
|
|
641
|
+
async function mr() {
|
|
642
|
+
pr(), await y(), gt(ut.value);
|
|
596
643
|
}
|
|
597
|
-
|
|
598
|
-
|
|
644
|
+
function hr() {
|
|
645
|
+
L.value = "date", fr();
|
|
599
646
|
}
|
|
600
|
-
function
|
|
601
|
-
|
|
602
|
-
|
|
647
|
+
async function gr(e) {
|
|
648
|
+
U.value?.focus(), hr(), await y(), gt(e === "year" ? ct.value : e === "month" ? st.value : e === "time" ? lt.value : null);
|
|
649
|
+
}
|
|
650
|
+
function _r() {
|
|
651
|
+
let e = L.value;
|
|
652
|
+
e !== "date" && gr(e);
|
|
603
653
|
}
|
|
604
|
-
async function
|
|
605
|
-
$(),
|
|
606
|
-
let e =
|
|
654
|
+
async function vr() {
|
|
655
|
+
$(), L.value = "month", await y();
|
|
656
|
+
let e = dt.get(R.value);
|
|
607
657
|
e?.scrollIntoView({ block: "center" }), e?.focus();
|
|
608
658
|
}
|
|
609
|
-
async function
|
|
610
|
-
$(),
|
|
659
|
+
async function yr() {
|
|
660
|
+
$(), B.value = z.value, L.value = "year", await y();
|
|
661
|
+
let e = ft.get(B.value);
|
|
662
|
+
e?.scrollIntoView({ block: "center" }), e?.focus();
|
|
611
663
|
}
|
|
612
|
-
async function
|
|
664
|
+
async function br(e) {
|
|
613
665
|
if (e.key !== "Escape") return;
|
|
614
|
-
if (
|
|
615
|
-
e.preventDefault(),
|
|
666
|
+
if (V = !0, L.value === "date" || N.value) {
|
|
667
|
+
e.preventDefault(), P.value = !1, await y(), Dr();
|
|
616
668
|
return;
|
|
617
669
|
}
|
|
618
670
|
e.preventDefault();
|
|
619
|
-
let t =
|
|
620
|
-
await
|
|
671
|
+
let t = L.value;
|
|
672
|
+
await gr(t);
|
|
621
673
|
}
|
|
622
|
-
function
|
|
623
|
-
|
|
674
|
+
function xr(e) {
|
|
675
|
+
br(e);
|
|
624
676
|
}
|
|
625
|
-
function
|
|
626
|
-
|
|
677
|
+
function Sr() {
|
|
678
|
+
cr()?.focus();
|
|
627
679
|
}
|
|
628
|
-
function
|
|
680
|
+
function Cr(e) {
|
|
629
681
|
return !e || e === document.body || e === document.documentElement;
|
|
630
682
|
}
|
|
631
|
-
function
|
|
683
|
+
function wr(e, t) {
|
|
632
684
|
return e.closest(".q-date-time-picker__menu") || t.closest(".q-date-time-picker")?.contains(e) || !(e instanceof HTMLElement) ? !1 : e.tabIndex >= 0 || e.matches("input, select, textarea, button, a[href], [tabindex]:not([tabindex=\"-1\"])");
|
|
633
685
|
}
|
|
634
|
-
function
|
|
635
|
-
let t =
|
|
636
|
-
return t ? e === t || !e || !e.isConnected ||
|
|
686
|
+
function Tr(e) {
|
|
687
|
+
let t = cr();
|
|
688
|
+
return t ? e === t || !e || !e.isConnected || Cr(e) || U.value?.contains(e) ? !0 : !wr(e, t) : !1;
|
|
637
689
|
}
|
|
638
|
-
function
|
|
639
|
-
if (
|
|
640
|
-
let e =
|
|
641
|
-
!e || !
|
|
690
|
+
function Er() {
|
|
691
|
+
if (rt) return;
|
|
692
|
+
let e = cr();
|
|
693
|
+
!e || !Tr(document.activeElement) || (V = !0, e.focus());
|
|
642
694
|
}
|
|
643
|
-
function
|
|
644
|
-
|
|
695
|
+
function Dr() {
|
|
696
|
+
y().then(() => {
|
|
645
697
|
requestAnimationFrame(() => {
|
|
646
698
|
requestAnimationFrame(() => {
|
|
647
|
-
|
|
699
|
+
Er();
|
|
648
700
|
});
|
|
649
701
|
});
|
|
650
702
|
});
|
|
651
703
|
}
|
|
652
|
-
function
|
|
653
|
-
|
|
654
|
-
let e =
|
|
655
|
-
|
|
704
|
+
function Or() {
|
|
705
|
+
it();
|
|
706
|
+
let e = rt;
|
|
707
|
+
rt = !1, !e && (V = !0, Dr());
|
|
656
708
|
}
|
|
657
|
-
return
|
|
709
|
+
return T(A, () => {
|
|
658
710
|
W.value && (X(W.value.getMonth()), Y(W.value.getFullYear()));
|
|
659
|
-
}),
|
|
660
|
-
if (e && t === !1 ?
|
|
661
|
-
$(),
|
|
711
|
+
}), T(P, (e, t) => {
|
|
712
|
+
if (e && t === !1 ? Se("open") : !e && t === !0 && Se("close"), e || (Mt.value = null), N.value) {
|
|
713
|
+
$(), ur(0), e ? (document.addEventListener("keydown", xr, { capture: !0 }), pr()) : (t && (vn(), Or()), document.removeEventListener("keydown", xr, { capture: !0 }));
|
|
662
714
|
return;
|
|
663
715
|
}
|
|
664
|
-
|
|
665
|
-
}),
|
|
666
|
-
e && $(),
|
|
667
|
-
}, { immediate: !0 }),
|
|
668
|
-
$(), document.removeEventListener("keydown",
|
|
669
|
-
}), (e,
|
|
670
|
-
id:
|
|
716
|
+
_n(), e ? (document.addEventListener("keydown", xr, { capture: !0 }), hn(), fr()) : (t && Or(), document.removeEventListener("keydown", xr, { capture: !0 }), $(), ur(0));
|
|
717
|
+
}), T(N, (e) => {
|
|
718
|
+
e && $(), P.value = !1, e && ur(0), e ? pr() : hr();
|
|
719
|
+
}, { immediate: !0 }), we(() => {
|
|
720
|
+
$(), document.removeEventListener("keydown", xr, { capture: !0 });
|
|
721
|
+
}), (e, n) => (x(), p(l, null, [h(C(o), v({
|
|
722
|
+
id: C(Ye),
|
|
671
723
|
ref: "field",
|
|
672
|
-
"model-value":
|
|
673
|
-
class: ["q-date-time-picker",
|
|
674
|
-
clearable:
|
|
675
|
-
label:
|
|
676
|
-
"label-position":
|
|
677
|
-
readonly:
|
|
678
|
-
disabled:
|
|
679
|
-
placeholder:
|
|
680
|
-
required:
|
|
681
|
-
size:
|
|
682
|
-
invalid:
|
|
683
|
-
help:
|
|
684
|
-
"help-display":
|
|
685
|
-
icons:
|
|
686
|
-
texts:
|
|
724
|
+
"model-value": F.value,
|
|
725
|
+
class: ["q-date-time-picker", g.class],
|
|
726
|
+
clearable: nn.value,
|
|
727
|
+
label: g.label,
|
|
728
|
+
"label-position": g.labelPosition,
|
|
729
|
+
readonly: g.readonly,
|
|
730
|
+
disabled: g.disabled,
|
|
731
|
+
placeholder: Ze.value,
|
|
732
|
+
required: g.required,
|
|
733
|
+
size: g.size,
|
|
734
|
+
invalid: g.invalid,
|
|
735
|
+
help: g.help,
|
|
736
|
+
"help-display": g.helpDisplay,
|
|
737
|
+
icons: g.icons,
|
|
738
|
+
texts: g.texts
|
|
687
739
|
}, e.$attrs, {
|
|
688
|
-
onBlur:
|
|
689
|
-
"onClick:clear":
|
|
690
|
-
onDrop:
|
|
691
|
-
onFocusin:
|
|
692
|
-
onKeydown:
|
|
693
|
-
"onUpdate:modelValue":
|
|
694
|
-
}),
|
|
695
|
-
prepend:
|
|
740
|
+
onBlur: nr,
|
|
741
|
+
"onClick:clear": rn,
|
|
742
|
+
onDrop: er,
|
|
743
|
+
onFocusin: rr,
|
|
744
|
+
onKeydown: $n,
|
|
745
|
+
"onUpdate:modelValue": Vn
|
|
746
|
+
}), xe({
|
|
747
|
+
prepend: E(() => [h(C(t), v({ class: "q-date-time-picker__input-icon" }, Zt.value), null, 16)]),
|
|
696
748
|
_: 2
|
|
697
749
|
}, [e.$slots.extras ? {
|
|
698
750
|
name: "extras",
|
|
699
|
-
fn:
|
|
751
|
+
fn: E(() => [Ee(e.$slots, "extras")]),
|
|
700
752
|
key: "0"
|
|
701
753
|
} : void 0]), 1040, [
|
|
702
754
|
"id",
|
|
@@ -715,152 +767,174 @@ var Oe = {
|
|
|
715
767
|
"help-display",
|
|
716
768
|
"icons",
|
|
717
769
|
"texts"
|
|
718
|
-
]), !
|
|
770
|
+
]), !g.readonly && !g.disabled ? (x(), d(C(i), {
|
|
719
771
|
key: 0,
|
|
720
|
-
"model-value":
|
|
721
|
-
anchor:
|
|
722
|
-
inline:
|
|
772
|
+
"model-value": P.value,
|
|
773
|
+
anchor: at.value?.fieldRef,
|
|
774
|
+
inline: g.inline,
|
|
723
775
|
offset: 8,
|
|
724
776
|
placement: "bottom",
|
|
725
777
|
trigger: "manual",
|
|
726
778
|
arrow: "",
|
|
727
779
|
"non-modal": "",
|
|
728
780
|
spy: "",
|
|
729
|
-
"onUpdate:modelValue":
|
|
781
|
+
"onUpdate:modelValue": ar
|
|
730
782
|
}, {
|
|
731
|
-
default:
|
|
783
|
+
default: E(() => [f(" eslint-disable-next-line vuejs-accessibility/no-static-element-interactions -- Tracks where a pointer press starts; the controls inside take the keyboard "), m("div", {
|
|
732
784
|
ref: "menu",
|
|
733
|
-
class: "q-date-time-picker__menu",
|
|
785
|
+
class: Ce(["q-date-time-picker__menu", { "q-date-time-picker__menu--time-only": N.value }]),
|
|
734
786
|
tabindex: "-1",
|
|
735
|
-
onPointerdownCapture:
|
|
736
|
-
onKeydown:
|
|
787
|
+
onPointerdownCapture: Zn,
|
|
788
|
+
onKeydown: tr
|
|
737
789
|
}, [
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
790
|
+
f(" Calendar View "),
|
|
791
|
+
L.value === "date" ? (x(), p("div", Ae, [
|
|
792
|
+
f(" Header "),
|
|
793
|
+
m("div", je, [
|
|
794
|
+
h(C(a), {
|
|
743
795
|
variant: "ghost",
|
|
744
|
-
disabled: !
|
|
745
|
-
title:
|
|
746
|
-
onClick:
|
|
796
|
+
disabled: !Jt.value,
|
|
797
|
+
title: g.texts.previousMonth,
|
|
798
|
+
onClick: fn
|
|
747
799
|
}, {
|
|
748
|
-
default:
|
|
800
|
+
default: E(() => [h(C(t), b(_(g.icons.back)), null, 16)]),
|
|
749
801
|
_: 1
|
|
750
802
|
}, 8, ["disabled", "title"]),
|
|
751
|
-
|
|
803
|
+
h(C(a), {
|
|
752
804
|
ref: "monthHeader",
|
|
753
805
|
"data-testid": "q-date-time-picker-month-header",
|
|
754
806
|
variant: "ghost",
|
|
755
|
-
label:
|
|
756
|
-
title:
|
|
757
|
-
onClick:
|
|
807
|
+
label: Rt(R.value, 3),
|
|
808
|
+
title: g.texts.pickMonth,
|
|
809
|
+
onClick: vr
|
|
758
810
|
}, null, 8, ["label", "title"]),
|
|
759
|
-
|
|
811
|
+
h(C(a), {
|
|
760
812
|
ref: "yearHeader",
|
|
761
813
|
"data-testid": "q-date-time-picker-year-header",
|
|
762
814
|
variant: "ghost",
|
|
763
|
-
label:
|
|
764
|
-
title:
|
|
765
|
-
onClick:
|
|
815
|
+
label: z.value.toString(),
|
|
816
|
+
title: g.texts.pickYear,
|
|
817
|
+
onClick: yr
|
|
766
818
|
}, null, 8, ["label", "title"]),
|
|
767
|
-
|
|
819
|
+
h(C(a), {
|
|
768
820
|
variant: "ghost",
|
|
769
|
-
disabled: !
|
|
770
|
-
title:
|
|
771
|
-
onClick:
|
|
821
|
+
disabled: !Yt.value,
|
|
822
|
+
title: g.texts.nextMonth,
|
|
823
|
+
onClick: pn
|
|
772
824
|
}, {
|
|
773
|
-
default:
|
|
825
|
+
default: E(() => [h(C(t), b(_(g.icons.forward)), null, 16)]),
|
|
774
826
|
_: 1
|
|
775
827
|
}, 8, ["disabled", "title"])
|
|
776
828
|
]),
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
class: "q-date-time-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
829
|
+
f(" Days Grid: one Tab stop, and the arrow keys move through the days "),
|
|
830
|
+
m("div", {
|
|
831
|
+
role: "grid",
|
|
832
|
+
class: "q-date-time-picker__grid",
|
|
833
|
+
"aria-label": At.value
|
|
834
|
+
}, [
|
|
835
|
+
m("div", Ne, [(x(!0), p(l, null, Te(Dt.value, (e, t) => (x(), p("div", {
|
|
836
|
+
key: e,
|
|
837
|
+
role: "columnheader",
|
|
838
|
+
class: "q-date-time-picker__weekday",
|
|
839
|
+
"aria-label": kt(t)
|
|
840
|
+
}, De(e), 9, Pe))), 128))]),
|
|
841
|
+
f(" eslint-disable-next-line vuejs-accessibility/no-static-element-interactions -- Hover and touch preview of a range; the day buttons inside take the keyboard "),
|
|
842
|
+
m("div", {
|
|
843
|
+
class: "q-date-time-picker__days",
|
|
844
|
+
onMouseleave: on,
|
|
845
|
+
onFocusout: sn,
|
|
846
|
+
onKeydown: Ft,
|
|
847
|
+
onTouchstartPassive: cn,
|
|
848
|
+
onTouchmovePassive: cn
|
|
849
|
+
}, [(x(!0), p(l, null, Te(Ot.value, (e, t) => (x(), p("div", {
|
|
850
|
+
key: t,
|
|
851
|
+
role: "row",
|
|
852
|
+
class: "q-date-time-picker__week"
|
|
853
|
+
}, [(x(!0), p(l, null, Te(e, ({ day: e, index: t }) => (x(), d(C(a), {
|
|
854
|
+
key: t,
|
|
855
|
+
role: "gridcell",
|
|
856
|
+
"data-day-index": t,
|
|
857
|
+
class: Ce(["q-date-time-picker__day", {
|
|
858
|
+
"q-date-time-picker__day--other-month": !e.isCurrentMonth,
|
|
859
|
+
"q-date-time-picker__day--today": e.isToday,
|
|
860
|
+
"q-date-time-picker__day--selected": e.isSelected,
|
|
861
|
+
"q-date-time-picker__day--in-range": e.isInRange,
|
|
862
|
+
"q-date-time-picker__day--range-start": e.isRangeStart,
|
|
863
|
+
"q-date-time-picker__day--range-end": e.isRangeEnd
|
|
864
|
+
}]),
|
|
865
|
+
label: e.date.getDate().toString(),
|
|
866
|
+
"aria-label": jt(e.date),
|
|
867
|
+
"aria-selected": e.isSelected || e.isInRange || e.isRangeEnd,
|
|
868
|
+
"aria-current": e.isToday ? "date" : void 0,
|
|
869
|
+
tabindex: t === Nt.value ? 0 : -1,
|
|
870
|
+
variant: lr(e),
|
|
871
|
+
disabled: e.isDisabled,
|
|
872
|
+
onMouseenter: () => an(e.date),
|
|
873
|
+
onFocus: () => an(e.date),
|
|
874
|
+
onClick: () => ln(e.date)
|
|
875
|
+
}, null, 8, [
|
|
876
|
+
"data-day-index",
|
|
877
|
+
"class",
|
|
878
|
+
"label",
|
|
879
|
+
"aria-label",
|
|
880
|
+
"aria-selected",
|
|
881
|
+
"aria-current",
|
|
882
|
+
"tabindex",
|
|
883
|
+
"variant",
|
|
884
|
+
"disabled",
|
|
885
|
+
"onMouseenter",
|
|
886
|
+
"onFocus",
|
|
887
|
+
"onClick"
|
|
888
|
+
]))), 128))]))), 128))], 32)
|
|
889
|
+
], 8, Me)
|
|
890
|
+
], 512)) : L.value === "time" ? (x(), p(l, { key: 1 }, [f(" Time View "), m("div", Fe, [(x(!0), p(l, null, Te(g.range ? 2 : 1, (e) => (x(), p("div", {
|
|
817
891
|
key: e,
|
|
818
892
|
class: "q-date-time-picker__time-group",
|
|
819
|
-
role:
|
|
820
|
-
"aria-label":
|
|
893
|
+
role: g.range ? "group" : void 0,
|
|
894
|
+
"aria-label": g.range ? e === 1 ? g.texts.startTime : g.texts.endTime : void 0
|
|
821
895
|
}, [
|
|
822
|
-
|
|
823
|
-
"model-value":
|
|
896
|
+
M.value ? (x(), p("div", Le, [h(C(re), {
|
|
897
|
+
"model-value": Cn(e - 1),
|
|
824
898
|
"show-state-labels": "",
|
|
825
899
|
size: "small",
|
|
826
|
-
"aria-label":
|
|
827
|
-
"false-label":
|
|
828
|
-
"true-label":
|
|
829
|
-
"onUpdate:modelValue": (t) =>
|
|
900
|
+
"aria-label": g.texts.pm,
|
|
901
|
+
"false-label": g.texts.am,
|
|
902
|
+
"true-label": g.texts.pm,
|
|
903
|
+
"onUpdate:modelValue": (t) => zn(t ?? !1, e - 1)
|
|
830
904
|
}, null, 8, [
|
|
831
905
|
"model-value",
|
|
832
906
|
"aria-label",
|
|
833
907
|
"false-label",
|
|
834
908
|
"true-label",
|
|
835
909
|
"onUpdate:modelValue"
|
|
836
|
-
])])) :
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
910
|
+
])])) : f("v-if", !0),
|
|
911
|
+
f(" Time Inputs "),
|
|
912
|
+
m("div", Re, [
|
|
913
|
+
m("div", ze, [
|
|
914
|
+
h(C(a), {
|
|
841
915
|
variant: "ghost",
|
|
842
|
-
title:
|
|
843
|
-
"aria-label":
|
|
844
|
-
onClick: (t) =>
|
|
916
|
+
title: g.texts.increaseHour,
|
|
917
|
+
"aria-label": g.texts.increaseHour,
|
|
918
|
+
onClick: (t) => Tn(e - 1)
|
|
845
919
|
}, {
|
|
846
|
-
default:
|
|
920
|
+
default: E(() => [h(C(t), v({ ref_for: !0 }, g.icons.up), null, 16)]),
|
|
847
921
|
_: 1
|
|
848
922
|
}, 8, [
|
|
849
923
|
"title",
|
|
850
924
|
"aria-label",
|
|
851
925
|
"onClick"
|
|
852
926
|
]),
|
|
853
|
-
|
|
927
|
+
h(C(o), {
|
|
854
928
|
class: "q-date-time-picker__time-number",
|
|
855
929
|
size: "small",
|
|
856
930
|
inputmode: "numeric",
|
|
857
|
-
icons:
|
|
858
|
-
texts:
|
|
931
|
+
icons: g.icons,
|
|
932
|
+
texts: g.texts,
|
|
859
933
|
"max-length": 2,
|
|
860
|
-
"aria-label":
|
|
861
|
-
"model-value":
|
|
862
|
-
onKeydown: (t) =>
|
|
863
|
-
"onUpdate:modelValue": (t) =>
|
|
934
|
+
"aria-label": g.texts.hours,
|
|
935
|
+
"model-value": C(he)(bn(e - 1)),
|
|
936
|
+
onKeydown: (t) => Rn(t, "hours", e - 1),
|
|
937
|
+
"onUpdate:modelValue": (t) => Fn(t, e - 1)
|
|
864
938
|
}, null, 8, [
|
|
865
939
|
"icons",
|
|
866
940
|
"texts",
|
|
@@ -869,13 +943,13 @@ var Oe = {
|
|
|
869
943
|
"onKeydown",
|
|
870
944
|
"onUpdate:modelValue"
|
|
871
945
|
]),
|
|
872
|
-
|
|
946
|
+
h(C(a), {
|
|
873
947
|
variant: "ghost",
|
|
874
|
-
title:
|
|
875
|
-
"aria-label":
|
|
876
|
-
onClick: (t) =>
|
|
948
|
+
title: g.texts.decreaseHour,
|
|
949
|
+
"aria-label": g.texts.decreaseHour,
|
|
950
|
+
onClick: (t) => En(e - 1)
|
|
877
951
|
}, {
|
|
878
|
-
default:
|
|
952
|
+
default: E(() => [h(C(t), v({ ref_for: !0 }, g.icons.down), null, 16)]),
|
|
879
953
|
_: 1
|
|
880
954
|
}, 8, [
|
|
881
955
|
"title",
|
|
@@ -883,32 +957,32 @@ var Oe = {
|
|
|
883
957
|
"onClick"
|
|
884
958
|
])
|
|
885
959
|
]),
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
960
|
+
n[1] ||= m("div", { class: "q-date-time-picker__time-separator" }, ":", -1),
|
|
961
|
+
m("div", Be, [
|
|
962
|
+
h(C(a), {
|
|
889
963
|
variant: "ghost",
|
|
890
|
-
title:
|
|
891
|
-
"aria-label":
|
|
892
|
-
onClick: (t) =>
|
|
964
|
+
title: g.texts.increaseMinute,
|
|
965
|
+
"aria-label": g.texts.increaseMinute,
|
|
966
|
+
onClick: (t) => Dn(e - 1)
|
|
893
967
|
}, {
|
|
894
|
-
default:
|
|
968
|
+
default: E(() => [h(C(t), v({ ref_for: !0 }, g.icons.up), null, 16)]),
|
|
895
969
|
_: 1
|
|
896
970
|
}, 8, [
|
|
897
971
|
"title",
|
|
898
972
|
"aria-label",
|
|
899
973
|
"onClick"
|
|
900
974
|
]),
|
|
901
|
-
|
|
975
|
+
h(C(o), {
|
|
902
976
|
class: "q-date-time-picker__time-number",
|
|
903
977
|
size: "small",
|
|
904
978
|
inputmode: "numeric",
|
|
905
|
-
icons:
|
|
906
|
-
texts:
|
|
979
|
+
icons: g.icons,
|
|
980
|
+
texts: g.texts,
|
|
907
981
|
"max-length": 2,
|
|
908
|
-
"aria-label":
|
|
909
|
-
"model-value":
|
|
910
|
-
onKeydown: (t) =>
|
|
911
|
-
"onUpdate:modelValue": (t) =>
|
|
982
|
+
"aria-label": g.texts.minutes,
|
|
983
|
+
"model-value": C(he)(xn(e - 1)),
|
|
984
|
+
onKeydown: (t) => Rn(t, "minutes", e - 1),
|
|
985
|
+
"onUpdate:modelValue": (t) => In(t, e - 1)
|
|
912
986
|
}, null, 8, [
|
|
913
987
|
"icons",
|
|
914
988
|
"texts",
|
|
@@ -917,13 +991,13 @@ var Oe = {
|
|
|
917
991
|
"onKeydown",
|
|
918
992
|
"onUpdate:modelValue"
|
|
919
993
|
]),
|
|
920
|
-
|
|
994
|
+
h(C(a), {
|
|
921
995
|
variant: "ghost",
|
|
922
|
-
title:
|
|
923
|
-
"aria-label":
|
|
924
|
-
onClick: (t) =>
|
|
996
|
+
title: g.texts.decreaseMinute,
|
|
997
|
+
"aria-label": g.texts.decreaseMinute,
|
|
998
|
+
onClick: (t) => On(e - 1)
|
|
925
999
|
}, {
|
|
926
|
-
default:
|
|
1000
|
+
default: E(() => [h(C(t), v({ ref_for: !0 }, g.icons.down), null, 16)]),
|
|
927
1001
|
_: 1
|
|
928
1002
|
}, 8, [
|
|
929
1003
|
"title",
|
|
@@ -931,31 +1005,31 @@ var Oe = {
|
|
|
931
1005
|
"onClick"
|
|
932
1006
|
])
|
|
933
1007
|
]),
|
|
934
|
-
|
|
935
|
-
|
|
1008
|
+
Qe.value ? (x(), p(l, { key: 0 }, [n[0] ||= m("div", { class: "q-date-time-picker__time-separator" }, ":", -1), m("div", Ve, [
|
|
1009
|
+
h(C(a), {
|
|
936
1010
|
variant: "ghost",
|
|
937
|
-
title:
|
|
938
|
-
"aria-label":
|
|
939
|
-
onClick: (t) =>
|
|
1011
|
+
title: g.texts.increaseSecond,
|
|
1012
|
+
"aria-label": g.texts.increaseSecond,
|
|
1013
|
+
onClick: (t) => kn(e - 1)
|
|
940
1014
|
}, {
|
|
941
|
-
default:
|
|
1015
|
+
default: E(() => [h(C(t), v({ ref_for: !0 }, g.icons.up), null, 16)]),
|
|
942
1016
|
_: 1
|
|
943
1017
|
}, 8, [
|
|
944
1018
|
"title",
|
|
945
1019
|
"aria-label",
|
|
946
1020
|
"onClick"
|
|
947
1021
|
]),
|
|
948
|
-
|
|
1022
|
+
h(C(o), {
|
|
949
1023
|
class: "q-date-time-picker__time-number",
|
|
950
1024
|
size: "small",
|
|
951
1025
|
inputmode: "numeric",
|
|
952
|
-
icons:
|
|
953
|
-
texts:
|
|
1026
|
+
icons: g.icons,
|
|
1027
|
+
texts: g.texts,
|
|
954
1028
|
"max-length": 2,
|
|
955
|
-
"aria-label":
|
|
956
|
-
"model-value":
|
|
957
|
-
onKeydown: (t) =>
|
|
958
|
-
"onUpdate:modelValue": (t) =>
|
|
1029
|
+
"aria-label": g.texts.seconds,
|
|
1030
|
+
"model-value": C(he)(Sn(e - 1)),
|
|
1031
|
+
onKeydown: (t) => Rn(t, "seconds", e - 1),
|
|
1032
|
+
"onUpdate:modelValue": (t) => Ln(t, e - 1)
|
|
959
1033
|
}, null, 8, [
|
|
960
1034
|
"icons",
|
|
961
1035
|
"texts",
|
|
@@ -964,127 +1038,128 @@ var Oe = {
|
|
|
964
1038
|
"onKeydown",
|
|
965
1039
|
"onUpdate:modelValue"
|
|
966
1040
|
]),
|
|
967
|
-
|
|
1041
|
+
h(C(a), {
|
|
968
1042
|
variant: "ghost",
|
|
969
|
-
title:
|
|
970
|
-
"aria-label":
|
|
971
|
-
onClick: (t) =>
|
|
1043
|
+
title: g.texts.decreaseSecond,
|
|
1044
|
+
"aria-label": g.texts.decreaseSecond,
|
|
1045
|
+
onClick: (t) => An(e - 1)
|
|
972
1046
|
}, {
|
|
973
|
-
default:
|
|
1047
|
+
default: E(() => [h(C(t), v({ ref_for: !0 }, g.icons.down), null, 16)]),
|
|
974
1048
|
_: 1
|
|
975
1049
|
}, 8, [
|
|
976
1050
|
"title",
|
|
977
1051
|
"aria-label",
|
|
978
1052
|
"onClick"
|
|
979
1053
|
])
|
|
980
|
-
])], 64)) :
|
|
1054
|
+
])], 64)) : f("v-if", !0)
|
|
981
1055
|
])
|
|
982
|
-
], 8,
|
|
1056
|
+
], 8, Ie))), 128))])], 2112)) : L.value === "month" ? (x(), p(l, { key: 2 }, [f(" Month View "), m("div", He, [(x(!0), p(l, null, Te(Lt.value, (e, t) => (x(), d(C(a), {
|
|
983
1057
|
key: t,
|
|
984
1058
|
ref_for: !0,
|
|
985
|
-
ref: (e) =>
|
|
1059
|
+
ref: (e) => mt(e, t),
|
|
986
1060
|
"data-testid": "q-date-time-picker-month-option",
|
|
987
1061
|
"data-month-index": t,
|
|
988
|
-
disabled:
|
|
1062
|
+
"aria-disabled": R.value === t || void 0,
|
|
989
1063
|
label: e,
|
|
990
|
-
title:
|
|
1064
|
+
title: Rt(t),
|
|
991
1065
|
variant: "ghost",
|
|
992
|
-
onClick: () =>
|
|
1066
|
+
onClick: () => un(t)
|
|
993
1067
|
}, null, 8, [
|
|
994
1068
|
"data-month-index",
|
|
995
|
-
"disabled",
|
|
1069
|
+
"aria-disabled",
|
|
996
1070
|
"label",
|
|
997
1071
|
"title",
|
|
998
1072
|
"onClick"
|
|
999
|
-
]))), 128))])], 2112)) :
|
|
1000
|
-
|
|
1073
|
+
]))), 128))])], 2112)) : L.value === "year" ? (x(), p(l, { key: 3 }, [f(" Year View "), m("div", Ue, [m("div", We, [
|
|
1074
|
+
h(C(a), {
|
|
1001
1075
|
variant: "ghost",
|
|
1002
|
-
disabled: !
|
|
1003
|
-
title:
|
|
1004
|
-
onClick:
|
|
1076
|
+
disabled: !Wt.value,
|
|
1077
|
+
title: g.texts.previousYears,
|
|
1078
|
+
onClick: Vt
|
|
1005
1079
|
}, {
|
|
1006
|
-
default:
|
|
1080
|
+
default: E(() => [h(C(t), b(_(g.icons.back)), null, 16)]),
|
|
1007
1081
|
_: 1
|
|
1008
1082
|
}, 8, ["disabled", "title"]),
|
|
1009
|
-
|
|
1010
|
-
|
|
1083
|
+
m("div", Ge, De(Ut.value.startYear) + " - " + De(Ut.value.endYear), 1),
|
|
1084
|
+
h(C(a), {
|
|
1011
1085
|
variant: "ghost",
|
|
1012
|
-
disabled: !
|
|
1013
|
-
title:
|
|
1014
|
-
onClick:
|
|
1086
|
+
disabled: !Gt.value,
|
|
1087
|
+
title: g.texts.nextYears,
|
|
1088
|
+
onClick: Ht
|
|
1015
1089
|
}, {
|
|
1016
|
-
default:
|
|
1090
|
+
default: E(() => [h(C(t), b(_(g.icons.forward)), null, 16)]),
|
|
1017
1091
|
_: 1
|
|
1018
1092
|
}, 8, ["disabled", "title"])
|
|
1019
|
-
]),
|
|
1093
|
+
]), m("div", Ke, [(x(!0), p(l, null, Te(Xt.value, (e, t) => (x(), d(C(a), {
|
|
1020
1094
|
key: t,
|
|
1021
1095
|
ref_for: !0,
|
|
1022
|
-
ref: (t) =>
|
|
1096
|
+
ref: (t) => ht(t, e),
|
|
1023
1097
|
"data-testid": "q-date-time-picker-year-option",
|
|
1024
1098
|
"data-year": e,
|
|
1025
|
-
disabled:
|
|
1099
|
+
"aria-disabled": z.value === e || void 0,
|
|
1026
1100
|
label: e.toString(),
|
|
1027
1101
|
title: e,
|
|
1028
1102
|
variant: "ghost",
|
|
1029
|
-
onClick: () =>
|
|
1103
|
+
onClick: () => dn(e)
|
|
1030
1104
|
}, null, 8, [
|
|
1031
1105
|
"data-year",
|
|
1032
|
-
"disabled",
|
|
1106
|
+
"aria-disabled",
|
|
1033
1107
|
"label",
|
|
1034
1108
|
"title",
|
|
1035
1109
|
"onClick"
|
|
1036
|
-
]))), 128))])])], 2112)) :
|
|
1037
|
-
|
|
1038
|
-
|
|
1110
|
+
]))), 128))])])], 2112)) : f("v-if", !0),
|
|
1111
|
+
m("div", qe, [
|
|
1112
|
+
N.value ? f("v-if", !0) : (x(), d(C(a), {
|
|
1039
1113
|
key: 0,
|
|
1040
1114
|
variant: "ghost",
|
|
1041
|
-
disabled:
|
|
1042
|
-
title:
|
|
1043
|
-
onClick:
|
|
1115
|
+
disabled: $e.value,
|
|
1116
|
+
title: g.texts.today,
|
|
1117
|
+
onClick: mn
|
|
1044
1118
|
}, {
|
|
1045
|
-
default:
|
|
1119
|
+
default: E(() => [h(C(t), b(_(g.icons.today)), null, 16)]),
|
|
1046
1120
|
_: 1
|
|
1047
1121
|
}, 8, ["disabled", "title"])),
|
|
1048
|
-
|
|
1122
|
+
j.value && L.value === "date" ? (x(), d(C(a), {
|
|
1049
1123
|
key: 1,
|
|
1050
1124
|
ref: "toggleTime",
|
|
1051
1125
|
"data-testid": "q-date-time-picker-toggle-time",
|
|
1052
1126
|
variant: "ghost",
|
|
1053
|
-
title:
|
|
1054
|
-
onClick:
|
|
1127
|
+
title: g.texts.toggleMode,
|
|
1128
|
+
onClick: mr
|
|
1055
1129
|
}, {
|
|
1056
|
-
default:
|
|
1130
|
+
default: E(() => [h(C(t), b(_(g.icons.clock)), null, 16)]),
|
|
1057
1131
|
_: 1
|
|
1058
|
-
}, 8, ["title"])) :
|
|
1132
|
+
}, 8, ["title"])) : L.value !== "date" && !N.value ? (x(), d(C(a), {
|
|
1059
1133
|
key: 2,
|
|
1134
|
+
ref: "toggleDate",
|
|
1060
1135
|
"data-testid": "q-date-time-picker-toggle-date",
|
|
1061
1136
|
variant: "ghost",
|
|
1062
|
-
title:
|
|
1063
|
-
onClick:
|
|
1137
|
+
title: g.texts.toggleMode,
|
|
1138
|
+
onClick: _r
|
|
1064
1139
|
}, {
|
|
1065
|
-
default:
|
|
1140
|
+
default: E(() => [h(C(t), b(_(g.icons.calendar)), null, 16)]),
|
|
1066
1141
|
_: 1
|
|
1067
|
-
}, 8, ["title"])) :
|
|
1068
|
-
|
|
1142
|
+
}, 8, ["title"])) : f("v-if", !0),
|
|
1143
|
+
g.clearable ? (x(), d(C(a), {
|
|
1069
1144
|
key: 3,
|
|
1070
1145
|
"data-testid": "q-date-time-picker-clear",
|
|
1071
1146
|
variant: "ghost",
|
|
1072
|
-
disabled: !
|
|
1073
|
-
title:
|
|
1074
|
-
onClick:
|
|
1147
|
+
disabled: !nn.value,
|
|
1148
|
+
title: g.texts.clearValue,
|
|
1149
|
+
onClick: rn
|
|
1075
1150
|
}, {
|
|
1076
|
-
default:
|
|
1151
|
+
default: E(() => [h(C(t), b(_(g.icons.delete)), null, 16)]),
|
|
1077
1152
|
_: 1
|
|
1078
|
-
}, 8, ["disabled", "title"])) :
|
|
1153
|
+
}, 8, ["disabled", "title"])) : f("v-if", !0)
|
|
1079
1154
|
])
|
|
1080
|
-
],
|
|
1155
|
+
], 34)]),
|
|
1081
1156
|
_: 1
|
|
1082
1157
|
}, 8, [
|
|
1083
1158
|
"model-value",
|
|
1084
1159
|
"anchor",
|
|
1085
1160
|
"inline"
|
|
1086
|
-
])) :
|
|
1161
|
+
])) : f("v-if", !0)], 64));
|
|
1087
1162
|
}
|
|
1088
1163
|
});
|
|
1089
1164
|
//#endregion
|
|
1090
|
-
export {
|
|
1165
|
+
export { Je as default };
|