bitboss-ui 3.0.0-beta.73 → 3.0.0-beta.75
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 +4 -2
- package/bin/bitboss-ui-mcp.mjs +101 -3
- package/bin/bitboss-ui.mjs +6 -1
- package/bin/cli.mjs +31 -5
- package/dist/ai/BbAvatar.md +86 -58
- package/dist/ai/BbBadge.md +5 -5
- package/dist/ai/BbBreadcrumbs.md +2 -2
- package/dist/ai/BbButton.md +2 -2
- package/dist/ai/BbCalendar.md +9 -5
- package/dist/ai/BbCheckboxGroup.md +5 -4
- package/dist/ai/BbColorInput.md +12 -0
- package/dist/ai/BbColorPalette.md +19 -15
- package/dist/ai/BbConfirmPortal.md +1 -1
- package/dist/ai/BbDatePicker.md +16 -3
- package/dist/ai/BbDatePickerInput.md +17 -1
- package/dist/ai/BbDialog.md +16 -4
- package/dist/ai/BbDropdown.md +175 -67
- package/dist/ai/BbDropdownButton.md +27 -8
- package/dist/ai/BbForm.md +4 -1
- package/dist/ai/BbHoverCardPortal.md +1 -1
- package/dist/ai/BbNumberInput.md +8 -4
- package/dist/ai/BbPopoverPortal.md +1 -1
- package/dist/ai/BbRadioGroup.md +4 -4
- package/dist/ai/BbSelect.md +79 -67
- package/dist/ai/BbSelectPopover.md +24 -5
- package/dist/ai/BbSwitchGroup.md +5 -4
- package/dist/ai/BbTable.md +59 -34
- package/dist/ai/BbTimePicker.md +16 -3
- package/dist/ai/BbTimePickerInput.md +15 -1
- package/dist/ai/BbToast.md +3 -2
- package/dist/ai/BbToastPortal.md +1 -1
- package/dist/ai/BbTree.md +5 -1
- package/dist/ai/CommonPopover.md +1 -0
- package/dist/ai/FlatListBox.md +1 -0
- package/dist/ai/GroupedListBox.md +1 -0
- package/dist/ai/ListBox.md +1 -0
- package/dist/ai/OptionsContainer.md +4 -4
- package/dist/ai/changelog.json +215 -6
- package/dist/ai/components.json +77 -43
- package/dist/ai/composables/useToast.md +2 -2
- package/dist/ai/design-tokens.json +60 -0
- package/dist/ai/guides/agent-contract.md +8 -4
- package/dist/ai/guides/design-tokens.md +33 -0
- package/dist/ai/guides/eslint-rules.md +1 -1
- package/dist/ai/guides/fetch-items-playbook.md +7 -11
- package/dist/ai/guides/inertia-helpers.md +613 -53
- package/dist/ai/guides/migration/adoption-checklist.md +5 -5
- package/dist/ai/guides/migration/components/bb-color-palette.md +11 -11
- package/dist/ai/guides/migration/components/bb-dropdown-button.md +1 -0
- package/dist/ai/guides/migration/components/bb-dropdown.md +1 -0
- package/dist/ai/guides/migration/components/bb-table.md +2 -1
- package/dist/ai/guides/migration/components/bb-toast.md +2 -2
- package/dist/ai/guides/migration/v2-to-v3.md +46 -5
- package/dist/ai/guides/migration/v3-beta-tooling.md +4 -0
- package/dist/ai/guides/passthrough.md +3 -3
- package/dist/ai/guides/preset-components.md +15 -2
- package/dist/ai/guides/reporting.md +49 -0
- package/dist/ai/helpers/inertia/manifest.json +33 -38
- package/dist/ai/helpers/inertia/useHasChanged.ts +25 -37
- package/dist/ai/helpers/inertia/useQuery.ts +24 -6
- package/dist/ai/helpers/inertia/utils.ts +552 -3
- package/dist/ai/index.md +2 -1
- package/dist/ai/manifest/common.json +1 -0
- package/dist/ai/manifest/components/BbAlert.tree.json +1 -1
- package/dist/ai/manifest/components/BbAvatar.json +5 -2
- package/dist/ai/manifest/components/BbAvatar.tree.json +32 -2
- package/dist/ai/manifest/components/BbCalendar.json +2 -2
- package/dist/ai/manifest/components/BbCarousel.json +0 -3
- package/dist/ai/manifest/components/BbCheckboxGroup.json +2 -2
- package/dist/ai/manifest/components/BbCheckboxGroup.tree.json +2 -0
- package/dist/ai/manifest/components/BbColorInput.json +5 -2
- package/dist/ai/manifest/components/BbColorPalette.json +7 -4
- package/dist/ai/manifest/components/BbColorPalette.removed.json +1 -2
- package/dist/ai/manifest/components/BbConfirmPortal.json +1 -1
- package/dist/ai/manifest/components/BbDatePicker.json +6 -3
- package/dist/ai/manifest/components/BbDatePickerInput.json +3 -0
- package/dist/ai/manifest/components/BbDialog.tree.json +7 -1
- package/dist/ai/manifest/components/BbDropdown.json +23 -17
- package/dist/ai/manifest/components/BbDropdown.removed.json +2 -1
- package/dist/ai/manifest/components/BbDropdown.tree.json +16 -5
- package/dist/ai/manifest/components/BbDropdownButton.json +15 -9
- package/dist/ai/manifest/components/BbDropdownButton.removed.json +2 -1
- package/dist/ai/manifest/components/BbDropdownButton.tree.json +2 -0
- package/dist/ai/manifest/components/BbForm.json +1 -1
- package/dist/ai/manifest/components/BbHoverCard.json +1 -1
- package/dist/ai/manifest/components/BbHoverCardPortal.json +1 -1
- package/dist/ai/manifest/components/BbNumberInput.json +1 -1
- package/dist/ai/manifest/components/BbOffCanvas.tree.json +2 -0
- package/dist/ai/manifest/components/BbPopover.json +1 -1
- package/dist/ai/manifest/components/BbPopoverPortal.json +1 -1
- package/dist/ai/manifest/components/BbRadioGroup.json +2 -2
- package/dist/ai/manifest/components/BbRadioGroup.tree.json +2 -0
- package/dist/ai/manifest/components/BbSelect.json +10 -7
- package/dist/ai/manifest/components/BbSelectPopover.json +7 -4
- package/dist/ai/manifest/components/BbSelectPopover.tree.json +5 -1
- package/dist/ai/manifest/components/BbSwitchGroup.json +2 -2
- package/dist/ai/manifest/components/BbSwitchGroup.tree.json +2 -0
- package/dist/ai/manifest/components/BbTable.json +6 -6
- package/dist/ai/manifest/components/BbTable.tree.json +16 -6
- package/dist/ai/manifest/components/BbTimePicker.json +7 -4
- package/dist/ai/manifest/components/BbTimePickerInput.json +5 -2
- package/dist/ai/manifest/components/BbToastPortal.json +1 -1
- package/dist/ai/manifest/components/BbTree.json +1 -1
- package/dist/ai/manifest/components/CommonPopover.json +2 -1
- package/dist/ai/manifest/components/FlatListBox.json +2 -1
- package/dist/ai/manifest/components/GroupedListBox.json +2 -1
- package/dist/ai/manifest/components/ListBox.json +2 -1
- package/dist/ai/manifest/components/OptionsContainer.json +6 -4
- package/dist/ai/manifest/index.json +2 -2
- package/dist/ai/manifest/meta.json +36 -3
- package/dist/ai/manifest/types.advanced.json +81 -80
- package/dist/ai/manifest/types.api.json +64 -65
- package/dist/ai/manifest/types.wrapper.json +155 -118
- package/dist/ai/recipes/inertia/layout-scaffold.md +3 -1
- package/dist/ai/recipes/nuxt/layout-scaffold.md +3 -1
- package/dist/ai/recipes/vue/layout-scaffold.md +3 -1
- package/dist/ai/source/BbAlert.md +16 -4
- package/dist/ai/source/BbAvatar.md +121 -9
- package/dist/ai/source/BbBadge.md +12 -5
- package/dist/ai/source/BbBreadcrumbs.md +56 -55
- package/dist/ai/source/BbButton.md +41 -25
- package/dist/ai/source/BbCalendar.md +22 -12
- package/dist/ai/source/BbCarousel.md +31 -28
- package/dist/ai/source/BbCheckboxGroup.md +15 -9
- package/dist/ai/source/BbColorInput.md +19 -0
- package/dist/ai/source/BbColorPalette.md +59 -12
- package/dist/ai/source/BbConfirm.md +7 -0
- package/dist/ai/source/BbConfirmPortal.md +9 -4
- package/dist/ai/source/BbDatePicker.md +71 -22
- package/dist/ai/source/BbDatePickerInput.md +72 -9
- package/dist/ai/source/BbDialog.md +45 -2
- package/dist/ai/source/BbDropdown.md +263 -63
- package/dist/ai/source/BbDropdownButton.md +27 -2
- package/dist/ai/source/BbDropdownGroup.md +121 -59
- package/dist/ai/source/BbForm.md +73 -6
- package/dist/ai/source/BbGallery.md +76 -55
- package/dist/ai/source/BbHost.md +12 -0
- package/dist/ai/source/BbHoverCard.md +7 -0
- package/dist/ai/source/BbHoverCardPortal.md +9 -5
- package/dist/ai/source/BbNumberInput.md +22 -16
- package/dist/ai/source/BbOffCanvas.md +48 -2
- package/dist/ai/source/BbPopover.md +7 -0
- package/dist/ai/source/BbPopoverPortal.md +9 -5
- package/dist/ai/source/BbRadio.md +4 -3
- package/dist/ai/source/BbRadioGroup.md +19 -10
- package/dist/ai/source/BbSelect.md +35 -20
- package/dist/ai/source/BbSelectPopover.md +116 -8
- package/dist/ai/source/BbSwitchGroup.md +11 -4
- package/dist/ai/source/BbTable.md +126 -32
- package/dist/ai/source/BbTag.md +10 -3
- package/dist/ai/source/BbTimePicker.md +69 -15
- package/dist/ai/source/BbTimePickerInput.md +45 -7
- package/dist/ai/source/BbToast.md +16 -2
- package/dist/ai/source/BbToastPortal.md +18 -6
- package/dist/ai/source/BbTree.md +1 -1
- package/dist/ai/source/CommonFieldInput.md +11 -5
- package/dist/ai/source/CommonPopover.md +28 -2
- package/dist/ai/source/FlatListBox.md +26 -5
- package/dist/ai/source/GroupedListBox.md +63 -11
- package/dist/ai/source/ListBox.md +4 -0
- package/dist/ai/source/OptionsContainer.md +29 -11
- package/dist/components/BbAlert/BbAlert.vue_vue_type_script_setup_true_lang.js +31 -26
- package/dist/components/BbAvatar/BbAvatar.vue.d.ts +1 -0
- package/dist/components/BbAvatar/BbAvatar.vue_vue_type_script_setup_true_lang.js +61 -43
- package/dist/components/BbAvatar/avatarIdentity.js +25 -0
- package/dist/components/BbAvatar/ptKeys.generated.d.ts +5 -1
- package/dist/components/BbAvatar/types.d.ts +24 -5
- package/dist/components/BbAvatar/types.js +5 -1
- package/dist/components/BbBadge/BadgeBodyContent.vue_vue_type_script_setup_true_lang.js +24 -23
- package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +80 -79
- package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue_vue_type_script_setup_true_lang.js +152 -158
- package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +100 -85
- package/dist/components/BbCalendar/BbCalendar.vue.d.ts +1 -1
- package/dist/components/BbCalendar/BbCalendar.vue_vue_type_script_setup_true_lang.js +235 -234
- package/dist/components/BbCalendar/types.d.ts +2 -2
- package/dist/components/BbCalendar/useDayGrid.js +120 -123
- package/dist/components/BbCalendar/useDayjsLocale.js +11 -8
- package/dist/components/BbCarousel/BbCarousel.vue_vue_type_script_setup_true_lang.js +7 -7
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +126 -122
- package/dist/components/BbCheckboxGroup/types.d.ts +7 -11
- package/dist/components/BbColorInput/BbColorInput.vue.d.ts +2 -0
- package/dist/components/BbColorInput/BbColorInput.vue_vue_type_script_setup_true_lang.js +148 -141
- package/dist/components/BbColorInput/types.d.ts +7 -0
- package/dist/components/BbColorPalette/BbColorPalette.vue.d.ts +2 -0
- package/dist/components/BbColorPalette/BbColorPalette.vue_vue_type_script_setup_true_lang.js +239 -223
- package/dist/components/BbColorPalette/types.d.ts +8 -1
- package/dist/components/BbConfirm/BbConfirmPortal.vue.d.ts +2 -4
- package/dist/components/BbConfirm/types.d.ts +5 -0
- package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +4 -2
- package/dist/components/BbDatePicker/BbDatePicker.vue_vue_type_script_setup_true_lang.js +160 -143
- package/dist/components/BbDatePicker/types.d.ts +9 -2
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +3 -1
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +483 -496
- package/dist/components/BbDatePickerInput/types.d.ts +7 -0
- package/dist/components/BbDialog/BbDialog.vue_vue_type_script_setup_true_lang.js +252 -236
- package/dist/components/BbDialog/leaveGhost.js +38 -0
- package/dist/components/BbDialog/overlayActions.js +34 -20
- package/dist/components/BbDropdown/AdaptiveDropdown.vue_vue_type_script_setup_true_lang.js +92 -87
- package/dist/components/BbDropdown/BbDropdown.vue.d.ts +3 -0
- package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +419 -368
- package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +384 -340
- package/dist/components/BbDropdown/DropdownFailures.vue.js +4 -0
- package/dist/components/BbDropdown/DropdownFailures.vue_vue_type_script_setup_true_lang.js +24 -0
- package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +133 -119
- package/dist/components/BbDropdown/DropdownRow.vue_vue_type_script_setup_true_lang.js +73 -45
- package/dist/components/BbDropdown/normalizeGroups.js +6 -2
- package/dist/components/BbDropdown/ptKeys.generated.d.ts +8 -0
- package/dist/components/BbDropdown/types.d.ts +73 -58
- package/dist/components/BbDropdown/types.js +1 -0
- package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +2 -0
- package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +93 -72
- package/dist/components/BbDropdownButton/ptKeys.generated.d.ts +48 -0
- package/dist/components/BbDropdownButton/types.d.ts +13 -2
- package/dist/components/BbDropdownButton/types.js +2 -0
- package/dist/components/BbForm/BbForm.vue.d.ts +2 -21
- package/dist/components/BbForm/BbForm.vue_vue_type_script_setup_true_lang.js +229 -227
- package/dist/components/BbForm/types.d.ts +31 -0
- package/dist/components/BbGallery/BbGallery.vue_vue_type_script_setup_true_lang.js +318 -296
- package/dist/components/BbHost/BbHost.vue_vue_type_script_setup_true_lang.js +7 -1
- package/dist/components/BbHoverCard/BbHoverCardPortal.vue.d.ts +2 -5
- package/dist/components/BbHoverCard/types.d.ts +5 -0
- package/dist/components/BbNumberInput/BbNumberInput.vue_vue_type_script_setup_true_lang.js +10 -6
- package/dist/components/BbNumberInput/numberDisplay.js +102 -106
- package/dist/components/BbNumberInput/types.d.ts +4 -3
- package/dist/components/BbOffCanvas/BbOffCanvas.vue_vue_type_script_setup_true_lang.js +425 -409
- package/dist/components/BbPopover/BbPopoverPortal.vue.d.ts +2 -5
- package/dist/components/BbPopover/types.d.ts +5 -0
- package/dist/components/BbRadio/types.d.ts +4 -3
- package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +108 -106
- package/dist/components/BbRadioGroup/types.d.ts +4 -7
- package/dist/components/BbSelect/BbSelect.vue.d.ts +3 -1
- package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +167 -163
- package/dist/components/BbSelect/types.d.ts +23 -20
- package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +3 -1
- package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +680 -637
- package/dist/components/BbSelectPopover/types.d.ts +10 -4
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +159 -155
- package/dist/components/BbSwitchGroup/types.d.ts +3 -6
- package/dist/components/BbTable/BbTable.vue.d.ts +1 -3
- package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +1182 -1165
- package/dist/components/BbTable/BbTableDataRow.js +96 -96
- package/dist/components/BbTable/types.d.ts +11 -10
- package/dist/components/BbTag/BbTag.vue_vue_type_script_setup_true_lang.js +9 -3
- package/dist/components/BbTimePicker/BbTimePicker.vue.d.ts +4 -2
- package/dist/components/BbTimePicker/BbTimePicker.vue_vue_type_script_setup_true_lang.js +157 -140
- package/dist/components/BbTimePicker/types.d.ts +9 -2
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue.d.ts +3 -1
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +278 -268
- package/dist/components/BbTimePickerInput/types.d.ts +7 -0
- package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +12 -12
- package/dist/components/BbToast/BbToastPortal.vue.d.ts +2 -4
- package/dist/components/BbToast/types.d.ts +7 -2
- package/dist/components/BbTree/BbTreeLevel.vue_vue_type_script_setup_true_lang.js +56 -46
- package/dist/components/BbTree/types.d.ts +1 -1
- package/dist/components/CommonFieldInput/CommonFieldInput.vue_vue_type_script_setup_true_lang.js +36 -36
- package/dist/components/CommonPopover/CommonPopover.vue_vue_type_script_setup_true_lang.js +14 -2
- package/dist/components/CommonTimeSelector/useMeridiem.js +6 -6
- package/dist/components/FlatListBox/FlatListBox.vue_vue_type_script_setup_true_lang.js +115 -96
- package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js +194 -166
- package/dist/components/ListBox/ListBox.vue_vue_type_script_setup_true_lang.js +7 -4
- package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js +86 -77
- package/dist/composables/formSubmitLock.js +2 -1
- package/dist/composables/overlayRegistry.js +52 -42
- package/dist/composables/useActiveInactiveState.js +8 -4
- package/dist/composables/useBbDialog.js +5 -5
- package/dist/composables/useItemsGetter.js +34 -32
- package/dist/composables/useOpenModel.js +20 -0
- package/dist/composables/useOwnModel.js +16 -0
- package/dist/composables/useSegmentedFields.js +31 -20
- package/dist/deprecation/ai-deprecations.json.js +1 -1
- package/dist/i18n/currencyDigits.js +58 -0
- package/dist/i18n/locales/ar.json +2 -0
- package/dist/i18n/locales/cs.json +2 -0
- package/dist/i18n/locales/da.json +2 -0
- package/dist/i18n/locales/de-CH.json +2 -0
- package/dist/i18n/locales/de.json +2 -0
- package/dist/i18n/locales/el.json +2 -0
- package/dist/i18n/locales/en-GB.json +2 -0
- package/dist/i18n/locales/en.json +2 -0
- package/dist/i18n/locales/es-MX.json +2 -0
- package/dist/i18n/locales/es.json +2 -0
- package/dist/i18n/locales/fa.json +2 -0
- package/dist/i18n/locales/fi.json +2 -0
- package/dist/i18n/locales/fr.json +2 -0
- package/dist/i18n/locales/he.json +2 -0
- package/dist/i18n/locales/hu.json +2 -0
- package/dist/i18n/locales/it.json +2 -0
- package/dist/i18n/locales/ja.json +2 -0
- package/dist/i18n/locales/ko.json +2 -0
- package/dist/i18n/locales/nb.json +2 -0
- package/dist/i18n/locales/nl.json +2 -0
- package/dist/i18n/locales/pl.json +2 -0
- package/dist/i18n/locales/pt-BR.json +2 -0
- package/dist/i18n/locales/pt-PT.json +2 -0
- package/dist/i18n/locales/ro.json +2 -0
- package/dist/i18n/locales/ru.json +2 -0
- package/dist/i18n/locales/sv.json +2 -0
- package/dist/i18n/locales/tr.json +2 -0
- package/dist/i18n/locales/uk.json +2 -0
- package/dist/i18n/locales/zh-CN.json +2 -0
- package/dist/i18n/locales/zh-HK.json +2 -0
- package/dist/i18n/locales/zh-TW.json +2 -0
- package/dist/i18n/regionDates.js +250 -0
- package/dist/i18n/regionHints.js +30 -41
- package/dist/icon-scan.js +68 -61
- package/dist/index.d.ts +35 -31
- package/dist/llms-full.txt +1428 -400
- package/dist/llms-medium.txt +8 -4
- package/dist/llms.txt +4 -2
- package/dist/locale-blueprint.json +2 -0
- package/dist/styles.css +2 -2
- package/dist/types/ActionButton.d.ts +2 -1
- package/dist/types/CommonProps.d.ts +8 -0
- package/dist/types/Option.d.ts +10 -0
- package/dist/types/ptComponentMap.d.ts +3 -3
- package/dist/utilities/functions/hash.js +97 -64
- package/dist/utilities/functions/isEqual.js +33 -25
- package/dist/utilities/functions/slotContent.js +19 -0
- package/dist/utils/loadRetry.js +8 -0
- package/dist/utils/versionCheck.js +1 -1
- package/dist/vite-plugin.d.ts +2 -1
- package/dist/vite.js +11 -4
- package/llms.txt +4 -2
- package/package.json +3 -2
- package/scripts/README.md +3 -1
- package/scripts/lib/adoption-checklist.json +6 -5
- package/scripts/lib/agent-manifest.mjs +33 -6
- package/scripts/lib/agent-setup.mjs +90 -24
- package/scripts/lib/cldr-pins.ts +182 -0
- package/scripts/lib/engines-include.d.mts +5 -0
- package/scripts/lib/engines-include.mjs +40 -0
- package/scripts/lib/eslint-plugin.mjs +8 -2
- package/scripts/lib/hidden-label-placeholder.mjs +25 -5
- package/scripts/lib/idiom-scan.mjs +30 -3
- package/scripts/lib/legacy-agent-files.json +152 -0
- package/scripts/lib/mcp-config.mjs +74 -7
- package/scripts/lib/portal-names.mjs +78 -8
- package/scripts/lib/release-results.mjs +5 -2
- package/scripts/lib/report.mjs +340 -0
- package/scripts/lib/run-beat.mjs +14 -0
- package/scripts/lib/run-records.mjs +313 -0
- package/scripts/lib/selector-log.mjs +98 -0
- package/scripts/lib/ticket-beat.mjs +30 -0
- package/scripts/lib/validate-bb-markup.mjs +37 -2
- package/dist/ai/manifest/components/BbAvatar.removed.json +0 -6
|
@@ -808,8 +808,9 @@ called with one context object — `BbCheckboxGroupItemsContext`: `reason`
|
|
|
808
808
|
`'model'` when the model changed from outside and the options cannot resolve
|
|
809
809
|
it), `modelValue` and `signal`; a group has no search field, so no `query`.
|
|
810
810
|
While it resolves, `loading-text` (or the `#loading` slot) shows; `empty-text`
|
|
811
|
-
(or `#empty`) covers the empty result, and `failed-text`
|
|
812
|
-
|
|
811
|
+
(or `#empty`) covers the empty result, and `failed-text` words the failure
|
|
812
|
+
row of a load that threw (it ends with a built-in "Try again"; `#empty` never
|
|
813
|
+
renders for a failure). Loading, cancellation and race protection are
|
|
813
814
|
built in — don't wrap the provider in your own `loading` ref or debounce.
|
|
814
815
|
|
|
815
816
|
Tie the option set to external state with `dependencies` (debounced by
|
|
@@ -1119,7 +1120,7 @@ for a preset that fits any row type (never `<any>`), not an imported
|
|
|
1119
1120
|
| `itemLayout` | `FieldLayout \| undefined` | `'auto'` | | How each row's input and label sit together, in the `layout` keywords: `'auto'`, `'vertical'`, `'horizontal'`, `'label-fill'`, `'input-fill'`, or a two-word ratio pattern like `'xx xxxxx'`. |
|
|
1120
1121
|
| `itemProps` | `BbOptionGroupItemProps<T> \| undefined` | | | ADDITIONAL row fields, never the text or value: `description`, a muted line under the label (it may wrap; announced as the option's description). An object of paths or getters, or a function of the item; nothing is read implicitly. |
|
|
1121
1122
|
| `itemReverse` | `boolean \| undefined` | `undefined` | | Swaps each row's input and label from their natural order (input first), in every `item-layout`. `reverse` swaps the legend and the options instead. |
|
|
1122
|
-
| `items` | `T[] \| ((context: BbCheckboxGroupItemsContext) => T[] \| Promise<T[]>)` | | yes | The options: an array, or a provider called with
|
|
1123
|
+
| `items` | `T[] \| ((context: BbCheckboxGroupItemsContext) => T[] \| Promise<T[]>)` | | yes | The options: an array, or a provider called with `{ reason, modelValue, signal }`, sync or async. A provider fails by THROWING, never by returning `[]`: the rows clear and the failure row shows `failed-text` with "Try again". |
|
|
1123
1124
|
| `itemText` | `ItemAccessor<T, string> \| undefined` | `own `label`, else `text`, else `JSON.stringify(item)`` | | Defines a path that returns a property of the object to use as text or a function that returns a string. Unset: own `label`, else `text` (`{ label, value }` needs no accessor). |
|
|
1124
1125
|
| `itemValue` | `ItemAccessor<T> \| undefined` | `own `value`, else the whole item` | | Defines a path that returns a property of the object to use as value or a function that returns any value. Unset: own `value`, even `null`. |
|
|
1125
1126
|
| `labelAlign` | `'center'` \| `'top'` \| `'bottom'` | | | Vertical position of the label block in a side-by-side row; not `labelPosition`, the horizontal one. Omitted, `'top'`. |
|
|
@@ -1197,7 +1198,7 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
1197
1198
|
|
|
1198
1199
|
- `append` — scope: `object` — Content rendered after the last option, inside the options container.
|
|
1199
1200
|
- `description` — scope: `BbCheckboxGroupDescriptionSlotProps` `{ text: string; hasErrors: boolean; hasWarnings: boolean }` — Replaces the description text. Provided alone (no `description` prop) it still renders the description region and wires it into `aria-describedby`.
|
|
1200
|
-
- `empty` — scope: `
|
|
1201
|
+
- `empty` — scope: `object` — Content shown when no options are available (replaces the default "no data" text). Empty only: a failed load shows the library's failure row instead (its message is `failed-text`, and it ends with "Try again").
|
|
1201
1202
|
- `icon` — scope: `BbCheckboxGroupIconSlotProps<T>` `{ disabled: boolean; readonly: boolean; checked: boolean; indeterminate?: boolean; focused: boolean; focusVisible: boolean; id: string; name: string; falseValue: any; hasErrors: boolean; hasWarnings: boolean; parsedValue: string; trueValue: any; value: any; item: T; text: string }` — Replaces the default checkmark icon for each checkbox option.
|
|
1202
1203
|
- `label` — scope: `BbCheckboxGroupLabelSlotProps<T>` `{ item: T; text: string; checked: boolean; description: string }` — Replaces the default label text for each option.
|
|
1203
1204
|
- `legend` — scope: `BbCheckboxGroupLegendSlotProps` `{ showAsterisk?: boolean; text: string; hasErrors: boolean; hasWarnings: boolean }` — Replaces the default fieldset legend text for the group.
|
package/dist/ai/BbColorInput.md
CHANGED
|
@@ -466,6 +466,15 @@ styles the sheet's root only. For what is inside it (header, title, ✕, body)
|
|
|
466
466
|
no part of the input reaches there, so put a `pt` in `offCanvasProps`
|
|
467
467
|
(passthrough guide § Inside the sheet).
|
|
468
468
|
|
|
469
|
+
### Opening from code: `v-model:open`
|
|
470
|
+
|
|
471
|
+
`v-model` is the value; `v-model:open` is whether the palette is open. Bound,
|
|
472
|
+
your ref opens and closes it, and every open and close the user makes is
|
|
473
|
+
written back: a pick, Escape, a click outside, the phone sheet's own dismiss. A static `:open` with no
|
|
474
|
+
listener is only the initial state. An open from code is the same open a
|
|
475
|
+
click makes, and `disabled` / `readonly` refuse it (the ref is set back
|
|
476
|
+
to `false`).
|
|
477
|
+
|
|
469
478
|
### Events
|
|
470
479
|
|
|
471
480
|
Beyond `update:modelValue` (see value format above), the native input events are
|
|
@@ -674,6 +683,7 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
674
683
|
## v-model
|
|
675
684
|
|
|
676
685
|
- `v-model` — type: `string \| null \| undefined`
|
|
686
|
+
- `v-model:open` — type: `boolean \| undefined`
|
|
677
687
|
|
|
678
688
|
## Props
|
|
679
689
|
|
|
@@ -707,6 +717,7 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
707
717
|
| `modelValue` | `string \| null \| undefined` | `null` | | Used by v-model. |
|
|
708
718
|
| `name` | `string \| undefined` | | | Defines the name of the input. |
|
|
709
719
|
| `offCanvasProps` | `Partial<BbOffCanvasProps> \| undefined` | | | Props for the phone sheet (the `BbOffCanvas` that `adaptive` renders on mobile), spread over its defaults. A `pt` inside it styles only the sheet (passthrough guide § Inside the sheet). The sheet hides its ✕; `{ hideClose: false }` brings it back. |
|
|
720
|
+
| `open` | `boolean \| undefined` | `false` | | Whether the panel is open (`v-model:open`; `v-model` stays the value). Bound, the app opens and closes it; unbound, the initial state. |
|
|
710
721
|
| `persistentHint` | `boolean \| undefined` | `false` | | Keeps the hint displayed. |
|
|
711
722
|
| `placeholder` | `string \| undefined` | | | Text shown while the field is empty. |
|
|
712
723
|
| `prepend:icon` | `string \| undefined` | | | Name of the icon to be added at the start of the input. |
|
|
@@ -778,6 +789,7 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
778
789
|
- `show` — `(): void` — Emitted as soon as the palette (the popover, or the sheet on a phone) starts to open.
|
|
779
790
|
- `shown` — `(): void` — Emitted once the palette is open and its open transition has finished.
|
|
780
791
|
- `update:modelValue` — `(value: string \| null): void` — Emitted when the value becomes a valid hex color via typing/masking, when the field is cleared, or when the palette selects a color. Emits: - `#RRGGBB` (or `#RRGGBBAA` when `alpha` is enabled) for valid values - `null` when cleared
|
|
792
|
+
- `update:open` — `(value: boolean): void` — The panel opened or closed (`v-model:open`).
|
|
781
793
|
|
|
782
794
|
## Slots
|
|
783
795
|
|
|
@@ -58,11 +58,10 @@ gradient, hue or alpha handle, and once per swatch/eyedropper pick. Treat it
|
|
|
58
58
|
like an `input`-frequency event: cheap handlers, or debounce your own
|
|
59
59
|
persistence.
|
|
60
60
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
nothing is chosen yet.
|
|
61
|
+
Seed a bound model as `ref<string | null>(null)`: `null` is the "no color
|
|
62
|
+
yet" value, and renders an "empty" trigger (nothing painted). With no
|
|
63
|
+
`v-model` at all the palette keeps the picked color itself, like a native
|
|
64
|
+
input, and still emits `update:modelValue` on every change.
|
|
66
65
|
|
|
67
66
|
**The palette never emits `null`** — every selection is a concrete hex — so
|
|
68
67
|
`null` is an _inbound_ value only. Once the user picks a colour there is no
|
|
@@ -535,10 +534,12 @@ popover ↔ sheet.
|
|
|
535
534
|
|
|
536
535
|
### Open state, disabled and readonly
|
|
537
536
|
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
537
|
+
Clicking the activator toggles the palette; a pick, Escape or a click outside
|
|
538
|
+
closes it, and the slot's `open` flag shows the state for styling (a caret, a
|
|
539
|
+
highlight). To open it from code, bind `v-model:open` (`v-model` stays the
|
|
540
|
+
color): your ref opens and closes it, and every close is written back. A
|
|
541
|
+
static `:open` with no listener is only the initial state. Two props gate
|
|
542
|
+
interaction:
|
|
542
543
|
|
|
543
544
|
- `disabled` — blocks the activator entirely (no open). The trigger gets
|
|
544
545
|
`disabled` and `aria-disabled="true"` — through the slot's `props`, or set on
|
|
@@ -730,10 +731,10 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
730
731
|
swatches/gradient as the primary path.
|
|
731
732
|
- **Alpha mismatch** — without `alpha`, an incoming `#RRGGBBAA` value can't be
|
|
732
733
|
represented; enable `alpha` wherever 8-digit values occur.
|
|
733
|
-
- **
|
|
734
|
-
|
|
735
|
-
- **
|
|
736
|
-
|
|
734
|
+
- **Start a bound model at `null`**, not `undefined`: `null` is the empty
|
|
735
|
+
value the palette reports back.
|
|
736
|
+
- **Open it from code with `v-model:open`**, not by clicking the activator
|
|
737
|
+
from a script; `disabled` / `readonly` refuse that open too.
|
|
737
738
|
|
|
738
739
|
### Accessibility
|
|
739
740
|
|
|
@@ -751,7 +752,8 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
751
752
|
|
|
752
753
|
## v-model
|
|
753
754
|
|
|
754
|
-
- `v-model` — type: `string \| null`
|
|
755
|
+
- `v-model` — type: `string \| null \| undefined`
|
|
756
|
+
- `v-model:open` — type: `boolean \| undefined`
|
|
755
757
|
|
|
756
758
|
## Props
|
|
757
759
|
|
|
@@ -768,9 +770,10 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
768
770
|
| `eager` | `boolean \| undefined` | `false` | | Renders the palette panel at mount instead of on the first open (the phone sheet's too). |
|
|
769
771
|
| `eyeDropper` | `boolean \| undefined` | `false` | | Show an eyedropper button inside the palette to sample any color on screen. Uses the native EyeDropper API — hidden automatically on unsupported browsers. |
|
|
770
772
|
| `label` | `string \| undefined` | | | Accessible label. The activator is named by it followed by the activator's own text, through `aria-labelledby`. Defaults to the locale string for "Open color picker" when omitted. |
|
|
771
|
-
| `modelValue` | `string \| null` | |
|
|
773
|
+
| `modelValue` | `string \| null \| undefined` | | | v-model: the current color as a `#RRGGBB` hex string (or `#RRGGBBAA` when `alpha` is enabled), or `null` when empty. |
|
|
772
774
|
| `offCanvasProps` | `Partial<BbOffCanvasProps> \| undefined` | | | Props for the phone sheet (the `BbOffCanvas` that `adaptive` renders on mobile), spread over its defaults. A `pt` inside it styles only the sheet (passthrough guide § Inside the sheet). The sheet hides its ✕; `{ hideClose: false }` brings it back. |
|
|
773
775
|
| `offset` | `number \| undefined` | `4` | | Space the floating container will maintain from the activator. |
|
|
776
|
+
| `open` | `boolean \| undefined` | `false` | | Whether the panel is open (`v-model:open`; `v-model` stays the value). Bound, the app opens and closes it; unbound, the initial state. |
|
|
774
777
|
| `padding` | `number \| undefined` | `6` | | Minimum empty space to keep from the edge of the page |
|
|
775
778
|
| `placement` | `Placement \| undefined` | | | Position of the overlay in respect to the related activator. |
|
|
776
779
|
| `readonly` | `boolean \| undefined` | `false` | | Prevent opening the palette while keeping the activator visible. |
|
|
@@ -802,6 +805,7 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
802
805
|
- `show` — `(): void` — Emitted as soon as the palette (the popover, or the sheet on a phone) starts to open.
|
|
803
806
|
- `shown` — `(): void` — Emitted once the palette is open and its open transition has finished.
|
|
804
807
|
- `update:modelValue` — `(value: string): void` — Emitted when a color is picked. Payload is a concrete `#RRGGBB` (or `#RRGGBBAA` when alpha is enabled) — the palette always emits a color, never `null`.
|
|
808
|
+
- `update:open` — `(value: boolean): void` — The panel opened or closed (`v-model:open`).
|
|
805
809
|
|
|
806
810
|
## Slots
|
|
807
811
|
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
|
|
21
21
|
## Slots
|
|
22
22
|
|
|
23
|
-
- `default` — scope: `BbConfirmPortalSlotProps
|
|
23
|
+
- `default` — scope: `BbConfirmPortalSlotProps<any>` `{ data: P; ok: () => void; cancel: () => void }` — The confirm's body.
|
|
24
24
|
|
|
25
25
|
## See Also
|
|
26
26
|
|
package/dist/ai/BbDatePicker.md
CHANGED
|
@@ -72,7 +72,8 @@ const due = ref<string | null>(null);
|
|
|
72
72
|
|
|
73
73
|
The value is typed `string | string[] | null` in every mode. `v-model` needs
|
|
74
74
|
nothing: bind a `ref<string | null>` for one date, a `ref<string[]>` for a
|
|
75
|
-
range or `multiple`.
|
|
75
|
+
range or `multiple`. With no `v-model` at all the picker keeps the picked value itself, like a
|
|
76
|
+
native input, and still emits `update:modelValue`. An explicit `@update:model-value` handler narrows in one
|
|
76
77
|
line:
|
|
77
78
|
|
|
78
79
|
```ts no-check
|
|
@@ -351,6 +352,15 @@ Reach for the **component** (slot or `activator` prop) when you want the
|
|
|
351
352
|
the directive is the shortcut for the bare-trigger cell case, not a replacement
|
|
352
353
|
for the component's `v-model` in a form.
|
|
353
354
|
|
|
355
|
+
### Opening from code: `v-model:open`
|
|
356
|
+
|
|
357
|
+
`v-model` is the value; `v-model:open` is whether the calendar is open. Bound,
|
|
358
|
+
your ref opens and closes it, and every open and close the user makes is
|
|
359
|
+
written back: a pick, Escape, a click outside, the phone sheet's own dismiss. A static `:open` with no
|
|
360
|
+
listener is only the initial state. An open from code is the same open a
|
|
361
|
+
click makes, and `disabled` / `readonly` refuse it (the ref is set back
|
|
362
|
+
to `false`).
|
|
363
|
+
|
|
354
364
|
### Relationship to BbDatePickerInput
|
|
355
365
|
|
|
356
366
|
`BbDatePickerInput` _is_ a `BbDatePicker` with a segmented text field wrapped
|
|
@@ -462,7 +472,8 @@ and digit typeahead; the time rail exposes labelled columns. Always pass a
|
|
|
462
472
|
## v-model
|
|
463
473
|
|
|
464
474
|
- `v-model:activeSegment` — type: `BbCalendarSegment \| undefined`
|
|
465
|
-
- `v-model` — type: `string \| string[] \| null`
|
|
475
|
+
- `v-model` — type: `string \| string[] \| null \| undefined`
|
|
476
|
+
- `v-model:open` — type: `boolean \| undefined`
|
|
466
477
|
- `v-model:time` — type: `string \| string[] \| null \| undefined`
|
|
467
478
|
|
|
468
479
|
## Props
|
|
@@ -485,11 +496,12 @@ and digit typeahead; the time rail exposes labelled columns. Always pass a
|
|
|
485
496
|
| `label` | `string \| undefined` | | | Accessible label. The activator is named by it followed by the activator's own text ("Due date 12 Sep"), through `aria-labelledby`. |
|
|
486
497
|
| `max` | `string \| undefined` | | | Maximum selectable value, in this `type`'s shape. A finer bound is accepted and ceiled to the unit, with a warning (`week`: as `min`). |
|
|
487
498
|
| `min` | `string \| undefined` | | | Minimum selectable value, in this `type`'s shape — `YYYY-MM-DD` (`YYYY-MM-DDTHH:mm` with `datetime`, `YYYY-MM` with `month`, `YYYY` with `year`; a week or a date with `week`, whole weeks only). A finer bound is accepted and floored to the unit, with a warning. |
|
|
488
|
-
| `modelValue` | `string \| string[] \| null` | |
|
|
499
|
+
| `modelValue` | `string \| string[] \| null \| undefined` | | | v-model: `null` when empty, a string, a `[start, end]` pair with `range`, or a sorted array with `multiple`. The string is `YYYY-MM-DD` when `floating` (`YYYY-Www` / `YYYY-MM` / `YYYY` for `week` / `month` / `year`), otherwise a zoned ISO instant (carrying the time under `datetime`). |
|
|
489
500
|
| `multiple` | `boolean` | `false` | | Multi-selection: each pick toggles a value in a sorted array (days, weeks, months or years), and the panel stays open until dismissed. Needs an array `modelValue` (`[]` when empty, never `null`). Throws with `range` or `type="datetime"`. |
|
|
490
501
|
| `numberOfMonths` | `number \| undefined` | `1` | | How many months the popover shows side by side (day grids only); the phone sheet always shows one. Too narrow for them all, the months wrap. |
|
|
491
502
|
| `offCanvasProps` | `Partial<BbOffCanvasProps> \| undefined` | | | Props for the phone sheet (the `BbOffCanvas` that `adaptive` renders on mobile), spread over its defaults. A `pt` inside it styles only the sheet (passthrough guide § Inside the sheet). The sheet hides its ✕; `{ hideClose: false }` brings it back. |
|
|
492
503
|
| `offset` | `number \| undefined` | `4` | | Space the popover keeps from the activator. |
|
|
504
|
+
| `open` | `boolean \| undefined` | `false` | | Whether the panel is open (`v-model:open`; `v-model` stays the value). Bound, the app opens and closes it; unbound, the initial state. |
|
|
493
505
|
| `padding` | `number \| undefined` | | | Minimum empty space to keep from the edge of the page. |
|
|
494
506
|
| `placement` | `'start'` \| `'end'` \| `'top'` \| `'bottom'` \| `'left'` \| `'right'` \| `'top-start'` \| `'top-end'` \| `'right-start'` \| `'right-end'` \| `'bottom-start'` \| `'bottom-end'` \| `'left-start'` \| `'left-end'` \| `'start-start'` \| `'start-end'` \| `'end-start'` \| `'end-end'` | | | Position of the popover relative to the activator/anchor. |
|
|
495
507
|
| `range` | `boolean` | `false` | | Enables range selection (`[start, end]`). |
|
|
@@ -549,6 +561,7 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
549
561
|
- `time-pick` — `(payload: { unit: TimeUnit; value: string; }): void` — Relay of the raw time-rail pick. An embedding host binds this to run its own value engine; clean consumers ignore it and use `update:time`.
|
|
550
562
|
- `update:activeSegment` — `(value: BbCalendarSegment): void` — The active range end changed (range + `type="datetime"` only).
|
|
551
563
|
- `update:modelValue` — `(value: string \| string[] \| null): void` — Emitted when the selected date value changes (single/range/null).
|
|
564
|
+
- `update:open` — `(value: boolean): void` — The panel opened or closed (`v-model:open`).
|
|
552
565
|
- `update:time` — `(value: string \| string[] \| null): void` — Companion time model, alongside every change while `type="datetime"`.
|
|
553
566
|
|
|
554
567
|
## Slots
|
|
@@ -178,6 +178,8 @@ line: `if (!Array.isArray(value)) return;` before treating it as the range.
|
|
|
178
178
|
For a window that often crosses the month line, `:number-of-months="2"` shows
|
|
179
179
|
two months side by side in the popover (one in the phone sheet). If the
|
|
180
180
|
popover doesn't have room for both, the second month wraps under the first.
|
|
181
|
+
With one month, the greyed days of the previous and next month are pickable
|
|
182
|
+
too: clicking one picks it and moves the calendar to its month.
|
|
181
183
|
|
|
182
184
|
**Booking — two months in the popover**
|
|
183
185
|
|
|
@@ -260,7 +262,9 @@ and parses its own digits. Any other attribute lands on the field root; a
|
|
|
260
262
|
|
|
261
263
|
`min` and `max` (each a `YYYY-MM-DD` string) constrain the selectable window;
|
|
262
264
|
days outside it render disabled in the calendar, and a typed out-of-range date is
|
|
263
|
-
snapped back on commit.
|
|
265
|
+
snapped back on commit. A value your app sets past a bound (on mount or later)
|
|
266
|
+
stays as it is while nobody touches the field; once the user focuses it and
|
|
267
|
+
leaves, it snaps like a typed one. **Malformed `min`/`max` throw during setup** on purpose,
|
|
264
268
|
to catch config mistakes early — always pass the `YYYY-MM-DD` shape.
|
|
265
269
|
|
|
266
270
|
For non-contiguous rules (no weekends, no holidays, only in-stock slots), pass a
|
|
@@ -768,6 +772,15 @@ const from = ref<string | null>('2026-05-01');
|
|
|
768
772
|
</script>
|
|
769
773
|
```
|
|
770
774
|
|
|
775
|
+
### Opening from code: `v-model:open`
|
|
776
|
+
|
|
777
|
+
`v-model` is the value; `v-model:open` is whether the calendar is open. Bound,
|
|
778
|
+
your ref opens and closes it, and every open and close the user makes is
|
|
779
|
+
written back: a pick, Escape, a click outside, the phone sheet's own dismiss. A static `:open` with no
|
|
780
|
+
listener is only the initial state. An open from code is the same open a
|
|
781
|
+
click makes, and `disabled` / `readonly` refuse it (the ref is set back
|
|
782
|
+
to `false`).
|
|
783
|
+
|
|
771
784
|
### Events & v-model
|
|
772
785
|
|
|
773
786
|
Because the control is a composite (segmented fields + calendar + optional
|
|
@@ -972,6 +985,7 @@ label>')` matches nothing; query each segment by its own label instead. See
|
|
|
972
985
|
## v-model
|
|
973
986
|
|
|
974
987
|
- `v-model` — type: `string \| string[] \| null \| undefined`
|
|
988
|
+
- `v-model:open` — type: `boolean \| undefined`
|
|
975
989
|
- `v-model:time` — type: `string \| string[] \| null \| undefined`
|
|
976
990
|
|
|
977
991
|
## Props
|
|
@@ -1012,6 +1026,7 @@ label>')` matches nothing; query each segment by its own label instead. See
|
|
|
1012
1026
|
| `name` | `string \| undefined` | | | Defines the name of the input. |
|
|
1013
1027
|
| `numberOfMonths` | `number \| undefined` | `1` | | How many months the calendar popover shows side by side (day grids only); the phone sheet always shows one. Too narrow for them all, the months wrap. |
|
|
1014
1028
|
| `offCanvasProps` | `Partial<BbOffCanvasProps> \| undefined` | | | Props for the phone sheet (the `BbOffCanvas` that `adaptive` renders on mobile), spread over its defaults. A `pt` inside it styles only the sheet (passthrough guide § Inside the sheet). The sheet hides its ✕; `{ hideClose: false }` brings it back. |
|
|
1029
|
+
| `open` | `boolean \| undefined` | `false` | | Whether the panel is open (`v-model:open`; `v-model` stays the value). Bound, the app opens and closes it; unbound, the initial state. |
|
|
1015
1030
|
| `persistentHint` | `boolean \| undefined` | `false` | | Keeps the hint displayed. |
|
|
1016
1031
|
| `placeholder` | `string \| undefined` | | | Text shown while the field is empty. |
|
|
1017
1032
|
| `prepend:icon` | `string \| undefined` | | | Name of the icon to be added at the start of the input. |
|
|
@@ -1100,6 +1115,7 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
1100
1115
|
- `show` — `(): void` — Emitted as soon as the calendar surface starts to open (the popover, or the sheet on a phone).
|
|
1101
1116
|
- `shown` — `(): void` — Emitted once the calendar surface is open and its open transition has finished.
|
|
1102
1117
|
- `update:modelValue` — `(value: string \| string[] \| null): void` — Emitted whenever the selected date value changes. Payload is `null` for cleared values, a single string for single-date mode, or a two-element array for range mode.
|
|
1118
|
+
- `update:open` — `(value: boolean): void` — The panel opened or closed (`v-model:open`).
|
|
1103
1119
|
- `update:time` — `(value: string \| string[] \| null): void` — Companion time model (`v-model:time`), emitted alongside every value change while `type="datetime"` is on. Always 24-hour `HH:mm` (or `HH:mm:ss` with `seconds`); `null` when cleared, an array in range mode.
|
|
1104
1120
|
|
|
1105
1121
|
## Slots
|
package/dist/ai/BbDialog.md
CHANGED
|
@@ -355,6 +355,13 @@ const replace = (saved: Member) => {
|
|
|
355
355
|
| `'server'` | `show()` called during a server render: nothing opens there |
|
|
356
356
|
|
|
357
357
|
- On Android, the system back button closes the top dialog like Escape (it is the browser's close request), so `prevent-close` and a saving form refuse it the same way; iOS swipe-back and the desktop back button are page navigation.
|
|
358
|
+
- **A dialog removed while open** (a `v-if` on the row its `@complete`
|
|
359
|
+
deleted, a route change) still plays its close and hands focus back. An
|
|
360
|
+
async `@complete` that removed it still decides the result: completed
|
|
361
|
+
when it succeeds, else `'unmounted'`. So `v-if="item"` on the dialog is
|
|
362
|
+
fine. In your own tests, the page stays inert for that close (its
|
|
363
|
+
`transition-duration`), as for any close: wait for focus to come back
|
|
364
|
+
before a `focus()`. Clicks driven by Playwright wait on their own.
|
|
358
365
|
- It settles when the close **starts**, together with `@hide`, so a list can
|
|
359
366
|
update while the dialog fades out. It never rejects and never hangs. A
|
|
360
367
|
refused close settles nothing, and a `complete` after a dismissal is
|
|
@@ -755,12 +762,16 @@ onClick }`.
|
|
|
755
762
|
- **`ok`** runs its `onClick` when written, then completes. Without one, it
|
|
756
763
|
submits the `BbForm` inside (validation first; an invalid form stays
|
|
757
764
|
open), and a successful save completes with what it resolved, else the
|
|
758
|
-
form's values. Enter in a field completes the same way
|
|
759
|
-
more: it completes with `data`.
|
|
765
|
+
form's values. Enter in a field completes the same way (`ok` is the form's
|
|
766
|
+
submit button). No form, or two or more: it completes with `data`.
|
|
760
767
|
- **`cancel`** runs its `onClick`, then closes as a dismissal
|
|
761
768
|
(`reason: 'close'`); refused while a save locks the dialog.
|
|
762
769
|
- **`actions`** replaces both: an array of button configs, each running its
|
|
763
770
|
`onClick`, then completing with `data`. `false`: none.
|
|
771
|
+
- **While one button's `onClick` runs or a form inside saves, the others
|
|
772
|
+
ignore clicks** without greying out (the running one spins); Cancel is
|
|
773
|
+
refused like the ✕.
|
|
774
|
+
Buttons of your own `#footer` are yours to handle.
|
|
764
775
|
- **`false` from an `onClick`** keeps the dialog open; a throw keeps it open
|
|
765
776
|
and is reported once (a `BbValidationError` never is).
|
|
766
777
|
- **`ok` is never disabled until the form is valid**: the user submits, the
|
|
@@ -1128,8 +1139,9 @@ import { BbDialog, BbForm, BbTextInput } from 'bitboss-ui';
|
|
|
1128
1139
|
|
|
1129
1140
|
type Role = { id?: number; name: string };
|
|
1130
1141
|
const props = defineProps<{ role?: Role }>();
|
|
1131
|
-
// A 422 rejects with the field errors; the form shows them.
|
|
1132
|
-
|
|
1142
|
+
// A 422 rejects with the field errors; the form shows them. The slot's
|
|
1143
|
+
// `data` is untyped, so the form hands back a plain record.
|
|
1144
|
+
const save = (values: Record<string, unknown>) =>
|
|
1133
1145
|
props.role
|
|
1134
1146
|
? api.put(`/roles/${props.role.id}`, values)
|
|
1135
1147
|
: api.post('/roles', values);
|