bitboss-ui 3.0.0-beta.67 → 3.0.0-beta.69
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 +230 -91
- package/bin/bitboss-ui-mcp.mjs +368 -142
- package/bin/bitboss-ui.mjs +24 -2073
- package/bin/cli.mjs +1922 -0
- package/dist/ai/BbAccordion.md +1 -1
- package/dist/ai/BbAlert.md +16 -12
- package/dist/ai/BbAsterisk.md +1 -1
- package/dist/ai/BbAvatar.md +3 -3
- package/dist/ai/BbBadge.md +5 -5
- package/dist/ai/BbBadgeButton.md +1 -1
- package/dist/ai/BbBaseButton.md +1 -1
- package/dist/ai/BbBaseCheckboxIcon.md +4 -0
- package/dist/ai/BbBaseRadioIcon.md +7 -3
- package/dist/ai/BbBaseSwitchIcon.md +11 -2
- package/dist/ai/BbBreadcrumbs.md +3 -3
- package/dist/ai/BbButton.md +63 -10
- package/dist/ai/BbCalendar.md +15 -2
- package/dist/ai/BbCarousel.md +1093 -0
- package/dist/ai/BbCheckbox.md +28 -8
- package/dist/ai/BbCheckboxGroup.md +65 -32
- package/dist/ai/BbColorInput.md +18 -15
- package/dist/ai/BbColorPalette.md +9 -6
- package/dist/ai/BbConfigScope.md +218 -0
- package/dist/ai/BbConfirm.md +25 -22
- package/dist/ai/BbDatePicker.md +12 -6
- package/dist/ai/BbDatePickerInput.md +29 -18
- package/dist/ai/BbDialog.md +11 -10
- package/dist/ai/BbDropdown.md +36 -29
- package/dist/ai/BbDropdownButton.md +21 -21
- package/dist/ai/BbDropzone.md +5 -16
- package/dist/ai/BbForm.md +14 -8
- package/dist/ai/BbHost.md +20 -14
- package/dist/ai/BbHoverCard.md +2 -2
- package/dist/ai/BbIcon.md +3 -3
- package/dist/ai/BbIndicator.md +4 -4
- package/dist/ai/BbNumberInput.md +20 -16
- package/dist/ai/BbOffCanvas.md +15 -10
- package/dist/ai/BbPagination.md +15 -6
- package/dist/ai/BbPopover.md +16 -9
- package/dist/ai/BbRadio.md +30 -9
- package/dist/ai/BbRadioGroup.md +78 -35
- package/dist/ai/BbRating.md +13 -11
- package/dist/ai/BbSelect.md +84 -49
- package/dist/ai/BbSelectPopover.md +33 -31
- package/dist/ai/BbSlider.md +266 -66
- package/dist/ai/BbSpinner.md +3 -3
- package/dist/ai/BbSwitch.md +33 -9
- package/dist/ai/BbSwitchGroup.md +27 -18
- package/dist/ai/BbTable.md +28 -25
- package/dist/ai/BbTabs.md +29 -32
- package/dist/ai/BbTabsList.md +4 -4
- package/dist/ai/BbTabsRoot.md +2 -2
- package/dist/ai/BbTag.md +15 -14
- package/dist/ai/BbTextInput.md +32 -22
- package/dist/ai/BbTextarea.md +20 -18
- package/dist/ai/BbTimePicker.md +5 -5
- package/dist/ai/BbTimePickerInput.md +15 -14
- package/dist/ai/BbToast.md +72 -28
- package/dist/ai/BbTooltip.md +7 -6
- package/dist/ai/BbTree.md +1 -1
- package/dist/ai/ChipsBox.md +1 -1
- package/dist/ai/ClearableButton.md +1 -1
- package/dist/ai/CommonField.md +5 -5
- package/dist/ai/CommonFieldInput.md +3 -2
- package/dist/ai/CommonPopover.md +4 -4
- package/dist/ai/CommonTimeSelector.md +1 -1
- package/dist/ai/ErrorIcon.md +1 -1
- package/dist/ai/FlatListBox.md +5 -4
- package/dist/ai/GroupedListBox.md +5 -4
- package/dist/ai/ListBox.md +6 -5
- package/dist/ai/OptionsContainer.md +20 -4
- package/dist/ai/WarningIcon.md +1 -1
- package/dist/ai/changelog.json +1002 -39
- package/dist/ai/components.json +117 -246
- package/dist/ai/composables/useBbConfig.md +3 -3
- package/dist/ai/composables/useBbDialog.md +1 -1
- package/dist/ai/composables/useBbFormField.md +1 -1
- package/dist/ai/composables/useConfirm.md +1 -1
- package/dist/ai/composables/useToast.md +16 -16
- package/dist/ai/design-tokens.json +10 -5
- package/dist/ai/guides/agent-contract.md +15 -10
- package/dist/ai/guides/ai-router.md +15 -10
- package/dist/ai/guides/app-layout.md +1 -1
- package/dist/ai/guides/calendars-and-digits.md +123 -0
- package/dist/ai/guides/component-picker.md +1 -1
- package/dist/ai/guides/design-language.md +18 -14
- package/dist/ai/guides/design-tokens.md +85 -43
- package/dist/ai/guides/eslint-rules.md +21 -2
- package/dist/ai/guides/fetch-items-playbook.md +1 -1
- package/dist/ai/guides/icons-policy.md +1 -1
- package/dist/ai/guides/inertia-helpers.md +322 -41
- package/dist/ai/guides/inline-edit-playbook.md +1 -1
- package/dist/ai/guides/installation-and-plugin-setup.md +498 -189
- package/dist/ai/guides/migration/adoption-checklist.md +5 -5
- package/dist/ai/guides/migration/components/bb-alert.md +2 -2
- package/dist/ai/guides/migration/components/bb-badge.md +1 -1
- package/dist/ai/guides/migration/components/bb-checkbox-group.md +15 -15
- package/dist/ai/guides/migration/components/bb-dialog.md +2 -2
- package/dist/ai/guides/migration/components/bb-dropdown.md +1 -1
- package/dist/ai/guides/migration/components/bb-host.md +10 -8
- package/dist/ai/guides/migration/components/bb-offcanvas.md +1 -1
- package/dist/ai/guides/migration/components/bb-rating.md +1 -1
- package/dist/ai/guides/migration/components/bb-select-popover.md +2 -2
- package/dist/ai/guides/migration/components/bb-select.md +3 -3
- package/dist/ai/guides/migration/components/bb-slider.md +17 -2
- package/dist/ai/guides/migration/components/bb-table.md +1 -0
- package/dist/ai/guides/migration/components/bb-tabs.md +33 -15
- package/dist/ai/guides/migration/components/bb-toast.md +10 -9
- package/dist/ai/guides/migration/components/use-confirm.md +1 -1
- package/dist/ai/guides/migration/v2-to-v3.md +345 -76
- package/dist/ai/guides/migration/v3-beta-css-classes.md +1 -0
- package/dist/ai/guides/migration/v3-beta-tooling.md +30 -13
- package/dist/ai/guides/options-items-playbook.md +5 -1
- package/dist/ai/guides/passthrough.md +150 -135
- package/dist/ai/guides/ssr-prefill.md +7 -1
- package/dist/ai/guides/typescript-generic-components.md +7 -7
- package/dist/ai/guides/validated-forms.md +14 -5
- package/dist/ai/guides/validation-libraries.md +4 -4
- package/dist/ai/helpers/inertia/manifest.json +23 -14
- package/dist/ai/helpers/inertia/useQuery.ts +74 -0
- package/dist/ai/helpers/inertia/useQueryObject.ts +33 -1
- package/dist/ai/helpers/inertia/useRouteQuery.ts +158 -30
- package/dist/ai/index.md +5 -3
- package/dist/ai/manifest/common.json +13 -15
- package/dist/ai/manifest/components/BbAccordion.tree.json +22 -4
- package/dist/ai/manifest/components/BbAlert.json +3 -2
- package/dist/ai/manifest/components/BbAlert.tree.json +26 -3
- package/dist/ai/manifest/components/BbAsterisk.tree.json +7 -1
- package/dist/ai/manifest/components/BbAvatar.json +2 -1
- package/dist/ai/manifest/components/BbAvatar.tree.json +16 -2
- package/dist/ai/manifest/components/BbBadge.json +4 -3
- package/dist/ai/manifest/components/BbBadge.tree.json +39 -4
- package/dist/ai/manifest/components/BbBadgeButton.tree.json +2 -2
- package/dist/ai/manifest/components/BbBaseButton.tree.json +16 -1
- package/dist/ai/manifest/components/BbBaseCheckboxIcon.tree.json +23 -2
- package/dist/ai/manifest/components/BbBaseRadioIcon.tree.json +21 -4
- package/dist/ai/manifest/components/BbBaseSwitchIcon.tree.json +26 -2
- package/dist/ai/manifest/components/BbBreadcrumbs.json +1 -1
- package/dist/ai/manifest/components/BbBreadcrumbs.tree.json +34 -4
- package/dist/ai/manifest/components/BbButton.json +5 -4
- package/dist/ai/manifest/components/BbButton.tree.json +78 -5
- package/dist/ai/manifest/components/BbCalendar.json +2 -2
- package/dist/ai/manifest/components/BbCalendar.tree.json +81 -5
- package/dist/ai/manifest/components/BbCarousel.json +59 -0
- package/dist/ai/manifest/components/BbCarousel.tree.json +135 -0
- package/dist/ai/manifest/components/BbCheckbox.json +5 -4
- package/dist/ai/manifest/components/BbCheckbox.tree.json +31 -2
- package/dist/ai/manifest/components/BbCheckboxGroup.json +18 -15
- package/dist/ai/manifest/components/BbCheckboxGroup.removed.json +1 -1
- package/dist/ai/manifest/components/BbCheckboxGroup.tree.json +89 -5
- package/dist/ai/manifest/components/BbCollapsible.tree.json +11 -1
- package/dist/ai/manifest/components/BbColorInput.json +7 -6
- package/dist/ai/manifest/components/BbColorInput.tree.json +49 -4
- package/dist/ai/manifest/components/BbColorPalette.json +4 -3
- package/dist/ai/manifest/components/BbColorPalette.tree.json +36 -2
- package/dist/ai/manifest/components/BbConfigScope.json +23 -0
- package/dist/ai/manifest/components/BbConfirm.json +3 -2
- package/dist/ai/manifest/components/BbConfirm.tree.json +27 -3
- package/dist/ai/manifest/components/BbDatePicker.json +7 -6
- package/dist/ai/manifest/components/BbDatePicker.tree.json +42 -3
- package/dist/ai/manifest/components/BbDatePickerInput.json +7 -6
- package/dist/ai/manifest/components/BbDatePickerInput.tree.json +86 -5
- package/dist/ai/manifest/components/BbDialog.json +3 -2
- package/dist/ai/manifest/components/BbDialog.tree.json +28 -3
- package/dist/ai/manifest/components/BbDropdown.json +14 -10
- package/dist/ai/manifest/components/BbDropdown.tree.json +80 -3
- package/dist/ai/manifest/components/BbDropdownButton.json +14 -11
- package/dist/ai/manifest/components/BbDropdownButton.tree.json +47 -4
- package/dist/ai/manifest/components/BbDropzone.json +2 -1
- package/dist/ai/manifest/components/BbDropzone.tree.json +27 -1
- package/dist/ai/manifest/components/BbForm.json +2 -2
- package/dist/ai/manifest/components/BbHost.tree.json +1 -1
- package/dist/ai/manifest/components/BbHoverCard.json +3 -3
- package/dist/ai/manifest/components/BbHoverCard.tree.json +18 -1
- package/dist/ai/manifest/components/BbIcon.json +2 -1
- package/dist/ai/manifest/components/BbIcon.tree.json +7 -1
- package/dist/ai/manifest/components/BbIndicator.json +2 -1
- package/dist/ai/manifest/components/BbIndicator.tree.json +27 -1
- package/dist/ai/manifest/components/BbNumberInput.json +6 -5
- package/dist/ai/manifest/components/BbNumberInput.tree.json +40 -3
- package/dist/ai/manifest/components/BbOffCanvas.json +2 -1
- package/dist/ai/manifest/components/BbOffCanvas.tree.json +55 -2
- package/dist/ai/manifest/components/BbPagination.json +1 -1
- package/dist/ai/manifest/components/BbPagination.tree.json +23 -3
- package/dist/ai/manifest/components/BbPopover.json +5 -4
- package/dist/ai/manifest/components/BbPopover.tree.json +20 -2
- package/dist/ai/manifest/components/BbProgress.tree.json +9 -1
- package/dist/ai/manifest/components/BbRadio.json +3 -2
- package/dist/ai/manifest/components/BbRadio.tree.json +30 -2
- package/dist/ai/manifest/components/BbRadioGroup.json +22 -19
- package/dist/ai/manifest/components/BbRadioGroup.removed.json +1 -1
- package/dist/ai/manifest/components/BbRadioGroup.tree.json +88 -5
- package/dist/ai/manifest/components/BbRating.json +6 -5
- package/dist/ai/manifest/components/BbRating.removed.json +1 -0
- package/dist/ai/manifest/components/BbRating.tree.json +37 -2
- package/dist/ai/manifest/components/BbSelect.json +13 -11
- package/dist/ai/manifest/components/BbSelect.tree.json +70 -7
- package/dist/ai/manifest/components/BbSelectPopover.json +17 -13
- package/dist/ai/manifest/components/BbSelectPopover.tree.json +94 -8
- package/dist/ai/manifest/components/BbSlider.json +30 -27
- package/dist/ai/manifest/components/BbSlider.removed.json +3 -0
- package/dist/ai/manifest/components/BbSlider.tree.json +48 -3
- package/dist/ai/manifest/components/BbSmoothHeight.tree.json +10 -1
- package/dist/ai/manifest/components/BbSpinner.tree.json +21 -2
- package/dist/ai/manifest/components/BbSwitch.json +3 -2
- package/dist/ai/manifest/components/BbSwitch.tree.json +31 -2
- package/dist/ai/manifest/components/BbSwitchGroup.json +9 -7
- package/dist/ai/manifest/components/BbSwitchGroup.removed.json +1 -1
- package/dist/ai/manifest/components/BbSwitchGroup.tree.json +65 -3
- package/dist/ai/manifest/components/BbTable.json +10 -9
- package/dist/ai/manifest/components/BbTable.tree.json +144 -5
- package/dist/ai/manifest/components/BbTabs.json +7 -6
- package/dist/ai/manifest/components/BbTabs.removed.json +5 -1
- package/dist/ai/manifest/components/BbTabs.tree.json +34 -3
- package/dist/ai/manifest/components/BbTabsList.json +4 -4
- package/dist/ai/manifest/components/BbTabsList.removed.json +5 -1
- package/dist/ai/manifest/components/BbTabsList.tree.json +24 -2
- package/dist/ai/manifest/components/BbTabsPanels.tree.json +16 -1
- package/dist/ai/manifest/components/BbTabsRoot.json +3 -3
- package/dist/ai/manifest/components/BbTag.json +7 -6
- package/dist/ai/manifest/components/BbTag.tree.json +49 -4
- package/dist/ai/manifest/components/BbTextInput.json +6 -5
- package/dist/ai/manifest/components/BbTextInput.tree.json +43 -3
- package/dist/ai/manifest/components/BbTextarea.json +7 -6
- package/dist/ai/manifest/components/BbTextarea.tree.json +46 -3
- package/dist/ai/manifest/components/BbTimePicker.json +7 -6
- package/dist/ai/manifest/components/BbTimePicker.tree.json +30 -3
- package/dist/ai/manifest/components/BbTimePickerInput.json +7 -6
- package/dist/ai/manifest/components/BbTimePickerInput.tree.json +58 -6
- package/dist/ai/manifest/components/BbToast.json +3 -2
- package/dist/ai/manifest/components/BbToast.tree.json +46 -2
- package/dist/ai/manifest/components/BbTooltip.json +4 -3
- package/dist/ai/manifest/components/BbTooltip.tree.json +17 -1
- package/dist/ai/manifest/components/BbTree.tree.json +14 -1
- package/dist/ai/manifest/components/ChipsBox.tree.json +1 -1
- package/dist/ai/manifest/components/ClearableButton.tree.json +8 -2
- package/dist/ai/manifest/components/CommonField.json +2 -2
- package/dist/ai/manifest/components/CommonField.tree.json +68 -1
- package/dist/ai/manifest/components/CommonFieldInput.json +2 -2
- package/dist/ai/manifest/components/CommonFieldInput.tree.json +38 -6
- package/dist/ai/manifest/components/CommonPopover.json +7 -5
- package/dist/ai/manifest/components/CommonPopover.tree.json +11 -1
- package/dist/ai/manifest/components/CommonTimeSelector.tree.json +18 -2
- package/dist/ai/manifest/components/ErrorIcon.tree.json +8 -2
- package/dist/ai/manifest/components/FlatListBox.json +1 -1
- package/dist/ai/manifest/components/FlatListBox.tree.json +4 -3
- package/dist/ai/manifest/components/GroupedListBox.json +1 -1
- package/dist/ai/manifest/components/GroupedListBox.tree.json +4 -3
- package/dist/ai/manifest/components/ListBox.json +1 -1
- package/dist/ai/manifest/components/ListBox.tree.json +2 -2
- package/dist/ai/manifest/components/OptionsContainer.json +4 -3
- package/dist/ai/manifest/components/OptionsContainer.tree.json +16 -1
- package/dist/ai/manifest/components/WarningIcon.tree.json +8 -2
- package/dist/ai/manifest/index.json +6 -5
- package/dist/ai/manifest/meta.json +23 -153
- package/dist/ai/manifest/types.advanced.json +78 -77
- package/dist/ai/manifest/types.api.json +29 -19
- package/dist/ai/manifest/types.wrapper.json +115 -112
- package/dist/ai/recipes/inertia/approvals-inbox.md +10 -10
- package/dist/ai/recipes/inertia/inline-edit-workspace.md +24 -20
- package/dist/ai/recipes/inertia/onboarding.md +10 -10
- package/dist/ai/recipes/inertia/ownership-atlas.md +8 -8
- package/dist/ai/recipes/inertia/record-form.md +16 -16
- package/dist/ai/recipes/inertia/records-workspace.md +13 -12
- package/dist/ai/recipes/inertia/settings-workspace.md +16 -15
- package/dist/ai/recipes/inertia/upload-center.md +13 -13
- package/dist/ai/recipes/inertia/wizard-form.md +16 -16
- package/dist/ai/recipes/nuxt/approvals-inbox.md +13 -13
- package/dist/ai/recipes/nuxt/inline-edit-workspace.md +26 -22
- package/dist/ai/recipes/nuxt/onboarding.md +10 -10
- package/dist/ai/recipes/nuxt/ownership-atlas.md +12 -12
- package/dist/ai/recipes/nuxt/record-form.md +16 -16
- package/dist/ai/recipes/nuxt/records-workspace.md +16 -15
- package/dist/ai/recipes/nuxt/settings-workspace.md +15 -14
- package/dist/ai/recipes/nuxt/upload-center.md +15 -15
- package/dist/ai/recipes/nuxt/wizard-form.md +17 -17
- package/dist/ai/recipes/vue/approvals-inbox.md +15 -13
- package/dist/ai/recipes/vue/inline-edit-workspace.md +26 -22
- package/dist/ai/recipes/vue/onboarding.md +16 -11
- package/dist/ai/recipes/vue/ownership-atlas.md +12 -12
- package/dist/ai/recipes/vue/record-form.md +18 -16
- package/dist/ai/recipes/vue/records-workspace.md +18 -15
- package/dist/ai/recipes/vue/settings-workspace.md +18 -15
- package/dist/ai/recipes/vue/upload-center.md +15 -15
- package/dist/ai/recipes/vue/wizard-form.md +18 -16
- package/dist/ai/source/BbAccordion.md +11 -14
- package/dist/ai/source/BbAlert.md +103 -91
- package/dist/ai/source/BbAsterisk.md +6 -7
- package/dist/ai/source/BbAvatar.md +42 -41
- package/dist/ai/source/BbBadge.md +100 -89
- package/dist/ai/source/BbBadgeButton.md +80 -76
- package/dist/ai/source/BbBaseButton.md +284 -276
- package/dist/ai/source/BbBaseCheckboxIcon.md +76 -68
- package/dist/ai/source/BbBaseRadioIcon.md +80 -68
- package/dist/ai/source/BbBaseSwitchIcon.md +98 -74
- package/dist/ai/source/BbBreadcrumbs.md +76 -63
- package/dist/ai/source/BbButton.md +101 -77
- package/dist/ai/source/BbCalendar.md +166 -176
- package/dist/ai/source/BbCarousel.md +2897 -0
- package/dist/ai/source/BbCheckbox.md +230 -192
- package/dist/ai/source/BbCheckboxGroup.md +172 -79
- package/dist/ai/source/BbCollapsible.md +7 -10
- package/dist/ai/source/BbColorInput.md +256 -243
- package/dist/ai/source/BbColorPalette.md +239 -160
- package/dist/ai/source/BbConfigScope.md +123 -0
- package/dist/ai/source/BbConfirm.md +38 -32
- package/dist/ai/source/BbConfirmPortal.md +30 -26
- package/dist/ai/source/BbDatePicker.md +218 -187
- package/dist/ai/source/BbDatePickerInput.md +789 -428
- package/dist/ai/source/BbDialog.md +207 -191
- package/dist/ai/source/BbDropdown.md +326 -234
- package/dist/ai/source/BbDropdownButton.md +115 -68
- package/dist/ai/source/BbDropdownGroup.md +271 -216
- package/dist/ai/source/BbDropzone.md +101 -100
- package/dist/ai/source/BbForm.md +29 -29
- package/dist/ai/source/BbHost.md +6 -6
- package/dist/ai/source/BbHoverCard.md +34 -20
- package/dist/ai/source/BbHoverCardPortal.md +9 -12
- package/dist/ai/source/BbIcon.md +32 -30
- package/dist/ai/source/BbIndicator.md +76 -70
- package/dist/ai/source/BbNumberInput.md +334 -313
- package/dist/ai/source/BbOffCanvas.md +245 -216
- package/dist/ai/source/BbPagination.md +144 -116
- package/dist/ai/source/BbPopover.md +49 -31
- package/dist/ai/source/BbPopoverPortal.md +11 -14
- package/dist/ai/source/BbProgress.md +20 -12
- package/dist/ai/source/BbRadio.md +205 -181
- package/dist/ai/source/BbRadioGroup.md +461 -364
- package/dist/ai/source/BbRating.md +212 -177
- package/dist/ai/source/BbSelect.md +514 -482
- package/dist/ai/source/BbSelectPopover.md +497 -413
- package/dist/ai/source/BbSlider.md +1208 -777
- package/dist/ai/source/BbSmoothHeight.md +8 -9
- package/dist/ai/source/BbSpinner.md +20 -20
- package/dist/ai/source/BbSwitch.md +25 -13
- package/dist/ai/source/BbSwitchGroup.md +115 -34
- package/dist/ai/source/BbTable.md +577 -531
- package/dist/ai/source/BbTabs.md +134 -116
- package/dist/ai/source/BbTabsList.md +164 -136
- package/dist/ai/source/BbTabsPanels.md +128 -113
- package/dist/ai/source/BbTabsRoot.md +125 -110
- package/dist/ai/source/BbTag.md +286 -281
- package/dist/ai/source/BbTextInput.md +59 -50
- package/dist/ai/source/BbTextarea.md +85 -71
- package/dist/ai/source/BbTimePicker.md +145 -126
- package/dist/ai/source/BbTimePickerInput.md +383 -316
- package/dist/ai/source/BbToast.md +97 -44
- package/dist/ai/source/BbToastPortal.md +56 -36
- package/dist/ai/source/BbTooltip.md +155 -129
- package/dist/ai/source/BbTree.md +16 -12
- package/dist/ai/source/CommonField.md +94 -59
- package/dist/ai/source/CommonFieldInput.md +18 -13
- package/dist/ai/source/CommonPopover.md +28 -9
- package/dist/ai/source/CommonTimeSelector.md +41 -8
- package/dist/ai/source/FlatListBox.md +16 -5
- package/dist/ai/source/GroupedListBox.md +18 -6
- package/dist/ai/source/ListBox.md +2 -1
- package/dist/ai/source/OptionsContainer.md +82 -4
- package/dist/assets/svgs/arrow_up.svg_raw.js +3 -0
- package/dist/assets/svgs/caret_down.svg_raw.js +3 -0
- package/dist/assets/svgs/chevron_left.svg_raw.js +3 -0
- package/dist/assets/svgs/chevron_left_small.svg_raw.js +3 -0
- package/dist/assets/svgs/chevron_right_small.svg_raw.js +3 -0
- package/dist/assets/svgs/close.svg_raw.js +3 -0
- package/dist/assets/svgs/eyedropper.svg_raw.js +3 -0
- package/dist/assets/svgs/move.svg_raw.js +3 -0
- package/dist/assets/svgs/pause.svg_raw.js +3 -0
- package/dist/assets/svgs/play.svg_raw.js +3 -0
- package/dist/assets/svgs/star.svg_raw.js +1 -1
- package/dist/assets/svgs/x.svg_raw.js +3 -0
- package/dist/calendar-runtime.js +112 -0
- package/dist/calendars.js +83 -0
- package/dist/components/BbAccordion/BbAccordion.vue.d.ts +2 -2
- package/dist/components/BbAccordion/BbAccordion.vue_vue_type_script_setup_true_lang.js +4 -4
- package/dist/components/BbAccordion/ptKeys.generated.d.ts +44 -0
- package/dist/components/BbAccordion/types.d.ts +5 -6
- package/dist/components/BbAlert/BbAlert.vue.d.ts +5 -4
- package/dist/components/BbAlert/BbAlert.vue_vue_type_script_setup_true_lang.js +52 -48
- package/dist/components/BbAlert/ptKeys.generated.d.ts +104 -0
- package/dist/components/BbAlert/types.d.ts +16 -9
- package/dist/components/BbAsterisk/BbAsterisk.vue.d.ts +2 -2
- package/dist/components/BbAsterisk/ptKeys.generated.d.ts +8 -0
- package/dist/components/BbAsterisk/types.d.ts +4 -5
- package/dist/components/BbAvatar/BbAvatar.vue.d.ts +3 -3
- package/dist/components/BbAvatar/BbAvatar.vue_vue_type_script_setup_true_lang.js +54 -53
- package/dist/components/BbAvatar/ptKeys.generated.d.ts +12 -0
- package/dist/components/BbAvatar/types.d.ts +5 -6
- package/dist/components/BbBadge/BbBadge.vue.d.ts +4 -4
- package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +75 -71
- package/dist/components/BbBadge/BbBadgeButton.vue.d.ts +2 -2
- package/dist/components/BbBadge/badgeButtonContext.d.ts +5 -5
- package/dist/components/BbBadge/ptKeys.generated.d.ts +160 -0
- package/dist/components/BbBadge/types.d.ts +17 -10
- package/dist/components/BbBaseButton/BbBaseButton.vue.d.ts +2 -2
- package/dist/components/BbBaseButton/ptKeys.generated.d.ts +20 -0
- package/dist/components/BbBaseButton/types.d.ts +13 -6
- package/dist/components/BbBaseButton/useLinkState.d.ts +1 -1
- package/dist/components/BbBaseCheckboxIcon/BbBaseCheckboxIcon.vue.d.ts +2 -2
- package/dist/components/BbBaseCheckboxIcon/BbBaseCheckboxIcon.vue_vue_type_script_setup_true_lang.js +4 -4
- package/dist/components/BbBaseCheckboxIcon/ptKeys.generated.d.ts +40 -0
- package/dist/components/BbBaseCheckboxIcon/types.d.ts +12 -6
- package/dist/components/BbBaseRadioIcon/BbBaseRadioIcon.vue.d.ts +2 -2
- package/dist/components/BbBaseRadioIcon/BbBaseRadioIcon.vue_vue_type_script_setup_true_lang.js +4 -4
- package/dist/components/BbBaseRadioIcon/ptKeys.generated.d.ts +36 -0
- package/dist/components/BbBaseRadioIcon/types.d.ts +12 -6
- package/dist/components/BbBaseSwitchIcon/BbBaseSwitchIcon.vue.d.ts +2 -2
- package/dist/components/BbBaseSwitchIcon/BbBaseSwitchIcon.vue_vue_type_script_setup_true_lang.js +4 -4
- package/dist/components/BbBaseSwitchIcon/ptKeys.generated.d.ts +40 -0
- package/dist/components/BbBaseSwitchIcon/types.d.ts +12 -6
- package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue.d.ts +2 -2
- package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue_vue_type_script_setup_true_lang.js +5 -5
- package/dist/components/BbBreadcrumbs/ptKeys.generated.d.ts +48 -0
- package/dist/components/BbBreadcrumbs/types.d.ts +15 -8
- package/dist/components/BbButton/BbButton.vue.d.ts +6 -4
- package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +130 -118
- package/dist/components/BbButton/ptKeys.generated.d.ts +196 -0
- package/dist/components/BbButton/toggleRoving.js +29 -28
- package/dist/components/BbButton/types.d.ts +29 -21
- package/dist/components/BbCalendar/BbCalendar.vue.d.ts +9 -71
- package/dist/components/BbCalendar/BbCalendar.vue_vue_type_script_setup_true_lang.js +327 -340
- package/dist/components/BbCalendar/CalendarMonthPanel.vue_vue_type_script_setup_true_lang.js +67 -65
- package/dist/components/BbCalendar/CalendarYearPanel.vue_vue_type_script_setup_true_lang.js +76 -67
- package/dist/components/BbCalendar/calendarHost.d.ts +1 -1
- package/dist/components/BbCalendar/calendarMath.d.ts +102 -0
- package/dist/components/BbCalendar/calendarMath.js +124 -0
- package/dist/components/BbCalendar/ptKeys.generated.d.ts +248 -0
- package/dist/components/BbCalendar/types.d.ts +15 -9
- package/dist/components/BbCalendar/useCalendarContext.d.ts +43 -17
- package/dist/components/BbCalendar/useCalendarGrid.d.ts +71 -4
- package/dist/components/BbCalendar/useCalendarGrid.js +264 -209
- package/dist/components/BbCalendar/useDayGrid.d.ts +26 -8
- package/dist/components/BbCalendar/useDayGrid.js +178 -172
- package/dist/components/BbCalendar/useDayjsLocale.d.ts +18 -3
- package/dist/components/BbCalendar/useDayjsLocale.js +28 -28
- package/dist/components/BbCalendar/useToday.d.ts +5 -3
- package/dist/components/BbCalendar/useToday.js +22 -12
- package/dist/components/BbCarousel/BbCarousel.vue.d.ts +51 -0
- package/dist/components/BbCarousel/BbCarousel.vue.js +5 -0
- package/dist/components/BbCarousel/BbCarousel.vue_vue_type_script_setup_true_lang.js +818 -0
- package/dist/components/BbCarousel/ptKeys.generated.d.ts +60 -0
- package/dist/components/BbCarousel/types.d.ts +213 -0
- package/dist/components/BbCarousel/types.js +27 -0
- package/dist/components/BbCheckbox/BbCheckbox.vue.d.ts +8 -6
- package/dist/components/BbCheckbox/BbCheckbox.vue_vue_type_script_setup_true_lang.js +123 -111
- package/dist/components/BbCheckbox/ptKeys.generated.d.ts +220 -0
- package/dist/components/BbCheckbox/types.d.ts +30 -14
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.d.ts +167 -306
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +222 -189
- package/dist/components/BbCheckboxGroup/ptKeys.generated.d.ts +492 -0
- package/dist/components/BbCheckboxGroup/types.d.ts +42 -28
- package/dist/components/BbCollapsible/BbCollapsible.vue.d.ts +4 -4
- package/dist/components/BbCollapsible/BbCollapsible.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/BbCollapsible/ptKeys.generated.d.ts +20 -0
- package/dist/components/BbCollapsible/types.d.ts +5 -6
- package/dist/components/BbColorInput/BbColorInput.vue.d.ts +16 -14
- package/dist/components/BbColorInput/BbColorInput.vue_vue_type_script_setup_true_lang.js +206 -195
- package/dist/components/BbColorInput/ptKeys.generated.d.ts +656 -0
- package/dist/components/BbColorInput/types.d.ts +30 -20
- package/dist/components/BbColorInput/types.js +1 -1
- package/dist/components/BbColorPalette/BbColorPalette.vue.d.ts +4 -4
- package/dist/components/BbColorPalette/BbColorPalette.vue_vue_type_script_setup_true_lang.js +331 -296
- package/dist/components/BbColorPalette/ptKeys.generated.d.ts +40 -0
- package/dist/components/BbColorPalette/types.d.ts +17 -10
- package/dist/components/BbConfigScope/BbConfigScope.vue.d.ts +12 -0
- package/dist/components/BbConfigScope/BbConfigScope.vue.js +4 -0
- package/dist/components/BbConfigScope/BbConfigScope.vue_vue_type_script_setup_true_lang.js +37 -0
- package/dist/components/BbConfigScope/types.d.ts +20 -0
- package/dist/components/BbConfirm/BbConfirm.vue.d.ts +1 -1
- package/dist/components/BbConfirm/BbConfirm.vue_vue_type_script_setup_true_lang.js +27 -27
- package/dist/components/BbConfirm/BbConfirmPortal.vue.d.ts +1 -1
- package/dist/components/BbConfirm/confirmEntry.d.ts +2 -2
- package/dist/components/BbConfirm/ptKeys.generated.d.ts +184 -0
- package/dist/components/BbConfirm/types.d.ts +14 -7
- package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +16 -97
- package/dist/components/BbDatePicker/BbDatePicker.vue_vue_type_script_setup_true_lang.js +201 -197
- package/dist/components/BbDatePicker/ptKeys.generated.d.ts +324 -0
- package/dist/components/BbDatePicker/types.d.ts +22 -15
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +20 -309
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +793 -660
- package/dist/components/BbDatePickerInput/calendarFields.d.ts +91 -0
- package/dist/components/BbDatePickerInput/calendarFields.js +188 -0
- package/dist/components/BbDatePickerInput/dateFieldLayout.d.ts +6 -0
- package/dist/components/BbDatePickerInput/dateFieldLayout.js +11 -1
- package/dist/components/BbDatePickerInput/ptKeys.generated.d.ts +1156 -0
- package/dist/components/BbDatePickerInput/types.d.ts +36 -26
- package/dist/components/BbDatePickerInput/types.js +1 -1
- package/dist/components/BbDialog/BbDialog.vue.d.ts +9 -8
- package/dist/components/BbDialog/BbDialog.vue_vue_type_script_setup_true_lang.js +211 -204
- package/dist/components/BbDialog/ptKeys.generated.d.ts +100 -0
- package/dist/components/BbDialog/types.d.ts +26 -20
- package/dist/components/BbDropdown/AdaptiveDropdown.vue.d.ts +1 -1
- package/dist/components/BbDropdown/BbDropdown.vue.d.ts +7 -6
- package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +399 -377
- package/dist/components/BbDropdown/BbDropdownGroup.vue.d.ts +2 -2
- package/dist/components/BbDropdown/BbDropdownList.vue.d.ts +1 -1
- package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +297 -292
- package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +97 -97
- package/dist/components/BbDropdown/DropdownRow.vue.d.ts +3 -3
- package/dist/components/BbDropdown/DropdownRow.vue_vue_type_script_setup_true_lang.js +2 -2
- package/dist/components/BbDropdown/normalizeGroups.d.ts +2 -2
- package/dist/components/BbDropdown/pointerTrail.d.ts +5 -0
- package/dist/components/BbDropdown/pointerTrail.js +26 -0
- package/dist/components/BbDropdown/ptKeys.generated.d.ts +228 -0
- package/dist/components/BbDropdown/types.d.ts +65 -48
- package/dist/components/BbDropdown/types.js +11 -2
- package/dist/components/BbDropdown/useDropdownContext.d.ts +3 -3
- package/dist/components/BbDropdown/useDropdownGroupRegistry.d.ts +5 -5
- package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +7 -6
- package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +168 -144
- package/dist/components/BbDropdownButton/ptKeys.generated.d.ts +616 -0
- package/dist/components/BbDropdownButton/types.d.ts +47 -23
- package/dist/components/BbDropdownButton/types.js +7 -3
- package/dist/components/BbDropzone/BbDropzone.vue.d.ts +7 -26
- package/dist/components/BbDropzone/BbDropzone.vue_vue_type_script_setup_true_lang.js +14 -14
- package/dist/components/BbDropzone/ptKeys.generated.d.ts +76 -0
- package/dist/components/BbDropzone/types.d.ts +15 -8
- package/dist/components/BbForm/BbForm.vue.d.ts +5 -5
- package/dist/components/BbForm/BbFormCustomField.d.ts +1 -1
- package/dist/components/BbForm/BbFormCustomField.js +2 -2
- package/dist/components/BbForm/bindFormField.d.ts +4 -4
- package/dist/components/BbForm/bindFormField.js +66 -66
- package/dist/components/BbForm/formFields.d.ts +5 -5
- package/dist/components/BbForm/formSchema.d.ts +4 -4
- package/dist/components/BbHost/BbHost.vue.d.ts +1 -1
- package/dist/components/BbHost/BbHost.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/BbHost/BbHostOpening.d.ts +4 -4
- package/dist/components/BbHost/types.d.ts +3 -3
- package/dist/components/BbHoverCard/BbHoverCard.vue.d.ts +4 -4
- package/dist/components/BbHoverCard/BbHoverCard.vue_vue_type_script_setup_true_lang.js +169 -162
- package/dist/components/BbHoverCard/BbHoverCardPortal.vue.d.ts +1 -1
- package/dist/components/BbHoverCard/ptKeys.generated.d.ts +44 -0
- package/dist/components/BbHoverCard/types.d.ts +8 -9
- package/dist/components/BbIcon/BbIcon.vue.d.ts +3 -3
- package/dist/components/BbIcon/BbIcon.vue_vue_type_script_setup_true_lang.js +41 -40
- package/dist/components/BbIcon/ptKeys.generated.d.ts +8 -0
- package/dist/components/BbIcon/types.d.ts +7 -8
- package/dist/components/BbIndicator/BbIndicator.vue.d.ts +4 -4
- package/dist/components/BbIndicator/BbIndicator.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/BbIndicator/ptKeys.generated.d.ts +52 -0
- package/dist/components/BbIndicator/types.d.ts +15 -8
- package/dist/components/BbNumberInput/BbNumberInput.vue.d.ts +15 -12
- package/dist/components/BbNumberInput/BbNumberInput.vue_vue_type_script_setup_true_lang.js +327 -311
- package/dist/components/BbNumberInput/numberDisplay.d.ts +10 -11
- package/dist/components/BbNumberInput/ptKeys.generated.d.ts +476 -0
- package/dist/components/BbNumberInput/types.d.ts +33 -22
- package/dist/components/BbNumberInput/types.js +1 -1
- package/dist/components/BbOffCanvas/BbOffCanvas.vue.d.ts +9 -9
- package/dist/components/BbOffCanvas/BbOffCanvas.vue_vue_type_script_setup_true_lang.js +408 -406
- package/dist/components/BbOffCanvas/ptKeys.generated.d.ts +88 -0
- package/dist/components/BbOffCanvas/sheetAttrs.d.ts +1 -1
- package/dist/components/BbOffCanvas/sheetSnap.d.ts +2 -2
- package/dist/components/BbOffCanvas/types.d.ts +30 -23
- package/dist/components/BbOffCanvas/useOffCanvasStack.d.ts +1 -1
- package/dist/components/BbPagination/BbPagination.vue.d.ts +3 -3
- package/dist/components/BbPagination/BbPagination.vue_vue_type_script_setup_true_lang.js +110 -114
- package/dist/components/BbPagination/paginationFit.d.ts +1 -1
- package/dist/components/BbPagination/ptKeys.generated.d.ts +48 -0
- package/dist/components/BbPagination/types.d.ts +16 -8
- package/dist/components/BbPopover/BbPopover.vue.d.ts +4 -4
- package/dist/components/BbPopover/BbPopover.vue_vue_type_script_setup_true_lang.js +121 -115
- package/dist/components/BbPopover/BbPopoverPortal.vue.d.ts +1 -1
- package/dist/components/BbPopover/ptKeys.generated.d.ts +52 -0
- package/dist/components/BbPopover/types.d.ts +10 -11
- package/dist/components/BbProgress/BbProgress.vue.d.ts +2 -2
- package/dist/components/BbProgress/BbProgress.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/BbProgress/ptKeys.generated.d.ts +20 -0
- package/dist/components/BbProgress/types.d.ts +4 -5
- package/dist/components/BbRadio/BbRadio.vue.d.ts +8 -6
- package/dist/components/BbRadio/BbRadio.vue_vue_type_script_setup_true_lang.js +134 -122
- package/dist/components/BbRadio/ptKeys.generated.d.ts +196 -0
- package/dist/components/BbRadio/types.d.ts +24 -13
- package/dist/components/BbRadioGroup/BbRadioGroup.vue.d.ts +152 -248
- package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +248 -215
- package/dist/components/BbRadioGroup/ptKeys.generated.d.ts +492 -0
- package/dist/components/BbRadioGroup/types.d.ts +41 -24
- package/dist/components/BbRating/BbRating.vue.d.ts +9 -7
- package/dist/components/BbRating/BbRating.vue_vue_type_script_setup_true_lang.js +153 -142
- package/dist/components/BbRating/ptKeys.generated.d.ts +152 -0
- package/dist/components/BbRating/types.d.ts +31 -20
- package/dist/components/BbRating/types.js +1 -1
- package/dist/components/BbSelect/BbSelect.vue.d.ts +269 -483
- package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +362 -341
- package/dist/components/BbSelect/ptKeys.generated.d.ts +960 -0
- package/dist/components/BbSelect/types.d.ts +50 -37
- package/dist/components/BbSelect/types.js +4 -2
- package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +23 -50
- package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +750 -730
- package/dist/components/BbSelectPopover/knownItems.d.ts +4 -4
- package/dist/components/BbSelectPopover/ptKeys.generated.d.ts +148 -0
- package/dist/components/BbSelectPopover/reclickClears.d.ts +17 -0
- package/dist/components/BbSelectPopover/reclickClears.js +4 -0
- package/dist/components/BbSelectPopover/sheetChipAttrs.d.ts +1 -1
- package/dist/components/BbSelectPopover/types.d.ts +44 -31
- package/dist/components/BbSelectPopover/types.js +3 -1
- package/dist/components/BbSlider/BbSlider.vue.d.ts +27 -86
- package/dist/components/BbSlider/BbSlider.vue_vue_type_script_setup_true_lang.js +414 -331
- package/dist/components/BbSlider/ptKeys.generated.d.ts +316 -0
- package/dist/components/BbSlider/types.d.ts +162 -61
- package/dist/components/BbSlider/types.js +2 -0
- package/dist/components/BbSmoothHeight/BbSmoothHeight.vue.d.ts +3 -3
- package/dist/components/BbSmoothHeight/ptKeys.generated.d.ts +8 -0
- package/dist/components/BbSmoothHeight/types.d.ts +5 -6
- package/dist/components/BbSpinner/BbSpinner.vue.d.ts +3 -3
- package/dist/components/BbSpinner/ptKeys.generated.d.ts +8 -0
- package/dist/components/BbSpinner/types.d.ts +5 -6
- package/dist/components/BbSwitch/BbSwitch.vue.d.ts +6 -6
- package/dist/components/BbSwitch/BbSwitch.vue_vue_type_script_setup_true_lang.js +30 -30
- package/dist/components/BbSwitch/ptKeys.generated.d.ts +220 -0
- package/dist/components/BbSwitch/types.d.ts +15 -5
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.d.ts +38 -116
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +13 -10
- package/dist/components/BbSwitchGroup/ptKeys.generated.d.ts +332 -0
- package/dist/components/BbSwitchGroup/types.d.ts +14 -5
- package/dist/components/BbTable/BbTable.vue.d.ts +13 -13
- package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +1360 -1366
- package/dist/components/BbTable/BbTableDataRow.d.ts +4 -4
- package/dist/components/BbTable/BbTableEdgeRow.d.ts +5 -5
- package/dist/components/BbTable/BbTableExpandRow.d.ts +2 -2
- package/dist/components/BbTable/BbTableSelectToggle.d.ts +3 -3
- package/dist/components/BbTable/estimatedFloors.golden.d.ts +1 -1
- package/dist/components/BbTable/gridWidgets.d.ts +1 -1
- package/dist/components/BbTable/measuredFloors.d.ts +1 -1
- package/dist/components/BbTable/measuredFloorsTestKit.d.ts +1 -1
- package/dist/components/BbTable/ptKeys.generated.d.ts +280 -0
- package/dist/components/BbTable/types.d.ts +30 -22
- package/dist/components/BbTable/utils.d.ts +5 -5
- package/dist/components/BbTable/utils.js +89 -88
- package/dist/components/BbTabs/BbTabs.vue.d.ts +41 -69
- package/dist/components/BbTabs/BbTabs.vue_vue_type_script_setup_true_lang.js +21 -15
- package/dist/components/BbTabs/BbTabsList.vue.d.ts +3 -3
- package/dist/components/BbTabs/BbTabsList.vue_vue_type_script_setup_true_lang.js +121 -122
- package/dist/components/BbTabs/BbTabsPanels.vue.d.ts +3 -3
- package/dist/components/BbTabs/BbTabsPanels.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/BbTabs/BbTabsRoot.vue.d.ts +2 -2
- package/dist/components/BbTabs/ptKeys.generated.d.ts +226 -0
- package/dist/components/BbTabs/types.d.ts +41 -23
- package/dist/components/BbTag/BbTag.vue.d.ts +18 -16
- package/dist/components/BbTag/BbTag.vue_vue_type_script_setup_true_lang.js +248 -238
- package/dist/components/BbTag/ptKeys.generated.d.ts +540 -0
- package/dist/components/BbTag/types.d.ts +28 -18
- package/dist/components/BbTag/types.js +1 -1
- package/dist/components/BbTextInput/BbTextInput.vue.d.ts +19 -171
- package/dist/components/BbTextInput/BbTextInput.vue_vue_type_script_setup_true_lang.js +176 -165
- package/dist/components/BbTextInput/ptKeys.generated.d.ts +608 -0
- package/dist/components/BbTextInput/types.d.ts +30 -21
- package/dist/components/BbTextInput/types.js +1 -1
- package/dist/components/BbTextarea/BbTextarea.vue.d.ts +19 -171
- package/dist/components/BbTextarea/BbTextarea.vue_vue_type_script_setup_true_lang.js +206 -196
- package/dist/components/BbTextarea/ptKeys.generated.d.ts +608 -0
- package/dist/components/BbTextarea/types.d.ts +29 -20
- package/dist/components/BbTextarea/types.js +1 -1
- package/dist/components/BbTimePicker/BbTimePicker.vue.d.ts +13 -33
- package/dist/components/BbTimePicker/BbTimePicker.vue_vue_type_script_setup_true_lang.js +137 -136
- package/dist/components/BbTimePicker/ptKeys.generated.d.ts +80 -0
- package/dist/components/BbTimePicker/types.d.ts +19 -13
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue.d.ts +18 -201
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +421 -397
- package/dist/components/BbTimePickerInput/ptKeys.generated.d.ts +732 -0
- package/dist/components/BbTimePickerInput/types.d.ts +35 -23
- package/dist/components/BbTimePickerInput/types.js +1 -1
- package/dist/components/BbToast/BbToast.vue.d.ts +2 -2
- package/dist/components/BbToast/BbToast.vue_vue_type_script_setup_true_lang.js +60 -53
- package/dist/components/BbToast/BbToastMessage.vue.d.ts +2 -2
- package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +75 -80
- package/dist/components/BbToast/BbToastPortal.vue.d.ts +1 -1
- package/dist/components/BbToast/BbToastRegion.vue.d.ts +5 -3
- package/dist/components/BbToast/ptKeys.generated.d.ts +232 -0
- package/dist/components/BbToast/types.d.ts +22 -13
- package/dist/components/BbTooltip/BbTooltip.vue.d.ts +6 -6
- package/dist/components/BbTooltip/BbTooltip.vue_vue_type_script_setup_true_lang.js +99 -88
- package/dist/components/BbTooltip/ptKeys.generated.d.ts +36 -0
- package/dist/components/BbTooltip/tooltipWarmup.d.ts +2 -2
- package/dist/components/BbTooltip/types.d.ts +16 -9
- package/dist/components/BbTree/BbTree.vue.d.ts +7 -11
- package/dist/components/BbTree/BbTreeLevel.vue.d.ts +1 -1
- package/dist/components/BbTree/context.d.ts +2 -2
- package/dist/components/BbTree/ptKeys.generated.d.ts +16 -0
- package/dist/components/BbTree/types.d.ts +5 -6
- package/dist/components/ChipsBox/ChipsBox.vue.d.ts +2 -2
- package/dist/components/ChipsBox/types.d.ts +2 -2
- package/dist/components/ClearableButton/ClearableButton.vue.d.ts +2 -2
- package/dist/components/CloseIcon/CloseButton.vue.d.ts +2 -2
- package/dist/components/CloseIcon/CloseButton.vue.js +1 -1
- package/dist/components/CloseIcon/CloseButton.vue_vue_type_script_setup_true_lang.js +11 -16
- package/dist/components/CommaBox/CommaBox.vue.d.ts +2 -2
- package/dist/components/CommaBox/types.d.ts +2 -2
- package/dist/components/CommonField/CommonField.vue.d.ts +7 -7
- package/dist/components/CommonField/CommonField.vue_vue_type_script_setup_true_lang.js +9 -4
- package/dist/components/CommonField/messageHeightMatrix.d.ts +1 -1
- package/dist/components/CommonField/types.d.ts +18 -14
- package/dist/components/CommonFieldInput/CommonFieldInput.vue.d.ts +3 -3
- package/dist/components/CommonFieldInput/types.d.ts +4 -4
- package/dist/components/CommonPopover/CommonPopover.vue.d.ts +4 -4
- package/dist/components/CommonPopover/CommonPopover.vue_vue_type_script_setup_true_lang.js +56 -55
- package/dist/components/CommonPopover/resolvePlacement.d.ts +9 -0
- package/dist/components/CommonPopover/resolvePlacement.js +9 -0
- package/dist/components/CommonPopover/types.d.ts +5 -5
- package/dist/components/CommonTimeSelector/CommonTimeSelector.vue.d.ts +2 -2
- package/dist/components/CommonTimeSelector/CommonTimeSelector.vue_vue_type_script_setup_true_lang.js +110 -99
- package/dist/components/CommonTimeSelector/useMeridiem.d.ts +1 -1
- package/dist/components/ErrorIcon/ErrorIcon.vue.d.ts +2 -2
- package/dist/components/FlatListBox/FlatListBox.vue.d.ts +2 -2
- package/dist/components/FlatListBox/FlatListBox.vue_vue_type_script_setup_true_lang.js +5 -2
- package/dist/components/FlatListBox/types.d.ts +3 -3
- package/dist/components/GroupedListBox/GroupedListBox.vue.d.ts +2 -2
- package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js +5 -2
- package/dist/components/GroupedListBox/types.d.ts +3 -3
- package/dist/components/ListBox/ListBox.vue.d.ts +2 -2
- package/dist/components/ListBox/types.d.ts +3 -3
- package/dist/components/OptionsContainer/OptionsContainer.vue.d.ts +1 -1
- package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js +101 -69
- package/dist/components/OptionsContainer/types.d.ts +8 -3
- package/dist/components/Transitions/Slide.vue.d.ts +5 -3
- package/dist/components/Transitions/Slide.vue.js +1 -1
- package/dist/components/WarningIcon/WarningIcon.vue.d.ts +2 -2
- package/dist/composables/autoHost.d.ts +1 -1
- package/dist/composables/formSubmitLock.d.ts +5 -5
- package/dist/composables/hostOpenings.d.ts +6 -6
- package/dist/composables/hostRegistry.d.ts +2 -2
- package/dist/composables/overlayRegistry.d.ts +25 -25
- package/dist/composables/overlayRegistry.js +13 -7
- package/dist/composables/useBaseOptions.d.ts +2 -2
- package/dist/composables/useBbConfig.d.ts +5 -5
- package/dist/composables/useBbDialog.d.ts +17 -17
- package/dist/composables/useBbDialog.js +2 -1
- package/dist/composables/useBbDropdown.d.ts +1 -1
- package/dist/composables/useBbForm.d.ts +2 -2
- package/dist/composables/useBbFormField.d.ts +4 -4
- package/dist/composables/useBbOffCanvas.d.ts +6 -6
- package/dist/composables/useBbTable.d.ts +4 -4
- package/dist/composables/useBbTabs.d.ts +4 -4
- package/dist/composables/useBbTabs.js +99 -94
- package/dist/composables/useBreakpoint.d.ts +1 -1
- package/dist/composables/useCharacterCounter.d.ts +2 -2
- package/dist/composables/useChoiceIndicator.d.ts +2 -2
- package/dist/composables/useClosingInert.d.ts +1 -1
- package/dist/composables/useConfig.d.ts +3 -3
- package/dist/composables/useConfig.js +2 -9
- package/dist/composables/useConfigDefaults.d.ts +54 -0
- package/dist/composables/useConfigDefaults.js +56 -0
- package/dist/composables/useConfirm.d.ts +18 -18
- package/dist/composables/useDirection.d.ts +43 -0
- package/dist/composables/useDirection.js +12 -0
- package/dist/composables/useFormBinding.d.ts +5 -5
- package/dist/composables/useFormBinding.js +3 -3
- package/dist/composables/useId.d.ts +1 -1
- package/dist/composables/useItemsGetter.d.ts +3 -3
- package/dist/composables/useKeyboardInset.d.ts +1 -1
- package/dist/composables/useListboxFocus.d.ts +1 -1
- package/dist/composables/useLocale.d.ts +2 -2
- package/dist/composables/useOnDemandOpener.d.ts +3 -3
- package/dist/composables/useOverlayNavigation.d.ts +1 -1
- package/dist/composables/useOverlayYield.d.ts +1 -1
- package/dist/composables/usePassthrough.d.ts +13 -11
- package/dist/composables/usePassthrough.js +137 -133
- package/dist/composables/useQuery.d.ts +1 -1
- package/dist/composables/useRefusedCloseAnnouncement.d.ts +1 -1
- package/dist/composables/useSafeArea.d.ts +1 -1
- package/dist/composables/useSafeAreaInternal.d.ts +1 -1
- package/dist/composables/useSegmentedFields.d.ts +25 -0
- package/dist/composables/useSegmentedFields.js +165 -115
- package/dist/composables/useServerPrefetch.d.ts +2 -2
- package/dist/composables/useSheetSurface.d.ts +1 -1
- package/dist/composables/useSsrState.d.ts +2 -2
- package/dist/composables/useToast.d.ts +13 -5
- package/dist/composables/useToast.js +52 -38
- package/dist/composables/useTypeahead.js +22 -21
- package/dist/deprecation/ai-deprecations.json.d.ts +160 -15
- package/dist/deprecation/ai-deprecations.json.js +1 -1
- package/dist/deprecation/removedProps.d.ts +1 -1
- package/dist/directives/bbColor.d.ts +1 -1
- package/dist/directives/bbDate.d.ts +1 -1
- package/dist/directives/bbDialog.d.ts +3 -3
- package/dist/directives/bbDropdown.d.ts +1 -1
- package/dist/directives/bbDropdown.js +7 -7
- package/dist/directives/bbHoverCard.d.ts +3 -3
- package/dist/directives/bbOffCanvas.d.ts +2 -2
- package/dist/directives/bbPopover.d.ts +3 -3
- package/dist/directives/bbTime.d.ts +1 -1
- package/dist/directives/bbTooltip.d.ts +4 -4
- package/dist/directives/directivePortal.d.ts +4 -4
- package/dist/directives/overlayTrigger.d.ts +4 -4
- package/dist/directives/overlayTrigger.js +2 -1
- package/dist/i18n/eraNames.d.ts +2 -0
- package/dist/i18n/eraNames.js +2013 -0
- package/dist/i18n/index.d.ts +9 -7
- package/dist/i18n/localeTags.d.ts +36 -0
- package/dist/i18n/locales/ar.json +176 -0
- package/dist/i18n/locales/cs.json +23 -3
- package/dist/i18n/locales/da.json +23 -3
- package/dist/i18n/locales/de-CH.json +23 -3
- package/dist/i18n/locales/de.json +23 -3
- package/dist/i18n/locales/el.json +23 -3
- package/dist/i18n/locales/en-GB.json +23 -3
- package/dist/i18n/locales/en.json +23 -3
- package/dist/i18n/locales/es-MX.json +23 -3
- package/dist/i18n/locales/es.json +23 -3
- package/dist/i18n/locales/fa.json +176 -0
- package/dist/i18n/locales/fi.json +23 -3
- package/dist/i18n/locales/fr.json +23 -3
- package/dist/i18n/locales/he.json +176 -0
- package/dist/i18n/locales/hu.json +23 -3
- package/dist/i18n/locales/it.json +23 -3
- package/dist/i18n/locales/ja.json +23 -3
- package/dist/i18n/locales/ko.json +23 -3
- package/dist/i18n/locales/nb.json +23 -3
- package/dist/i18n/locales/nl.json +23 -3
- package/dist/i18n/locales/pl.json +23 -3
- package/dist/i18n/locales/pt-BR.json +23 -3
- package/dist/i18n/locales/pt-PT.json +23 -3
- package/dist/i18n/locales/ro.json +23 -3
- package/dist/i18n/locales/ru.json +23 -3
- package/dist/i18n/locales/sv.json +23 -3
- package/dist/i18n/locales/tr.json +23 -3
- package/dist/i18n/locales/uk.json +23 -3
- package/dist/i18n/locales/zh-CN.json +23 -3
- package/dist/i18n/locales/zh-HK.json +23 -3
- package/dist/i18n/locales/zh-TW.json +23 -3
- package/dist/i18n/regionHints.js +22 -22
- package/dist/i18n/regions.d.ts +73 -24
- package/dist/i18n/regions.js +57 -12
- package/dist/index.d.ts +192 -190
- package/dist/index.js +55 -54
- package/dist/llms-full.txt +8848 -5872
- package/dist/llms-medium.txt +830 -506
- package/dist/llms.txt +6 -5
- package/dist/locale-blueprint.json +26 -3
- package/dist/locale-tags.js +81 -0
- package/dist/mcp-sdk.LICENSES.txt +210 -0
- package/dist/mcp-sdk.mjs +78 -0
- package/dist/nuxt-auto-imports.d.ts +1 -1
- package/dist/nuxt-auto-imports.js +1 -1
- package/dist/nuxt-module.d.ts +5 -5
- package/dist/nuxt.js +26 -23
- package/dist/plugin.d.ts +2 -2
- package/dist/project-dts.d.ts +76 -14
- package/dist/project-dts.js +117 -63
- package/dist/setup-kit.LICENSES.txt +23 -0
- package/dist/setup-kit.mjs +9 -0
- package/dist/styles.css +2 -2
- package/dist/types/ActionButton.d.ts +3 -3
- package/dist/types/AlertVariant.d.ts +2 -2
- package/dist/types/BadgeVariant.d.ts +2 -2
- package/dist/types/ButtonVariant.d.ts +2 -2
- package/dist/types/CheckboxVariant.d.ts +9 -6
- package/dist/types/CheckboxVariant.js +5 -1
- package/dist/types/ColumnName.d.ts +1 -1
- package/dist/types/CommonProps.d.ts +25 -3
- package/dist/types/Config.d.ts +24 -110
- package/dist/types/ConfigDefaults.d.ts +352 -0
- package/dist/types/ConfigDefaults.js +115 -0
- package/dist/types/ConfirmVariant.d.ts +2 -2
- package/dist/types/DatePickerType.d.ts +29 -2
- package/dist/types/DatePickerType.js +6 -2
- package/dist/types/DropdownItemVariant.d.ts +2 -2
- package/dist/types/FieldLayout.d.ts +3 -3
- package/dist/types/IndicatorVariant.d.ts +2 -2
- package/dist/types/InputVariant.d.ts +58 -25
- package/dist/types/ItemAccessor.d.ts +7 -1
- package/dist/types/ItemProps.d.ts +3 -3
- package/dist/types/ItemsProvider.d.ts +2 -2
- package/dist/types/Placement.d.ts +7 -2
- package/dist/types/RadioVariant.d.ts +9 -6
- package/dist/types/RadioVariant.js +5 -1
- package/dist/types/ShapeErased.d.ts +1 -1
- package/dist/types/SizeScale.d.ts +4 -0
- package/dist/types/SizeScale.js +17 -0
- package/dist/types/TabsVariant.d.ts +2 -2
- package/dist/types/ToastVariant.d.ts +2 -2
- package/dist/types/TooltipVariant.d.ts +2 -2
- package/dist/types/fallthrough.d.ts +1 -1
- package/dist/types/passthrough.d.ts +23 -23
- package/dist/types/ptComponentMap.d.ts +29 -28
- package/dist/utilities/calendar/canonicalParts.d.ts +29 -0
- package/dist/utilities/calendar/canonicalParts.js +12 -0
- package/dist/utilities/calendar/digits.d.ts +18 -0
- package/dist/utilities/calendar/digits.js +26 -0
- package/dist/utilities/calendar/gregorian.d.ts +2 -0
- package/dist/utilities/calendar/gregorian.js +36 -0
- package/dist/utilities/calendar/index.d.ts +3 -0
- package/dist/utilities/calendar/index.js +1 -0
- package/dist/utilities/calendar/international.d.ts +19 -0
- package/dist/utilities/calendar/resolve.d.ts +32 -0
- package/dist/utilities/calendar/resolve.js +12 -0
- package/dist/utilities/calendar/runtime.d.ts +49 -0
- package/dist/utilities/calendar/types.d.ts +140 -0
- package/dist/utilities/calendar/types.js +83 -0
- package/dist/utilities/functions/convertDateValue.d.ts +15 -2
- package/dist/utilities/functions/convertDateValue.js +22 -17
- package/dist/utilities/functions/elementLabel.d.ts +1 -1
- package/dist/utilities/functions/extractDomContainer.d.ts +1 -1
- package/dist/utilities/functions/isDateDisabled.d.ts +9 -1
- package/dist/utilities/functions/isDateDisabled.js +38 -21
- package/dist/utilities/functions/itemProps.d.ts +1 -1
- package/dist/utilities/functions/normalizeDateBound.d.ts +45 -2
- package/dist/utilities/functions/normalizeDateBound.js +52 -11
- package/dist/utilities/functions/parseSize.d.ts +2 -2
- package/dist/utilities/functions/readableValue.d.ts +1 -1
- package/dist/utilities/functions/responsiveDefault.d.ts +1 -1
- package/dist/utilities/functions/searchRank.d.ts +19 -0
- package/dist/utilities/functions/searchRank.js +76 -0
- package/dist/utilities/functions/slotKey.d.ts +1 -1
- package/dist/utilities/functions/toggleInput.d.ts +1 -1
- package/dist/utilities/functions/warnRemovedAttrs.d.ts +3 -3
- package/dist/utilities/functions/when.d.ts +1 -1
- package/dist/utilities/misc/autofocus.d.ts +2 -2
- package/dist/utilities/misc/listboxMetrics.d.ts +2 -2
- package/dist/utilities/misc/maskaDataOptions.d.ts +1 -1
- package/dist/utilities/misc/ssrStateInjectionKey.d.ts +1 -1
- package/dist/utilities/misc/ssrValue.d.ts +1 -1
- package/dist/utils/configDefaults.d.ts +43 -0
- package/dist/utils/configDefaults.js +170 -0
- package/dist/utils/configScope.d.ts +43 -0
- package/dist/utils/configScope.js +13 -0
- package/dist/utils/copyData.d.ts +2 -2
- package/dist/utils/cssLayers.d.ts +1 -1
- package/dist/utils/focusVisibility.d.ts +1 -1
- package/dist/utils/injectLibraryStyles.d.ts +1 -1
- package/dist/utils/overlayEscapeStack.d.ts +1 -1
- package/dist/utils/passthrough.d.ts +5 -8
- package/dist/utils/passthrough.js +31 -29
- package/dist/utils/passthroughDeduper.d.ts +1 -1
- package/dist/utils/releasedActivator.d.ts +20 -0
- package/dist/utils/releasedActivator.js +11 -0
- package/dist/utils/versionCheck.d.ts +1 -1
- package/dist/utils/versionCheck.js +1 -1
- package/dist/vite-plugin.d.ts +139 -218
- package/dist/vite.js +451 -425
- package/llms.txt +6 -5
- package/package.json +51 -19
- package/scripts/README.md +2 -1
- package/scripts/lib/adoption-checklist.json +2 -2
- package/scripts/lib/agent-manifest.mjs +107 -22
- package/scripts/lib/agent-refresh.mjs +151 -0
- package/scripts/lib/agent-setup.mjs +679 -0
- package/scripts/lib/carousel-items-without-slide.mjs +263 -0
- package/scripts/lib/carousel-prop-or-local.mjs +117 -0
- package/scripts/lib/check-fix.mjs +1 -1
- package/scripts/lib/collapsible-trigger-aria.mjs +1 -1
- package/scripts/lib/css-class-check.mjs +3 -3
- package/scripts/lib/css-local-check.mjs +25 -17
- package/scripts/lib/css-surface-answer.mjs +117 -0
- package/scripts/lib/define-preset-copy.mjs +1 -1
- package/scripts/lib/distributed-alias.mjs +81 -0
- package/scripts/lib/doc-sections.mjs +12 -4
- package/scripts/lib/dropdown-default-slot.mjs +1 -1
- package/scripts/lib/eslint-disable.mjs +60 -2
- package/scripts/lib/eslint-plugin.d.ts +13 -2
- package/scripts/lib/eslint-plugin.mjs +609 -64
- package/scripts/lib/form-v-model.mjs +1 -1
- package/scripts/lib/hand-imported-styles.mjs +2 -2
- package/scripts/lib/hand-roll-hints.mjs +25 -3
- package/scripts/lib/helper-canon.mjs +4 -4
- package/scripts/lib/helpers-add.mjs +39 -24
- package/scripts/lib/hidden-label-placeholder.mjs +1 -1
- package/scripts/lib/idiom-scan.mjs +12 -11
- package/scripts/lib/is-direct-run.mjs +20 -0
- package/scripts/lib/items-provider-context.mjs +1 -1
- package/scripts/lib/linked-target.mjs +26 -2
- package/scripts/lib/local-components.mjs +2 -2
- package/scripts/lib/locale-check.mjs +109 -13
- package/scripts/lib/mcp-config.mjs +140 -75
- package/scripts/lib/mcp-sdk.mjs +199 -0
- package/scripts/lib/migrate-fix.mjs +3 -3
- package/scripts/lib/plugin-options-check.mjs +170 -0
- package/scripts/lib/pnp.mjs +165 -0
- package/scripts/lib/portal-names.mjs +4 -4
- package/scripts/lib/prefer-v-bb-dialog.mjs +1 -1
- package/scripts/lib/project-variant-dts.mjs +182 -48
- package/scripts/lib/reactive-v-model.mjs +2 -2
- package/scripts/lib/redundant-item-accessor.mjs +1 -1
- package/scripts/lib/renamed-item-field.mjs +1 -1
- package/scripts/lib/renamed-slot-prop.mjs +524 -0
- package/scripts/lib/rule-registry.mjs +1 -1
- package/scripts/lib/setup-edits.mjs +1845 -0
- package/scripts/lib/setup.mjs +440 -0
- package/scripts/lib/slot-key.mjs +1 -1
- package/scripts/lib/slot-renames.mjs +3 -3
- package/scripts/lib/squashed-slot-words.mjs +1 -1
- package/scripts/lib/tab-links.mjs +2 -2
- package/scripts/lib/text-null-value.mjs +1 -1
- package/scripts/lib/toolchain-check.mjs +3 -3
- package/scripts/lib/tooling-options.mjs +87 -0
- package/scripts/lib/unimported-components.mjs +1 -1
- package/scripts/lib/unstyled-variants.mjs +1 -1
- package/scripts/lib/valid-locale.mjs +119 -0
- package/scripts/lib/validate-bb-markup.mjs +219 -115
- package/scripts/lib/wrapper-props.mjs +2 -2
- package/dist/ai/BbPtScope.md +0 -138
- package/dist/ai/manifest/components/BbPtScope.json +0 -21
- package/dist/ai/source/BbPtScope.md +0 -54
- package/dist/components/BbNumberInput/warroom/corpus.d.ts +0 -58
- package/dist/components/BbNumberInput/warroom/currency-verify.rows.d.ts +0 -28
- package/dist/components/BbNumberInput/warroom/currency.rows.d.ts +0 -2
- package/dist/components/BbNumberInput/warroom/harness.d.ts +0 -217
- package/dist/components/BbNumberInput/warroom/oracle.d.ts +0 -150
- package/dist/components/BbPtScope/BbPtScope.vue.d.ts +0 -12
- package/dist/components/BbPtScope/BbPtScope.vue.js +0 -4
- package/dist/components/BbPtScope/BbPtScope.vue_vue_type_script_setup_true_lang.js +0 -12
- package/dist/components/BbPtScope/types.d.ts +0 -15
- package/dist/components/BbTable/warroom/harness.d.ts +0 -260
- package/dist/types/PtScope.d.ts +0 -15
- package/dist/utilities/functions/head.js +0 -3
- package/dist/utilities/functions/matchAnyKey.d.ts +0 -8
- package/dist/utilities/functions/matchAnyKey.js +0 -14
- package/dist/utilities/functions/pipe.d.ts +0 -3
- package/dist/utilities/functions/range.js +0 -7
- package/dist/utils/ptScope.d.ts +0 -8
- package/dist/utils/ptScope.js +0 -3
- package/scripts/lib/check-queue.mjs +0 -102
- package/scripts/lib/component-attr-targets.ts +0 -123
- package/scripts/lib/component-tree.ts +0 -648
- package/scripts/lib/consumer-install.mjs +0 -64
- package/scripts/lib/css-class-surface.mjs +0 -328
- package/scripts/lib/css-color-resolve.mjs +0 -296
- package/scripts/lib/css-comment-text.mjs +0 -16
- package/scripts/lib/design-token-manifest.mjs +0 -506
- package/scripts/lib/ensure-manifest.mjs +0 -135
- package/scripts/lib/example-checks.mjs +0 -337
- package/scripts/lib/guide-claims.mjs +0 -452
- package/scripts/lib/manifest-pointers.mjs +0 -71
- package/scripts/lib/pack.mjs +0 -55
- package/scripts/lib/public-type-exports.mjs +0 -273
- package/scripts/lib/quiet-gate.mjs +0 -385
- package/scripts/lib/recipe-excerpts.mjs +0 -98
- package/scripts/lib/swap-noun.mjs +0 -33
- package/scripts/lib/token-color-mix.mjs +0 -114
|
@@ -0,0 +1,1093 @@
|
|
|
1
|
+
# BbCarousel
|
|
2
|
+
|
|
3
|
+
## Agent Contract
|
|
4
|
+
|
|
5
|
+
- Safety level: **Consumer API**
|
|
6
|
+
- Group: **Data Display**
|
|
7
|
+
- Description: Slides moved by swipe, arrows and dots.
|
|
8
|
+
- Usage rule: Prefer this component for consumer-facing implementations.
|
|
9
|
+
- Implementation source (only when the contract below is not enough): [source/BbCarousel.md](./source/BbCarousel.md)
|
|
10
|
+
|
|
11
|
+
## Usage & Guidelines
|
|
12
|
+
|
|
13
|
+
### When to use
|
|
14
|
+
|
|
15
|
+
`BbCarousel` is for a short run of slides the reader steps through: a hero, a
|
|
16
|
+
row of product cards, onboarding screens. Each child of the default slot is one
|
|
17
|
+
slide. The browser does the swiping (native scroll-snap: real momentum on touch
|
|
18
|
+
and trackpads), so it feels like the platform. For an image grid that opens a
|
|
19
|
+
full-screen viewer, use a gallery; for content the reader must compare side by
|
|
20
|
+
side, a grid or a table is clearer than a carousel.
|
|
21
|
+
|
|
22
|
+
```vue
|
|
23
|
+
<BbCarousel label="Featured">
|
|
24
|
+
<img alt="Dolomites at dawn" src="/dolomites.jpg" />
|
|
25
|
+
<img alt="Cinque Terre harbour" src="/cinque-terre.jpg" />
|
|
26
|
+
<img alt="Matera at night" src="/matera.jpg" />
|
|
27
|
+
</BbCarousel>
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
### Layout at a glance
|
|
31
|
+
|
|
32
|
+
Three props cover the common case: `per-view` (slides in view), `bleed`
|
|
33
|
+
(run to the page edges) and `align` (`center` puts the current slide in the
|
|
34
|
+
middle, its neighbours peeking on both sides). They work the same whatever the slides are: images,
|
|
35
|
+
`slide` slot markup or plain children.
|
|
36
|
+
|
|
37
|
+
```vue
|
|
38
|
+
<BbCarousel bleed :per-view="1.2" label="Stories">…</BbCarousel>
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Centred, the current slide sits in the middle and its neighbours peek on both
|
|
42
|
+
sides, the first and the last slides included:
|
|
43
|
+
|
|
44
|
+
**App screens, centred**
|
|
45
|
+
|
|
46
|
+
```vue
|
|
47
|
+
<template>
|
|
48
|
+
<BbCarousel
|
|
49
|
+
align="center"
|
|
50
|
+
class="[--gap:20px] [--per-view:1.6] sm:[--per-view:2.6] lg:[--per-view:3.4]"
|
|
51
|
+
:items="screens"
|
|
52
|
+
label="Inside the app"
|
|
53
|
+
>
|
|
54
|
+
<template #slide="{ item, current }">
|
|
55
|
+
<figure class="m-0 grid gap-3">
|
|
56
|
+
<div
|
|
57
|
+
class="overflow-hidden rounded-[2rem] border-[6px] border-zinc-900 bg-zinc-900 transition motion-safe:duration-300"
|
|
58
|
+
:class="current ? 'scale-100' : 'scale-95 opacity-70'"
|
|
59
|
+
>
|
|
60
|
+
<img
|
|
61
|
+
:alt="`The ${item.title.toLowerCase()} screen`"
|
|
62
|
+
class="aspect-[390/844] w-full rounded-[1.6rem] object-cover"
|
|
63
|
+
loading="lazy"
|
|
64
|
+
:src="item.shot"
|
|
65
|
+
/>
|
|
66
|
+
</div>
|
|
67
|
+
<figcaption class="grid gap-0.5 text-center text-sm">
|
|
68
|
+
<span class="font-medium">{{ item.title }}</span>
|
|
69
|
+
<span class="text-(--bb-text-muted)">{{ item.body }}</span>
|
|
70
|
+
</figcaption>
|
|
71
|
+
</figure>
|
|
72
|
+
</template>
|
|
73
|
+
</BbCarousel>
|
|
74
|
+
</template>
|
|
75
|
+
|
|
76
|
+
<script setup lang="ts">
|
|
77
|
+
import { BbCarousel } from 'bitboss-ui';
|
|
78
|
+
|
|
79
|
+
/** App screens, centred: the current screen in the middle, its neighbours
|
|
80
|
+
* peeking on both sides, the first and the last too. */
|
|
81
|
+
const screens = [
|
|
82
|
+
{
|
|
83
|
+
title: 'Plan a route',
|
|
84
|
+
body: 'Drop pins, get the climb and the hours.',
|
|
85
|
+
shot: 'https://picsum.photos/seed/app-route/390/844',
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
title: 'Pack the list',
|
|
89
|
+
body: 'A checklist that knows the forecast.',
|
|
90
|
+
shot: 'https://picsum.photos/seed/app-pack/390/844',
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
title: 'Share the trip',
|
|
94
|
+
body: 'Friends follow along, offline maps included.',
|
|
95
|
+
shot: 'https://picsum.photos/seed/app-share/390/844',
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
title: 'Log the miles',
|
|
99
|
+
body: 'Your season, in one quiet timeline.',
|
|
100
|
+
shot: 'https://picsum.photos/seed/app-log/390/844',
|
|
101
|
+
},
|
|
102
|
+
];
|
|
103
|
+
</script>
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
Left out, they set nothing. For anything finer (a value per breakpoint, a
|
|
107
|
+
bleed length or one side) set the CSS locals on the carousel instead, never
|
|
108
|
+
both for the same thing (`bitboss-ui/carousel-prop-or-local` flags it):
|
|
109
|
+
`class="[--per-view:1.2] md:[--per-view:3]"`. Every local, defaults in
|
|
110
|
+
brackets:
|
|
111
|
+
|
|
112
|
+
- `--per-view`: slides in view; a fraction shows a peek of the next (`1`).
|
|
113
|
+
- `--gap`: space between slides, never a `gap-*` utility (`16px`).
|
|
114
|
+
- `--align`: `start` or `center`, where the current slide sits (`start`).
|
|
115
|
+
- `--py`: room above and below the slides, so a ribbon, a shadow, a hover
|
|
116
|
+
lift or a focus outline poking out of a slide shows; nothing on the page
|
|
117
|
+
moves (`0px`).
|
|
118
|
+
- `--bleed`: lets the slides run past the carousel to the page edge, `auto`
|
|
119
|
+
or a length; per side `--bleed-start` / `--bleed-end` (`0`).
|
|
120
|
+
- `--ratio`: the crop of built-in images (`16 / 9`).
|
|
121
|
+
- `--r`: corner radius of the slides (the system radius).
|
|
122
|
+
- `--speed`: how long a move takes; `0ms` jumps (`300ms`).
|
|
123
|
+
- `--peek-click`: `off` stops a click on a peeking slide from bringing it in.
|
|
124
|
+
- `--dot` / `--dot-active`: the dot colours (light, over the slides).
|
|
125
|
+
|
|
126
|
+
### Slides from data
|
|
127
|
+
|
|
128
|
+
`items` takes three shapes. Image URLs, or image entries (a `src` or a
|
|
129
|
+
`srcset`, with optional `sizes` and `alt`), render as cover-cropped images
|
|
130
|
+
with no slot; the crop is the `--ratio` local (default `16 / 9`), or the
|
|
131
|
+
carousel's own height when you give it one (cropped from the centre). An image
|
|
132
|
+
without `alt` (a bare URL included) is decorative, so add `alt` when the
|
|
133
|
+
images carry meaning.
|
|
134
|
+
The images in view and one either side load right away; the rest load lazily
|
|
135
|
+
as the reader nears them. Each slide keeps its state by item, not position,
|
|
136
|
+
so reordering `items` never hands one item's typed input or playing video to
|
|
137
|
+
another.
|
|
138
|
+
|
|
139
|
+
```vue
|
|
140
|
+
<BbCarousel :items="photos" label="Trip photos" />
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
Any other array renders through the `slide` slot (`{ item, index, active,
|
|
144
|
+
current }`: `active` while the slide is in view, `current` on the `v-model`
|
|
145
|
+
slide), and `item` is typed as your entry. The slot also wins over the
|
|
146
|
+
built-in image.
|
|
147
|
+
|
|
148
|
+
**Testimonials from data, two per view from md**
|
|
149
|
+
|
|
150
|
+
```vue
|
|
151
|
+
<template>
|
|
152
|
+
<BbCarousel
|
|
153
|
+
class="md:[--per-view:2]"
|
|
154
|
+
:items="quotes"
|
|
155
|
+
label="What customers say"
|
|
156
|
+
loop
|
|
157
|
+
>
|
|
158
|
+
<template #slide="{ item }">
|
|
159
|
+
<figure
|
|
160
|
+
class="m-0 grid h-full content-between gap-4 rounded-(--bb-radius) border p-5"
|
|
161
|
+
>
|
|
162
|
+
<blockquote class="m-0 leading-relaxed">“{{ item.text }}”</blockquote>
|
|
163
|
+
<figcaption class="flex items-center gap-3">
|
|
164
|
+
<BbAvatar :alt="item.name" :src="item.avatar" />
|
|
165
|
+
<span class="grid text-sm">
|
|
166
|
+
<span class="font-medium">{{ item.name }}</span>
|
|
167
|
+
<span class="text-(--bb-text-muted)">{{ item.role }}</span>
|
|
168
|
+
</span>
|
|
169
|
+
</figcaption>
|
|
170
|
+
</figure>
|
|
171
|
+
</template>
|
|
172
|
+
</BbCarousel>
|
|
173
|
+
</template>
|
|
174
|
+
|
|
175
|
+
<script setup lang="ts">
|
|
176
|
+
import { BbAvatar, BbCarousel } from 'bitboss-ui';
|
|
177
|
+
|
|
178
|
+
/** Testimonials: markup slides from data, one per view on a phone, two from
|
|
179
|
+
* `md`, endless. The dots sit below the cards by themselves. */
|
|
180
|
+
const quotes = [
|
|
181
|
+
{
|
|
182
|
+
text: 'The jacket survived a week of sideways rain in Skye. My old one would have given up on day two.',
|
|
183
|
+
name: 'Ailsa Mackenzie',
|
|
184
|
+
role: 'Hiking guide, Portree',
|
|
185
|
+
avatar: 'https://picsum.photos/seed/face-ailsa/96/96',
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
text: 'Ordered on Monday, wore them up Monte Rosa on Saturday. No blisters, no break-in.',
|
|
189
|
+
name: 'Matteo Brambilla',
|
|
190
|
+
role: 'Alpinist, Biella',
|
|
191
|
+
avatar: 'https://picsum.photos/seed/face-matteo/96/96',
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
text: 'Returns were painless when the size was off. The replacement fit like it was measured for me.',
|
|
195
|
+
name: 'Ingrid Solheim',
|
|
196
|
+
role: 'Trail runner, Bergen',
|
|
197
|
+
avatar: 'https://picsum.photos/seed/face-ingrid/96/96',
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
text: 'The tote has carried groceries, climbing shoes and a sleepy dog. It still looks new.',
|
|
201
|
+
name: 'Kofi Mensah',
|
|
202
|
+
role: 'Illustrator, Lisbon',
|
|
203
|
+
avatar: 'https://picsum.photos/seed/face-kofi/96/96',
|
|
204
|
+
},
|
|
205
|
+
];
|
|
206
|
+
</script>
|
|
207
|
+
```
|
|
208
|
+
|
|
209
|
+
A slide can hold a carousel of its own: each card swipes its photos, the row
|
|
210
|
+
swipes the cards, and a drag moves only the carousel it starts on.
|
|
211
|
+
|
|
212
|
+
**Listings, a photo carousel in each card**
|
|
213
|
+
|
|
214
|
+
```vue
|
|
215
|
+
<template>
|
|
216
|
+
<BbCarousel
|
|
217
|
+
class="[--per-view:1.1] md:[--per-view:2]"
|
|
218
|
+
:items="listings"
|
|
219
|
+
label="Homes for rent"
|
|
220
|
+
>
|
|
221
|
+
<template #slide="{ item: listing }">
|
|
222
|
+
<article class="grid gap-2">
|
|
223
|
+
<BbCarousel
|
|
224
|
+
class="[--ratio:4/3]"
|
|
225
|
+
:items="listing.photos"
|
|
226
|
+
:label="`Photos of ${listing.title}`"
|
|
227
|
+
loop
|
|
228
|
+
>
|
|
229
|
+
<template #overlay="{ index }">
|
|
230
|
+
<span
|
|
231
|
+
class="absolute top-3 left-3 rounded-full bg-black/60 px-2 py-0.5 text-xs text-white tabular-nums"
|
|
232
|
+
>
|
|
233
|
+
{{ index + 1 }} / {{ listing.photos.length }}
|
|
234
|
+
</span>
|
|
235
|
+
</template>
|
|
236
|
+
</BbCarousel>
|
|
237
|
+
<div class="grid gap-0.5 text-sm">
|
|
238
|
+
<p class="m-0 font-medium">{{ listing.title }}</p>
|
|
239
|
+
<p class="m-0 text-(--bb-text-muted)">
|
|
240
|
+
{{ listing.area }}, {{ listing.beds }} bed
|
|
241
|
+
</p>
|
|
242
|
+
<p class="m-0 font-medium">{{ listing.price }}</p>
|
|
243
|
+
</div>
|
|
244
|
+
</article>
|
|
245
|
+
</template>
|
|
246
|
+
</BbCarousel>
|
|
247
|
+
</template>
|
|
248
|
+
|
|
249
|
+
<script setup lang="ts">
|
|
250
|
+
import { BbCarousel } from 'bitboss-ui';
|
|
251
|
+
|
|
252
|
+
/** Listings: each card swipes its own photos, the row swipes the cards. A
|
|
253
|
+
* drag moves only the carousel it starts on. */
|
|
254
|
+
const listings = [
|
|
255
|
+
{
|
|
256
|
+
title: 'Loft over the old harbour',
|
|
257
|
+
area: 'Genova, Porto Antico',
|
|
258
|
+
beds: 2,
|
|
259
|
+
price: '€ 1,480 / month',
|
|
260
|
+
photos: [
|
|
261
|
+
{
|
|
262
|
+
src: 'https://picsum.photos/seed/loft-living/800/600',
|
|
263
|
+
alt: 'Living room with exposed beams',
|
|
264
|
+
},
|
|
265
|
+
{
|
|
266
|
+
src: 'https://picsum.photos/seed/loft-kitchen/800/600',
|
|
267
|
+
alt: 'Open kitchen with a long table',
|
|
268
|
+
},
|
|
269
|
+
{
|
|
270
|
+
src: 'https://picsum.photos/seed/loft-view/800/600',
|
|
271
|
+
alt: 'View over the harbour cranes',
|
|
272
|
+
},
|
|
273
|
+
],
|
|
274
|
+
},
|
|
275
|
+
{
|
|
276
|
+
title: 'Garden flat near the park',
|
|
277
|
+
area: 'Torino, San Salvario',
|
|
278
|
+
beds: 1,
|
|
279
|
+
price: '€ 1,120 / month',
|
|
280
|
+
photos: [
|
|
281
|
+
{
|
|
282
|
+
src: 'https://picsum.photos/seed/garden-flat/800/600',
|
|
283
|
+
alt: 'Garden with a small terrace',
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
src: 'https://picsum.photos/seed/garden-living/800/600',
|
|
287
|
+
alt: 'Bright living room',
|
|
288
|
+
},
|
|
289
|
+
{
|
|
290
|
+
src: 'https://picsum.photos/seed/garden-bath/800/600',
|
|
291
|
+
alt: 'Tiled bathroom',
|
|
292
|
+
},
|
|
293
|
+
],
|
|
294
|
+
},
|
|
295
|
+
{
|
|
296
|
+
title: 'Top floor with a terrace',
|
|
297
|
+
area: 'Milano, Isola',
|
|
298
|
+
beds: 3,
|
|
299
|
+
price: '€ 2,050 / month',
|
|
300
|
+
photos: [
|
|
301
|
+
{
|
|
302
|
+
src: 'https://picsum.photos/seed/terrace-top/800/600',
|
|
303
|
+
alt: 'Roof terrace with plants',
|
|
304
|
+
},
|
|
305
|
+
{
|
|
306
|
+
src: 'https://picsum.photos/seed/terrace-living/800/600',
|
|
307
|
+
alt: 'Living room with large windows',
|
|
308
|
+
},
|
|
309
|
+
{
|
|
310
|
+
src: 'https://picsum.photos/seed/terrace-night/800/600',
|
|
311
|
+
alt: 'The terrace at night',
|
|
312
|
+
},
|
|
313
|
+
],
|
|
314
|
+
},
|
|
315
|
+
];
|
|
316
|
+
</script>
|
|
317
|
+
```
|
|
318
|
+
|
|
319
|
+
A number gives that many slides of your own markup; `item` is the index.
|
|
320
|
+
|
|
321
|
+
```vue
|
|
322
|
+
<BbCarousel :items="3" label="Onboarding">
|
|
323
|
+
<template #slide="{ item }">
|
|
324
|
+
<OnboardingStep :step="item" />
|
|
325
|
+
</template>
|
|
326
|
+
</BbCarousel>
|
|
327
|
+
```
|
|
328
|
+
|
|
329
|
+
### Above and below each slide
|
|
330
|
+
|
|
331
|
+
`slide:header` and `slide:footer` add content inside each slide, above and
|
|
332
|
+
below what it shows: a title under a photo, a price under a card, a kicker
|
|
333
|
+
above a quote. They work on every kind of slide and get
|
|
334
|
+
`{ item, index, active, current }` (`item` undefined over a default-slot
|
|
335
|
+
child). With
|
|
336
|
+
built-in images the photo stays the built-in one, lazy loading, sizes and
|
|
337
|
+
crop included; in a carousel given a height, it shrinks to make room.
|
|
338
|
+
|
|
339
|
+
**A video row, the title under each thumbnail**
|
|
340
|
+
|
|
341
|
+
```vue
|
|
342
|
+
<template>
|
|
343
|
+
<BbCarousel
|
|
344
|
+
class="[--per-view:1.2] [--ratio:16/9] sm:[--per-view:2.2] lg:[--per-view:3]"
|
|
345
|
+
:items="videos"
|
|
346
|
+
label="How-to videos"
|
|
347
|
+
>
|
|
348
|
+
<template #slide:footer="{ item }">
|
|
349
|
+
<div class="grid gap-0.5 pt-2 text-sm">
|
|
350
|
+
<p class="m-0 font-medium">{{ item?.title }}</p>
|
|
351
|
+
<p class="m-0 text-(--bb-text-muted)">{{ item?.channel }}</p>
|
|
352
|
+
</div>
|
|
353
|
+
</template>
|
|
354
|
+
<template #overlay="{ item }">
|
|
355
|
+
<div class="absolute inset-x-0 top-0 aspect-video">
|
|
356
|
+
<BbButton
|
|
357
|
+
:aria-label="`Play: ${item?.title}`"
|
|
358
|
+
class="absolute top-1/2 left-1/2 -translate-1/2"
|
|
359
|
+
icon="lucide:play"
|
|
360
|
+
variant="secondary"
|
|
361
|
+
/>
|
|
362
|
+
<span
|
|
363
|
+
class="absolute right-2 bottom-2 rounded bg-black/70 px-1.5 py-0.5 text-xs text-white tabular-nums"
|
|
364
|
+
>
|
|
365
|
+
{{ item?.length }}
|
|
366
|
+
</span>
|
|
367
|
+
</div>
|
|
368
|
+
</template>
|
|
369
|
+
</BbCarousel>
|
|
370
|
+
</template>
|
|
371
|
+
|
|
372
|
+
<script setup lang="ts">
|
|
373
|
+
import { BbButton, BbCarousel } from 'bitboss-ui';
|
|
374
|
+
|
|
375
|
+
/** A video row: built-in 16:9 thumbnails, the title under each
|
|
376
|
+
* (`#slide:footer`), the play button and the length on top (`#overlay`). */
|
|
377
|
+
const videos = [
|
|
378
|
+
{
|
|
379
|
+
src: 'https://picsum.photos/seed/video-packing/640/360',
|
|
380
|
+
title: 'Packing a 40 litre pack for five days',
|
|
381
|
+
channel: 'Trail Notes',
|
|
382
|
+
length: '12:48',
|
|
383
|
+
},
|
|
384
|
+
{
|
|
385
|
+
src: 'https://picsum.photos/seed/video-wind/640/360',
|
|
386
|
+
title: 'Pitching a tent in strong wind',
|
|
387
|
+
channel: 'Trail Notes',
|
|
388
|
+
length: '7:15',
|
|
389
|
+
},
|
|
390
|
+
{
|
|
391
|
+
src: 'https://picsum.photos/seed/video-water/640/360',
|
|
392
|
+
title: 'Water filters compared',
|
|
393
|
+
channel: 'Gear Lab',
|
|
394
|
+
length: '18:02',
|
|
395
|
+
},
|
|
396
|
+
{
|
|
397
|
+
src: 'https://picsum.photos/seed/video-map/640/360',
|
|
398
|
+
title: 'Reading a topo map in ten minutes',
|
|
399
|
+
channel: 'Gear Lab',
|
|
400
|
+
length: '10:31',
|
|
401
|
+
},
|
|
402
|
+
];
|
|
403
|
+
</script>
|
|
404
|
+
```
|
|
405
|
+
|
|
406
|
+
### Content on top of the slides
|
|
407
|
+
|
|
408
|
+
The `overlay` slot puts a layer on top of every slide, whatever the slide is
|
|
409
|
+
(a built-in image, `slide` slot markup or a default-slot child), and it moves
|
|
410
|
+
with its slide: captions, badges, decorative glyphs, buttons, an editorial
|
|
411
|
+
block. It gets `{ item, index, active, current }`; `item` is undefined over a
|
|
412
|
+
default-slot child. The layer is the slide's size and bare: place the content
|
|
413
|
+
yourself. Where it is empty, taps go through, so the slide still swipes,
|
|
414
|
+
drags and peek-clicks there.
|
|
415
|
+
|
|
416
|
+
**An editorial hero: copy and a link over each photo**
|
|
417
|
+
|
|
418
|
+
```vue
|
|
419
|
+
<template>
|
|
420
|
+
<BbCarousel
|
|
421
|
+
:autoplay="6000"
|
|
422
|
+
class="h-[420px]"
|
|
423
|
+
:items="trips"
|
|
424
|
+
label="Featured trips"
|
|
425
|
+
loop
|
|
426
|
+
>
|
|
427
|
+
<template #overlay="{ item, active }">
|
|
428
|
+
<div
|
|
429
|
+
class="absolute inset-x-0 bottom-0 grid gap-2 bg-gradient-to-t from-black/75 via-black/40 to-transparent p-6 pb-12 text-white"
|
|
430
|
+
>
|
|
431
|
+
<p class="text-sm text-white/80">{{ item?.kicker }}</p>
|
|
432
|
+
<h3
|
|
433
|
+
class="max-w-[20ch] text-3xl leading-tight font-semibold tracking-tight transition motion-safe:duration-700"
|
|
434
|
+
:class="
|
|
435
|
+
active ? 'translate-y-0 opacity-100' : 'translate-y-2 opacity-0'
|
|
436
|
+
"
|
|
437
|
+
>
|
|
438
|
+
{{ item?.title }}
|
|
439
|
+
</h3>
|
|
440
|
+
<div>
|
|
441
|
+
<BbButton :href="item?.href" variant="secondary"
|
|
442
|
+
>See the trip</BbButton
|
|
443
|
+
>
|
|
444
|
+
</div>
|
|
445
|
+
</div>
|
|
446
|
+
</template>
|
|
447
|
+
</BbCarousel>
|
|
448
|
+
</template>
|
|
449
|
+
|
|
450
|
+
<script setup lang="ts">
|
|
451
|
+
import { BbButton, BbCarousel } from 'bitboss-ui';
|
|
452
|
+
|
|
453
|
+
/** A marketing hero: built-in photos, the copy and a real link on top. */
|
|
454
|
+
const trips = [
|
|
455
|
+
{
|
|
456
|
+
src: 'https://picsum.photos/seed/lysefjord/1600/900',
|
|
457
|
+
alt: 'A fjord between steep green slopes',
|
|
458
|
+
kicker: 'Norway, 4 days',
|
|
459
|
+
title: 'Walk the Lysefjord rim',
|
|
460
|
+
href: '#lysefjord',
|
|
461
|
+
},
|
|
462
|
+
{
|
|
463
|
+
src: 'https://picsum.photos/seed/abisko/1600/900',
|
|
464
|
+
alt: 'Green aurora over a lone pine',
|
|
465
|
+
kicker: 'Sweden, 5 nights',
|
|
466
|
+
title: 'Chase the aurora from Abisko',
|
|
467
|
+
href: '#abisko',
|
|
468
|
+
},
|
|
469
|
+
{
|
|
470
|
+
src: 'https://picsum.photos/seed/canyon-walls/1600/900',
|
|
471
|
+
alt: 'Red rock canyon walls lit by low sun',
|
|
472
|
+
kicker: 'Utah, 6 days',
|
|
473
|
+
title: 'Sleep under the canyon walls',
|
|
474
|
+
href: '#canyon',
|
|
475
|
+
},
|
|
476
|
+
];
|
|
477
|
+
</script>
|
|
478
|
+
```
|
|
479
|
+
|
|
480
|
+
The arrows sit at the middle of each side and the dots (with the pause button,
|
|
481
|
+
under autoplay) at the bottom centre, above the overlay: keep content clear of
|
|
482
|
+
them (the bottom padding above leaves the dots room) or move them with `pt`.
|
|
483
|
+
|
|
484
|
+
What the overlay holds is read with its slide ("2 of 5") and goes inert when
|
|
485
|
+
the slide leaves the view, so Tab never reaches a hidden button, and focus
|
|
486
|
+
inside it pauses autoplay. The rest is yours:
|
|
487
|
+
|
|
488
|
+
- Text over a photo has no contrast of its own: put it on a scrim or a solid
|
|
489
|
+
panel.
|
|
490
|
+
- The overlay adds to the image's `alt`, never repeats it; if the overlay
|
|
491
|
+
says it all, give the image `alt: ''`.
|
|
492
|
+
- Name every button and link for what it does ("Read the story", not "→").
|
|
493
|
+
- Mark decorative glyphs `aria-hidden="true"`.
|
|
494
|
+
- Animate with `motion-safe:` variants, so reduced motion gets none.
|
|
495
|
+
- A slide change announces "2 of 5", not the overlay's text: readers reach it
|
|
496
|
+
by reading the slide.
|
|
497
|
+
|
|
498
|
+
### A thumbnail strip
|
|
499
|
+
|
|
500
|
+
Two carousels on one `v-model` stay in step: the main photo and a strip of
|
|
501
|
+
thumbnails. `picker` makes the strip pick the current slide: a tap makes a thumbnail
|
|
502
|
+
current (the photo follows), the strip marks it (`current`) and follows it,
|
|
503
|
+
keeping it in the middle slot with the ends clamped, the arrow keys step one
|
|
504
|
+
thumbnail at a time, and a swipe only browses. The value is the photo, so the
|
|
505
|
+
main carousel can show one or several per view.
|
|
506
|
+
|
|
507
|
+
**A gallery with a picker strip**
|
|
508
|
+
|
|
509
|
+
```vue
|
|
510
|
+
<template>
|
|
511
|
+
<div class="grid gap-3">
|
|
512
|
+
<BbCarousel
|
|
513
|
+
v-model="photo"
|
|
514
|
+
class="[--ratio:3/2]"
|
|
515
|
+
:items="photos"
|
|
516
|
+
label="Lysefjord, day by day"
|
|
517
|
+
/>
|
|
518
|
+
<BbCarousel
|
|
519
|
+
v-model="photo"
|
|
520
|
+
class="[--gap:8px] [--per-view:4.5] [--py:4px] md:[--per-view:6]"
|
|
521
|
+
:items="photos"
|
|
522
|
+
label="Thumbnails"
|
|
523
|
+
picker
|
|
524
|
+
pt:dots="hidden"
|
|
525
|
+
>
|
|
526
|
+
<template #slide="{ item, index, current }">
|
|
527
|
+
<button
|
|
528
|
+
:aria-current="current || undefined"
|
|
529
|
+
:aria-label="`Show photo ${index + 1}: ${item.alt}`"
|
|
530
|
+
class="relative block w-full overflow-hidden rounded-(--bb-radius) transition after:absolute after:inset-0 after:rounded-[inherit] after:border-2 after:border-transparent focus-visible:outline-none focus-visible:after:border-(--bb-ring)"
|
|
531
|
+
:class="
|
|
532
|
+
current
|
|
533
|
+
? 'after:border-(--bb-primary)'
|
|
534
|
+
: 'opacity-60 hover:opacity-100'
|
|
535
|
+
"
|
|
536
|
+
type="button"
|
|
537
|
+
>
|
|
538
|
+
<img
|
|
539
|
+
alt=""
|
|
540
|
+
class="aspect-[3/2] w-full object-cover"
|
|
541
|
+
:src="item.src"
|
|
542
|
+
/>
|
|
543
|
+
</button>
|
|
544
|
+
</template>
|
|
545
|
+
</BbCarousel>
|
|
546
|
+
</div>
|
|
547
|
+
</template>
|
|
548
|
+
|
|
549
|
+
<script setup lang="ts">
|
|
550
|
+
import { ref } from 'vue';
|
|
551
|
+
import { BbCarousel } from 'bitboss-ui';
|
|
552
|
+
|
|
553
|
+
/** A gallery: the photo and a `picker` strip of thumbnails on ONE
|
|
554
|
+
* `v-model`. No sync code: a tap picks, the photo follows, the strip keeps
|
|
555
|
+
* the current thumbnail in view. */
|
|
556
|
+
const photos = [
|
|
557
|
+
{
|
|
558
|
+
src: 'https://picsum.photos/seed/fjord-rim/1200/800',
|
|
559
|
+
alt: 'The fjord from the rim',
|
|
560
|
+
},
|
|
561
|
+
{
|
|
562
|
+
src: 'https://picsum.photos/seed/fjord-pines/1200/800',
|
|
563
|
+
alt: 'Pines in low cloud',
|
|
564
|
+
},
|
|
565
|
+
{
|
|
566
|
+
src: 'https://picsum.photos/seed/fjord-dawn/1200/800',
|
|
567
|
+
alt: 'Fog over the valley at dawn',
|
|
568
|
+
},
|
|
569
|
+
{
|
|
570
|
+
src: 'https://picsum.photos/seed/fjord-peaks/1200/800',
|
|
571
|
+
alt: 'Peaks at sunset',
|
|
572
|
+
},
|
|
573
|
+
{
|
|
574
|
+
src: 'https://picsum.photos/seed/fjord-walls/1200/800',
|
|
575
|
+
alt: 'Rock walls in low sun',
|
|
576
|
+
},
|
|
577
|
+
{
|
|
578
|
+
src: 'https://picsum.photos/seed/fjord-aurora/1200/800',
|
|
579
|
+
alt: 'Aurora over the last camp',
|
|
580
|
+
},
|
|
581
|
+
{
|
|
582
|
+
src: 'https://picsum.photos/seed/fjord-boat/1200/800',
|
|
583
|
+
alt: 'The ferry back',
|
|
584
|
+
},
|
|
585
|
+
{
|
|
586
|
+
src: 'https://picsum.photos/seed/fjord-hut/1200/800',
|
|
587
|
+
alt: 'A red hut by the water',
|
|
588
|
+
},
|
|
589
|
+
];
|
|
590
|
+
const photo = ref(0);
|
|
591
|
+
</script>
|
|
592
|
+
```
|
|
593
|
+
|
|
594
|
+
### Slides per view and gap
|
|
595
|
+
|
|
596
|
+
Two locals on the root size the slides: `--per-view` (default `1`) and `--gap`
|
|
597
|
+
(default `16px`). Set them per breakpoint with utilities; a fraction shows a
|
|
598
|
+
peek of the next slide, which tells a phone reader there is more.
|
|
599
|
+
|
|
600
|
+
```vue
|
|
601
|
+
<BbCarousel
|
|
602
|
+
class="[--gap:12px] [--per-view:1.25] sm:[--per-view:3]"
|
|
603
|
+
label="Products"
|
|
604
|
+
>
|
|
605
|
+
…
|
|
606
|
+
</BbCarousel>
|
|
607
|
+
```
|
|
608
|
+
|
|
609
|
+
Several per view, the carousel moves a page at a time: as many slides as fit
|
|
610
|
+
whole (`--per-view: 2.3` pages by two). Nine slides at three per view are the
|
|
611
|
+
pages 1–3, 4–6, 7–9: the arrows and keys go 1 › 4 › 7, a swipe lands on a
|
|
612
|
+
page, and there is one dot per page. A last page that does not fill up shows
|
|
613
|
+
the last full view (nine at two per view: …, 7–8, 8–9). Over seven pages the
|
|
614
|
+
dots run in a window around the current one. When every slide fits, the
|
|
615
|
+
controls are not rendered. A fractional peek is not live: only the fully
|
|
616
|
+
visible slides take clicks and focus.
|
|
617
|
+
|
|
618
|
+
### Bleeding to the page edge
|
|
619
|
+
|
|
620
|
+
The common marketing layout: the page sits in a centred column, and the
|
|
621
|
+
carousel's slides start on the column's edge but run across the whole screen
|
|
622
|
+
as they move, the last one stopping on the column's far edge. Keep the
|
|
623
|
+
carousel in the column and set `bleed` (or the local `--bleed: auto`): the
|
|
624
|
+
track spills to the nearest ancestor that clips sideways (else the page
|
|
625
|
+
edge, scrollbar excluded), while the slides are still sized from the column
|
|
626
|
+
and snap to its edge. The dots stay centred on the column; the arrows sit at the bleed's
|
|
627
|
+
edges, over the peeking slides.
|
|
628
|
+
|
|
629
|
+
**A shop row running to the page edges**
|
|
630
|
+
|
|
631
|
+
```vue
|
|
632
|
+
<template>
|
|
633
|
+
<!-- The page column: the carousel sits in it, its slides run past it. -->
|
|
634
|
+
<div class="mx-auto max-w-[960px] px-4">
|
|
635
|
+
<BbCarousel
|
|
636
|
+
bleed
|
|
637
|
+
class="[--per-view:1.3] sm:[--per-view:2.5] lg:[--per-view:4]"
|
|
638
|
+
:items="products"
|
|
639
|
+
label="New this season"
|
|
640
|
+
>
|
|
641
|
+
<template #slide="{ item }">
|
|
642
|
+
<article class="grid gap-2">
|
|
643
|
+
<img
|
|
644
|
+
:alt="item.name"
|
|
645
|
+
class="aspect-[4/5] w-full rounded-(--bb-radius) bg-(--bb-muted) object-cover"
|
|
646
|
+
loading="lazy"
|
|
647
|
+
:src="item.photo"
|
|
648
|
+
/>
|
|
649
|
+
<div class="grid gap-0.5 text-sm">
|
|
650
|
+
<p class="m-0 font-medium">{{ item.name }}</p>
|
|
651
|
+
<p class="m-0 flex items-baseline gap-2">
|
|
652
|
+
<span class="font-semibold">{{ item.price }}</span>
|
|
653
|
+
<s v-if="item.was" class="text-(--bb-text-muted)">{{
|
|
654
|
+
item.was
|
|
655
|
+
}}</s>
|
|
656
|
+
</p>
|
|
657
|
+
</div>
|
|
658
|
+
</article>
|
|
659
|
+
</template>
|
|
660
|
+
<template #overlay="{ item }">
|
|
661
|
+
<BbBadge v-if="item?.badge" class="absolute top-3 left-3">
|
|
662
|
+
{{ item.badge }}
|
|
663
|
+
</BbBadge>
|
|
664
|
+
<BbButton
|
|
665
|
+
v-if="item"
|
|
666
|
+
:aria-label="`Save ${item.name}`"
|
|
667
|
+
class="absolute top-2 right-2"
|
|
668
|
+
icon="lucide:heart"
|
|
669
|
+
:model-value="saved.has(item.id)"
|
|
670
|
+
variant="secondary"
|
|
671
|
+
@update:model-value="toggle(item.id)"
|
|
672
|
+
/>
|
|
673
|
+
</template>
|
|
674
|
+
</BbCarousel>
|
|
675
|
+
</div>
|
|
676
|
+
</template>
|
|
677
|
+
|
|
678
|
+
<script setup lang="ts">
|
|
679
|
+
import { ref } from 'vue';
|
|
680
|
+
import { BbBadge, BbButton, BbCarousel } from 'bitboss-ui';
|
|
681
|
+
|
|
682
|
+
/** A shop row: cards through `#slide`, the badge and the save button on
|
|
683
|
+
* `#overlay`, the row running to the page edges (`bleed`). */
|
|
684
|
+
type Product = {
|
|
685
|
+
id: string;
|
|
686
|
+
name: string;
|
|
687
|
+
price: string;
|
|
688
|
+
was?: string;
|
|
689
|
+
photo: string;
|
|
690
|
+
badge?: string;
|
|
691
|
+
};
|
|
692
|
+
|
|
693
|
+
const products: Product[] = [
|
|
694
|
+
{
|
|
695
|
+
id: 'merino',
|
|
696
|
+
name: 'Merino crew, slate',
|
|
697
|
+
price: '€ 89',
|
|
698
|
+
photo: 'https://picsum.photos/seed/merino-crew/600/750',
|
|
699
|
+
badge: 'New',
|
|
700
|
+
},
|
|
701
|
+
{
|
|
702
|
+
id: 'runner',
|
|
703
|
+
name: 'Trail runner 3',
|
|
704
|
+
price: '€ 129',
|
|
705
|
+
was: '€ 159',
|
|
706
|
+
photo: 'https://picsum.photos/seed/trail-runner/600/750',
|
|
707
|
+
badge: 'Sale',
|
|
708
|
+
},
|
|
709
|
+
{
|
|
710
|
+
id: 'jacket',
|
|
711
|
+
name: 'Waxed field jacket',
|
|
712
|
+
price: '€ 239',
|
|
713
|
+
photo: 'https://picsum.photos/seed/field-jacket/600/750',
|
|
714
|
+
},
|
|
715
|
+
{
|
|
716
|
+
id: 'mug',
|
|
717
|
+
name: 'Enamel camp mug',
|
|
718
|
+
price: '€ 14',
|
|
719
|
+
photo: 'https://picsum.photos/seed/camp-mug/600/750',
|
|
720
|
+
},
|
|
721
|
+
{
|
|
722
|
+
id: 'vest',
|
|
723
|
+
name: 'Down vest, olive',
|
|
724
|
+
price: '€ 149',
|
|
725
|
+
photo: 'https://picsum.photos/seed/down-vest/600/750',
|
|
726
|
+
},
|
|
727
|
+
{
|
|
728
|
+
id: 'tote',
|
|
729
|
+
name: 'Canvas tote',
|
|
730
|
+
price: '€ 39',
|
|
731
|
+
photo: 'https://picsum.photos/seed/canvas-tote/600/750',
|
|
732
|
+
},
|
|
733
|
+
];
|
|
734
|
+
|
|
735
|
+
const saved = ref(new Set<string>());
|
|
736
|
+
const toggle = (id: string) => {
|
|
737
|
+
const next = new Set(saved.value);
|
|
738
|
+
if (!next.delete(id)) next.add(id);
|
|
739
|
+
saved.value = next;
|
|
740
|
+
};
|
|
741
|
+
</script>
|
|
742
|
+
```
|
|
743
|
+
|
|
744
|
+
It works on any slides, plain markup included:
|
|
745
|
+
|
|
746
|
+
```vue
|
|
747
|
+
<div class="mx-auto max-w-[960px] px-4">
|
|
748
|
+
<BbCarousel bleed :per-view="1.2" label="Stories">
|
|
749
|
+
<article>…</article>
|
|
750
|
+
<article>…</article>
|
|
751
|
+
<article>…</article>
|
|
752
|
+
</BbCarousel>
|
|
753
|
+
</div>
|
|
754
|
+
```
|
|
755
|
+
|
|
756
|
+
`--bleed` also takes a length, and per side `--bleed-start` / `--bleed-end`;
|
|
757
|
+
set it per breakpoint like the other locals (`lg:[--bleed:0px]`). `auto` is
|
|
758
|
+
measured in the browser, so a server-rendered page shows no bleed until the
|
|
759
|
+
carousel mounts, then the peeks appear; a length (the column's gutter, say
|
|
760
|
+
`[--bleed:16px]`) is pure CSS and exact from the first paint. `:bleed="false"`
|
|
761
|
+
sets the bleed to `0`. `auto` follows the reading direction (in RTL the start
|
|
762
|
+
side is the right). On a phone the column's gutter becomes the peek. A click
|
|
763
|
+
on a peeking slide brings it in; `--peek-click: off` turns that off. To dim
|
|
764
|
+
the slides outside the column, style the ones that are not `active` (in view;
|
|
765
|
+
it follows a swipe as it goes):
|
|
766
|
+
|
|
767
|
+
```vue
|
|
768
|
+
<BbCarousel
|
|
769
|
+
bleed
|
|
770
|
+
pt:slide="opacity-40 transition-opacity"
|
|
771
|
+
pt:slide:active="opacity-100"
|
|
772
|
+
>…</BbCarousel>
|
|
773
|
+
```
|
|
774
|
+
|
|
775
|
+
An ancestor with `overflow: hidden` between the carousel and the page edge
|
|
776
|
+
cuts the bleed at that ancestor; that is where `auto` stops.
|
|
777
|
+
|
|
778
|
+
### Current slide, loop
|
|
779
|
+
|
|
780
|
+
`v-model` is the current slide, 0-based: any slide, whatever fits per view;
|
|
781
|
+
without it the carousel keeps its own. The current slide is `current` (the
|
|
782
|
+
slot prop and `pt:slide:current`); the slides in view are `active`. Writing it shows the page that holds it,
|
|
783
|
+
moving only if it is not in view already; an out-of-range value is brought
|
|
784
|
+
back to the first or last slide and written back. A click on a slide makes
|
|
785
|
+
it current, the view staying put; a page turned by the arrows, keys, dots,
|
|
786
|
+
autoplay or a swipe makes its first slide current (a swipe keeps the current
|
|
787
|
+
slide while it is still in view). `loop` makes the run endless: the buttons,
|
|
788
|
+
keys, autoplay and a swipe all carry on past the last page into the first,
|
|
789
|
+
with no rewind.
|
|
790
|
+
|
|
791
|
+
Because the value is the slide, the page can drive it: here the page's own
|
|
792
|
+
Back / Next and a progress bar share it, and the carousel's arrows are hidden.
|
|
793
|
+
|
|
794
|
+
**Onboarding driven from outside**
|
|
795
|
+
|
|
796
|
+
```vue
|
|
797
|
+
<template>
|
|
798
|
+
<div class="grid max-w-md gap-4 rounded-(--bb-radius) border p-5">
|
|
799
|
+
<BbProgress
|
|
800
|
+
label="Setup progress"
|
|
801
|
+
:max="steps.length"
|
|
802
|
+
:model-value="step + 1"
|
|
803
|
+
/>
|
|
804
|
+
<BbCarousel
|
|
805
|
+
v-model="step"
|
|
806
|
+
:items="steps"
|
|
807
|
+
label="Getting started"
|
|
808
|
+
pt:next="hidden"
|
|
809
|
+
pt:prev="hidden"
|
|
810
|
+
>
|
|
811
|
+
<template #slide="{ item }">
|
|
812
|
+
<div class="grid min-h-28 content-center gap-1">
|
|
813
|
+
<p class="m-0 text-lg font-semibold">{{ item.title }}</p>
|
|
814
|
+
<p class="m-0 text-sm text-(--bb-text-muted)">{{ item.body }}</p>
|
|
815
|
+
</div>
|
|
816
|
+
</template>
|
|
817
|
+
</BbCarousel>
|
|
818
|
+
<div class="mt-6 flex justify-between gap-2">
|
|
819
|
+
<BbButton :disabled="step === 0" variant="ghost" @click="step--">
|
|
820
|
+
Back
|
|
821
|
+
</BbButton>
|
|
822
|
+
<BbButton v-if="step < steps.length - 1" @click="step++">Next</BbButton>
|
|
823
|
+
<BbButton v-else @click="step = 0">Finish</BbButton>
|
|
824
|
+
</div>
|
|
825
|
+
</div>
|
|
826
|
+
</template>
|
|
827
|
+
|
|
828
|
+
<script setup lang="ts">
|
|
829
|
+
import { ref } from 'vue';
|
|
830
|
+
import { BbButton, BbCarousel, BbProgress } from 'bitboss-ui';
|
|
831
|
+
|
|
832
|
+
/** Onboarding driven from outside: the page's own Back / Next and a
|
|
833
|
+
* progress bar share the carousel's `v-model`; its arrows are hidden, the
|
|
834
|
+
* dots and the swipe stay. */
|
|
835
|
+
const steps = [
|
|
836
|
+
{
|
|
837
|
+
title: 'Pick your home store',
|
|
838
|
+
body: 'Rentals and repairs are booked there; you can change it any time.',
|
|
839
|
+
},
|
|
840
|
+
{
|
|
841
|
+
title: 'Tell us what you climb',
|
|
842
|
+
body: 'We use it to suggest gear and trips, nothing else.',
|
|
843
|
+
},
|
|
844
|
+
{
|
|
845
|
+
title: 'Turn on trip alerts',
|
|
846
|
+
body: 'One message when a rental is ready, one when it is due back.',
|
|
847
|
+
},
|
|
848
|
+
];
|
|
849
|
+
const step = ref(0);
|
|
850
|
+
</script>
|
|
851
|
+
```
|
|
852
|
+
|
|
853
|
+
A move takes 300 ms on CSS's `ease` curve, the motion Swiper uses; a move
|
|
854
|
+
that starts while the track is already moving (a quick second press, a released
|
|
855
|
+
drag) keeps the speed it has, so nothing stalls or kicks. `--speed` changes the
|
|
856
|
+
duration (`[--speed:450ms]`; `0ms` jumps), and under
|
|
857
|
+
`prefers-reduced-motion` every move jumps. A released drag goes where the
|
|
858
|
+
whole gesture points: a quick swipe one page on, a slower drag to the nearest
|
|
859
|
+
page; a wobble back just before letting go does not reverse it.
|
|
860
|
+
|
|
861
|
+
### Autoplay
|
|
862
|
+
|
|
863
|
+
Off by default. `autoplay` (`true` = every 5 s, or a number of ms) advances and
|
|
864
|
+
wraps, following the APG rotation rules:
|
|
865
|
+
|
|
866
|
+
- it pauses while the pointer is over the carousel, while a finger holds it,
|
|
867
|
+
and while it is scrolled out of view or the page is hidden;
|
|
868
|
+
- keyboard focus entering it stops it until the reader presses Play;
|
|
869
|
+
- any move the reader makes restarts the countdown;
|
|
870
|
+
- it never runs under `prefers-reduced-motion`, and then shows no pause
|
|
871
|
+
button.
|
|
872
|
+
|
|
873
|
+
The pause button leads the dots' row: never over the slides' content, and
|
|
874
|
+
always shown (a touch screen cannot hover). Hide the dots with `pt:dot="hidden"`
|
|
875
|
+
and the pause button stays alone; `pt:dots="hidden"` hides the whole row,
|
|
876
|
+
pause included, so keep it for carousels without autoplay.
|
|
877
|
+
|
|
878
|
+
Keep it for decorative rotation; content the reader must see should not move
|
|
879
|
+
on its own.
|
|
880
|
+
|
|
881
|
+
**An announcement bar**
|
|
882
|
+
|
|
883
|
+
```vue
|
|
884
|
+
<template>
|
|
885
|
+
<BbCarousel
|
|
886
|
+
:autoplay="4500"
|
|
887
|
+
:items="headlines"
|
|
888
|
+
label="Announcements"
|
|
889
|
+
loop
|
|
890
|
+
pt:dot="hidden"
|
|
891
|
+
>
|
|
892
|
+
<template #slide="{ item }">
|
|
893
|
+
<p
|
|
894
|
+
class="m-0 grid h-10 place-items-center rounded-(--bb-radius) bg-(--bb-primary) px-12 text-center text-sm font-medium text-(--bb-primary-fg)"
|
|
895
|
+
>
|
|
896
|
+
{{ item }}
|
|
897
|
+
</p>
|
|
898
|
+
</template>
|
|
899
|
+
</BbCarousel>
|
|
900
|
+
</template>
|
|
901
|
+
|
|
902
|
+
<script setup lang="ts">
|
|
903
|
+
import { BbCarousel } from 'bitboss-ui';
|
|
904
|
+
|
|
905
|
+
/** An announcement bar: a slim strip that turns on its own. The dots are
|
|
906
|
+
* hidden with `pt:dot`, so the pause button stays (`pt:dots` would hide it
|
|
907
|
+
* too). */
|
|
908
|
+
const headlines = [
|
|
909
|
+
'Free repairs on everything bought since 2006, in any store.',
|
|
910
|
+
'Winter rentals open on 18 November: book a weekend tent now.',
|
|
911
|
+
'Returns are free for 60 days, even when the tags are off.',
|
|
912
|
+
];
|
|
913
|
+
</script>
|
|
914
|
+
```
|
|
915
|
+
|
|
916
|
+
### Keyboard and touch
|
|
917
|
+
|
|
918
|
+
- Swipe or flick on touch and trackpads; a fast flick stops at the next page.
|
|
919
|
+
- Drag with the mouse on desktop; the click that ends a drag does not reach
|
|
920
|
+
the slide.
|
|
921
|
+
- With focus on the controls, after clicking a slide, or on a link or button
|
|
922
|
+
inside a slide: ArrowLeft / ArrowRight (mirrored in RTL), Home, End; from
|
|
923
|
+
inside a slide the focus follows to the current slide. Content that uses the
|
|
924
|
+
arrows itself (a text field, a slider, tabs, a nested carousel) keeps them.
|
|
925
|
+
- The arrows show on hover and while keyboard focus is inside; on touch they
|
|
926
|
+
stay hidden (the swipe is the gesture) but remain in the accessibility tree.
|
|
927
|
+
- On a coarse pointer the pause button reaches 44×44 and the dots 44px tall,
|
|
928
|
+
invisibly: nothing moves.
|
|
929
|
+
|
|
930
|
+
### Restyling with passthrough
|
|
931
|
+
|
|
932
|
+
Parts: `root`, `slide`, `image`, `prev`, `next`, `dots`, `dot`, `pause`.
|
|
933
|
+
States: `active` (the slides in view, the current page's dot), `current` (the
|
|
934
|
+
`v-model` slide) and `disabled` (`prev` /
|
|
935
|
+
`next` at an end without `loop`). The slides' corner radius is the `--r`
|
|
936
|
+
local, the dot colours `--dot` / `--dot-active`.
|
|
937
|
+
|
|
938
|
+
The scroller that holds the slides is not a part, on purpose: its gap,
|
|
939
|
+
overflow, snapping and padding are what the slide widths and snap points are
|
|
940
|
+
computed from, so a class there breaks the carousel. Leave it alone. Its look
|
|
941
|
+
(a background behind the slides, a border or a shadow, the corners) goes on
|
|
942
|
+
the root, and the spacing is `--gap`: `class="[--gap:24px]"`, never a `gap-*`
|
|
943
|
+
utility.
|
|
944
|
+
|
|
945
|
+
```vue
|
|
946
|
+
<BbCarousel
|
|
947
|
+
pt:dot:active="[--dot-active:var(--bb-primary)]"
|
|
948
|
+
label="…"
|
|
949
|
+
>…</BbCarousel>
|
|
950
|
+
```
|
|
951
|
+
|
|
952
|
+
Where the dots sit depends on the slides. Over built-in images (`items` of
|
|
953
|
+
photos, no `slide` slot, no `slide:header` / `slide:footer`) they overlay the
|
|
954
|
+
bottom of the photos, on a pill.
|
|
955
|
+
Over anything else (cards, `slide` slot markup, plain children) they would
|
|
956
|
+
land on the content, so they sit in a row below the slides, in the page's
|
|
957
|
+
colours, with room reserved for them (a background painted on the root
|
|
958
|
+
covers that row too: give it its own `--dot` / `--dot-active`). The root
|
|
959
|
+
never clips, so `pt:dots` can still move them (photos with a caption at the
|
|
960
|
+
bottom want them below too) or hide them.
|
|
961
|
+
|
|
962
|
+
```vue
|
|
963
|
+
<BbCarousel
|
|
964
|
+
pt:root="mb-8"
|
|
965
|
+
pt:dots="top-full bottom-auto mt-2 bg-transparent [--dot:var(--bb-text-muted)] [--dot-active:var(--bb-text)]"
|
|
966
|
+
label="…"
|
|
967
|
+
>…</BbCarousel>
|
|
968
|
+
<BbCarousel pt:dots="hidden" label="…">…</BbCarousel>
|
|
969
|
+
```
|
|
970
|
+
|
|
971
|
+
The arrows are centred between two insets, so moving one takes a pair: set the
|
|
972
|
+
side it goes to and release the other.
|
|
973
|
+
|
|
974
|
+
```vue
|
|
975
|
+
<BbCarousel
|
|
976
|
+
pt:prev="top-auto right-16 bottom-3 left-auto"
|
|
977
|
+
pt:next="top-auto bottom-3"
|
|
978
|
+
label="…"
|
|
979
|
+
>…</BbCarousel>
|
|
980
|
+
```
|
|
981
|
+
|
|
982
|
+
### Accessibility
|
|
983
|
+
|
|
984
|
+
- The APG carousel pattern: the root is a labelled region with
|
|
985
|
+
`aria-roledescription="carousel"`, each slide a group "3 of 8" with
|
|
986
|
+
`aria-roledescription="slide"`. Give the carousel a `label`.
|
|
987
|
+
- Slides out of view are `inert`, so Tab never lands on a hidden slide; when
|
|
988
|
+
the slide holding focus leaves, focus moves to the carousel, never to the
|
|
989
|
+
page.
|
|
990
|
+
- A move the reader makes is announced politely ("2 of 5") once it lands;
|
|
991
|
+
nothing is announced while autoplay runs (APG).
|
|
992
|
+
- The controls come before the slides in the tab order, the pause button
|
|
993
|
+
first; the dots are one Tab stop (the current dot).
|
|
994
|
+
- The server renders every slide live and no controls (it cannot know how
|
|
995
|
+
many fit); they appear once the carousel mounts.
|
|
996
|
+
|
|
997
|
+
## v-model
|
|
998
|
+
|
|
999
|
+
- `v-model` — type: `number \| undefined`
|
|
1000
|
+
|
|
1001
|
+
## Props
|
|
1002
|
+
|
|
1003
|
+
| Prop | Type | Default | Required | Description |
|
|
1004
|
+
| --- | --- | --- | --- | --- |
|
|
1005
|
+
| `pt:<part>`, `pt:<part>:<state>`, `pt` | `PtValue` | | | Passthrough — a class list, or `{ class, style, attrs }`, bound to one named part of the component; the state form applies only while that state is on. Parts: `dot`, `dots`, `image`, `next`, `overlay`, `pause`, `prev`, `root`, `slide`. States: `active`, `disabled`, `current`. What each one is: _Passthrough parts and states_ below. `pt` is the object form with the same keys minus the prefix (`{ icon: '…', 'icon:loading': '…' }`). See `guides/passthrough.md`. In `<script>` a `pt` value is typed `BbCarouselProps<Row>['pt']` (`BbCarouselProps<object>['pt']` for a preset that fits any row type, never `<any>`) (`PtValue` is not exported): § Typing `pt` in `<script>`. |
|
|
1006
|
+
| `align` | `"start" \| "center" \| undefined` | ``undefined` (the local's own default: `start`)` | | Where the current slide sits: `start` (the column's start edge) or `center` (the middle, neighbours peeking on both sides). Sets the `--align` local; leave it out to set the local yourself, never both (`bitboss-ui/carousel-prop-or-local`). |
|
|
1007
|
+
| `autoplay` | `number \| boolean \| undefined` | `false` | | Advance on a timer, in ms (`true` = 5000). Pauses while hovered, while focus is inside and with the pause button; never runs under `prefers-reduced-motion`. |
|
|
1008
|
+
| `bleed` | `boolean \| undefined` | ``undefined` (no bleed)` | | Lets the slides run past the carousel to the page edge, while they still snap to and size from the carousel (`--bleed: auto`). Leave it out to set the `--bleed` locals yourself (a length, one side, per breakpoint); never both (`bitboss-ui/carousel-prop-or-local`). |
|
|
1009
|
+
| `items` | `number \| readonly T[] \| undefined` | `undefined` | | The slides as data, rendered through the `slide` slot (`item` is the entry; with a number, that many slides and `item` is the index). Without the slot, an image URL or a `{ src, alt }` entry renders as a cover image. Without `items`, each default-slot child is a slide. |
|
|
1010
|
+
| `label` | `string \| undefined` | `undefined` | | The carousel's accessible name. Default: the locale's "Carousel". |
|
|
1011
|
+
| `loop` | `boolean \| undefined` | `false` | | An endless run: buttons, keys, autoplay, a swipe and a mouse drag all carry on past the last slide into the first (and back), with no rewind. |
|
|
1012
|
+
| `modelValue` | `number \| undefined` | `0` | | The current slide, 0-based, never clamped to a scroll position: the view shows the page that holds it. Out of range, it is brought back and written back. The current slide: any slide, 0 to the last. The view shows the page that holds it; a value out of range is brought back in and written back. |
|
|
1013
|
+
| `perView` | `number \| undefined` | ``undefined` (the local's own default: 1)` | | Slides in view; a fraction shows a peek of the next (`1.2`). Sets the `--per-view` local. Leave it out to set the local yourself, for instance per breakpoint (`class="[--per-view:1.2] md:[--per-view:3]"`); never both (`bitboss-ui/carousel-prop-or-local`). |
|
|
1014
|
+
| `picker` | `boolean \| undefined` | `false` | | A strip that picks the current slide, typically thumbnails under a big photo on the same `v-model` (also dates, colour swatches): it steps one slide at a time (arrows, keys), follows the current one, keeping it in the middle slot with the ends clamped, and a swipe only browses. |
|
|
1015
|
+
|
|
1016
|
+
## Passthrough parts and states
|
|
1017
|
+
|
|
1018
|
+
`pt:<part>="…"` restyles a part; `pt:<part>:<state>="…"` applies only while the state is on. A component-wide state is on for every part at once; a _per node_ state resolves on each node of a broadcast part (one row, one option, one day). Grammar and merge rules: `guides/passthrough.md`. In `<script>`, type a `pt` value as `<Component>Props['pt']` (`<Component>Props<Row>['pt']` on a generic component); `PtValue` is not exported: `guides/passthrough.md` § Typing `pt` in `<script>`.
|
|
1019
|
+
|
|
1020
|
+
| Part | What it is |
|
|
1021
|
+
| --- | --- |
|
|
1022
|
+
| `root` | The carousel region (`aria-roledescription="carousel"`). Its locals size the slides: `--per-view` (slides in view, default `1`) and `--gap` (between slides, default `16px`). Set them per breakpoint with utilities (`class="md:[--per-view:2]"`). `--bleed` (`auto` or a length; per side `--bleed-start` / `--bleed-end`) lets the slides run past the root to the page edge while they still snap to the root's edge. `--speed` (default `300ms`) is how long a move takes. The root also carries what looks like the strip's own styling: a background behind the slides, a border or a shadow around them, the corners (`--r`). |
|
|
1023
|
+
| `slide` | One slide (`aria-roledescription="slide"`, "3 of 8"). |
|
|
1024
|
+
| `image` | The image an image-URL entry of `items`, or an entry with a `src` or a `srcset`, renders without a `slide` slot. Its crop is the root's `--ratio` local (default `16 / 9`), or the root's height when it has one. The track (the scroller between the root and the slides) is deliberately NOT a part: its gap, overflow, snapping and padding are the carousel's geometry (the slide widths, the snap points and the bleed are computed from the same values), so a class there breaks the carousel, and the root already covers every look a consumer needs. Weigh any change that would expose it, or add to what it does, against that. |
|
|
1025
|
+
| `overlay` | The layer the `overlay` slot renders on top of each slide: the slide's size, empty by default, letting taps through where it has no content. |
|
|
1026
|
+
| `prev` | The previous-slide button. |
|
|
1027
|
+
| `next` | The next-slide button. |
|
|
1028
|
+
| `dots` | The row of dot buttons. |
|
|
1029
|
+
| `dot` | One dot (one per page). |
|
|
1030
|
+
| `pause` | The autoplay pause / play button (only with `autoplay`), first in the dots' row. |
|
|
1031
|
+
|
|
1032
|
+
States are listed in precedence order: when two are on at once and their entries conflict, the later one wins.
|
|
1033
|
+
|
|
1034
|
+
| State | When it is on |
|
|
1035
|
+
| --- | --- |
|
|
1036
|
+
| `current` | Per node, on `slide`: the current slide (the `v-model`). |
|
|
1037
|
+
| `disabled` | Per node, on `prev` / `next`: the button at an end without `loop`. |
|
|
1038
|
+
| `active` | Per node, on `slide` / `dot`: a slide in view (a fractional peek and, with `--bleed`, the slides outside the root are not), live while a swipe runs; the current page's dot. |
|
|
1039
|
+
|
|
1040
|
+
## Events
|
|
1041
|
+
|
|
1042
|
+
- `update:modelValue` — `(value: number): void` — Emitted with the new value whenever `v-model` changes.
|
|
1043
|
+
|
|
1044
|
+
## Slots
|
|
1045
|
+
|
|
1046
|
+
- `default` — scope: `any` — The slides: one per child.
|
|
1047
|
+
- `overlay` — scope: `BbCarouselSlotProps<T \| undefined>` `{ item: T; index: number; active: boolean; current: boolean }` — A layer on top of each slide (any kind), moving with it: captions, badges, glyphs, buttons.
|
|
1048
|
+
- `slide` — scope: `BbCarouselSlotProps<T>` `{ item: T; index: number; active: boolean; current: boolean }` — One slide's content, from `items` (replaces the built-in image).
|
|
1049
|
+
- `slide:footer` — scope: `BbCarouselSlotProps<T \| undefined>` `{ item: T; index: number; active: boolean; current: boolean }` — Below each slide's content, inside the slide (any kind of slide): a caption, a price, a link.
|
|
1050
|
+
- `slide:header` — scope: `BbCarouselSlotProps<T \| undefined>` `{ item: T; index: number; active: boolean; current: boolean }` — Above each slide's content, inside the slide (any kind of slide; the built-in image keeps its lazy loading, sizes and crop): a kicker, a title.
|
|
1051
|
+
|
|
1052
|
+
## CSS custom properties
|
|
1053
|
+
|
|
1054
|
+
Set these on the element, or on a class you put on it, to retune this component alone — the sanctioned alternative to reaching past the API with `:deep()`. They are this component's own locals — a **Set on** of `pt:<part>` means the local lives on that part's element, so set it through that entry (`pt:box="[--border-color:var(--color-green-500)]"`); the global `--bb-*` theme tokens are a separate tier (see the [design-tokens guide](./guides/design-tokens.md), or the MCP `list_tokens` tool).
|
|
1055
|
+
|
|
1056
|
+
| Property | Set on | Default | What it is |
|
|
1057
|
+
| --- | --- | --- | --- |
|
|
1058
|
+
| `--per-view` | `.bb-carousel` | `1` | |
|
|
1059
|
+
| `--gap` | `.bb-carousel` | `16px` | |
|
|
1060
|
+
| `--r` | `.bb-carousel` | `var(--bb-radius)` | |
|
|
1061
|
+
| `--ratio` | `.bb-carousel` | `16 / 9` | |
|
|
1062
|
+
| `--dot` | `.bb-carousel` | `rgb(255 255 255 / 0.8)` | |
|
|
1063
|
+
| `--dot-active` | `.bb-carousel` | `rgb(255 255 255)` | |
|
|
1064
|
+
| `--speed` | `.bb-carousel` | `300ms` | |
|
|
1065
|
+
| `--align` | `.bb-carousel` | `start` | |
|
|
1066
|
+
| `--py` | `.bb-carousel` | `0px` | Room above and below the slides inside the track (see the track). |
|
|
1067
|
+
| `--bleed` | `.bb-carousel` | `0px` | |
|
|
1068
|
+
| `--bleed-start` | `.bb-carousel` | `var(--bleed)` | |
|
|
1069
|
+
| `--bleed-end` | `.bb-carousel` | `var(--bleed)` | |
|
|
1070
|
+
| `--_bs` | `.bb-carousel` | `var(--_bleed-start, var(--bleed-start))` | The resolved bleed per side (the measured `auto`, or the length): read by the track and, when bled, by the arrows. |
|
|
1071
|
+
| `--_be` | `.bb-carousel` | `var(--_bleed-end, var(--bleed-end))` | |
|
|
1072
|
+
| `--arrow` | `.bb-carousel` | `clamp( 28px, (100% - (var(--per-view) - 1) * var(--gap)) / var(--per-view) * 0.0…` | The controls scale with ONE SLIDE: a wide hero gets big arrows, a row of narrow cards small ones, at the same carousel width. A percentage, not `cqi`: they are absolutely positioned, so `100%` is the root's width. A size container (`container-type: inline-size`) would collapse a carousel that takes its width from its content (a centred flex column, Storybook's own canvas) to 0. Read where it is used, so only in a `width` (never a `height`: there `%` is the root's height). |
|
|
1073
|
+
| `--inset` | `.bb-carousel` | `12px` | |
|
|
1074
|
+
| `--_tr` | `.bb-carousel__track` | `var(--r)` | Rounded too: a slide half out of view is cut by the track's edge, and a square edge there would square its corners mid-swipe. |
|
|
1075
|
+
| `--_dots-band` | `.bb-carousel--dots-below` | `24px` | |
|
|
1076
|
+
| `--dot` | `.bb-carousel--dots-below` | `var(--bb-text-muted)` | |
|
|
1077
|
+
| `--dot-active` | `.bb-carousel--dots-below` | `var(--bb-text)` | |
|
|
1078
|
+
|
|
1079
|
+
## Component tree
|
|
1080
|
+
|
|
1081
|
+
`BbCarousel` is not one component: rendering it mounts every component below, and each one is live inside it. **Read this before styling, theming or debugging `BbCarousel`, and before concluding a part, a token or a behaviour does not exist** — it may live on a component further down. How to read it:
|
|
1082
|
+
|
|
1083
|
+
- **_internal_** nodes are building blocks with no API of their own: you reach them only through `BbCarousel`. A pt part listed as landing there is set on `BbCarousel` (`pt:<part>`).
|
|
1084
|
+
- **_public_** nodes are components with their own contract. `BbCarousel` reaches one only through a pt part of its own that lands on it (shown on the parent node as `part → Component`, e.g. `spinner → BbSpinner`) or through a pt map it hands it (shown as "hands … the pt map", in `BbCarousel`'s words → the child's). The child's other props and parts are not exposed; its contract explains what it renders.
|
|
1085
|
+
- **CSS custom properties** listed on a node are declared on THAT node's root and read by elements inside it. Set one on that node's root or on the element inside it that reads it — the pt part that lands there is how you reach it (`pt:box="[--border-color:…]"` on a text input) — never on `BbCarousel`'s root, where the node's own declaration masks it (design-tokens guide, _Overriding one from a consumer app_, rule 0).
|
|
1086
|
+
- Listed nodes are the ones `BbCarousel`'s API reaches or that declare a documented CSS variable; the rest fold into "also mounts". The complete tree, undocumented locals included, is `manifest/components/BbCarousel.tree.json` (a public component in it is a name: its own tree file has the rest).
|
|
1087
|
+
|
|
1088
|
+
- `BbCarousel` _(this component)_ — its own template binds: `dots` → `div.bb-carousel__dots`, `pause` → `button.bb-carousel__pause`, `dot` → `button.bb-carousel__dot`, `prev` → `button.bb-carousel__arrow`, `next` → `button.bb-carousel__arrow`, `slide` → `div.bb-carousel__slide`, `image` → `img.bb-carousel__image`, `overlay` → `div.bb-carousel__overlay`
|
|
1089
|
+
- Also mounts `BbIcon`
|
|
1090
|
+
|
|
1091
|
+
## See Also
|
|
1092
|
+
|
|
1093
|
+
- [BbTabs](./BbTabs.md) — Switches between views of one page from a row of tabs. For the tabs and their panels in different places of the layout, use BbTabsRoot with BbTabsList and BbTabsPanels.
|