bitboss-ui 3.0.0-beta.48 → 3.0.0-beta.49
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/README.md +24 -7
- package/bin/bitboss-ui-mcp.mjs +15 -3
- package/bin/bitboss-ui.mjs +115 -13
- package/dist/ai/BbAvatar.md +1 -1
- package/dist/ai/BbBreadcrumbs.md +65 -65
- package/dist/ai/BbButton.md +16 -5
- package/dist/ai/BbCheckbox.md +0 -2
- package/dist/ai/BbCheckboxGroup.md +13 -20
- package/dist/ai/BbDatePickerInput.md +4 -2
- package/dist/ai/BbDialog.md +1 -8
- package/dist/ai/BbDropdown.md +231 -220
- package/dist/ai/BbDropdownButton.md +65 -65
- package/dist/ai/BbDropdownGroup.md +2 -2
- package/dist/ai/BbDropzone.md +10 -10
- package/dist/ai/BbForm.md +43 -52
- package/dist/ai/BbHoverCard.md +4 -2
- package/dist/ai/BbNumberInput.md +88 -21
- package/dist/ai/BbPopover.md +29 -23
- package/dist/ai/BbProgress.md +48 -22
- package/dist/ai/BbRadioGroup.md +13 -19
- package/dist/ai/BbSelect.md +16 -36
- package/dist/ai/BbSelectPopover.md +14 -30
- package/dist/ai/BbSmoothHeight.md +0 -2
- package/dist/ai/BbSwitchGroup.md +13 -20
- package/dist/ai/BbTable.md +11 -10
- package/dist/ai/BbTabs.md +106 -105
- package/dist/ai/BbTabsList.md +2 -2
- package/dist/ai/BbTabsPanels.md +1 -1
- package/dist/ai/BbTabsRoot.md +2 -2
- package/dist/ai/BbTooltip.md +24 -10
- package/dist/ai/BbTree.md +14 -11
- package/dist/ai/changelog.json +256 -5
- package/dist/ai/components.json +36 -34
- package/dist/ai/composables/useBbDropdownContext.md +16 -16
- package/dist/ai/composables/useBbFormField.md +5 -1
- package/dist/ai/composables/useBbTabsContext.md +14 -14
- package/dist/ai/guides/agent-contract.md +27 -27
- package/dist/ai/guides/ai-router.md +1 -1
- package/dist/ai/guides/component-picker.md +3 -3
- package/dist/ai/guides/fetch-items-playbook.md +1 -1
- package/dist/ai/guides/icons-policy.md +10 -10
- package/dist/ai/guides/inertia-helpers.md +120 -67
- package/dist/ai/guides/installation-and-plugin-setup.md +43 -15
- package/dist/ai/guides/migration/components/bb-breadcrumbs.md +3 -2
- package/dist/ai/guides/migration/components/bb-checkbox-group.md +16 -16
- package/dist/ai/guides/migration/components/bb-dropdown-button.md +9 -8
- package/dist/ai/guides/migration/components/bb-dropdown.md +15 -14
- package/dist/ai/guides/migration/components/bb-radio-group.md +2 -1
- package/dist/ai/guides/migration/components/bb-select-popover.md +6 -1
- package/dist/ai/guides/migration/components/bb-select.md +10 -2
- package/dist/ai/guides/migration/components/bb-switch-group.md +2 -1
- package/dist/ai/guides/migration/components/bb-tabs.md +9 -8
- package/dist/ai/guides/migration/components/bb-tooltip.md +1 -1
- package/dist/ai/guides/migration/v2-to-v3.md +114 -17
- package/dist/ai/guides/migration/v3-beta-tooling.md +11 -0
- package/dist/ai/guides/options-items-playbook.md +30 -24
- package/dist/ai/guides/passthrough.md +2 -2
- package/dist/ai/guides/preset-components.md +18 -3
- package/dist/ai/guides/typescript-generic-components.md +1 -1
- package/dist/ai/guides/validated-forms.md +11 -22
- package/dist/ai/guides/validation-providers.md +4 -3
- package/dist/ai/helpers/inertia/manifest.json +636 -0
- package/dist/ai/helpers/inertia/types.ts +15 -0
- package/dist/ai/helpers/inertia/useAsyncFn.ts +110 -0
- package/dist/ai/helpers/inertia/useConfirmOnRouteLeave.ts +102 -0
- package/dist/ai/helpers/inertia/useDeleteCmd.ts +30 -0
- package/dist/ai/helpers/inertia/useHasChanged.ts +36 -0
- package/dist/ai/helpers/inertia/useIndexById.ts +23 -0
- package/dist/ai/helpers/inertia/useLazyProp.ts +148 -0
- package/dist/ai/helpers/inertia/useLazyPropGetter.ts +50 -0
- package/dist/ai/helpers/inertia/useLoading.ts +20 -0
- package/dist/ai/helpers/inertia/usePaginatedResponseContext.ts +88 -0
- package/dist/ai/helpers/inertia/usePromiseForm.ts +62 -0
- package/dist/ai/helpers/inertia/useProp.ts +63 -0
- package/dist/ai/helpers/inertia/useQuery.ts +19 -0
- package/dist/ai/helpers/inertia/useQueryObject.ts +116 -0
- package/dist/ai/helpers/inertia/useResourceContext.ts +69 -0
- package/dist/ai/helpers/inertia/useRouteQuery.ts +54 -0
- package/dist/ai/helpers/inertia/useScreenSizes.ts +23 -0
- package/dist/ai/helpers/inertia/useTableContext.ts +34 -0
- package/dist/ai/helpers/inertia/useTableSelectionContext.ts +48 -0
- package/dist/ai/helpers/inertia/useUntil.ts +33 -0
- package/dist/ai/helpers/inertia/utils.ts +24 -0
- package/dist/ai/index.md +6 -6
- package/dist/ai/manifest/components/BbBreadcrumbs.json +10 -6
- package/dist/ai/manifest/components/BbBreadcrumbs.tree.json +1 -1
- package/dist/ai/manifest/components/BbButton.json +1 -1
- package/dist/ai/manifest/components/BbCheckboxGroup.json +2 -2
- package/dist/ai/manifest/components/BbDropdown.json +23 -20
- package/dist/ai/manifest/components/BbDropdown.tree.json +2 -2
- package/dist/ai/manifest/components/BbDropdownButton.json +22 -19
- package/dist/ai/manifest/components/BbDropdownButton.tree.json +1 -1
- package/dist/ai/manifest/components/BbDropdownGroup.json +2 -2
- package/dist/ai/manifest/components/BbForm.json +1 -0
- package/dist/ai/manifest/components/BbNumberInput.json +6 -1
- package/dist/ai/manifest/components/BbNumberInput.tree.json +2 -1
- package/dist/ai/manifest/components/BbPopover.json +1 -0
- package/dist/ai/manifest/components/BbProgress.json +6 -6
- package/dist/ai/manifest/components/BbProgress.tree.json +1 -0
- package/dist/ai/manifest/components/BbRadioGroup.json +2 -2
- package/dist/ai/manifest/components/BbSelect.json +2 -2
- package/dist/ai/manifest/components/BbSelectPopover.json +2 -2
- package/dist/ai/manifest/components/BbSwitchGroup.json +2 -2
- package/dist/ai/manifest/components/BbTabs.json +7 -6
- package/dist/ai/manifest/components/BbTabsList.json +3 -3
- package/dist/ai/manifest/components/BbTabsPanels.json +1 -1
- package/dist/ai/manifest/components/BbTabsRoot.json +5 -4
- package/dist/ai/manifest/components/BbTooltip.json +1 -1
- package/dist/ai/manifest/index.json +2 -2
- package/dist/ai/manifest/meta.json +2 -0
- package/dist/ai/manifest/types.advanced.json +10 -9
- package/dist/ai/manifest/types.api.json +5 -4
- package/dist/ai/recipes/inertia/approvals-inbox.md +16 -18
- package/dist/ai/recipes/inertia/inline-edit-workspace.md +23 -33
- package/dist/ai/recipes/inertia/layout-scaffold.md +16 -16
- package/dist/ai/recipes/inertia/onboarding.md +6 -10
- package/dist/ai/recipes/inertia/ownership-atlas.md +15 -18
- package/dist/ai/recipes/inertia/record-form.md +11 -11
- package/dist/ai/recipes/inertia/records-workspace.md +38 -41
- package/dist/ai/recipes/inertia/settings-workspace.md +26 -38
- package/dist/ai/recipes/inertia/upload-center.md +31 -39
- package/dist/ai/recipes/inertia/wizard-form.md +10 -19
- package/dist/ai/recipes/nuxt/approvals-inbox.md +7 -8
- package/dist/ai/recipes/nuxt/inline-edit-workspace.md +14 -24
- package/dist/ai/recipes/nuxt/layout-scaffold.md +16 -16
- package/dist/ai/recipes/nuxt/onboarding.md +2 -6
- package/dist/ai/recipes/nuxt/ownership-atlas.md +7 -9
- package/dist/ai/recipes/nuxt/record-form.md +5 -5
- package/dist/ai/recipes/nuxt/records-workspace.md +29 -31
- package/dist/ai/recipes/nuxt/settings-workspace.md +22 -34
- package/dist/ai/recipes/nuxt/upload-center.md +22 -29
- package/dist/ai/recipes/nuxt/wizard-form.md +3 -11
- package/dist/ai/recipes/vue/approvals-inbox.md +7 -8
- package/dist/ai/recipes/vue/inline-edit-workspace.md +14 -24
- package/dist/ai/recipes/vue/layout-scaffold.md +16 -16
- package/dist/ai/recipes/vue/onboarding.md +2 -6
- package/dist/ai/recipes/vue/ownership-atlas.md +7 -9
- package/dist/ai/recipes/vue/record-form.md +5 -5
- package/dist/ai/recipes/vue/records-workspace.md +29 -31
- package/dist/ai/recipes/vue/settings-workspace.md +22 -34
- package/dist/ai/recipes/vue/upload-center.md +22 -29
- package/dist/ai/recipes/vue/wizard-form.md +3 -11
- package/dist/ai/source/BbAccordion.md +1 -1
- package/dist/ai/source/BbAlert.md +3 -3
- package/dist/ai/source/BbBadge.md +2 -2
- package/dist/ai/source/BbBadgeButton.md +5 -4
- package/dist/ai/source/BbBaseButton.md +1 -1
- package/dist/ai/source/BbBaseRadioIcon.md +1 -0
- package/dist/ai/source/BbBaseSwitchIcon.md +1 -0
- package/dist/ai/source/BbBreadcrumbs.md +63 -42
- package/dist/ai/source/BbButton.md +71 -33
- package/dist/ai/source/BbCalendar.md +17 -16
- package/dist/ai/source/BbCheckbox.md +3 -2
- package/dist/ai/source/BbCheckboxGroup.md +11 -4
- package/dist/ai/source/BbColorInput.md +10 -9
- package/dist/ai/source/BbConfirm.md +1 -1
- package/dist/ai/source/BbConfirmPortal.md +1 -1
- package/dist/ai/source/BbDatePicker.md +2 -2
- package/dist/ai/source/BbDatePickerInput.md +47 -20
- package/dist/ai/source/BbDialog.md +5 -5
- package/dist/ai/source/BbDropdown.md +230 -158
- package/dist/ai/source/BbDropdownButton.md +19 -12
- package/dist/ai/source/BbDropdownGroup.md +126 -93
- package/dist/ai/source/BbForm.md +25 -1
- package/dist/ai/source/BbIndicator.md +4 -0
- package/dist/ai/source/BbNumberInput.md +855 -19
- package/dist/ai/source/BbOffCanvas.md +27 -11
- package/dist/ai/source/BbPagination.md +3 -3
- package/dist/ai/source/BbPopover.md +152 -8
- package/dist/ai/source/BbPopoverPortal.md +11 -0
- package/dist/ai/source/BbProgress.md +82 -18
- package/dist/ai/source/BbRadioGroup.md +12 -5
- package/dist/ai/source/BbRating.md +11 -9
- package/dist/ai/source/BbSelect.md +16 -10
- package/dist/ai/source/BbSelectPopover.md +29 -23
- package/dist/ai/source/BbSlider.md +12 -6
- package/dist/ai/source/BbSwitch.md +3 -2
- package/dist/ai/source/BbSwitchGroup.md +5 -2
- package/dist/ai/source/BbTable.md +102 -18
- package/dist/ai/source/BbTabs.md +27 -23
- package/dist/ai/source/BbTabsList.md +26 -22
- package/dist/ai/source/BbTabsPanels.md +26 -22
- package/dist/ai/source/BbTabsRoot.md +25 -21
- package/dist/ai/source/BbTag.md +10 -9
- package/dist/ai/source/BbTextInput.md +5 -4
- package/dist/ai/source/BbTextarea.md +6 -5
- package/dist/ai/source/BbTimePicker.md +1 -1
- package/dist/ai/source/BbTimePickerInput.md +46 -9
- package/dist/ai/source/BbToast.md +10 -7
- package/dist/ai/source/BbToastPortal.md +10 -7
- package/dist/ai/source/BbTooltip.md +54 -8
- package/dist/ai/source/BbTree.md +21 -3
- package/dist/ai/source/CommonField.md +6 -4
- package/dist/ai/source/CommonFieldInput.md +15 -10
- package/dist/ai/source/CommonPopover.md +6 -0
- package/dist/ai/source/CommonTimeSelector.md +5 -4
- package/dist/components/BbBadge/BbBadgeButton.vue_vue_type_script_setup_true_lang.js +10 -8
- package/dist/components/BbBaseButton/BbBaseButton.vue_vue_type_script_setup_true_lang.js +8 -8
- package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue_vue_type_script_setup_true_lang.js +45 -45
- package/dist/components/BbBreadcrumbs/types.d.ts +25 -17
- package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +84 -71
- package/dist/components/BbButton/toggleRoving.d.ts +6 -0
- package/dist/components/BbButton/toggleRoving.js +45 -0
- package/dist/components/BbButton/types.d.ts +4 -1
- package/dist/components/BbCalendar/BbCalendar.vue_vue_type_script_setup_true_lang.js +178 -178
- package/dist/components/BbCalendar/CalendarMonthPanel.vue_vue_type_script_setup_true_lang.js +15 -15
- package/dist/components/BbCalendar/CalendarYearPanel.vue_vue_type_script_setup_true_lang.js +28 -28
- package/dist/components/BbCalendar/useCalendarGrid.js +141 -139
- package/dist/components/BbCalendar/useDayjsLocale.d.ts +38 -15
- package/dist/components/BbCalendar/useDayjsLocale.js +31 -30
- package/dist/components/BbCheckbox/BbCheckbox.vue_vue_type_script_setup_true_lang.js +48 -48
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +81 -80
- package/dist/components/BbCheckboxGroup/types.d.ts +6 -2
- package/dist/components/BbColorInput/BbColorInput.vue_vue_type_script_setup_true_lang.js +69 -69
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +363 -349
- package/dist/components/BbDropdown/AdaptiveDropdown.vue_vue_type_script_setup_true_lang.js +91 -86
- package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +298 -289
- package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +322 -356
- package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +17 -15
- package/dist/components/BbDropdown/DropdownRow.vue.d.ts +40 -0
- package/dist/components/BbDropdown/DropdownRow.vue.js +5 -0
- package/dist/components/BbDropdown/DropdownRow.vue_vue_type_script_setup_true_lang.js +60 -0
- package/dist/components/BbDropdown/normalizeGroups.d.ts +8 -2
- package/dist/components/BbDropdown/normalizeGroups.js +60 -46
- package/dist/components/BbDropdown/types.d.ts +119 -88
- package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +11 -2
- package/dist/components/BbDropdownButton/types.d.ts +2 -2
- package/dist/components/BbForm/BbForm.vue.d.ts +9 -0
- package/dist/components/BbForm/BbForm.vue_vue_type_script_setup_true_lang.js +114 -105
- package/dist/components/BbForm/BbFormCustomField.js +1 -1
- package/dist/components/BbForm/bindFormField.js +2 -1
- package/dist/components/BbForm/formFields.d.ts +5 -0
- package/dist/components/BbNumberInput/BbNumberInput.vue.d.ts +0 -1
- package/dist/components/BbNumberInput/BbNumberInput.vue_vue_type_script_setup_true_lang.js +452 -125
- package/dist/components/BbNumberInput/numberDisplay.d.ts +256 -0
- package/dist/components/BbNumberInput/numberDisplay.js +499 -0
- package/dist/components/BbNumberInput/types.d.ts +54 -1
- package/dist/components/BbNumberInput/warroom/corpus.d.ts +58 -0
- package/dist/components/BbNumberInput/warroom/currency-verify.rows.d.ts +28 -0
- package/dist/components/BbNumberInput/warroom/currency.rows.d.ts +2 -0
- package/dist/components/BbNumberInput/warroom/harness.d.ts +217 -0
- package/dist/components/BbNumberInput/warroom/oracle.d.ts +150 -0
- package/dist/components/BbPagination/BbPagination.vue_vue_type_script_setup_true_lang.js +7 -7
- package/dist/components/BbPopover/BbPopover.vue.d.ts +1 -0
- package/dist/components/BbPopover/BbPopover.vue_vue_type_script_setup_true_lang.js +207 -164
- package/dist/components/BbPopover/types.d.ts +11 -0
- package/dist/components/BbProgress/BbProgress.vue_vue_type_script_setup_true_lang.js +15 -7
- package/dist/components/BbProgress/types.d.ts +23 -7
- package/dist/components/BbProgress/types.js +1 -1
- package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +102 -101
- package/dist/components/BbRadioGroup/types.d.ts +6 -2
- package/dist/components/BbRating/BbRating.vue_vue_type_script_setup_true_lang.js +63 -63
- package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +156 -154
- package/dist/components/BbSelect/types.d.ts +6 -2
- package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +2 -1
- package/dist/components/BbSelectPopover/types.d.ts +6 -2
- package/dist/components/BbSlider/BbSlider.vue_vue_type_script_setup_true_lang.js +153 -153
- package/dist/components/BbSwitch/BbSwitch.vue_vue_type_script_setup_true_lang.js +62 -62
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +131 -130
- package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +711 -676
- package/dist/components/BbTabs/BbTabs.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/BbTabs/BbTabsList.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/BbTabs/types.d.ts +25 -21
- package/dist/components/BbTag/BbTag.vue_vue_type_script_setup_true_lang.js +76 -76
- package/dist/components/BbTextInput/BbTextInput.vue_vue_type_script_setup_true_lang.js +58 -58
- package/dist/components/BbTextarea/BbTextarea.vue_vue_type_script_setup_true_lang.js +82 -82
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +246 -236
- package/dist/components/BbTooltip/BbTooltip.vue_vue_type_script_setup_true_lang.js +102 -97
- package/dist/components/BbTooltip/tooltipWarmup.d.ts +23 -0
- package/dist/components/BbTooltip/tooltipWarmup.js +7 -0
- package/dist/components/BbTooltip/types.d.ts +7 -2
- package/dist/components/BbTree/BbTree.vue_vue_type_script_setup_true_lang.js +29 -21
- package/dist/components/BbTree/BbTreeLevel.vue_vue_type_script_setup_true_lang.js +10 -7
- package/dist/components/CommonFieldInput/CommonFieldInput.vue_vue_type_script_setup_true_lang.js +37 -36
- package/dist/components/CommonTimeSelector/CommonTimeSelector.vue_vue_type_script_setup_true_lang.js +9 -9
- package/dist/composables/formSubmitLock.d.ts +6 -0
- package/dist/composables/formSubmitLock.js +4 -0
- package/dist/composables/useBaseOptions.d.ts +7 -1
- package/dist/composables/useBaseOptions.js +32 -32
- package/dist/composables/useBbDropdownContext.d.ts +8 -8
- package/dist/composables/useBbFormField.d.ts +9 -0
- package/dist/composables/useBbFormField.js +5 -3
- package/dist/composables/useBbTabsContext.d.ts +10 -10
- package/dist/composables/useBbTabsContext.js +18 -18
- package/dist/composables/useFormBinding.d.ts +11 -0
- package/dist/composables/useFormBinding.js +15 -13
- package/dist/composables/useItemText.d.ts +5 -1
- package/dist/composables/useItemText.js +8 -3
- package/dist/composables/useItemValue.d.ts +5 -1
- package/dist/composables/useItemValue.js +8 -3
- package/dist/composables/useLocale.js +10 -9
- package/dist/deprecation/ai-deprecations.json.d.ts +130 -0
- package/dist/deprecation/ai-deprecations.json.js +1 -1
- package/dist/deprecation/removedProps.js +1 -1
- package/dist/directives/bbDropdown.js +1 -1
- package/dist/i18n/index.d.ts +7 -12
- package/dist/i18n/locales/cs.json +11 -14
- package/dist/i18n/locales/da.json +13 -16
- package/dist/i18n/locales/de-CH.json +137 -0
- package/dist/i18n/locales/de.json +14 -17
- package/dist/i18n/locales/el.json +10 -13
- package/dist/i18n/locales/en-GB.json +137 -0
- package/dist/i18n/locales/en.json +8 -11
- package/dist/i18n/locales/es-MX.json +137 -0
- package/dist/i18n/locales/es.json +16 -19
- package/dist/i18n/locales/fi.json +8 -11
- package/dist/i18n/locales/fr.json +23 -26
- package/dist/i18n/locales/hu.json +8 -11
- package/dist/i18n/locales/it.json +12 -15
- package/dist/i18n/locales/ja.json +13 -16
- package/dist/i18n/locales/ko.json +10 -13
- package/dist/i18n/locales/nb.json +13 -16
- package/dist/i18n/locales/nl.json +21 -24
- package/dist/i18n/locales/pl.json +10 -13
- package/dist/i18n/locales/{pt.json → pt-BR.json} +19 -22
- package/dist/i18n/locales/pt-PT.json +137 -0
- package/dist/i18n/locales/ro.json +22 -25
- package/dist/i18n/locales/ru.json +11 -14
- package/dist/i18n/locales/sv.json +16 -19
- package/dist/i18n/locales/tr.json +14 -17
- package/dist/i18n/locales/uk.json +11 -14
- package/dist/i18n/locales/{zh-cn.json → zh-CN.json} +10 -13
- package/dist/i18n/locales/zh-HK.json +137 -0
- package/dist/i18n/locales/zh-TW.json +137 -0
- package/dist/i18n/regionHints.d.ts +16 -0
- package/dist/i18n/regionHints.js +49 -0
- package/dist/i18n/regions.d.ts +286 -0
- package/dist/i18n/regions.js +265 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +4 -4
- package/dist/llms-full.txt +1785 -1637
- package/dist/llms-medium.txt +74 -46
- package/dist/llms.txt +7 -7
- package/dist/locale-blueprint.json +16 -13
- package/dist/styles.css +2 -2
- package/dist/types/ptComponentMap.d.ts +1 -1
- package/dist/utilities/functions/slotKey.d.ts +2 -2
- package/dist/utils/versionCheck.js +1 -1
- package/dist/vite-plugin.d.ts +22 -19
- package/dist/vite.js +309 -297
- package/llms.txt +7 -7
- package/package.json +5 -3
- package/scripts/lib/agent-manifest.mjs +2 -1
- package/scripts/lib/eslint-disable.mjs +12 -4
- package/scripts/lib/eslint-plugin.d.ts +5 -1
- package/scripts/lib/eslint-plugin.mjs +187 -6
- package/scripts/lib/helper-canon.mjs +176 -0
- package/scripts/lib/helpers-add.mjs +1303 -0
- package/scripts/lib/local-components.mjs +33 -4
- package/scripts/lib/locale-check.mjs +165 -0
- package/scripts/lib/redundant-item-accessor.mjs +398 -0
- package/scripts/lib/renamed-item-field.mjs +343 -0
- package/scripts/lib/slot-key.mjs +2 -2
- package/scripts/lib/slot-renames.mjs +1 -1
- package/scripts/lib/validate-bb-markup.mjs +123 -56
- package/dist/i18n/index.js +0 -27
package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js
CHANGED
|
@@ -8,28 +8,28 @@ import { removedPropsFor as c } from "../../deprecation/removedProps.js";
|
|
|
8
8
|
import { warnRemovedAttrs as l } from "../../utilities/functions/warnRemovedAttrs.js";
|
|
9
9
|
import { useMobile as u } from "../../composables/useMobile.js";
|
|
10
10
|
import { useLocale as d } from "../../composables/useLocale.js";
|
|
11
|
-
import
|
|
12
|
-
import { formatOfType as
|
|
13
|
-
import { toInnerValue as
|
|
14
|
-
import { useMeridiem as
|
|
15
|
-
import {
|
|
16
|
-
import { normalizeDateBound as
|
|
17
|
-
import { BB_DATE_PICKER_PT as
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import { useFormBinding as
|
|
21
|
-
import
|
|
22
|
-
import { useSegmentedFields as
|
|
23
|
-
import
|
|
24
|
-
import { BB_DATE_PICKER_INPUT_PT as
|
|
25
|
-
import { dateLayoutFromHint as
|
|
26
|
-
import { Fragment as
|
|
27
|
-
import
|
|
28
|
-
import
|
|
29
|
-
import
|
|
30
|
-
import
|
|
11
|
+
import f from "../BbIcon/BbIcon.vue.js";
|
|
12
|
+
import { formatOfType as ee, isCoarseType as te, unitOfType as ne } from "../../types/DatePickerType.js";
|
|
13
|
+
import { toInnerValue as re, toOuterValue as ie } from "../../utilities/functions/convertDateValue.js";
|
|
14
|
+
import { useMeridiem as ae } from "../CommonTimeSelector/useMeridiem.js";
|
|
15
|
+
import { formatDateOf as oe, timeFieldsOf as se, useDayjsLocale as ce } from "../BbCalendar/useDayjsLocale.js";
|
|
16
|
+
import { normalizeDateBound as le } from "../../utilities/functions/normalizeDateBound.js";
|
|
17
|
+
import { BB_DATE_PICKER_PT as ue, DATE_PICKER_CALENDAR_PARTS as de } from "../BbDatePicker/types.js";
|
|
18
|
+
import fe from "../BbDatePicker/BbDatePicker.vue.js";
|
|
19
|
+
import pe from "../CommonField/CommonField.vue.js";
|
|
20
|
+
import { useFormBinding as me } from "../../composables/useFormBinding.js";
|
|
21
|
+
import he from "../CommonFieldInput/CommonFieldInput.vue.js";
|
|
22
|
+
import { useSegmentedFields as ge } from "../../composables/useSegmentedFields.js";
|
|
23
|
+
import _e from "../../assets/svgs/calendar.svg_raw.js";
|
|
24
|
+
import { BB_DATE_PICKER_INPUT_PT as ve } from "./types.js";
|
|
25
|
+
import { dateLayoutFromHint as ye, monthLayoutFromHint as be } from "./dateFieldLayout.js";
|
|
26
|
+
import { Fragment as xe, computed as p, createBlock as Se, createCommentVNode as m, createElementBlock as h, createElementVNode as g, createSlots as Ce, createVNode as we, defineComponent as Te, guardReactiveProps as _, mergeProps as v, normalizeClass as Ee, normalizeProps as y, normalizeStyle as De, onBeforeUnmount as Oe, onDeactivated as ke, openBlock as b, ref as x, renderList as Ae, renderSlot as S, toDisplayString as C, unref as w, useAttrs as je, useSlots as Me, watch as Ne, withCtx as T } from "vue";
|
|
27
|
+
import E from "dayjs";
|
|
28
|
+
import Pe from "dayjs/plugin/customParseFormat";
|
|
29
|
+
import Fe from "dayjs/plugin/isSameOrAfter";
|
|
30
|
+
import Ie from "dayjs/plugin/isSameOrBefore";
|
|
31
31
|
//#region src/components/BbDatePickerInput/BbDatePickerInput.vue?vue&type=script&setup=true&lang.ts
|
|
32
|
-
var
|
|
32
|
+
var Le = ["data-value"], Re = [
|
|
33
33
|
"id",
|
|
34
34
|
"aria-describedby",
|
|
35
35
|
"aria-disabled",
|
|
@@ -52,7 +52,7 @@ var Ie = ["data-value"], Le = [
|
|
|
52
52
|
"onInput",
|
|
53
53
|
"onKeydown",
|
|
54
54
|
"onPaste"
|
|
55
|
-
],
|
|
55
|
+
], ze = ["onClick"], Be = ["disabled"], Ve = ["id"], D = "YYYY-MM-DD", He = "YYYY-MM-DDTHH:mm", Ue = /*@__PURE__*/ Te({
|
|
56
56
|
inheritAttrs: !1,
|
|
57
57
|
__name: "BbDatePickerInput",
|
|
58
58
|
props: {
|
|
@@ -530,148 +530,162 @@ var Ie = ["data-value"], Le = [
|
|
|
530
530
|
"update:modelValue",
|
|
531
531
|
"update:time"
|
|
532
532
|
],
|
|
533
|
-
setup(
|
|
534
|
-
let
|
|
533
|
+
setup(Te, { emit: Ue }) {
|
|
534
|
+
let We = Te, Ge = Ue, Ke = Me(), { props: O, emit: k, showAsterisk: qe, errors: Je, required: Ye, ariaRequired: Xe, model: Ze, readonly: Qe } = me(We, Ge, {
|
|
535
535
|
componentName: "BbDatePickerInput",
|
|
536
|
-
identifierFallback: () =>
|
|
536
|
+
identifierFallback: () => We.label,
|
|
537
537
|
leaveOn: "inactive"
|
|
538
|
-
}),
|
|
538
|
+
}), $e = /^\d{4}-\d{2}-\d{2}(:append)?$/, et = () => Object.keys(Ke).filter((e) => $e.test(e)), tt = o();
|
|
539
539
|
process.env.NODE_ENV !== "production" && l("BbDatePickerInput", c("BbDatePickerInput"), { fixedSlots: ["append:outer"] });
|
|
540
|
-
let
|
|
541
|
-
|
|
542
|
-
},
|
|
543
|
-
|
|
544
|
-
},
|
|
545
|
-
|
|
540
|
+
let A = x(!1), nt = x(!1), rt = () => {
|
|
541
|
+
nt.value = !1;
|
|
542
|
+
}, it = x(!1), at = () => {
|
|
543
|
+
it.value = !0, k("show");
|
|
544
|
+
}, ot = () => {
|
|
545
|
+
it.value = !1, k("hide");
|
|
546
546
|
};
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
}),
|
|
550
|
-
let
|
|
547
|
+
ke(() => {
|
|
548
|
+
A.value ? Nt() : rt();
|
|
549
|
+
}), Oe(rt);
|
|
550
|
+
let st = p(() => O.persistentHint || nt.value), ct = p(() => n(O.modelValue)), lt = p(() => O.labelMode ?? tt.defaultInputLabelMode), ut = [
|
|
551
551
|
"panel",
|
|
552
552
|
"sheet",
|
|
553
|
-
...
|
|
554
|
-
],
|
|
553
|
+
...de
|
|
554
|
+
], j = a({
|
|
555
555
|
component: "BbDatePickerInput",
|
|
556
|
-
attrs:
|
|
556
|
+
attrs: je(),
|
|
557
557
|
controlAttrs: r,
|
|
558
|
-
props:
|
|
559
|
-
parts:
|
|
560
|
-
states:
|
|
558
|
+
props: O,
|
|
559
|
+
parts: ve.parts,
|
|
560
|
+
states: ve.states,
|
|
561
561
|
active: {
|
|
562
|
-
...i(
|
|
563
|
-
open: () =>
|
|
562
|
+
...i(O, () => ct.value),
|
|
563
|
+
open: () => it.value
|
|
564
564
|
}
|
|
565
|
-
}),
|
|
566
|
-
|
|
567
|
-
let { t:
|
|
568
|
-
let n = [e,
|
|
565
|
+
}), M = p(() => O.type === "datetime"), N = p(() => te(O.type)), dt = p(() => O.floating || N.value), P = p(() => ne(O.type)), ft = p(() => ee(O.type));
|
|
566
|
+
E.extend(Pe), E.extend(Fe), E.extend(Ie), ce();
|
|
567
|
+
let { t: F } = d(), I = e(), L = x(null), pt = (e) => `bdpi-description_${e}`, mt = (e, t) => {
|
|
568
|
+
let n = [e, pt(t)].filter((e) => !!e?.trim()).flatMap((e) => e.split(/\s+/)).filter(Boolean);
|
|
569
569
|
return Array.from(new Set(n)).join(" ");
|
|
570
|
-
}, { isMobile:
|
|
571
|
-
!
|
|
572
|
-
},
|
|
570
|
+
}, { isMobile: R } = u(), ht = p(() => O.disableWriting === "mobile" ? !R.value : O.disableWriting === "desktop" ? R.value : !O.disableWriting), gt = p(() => !ht.value && !xt.value && !O.disabled && !O.readonly), _t = () => {
|
|
571
|
+
!gt.value || it.value || (L.value?.$el)?.querySelector(".bb-segmented-field__activator")?.click();
|
|
572
|
+
}, vt = (e) => {
|
|
573
573
|
let t = e.target;
|
|
574
|
-
t?.closest(".bb-field-input__box") && (t.closest(".bb-segmented-field__activator, .bb-clearable-button, .bb-date-picker__panel, [role=\"dialog\"]") ||
|
|
575
|
-
},
|
|
576
|
-
if (
|
|
577
|
-
t.preventDefault(),
|
|
574
|
+
t?.closest(".bb-field-input__box") && (t.closest(".bb-segmented-field__activator, .bb-clearable-button, .bb-date-picker__panel, [role=\"dialog\"]") || _t());
|
|
575
|
+
}, yt = (e) => e.key === "ArrowUp" || e.key === "ArrowDown" || e.key === "Backspace" || e.key === "Delete" || e.key.length === 1 && !e.ctrlKey && !e.metaKey && !e.altKey, bt = (e, t) => {
|
|
576
|
+
if (gt.value && (t.key === "Enter" || t.key === " ")) {
|
|
577
|
+
t.preventDefault(), _t();
|
|
578
578
|
return;
|
|
579
579
|
}
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
let t = T(e, ut.value, !0);
|
|
584
|
-
return t.isValid() ? t : T(e);
|
|
580
|
+
if (O.readonly && yt(t)) {
|
|
581
|
+
t.preventDefault();
|
|
582
|
+
return;
|
|
585
583
|
}
|
|
586
|
-
|
|
587
|
-
},
|
|
588
|
-
|
|
589
|
-
|
|
584
|
+
fn(e, t);
|
|
585
|
+
}, xt = p(() => O.disableCalendar === "mobile" ? R.value : O.disableCalendar === "desktop" ? !R.value : !!O.disableCalendar), St = p(() => !!O.readonly || !ht.value), Ct = (e) => ht.value ? tn.value[e].kind === "enum" ? "none" : "numeric" : "none", z = (e) => e.includes("T"), B = (e) => {
|
|
586
|
+
if (N.value) {
|
|
587
|
+
let t = E(e, ft.value, !0);
|
|
588
|
+
return t.isValid() ? t : E(e);
|
|
589
|
+
}
|
|
590
|
+
return z(e) ? E(e, He, !0) : E(e, D, !0);
|
|
591
|
+
}, wt = p(() => le(O.min, O.type, "min", (e) => I.warn(`BbDatePickerInput: ${e}`))), Tt = p(() => le(O.max, O.type, "max", (e) => I.warn(`BbDatePickerInput: ${e}`)));
|
|
592
|
+
for (let [e, t] of [["min", O.min], ["max", O.max]]) if (t && (B(t).isValid() || I.throw(N.value ? `BbDatePickerInput: ${e} must be a ${ft.value} value (a longer date is accepted and rounded to the ${P.value}) with type="${O.type}"` : `BbDatePickerInput: ${e} must be in the format YYYY-MM-DD or YYYY-MM-DDTHH:mm`), N.value)) {
|
|
593
|
+
e === "min" ? wt.value : Tt.value;
|
|
590
594
|
continue;
|
|
591
595
|
}
|
|
592
|
-
let
|
|
593
|
-
!
|
|
594
|
-
let
|
|
595
|
-
floating:
|
|
596
|
-
utc:
|
|
597
|
-
type:
|
|
598
|
-
})),
|
|
599
|
-
|
|
600
|
-
},
|
|
596
|
+
let Et = O.disableWriting !== !0 && O.disableWriting !== "desktop", Dt = O.disableCalendar !== !0 && O.disableCalendar !== "desktop", Ot = O.disableWriting !== !0 && O.disableWriting !== "mobile", kt = O.disableCalendar !== !0 && O.disableCalendar !== "mobile";
|
|
597
|
+
!Et && !Dt && I.throw("BbDatePickerInput: desktop users would have no interaction method — disableWriting:true (or \"desktop\") and disableCalendar:true (or \"desktop\") cannot be combined."), !Ot && !kt && I.throw("BbDatePickerInput: mobile users would have no interaction method — combine disableWriting:\"mobile\" with disableCalendar:\"desktop\" to keep calendar interaction on mobile while staying keyboard-first on desktop.");
|
|
598
|
+
let At = p(() => ({
|
|
599
|
+
floating: dt.value,
|
|
600
|
+
utc: O.utc,
|
|
601
|
+
type: O.type
|
|
602
|
+
})), V = (e) => ie(e, At.value), jt = (e) => re(e, At.value), Mt = () => {
|
|
603
|
+
A.value || (nt.value = !0, k("active"), A.value = !0, document.addEventListener("focusin", H), document.addEventListener("click", H));
|
|
604
|
+
}, H = (e) => {
|
|
601
605
|
let t = e.target;
|
|
602
|
-
t instanceof HTMLElement &&
|
|
603
|
-
},
|
|
604
|
-
$({ finalize: !0 }),
|
|
605
|
-
},
|
|
606
|
-
let n =
|
|
606
|
+
t instanceof HTMLElement && L.value?.$el && (L.value.$el.contains(t) || Nt());
|
|
607
|
+
}, Nt = () => {
|
|
608
|
+
$({ finalize: !0 }), Ln() && (Fn(), J()), A.value = !1, rt(), k("inactive"), document.removeEventListener("focusin", H), document.removeEventListener("click", H);
|
|
609
|
+
}, Pt = (e, t) => {
|
|
610
|
+
let n = jt(t);
|
|
607
611
|
if (!n.isValid()) return;
|
|
608
|
-
let r =
|
|
612
|
+
let r = K.value[e];
|
|
609
613
|
r.day = n.format("DD"), r.month = n.format("MM"), r.year = n.format("YYYY");
|
|
610
|
-
},
|
|
611
|
-
if (e === null &&
|
|
612
|
-
|
|
614
|
+
}, Ft = { "onUpdate:modelValue": (e) => {
|
|
615
|
+
if (e === null && O.range && (e = []), !M.value) {
|
|
616
|
+
k("update:modelValue", e);
|
|
613
617
|
return;
|
|
614
618
|
}
|
|
615
619
|
if (e === null || Array.isArray(e) && !e.length) {
|
|
616
|
-
|
|
620
|
+
K.value.start = q(), K.value.end = q(), J(), Q(O.range ? [] : null);
|
|
617
621
|
return;
|
|
618
622
|
}
|
|
619
623
|
if (Array.isArray(e)) {
|
|
620
624
|
let [t, n] = e;
|
|
621
|
-
t ?
|
|
625
|
+
t ? Pt("start", t) : K.value.start = q(), n ? Pt("end", n) : K.value.end = q(), J(), $({ finalize: !1 });
|
|
622
626
|
return;
|
|
623
627
|
}
|
|
624
|
-
|
|
625
|
-
} },
|
|
626
|
-
let t =
|
|
628
|
+
Pt("start", e), J(), $({ finalize: !1 });
|
|
629
|
+
} }, It = (e) => {
|
|
630
|
+
let t = K.value[e];
|
|
627
631
|
return !!(t.day && t.month && t.year && t.year.length === 4);
|
|
628
|
-
},
|
|
629
|
-
|
|
630
|
-
},
|
|
631
|
-
let n =
|
|
632
|
-
e === "hour" ?
|
|
633
|
-
},
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
632
|
+
}, Lt = x("start"), Rt = (e, t) => {
|
|
633
|
+
Lt.value = e.segment, pn(e), k("focus", t);
|
|
634
|
+
}, zt = p(() => O.range ? It(Lt.value) ? Lt.value : It("end") ? "end" : "start" : "start"), Bt = ({ unit: e, value: t }) => {
|
|
635
|
+
let n = K.value[zt.value];
|
|
636
|
+
e === "hour" ? xn(n, parseInt(t, 10)) : e === "meridiem" ? n.meridiem = U.label(t === "PM" ? "PM" : "AM") : n[e] = t, n.hour || (O.ampm ? n.hour = "12" : n.hour = "00"), O.ampm && !n.meridiem && (n.meridiem = U.am.value), n.minute ||= "00", O.seconds && !n.second && (n.second = "00"), J(), $({ finalize: !1 });
|
|
637
|
+
}, Vt = p(() => O.type === "year" ? { year: "numeric" } : O.type === "month" ? {
|
|
638
|
+
year: "numeric",
|
|
639
|
+
month: "long"
|
|
640
|
+
} : {
|
|
641
|
+
year: "numeric",
|
|
642
|
+
month: "long",
|
|
643
|
+
day: "numeric"
|
|
644
|
+
}), Ht = (e) => {
|
|
645
|
+
let t = oe(e, tt.locale, Vt.value);
|
|
646
|
+
return M.value ? `${t} ${oe(e, tt.locale, se(!!O.ampm, !!O.seconds))}` : t;
|
|
647
|
+
}, Ut = (e) => {
|
|
648
|
+
if (Y(e) !== "complete") return null;
|
|
649
|
+
let t = K.value[e], n = W.value, r = n.has("day") ? t.day.padStart(2, "0") : "01", i = n.has("month") ? t.month.padStart(2, "0") : "01", a = `${t.year.padStart(4, "0")}-${i}-${r}`, o = D;
|
|
650
|
+
M.value && (a += `T${Vn(e)}`, o += O.seconds ? "THH:mm:ss" : "THH:mm");
|
|
651
|
+
let s = E(a, o, !0);
|
|
638
652
|
return s.isValid() ? s : null;
|
|
639
|
-
},
|
|
640
|
-
if (
|
|
641
|
-
let e =
|
|
642
|
-
return !e || !t ?
|
|
653
|
+
}, Wt = p(() => {
|
|
654
|
+
if (O.range) {
|
|
655
|
+
let e = Ut("start"), t = Ut("end");
|
|
656
|
+
return !e || !t ? F("datePickerInput.emptyRange").value : F("datePickerInput.changeSelectionRange", Ht(e), Ht(t)).value;
|
|
643
657
|
}
|
|
644
|
-
let e =
|
|
645
|
-
return e ?
|
|
646
|
-
}),
|
|
658
|
+
let e = Ut("start");
|
|
659
|
+
return e ? F("datePickerInput.changeSelection", Ht(e)).value : F("datePickerInput.emptySelection").value;
|
|
660
|
+
}), Gt = (e) => {
|
|
647
661
|
if (!e.isValid()) return !0;
|
|
648
|
-
let t = !0, n = (e) =>
|
|
649
|
-
return r && (t &&= e.isSameOrAfter(
|
|
650
|
-
},
|
|
651
|
-
|
|
652
|
-
},
|
|
662
|
+
let t = !0, n = (e) => N.value ? P.value : M.value && z(e) ? "minute" : "day", r = wt.value, i = Tt.value;
|
|
663
|
+
return r && (t &&= e.isSameOrAfter(B(r), n(r))), i && (t &&= e.isSameOrBefore(B(i), n(i))), typeof O.selectable == "function" && (t &&= O.selectable(V(e))), !t;
|
|
664
|
+
}, Kt = () => {
|
|
665
|
+
O.range ? (k("update:modelValue", []), M.value && (Z.value = [], k("update:time", []))) : (k("update:modelValue", null), M.value && (Z.value = null, k("update:time", null)));
|
|
666
|
+
}, qt = /* @__PURE__ */ new Set([
|
|
653
667
|
"hour",
|
|
654
668
|
"minute",
|
|
655
669
|
"second",
|
|
656
670
|
"meridiem"
|
|
657
|
-
]),
|
|
671
|
+
]), U = ae(), Jt = (e, t) => U.isPm(t) ? e === 12 ? 12 : e + 12 : e === 12 ? 0 : e, Yt = (e) => {
|
|
658
672
|
let t = e >= 12 ? "PM" : "AM", n = e % 12;
|
|
659
673
|
return n === 0 && (n = 12), {
|
|
660
674
|
hour: String(n).padStart(2, "0"),
|
|
661
675
|
meridiem: t
|
|
662
676
|
};
|
|
663
|
-
},
|
|
664
|
-
if (
|
|
677
|
+
}, Xt = p(() => {
|
|
678
|
+
if (O.type === "year") return {
|
|
665
679
|
order: ["year"],
|
|
666
680
|
separator: "/"
|
|
667
681
|
};
|
|
668
|
-
let e =
|
|
669
|
-
if (
|
|
682
|
+
let e = F("datePickerInput.monthFormatSingle").value;
|
|
683
|
+
if (O.type === "month") return be(e) ?? {
|
|
670
684
|
order: ["month", "year"],
|
|
671
685
|
separator: "/"
|
|
672
686
|
};
|
|
673
|
-
let t =
|
|
674
|
-
return
|
|
687
|
+
let t = F("datePickerInput.dateFormatSingle").value;
|
|
688
|
+
return ye(t, e) ?? {
|
|
675
689
|
order: [
|
|
676
690
|
"day",
|
|
677
691
|
"month",
|
|
@@ -679,27 +693,27 @@ var Ie = ["data-value"], Le = [
|
|
|
679
693
|
],
|
|
680
694
|
separator: "/"
|
|
681
695
|
};
|
|
682
|
-
}),
|
|
683
|
-
if (!
|
|
696
|
+
}), Zt = p(() => Xt.value.order), W = p(() => new Set(Zt.value)), Qt = p(() => {
|
|
697
|
+
if (!M.value) return [];
|
|
684
698
|
let e = ["hour", "minute"];
|
|
685
|
-
return
|
|
686
|
-
}),
|
|
687
|
-
let e = [...
|
|
699
|
+
return O.seconds && e.push("second"), O.ampm && e.push("meridiem"), e;
|
|
700
|
+
}), G = p(() => {
|
|
701
|
+
let e = [...Zt.value, ...Qt.value], t = e.map((e) => ({
|
|
688
702
|
segment: "start",
|
|
689
703
|
field: e
|
|
690
704
|
}));
|
|
691
|
-
if (!
|
|
705
|
+
if (!O.range) return t;
|
|
692
706
|
let n = e.map((e) => ({
|
|
693
707
|
segment: "end",
|
|
694
708
|
field: e
|
|
695
709
|
}));
|
|
696
710
|
return [...t, ...n];
|
|
697
|
-
}),
|
|
711
|
+
}), $t = p(() => {
|
|
698
712
|
let e = /* @__PURE__ */ new Set(), t = /* @__PURE__ */ new Set();
|
|
699
|
-
return
|
|
713
|
+
return G.value.forEach((n, r) => {
|
|
700
714
|
e.has(n.segment) || (e.add(n.segment), t.add(r));
|
|
701
715
|
}), t;
|
|
702
|
-
}),
|
|
716
|
+
}), en = (e) => $t.value.has(e), tn = p(() => ({
|
|
703
717
|
day: {
|
|
704
718
|
kind: "numeric",
|
|
705
719
|
maxLength: 2,
|
|
@@ -724,7 +738,7 @@ var Ie = ["data-value"], Le = [
|
|
|
724
738
|
requireFullLength: !0,
|
|
725
739
|
label: "Year"
|
|
726
740
|
},
|
|
727
|
-
hour:
|
|
741
|
+
hour: O.ampm ? {
|
|
728
742
|
kind: "numeric",
|
|
729
743
|
maxLength: 2,
|
|
730
744
|
max: 12,
|
|
@@ -756,15 +770,15 @@ var Ie = ["data-value"], Le = [
|
|
|
756
770
|
autoAdvanceFrom: 6,
|
|
757
771
|
label: "Second"
|
|
758
772
|
},
|
|
759
|
-
meridiem:
|
|
760
|
-
})),
|
|
773
|
+
meridiem: U.fieldSpec.value
|
|
774
|
+
})), nn = (e, t) => {
|
|
761
775
|
if (e.segment !== t.segment) return "–";
|
|
762
776
|
if (t.field === "meridiem") return "\xA0";
|
|
763
|
-
let n =
|
|
764
|
-
return n && r ? ":" : !n && r ? "\xA0" :
|
|
765
|
-
}, { fields:
|
|
766
|
-
fieldOrder:
|
|
767
|
-
specs:
|
|
777
|
+
let n = qt.has(e.field), r = qt.has(t.field);
|
|
778
|
+
return n && r ? ":" : !n && r ? "\xA0" : Xt.value.separator;
|
|
779
|
+
}, { fields: K, fieldRefs: rn, descriptorKey: an, emptyFieldGroup: q, getSizedValue: on, minChars: sn, updateAllSizedValues: J, isOwnField: cn, focusField: ln, focusFirstField: un, segmentStatus: Y, onFieldInput: dn, onFieldKeydown: fn, onFieldFocus: pn, onFieldBlur: mn, onFieldPaste: hn } = ge({
|
|
780
|
+
fieldOrder: G,
|
|
781
|
+
specs: tn,
|
|
768
782
|
segments: ["start", "end"],
|
|
769
783
|
fieldKeys: [
|
|
770
784
|
"day",
|
|
@@ -787,20 +801,20 @@ var Ie = ["data-value"], Le = [
|
|
|
787
801
|
" "
|
|
788
802
|
],
|
|
789
803
|
onDirty: () => $({ finalize: !1 })
|
|
790
|
-
}),
|
|
804
|
+
}), gn = (e, t) => {
|
|
791
805
|
if (e.field === "meridiem") {
|
|
792
|
-
let n =
|
|
806
|
+
let n = K.value[e.segment], r = U.match(t.target.value, n.meridiem);
|
|
793
807
|
r && r !== n.meridiem && (n.meridiem = r, $({ finalize: !1 }));
|
|
794
808
|
}
|
|
795
|
-
|
|
809
|
+
dn(e, t);
|
|
796
810
|
};
|
|
797
|
-
|
|
798
|
-
for (let n of Object.values(
|
|
799
|
-
|
|
811
|
+
U.onRelabel((e, t) => {
|
|
812
|
+
for (let n of Object.values(K.value)) n.meridiem === e && (n.meridiem = t);
|
|
813
|
+
J();
|
|
800
814
|
});
|
|
801
|
-
let
|
|
802
|
-
if (
|
|
803
|
-
},
|
|
815
|
+
let _n = (e, t) => O.range ? `${t}-${e.segment}-${e.field}` : `${t}-${e.field}`, vn = (e) => {
|
|
816
|
+
if (O.name) return O.range ? `${O.name}-${e.segment}-${e.field}` : `${O.name}-${e.field}`;
|
|
817
|
+
}, yn = {
|
|
804
818
|
day: "datePickerInput.dayField",
|
|
805
819
|
month: "datePickerInput.monthField",
|
|
806
820
|
year: "datePickerInput.yearField",
|
|
@@ -808,23 +822,23 @@ var Ie = ["data-value"], Le = [
|
|
|
808
822
|
minute: "datePickerInput.minuteField",
|
|
809
823
|
second: "datePickerInput.secondField",
|
|
810
824
|
meridiem: "datePickerInput.meridiemField"
|
|
811
|
-
},
|
|
812
|
-
let t =
|
|
813
|
-
return
|
|
814
|
-
},
|
|
815
|
-
if (!
|
|
825
|
+
}, bn = (e) => {
|
|
826
|
+
let t = F(yn[e.field]).value;
|
|
827
|
+
return O.range ? F(e.segment === "start" ? "datePickerInput.startFieldLabel" : "datePickerInput.endFieldLabel", t).value : t;
|
|
828
|
+
}, xn = (e, t) => {
|
|
829
|
+
if (!O.ampm) {
|
|
816
830
|
e.hour = String(t).padStart(2, "0");
|
|
817
831
|
return;
|
|
818
832
|
}
|
|
819
|
-
let n =
|
|
820
|
-
e.hour = n.hour, e.meridiem =
|
|
821
|
-
},
|
|
833
|
+
let n = Yt(t);
|
|
834
|
+
e.hour = n.hour, e.meridiem = U.label(n.meridiem);
|
|
835
|
+
}, Sn = (e) => {
|
|
822
836
|
if (!e.hour) return 0;
|
|
823
837
|
let t = parseInt(e.hour, 10);
|
|
824
|
-
return
|
|
825
|
-
},
|
|
838
|
+
return O.ampm ? Jt(t, e.meridiem || "AM") : t;
|
|
839
|
+
}, Cn = p(() => O.seconds ? "HH:mm:ss" : "HH:mm"), wn = (e) => e.format(Cn.value), Tn = /^(\d{1,2}):(\d{1,2})(?::(\d{1,2}))?$/, En = (e) => {
|
|
826
840
|
if (!e) return null;
|
|
827
|
-
let t =
|
|
841
|
+
let t = Tn.exec(e);
|
|
828
842
|
if (!t) return null;
|
|
829
843
|
let [, n, r, i] = t;
|
|
830
844
|
return parseInt(n, 10) > 23 || parseInt(r, 10) > 59 || i && parseInt(i, 10) > 59 ? null : {
|
|
@@ -832,177 +846,177 @@ var Ie = ["data-value"], Le = [
|
|
|
832
846
|
minute: r.padStart(2, "0"),
|
|
833
847
|
second: (i ?? "").padStart(i ? 2 : 0, "0")
|
|
834
848
|
};
|
|
835
|
-
},
|
|
836
|
-
if (!
|
|
837
|
-
let n =
|
|
849
|
+
}, Dn = (e, t) => {
|
|
850
|
+
if (!M.value) return;
|
|
851
|
+
let n = En(t);
|
|
838
852
|
if (!n) {
|
|
839
853
|
e.hour = "", e.minute = "", e.second = "", e.meridiem = "";
|
|
840
854
|
return;
|
|
841
855
|
}
|
|
842
|
-
|
|
843
|
-
},
|
|
844
|
-
if (
|
|
845
|
-
let e =
|
|
846
|
-
return
|
|
856
|
+
xn(e, parseInt(n.hour, 10)), e.minute = n.minute, e.second = O.seconds ? n.second : "";
|
|
857
|
+
}, On = p(() => O.seconds ? "datePickerInput.timeFormatSeconds" : "datePickerInput.timeFormat"), kn = p(() => {
|
|
858
|
+
if (O.type === "month" || O.type === "year") {
|
|
859
|
+
let e = O.type === "month" ? "month" : "year";
|
|
860
|
+
return F(O.range ? `datePickerInput.${e}FormatRange` : `datePickerInput.${e}FormatSingle`).value;
|
|
847
861
|
}
|
|
848
|
-
if (!
|
|
849
|
-
let e = `${
|
|
850
|
-
return
|
|
851
|
-
}),
|
|
852
|
-
if (!e) return
|
|
853
|
-
let t =
|
|
854
|
-
if (!t.isValid()) return
|
|
855
|
-
let n =
|
|
856
|
-
return
|
|
857
|
-
},
|
|
862
|
+
if (!M.value) return F(O.range ? "datePickerInput.dateFormatRange" : "datePickerInput.dateFormatSingle").value;
|
|
863
|
+
let e = `${F("datePickerInput.dateFormatSingle").value} ${F(On.value).value}`;
|
|
864
|
+
return O.range ? `${e} – ${e}` : e;
|
|
865
|
+
}), An = p(() => O.placeholder || kn.value), jn = p(() => G.value.every((e) => !K.value[e.segment][e.field])), Mn = (e) => {
|
|
866
|
+
if (!e) return q();
|
|
867
|
+
let t = jt(e);
|
|
868
|
+
if (!t.isValid()) return q();
|
|
869
|
+
let n = q();
|
|
870
|
+
return W.value.has("day") && (n.day = t.format("DD")), W.value.has("month") && (n.month = t.format("MM")), n.year = t.format("YYYY"), M.value && !O.floating && (xn(n, t.hour()), n.minute = t.format("mm"), n.second = O.seconds ? t.format("ss") : ""), n;
|
|
871
|
+
}, Nn = (e) => Array.isArray(O.time) ? O.time[e === "start" ? 0 : 1] : e === "start" ? O.time : void 0, Pn = (e) => {
|
|
858
872
|
if (!e) {
|
|
859
|
-
|
|
860
|
-
start:
|
|
861
|
-
end:
|
|
873
|
+
K.value = {
|
|
874
|
+
start: q(),
|
|
875
|
+
end: q()
|
|
862
876
|
};
|
|
863
877
|
return;
|
|
864
878
|
}
|
|
865
|
-
if (
|
|
879
|
+
if (O.range) {
|
|
866
880
|
let [t, n] = Array.isArray(e) ? e : [];
|
|
867
|
-
|
|
868
|
-
start:
|
|
869
|
-
end:
|
|
881
|
+
K.value = {
|
|
882
|
+
start: Mn(t),
|
|
883
|
+
end: Mn(n)
|
|
870
884
|
};
|
|
871
|
-
} else Array.isArray(e) ?
|
|
872
|
-
start:
|
|
873
|
-
end:
|
|
874
|
-
} :
|
|
875
|
-
start:
|
|
876
|
-
end:
|
|
885
|
+
} else Array.isArray(e) ? K.value = {
|
|
886
|
+
start: q(),
|
|
887
|
+
end: q()
|
|
888
|
+
} : K.value = {
|
|
889
|
+
start: Mn(e),
|
|
890
|
+
end: q()
|
|
877
891
|
};
|
|
878
|
-
if (
|
|
879
|
-
let t =
|
|
880
|
-
t.day &&
|
|
892
|
+
if (M.value && O.floating) for (let e of ["start", "end"]) {
|
|
893
|
+
let t = K.value[e];
|
|
894
|
+
t.day && Dn(t, Nn(e));
|
|
881
895
|
}
|
|
882
|
-
},
|
|
883
|
-
|
|
896
|
+
}, Fn = () => {
|
|
897
|
+
Pn(O.modelValue);
|
|
884
898
|
};
|
|
885
|
-
|
|
886
|
-
let
|
|
887
|
-
if (!
|
|
899
|
+
Pn(O.modelValue), J();
|
|
900
|
+
let In = (e) => {
|
|
901
|
+
if (!M.value || O.floating) return;
|
|
888
902
|
let t;
|
|
889
|
-
t = e ? Array.isArray(e) ? e.map((e) =>
|
|
903
|
+
t = e ? Array.isArray(e) ? e.map((e) => wn(jt(e))) : wn(jt(e)) : null, Z.value = t, k("update:time", t);
|
|
890
904
|
};
|
|
891
|
-
|
|
905
|
+
Ne(() => O.modelValue, (e) => {
|
|
892
906
|
if (e === null || Array.isArray(e) && e.length === 0) {
|
|
893
|
-
|
|
907
|
+
Pn(e), J(), In(e);
|
|
894
908
|
return;
|
|
895
909
|
}
|
|
896
910
|
let t = document.activeElement;
|
|
897
|
-
t &&
|
|
898
|
-
}),
|
|
899
|
-
if (!
|
|
911
|
+
t && cn(t) || (Pn(e), J(), In(e));
|
|
912
|
+
}), Ne(() => O.time, (e) => {
|
|
913
|
+
if (!M.value || s(e ?? null) === s(Z.value ?? null)) return;
|
|
900
914
|
let t = document.activeElement;
|
|
901
|
-
if (!(t &&
|
|
915
|
+
if (!(t && cn(t))) {
|
|
902
916
|
for (let e of ["start", "end"]) {
|
|
903
|
-
if (e === "end" && !
|
|
904
|
-
let t =
|
|
905
|
-
t !== void 0 &&
|
|
917
|
+
if (e === "end" && !O.range) break;
|
|
918
|
+
let t = Nn(e), n = K.value[e];
|
|
919
|
+
t !== void 0 && Dn(n, t);
|
|
906
920
|
}
|
|
907
|
-
|
|
921
|
+
J(), $({ finalize: !1 });
|
|
908
922
|
}
|
|
909
923
|
});
|
|
910
|
-
let
|
|
911
|
-
let t =
|
|
924
|
+
let Ln = () => Y("start") === "partial" ? !0 : O.range ? Y("end") === "partial" : !1, Rn = (e) => {
|
|
925
|
+
let t = K.value[e], n = W.value;
|
|
912
926
|
if (n.has("day") && !t.day || n.has("month") && !t.month || !t.year) return null;
|
|
913
927
|
let r = n.has("day") ? parseInt(t.day, 10) : 1, i = n.has("month") ? parseInt(t.month, 10) : 1, a = parseInt(t.year, 10);
|
|
914
928
|
if (r < 1 || r > 31 || i < 1 || i > 12 || a < 1e3 || a > 9999) return null;
|
|
915
929
|
let o = t.year.padStart(4, "0"), s = String(i).padStart(2, "0"), c = String(r).padStart(2, "0"), l = "", u = "";
|
|
916
|
-
if (
|
|
917
|
-
if (
|
|
930
|
+
if (M.value) {
|
|
931
|
+
if (O.ampm && t.hour) {
|
|
918
932
|
let e = parseInt(t.hour, 10);
|
|
919
933
|
if (e < 1 || e > 12) return null;
|
|
920
934
|
}
|
|
921
|
-
let e = String(
|
|
935
|
+
let e = String(Sn(t)).padStart(2, "0"), n = (t.minute || "0").padStart(2, "0"), r = ((O.seconds ? t.second : "") || "0").padStart(2, "0");
|
|
922
936
|
if (parseInt(e, 10) > 23 || parseInt(n, 10) > 59 || parseInt(r, 10) > 59) return null;
|
|
923
937
|
l = `T${e}:${n}:${r}`, u = "THH:mm:ss";
|
|
924
938
|
}
|
|
925
|
-
let d =
|
|
939
|
+
let d = E(`${o}-${s}-${c}${l}`, D + u, !0);
|
|
926
940
|
if (!d.isValid()) {
|
|
927
|
-
let t =
|
|
928
|
-
d =
|
|
941
|
+
let t = E(`${o}-${s}-01`, D, !0).endOf("month").date(), n = Math.min(r, t);
|
|
942
|
+
d = E(`${o}-${s}-${String(n).padStart(2, "0")}${l}`, D + u, !0), K.value[e].day = String(n).padStart(2, "0");
|
|
929
943
|
}
|
|
930
944
|
return d.isValid() ? d : null;
|
|
931
|
-
},
|
|
932
|
-
let t =
|
|
933
|
-
return
|
|
934
|
-
},
|
|
935
|
-
let t = (t, n) =>
|
|
945
|
+
}, zn = (e) => {
|
|
946
|
+
let t = q();
|
|
947
|
+
return W.value.has("day") && (t.day = e.format("DD")), W.value.has("month") && (t.month = e.format("MM")), t.year = e.format("YYYY"), M.value && (xn(t, e.hour()), t.minute = e.format("mm"), t.second = O.seconds ? e.format("ss") : ""), t;
|
|
948
|
+
}, Bn = (e) => {
|
|
949
|
+
let t = (t, n) => M.value && !n ? t.hour(e.hour()).minute(e.minute()).second(e.second()) : t, n = N.value ? P.value : M.value ? "minute" : "day", r = e, i = wt.value, a = Tt.value;
|
|
936
950
|
if (i) {
|
|
937
|
-
let e =
|
|
938
|
-
r.isBefore(n,
|
|
951
|
+
let e = z(i), n = B(i);
|
|
952
|
+
r.isBefore(n, N.value ? P.value : M.value && e ? "minute" : "day") && (r = N.value ? n : t(n, e));
|
|
939
953
|
}
|
|
940
954
|
if (a) {
|
|
941
|
-
let e =
|
|
942
|
-
r.isAfter(n,
|
|
955
|
+
let e = z(a), n = B(a);
|
|
956
|
+
r.isAfter(n, N.value ? P.value : M.value && e ? "minute" : "day") && (r = N.value ? n.startOf(P.value) : t(n, e));
|
|
943
957
|
}
|
|
944
|
-
return r.isSame(e, n) ||
|
|
958
|
+
return r.isSame(e, n) || Gt(r) ? null : r;
|
|
945
959
|
}, X = (e) => {
|
|
946
|
-
|
|
947
|
-
},
|
|
948
|
-
let t =
|
|
949
|
-
return
|
|
950
|
-
}, Z =
|
|
951
|
-
if (
|
|
960
|
+
k("error", e);
|
|
961
|
+
}, Vn = (e) => {
|
|
962
|
+
let t = K.value[e], n = String(Sn(t)).padStart(2, "0"), r = (t.minute || "0").padStart(2, "0");
|
|
963
|
+
return O.seconds ? `${n}:${r}:${(t.second || "0").padStart(2, "0")}` : `${n}:${r}`;
|
|
964
|
+
}, Z = x(void 0), Q = (e) => {
|
|
965
|
+
if (k("update:modelValue", e), !M.value) return;
|
|
952
966
|
let t;
|
|
953
|
-
t = e === null ? null : Array.isArray(e) ? e.map((e, t) =>
|
|
967
|
+
t = e === null ? null : Array.isArray(e) ? e.map((e, t) => Vn(t === 0 ? "start" : "end")) : Vn("start"), Z.value = t, k("update:time", t);
|
|
954
968
|
}, $ = (e = {}) => {
|
|
955
|
-
let t = !!e.finalize, n =
|
|
956
|
-
if (!
|
|
969
|
+
let t = !!e.finalize, n = Y("start");
|
|
970
|
+
if (!O.range) {
|
|
957
971
|
if (n === "empty") {
|
|
958
972
|
Q(null);
|
|
959
973
|
return;
|
|
960
974
|
}
|
|
961
975
|
if (n === "partial") return;
|
|
962
|
-
let e =
|
|
976
|
+
let e = Rn("start");
|
|
963
977
|
if (!e) return;
|
|
964
|
-
if (
|
|
978
|
+
if (Gt(e)) {
|
|
965
979
|
if (!t) return;
|
|
966
|
-
let n =
|
|
980
|
+
let n = V(e), r = Bn(e);
|
|
967
981
|
if (r) {
|
|
968
|
-
let e =
|
|
969
|
-
|
|
982
|
+
let e = V(r);
|
|
983
|
+
K.value.start = zn(r), Q(e), X({
|
|
970
984
|
code: "disabled_date",
|
|
971
985
|
original: n,
|
|
972
986
|
normalized: e
|
|
973
987
|
});
|
|
974
|
-
} else
|
|
988
|
+
} else K.value.start = q(), Q(null), X({
|
|
975
989
|
code: "disabled_date",
|
|
976
990
|
original: n,
|
|
977
991
|
normalized: null
|
|
978
992
|
});
|
|
979
993
|
return;
|
|
980
994
|
}
|
|
981
|
-
Q(
|
|
995
|
+
Q(V(e));
|
|
982
996
|
return;
|
|
983
997
|
}
|
|
984
|
-
let r =
|
|
998
|
+
let r = Y("end");
|
|
985
999
|
if (n === "empty" && r === "empty") {
|
|
986
1000
|
Q([]);
|
|
987
1001
|
return;
|
|
988
1002
|
}
|
|
989
1003
|
if (n === "partial" || r === "partial" || n === "empty") return;
|
|
990
|
-
let i =
|
|
1004
|
+
let i = Rn("start");
|
|
991
1005
|
if (!i) return;
|
|
992
|
-
let a = r === "empty" ? null :
|
|
993
|
-
if (
|
|
1006
|
+
let a = r === "empty" ? null : Rn("end"), o = V(i), s = a ? V(a) : null, c = i, l = !1;
|
|
1007
|
+
if (Gt(i)) {
|
|
994
1008
|
if (!t) return;
|
|
995
|
-
let e =
|
|
1009
|
+
let e = Bn(i), n = s ? [o, s] : [o];
|
|
996
1010
|
if (!e) {
|
|
997
|
-
|
|
1011
|
+
K.value.start = q(), K.value.end = q(), Q([]), X({
|
|
998
1012
|
code: "disabled_range_start",
|
|
999
1013
|
original: n,
|
|
1000
1014
|
normalized: []
|
|
1001
1015
|
});
|
|
1002
1016
|
return;
|
|
1003
1017
|
}
|
|
1004
|
-
if (c = e, l = !0,
|
|
1005
|
-
let t = [
|
|
1018
|
+
if (c = e, l = !0, K.value.start = zn(e), !a) {
|
|
1019
|
+
let t = [V(e)];
|
|
1006
1020
|
Q(t), X({
|
|
1007
1021
|
code: "disabled_range_start",
|
|
1008
1022
|
original: n,
|
|
@@ -1012,16 +1026,16 @@ var Ie = ["data-value"], Le = [
|
|
|
1012
1026
|
}
|
|
1013
1027
|
}
|
|
1014
1028
|
if (!a) {
|
|
1015
|
-
Q([
|
|
1029
|
+
Q([V(c)]);
|
|
1016
1030
|
return;
|
|
1017
1031
|
}
|
|
1018
1032
|
let u = a, d = !1;
|
|
1019
|
-
if (
|
|
1033
|
+
if (Gt(a)) {
|
|
1020
1034
|
if (!t) return;
|
|
1021
|
-
let e =
|
|
1035
|
+
let e = Bn(a), n = [o, s];
|
|
1022
1036
|
if (!e) {
|
|
1023
|
-
let e = [
|
|
1024
|
-
|
|
1037
|
+
let e = [V(c)];
|
|
1038
|
+
K.value.end = q(), Q(e), l && X({
|
|
1025
1039
|
code: "disabled_range_start",
|
|
1026
1040
|
original: n,
|
|
1027
1041
|
normalized: e
|
|
@@ -1032,12 +1046,12 @@ var Ie = ["data-value"], Le = [
|
|
|
1032
1046
|
});
|
|
1033
1047
|
return;
|
|
1034
1048
|
}
|
|
1035
|
-
u = e, d = !0,
|
|
1049
|
+
u = e, d = !0, K.value.end = zn(e);
|
|
1036
1050
|
}
|
|
1037
|
-
if (u.isBefore(c,
|
|
1051
|
+
if (u.isBefore(c, M.value ? "second" : "day")) {
|
|
1038
1052
|
if (!t) return;
|
|
1039
|
-
let e = [
|
|
1040
|
-
|
|
1053
|
+
let e = [V(c), V(u)], n = [V(u), V(c)], r = { ...K.value.start };
|
|
1054
|
+
K.value.start = { ...K.value.end }, K.value.end = r, J(), Q(n), l && X({
|
|
1041
1055
|
code: "disabled_range_start",
|
|
1042
1056
|
original: [o, s],
|
|
1043
1057
|
normalized: n
|
|
@@ -1052,88 +1066,88 @@ var Ie = ["data-value"], Le = [
|
|
|
1052
1066
|
});
|
|
1053
1067
|
return;
|
|
1054
1068
|
}
|
|
1055
|
-
let
|
|
1056
|
-
Q(
|
|
1069
|
+
let f = [V(c), V(u)];
|
|
1070
|
+
Q(f), l && X({
|
|
1057
1071
|
code: "disabled_range_start",
|
|
1058
1072
|
original: s ? [o, s] : [o],
|
|
1059
|
-
normalized:
|
|
1073
|
+
normalized: f
|
|
1060
1074
|
}), d && X({
|
|
1061
1075
|
code: "disabled_range_end",
|
|
1062
1076
|
original: [o, s],
|
|
1063
|
-
normalized:
|
|
1077
|
+
normalized: f
|
|
1064
1078
|
});
|
|
1065
1079
|
};
|
|
1066
|
-
return
|
|
1067
|
-
document.removeEventListener("focusin",
|
|
1068
|
-
}), (e, n) => (
|
|
1080
|
+
return Oe(() => {
|
|
1081
|
+
document.removeEventListener("focusin", H), document.removeEventListener("click", H);
|
|
1082
|
+
}), (e, n) => (b(), Se(pe, v({
|
|
1069
1083
|
id: e.id,
|
|
1070
1084
|
class: "bb-date-picker-input",
|
|
1071
|
-
clearable: e.clearable &&
|
|
1085
|
+
clearable: e.clearable && ct.value,
|
|
1072
1086
|
compact: e.compact,
|
|
1073
1087
|
description: e.description,
|
|
1074
1088
|
disabled: e.disabled,
|
|
1075
|
-
errors:
|
|
1089
|
+
errors: w(Je),
|
|
1076
1090
|
"has-errors": e.hasErrors,
|
|
1077
|
-
"has-value":
|
|
1091
|
+
"has-value": ct.value,
|
|
1078
1092
|
"has-warnings": e.hasWarnings,
|
|
1079
1093
|
"hide-label": e.hideLabel,
|
|
1080
1094
|
hint: e.hint,
|
|
1081
1095
|
"input-align": e.inputAlign,
|
|
1082
1096
|
label: e.label,
|
|
1083
1097
|
"label-align": e.labelAlign,
|
|
1084
|
-
"label-mode":
|
|
1098
|
+
"label-mode": lt.value,
|
|
1085
1099
|
"label-position": e.labelPosition,
|
|
1086
1100
|
layout: e.layout,
|
|
1087
1101
|
loading: e.loading,
|
|
1088
1102
|
name: e.name,
|
|
1089
|
-
passthrough:
|
|
1090
|
-
readonly:
|
|
1103
|
+
passthrough: w(j),
|
|
1104
|
+
readonly: w(Qe),
|
|
1091
1105
|
reverse: e.reverse,
|
|
1092
|
-
"show-asterisk":
|
|
1093
|
-
"show-hint":
|
|
1106
|
+
"show-asterisk": w(qe),
|
|
1107
|
+
"show-hint": st.value,
|
|
1094
1108
|
warnings: e.warnings
|
|
1095
|
-
},
|
|
1096
|
-
label:
|
|
1097
|
-
input:
|
|
1109
|
+
}, w(j).forwardAttrs), Ce({
|
|
1110
|
+
label: T((t) => [S(e.$slots, "label", y(_(t)))]),
|
|
1111
|
+
input: T(({ id: r, hasErrors: i, hasWarnings: a, ariaDescribedby: o }) => [we(he, {
|
|
1098
1112
|
ref_key: "wrapper",
|
|
1099
|
-
ref:
|
|
1100
|
-
active:
|
|
1101
|
-
"append:icon":
|
|
1102
|
-
class:
|
|
1103
|
-
clearable: e.clearable && !
|
|
1113
|
+
ref: L,
|
|
1114
|
+
active: A.value,
|
|
1115
|
+
"append:icon": w(O)["append:icon"],
|
|
1116
|
+
class: Ee(["bb-date-picker-input__field", { "bb-date-picker-input__field--range": e.range }]),
|
|
1117
|
+
clearable: e.clearable && !w(t)(w(Ze)),
|
|
1104
1118
|
compact: e.compact,
|
|
1105
1119
|
disabled: e.disabled,
|
|
1106
1120
|
"has-errors": i,
|
|
1107
|
-
"has-value":
|
|
1121
|
+
"has-value": ct.value,
|
|
1108
1122
|
"has-warnings": a,
|
|
1109
1123
|
loading: e.loading,
|
|
1110
|
-
passthrough:
|
|
1111
|
-
"prepend:icon":
|
|
1112
|
-
readonly:
|
|
1124
|
+
passthrough: w(j),
|
|
1125
|
+
"prepend:icon": w(O)["prepend:icon"],
|
|
1126
|
+
readonly: w(Qe),
|
|
1113
1127
|
variant: e.variant,
|
|
1114
|
-
onClick:
|
|
1115
|
-
"onClick:clear":
|
|
1116
|
-
onFocusin:
|
|
1117
|
-
},
|
|
1118
|
-
"prepend:outer":
|
|
1119
|
-
prepend:
|
|
1120
|
-
append:
|
|
1128
|
+
onClick: vt,
|
|
1129
|
+
"onClick:clear": Kt,
|
|
1130
|
+
onFocusin: Mt
|
|
1131
|
+
}, Ce({
|
|
1132
|
+
"prepend:outer": T(() => [S(e.$slots, "prepend:outer")]),
|
|
1133
|
+
prepend: T(() => [S(e.$slots, "prepend")]),
|
|
1134
|
+
append: T(() => [xt.value ? m("", !0) : (b(), Se(fe, {
|
|
1121
1135
|
key: 0,
|
|
1122
|
-
"active-segment":
|
|
1136
|
+
"active-segment": zt.value,
|
|
1123
1137
|
adaptive: e.adaptive,
|
|
1124
1138
|
ampm: e.ampm,
|
|
1125
|
-
anchor:
|
|
1139
|
+
anchor: L.value,
|
|
1126
1140
|
disabled: e.disabled,
|
|
1127
1141
|
"first-day-of-week": e.firstDayOfWeek,
|
|
1128
1142
|
floating: e.floating,
|
|
1129
|
-
label:
|
|
1143
|
+
label: Wt.value,
|
|
1130
1144
|
max: e.max,
|
|
1131
1145
|
min: e.min,
|
|
1132
|
-
"model-value":
|
|
1146
|
+
"model-value": w(Ze),
|
|
1133
1147
|
"off-canvas-props": e.offCanvasProps,
|
|
1134
|
-
pt:
|
|
1148
|
+
pt: w(j).forward(ut, w(ue).states),
|
|
1135
1149
|
range: e.range,
|
|
1136
|
-
readonly:
|
|
1150
|
+
readonly: w(Qe),
|
|
1137
1151
|
seconds: e.seconds,
|
|
1138
1152
|
selectable: e.selectable,
|
|
1139
1153
|
step: e.step,
|
|
@@ -1141,27 +1155,27 @@ var Ie = ["data-value"], Le = [
|
|
|
1141
1155
|
"transition-duration": e.transitionDuration,
|
|
1142
1156
|
type: e.type,
|
|
1143
1157
|
utc: e.utc,
|
|
1144
|
-
onGridPick:
|
|
1145
|
-
onHidden: n[1] ||= (e) =>
|
|
1146
|
-
onHide:
|
|
1147
|
-
onShow:
|
|
1148
|
-
onShown: n[2] ||= (e) =>
|
|
1149
|
-
onTimePick:
|
|
1150
|
-
},
|
|
1151
|
-
activator:
|
|
1158
|
+
onGridPick: Ft["onUpdate:modelValue"],
|
|
1159
|
+
onHidden: n[1] ||= (e) => w(k)("hidden"),
|
|
1160
|
+
onHide: ot,
|
|
1161
|
+
onShow: at,
|
|
1162
|
+
onShown: n[2] ||= (e) => w(k)("shown"),
|
|
1163
|
+
onTimePick: Bt
|
|
1164
|
+
}, Ce({
|
|
1165
|
+
activator: T(({ props: t }) => [g("button", v({
|
|
1152
1166
|
class: "bb-segmented-field__activator",
|
|
1153
|
-
disabled: e.disabled ||
|
|
1167
|
+
disabled: e.disabled || w(Qe),
|
|
1154
1168
|
type: "button"
|
|
1155
|
-
},
|
|
1169
|
+
}, v(t, w(j).activator)), [we(f, {
|
|
1156
1170
|
class: "bb-segmented-field__trigger-icon",
|
|
1157
|
-
icon:
|
|
1158
|
-
}, null, 8, ["icon"])], 16,
|
|
1159
|
-
day:
|
|
1160
|
-
"day:append":
|
|
1171
|
+
icon: w(_e)
|
|
1172
|
+
}, null, 8, ["icon"])], 16, Be)]),
|
|
1173
|
+
day: T((t) => [S(e.$slots, "day", y(_(t)))]),
|
|
1174
|
+
"day:append": T((t) => [S(e.$slots, "day:append", y(_(t)))]),
|
|
1161
1175
|
_: 2
|
|
1162
|
-
}, [
|
|
1176
|
+
}, [Ae(et(), (t) => ({
|
|
1163
1177
|
name: t,
|
|
1164
|
-
fn:
|
|
1178
|
+
fn: T((n) => [S(e.$slots, t, y(_(n)))])
|
|
1165
1179
|
}))]), 1032, [
|
|
1166
1180
|
"active-segment",
|
|
1167
1181
|
"adaptive",
|
|
@@ -1186,67 +1200,67 @@ var Ie = ["data-value"], Le = [
|
|
|
1186
1200
|
"type",
|
|
1187
1201
|
"utc",
|
|
1188
1202
|
"onGridPick"
|
|
1189
|
-
])),
|
|
1203
|
+
])), S(e.$slots, "append", {}, () => [e.$slots.suffix ? (b(), h("span", v({
|
|
1190
1204
|
key: 0,
|
|
1191
1205
|
class: "bb-field-input__suffix"
|
|
1192
|
-
},
|
|
1193
|
-
"append:outer":
|
|
1194
|
-
default:
|
|
1195
|
-
class:
|
|
1196
|
-
"bb-segmented-field__fields--empty":
|
|
1206
|
+
}, w(j).suffix), [S(e.$slots, "suffix")], 16)) : m("", !0)])]),
|
|
1207
|
+
"append:outer": T(() => [S(e.$slots, "append:outer")]),
|
|
1208
|
+
default: T(() => [g("div", {
|
|
1209
|
+
class: Ee(["bb-segmented-field__fields", {
|
|
1210
|
+
"bb-segmented-field__fields--empty": jn.value,
|
|
1197
1211
|
"bb-segmented-field__fields--range": e.range
|
|
1198
1212
|
}]),
|
|
1199
|
-
style:
|
|
1200
|
-
}, [
|
|
1213
|
+
style: De({ "--fields-min-ch": w(sn) })
|
|
1214
|
+
}, [jn.value ? (b(), h("span", {
|
|
1201
1215
|
key: 0,
|
|
1202
1216
|
"aria-hidden": "true",
|
|
1203
1217
|
class: "bb-segmented-field__placeholder",
|
|
1204
|
-
onClick: n[0] ||= (...e) =>
|
|
1205
|
-
},
|
|
1218
|
+
onClick: n[0] ||= (...e) => w(un) && w(un)(...e)
|
|
1219
|
+
}, C(An.value), 1)) : m("", !0), (b(!0), h(xe, null, Ae(G.value, (t, n) => (b(), h(xe, { key: w(an)(t) }, [g("span", {
|
|
1206
1220
|
class: "bb-segmented-field__field-sizer",
|
|
1207
|
-
"data-value":
|
|
1208
|
-
}, [
|
|
1209
|
-
id: n === 0 ? r :
|
|
1221
|
+
"data-value": w(on)(t)
|
|
1222
|
+
}, [g("input", v({
|
|
1223
|
+
id: n === 0 ? r : _n(t, r),
|
|
1210
1224
|
ref_for: !0,
|
|
1211
|
-
ref: (e) =>
|
|
1212
|
-
"aria-describedby":
|
|
1225
|
+
ref: (e) => w(rn)[w(an)(t)] = e,
|
|
1226
|
+
"aria-describedby": mt(o, r),
|
|
1213
1227
|
"aria-disabled": e.disabled || void 0,
|
|
1214
1228
|
"aria-invalid": i ? "true" : void 0,
|
|
1215
|
-
"aria-label":
|
|
1216
|
-
"aria-readonly":
|
|
1229
|
+
"aria-label": bn(t),
|
|
1230
|
+
"aria-readonly": St.value || void 0,
|
|
1217
1231
|
autocomplete: e.autocomplete,
|
|
1218
1232
|
autofocus: e.autofocus && n === 0,
|
|
1219
1233
|
class: ["bb-segmented-field__input", [`bb-segmented-field__input--${t.field}`, `bb-segmented-field__input--${t.segment}`]],
|
|
1220
1234
|
disabled: e.disabled,
|
|
1221
|
-
inputmode:
|
|
1222
|
-
maxlength:
|
|
1223
|
-
name:
|
|
1224
|
-
readonly:
|
|
1225
|
-
required:
|
|
1226
|
-
"aria-required":
|
|
1227
|
-
tabindex:
|
|
1235
|
+
inputmode: Ct(t.field),
|
|
1236
|
+
maxlength: tn.value[t.field].maxLength,
|
|
1237
|
+
name: vn(t),
|
|
1238
|
+
readonly: St.value,
|
|
1239
|
+
required: w(Ye),
|
|
1240
|
+
"aria-required": w(Xe),
|
|
1241
|
+
tabindex: en(n) ? 0 : -1,
|
|
1228
1242
|
type: "text",
|
|
1229
|
-
value:
|
|
1230
|
-
onBlur: (e) =>
|
|
1231
|
-
onFocus: (e) =>
|
|
1232
|
-
onInput: (e) =>
|
|
1233
|
-
onKeydown: (e) =>
|
|
1234
|
-
onPaste: (e) =>
|
|
1235
|
-
},
|
|
1243
|
+
value: w(K)[t.segment][t.field],
|
|
1244
|
+
onBlur: (e) => w(mn)(t),
|
|
1245
|
+
onFocus: (e) => Rt(t, e),
|
|
1246
|
+
onInput: (e) => gn(t, e),
|
|
1247
|
+
onKeydown: (e) => bt(t, e),
|
|
1248
|
+
onPaste: (e) => w(hn)(t, e)
|
|
1249
|
+
}, v(w(j).controlAttrs, w(j).input)), null, 16, Re)], 8, Le), n < G.value.length - 1 ? (b(), h("span", {
|
|
1236
1250
|
key: 0,
|
|
1237
1251
|
"aria-hidden": "true",
|
|
1238
|
-
class:
|
|
1252
|
+
class: Ee(["bb-segmented-field__separator", { "bb-segmented-field__separator--range": G.value[n].segment !== G.value[n + 1].segment }]),
|
|
1239
1253
|
role: "presentation",
|
|
1240
|
-
onClick: (e) =>
|
|
1241
|
-
},
|
|
1242
|
-
id:
|
|
1254
|
+
onClick: (e) => w(ln)(G.value[n + 1], { select: !0 })
|
|
1255
|
+
}, C(nn(G.value[n], G.value[n + 1])), 11, ze)) : m("", !0)], 64))), 128))], 6), g("span", {
|
|
1256
|
+
id: pt(r),
|
|
1243
1257
|
class: "bb-date-picker-input__accessible-description",
|
|
1244
1258
|
hidden: ""
|
|
1245
|
-
},
|
|
1259
|
+
}, C(w(F)("datePickerInput.dateFormat")) + " " + C(kn.value), 9, Ve)]),
|
|
1246
1260
|
_: 2
|
|
1247
1261
|
}, [e.$slots.prefix ? {
|
|
1248
1262
|
name: "prefix",
|
|
1249
|
-
fn:
|
|
1263
|
+
fn: T(() => [S(e.$slots, "prefix")]),
|
|
1250
1264
|
key: "0"
|
|
1251
1265
|
} : void 0]), 1032, [
|
|
1252
1266
|
"active",
|
|
@@ -1267,7 +1281,7 @@ var Ie = ["data-value"], Le = [
|
|
|
1267
1281
|
_: 2
|
|
1268
1282
|
}, [e.$slots.description ? {
|
|
1269
1283
|
name: "description",
|
|
1270
|
-
fn:
|
|
1284
|
+
fn: T((t) => [S(e.$slots, "description", y(_(t)))]),
|
|
1271
1285
|
key: "0"
|
|
1272
1286
|
} : void 0]), 1040, [
|
|
1273
1287
|
"id",
|
|
@@ -1299,4 +1313,4 @@ var Ie = ["data-value"], Le = [
|
|
|
1299
1313
|
}
|
|
1300
1314
|
});
|
|
1301
1315
|
//#endregion
|
|
1302
|
-
export {
|
|
1316
|
+
export { Ue as default };
|