bitboss-ui 3.0.0-beta.74 → 3.0.0-beta.76
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 +5 -5
- package/bin/cli.mjs +16 -10
- package/dist/ai/BbAlert.md +1 -1
- package/dist/ai/BbAvatar.md +86 -58
- package/dist/ai/BbBadge.md +1 -1
- package/dist/ai/BbBreadcrumbs.md +3 -3
- package/dist/ai/BbButton.md +4 -4
- package/dist/ai/BbCalendar.md +5 -2
- package/dist/ai/BbCheckboxGroup.md +5 -4
- package/dist/ai/BbColorInput.md +13 -1
- package/dist/ai/BbColorPalette.md +12 -7
- package/dist/ai/BbConfirm.md +1 -1
- package/dist/ai/BbDatePicker.md +13 -1
- package/dist/ai/BbDatePickerInput.md +18 -2
- package/dist/ai/BbDialog.md +6 -3
- package/dist/ai/BbDropdown.md +174 -77
- package/dist/ai/BbDropdownButton.md +37 -16
- package/dist/ai/BbGallery.md +3 -2
- package/dist/ai/BbIcon.md +10 -10
- package/dist/ai/BbNumberInput.md +3 -1
- package/dist/ai/BbOffCanvas.md +3 -2
- package/dist/ai/BbPopover.md +1 -1
- package/dist/ai/BbRadioGroup.md +4 -4
- package/dist/ai/BbSelect.md +227 -105
- package/dist/ai/BbSelectPopover.md +139 -14
- package/dist/ai/BbSwitchGroup.md +5 -4
- package/dist/ai/BbTable.md +18 -17
- package/dist/ai/BbTimePicker.md +13 -1
- package/dist/ai/BbTimePickerInput.md +16 -2
- package/dist/ai/BbToast.md +3 -2
- package/dist/ai/BbTree.md +5 -1
- package/dist/ai/CommonPopover.md +1 -0
- package/dist/ai/FlatListBox.md +1 -0
- package/dist/ai/GroupedListBox.md +3 -2
- package/dist/ai/ListBox.md +4 -2
- package/dist/ai/OptionsContainer.md +4 -4
- package/dist/ai/changelog.json +310 -7
- package/dist/ai/components.json +33 -35
- package/dist/ai/composables/useToast.md +2 -2
- package/dist/ai/design-tokens.json +60 -0
- package/dist/ai/guides/agent-contract.md +9 -5
- package/dist/ai/guides/calendars-and-digits.md +1 -1
- package/dist/ai/guides/design-tokens.md +13 -0
- package/dist/ai/guides/eslint-rules.md +1 -1
- package/dist/ai/guides/fetch-items-playbook.md +7 -11
- package/dist/ai/guides/icons-policy.md +32 -11
- package/dist/ai/guides/installation-and-plugin-setup.md +24 -23
- package/dist/ai/guides/migration/adoption-checklist.md +1 -1
- package/dist/ai/guides/migration/components/bb-color-palette.md +11 -11
- package/dist/ai/guides/migration/components/bb-dropdown-button.md +1 -0
- package/dist/ai/guides/migration/components/bb-dropdown.md +1 -0
- package/dist/ai/guides/migration/components/bb-icon.md +4 -4
- package/dist/ai/guides/migration/components/bb-table.md +2 -1
- package/dist/ai/guides/migration/components/bb-toast.md +2 -2
- package/dist/ai/guides/migration/v2-to-v3.md +70 -24
- package/dist/ai/guides/migration/v3-beta-css-classes.md +18 -3
- package/dist/ai/guides/migration/v3-beta-tooling.md +1 -0
- package/dist/ai/guides/passthrough.md +58 -58
- package/dist/ai/helpers/inertia/manifest.json +1 -1
- package/dist/ai/index.md +1 -1
- package/dist/ai/manifest/common.json +1 -0
- package/dist/ai/manifest/components/BbAvatar.json +5 -2
- package/dist/ai/manifest/components/BbAvatar.tree.json +32 -2
- package/dist/ai/manifest/components/BbCarousel.json +0 -3
- package/dist/ai/manifest/components/BbCheckboxGroup.json +2 -2
- package/dist/ai/manifest/components/BbCheckboxGroup.tree.json +2 -0
- package/dist/ai/manifest/components/BbColorInput.json +5 -2
- package/dist/ai/manifest/components/BbColorPalette.json +5 -2
- package/dist/ai/manifest/components/BbColorPalette.removed.json +1 -2
- package/dist/ai/manifest/components/BbDatePicker.json +3 -0
- package/dist/ai/manifest/components/BbDatePickerInput.json +3 -0
- package/dist/ai/manifest/components/BbDialog.tree.json +3 -1
- package/dist/ai/manifest/components/BbDropdown.json +36 -28
- package/dist/ai/manifest/components/BbDropdown.removed.json +2 -1
- package/dist/ai/manifest/components/BbDropdown.tree.json +21 -11
- package/dist/ai/manifest/components/BbDropdownButton.json +24 -16
- package/dist/ai/manifest/components/BbDropdownButton.removed.json +2 -1
- package/dist/ai/manifest/components/BbDropdownButton.tree.json +4 -0
- package/dist/ai/manifest/components/BbGallery.tree.json +1 -1
- package/dist/ai/manifest/components/BbOffCanvas.tree.json +3 -1
- package/dist/ai/manifest/components/BbRadioGroup.json +2 -2
- package/dist/ai/manifest/components/BbRadioGroup.tree.json +2 -0
- package/dist/ai/manifest/components/BbSelect.json +47 -40
- package/dist/ai/manifest/components/BbSelect.tree.json +2 -1
- package/dist/ai/manifest/components/BbSelectPopover.json +14 -7
- package/dist/ai/manifest/components/BbSelectPopover.tree.json +9 -2
- package/dist/ai/manifest/components/BbSwitchGroup.json +2 -2
- package/dist/ai/manifest/components/BbSwitchGroup.tree.json +2 -0
- package/dist/ai/manifest/components/BbTable.json +6 -6
- package/dist/ai/manifest/components/BbTable.tree.json +9 -1
- package/dist/ai/manifest/components/BbTimePicker.json +5 -2
- package/dist/ai/manifest/components/BbTimePickerInput.json +5 -2
- package/dist/ai/manifest/components/BbTree.json +1 -1
- package/dist/ai/manifest/components/CommonPopover.json +1 -0
- package/dist/ai/manifest/components/FlatListBox.json +2 -1
- package/dist/ai/manifest/components/GroupedListBox.json +3 -2
- package/dist/ai/manifest/components/GroupedListBox.tree.json +1 -0
- package/dist/ai/manifest/components/ListBox.json +3 -2
- package/dist/ai/manifest/components/ListBox.tree.json +1 -1
- package/dist/ai/manifest/components/OptionsContainer.json +6 -4
- package/dist/ai/manifest/index.json +2 -2
- package/dist/ai/manifest/meta.json +0 -3
- package/dist/ai/manifest/types.advanced.json +6 -6
- package/dist/ai/manifest/types.api.json +1 -3
- package/dist/ai/recipes/inertia/inline-edit-workspace.md +1 -1
- package/dist/ai/recipes/inertia/onboarding.md +1 -1
- package/dist/ai/recipes/nuxt/inline-edit-workspace.md +1 -1
- package/dist/ai/recipes/nuxt/onboarding.md +1 -1
- package/dist/ai/recipes/vue/inline-edit-workspace.md +1 -1
- package/dist/ai/recipes/vue/onboarding.md +2 -2
- package/dist/ai/source/BbAccordion.md +4 -5
- package/dist/ai/source/BbAvatar.md +128 -11
- package/dist/ai/source/BbBadge.md +18 -7
- package/dist/ai/source/BbBreadcrumbs.md +57 -56
- package/dist/ai/source/BbButton.md +41 -25
- package/dist/ai/source/BbCalendar.md +8 -6
- package/dist/ai/source/BbCarousel.md +41 -34
- package/dist/ai/source/BbCheckboxGroup.md +15 -9
- package/dist/ai/source/BbColorInput.md +19 -0
- package/dist/ai/source/BbColorPalette.md +23 -2
- package/dist/ai/source/BbDatePicker.md +18 -0
- package/dist/ai/source/BbDatePickerInput.md +47 -3
- package/dist/ai/source/BbDialog.md +14 -1
- package/dist/ai/source/BbDropdown.md +296 -99
- package/dist/ai/source/BbDropdownButton.md +61 -19
- package/dist/ai/source/BbDropdownGroup.md +189 -98
- package/dist/ai/source/BbGallery.md +82 -60
- package/dist/ai/source/BbHost.md +12 -0
- package/dist/ai/source/BbNumberInput.md +17 -10
- package/dist/ai/source/BbOffCanvas.md +14 -1
- package/dist/ai/source/BbPagination.md +12 -28
- package/dist/ai/source/BbRadioGroup.md +12 -5
- package/dist/ai/source/BbRating.md +4 -4
- package/dist/ai/source/BbSelect.md +151 -112
- package/dist/ai/source/BbSelectPopover.md +244 -29
- package/dist/ai/source/BbSwitchGroup.md +11 -4
- package/dist/ai/source/BbTable.md +114 -35
- package/dist/ai/source/BbTimePicker.md +19 -0
- package/dist/ai/source/BbTimePickerInput.md +21 -2
- package/dist/ai/source/BbToast.md +2 -2
- package/dist/ai/source/BbToastPortal.md +2 -2
- package/dist/ai/source/BbTree.md +1 -1
- package/dist/ai/source/ClearableButton.md +4 -2
- package/dist/ai/source/CommonPopover.md +24 -1
- package/dist/ai/source/ErrorIcon.md +4 -3
- package/dist/ai/source/FlatListBox.md +33 -7
- package/dist/ai/source/GroupedListBox.md +85 -14
- package/dist/ai/source/ListBox.md +11 -1
- package/dist/ai/source/OptionsContainer.md +29 -11
- package/dist/ai/source/WarningIcon.md +4 -3
- package/dist/assets/svgs/close.svg_raw.js +1 -1
- package/dist/components/BbAccordion/BbAccordion.vue.d.ts +1 -1
- package/dist/components/BbAccordion/BbAccordion.vue_vue_type_script_setup_true_lang.js +35 -34
- package/dist/components/BbAvatar/BbAvatar.vue.d.ts +1 -0
- package/dist/components/BbAvatar/BbAvatar.vue_vue_type_script_setup_true_lang.js +62 -43
- package/dist/components/BbAvatar/avatarIdentity.js +25 -0
- package/dist/components/BbAvatar/ptKeys.generated.d.ts +5 -1
- package/dist/components/BbAvatar/types.d.ts +24 -5
- package/dist/components/BbAvatar/types.js +5 -1
- package/dist/components/BbBadge/BadgeBodyContent.vue_vue_type_script_setup_true_lang.js +24 -23
- package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +66 -64
- package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue_vue_type_script_setup_true_lang.js +141 -146
- package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +100 -85
- package/dist/components/BbCalendar/BbCalendar.vue.d.ts +1 -1
- package/dist/components/BbCalendar/BbCalendar.vue_vue_type_script_setup_true_lang.js +240 -239
- package/dist/components/BbCalendar/useDayGrid.js +120 -123
- package/dist/components/BbCarousel/BbCarousel.vue_vue_type_script_setup_true_lang.js +503 -502
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.d.ts +4 -4
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +126 -122
- package/dist/components/BbCheckboxGroup/types.d.ts +7 -11
- package/dist/components/BbColorInput/BbColorInput.vue.d.ts +2 -0
- package/dist/components/BbColorInput/BbColorInput.vue_vue_type_script_setup_true_lang.js +148 -141
- package/dist/components/BbColorInput/types.d.ts +7 -0
- package/dist/components/BbColorPalette/BbColorPalette.vue.d.ts +2 -0
- package/dist/components/BbColorPalette/BbColorPalette.vue_vue_type_script_setup_true_lang.js +208 -196
- package/dist/components/BbColorPalette/types.d.ts +7 -0
- package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +3 -1
- package/dist/components/BbDatePicker/BbDatePicker.vue_vue_type_script_setup_true_lang.js +84 -73
- package/dist/components/BbDatePicker/types.d.ts +7 -0
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +4 -2
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +496 -510
- package/dist/components/BbDatePickerInput/types.d.ts +7 -0
- package/dist/components/BbDialog/BbDialog.vue_vue_type_script_setup_true_lang.js +219 -211
- package/dist/components/BbDialog/leaveGhost.js +22 -17
- package/dist/components/BbDropdown/AdaptiveDropdown.vue_vue_type_script_setup_true_lang.js +106 -100
- package/dist/components/BbDropdown/BbDropdown.vue.d.ts +3 -0
- package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +416 -369
- package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +404 -354
- package/dist/components/BbDropdown/DropdownFailures.vue.js +4 -0
- package/dist/components/BbDropdown/DropdownFailures.vue_vue_type_script_setup_true_lang.js +24 -0
- package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +117 -102
- package/dist/components/BbDropdown/DropdownRow.vue_vue_type_script_setup_true_lang.js +67 -38
- package/dist/components/BbDropdown/normalizeGroups.js +6 -2
- package/dist/components/BbDropdown/ptKeys.generated.d.ts +44 -20
- package/dist/components/BbDropdown/types.d.ts +109 -87
- package/dist/components/BbDropdown/types.js +3 -0
- package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +3 -1
- package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +101 -65
- package/dist/components/BbDropdownButton/ptKeys.generated.d.ts +153 -57
- package/dist/components/BbDropdownButton/types.d.ts +23 -10
- package/dist/components/BbDropdownButton/types.js +4 -0
- package/dist/components/BbDropzone/BbDropzone.vue.d.ts +1 -1
- package/dist/components/BbGallery/BbGallery.vue_vue_type_script_setup_true_lang.js +335 -312
- package/dist/components/BbHost/BbHost.vue_vue_type_script_setup_true_lang.js +7 -1
- package/dist/components/BbIcon/iconCache.js +1 -1
- package/dist/components/BbNumberInput/BbNumberInput.vue.d.ts +1 -1
- package/dist/components/BbNumberInput/BbNumberInput.vue_vue_type_script_setup_true_lang.js +9 -5
- package/dist/components/BbOffCanvas/BbOffCanvas.vue_vue_type_script_setup_true_lang.js +152 -144
- package/dist/components/BbPagination/BbPagination.vue.d.ts +2 -2
- package/dist/components/BbPagination/BbPagination.vue_vue_type_script_setup_true_lang.js +138 -136
- package/dist/components/BbProgress/BbProgress.vue.d.ts +1 -1
- package/dist/components/BbRadioGroup/BbRadioGroup.vue.d.ts +4 -4
- package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +108 -104
- package/dist/components/BbRadioGroup/types.d.ts +4 -7
- package/dist/components/BbRating/BbRating.vue.d.ts +1 -1
- package/dist/components/BbRating/BbRating.vue_vue_type_script_setup_true_lang.js +100 -99
- package/dist/components/BbSelect/BbSelect.vue.d.ts +32 -20
- package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +217 -196
- package/dist/components/BbSelect/ptKeys.generated.d.ts +128 -96
- package/dist/components/BbSelect/types.d.ts +110 -111
- package/dist/components/BbSelect/types.js +1 -27
- package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +8 -3
- package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +728 -653
- package/dist/components/BbSelectPopover/ptKeys.generated.d.ts +22 -10
- package/dist/components/BbSelectPopover/types.d.ts +32 -17
- package/dist/components/BbSelectPopover/types.js +3 -1
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.d.ts +1 -1
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +159 -155
- package/dist/components/BbSwitchGroup/types.d.ts +3 -6
- package/dist/components/BbTable/BbTable.vue.d.ts +2 -4
- package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +1171 -1152
- package/dist/components/BbTable/BbTableDataRow.js +97 -90
- package/dist/components/BbTable/types.d.ts +11 -10
- package/dist/components/BbTabs/BbTabs.vue.d.ts +3 -3
- package/dist/components/BbTimePicker/BbTimePicker.vue.d.ts +4 -2
- package/dist/components/BbTimePicker/BbTimePicker.vue_vue_type_script_setup_true_lang.js +145 -134
- package/dist/components/BbTimePicker/types.d.ts +7 -0
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue.d.ts +4 -2
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +290 -280
- package/dist/components/BbTimePickerInput/types.d.ts +7 -0
- package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +79 -78
- package/dist/components/BbToast/types.d.ts +2 -2
- package/dist/components/BbTree/BbTreeLevel.vue_vue_type_script_setup_true_lang.js +56 -46
- package/dist/components/BbTree/types.d.ts +1 -1
- package/dist/components/ClearableButton/ClearableButton.vue_vue_type_script_setup_true_lang.js +9 -8
- package/dist/components/CloseIcon/CloseButton.vue.js +1 -1
- package/dist/components/CloseIcon/CloseButton.vue_vue_type_script_setup_true_lang.js +9 -7
- package/dist/components/CommonPopover/CommonPopover.vue_vue_type_script_setup_true_lang.js +13 -1
- package/dist/components/ErrorIcon/ErrorIcon.vue_vue_type_script_setup_true_lang.js +8 -6
- package/dist/components/FlatListBox/FlatListBox.vue_vue_type_script_setup_true_lang.js +122 -102
- package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js +182 -153
- package/dist/components/ListBox/ListBox.vue_vue_type_script_setup_true_lang.js +7 -4
- package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js +86 -77
- package/dist/components/WarningIcon/WarningIcon.vue_vue_type_script_setup_true_lang.js +8 -6
- package/dist/composables/useInternalIcon.js +25 -0
- package/dist/composables/useItemsGetter.js +34 -32
- package/dist/composables/useOpenModel.js +20 -0
- package/dist/deprecation/ai-deprecations.json.js +1 -1
- package/dist/i18n/locales/ar.json +2 -0
- package/dist/i18n/locales/cs.json +2 -0
- package/dist/i18n/locales/da.json +2 -0
- package/dist/i18n/locales/de-CH.json +2 -0
- package/dist/i18n/locales/de.json +2 -0
- package/dist/i18n/locales/el.json +2 -0
- package/dist/i18n/locales/en-GB.json +2 -0
- package/dist/i18n/locales/en.json +2 -0
- package/dist/i18n/locales/es-MX.json +2 -0
- package/dist/i18n/locales/es.json +2 -0
- package/dist/i18n/locales/fa.json +2 -0
- package/dist/i18n/locales/fi.json +2 -0
- package/dist/i18n/locales/fr.json +2 -0
- package/dist/i18n/locales/he.json +2 -0
- package/dist/i18n/locales/hu.json +2 -0
- package/dist/i18n/locales/it.json +2 -0
- package/dist/i18n/locales/ja.json +2 -0
- package/dist/i18n/locales/ko.json +2 -0
- package/dist/i18n/locales/nb.json +2 -0
- package/dist/i18n/locales/nl.json +2 -0
- package/dist/i18n/locales/pl.json +2 -0
- package/dist/i18n/locales/pt-BR.json +2 -0
- package/dist/i18n/locales/pt-PT.json +2 -0
- package/dist/i18n/locales/ro.json +2 -0
- package/dist/i18n/locales/ru.json +2 -0
- package/dist/i18n/locales/sv.json +2 -0
- package/dist/i18n/locales/tr.json +2 -0
- package/dist/i18n/locales/uk.json +2 -0
- package/dist/i18n/locales/zh-CN.json +2 -0
- package/dist/i18n/locales/zh-HK.json +2 -0
- package/dist/i18n/locales/zh-TW.json +2 -0
- package/dist/icon-scan.d.ts +1 -1
- package/dist/icon-scan.js +68 -61
- package/dist/index.d.ts +2 -2
- package/dist/llms-full.txt +1038 -451
- package/dist/llms-medium.txt +33 -28
- package/dist/llms.txt +2 -2
- package/dist/locale-blueprint.json +2 -0
- package/dist/nuxt.js +1 -1
- package/dist/styles.css +2 -2
- package/dist/types/ActionButton.d.ts +2 -3
- package/dist/types/Config.d.ts +8 -1
- package/dist/types/ConfigDefaults.d.ts +10 -2
- package/dist/types/Option.d.ts +10 -0
- package/dist/types/internalIcons.d.ts +89 -0
- package/dist/types/internalIcons.js +158 -0
- package/dist/types/ptComponentMap.d.ts +5 -5
- package/dist/utilities/functions/slotContent.js +19 -0
- package/dist/utils/configDefaults.js +75 -64
- package/dist/utils/iconsOption.js +48 -0
- package/dist/utils/loadRetry.js +8 -0
- package/dist/utils/versionCheck.js +1 -1
- package/dist/vite-plugin.d.ts +10 -16
- package/dist/vite.js +323 -307
- package/llms.txt +2 -2
- package/package.json +3 -1
- package/scripts/README.md +2 -0
- package/scripts/lib/adoption-checklist.json +1 -1
- package/scripts/lib/agent-setup.mjs +44 -26
- package/scripts/lib/update-install.mjs +48 -0
- package/scripts/lib/validate-bb-markup.mjs +93 -12
- package/dist/ai/manifest/components/BbAvatar.removed.json +0 -6
- package/dist/assets/svgs/caret_down.svg_raw.js +0 -3
|
@@ -498,8 +498,9 @@ style and attributes — optionally only while a state is on. Parts: `root`
|
|
|
498
498
|
(the group), `main` and `toggle` (the two halves, each handed to its button as
|
|
499
499
|
its `pt:root`), `icon`, `spinner` and `text` (the main button's — handed to it
|
|
500
500
|
as its own `pt`; the toggle's chevron is chrome), `panel` (the menu), `sheet` (the bottom sheet
|
|
501
|
-
the menu becomes on a phone, only), `input` (every `searchable`
|
|
502
|
-
search field), `
|
|
501
|
+
the menu becomes on a phone, only), `box` and `input` (every `searchable`
|
|
502
|
+
group's search box, and the field in it), `list` (the top-level entries
|
|
503
|
+
container), `item` (every entry), and `itemText` /
|
|
503
504
|
`itemIcon` / `itemDescription` / `check` (an entry's label, its icons, its muted
|
|
504
505
|
second line and a checked entry's tick), and `submenu` (every submenu's flyout
|
|
505
506
|
box) — all handed to the `BbDropdown` under the same words, so
|
|
@@ -596,6 +597,15 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
596
597
|
`pt` prop) is typed as `BbDropdownButtonProps['pt']`, never an imported `PtValue`: see
|
|
597
598
|
[passthrough § Typing `pt` in `<script>`](./guides/passthrough.md#typing-pt-in-script).
|
|
598
599
|
|
|
600
|
+
### Opening from code: `v-model:open`
|
|
601
|
+
|
|
602
|
+
`v-model` is the value; `v-model:open` is whether the menu is open. Bound,
|
|
603
|
+
your ref opens and closes it, and every open and close the user makes is
|
|
604
|
+
written back: a pick, Escape, a click outside. A static `:open` with no
|
|
605
|
+
listener is only the initial state. An open from code is the same open a
|
|
606
|
+
click makes (focus moves to the first row, and back on close), and `disabled` / `readonly` refuse it (the ref is set back
|
|
607
|
+
to `false`).
|
|
608
|
+
|
|
599
609
|
### Works well with
|
|
600
610
|
|
|
601
611
|
- [useConfirm](./composables/useConfirm.md) — gate a destructive alternate
|
|
@@ -635,27 +645,31 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
635
645
|
- While an async action runs, the busy half blocks re-entry automatically;
|
|
636
646
|
don't disable the other half yourself.
|
|
637
647
|
|
|
648
|
+
## v-model
|
|
649
|
+
|
|
650
|
+
- `v-model:open` — type: `boolean \| undefined`
|
|
651
|
+
|
|
638
652
|
## Props
|
|
639
653
|
|
|
640
654
|
| Prop | Type | Default | Required | Description |
|
|
641
655
|
| --- | --- | --- | --- | --- |
|
|
642
|
-
| `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: `check`, `footer`, `header`, `icon`, `input`, `item`, `itemDescription`, `itemIcon`, `itemText`, `main`, `panel`, `root`, `sheet`, `spinner`, `submenu`, `text`, `toggle`. States: `activeLink`, `
|
|
656
|
+
| `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: `box`, `check`, `footer`, `groupHeader`, `groupLabel`, `header`, `icon`, `input`, `item`, `itemDescription`, `itemIcon`, `itemText`, `list`, `main`, `panel`, `root`, `sheet`, `spinner`, `submenu`, `text`, `toggle`. States: `activeLink`, `disabled`, `exactActiveLink`, `loading`, `open`, `default`, `destructive`, `selected`, `ghost`, `link`, `outline`, `primary`, `secondary`. 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 `BbDropdownButtonProps['pt']` (`PtValue` is not exported): § Typing `pt` in `<script>`. |
|
|
643
657
|
| `activeClass` | `string \| undefined` | | | Class to apply when the link is active. |
|
|
644
|
-
| `adaptive` | `boolean \| undefined` | ``all.adaptive` (`true`)` | | On mobile (below `config.mobileMaxWidth`),
|
|
658
|
+
| `adaptive` | `boolean \| undefined` | ``all.adaptive` (`true`)` | | On mobile (below `config.mobileMaxWidth`), the menu is a bottom sheet drilling into submenus a level at a time, not hover flyouts; slots and selection unchanged. Unset: the global `all.adaptive`. |
|
|
645
659
|
| `append:icon` | `string \| undefined` | | | Icon to be added on the right of the text. |
|
|
646
660
|
| `ariaCurrentValue` | `"time" \| "true" \| "false" \| "page" \| "step" \| "location" \| "date" \| undefined` | `'page'` | | Value passed to the attribute `aria-current` when the link is exact active. |
|
|
647
661
|
| `async` | `boolean \| undefined` | `false` | | Inertia: runs the visit without blocking — the page stays interactive and several async visits can be in flight at once. |
|
|
648
662
|
| `block` | `boolean \| undefined` | `undefined` | | Displays the component as full width. |
|
|
649
663
|
| `cacheFor` | `string \| number \| (string \| number)[] \| undefined` | | | Inertia: how long a prefetched response stays fresh before it is re-fetched. A single duration, or `[staleAfter, expiresAfter]`. Typed platform-agnostically (matching BbButton) so the library's types never require `@inertiajs/vue3` to be installed. |
|
|
650
664
|
| `cacheTags` | `string \| string[] \| undefined` | | | Inertia: tags to file this visit's prefetch cache under, so a later request can invalidate the whole tagged group. |
|
|
651
|
-
| `closeOnSelect` | `boolean \| undefined` | `unset (close after a single-choice change)` | | Whether a selection closes the menu. Unset: a
|
|
652
|
-
| `compact` | `boolean \| undefined` | `false` | | Compact density, the `BbSelect` ladder: flyout rows
|
|
665
|
+
| `closeOnSelect` | `boolean \| undefined` | `unset (close after a single-choice change)` | | Whether a selection closes the menu. Unset: a single-choice group's change closes it (an untick too, any depth), a `multiple` group stays open. `true`: every change closes it; `false`: none. |
|
|
666
|
+
| `compact` | `boolean \| undefined` | `false` | | Compact density, the `BbSelect` ladder: flyout rows 28 → 24px, sheet rows 44 → 36px (still a touch target). The label size stays. |
|
|
653
667
|
| `component` | `string \| undefined` | | | Inertia: the page component this visit resolves to. Rarely set by hand — the server normally decides it. |
|
|
654
668
|
| `data` | `object \| undefined` | | | Request payload forwarded to Inertia when navigating via `href` in an Inertia-enabled app. Ignored when not using Inertia. |
|
|
655
669
|
| `disableAutoLoading` | `boolean \| undefined` | `false` | | Disables the automatic loading state that tracks async actions (enabled by default). Only affects the main action button: the split toggle half still mirrors the dropdown's internal async-action loading state. |
|
|
656
670
|
| `disabled` | `boolean \| undefined` | `false` | | Disables both halves: the main button and the menu toggle. |
|
|
657
671
|
| `download` | `string \| boolean \| undefined` | | | Marks an `href` link as a download: renders a plain `<a download>` doing a native navigation (never an Inertia/router visit), so file downloads work. Pass a string for the suggested filename. A native-anchor signal alongside `target` and `external`. |
|
|
658
|
-
| `eager` | `boolean \| undefined` | `false` | | Renders the
|
|
672
|
+
| `eager` | `boolean \| undefined` | `false` | | Renders the panel (the phone sheet's too) at mount, not on the first open, and keeps its rows after a close; otherwise rows mount on each open and go after the close. |
|
|
659
673
|
| `exactActiveClass` | `string \| undefined` | | | Class to apply when the link is exact active. |
|
|
660
674
|
| `except` | `string[] \| undefined` | | | Inertia: the inverse of `only` — properties to EXCLUDE from a partial reload. Pass one or the other, not both. |
|
|
661
675
|
| `external` | `boolean \| undefined` | `false` | | Forces an `href` link to render as a plain `<a>` (native navigation), bypassing Inertia/router interception — same intent as Nuxt's `external`. A native-anchor signal alongside `target` and `download`. |
|
|
@@ -682,6 +696,7 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
682
696
|
| `onProgress` | `((progress: { percentage: number \| undefined; }) => void) \| undefined` | | | Progress callback invoked by Inertia with the upload/download percentage when available. |
|
|
683
697
|
| `onStart` | `(() => void) \| undefined` | | | Lifecycle hook invoked by Inertia when a request starts. |
|
|
684
698
|
| `onSuccess` | `(() => void) \| undefined` | | | Lifecycle hook invoked by Inertia when a request succeeds. |
|
|
699
|
+
| `open` | `boolean \| undefined` | `false` | | Whether the panel is open (`v-model:open`; `v-model` stays the value). Bound, the app opens and closes it; unbound, the initial state. |
|
|
685
700
|
| `padding` | `number \| undefined` | `10` | | Minimum empty space to keep from the edge of the page |
|
|
686
701
|
| `pageProps` | `Record<string, unknown> \| ((currentProps: Record<string, unknown>, sharedProps: Record<string, unknown>) => Record<string, unknown>) \| null \| undefined` | | | Inertia: props to merge into the next page optimistically, before the server responds. Either an object or a function of the current props. Typed platform-agnostically (matching BbButton) so the library's types never require `@inertiajs/vue3` to be installed. |
|
|
687
702
|
| `placement` | `'start'` \| `'end'` \| `'top'` \| `'bottom'` \| `'left'` \| `'right'` \| `'top-start'` \| `'top-end'` \| `'right-start'` \| `'right-end'` \| `'bottom-start'` \| `'bottom-end'` \| `'left-start'` \| `'left-end'` \| `'start-start'` \| `'start-end'` \| `'end-start'` \| `'end-end'` \| `'cursor'` | `'bottom'` | | Position relative to the activator; `'cursor'` anchors at the mouse/touch point. No arrow (tooltips only). |
|
|
@@ -698,7 +713,7 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
698
713
|
| `text` | `string \| undefined` | | | Text content of the component. |
|
|
699
714
|
| `to` | `string \| et \| X \| undefined` | | | Route Location the link should navigate to when clicked on. |
|
|
700
715
|
| `toggle:icon` | `string \| undefined` | | | Replaces the chevron shown inside the dropdown toggle button. A constrained alternative to a slot: only the toggle's icon changes, so the button keeps its semantics. Named after the part it sits in (the `toggle`), the way `prepend:icon` / `append:icon` name theirs. |
|
|
701
|
-
| `transitionDuration` | `number \| undefined` | `150` | | The open / close transition
|
|
716
|
+
| `transitionDuration` | `number \| undefined` | `150` | | The open / close transition (ms). Menus take the fast 150, not the popovers' 250: a menu is picked from and gone, quicker than a panel you read or edit. |
|
|
702
717
|
| `type` | `"button" \| "reset" \| "submit" \| undefined` | | | Gets the classification and default behavior of the button. |
|
|
703
718
|
| `variant` | `'outline'` \| `'primary'` \| `'destructive'` \| `'secondary'` \| `'none'` \| `'ghost'` \| `'link'` | ``components.BbButton.variant`, else `'primary'`` | | Visual variant shared by both buttons of the split control. `'none'` takes no look (you own hover, focus and disabled); register a real one with the plugin's `components.BbButton.variants` and style `.bb-button--<name>`. Unset: `BbButton`'s `components` entry (the app's or a config scope's). |
|
|
704
719
|
| `viewTransition` | `boolean \| undefined` | `false` | | Inertia: run the page swap inside a View Transition, where the browser supports one. |
|
|
@@ -720,11 +735,15 @@ A `pt` value written in `<script>` (a constant, a preset, a wrapper's
|
|
|
720
735
|
| `sheet` | The bottom sheet the menu becomes on a phone only. |
|
|
721
736
|
| `header` | The band around your `#header` slot: at the top of the menu on desktop, the sheet's header on a phone — handed to the `BbDropdown`. |
|
|
722
737
|
| `footer` | The band around your `#footer` slot: at the bottom of the menu on desktop, the sheet's footer on a phone — handed to the `BbDropdown`. |
|
|
738
|
+
| `box` | A searchable group's search box in the menu (field and magnifier) — handed to the `BbDropdown` as its own `pt:box`. |
|
|
723
739
|
| `input` | A searchable group's search field in the menu — a broadcast, every searchable group's field — handed to the `BbDropdown` as its own `pt:input`. |
|
|
740
|
+
| `list` | The menu's top-level items container — handed to the `BbDropdown` as its own `pt:list`. |
|
|
741
|
+
| `groupLabel` | Every menu group's label row (the menu's own). |
|
|
742
|
+
| `groupHeader` | Every `groupBy` heading in the menu (the menu's own). |
|
|
724
743
|
| `item` | One menu entry, submenus included — a broadcast resolved per entry. Also takes a per-item function, called with the entry. |
|
|
725
744
|
| `itemText` | An entry's label (its `label`) — resolved with that entry's states. A per-entry `#<value>` slot replaces it. Also takes a per-item function. |
|
|
726
745
|
| `itemIcon` | An entry's prepend / append icons — resolved with that entry's states. Also takes a per-item function. |
|
|
727
|
-
| `itemDescription` | An entry's muted second line (its `description`)
|
|
746
|
+
| `itemDescription` | An entry's muted second line (its `description`), with the entry's states. A per-entry `#<value>` slot replaces it. Also takes a per-item function. |
|
|
728
747
|
| `check` | A checked entry's tick, outside the row slots: `pt:check="hidden"` spares your own glyph. Also takes a per-item function. |
|
|
729
748
|
| `submenu` | Every submenu's flyout box (desktop only). Also takes a per-item function, called with the entry that opens it. |
|
|
730
749
|
|
|
@@ -732,10 +751,10 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
732
751
|
|
|
733
752
|
| State | When it is on |
|
|
734
753
|
| --- | --- |
|
|
735
|
-
| `activeLink` | Component-wide while the main button
|
|
736
|
-
| `exactActiveLink` | Component-wide while the main button
|
|
754
|
+
| `activeLink` | Component-wide while the main button links to the current page or an ancestor (its `activeClass` is on); per node, on the entry parts: an entry whose link does. The weakest state. |
|
|
755
|
+
| `exactActiveLink` | Component-wide while the main button links to the current page itself (its `exactActiveClass` is on); per node, on the entry parts. |
|
|
737
756
|
| `selected` | Per node, on the entry parts only (`item`, `itemText`, `itemIcon`, `itemDescription`, `check`): a selectable group's checked entry. `pt:root:selected` is a type error, not a silent no-op. |
|
|
738
|
-
| `disabled` | Component-wide while the control is `disabled`;
|
|
757
|
+
| `disabled` | Component-wide while the control is `disabled`; per node, on the entry parts: a disabled entry. |
|
|
739
758
|
| `open` | Component-wide: the menu is open. |
|
|
740
759
|
| `loading` | Component-wide: `loading` is on — the main button shows its spinner. |
|
|
741
760
|
| `default` | Per entry, on the entry parts: an entry with `variant: 'default'` or none. Merged after the part's base entry and before its states, so the real states still win. |
|
|
@@ -754,6 +773,7 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
754
773
|
- `item:unselected` — `(value: any): void` — A row of a selectable group was unselected (same payload as above).
|
|
755
774
|
- `show` — `(): void` — Emitted as soon as the menu (the popover, or the sheet on a phone) starts to open.
|
|
756
775
|
- `shown` — `(): void` — Emitted once the menu is open and its open transition has finished.
|
|
776
|
+
- `update:open` — `(value: boolean): void` — The panel opened or closed (`v-model:open`).
|
|
757
777
|
|
|
758
778
|
## Slots
|
|
759
779
|
|
|
@@ -773,9 +793,10 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
773
793
|
- `#<groupId>:item` (named from data) — scope: `BbDropdownItemSlotProps` — The content of every row of that group, and no other; a row's own `#<value>` still wins.
|
|
774
794
|
- `#<groupId>:item:prepend` (named from data) — scope: `BbDropdownItemSlotProps` — The leading region of every row of that group — e.g. an avatar per record, drawn from `item.meta`, while other rows keep their `prepend:icon`.
|
|
775
795
|
- `#<groupId>:item:append` (named from data) — scope: `BbDropdownItemSlotProps` — The trailing region of every row of that group; replaces their `append:icon`. The check takes its place on the selected row.
|
|
776
|
-
- `#<groupId
|
|
796
|
+
- `#<groupId>:label` (named from data) — scope: `BbDropdownItemSlotProps` — That group's title content (`item` is the group, `groupTitle` is `true`).
|
|
777
797
|
- `#<groupId>:prepend` (named from data) — scope: `BbDropdownItemSlotProps` — The leading region of that group's title line.
|
|
778
798
|
- `#<groupId>:append` (named from data) — scope: `BbDropdownItemSlotProps` — The trailing region of that group's title line.
|
|
799
|
+
- `#<groupId>:group` (named from data) — scope: `BbDropdownGroupSlotProps` — That group's `groupBy` headings; beats `group`.
|
|
779
800
|
|
|
780
801
|
## Component tree
|
|
781
802
|
|
|
@@ -789,12 +810,12 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
789
810
|
- `BbDropdownButton` _(this component)_ — hands `BbButton` the pt map `{ main: 'root', icon: 'icon', spinner: 'spinner', text: 'text' }` (ours → theirs); hands `BbDropdown` the pt map `{ item: 'item', itemText: 'itemText', itemIcon: 'itemIcon', itemDescription: 'itemDescription', check: 'check' }` (ours → theirs); hands `BbButton` the pt map `{ toggle: 'root' }` (ours → theirs)
|
|
790
811
|
- `BbButton` _(public — [contract](./BbButton.md))_ — its own pt parts (`BbButton`): `root` → `BbBaseButton`, `spinner` → `BbSpinner`, `icon` → `span.bb-button__prepend-icon`, `icon` → `BbIcon`, `text` → `span.bb-button__text`, `icon` → `span.bb-button__append-icon`; documented CSS variables: `--h-xs`, `--h`, `--icon-size`, `--px`, `--ipx`, `--fs`, `--r`, `--gap`, `--bg`, `--bg-hover`, `--bg-pressed`, `--fg`, `--border-color`, `--ring-color`, `--ring-size`, `--bw`, `--fg-hover`, `--border-hover`, `--fg-pressed`, `--border-pressed`, `--bg-disabled`, `--fg-disabled`, `--border-disabled`, `--opacity-disabled`, `--elev-tier`, `--elev`; also mounts `BbSpinner`, `BbIcon`
|
|
791
812
|
- `BbBaseButton` _(public — [contract](./BbBaseButton.md))_ — its own pt parts (`BbBaseButton`): `root` → `RouterComponent`, `root` → `a`, `root` → `component`; also mounts `RouterComponent`
|
|
792
|
-
- `BbDropdown` _(public — [contract](./BbDropdown.md))_ — its own pt parts (`BbDropdown`): `panel` → `CommonPopover`, `root` → `CommonPopover`, `header` → `div.bb-dropdown__header`, `list` → `span.bb-dropdown__list`, `footer` → `div.bb-dropdown__footer`; documented CSS variables: `--menu-inset`; also mounts `CommonPopover`, `DropdownPipelineResolver`
|
|
813
|
+
- `BbDropdown` _(public — [contract](./BbDropdown.md))_ — its own pt parts (`BbDropdown`): `panel` → `CommonPopover`, `root` → `CommonPopover`, `header` → `div.bb-dropdown__header`, `list` → `span.bb-dropdown__list`, `footer` → `div.bb-dropdown__footer`; documented CSS variables: `--menu-inset`; also mounts `CommonPopover`, `DropdownFailures`, `DropdownPipelineResolver`
|
|
793
814
|
- `BbDropdownList` _(internal — not importable, reach it through `BbDropdown`)_ — also mounts `BbIcon`, `ErrorIcon`, `CommonPopover`, `BbDropdownList`
|
|
794
815
|
- `BbBadge` _(public — [contract](./BbBadge.md))_ — its own pt parts (`BbBadge`): `spinner` → `BbSpinner`, `icon` → `span.bb-badge__append-icon`, `icon` → `BbIcon`, `clear` → `button.bb-badge__clear`; documented CSS variables: `--bg`, `--fg`, `--bw`, `--ring-color`, `--ring-size`, `--min-size-md`, `--min-size`, `--elev`, `--r`, `--fs`, `--icon-size`, `--gap`, `--px`, `--clear-size`, `--bg-disabled`, `--fg-disabled`, `--border-disabled`, `--pad-left`; also mounts `BbIcon`, `BbSpinner`, `BadgeBodyContent`
|
|
795
|
-
- `AdaptiveDropdown` _(internal — not importable, reach it through `BbDropdown`)_ — hands `BbOffCanvas` the pt map `{ header: 'header', footer: 'footer', panel: 'root', sheet: 'root' }` (ours → theirs); also mounts `BbSmoothHeight`, `BbButton`, `BbDropdownList`
|
|
816
|
+
- `AdaptiveDropdown` _(internal — not importable, reach it through `BbDropdown`)_ — hands `BbOffCanvas` the pt map `{ header: 'header', footer: 'footer', panel: 'root', sheet: 'root' }` (ours → theirs); also mounts `BbSmoothHeight`, `BbButton`, `BbDropdownList`, `DropdownFailures`
|
|
796
817
|
- `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
|
|
797
|
-
- `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
|
|
818
|
+
- `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
|
|
798
819
|
|
|
799
820
|
## See Also
|
|
800
821
|
|
package/dist/ai/BbGallery.md
CHANGED
|
@@ -22,7 +22,8 @@
|
|
|
22
22
|
| --- | --- | --- | --- |
|
|
23
23
|
| `--size` | `pt:close` | `CloseButton` | the button box — the hit target, not the glyph |
|
|
24
24
|
| `--p` | `pt:close` | `CloseButton` | padding inside that box; what is left of --size is the glyph |
|
|
25
|
-
| `--icon-size` | `pt:close` | `CloseButton` | Glyph:
|
|
25
|
+
| `--icon-size` | `pt:close` | `CloseButton` | Glyph: the ✕ is drawn on a 24 grid with a stock icon's proportions (its ink spans 12 of the 24 units, as Lucide's, Tabler's and Phosphor's do), so any set's ✕ can stand in. Its box is what the padding leaves × 22/12: the ink then spans what the old edge-to-edge glyph painted, the same optical size in the same button box (the extra box overflows the padding, unpainted). Never under 10px — a tight --size with the default padding would otherwise collapse it. Declared here, not on the svg: the glyph is a BbIcon, whose own `--size` local would shadow the button's there. |
|
|
26
|
+
| `--icon-inset` | `pt:close` | `CloseButton` | Centres that larger box on the padding box (negative: it overflows it evenly). Resolved here for the same `--size` reason. |
|
|
26
27
|
|
|
27
28
|
## Usage & Guidelines
|
|
28
29
|
|
|
@@ -2026,7 +2027,7 @@ Set these on the element, or on a class you put on it, to retune this component
|
|
|
2026
2027
|
- Listed nodes are the ones `BbGallery`'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/BbGallery.tree.json` (a public component in it is a name: its own tree file has the rest).
|
|
2027
2028
|
|
|
2028
2029
|
- `BbGallery` _(this component)_ — its own template binds: `header` → `div.bb-gallery__header`, `title` → `p.bb-gallery__title`, `close` → `CloseButton`, `slide` → `figure.bb-gallery__slide`, `image` → `img.bb-gallery__image`, `prev` → `button.bb-gallery__nav`, `next` → `button.bb-gallery__nav`, `footer` → `div.bb-gallery__footer`, `caption` → `p.bb-gallery__caption`, `more` → `button.bb-gallery__more`, `counter` → `p.bb-gallery__counter`
|
|
2029
|
-
- `CloseButton` _(internal — not importable, reach it through `BbGallery`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
|
|
2030
|
+
- `CloseButton` _(internal — not importable, reach it through `BbGallery`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
|
|
2030
2031
|
- Also mounts `BbIcon`
|
|
2031
2032
|
|
|
2032
2033
|
## See Also
|
package/dist/ai/BbIcon.md
CHANGED
|
@@ -128,7 +128,7 @@ The `icon` prop takes a name in one of three forms:
|
|
|
128
128
|
ships no icon package of its own — install the ones you want. Prefer `lucide:`
|
|
129
129
|
for UI glyphs when no direction is given, so one visual language stays
|
|
130
130
|
consistent.
|
|
131
|
-
- **`local:name`** — an SVG in the configured `
|
|
131
|
+
- **`local:name`** — an SVG in the configured `icons.dir` (brand marks, custom
|
|
132
132
|
illustrations). Each `.svg` file becomes `local:<basename>`.
|
|
133
133
|
- **bare `name`** — an unprefixed name **normalizes to `local:`**; it never
|
|
134
134
|
searches provider sets. Prefer writing the prefix anyway: the Iconify editor
|
|
@@ -138,7 +138,7 @@ The `icon` prop takes a name in one of three forms:
|
|
|
138
138
|
the same shape as `mdi:home` / `lucide:check`, so the source of every icon is
|
|
139
139
|
legible without inferring it from a missing prefix.
|
|
140
140
|
|
|
141
|
-
**Split `
|
|
141
|
+
**Split `icons.dir` by kind.** Keep single-colour UI glyphs, which paint in
|
|
142
142
|
`currentColor` and follow the text around them, in `icons/ui/`, and
|
|
143
143
|
fixed-colour logos, which carry their own fills, in `icons/brand/`. The folder
|
|
144
144
|
is scanned recursively, so both are found, but a name is the file's
|
|
@@ -179,13 +179,13 @@ guess a name. See the Icons Policy for the discovery workflow and the heroicons
|
|
|
179
179
|
</div>
|
|
180
180
|
```
|
|
181
181
|
|
|
182
|
-
`local:*` is for brand art in `
|
|
182
|
+
`local:*` is for brand art in `icons.dir`. The deploy card below cycles stages
|
|
183
183
|
with full `local:` literals from that folder — the canonical brand-mark demo.
|
|
184
184
|
|
|
185
185
|
**Every `local:` name in this guide is one of _this repository's_ fixture SVGs**
|
|
186
186
|
(`clock`, `loader`, `check_circle`, `alert_circle`, …). They are illustrative,
|
|
187
187
|
not a shipped set: copy the pattern, not the names. In your project a
|
|
188
|
-
`local:` name resolves only if `<name>.svg` exists in your own `
|
|
188
|
+
`local:` name resolves only if `<name>.svg` exists in your own `icons.dir`; a
|
|
189
189
|
missing one renders the placeholder and logs which file is absent.
|
|
190
190
|
|
|
191
191
|
**Brand marks via local: — deploy stages**
|
|
@@ -221,11 +221,11 @@ type Stage = {
|
|
|
221
221
|
tone: string;
|
|
222
222
|
};
|
|
223
223
|
|
|
224
|
-
// Brand marks via `local:*` (files in
|
|
224
|
+
// Brand marks via `local:*` (files in icons.dir). Each stage owns a full static
|
|
225
225
|
// literal so the production scanner bundles it — never `local:${name}`. The
|
|
226
226
|
// glyph is decorative beside the stage label, so no `label` prop.
|
|
227
227
|
const stages: Stage[] = [
|
|
228
|
-
// `local:*` names resolve against YOUR `
|
|
228
|
+
// `local:*` names resolve against YOUR `icons.dir` — these four are this
|
|
229
229
|
// repository's fixture SVGs. Copied into another project, each one throws
|
|
230
230
|
// at mount until a `<name>.svg` of your own exists there (or swap them for
|
|
231
231
|
// `lucide:*` names, which need no files).
|
|
@@ -264,13 +264,13 @@ Provider icons ship only when the plugin can see them. It reads the **whole
|
|
|
264
264
|
project** as bytes — every file under the Vite root, PHP and JSON and SQL
|
|
265
265
|
included, minus gitignored, hidden, binary, `node_modules`/`vendor` and
|
|
266
266
|
excluded paths — for `provider:name` literals, and bundles exactly those (plus
|
|
267
|
-
`
|
|
267
|
+
`icons.whitelist`). `local:` ships everything. **Dev registers the same set**, so
|
|
268
268
|
a name assembled at runtime (`` `lucide:${kind}` ``) renders the placeholder
|
|
269
269
|
on first render in dev, not after deploy. Map dynamic state to full literals —
|
|
270
270
|
a lookup object of complete names, exactly as the deploy-stages companion does
|
|
271
271
|
(`stages[i].icon` holds `'local:clock'`, not a concatenation) — or, when the
|
|
272
272
|
name really is composed at runtime or comes from a database, list it in the
|
|
273
|
-
plugin's `
|
|
273
|
+
plugin's `icons.whitelist` (`'lucide:circle-check'`, or a glob such as
|
|
274
274
|
`'lucide:calendar-*'`). An icon used only in a `.stories.ts` / `.test.ts` file
|
|
275
275
|
is scanned like any other file.
|
|
276
276
|
|
|
@@ -283,7 +283,7 @@ const STATUS_ICON = {
|
|
|
283
283
|
failed: 'lucide:circle-x',
|
|
284
284
|
} as const;
|
|
285
285
|
// Wrong: `lucide:${status}` — never scanned; placeholder in dev AND prod
|
|
286
|
-
// (unless every value is in the plugin's `
|
|
286
|
+
// (unless every value is in the plugin's `icons.whitelist`).
|
|
287
287
|
defineProps<{ status: 'paid' | 'pending' | 'failed' }>();
|
|
288
288
|
</script>
|
|
289
289
|
|
|
@@ -378,7 +378,7 @@ deploy-stages companions both color the row wrapper; the icon tracks it.
|
|
|
378
378
|
(a setup fault — a merely missing NAME never throws, it renders the
|
|
379
379
|
placeholder).
|
|
380
380
|
Provider sets (`@iconify-json/*`) are auto-discovered from `node_modules`;
|
|
381
|
-
`local:*` comes from `
|
|
381
|
+
`local:*` comes from `icons.dir` (default `./assets/icons` on Nuxt).
|
|
382
382
|
- **SSR / Nuxt** — icons resolve during `onServerPrefetch`, so server-rendered
|
|
383
383
|
markup contains the glyph on first paint (no hydration flash). `BbIcon` carries
|
|
384
384
|
no navigation surface — it is a pure visual primitive.
|
package/dist/ai/BbNumberInput.md
CHANGED
|
@@ -220,7 +220,9 @@ settles back to `max` at once; `min` waits for blur or Enter, because the
|
|
|
220
220
|
digits of a valid number pass through smaller ones (typing `20` into a 16–28
|
|
221
221
|
field goes through `2`). Leave the field below `min`, or press Enter in it, and
|
|
222
222
|
it rises to `min` — Enter corrects it before a surrounding form submits, so
|
|
223
|
-
`@submit` never receives a value below `min
|
|
223
|
+
`@submit` never receives a value below `min`. A value your app sets past
|
|
224
|
+
either bound stays as it is while nobody touches the field; a focus and a
|
|
225
|
+
blur bring it inside the bounds, as Enter does (defaults are
|
|
224
226
|
the safe-integer bounds, i.e. effectively unbounded). `maxPrecision` caps the number of decimal places (default `8`),
|
|
225
227
|
which is how you pin a field to whole numbers (`0`); for money set `currency`,
|
|
226
228
|
which brings its own decimals. Extra decimals are refused as typed, never
|
package/dist/ai/BbOffCanvas.md
CHANGED
|
@@ -22,7 +22,8 @@
|
|
|
22
22
|
| --- | --- | --- | --- |
|
|
23
23
|
| `--size` | `pt:close` | `CloseButton` | the button box — the hit target, not the glyph |
|
|
24
24
|
| `--p` | `pt:close` | `CloseButton` | padding inside that box; what is left of --size is the glyph |
|
|
25
|
-
| `--icon-size` | `pt:close` | `CloseButton` | Glyph:
|
|
25
|
+
| `--icon-size` | `pt:close` | `CloseButton` | Glyph: the ✕ is drawn on a 24 grid with a stock icon's proportions (its ink spans 12 of the 24 units, as Lucide's, Tabler's and Phosphor's do), so any set's ✕ can stand in. Its box is what the padding leaves × 22/12: the ink then spans what the old edge-to-edge glyph painted, the same optical size in the same button box (the extra box overflows the padding, unpainted). Never under 10px — a tight --size with the default padding would otherwise collapse it. Declared here, not on the svg: the glyph is a BbIcon, whose own `--size` local would shadow the button's there. |
|
|
26
|
+
| `--icon-inset` | `pt:close` | `CloseButton` | Centres that larger box on the padding box (negative: it overflows it evenly). Resolved here for the same `--size` reason. |
|
|
26
27
|
|
|
27
28
|
## Usage & Guidelines
|
|
28
29
|
|
|
@@ -1547,7 +1548,7 @@ Set these on the element, or on a class you put on it, to retune this component
|
|
|
1547
1548
|
- Listed nodes are the ones `BbOffCanvas`'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/BbOffCanvas.tree.json` (a public component in it is a name: its own tree file has the rest).
|
|
1548
1549
|
|
|
1549
1550
|
- `BbOffCanvas` _(this component)_ — its own template binds: `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`
|
|
1550
|
-
- `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
|
|
1551
|
+
- `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
|
|
1551
1552
|
|
|
1552
1553
|
## See Also
|
|
1553
1554
|
|
package/dist/ai/BbPopover.md
CHANGED
|
@@ -965,7 +965,7 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
965
965
|
|
|
966
966
|
- `BbPopover` _(this component)_ — its own template binds: `panel` → `CommonPopover`, `root` → `CommonPopover`, `header` → `div.bb-popover__header`, `content` → `div.bb-popover__content`, `footer` → `div.bb-popover__footer`; hands `BbOffCanvas` the pt map `{ header: 'header', content: 'content', footer: 'footer', panel: 'root', sheet: 'root', }` (ours → theirs)
|
|
967
967
|
- `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
|
|
968
|
-
- `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
|
|
968
|
+
- `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
|
|
969
969
|
- Also mounts `CommonPopover`
|
|
970
970
|
|
|
971
971
|
## See Also
|
package/dist/ai/BbRadioGroup.md
CHANGED
|
@@ -566,8 +566,8 @@ Keep the set short enough that arrow-cycling stays quick; past ~6 options prefer
|
|
|
566
566
|
|
|
567
567
|
`items` accepts a provider function for options fetched from an API;
|
|
568
568
|
`loading-text` / `#loading` and `empty-text` / `#empty` cover the loading
|
|
569
|
-
and empty states, `failed-text`
|
|
570
|
-
|
|
569
|
+
and empty states, `failed-text` words the failure row of a load that threw
|
|
570
|
+
(with a built-in "Try again"; `#empty` is for empty results only), `dependencies` (+ `deps-debounce-time`) trigger re-fetches,
|
|
571
571
|
and `enforce-coherence` resets the model to `null` when the current value no
|
|
572
572
|
longer matches an available option. See the
|
|
573
573
|
[fetch-items](../../ai/guides/fetch-items-playbook.md) and
|
|
@@ -1049,7 +1049,7 @@ for a preset that fits any row type (never `<any>`), not an imported
|
|
|
1049
1049
|
| `itemLayout` | `FieldLayout \| undefined` | `'auto'` | | How each row's input and label sit together, in the `layout` keywords: `'auto'`, `'vertical'`, `'horizontal'`, `'label-fill'`, `'input-fill'`, or a two-word ratio pattern like `'xx xxxxx'`. |
|
|
1050
1050
|
| `itemProps` | `BbOptionGroupItemProps<T> \| undefined` | | | ADDITIONAL row fields, never the text or value: `description`, a muted line under the label (it may wrap; announced as the option's description). An object of paths or getters, or a function of the item; nothing is read implicitly. |
|
|
1051
1051
|
| `itemReverse` | `boolean \| undefined` | `undefined` | | Swaps each row's input and label from their natural order (input first), in every `item-layout`. `reverse` swaps the legend and the options instead. |
|
|
1052
|
-
| `items` | `T[] \| ((context: BbRadioGroupItemsContext) => T[] \| Promise<T[]>)` | | yes | The options: an array, or a provider called with a `BbRadioGroupItemsContext` (`reason`, `modelValue`, `signal`), sync or async. A provider fails by THROWING, never by returning `[]`: the rows clear and
|
|
1052
|
+
| `items` | `T[] \| ((context: BbRadioGroupItemsContext) => T[] \| Promise<T[]>)` | | yes | The options: an array, or a provider called with a `BbRadioGroupItemsContext` (`reason`, `modelValue`, `signal`), sync or async. A provider fails by THROWING, never by returning `[]`: the rows clear and the failure row shows `failed-text` with "Try again". |
|
|
1053
1053
|
| `itemText` | `ItemAccessor<T, string> \| undefined` | `own `label`, else `text`, else `JSON.stringify(item)`` | | Defines a path that returns a property of the object to use as text or a function that returns a string. Unset: own `label`, else `text` (`{ label, value }` needs no accessor). |
|
|
1054
1054
|
| `itemValue` | `ItemAccessor<T> \| undefined` | `own `value`, else the whole item` | | Defines a path that returns a property of the object to use as value or a function that returns any value. Unset: own `value`, even `null`. |
|
|
1055
1055
|
| `labelAlign` | `'center'` \| `'top'` \| `'bottom'` | | | Vertical position of the label block in a side-by-side row; not `labelPosition`, the horizontal one. Omitted, `'top'`. |
|
|
@@ -1126,7 +1126,7 @@ States are listed in precedence order: when two are on at once and their entries
|
|
|
1126
1126
|
|
|
1127
1127
|
- `append` — scope: `object` — Content rendered after the last option, inside the options container.
|
|
1128
1128
|
- `description` — scope: `BbRadioGroupDescriptionSlotProps` `{ text: string; hasErrors: boolean; hasWarnings: boolean }` — Replaces the description text. Provided alone (no `description` prop) it still renders the description region and wires it into `aria-describedby`.
|
|
1129
|
-
- `empty` — scope: `
|
|
1129
|
+
- `empty` — scope: `object` — Content shown when no options are available (replaces the default "no data" text). Empty only: a failed load shows the library's failure row instead (its message is `failed-text`, and it ends with "Try again").
|
|
1130
1130
|
- `icon` — scope: `BbRadioGroupIconSlotProps<T>` `{ disabled: boolean; readonly: boolean; checked: boolean; focused: boolean; focusVisible: boolean; id: string; name: string; hasErrors: boolean; hasWarnings: boolean; parsedValue: string; value: any; item: T; text: string }` — Replaces the default radio dot icon for each option. Receives the radio state plus the source item and its display text.
|
|
1131
1131
|
- `label` — scope: `BbRadioGroupLabelSlotProps<T>` `{ item: T; text: string; checked: boolean; description: string }` — Replaces the default label text for each option.
|
|
1132
1132
|
- `legend` — scope: `BbRadioGroupLegendSlotProps` `{ showAsterisk?: boolean; text: string; hasErrors: boolean; hasWarnings: boolean }` — Replaces the default fieldset legend text for the group.
|