bitboss-ui 3.0.0-beta.67 → 3.0.0-beta.68
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 +1 -1
- package/bin/bitboss-ui-mcp.mjs +87 -19
- package/bin/bitboss-ui.mjs +6 -2
- package/dist/ai/BbAlert.md +15 -11
- package/dist/ai/BbAsterisk.md +1 -1
- package/dist/ai/BbAvatar.md +2 -2
- package/dist/ai/BbBadge.md +4 -4
- 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 +2 -2
- package/dist/ai/BbButton.md +62 -9
- package/dist/ai/BbCalendar.md +1 -1
- package/dist/ai/BbCheckbox.md +23 -5
- package/dist/ai/BbCheckboxGroup.md +52 -25
- package/dist/ai/BbColorInput.md +13 -12
- package/dist/ai/BbColorPalette.md +5 -5
- package/dist/ai/BbConfigScope.md +218 -0
- package/dist/ai/BbConfirm.md +24 -21
- package/dist/ai/BbDatePicker.md +4 -4
- package/dist/ai/BbDatePickerInput.md +16 -15
- package/dist/ai/BbDialog.md +10 -9
- package/dist/ai/BbDropdown.md +26 -16
- package/dist/ai/BbDropdownButton.md +18 -18
- package/dist/ai/BbDropzone.md +1 -1
- package/dist/ai/BbForm.md +6 -4
- package/dist/ai/BbHost.md +19 -13
- package/dist/ai/BbIcon.md +3 -3
- package/dist/ai/BbIndicator.md +4 -4
- package/dist/ai/BbNumberInput.md +17 -13
- package/dist/ai/BbOffCanvas.md +4 -3
- package/dist/ai/BbPagination.md +10 -2
- package/dist/ai/BbPopover.md +5 -5
- package/dist/ai/BbRadio.md +23 -4
- package/dist/ai/BbRadioGroup.md +69 -30
- package/dist/ai/BbRating.md +5 -5
- package/dist/ai/BbSelect.md +74 -39
- package/dist/ai/BbSelectPopover.md +28 -26
- package/dist/ai/BbSlider.md +258 -61
- package/dist/ai/BbSpinner.md +2 -2
- package/dist/ai/BbSwitch.md +27 -4
- package/dist/ai/BbSwitchGroup.md +22 -13
- package/dist/ai/BbTable.md +10 -5
- package/dist/ai/BbTabs.md +6 -6
- package/dist/ai/BbTabsRoot.md +1 -1
- package/dist/ai/BbTag.md +12 -11
- package/dist/ai/BbTextInput.md +25 -17
- package/dist/ai/BbTextarea.md +15 -14
- package/dist/ai/BbTimePicker.md +3 -3
- package/dist/ai/BbTimePickerInput.md +12 -11
- package/dist/ai/BbToast.md +65 -26
- package/dist/ai/BbTooltip.md +2 -2
- package/dist/ai/CommonField.md +2 -2
- package/dist/ai/CommonFieldInput.md +2 -1
- package/dist/ai/FlatListBox.md +4 -3
- package/dist/ai/GroupedListBox.md +4 -3
- package/dist/ai/ListBox.md +5 -4
- package/dist/ai/OptionsContainer.md +17 -1
- package/dist/ai/changelog.json +454 -7
- package/dist/ai/components.json +77 -69
- 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 +8 -8
- package/dist/ai/guides/ai-router.md +1 -1
- package/dist/ai/guides/app-layout.md +1 -1
- package/dist/ai/guides/design-language.md +17 -13
- package/dist/ai/guides/design-tokens.md +81 -42
- package/dist/ai/guides/eslint-rules.md +3 -1
- package/dist/ai/guides/fetch-items-playbook.md +1 -1
- package/dist/ai/guides/icons-policy.md +1 -1
- package/dist/ai/guides/inline-edit-playbook.md +1 -1
- package/dist/ai/guides/installation-and-plugin-setup.md +335 -161
- 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-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-tabs.md +1 -1
- package/dist/ai/guides/migration/components/bb-toast.md +6 -6
- package/dist/ai/guides/migration/components/use-confirm.md +1 -1
- package/dist/ai/guides/migration/v2-to-v3.md +191 -56
- package/dist/ai/guides/migration/v3-beta-tooling.md +2 -2
- package/dist/ai/guides/passthrough.md +140 -131
- package/dist/ai/guides/typescript-generic-components.md +7 -7
- package/dist/ai/guides/validated-forms.md +5 -5
- package/dist/ai/guides/validation-libraries.md +4 -4
- package/dist/ai/helpers/inertia/manifest.json +1 -1
- package/dist/ai/index.md +3 -3
- package/dist/ai/manifest/common.json +9 -11
- package/dist/ai/manifest/components/BbAlert.json +3 -2
- package/dist/ai/manifest/components/BbAvatar.json +2 -1
- package/dist/ai/manifest/components/BbBadge.json +3 -2
- package/dist/ai/manifest/components/BbBaseCheckboxIcon.tree.json +5 -1
- package/dist/ai/manifest/components/BbBaseRadioIcon.tree.json +7 -3
- package/dist/ai/manifest/components/BbBaseSwitchIcon.tree.json +9 -1
- package/dist/ai/manifest/components/BbBreadcrumbs.tree.json +1 -1
- package/dist/ai/manifest/components/BbButton.json +4 -3
- package/dist/ai/manifest/components/BbButton.tree.json +3 -1
- package/dist/ai/manifest/components/BbCalendar.tree.json +1 -0
- package/dist/ai/manifest/components/BbCheckbox.json +4 -3
- package/dist/ai/manifest/components/BbCheckbox.tree.json +1 -1
- package/dist/ai/manifest/components/BbCheckboxGroup.json +17 -14
- package/dist/ai/manifest/components/BbCheckboxGroup.removed.json +1 -1
- package/dist/ai/manifest/components/BbCheckboxGroup.tree.json +25 -4
- package/dist/ai/manifest/components/BbColorInput.json +6 -5
- package/dist/ai/manifest/components/BbColorInput.tree.json +4 -3
- package/dist/ai/manifest/components/BbColorPalette.json +2 -1
- package/dist/ai/manifest/components/BbColorPalette.tree.json +2 -1
- package/dist/ai/manifest/components/BbConfigScope.json +23 -0
- package/dist/ai/manifest/components/BbConfirm.json +2 -1
- package/dist/ai/manifest/components/BbConfirm.tree.json +2 -2
- package/dist/ai/manifest/components/BbDatePicker.json +2 -1
- package/dist/ai/manifest/components/BbDatePicker.tree.json +2 -2
- package/dist/ai/manifest/components/BbDatePickerInput.json +6 -5
- package/dist/ai/manifest/components/BbDatePickerInput.tree.json +6 -4
- package/dist/ai/manifest/components/BbDialog.json +3 -2
- package/dist/ai/manifest/components/BbDialog.tree.json +2 -2
- package/dist/ai/manifest/components/BbDropdown.json +7 -4
- package/dist/ai/manifest/components/BbDropdown.tree.json +1 -1
- package/dist/ai/manifest/components/BbDropdownButton.json +11 -8
- package/dist/ai/manifest/components/BbDropdownButton.tree.json +3 -3
- package/dist/ai/manifest/components/BbDropzone.json +1 -0
- package/dist/ai/manifest/components/BbForm.json +1 -1
- package/dist/ai/manifest/components/BbHost.tree.json +1 -1
- package/dist/ai/manifest/components/BbIcon.json +2 -1
- package/dist/ai/manifest/components/BbIndicator.json +2 -1
- package/dist/ai/manifest/components/BbNumberInput.json +5 -4
- package/dist/ai/manifest/components/BbNumberInput.tree.json +3 -2
- package/dist/ai/manifest/components/BbOffCanvas.json +2 -1
- package/dist/ai/manifest/components/BbOffCanvas.tree.json +1 -1
- package/dist/ai/manifest/components/BbPagination.json +1 -1
- package/dist/ai/manifest/components/BbPagination.tree.json +2 -1
- package/dist/ai/manifest/components/BbPopover.json +2 -1
- package/dist/ai/manifest/components/BbPopover.tree.json +1 -1
- package/dist/ai/manifest/components/BbRadio.json +3 -2
- package/dist/ai/manifest/components/BbRadio.tree.json +1 -1
- package/dist/ai/manifest/components/BbRadioGroup.json +21 -18
- package/dist/ai/manifest/components/BbRadioGroup.removed.json +1 -1
- package/dist/ai/manifest/components/BbRadioGroup.tree.json +25 -4
- package/dist/ai/manifest/components/BbRating.json +3 -2
- package/dist/ai/manifest/components/BbSelect.json +11 -9
- package/dist/ai/manifest/components/BbSelect.tree.json +7 -5
- package/dist/ai/manifest/components/BbSelectPopover.json +11 -9
- package/dist/ai/manifest/components/BbSelectPopover.tree.json +5 -2
- package/dist/ai/manifest/components/BbSlider.json +20 -18
- package/dist/ai/manifest/components/BbSlider.removed.json +3 -0
- package/dist/ai/manifest/components/BbSlider.tree.json +4 -2
- package/dist/ai/manifest/components/BbSwitch.json +2 -1
- package/dist/ai/manifest/components/BbSwitch.tree.json +1 -1
- package/dist/ai/manifest/components/BbSwitchGroup.json +7 -5
- package/dist/ai/manifest/components/BbSwitchGroup.removed.json +1 -1
- package/dist/ai/manifest/components/BbSwitchGroup.tree.json +6 -2
- package/dist/ai/manifest/components/BbTable.json +3 -2
- package/dist/ai/manifest/components/BbTable.tree.json +4 -3
- package/dist/ai/manifest/components/BbTabs.json +3 -2
- package/dist/ai/manifest/components/BbTabsRoot.json +2 -2
- package/dist/ai/manifest/components/BbTag.json +6 -5
- package/dist/ai/manifest/components/BbTag.tree.json +3 -2
- package/dist/ai/manifest/components/BbTextInput.json +5 -4
- package/dist/ai/manifest/components/BbTextInput.tree.json +3 -2
- package/dist/ai/manifest/components/BbTextarea.json +6 -5
- package/dist/ai/manifest/components/BbTextarea.tree.json +3 -2
- package/dist/ai/manifest/components/BbTimePicker.json +2 -1
- package/dist/ai/manifest/components/BbTimePicker.tree.json +1 -1
- package/dist/ai/manifest/components/BbTimePickerInput.json +6 -5
- package/dist/ai/manifest/components/BbTimePickerInput.tree.json +5 -3
- package/dist/ai/manifest/components/BbToast.json +2 -1
- package/dist/ai/manifest/components/BbToast.tree.json +6 -1
- package/dist/ai/manifest/components/BbTooltip.json +1 -0
- package/dist/ai/manifest/components/CommonField.json +2 -2
- package/dist/ai/manifest/components/CommonFieldInput.json +2 -2
- package/dist/ai/manifest/components/CommonFieldInput.tree.json +2 -0
- package/dist/ai/manifest/components/FlatListBox.json +1 -1
- package/dist/ai/manifest/components/FlatListBox.tree.json +2 -1
- package/dist/ai/manifest/components/GroupedListBox.json +1 -1
- package/dist/ai/manifest/components/GroupedListBox.tree.json +2 -1
- 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 +3 -2
- package/dist/ai/manifest/components/OptionsContainer.tree.json +16 -1
- package/dist/ai/manifest/index.json +3 -3
- package/dist/ai/manifest/meta.json +16 -7
- package/dist/ai/manifest/types.advanced.json +5 -6
- package/dist/ai/manifest/types.api.json +15 -6
- package/dist/ai/manifest/types.wrapper.json +2 -2
- package/dist/ai/recipes/inertia/approvals-inbox.md +2 -2
- package/dist/ai/recipes/inertia/inline-edit-workspace.md +13 -9
- package/dist/ai/recipes/inertia/onboarding.md +2 -2
- package/dist/ai/recipes/inertia/ownership-atlas.md +2 -2
- package/dist/ai/recipes/inertia/record-form.md +2 -2
- package/dist/ai/recipes/inertia/records-workspace.md +2 -2
- package/dist/ai/recipes/inertia/settings-workspace.md +5 -4
- package/dist/ai/recipes/inertia/upload-center.md +3 -3
- package/dist/ai/recipes/inertia/wizard-form.md +2 -2
- package/dist/ai/recipes/nuxt/approvals-inbox.md +2 -2
- package/dist/ai/recipes/nuxt/inline-edit-workspace.md +13 -9
- package/dist/ai/recipes/nuxt/onboarding.md +2 -2
- package/dist/ai/recipes/nuxt/ownership-atlas.md +2 -2
- package/dist/ai/recipes/nuxt/record-form.md +2 -2
- package/dist/ai/recipes/nuxt/records-workspace.md +2 -2
- package/dist/ai/recipes/nuxt/settings-workspace.md +5 -4
- package/dist/ai/recipes/nuxt/upload-center.md +4 -4
- package/dist/ai/recipes/nuxt/wizard-form.md +2 -2
- package/dist/ai/recipes/vue/approvals-inbox.md +2 -2
- package/dist/ai/recipes/vue/inline-edit-workspace.md +13 -9
- package/dist/ai/recipes/vue/onboarding.md +2 -2
- package/dist/ai/recipes/vue/ownership-atlas.md +2 -2
- package/dist/ai/recipes/vue/record-form.md +2 -2
- package/dist/ai/recipes/vue/records-workspace.md +2 -2
- package/dist/ai/recipes/vue/settings-workspace.md +5 -4
- package/dist/ai/recipes/vue/upload-center.md +4 -4
- package/dist/ai/recipes/vue/wizard-form.md +2 -2
- package/dist/ai/source/BbAlert.md +10 -4
- package/dist/ai/source/BbAvatar.md +5 -4
- package/dist/ai/source/BbBadge.md +16 -9
- package/dist/ai/source/BbBadgeButton.md +1 -1
- package/dist/ai/source/BbBaseCheckboxIcon.md +7 -5
- package/dist/ai/source/BbBaseRadioIcon.md +17 -11
- package/dist/ai/source/BbBaseSwitchIcon.md +14 -9
- package/dist/ai/source/BbButton.md +38 -22
- package/dist/ai/source/BbCalendar.md +5 -30
- package/dist/ai/source/BbCheckbox.md +20 -7
- package/dist/ai/source/BbCheckboxGroup.md +66 -27
- package/dist/ai/source/BbColorInput.md +29 -22
- package/dist/ai/source/BbColorPalette.md +23 -22
- package/dist/ai/source/BbConfigScope.md +123 -0
- package/dist/ai/source/BbConfirm.md +5 -3
- package/dist/ai/source/BbDatePicker.md +18 -8
- package/dist/ai/source/BbDatePickerInput.md +44 -27
- package/dist/ai/source/BbDialog.md +23 -13
- package/dist/ai/source/BbDropdown.md +61 -25
- package/dist/ai/source/BbDropdownButton.md +67 -25
- package/dist/ai/source/BbDropdownGroup.md +38 -15
- package/dist/ai/source/BbForm.md +1 -1
- package/dist/ai/source/BbHost.md +4 -4
- package/dist/ai/source/BbHoverCard.md +6 -2
- package/dist/ai/source/BbIcon.md +5 -4
- package/dist/ai/source/BbIndicator.md +1 -1
- package/dist/ai/source/BbNumberInput.md +44 -30
- package/dist/ai/source/BbOffCanvas.md +17 -10
- package/dist/ai/source/BbPagination.md +10 -18
- package/dist/ai/source/BbPopover.md +17 -9
- package/dist/ai/source/BbPopoverPortal.md +2 -2
- package/dist/ai/source/BbRadio.md +18 -7
- package/dist/ai/source/BbRadioGroup.md +67 -27
- package/dist/ai/source/BbRating.md +21 -11
- package/dist/ai/source/BbSelect.md +51 -32
- package/dist/ai/source/BbSelectPopover.md +81 -38
- package/dist/ai/source/BbSlider.md +929 -565
- package/dist/ai/source/BbSwitchGroup.md +28 -9
- package/dist/ai/source/BbTable.md +17 -30
- package/dist/ai/source/BbTabs.md +5 -2
- package/dist/ai/source/BbTabsList.md +1 -1
- package/dist/ai/source/BbTabsPanels.md +1 -1
- package/dist/ai/source/BbTabsRoot.md +1 -1
- package/dist/ai/source/BbTag.md +27 -20
- package/dist/ai/source/BbTextInput.md +29 -26
- package/dist/ai/source/BbTextarea.md +53 -45
- package/dist/ai/source/BbTimePicker.md +19 -7
- package/dist/ai/source/BbTimePickerInput.md +34 -21
- package/dist/ai/source/BbToast.md +18 -9
- package/dist/ai/source/BbToastPortal.md +14 -6
- package/dist/ai/source/BbTooltip.md +1 -1
- package/dist/ai/source/CommonFieldInput.md +9 -4
- package/dist/ai/source/FlatListBox.md +11 -1
- package/dist/ai/source/GroupedListBox.md +12 -1
- package/dist/ai/source/ListBox.md +1 -1
- package/dist/ai/source/OptionsContainer.md +48 -1
- 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_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/x.svg_raw.js +3 -0
- package/dist/components/BbAlert/BbAlert.vue.d.ts +1 -0
- package/dist/components/BbAlert/BbAlert.vue_vue_type_script_setup_true_lang.js +48 -44
- package/dist/components/BbAlert/types.d.ts +1 -1
- package/dist/components/BbAvatar/BbAvatar.vue.d.ts +1 -1
- package/dist/components/BbAvatar/BbAvatar.vue_vue_type_script_setup_true_lang.js +54 -53
- package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +60 -56
- package/dist/components/BbBadge/types.d.ts +1 -1
- package/dist/components/BbButton/BbButton.vue.d.ts +2 -0
- package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +110 -98
- package/dist/components/BbButton/types.d.ts +12 -10
- package/dist/components/BbCalendar/BbCalendar.vue.d.ts +17 -17
- package/dist/components/BbCalendar/BbCalendar.vue_vue_type_script_setup_true_lang.js +298 -313
- package/dist/components/BbCalendar/useCalendarGrid.js +3 -2
- package/dist/components/BbCheckbox/BbCheckbox.vue.d.ts +4 -2
- package/dist/components/BbCheckbox/BbCheckbox.vue_vue_type_script_setup_true_lang.js +94 -82
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.d.ts +78 -55
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +184 -151
- package/dist/components/BbCheckboxGroup/types.d.ts +10 -5
- package/dist/components/BbCollapsible/BbCollapsible.vue.d.ts +1 -1
- package/dist/components/BbColorInput/BbColorInput.vue.d.ts +13 -11
- package/dist/components/BbColorInput/BbColorInput.vue_vue_type_script_setup_true_lang.js +82 -71
- package/dist/components/BbColorInput/types.d.ts +8 -8
- package/dist/components/BbColorInput/types.js +1 -1
- package/dist/components/BbColorPalette/BbColorPalette.vue.d.ts +2 -2
- package/dist/components/BbColorPalette/BbColorPalette.vue_vue_type_script_setup_true_lang.js +180 -182
- package/dist/components/BbColorPalette/types.d.ts +2 -2
- 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_vue_type_script_setup_true_lang.js +3 -3
- package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +31 -31
- package/dist/components/BbDatePicker/BbDatePicker.vue_vue_type_script_setup_true_lang.js +171 -170
- package/dist/components/BbDatePicker/types.d.ts +2 -2
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +110 -110
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +457 -441
- package/dist/components/BbDatePickerInput/types.d.ts +8 -8
- package/dist/components/BbDatePickerInput/types.js +1 -1
- package/dist/components/BbDialog/BbDialog.vue.d.ts +4 -3
- package/dist/components/BbDialog/BbDialog.vue_vue_type_script_setup_true_lang.js +204 -197
- package/dist/components/BbDialog/types.d.ts +2 -2
- package/dist/components/BbDropdown/BbDropdown.vue.d.ts +5 -4
- package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +302 -286
- package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +348 -344
- package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +97 -97
- package/dist/components/BbDropdown/DropdownRow.vue.d.ts +1 -1
- package/dist/components/BbDropdown/DropdownRow.vue_vue_type_script_setup_true_lang.js +2 -2
- package/dist/components/BbDropdown/pointerTrail.d.ts +5 -0
- package/dist/components/BbDropdown/pointerTrail.js +26 -0
- package/dist/components/BbDropdown/types.d.ts +25 -13
- package/dist/components/BbDropdown/types.js +11 -2
- package/dist/components/BbDropdown/useDropdownContext.d.ts +1 -1
- package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +4 -3
- package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +93 -69
- package/dist/components/BbDropdownButton/types.d.ts +30 -13
- package/dist/components/BbDropdownButton/types.js +7 -3
- package/dist/components/BbDropzone/BbDropzone.vue.d.ts +5 -5
- package/dist/components/BbForm/BbForm.vue.d.ts +2 -2
- package/dist/components/BbForm/BbFormCustomField.js +2 -2
- package/dist/components/BbForm/bindFormField.js +66 -66
- package/dist/components/BbHost/BbHost.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/BbHost/BbHostOpening.d.ts +1 -1
- package/dist/components/BbHost/types.d.ts +2 -2
- package/dist/components/BbHoverCard/BbHoverCard.vue.d.ts +2 -2
- package/dist/components/BbHoverCard/BbHoverCard.vue_vue_type_script_setup_true_lang.js +158 -157
- package/dist/components/BbIcon/BbIcon.vue.d.ts +1 -1
- package/dist/components/BbIcon/BbIcon.vue_vue_type_script_setup_true_lang.js +41 -40
- package/dist/components/BbIndicator/types.d.ts +1 -1
- package/dist/components/BbNumberInput/BbNumberInput.vue.d.ts +12 -9
- package/dist/components/BbNumberInput/BbNumberInput.vue_vue_type_script_setup_true_lang.js +248 -232
- package/dist/components/BbNumberInput/types.d.ts +12 -11
- package/dist/components/BbNumberInput/types.js +1 -1
- package/dist/components/BbOffCanvas/BbOffCanvas.vue.d.ts +2 -2
- package/dist/components/BbOffCanvas/BbOffCanvas.vue_vue_type_script_setup_true_lang.js +275 -274
- package/dist/components/BbPagination/BbPagination.vue.d.ts +1 -1
- package/dist/components/BbPagination/BbPagination.vue_vue_type_script_setup_true_lang.js +104 -108
- package/dist/components/BbPopover/BbPopover.vue.d.ts +2 -2
- package/dist/components/BbPopover/BbPopover.vue_vue_type_script_setup_true_lang.js +90 -90
- package/dist/components/BbPopover/types.d.ts +2 -2
- package/dist/components/BbRadio/BbRadio.vue.d.ts +4 -2
- package/dist/components/BbRadio/BbRadio.vue_vue_type_script_setup_true_lang.js +105 -93
- package/dist/components/BbRadioGroup/BbRadioGroup.vue.d.ts +72 -49
- package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +214 -181
- package/dist/components/BbRadioGroup/types.d.ts +11 -5
- package/dist/components/BbRating/BbRating.vue.d.ts +7 -5
- package/dist/components/BbRating/BbRating.vue_vue_type_script_setup_true_lang.js +139 -128
- package/dist/components/BbSelect/BbSelect.vue.d.ts +174 -155
- package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +179 -158
- package/dist/components/BbSelect/types.d.ts +23 -19
- package/dist/components/BbSelect/types.js +4 -2
- package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +21 -16
- package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +637 -623
- package/dist/components/BbSelectPopover/reclickClears.d.ts +17 -0
- package/dist/components/BbSelectPopover/reclickClears.js +4 -0
- package/dist/components/BbSelectPopover/types.d.ts +21 -16
- package/dist/components/BbSelectPopover/types.js +3 -1
- package/dist/components/BbSlider/BbSlider.vue.d.ts +22 -15
- package/dist/components/BbSlider/BbSlider.vue_vue_type_script_setup_true_lang.js +382 -315
- package/dist/components/BbSlider/types.d.ts +136 -47
- package/dist/components/BbSwitch/BbSwitch.vue.d.ts +2 -2
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.d.ts +28 -27
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +3 -0
- package/dist/components/BbTable/BbTable.vue.d.ts +4 -4
- package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +1128 -1135
- package/dist/components/BbTable/BbTableSelectToggle.d.ts +1 -1
- package/dist/components/BbTabs/BbTabs.vue.d.ts +21 -21
- package/dist/components/BbTabs/BbTabs.vue_vue_type_script_setup_true_lang.js +8 -2
- package/dist/components/BbTabs/types.d.ts +1 -1
- package/dist/components/BbTag/BbTag.vue.d.ts +15 -13
- package/dist/components/BbTag/BbTag.vue_vue_type_script_setup_true_lang.js +196 -185
- package/dist/components/BbTag/types.d.ts +7 -7
- package/dist/components/BbTag/types.js +1 -1
- package/dist/components/BbTextInput/BbTextInput.vue.d.ts +30 -30
- package/dist/components/BbTextInput/BbTextInput.vue_vue_type_script_setup_true_lang.js +66 -55
- package/dist/components/BbTextInput/types.d.ts +9 -9
- package/dist/components/BbTextInput/types.js +1 -1
- package/dist/components/BbTextarea/BbTextarea.vue.d.ts +30 -30
- package/dist/components/BbTextarea/BbTextarea.vue_vue_type_script_setup_true_lang.js +96 -86
- package/dist/components/BbTextarea/types.d.ts +8 -8
- package/dist/components/BbTextarea/types.js +1 -1
- package/dist/components/BbTimePicker/BbTimePicker.vue.d.ts +12 -12
- package/dist/components/BbTimePicker/BbTimePicker.vue_vue_type_script_setup_true_lang.js +131 -130
- package/dist/components/BbTimePicker/types.d.ts +2 -2
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue.d.ts +73 -73
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +286 -273
- package/dist/components/BbTimePickerInput/types.d.ts +8 -8
- package/dist/components/BbTimePickerInput/types.js +1 -1
- package/dist/components/BbToast/BbToast.vue_vue_type_script_setup_true_lang.js +3 -3
- package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +75 -80
- package/dist/components/BbToast/types.d.ts +2 -2
- package/dist/components/BbTooltip/BbTooltip.vue.d.ts +3 -3
- package/dist/components/BbTooltip/types.d.ts +1 -1
- package/dist/components/BbTree/BbTree.vue.d.ts +1 -1
- 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/CommonFieldInput/types.d.ts +1 -1
- package/dist/components/FlatListBox/FlatListBox.vue_vue_type_script_setup_true_lang.js +5 -2
- package/dist/components/FlatListBox/types.d.ts +1 -1
- package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js +5 -2
- package/dist/components/GroupedListBox/types.d.ts +1 -1
- package/dist/components/ListBox/types.d.ts +1 -1
- package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js +87 -69
- package/dist/components/OptionsContainer/types.d.ts +5 -0
- package/dist/components/Transitions/Slide.vue.d.ts +1 -1
- package/dist/composables/useBbTabs.js +94 -90
- 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 +7 -7
- package/dist/composables/useFormBinding.d.ts +1 -1
- package/dist/composables/useFormBinding.js +3 -3
- package/dist/composables/usePassthrough.d.ts +7 -5
- package/dist/composables/usePassthrough.js +137 -133
- package/dist/composables/useToast.d.ts +5 -4
- package/dist/composables/useToast.js +47 -37
- package/dist/deprecation/ai-deprecations.json.d.ts +44 -15
- package/dist/deprecation/ai-deprecations.json.js +1 -1
- package/dist/directives/bbDropdown.js +7 -7
- package/dist/i18n/locales/cs.json +2 -1
- package/dist/i18n/locales/da.json +2 -1
- package/dist/i18n/locales/de-CH.json +2 -1
- package/dist/i18n/locales/de.json +2 -1
- package/dist/i18n/locales/el.json +2 -1
- package/dist/i18n/locales/en-GB.json +2 -1
- package/dist/i18n/locales/en.json +2 -1
- package/dist/i18n/locales/es-MX.json +2 -1
- package/dist/i18n/locales/es.json +2 -1
- package/dist/i18n/locales/fi.json +2 -1
- package/dist/i18n/locales/fr.json +2 -1
- package/dist/i18n/locales/hu.json +2 -1
- package/dist/i18n/locales/it.json +2 -1
- package/dist/i18n/locales/ja.json +2 -1
- package/dist/i18n/locales/ko.json +2 -1
- package/dist/i18n/locales/nb.json +2 -1
- package/dist/i18n/locales/nl.json +2 -1
- package/dist/i18n/locales/pl.json +2 -1
- package/dist/i18n/locales/pt-BR.json +2 -1
- package/dist/i18n/locales/pt-PT.json +2 -1
- package/dist/i18n/locales/ro.json +2 -1
- package/dist/i18n/locales/ru.json +2 -1
- package/dist/i18n/locales/sv.json +2 -1
- package/dist/i18n/locales/tr.json +2 -1
- package/dist/i18n/locales/uk.json +2 -1
- package/dist/i18n/locales/zh-CN.json +2 -1
- package/dist/i18n/locales/zh-HK.json +2 -1
- package/dist/i18n/locales/zh-TW.json +2 -1
- package/dist/index.d.ts +5 -5
- package/dist/index.js +2 -2
- package/dist/llms-full.txt +2273 -1243
- package/dist/llms-medium.txt +362 -184
- package/dist/llms.txt +4 -4
- package/dist/locale-blueprint.json +2 -1
- package/dist/nuxt-auto-imports.js +1 -1
- package/dist/nuxt-module.d.ts +1 -1
- package/dist/nuxt.js +17 -17
- package/dist/project-dts.d.ts +72 -10
- package/dist/project-dts.js +69 -21
- package/dist/styles.css +2 -2
- package/dist/types/AlertVariant.d.ts +1 -1
- package/dist/types/BadgeVariant.d.ts +1 -1
- package/dist/types/ButtonVariant.d.ts +1 -1
- package/dist/types/CheckboxVariant.d.ts +7 -4
- package/dist/types/CheckboxVariant.js +5 -1
- package/dist/types/Config.d.ts +17 -103
- package/dist/types/ConfigDefaults.d.ts +352 -0
- package/dist/types/ConfigDefaults.js +115 -0
- package/dist/types/ConfirmVariant.d.ts +1 -1
- package/dist/types/DropdownItemVariant.d.ts +1 -1
- package/dist/types/FieldLayout.d.ts +3 -3
- package/dist/types/IndicatorVariant.d.ts +1 -1
- package/dist/types/InputVariant.d.ts +57 -24
- package/dist/types/RadioVariant.d.ts +7 -4
- package/dist/types/RadioVariant.js +5 -1
- package/dist/types/SizeScale.d.ts +4 -0
- package/dist/types/SizeScale.js +17 -0
- package/dist/types/TabsVariant.d.ts +1 -1
- package/dist/types/ToastVariant.d.ts +1 -1
- package/dist/types/TooltipVariant.d.ts +1 -1
- package/dist/types/passthrough.d.ts +6 -6
- package/dist/types/ptComponentMap.d.ts +14 -14
- package/dist/utilities/functions/searchRank.d.ts +19 -0
- package/dist/utilities/functions/searchRank.js +76 -0
- package/dist/utilities/misc/listboxMetrics.d.ts +1 -1
- package/dist/utils/configDefaults.d.ts +33 -0
- package/dist/utils/configDefaults.js +140 -0
- package/dist/utils/configScope.d.ts +43 -0
- package/dist/utils/configScope.js +13 -0
- package/dist/utils/passthrough.d.ts +4 -7
- package/dist/utils/passthrough.js +31 -29
- package/dist/utils/versionCheck.js +1 -1
- package/dist/vite-plugin.d.ts +54 -191
- package/dist/vite.js +318 -367
- package/llms.txt +4 -4
- package/package.json +3 -3
- package/scripts/lib/adoption-checklist.json +2 -2
- package/scripts/lib/agent-manifest.mjs +2 -0
- package/scripts/lib/eslint-disable.mjs +2 -0
- package/scripts/lib/eslint-plugin.d.ts +4 -2
- package/scripts/lib/eslint-plugin.mjs +67 -0
- package/scripts/lib/idiom-scan.mjs +8 -7
- package/scripts/lib/project-variant-dts.mjs +105 -36
- package/scripts/lib/validate-bb-markup.mjs +73 -13
- 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/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/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/utils/ptScope.d.ts +0 -8
- package/dist/utils/ptScope.js +0 -3
package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { useLocale as e } from "../../composables/useLocale.js";
|
|
2
2
|
import { useId as t } from "../../composables/useId.js";
|
|
3
3
|
import { FIELD_CROSS_ALIGNS as n } from "../../types/FieldLayout.js";
|
|
4
|
-
import { Fragment as r, computed as i, createCommentVNode as a, createElementBlock as o, createElementVNode as s, createTextVNode as c, defineComponent as l, mergeProps as u, normalizeClass as d,
|
|
4
|
+
import { Fragment as r, computed as i, createCommentVNode as a, createElementBlock as o, createElementVNode as s, createTextVNode as c, defineComponent as l, mergeProps as u, normalizeClass as d, onBeforeUnmount as f, onMounted as p, openBlock as m, ref as h, renderList as g, renderSlot as _, toDisplayString as v, unref as y, watch as b } from "vue";
|
|
5
5
|
// src/components/OptionsContainer/OptionsContainer.vue?vue&type=script&setup=true&lang.ts
|
|
6
|
-
var
|
|
6
|
+
var x = ["id"], S = ["id"], C = /*@__PURE__*/ l({
|
|
7
7
|
__name: "OptionsContainer",
|
|
8
8
|
props: {
|
|
9
9
|
block: {},
|
|
@@ -12,6 +12,7 @@ var v = ["id"], y = ["id"], b = /*@__PURE__*/ l({
|
|
|
12
12
|
itemLabelAlign: {},
|
|
13
13
|
itemInputAlign: {},
|
|
14
14
|
listLayout: {},
|
|
15
|
+
listBlock: { type: Boolean },
|
|
15
16
|
variant: {},
|
|
16
17
|
indicatorReady: { type: Boolean },
|
|
17
18
|
hasErrors: { type: Boolean },
|
|
@@ -26,108 +27,125 @@ var v = ["id"], y = ["id"], b = /*@__PURE__*/ l({
|
|
|
26
27
|
options: {}
|
|
27
28
|
},
|
|
28
29
|
setup(l) {
|
|
29
|
-
let
|
|
30
|
-
root: `${
|
|
31
|
-
loading: `${
|
|
32
|
-
empty: `${
|
|
33
|
-
option: `${
|
|
34
|
-
label: `${
|
|
35
|
-
description: `${
|
|
36
|
-
})),
|
|
30
|
+
let C = l, w = i(() => !!C.hasWarnings && !C.hasErrors), { t: T } = e(), E = i(() => ({
|
|
31
|
+
root: `${C.block}__list`,
|
|
32
|
+
loading: `${C.block}__loading`,
|
|
33
|
+
empty: `${C.block}__empty`,
|
|
34
|
+
option: `${C.block}__item`,
|
|
35
|
+
label: `${C.block}__label`,
|
|
36
|
+
description: `${C.block}__item-description`
|
|
37
|
+
})), D = i(() => C.listLayout ?? "horizontal"), O = h(null), k = h(), A, j = () => Array.from(O.value?.children ?? []).filter((e) => e.classList.contains(E.value.option)), M = () => {
|
|
38
|
+
let e = j().map((e) => e.offsetHeight);
|
|
39
|
+
k.value = e.length ? Math.min(...e) : void 0;
|
|
40
|
+
}, N = () => {
|
|
41
|
+
if (A?.disconnect(), typeof ResizeObserver < "u") {
|
|
42
|
+
A ??= new ResizeObserver(M);
|
|
43
|
+
for (let e of j()) A.observe(e);
|
|
44
|
+
M();
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
p(N), b(() => C.options, N, { flush: "post" }), f(() => A?.disconnect());
|
|
48
|
+
let P = [
|
|
37
49
|
"auto",
|
|
38
50
|
"horizontal",
|
|
39
51
|
"vertical",
|
|
40
52
|
"label-fill",
|
|
41
53
|
"input-fill"
|
|
42
|
-
],
|
|
43
|
-
let e =
|
|
44
|
-
return
|
|
45
|
-
}),
|
|
46
|
-
if (
|
|
47
|
-
let [e, t] =
|
|
54
|
+
], F = (e) => /^[\S]+\s[\S]+$/.test(e), I = i(() => {
|
|
55
|
+
let e = C.itemLayout ?? "auto";
|
|
56
|
+
return P.includes(e) ? e : F(e) ? "ratio" : "auto";
|
|
57
|
+
}), L = (e) => I.value !== "vertical" && n.includes(e) ? e : void 0, R = i(() => L(C.itemLabelAlign)), z = i(() => L(C.itemInputAlign)), B = i(() => {
|
|
58
|
+
if (I.value !== "ratio") return;
|
|
59
|
+
let [e, t] = C.itemLayout.split(/\s+/).map((e) => e.length);
|
|
48
60
|
return { gridTemplateColumns: `minmax(0, ${e}fr) minmax(0, ${t}fr)` };
|
|
49
|
-
}),
|
|
50
|
-
|
|
51
|
-
},
|
|
52
|
-
|
|
53
|
-
},
|
|
61
|
+
}), V = t().id, H = (e) => `${V.value}-option-${e}__text`, U = (e) => `${V.value}-option-${e}__description`, W = h(null), G = h(!1), K = (e, t) => {
|
|
62
|
+
W.value = t, G.value = e.target instanceof Element && e.target.matches(":focus-visible");
|
|
63
|
+
}, q = (e) => {
|
|
64
|
+
W.value === e && (W.value = null, G.value = !1);
|
|
65
|
+
}, J = (e, t) => {
|
|
54
66
|
let n = {
|
|
55
|
-
onFocusin: (e) =>
|
|
56
|
-
onFocusout: () =>
|
|
57
|
-
}, r =
|
|
67
|
+
onFocusin: (e) => K(e, t),
|
|
68
|
+
onFocusout: () => q(t)
|
|
69
|
+
}, r = C.passthrough?.part?.("item", Y(e, t), e.item);
|
|
58
70
|
return r ? u(n, r) : n;
|
|
59
|
-
},
|
|
60
|
-
let n =
|
|
71
|
+
}, Y = (e, t) => {
|
|
72
|
+
let n = W.value === t;
|
|
61
73
|
return {
|
|
62
74
|
selected: !!e.selected,
|
|
63
75
|
checked: !!e.selected,
|
|
64
76
|
disabled: e.disabled || void 0,
|
|
65
77
|
focused: n,
|
|
66
|
-
focusVisible: n &&
|
|
78
|
+
focusVisible: n && G.value
|
|
67
79
|
};
|
|
68
80
|
};
|
|
69
|
-
return (e, t) => (
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
[
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
81
|
+
return (e, t) => (m(), o("span", u({
|
|
82
|
+
ref_key: "listEl",
|
|
83
|
+
ref: O,
|
|
84
|
+
class: [E.value.root, {
|
|
85
|
+
[`${E.value.root}--errors`]: l.hasErrors,
|
|
86
|
+
[`${E.value.root}--warnings`]: w.value,
|
|
87
|
+
[`${E.value.root}--${D.value}`]: !0,
|
|
88
|
+
[`${E.value.root}--block`]: l.listBlock,
|
|
89
|
+
[`${E.value.root}--strip`]: !!l.variant,
|
|
90
|
+
[`${E.value.root}--${l.variant}`]: !!l.variant,
|
|
91
|
+
[`${E.value.root}--no-transition`]: !!l.variant && !l.indicatorReady
|
|
92
|
+
}],
|
|
93
|
+
style: k.value ? { "--row-h": `${k.value}px` } : void 0
|
|
94
|
+
}, l.passthrough?.list), [
|
|
95
|
+
_(e.$slots, "prepend"),
|
|
96
|
+
!l.options.length && l.loading ? (m(), o("span", {
|
|
79
97
|
key: 0,
|
|
80
|
-
class: d(
|
|
81
|
-
}, [
|
|
98
|
+
class: d(E.value.loading)
|
|
99
|
+
}, [_(e.$slots, "loading", {}, () => [c(v(l.loadingText || y(T)("common.loadingText").value), 1)])], 2)) : l.options.length ? a("", !0) : (m(), o("span", {
|
|
82
100
|
key: 1,
|
|
83
|
-
class: d(
|
|
84
|
-
}, [
|
|
85
|
-
(
|
|
101
|
+
class: d(E.value.empty)
|
|
102
|
+
}, [_(e.$slots, "empty", { error: l.error ?? null }, () => [c(v(l.error == null ? l.emptyText || y(T)("common.emptyText").value : l.failedText || y(T)("common.failedText").value), 1)])], 2)),
|
|
103
|
+
(m(!0), o(r, null, g(l.options, (t, n) => (m(), o("label", u({
|
|
86
104
|
key: t?.valueHash || n,
|
|
87
|
-
class: [`${
|
|
88
|
-
[`${
|
|
89
|
-
[`${
|
|
90
|
-
[`${
|
|
91
|
-
[`${
|
|
92
|
-
[`${
|
|
93
|
-
[`${
|
|
94
|
-
[`${
|
|
95
|
-
[`${
|
|
96
|
-
[`${
|
|
97
|
-
[`${
|
|
105
|
+
class: [`${E.value.option}`, {
|
|
106
|
+
[`${E.value.option}--selected`]: t.selected,
|
|
107
|
+
[`${E.value.option}--description`]: t.description,
|
|
108
|
+
[`${E.value.option}--disabled`]: t.disabled,
|
|
109
|
+
[`${E.value.option}--focused`]: W.value === n,
|
|
110
|
+
[`${E.value.option}--focus-visible`]: W.value === n && G.value,
|
|
111
|
+
[`${E.value.option}--${I.value}`]: !0,
|
|
112
|
+
[`${E.value.option}--reverse`]: l.itemReverse,
|
|
113
|
+
[`${E.value.option}--aligned`]: !!(R.value || z.value),
|
|
114
|
+
[`${E.value.option}--label-align-${R.value}`]: !!R.value,
|
|
115
|
+
[`${E.value.option}--input-align-${z.value}`]: !!z.value
|
|
98
116
|
}],
|
|
99
|
-
style:
|
|
100
|
-
}, { ref_for: !0 },
|
|
101
|
-
|
|
102
|
-
descriptionId: t.description ?
|
|
117
|
+
style: B.value
|
|
118
|
+
}, { ref_for: !0 }, J(t, n)), [
|
|
119
|
+
_(e.$slots, "input", {
|
|
120
|
+
descriptionId: t.description ? U(n) : void 0,
|
|
103
121
|
index: n,
|
|
104
|
-
labelId:
|
|
122
|
+
labelId: H(n),
|
|
105
123
|
option: t,
|
|
106
|
-
rowStates:
|
|
124
|
+
rowStates: Y(t, n)
|
|
107
125
|
}),
|
|
108
126
|
s("span", u({
|
|
109
|
-
id:
|
|
127
|
+
id: H(n),
|
|
110
128
|
class: {
|
|
111
|
-
[
|
|
129
|
+
[E.value.label]: !0,
|
|
112
130
|
"bb-sr-only": l.hideLabel
|
|
113
131
|
}
|
|
114
|
-
}, { ref_for: !0 }, l.passthrough?.part?.("label",
|
|
132
|
+
}, { ref_for: !0 }, l.passthrough?.part?.("label", Y(t, n), t.item)), [_(e.$slots, "label", {
|
|
115
133
|
checked: !!t.selected,
|
|
116
134
|
description: t.description,
|
|
117
135
|
item: t.item,
|
|
118
136
|
text: t.text
|
|
119
|
-
}, () => [c(
|
|
120
|
-
t.description ? (
|
|
137
|
+
}, () => [c(v(t.text), 1)])], 16, x),
|
|
138
|
+
t.description ? (m(), o("span", u({
|
|
121
139
|
key: 0,
|
|
122
|
-
id:
|
|
140
|
+
id: U(n),
|
|
123
141
|
class: {
|
|
124
|
-
[
|
|
142
|
+
[E.value.description]: !0,
|
|
125
143
|
"bb-sr-only": l.hideLabel
|
|
126
144
|
}
|
|
127
|
-
}, { ref_for: !0 }, l.passthrough?.part?.("itemDescription",
|
|
145
|
+
}, { ref_for: !0 }, l.passthrough?.part?.("itemDescription", Y(t, n), t.item)), v(t.description), 17, S)) : a("", !0)
|
|
128
146
|
], 16))), 128)),
|
|
129
|
-
|
|
147
|
+
_(e.$slots, "append")
|
|
130
148
|
], 16));
|
|
131
149
|
}
|
|
132
150
|
});
|
|
133
|
-
export {
|
|
151
|
+
export { C as default };
|
|
@@ -34,6 +34,11 @@ export type OptionsContainerProps<T = any> = {
|
|
|
34
34
|
* @defaultValue `'horizontal'`
|
|
35
35
|
*/
|
|
36
36
|
listLayout?: ListLayout;
|
|
37
|
+
/**
|
|
38
|
+
* The group's `block`: the rows take the list's full width (`--block`),
|
|
39
|
+
* shared equally on a line, each full width when stacked.
|
|
40
|
+
*/
|
|
41
|
+
listBlock?: boolean;
|
|
37
42
|
/**
|
|
38
43
|
* A tab-strip look on the list: `--strip` plus the variant's
|
|
39
44
|
* class hook (`--pill`, `--line`, a registered name), the strip and its
|
|
@@ -23,8 +23,8 @@ type __VLS_Slots = {
|
|
|
23
23
|
default?: (props: object) => any;
|
|
24
24
|
};
|
|
25
25
|
declare const __VLS_base: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{}>, {
|
|
26
|
-
duration: number;
|
|
27
26
|
direction: "left" | "right" | "bottom" | "top";
|
|
27
|
+
duration: number;
|
|
28
28
|
gap: number;
|
|
29
29
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
30
30
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
@@ -1,20 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
1
|
+
import { useConfigDefaults as e } from "./useConfigDefaults.js";
|
|
2
|
+
import { useId as t } from "./useId.js";
|
|
3
|
+
import { useUrlQueryParam as n } from "./useUrlQueryParam.js";
|
|
4
|
+
import { useLogger as r } from "./useLogger.js";
|
|
5
|
+
import { useFrameworkDetection as i } from "./useFrameworkDetection.js";
|
|
6
|
+
import { isNil as a } from "../utilities/functions/isNil.js";
|
|
7
|
+
import { isNotNil as o } from "../utilities/functions/isNotNil.js";
|
|
8
|
+
import { slotKey as s } from "../utilities/functions/slotKey.js";
|
|
9
|
+
import { hash as c } from "../utilities/functions/hash.js";
|
|
10
|
+
import { computed as l, getCurrentInstance as ee, inject as u, nextTick as te, onMounted as d, onScopeDispose as ne, onUnmounted as f, provide as p, ref as m, shallowReactive as h, watch as g } from "vue";
|
|
10
11
|
// src/composables/useBbTabs.ts
|
|
11
|
-
var
|
|
12
|
-
let
|
|
12
|
+
var _ = Symbol("BbTabsContext"), v = h(/* @__PURE__ */ new Map()), y = /* @__PURE__ */ new Map(), b = (u, b) => {
|
|
13
|
+
let x = e("BbTabs", u, {
|
|
14
|
+
block: !1,
|
|
15
|
+
compact: !1
|
|
16
|
+
}), S = n(() => u.queryKey), { route: C, router: w } = S, { error: T, warn: E } = r(), { isInertia: D } = i(), O = ee(), k = t().id.value, A = u.id ?? k, j = `bb-tabs_${A}`, M = m(null), N = l(() => u.items.findIndex((e) => e.value === M.value)), P = l(() => N.value === 0), F = l(() => N.value === u.items.length - 1), I = l(() => u.items.some((e) => e.href != null || e.to != null));
|
|
13
17
|
u.items.forEach((e) => {
|
|
14
|
-
e.value ? (u.server || e.server) && !u.navigation && !I.value &&
|
|
18
|
+
e.value ? (u.server || e.server) && !u.navigation && !I.value && T(`A tab item has a server property but the navigation prop is false: ${JSON.stringify(e, null, 2)}`) : T(`A tab item has no value: ${JSON.stringify(e, null, 2)}`);
|
|
15
19
|
});
|
|
16
|
-
let L =
|
|
17
|
-
let t = u.items.find((t) =>
|
|
20
|
+
let L = S.tracked, R = (e) => String(e).split(/\W+/g).join("_").toLowerCase(), z = (e) => {
|
|
21
|
+
let t = u.items.find((t) => s(t.value) === e);
|
|
18
22
|
if (t) return {
|
|
19
23
|
key: t.value,
|
|
20
24
|
legacy: !1
|
|
@@ -24,16 +28,16 @@ var y = Symbol("BbTabsContext"), b = _(/* @__PURE__ */ new Map()), x = /* @__PUR
|
|
|
24
28
|
key: n.value,
|
|
25
29
|
legacy: !0
|
|
26
30
|
} : null;
|
|
27
|
-
}, B =
|
|
31
|
+
}, B = S.readLive, V = (e) => {
|
|
28
32
|
if (typeof window > "u") return;
|
|
29
|
-
let t =
|
|
30
|
-
(
|
|
33
|
+
let t = s(e);
|
|
34
|
+
(w && C.value ? C.value.query?.[u.queryKey] : B()) !== t && S.write(t, "replace");
|
|
31
35
|
}, H = () => {
|
|
32
36
|
if (I.value) {
|
|
33
37
|
M.value = u.modelValue ?? null;
|
|
34
38
|
return;
|
|
35
39
|
}
|
|
36
|
-
let e =
|
|
40
|
+
let e = S.read(), t = e ? z(e) : null, n = t?.key ?? null;
|
|
37
41
|
if (u.navigation && n) M.value = n, t?.legacy && typeof window < "u" && queueMicrotask(() => V(n));
|
|
38
42
|
else if (u.modelValue) M.value = u.modelValue;
|
|
39
43
|
else if (u.items[0]) {
|
|
@@ -56,31 +60,31 @@ var y = Symbol("BbTabsContext"), b = _(/* @__PURE__ */ new Map()), x = /* @__PUR
|
|
|
56
60
|
onCancel: e.onCancel ?? u.onCancel,
|
|
57
61
|
onFinish: e.onFinish ?? u.onFinish
|
|
58
62
|
}), W = (e) => {
|
|
59
|
-
u.modelValue !== e &&
|
|
63
|
+
u.modelValue !== e && b("update:modelValue", e), M.value = e;
|
|
60
64
|
}, G = (e, t = u.replace) => {
|
|
61
65
|
let n = u.items.find((t) => t.value === e);
|
|
62
|
-
if (
|
|
63
|
-
|
|
66
|
+
if (a(n)) {
|
|
67
|
+
E(`Cannot select tab "${e}" on tabs "${A}": no item with this key. Available keys: ${u.items.map((e) => e.value).join(", ")}. Selection unchanged.`);
|
|
64
68
|
return;
|
|
65
69
|
}
|
|
66
70
|
if (n.value === M.value || I.value) return;
|
|
67
|
-
let r =
|
|
68
|
-
if (u.navigation &&
|
|
69
|
-
else if (u.navigation &&
|
|
71
|
+
let r = s(e);
|
|
72
|
+
if (u.navigation && C.value && w && L.value !== r) S.write(r, t ? "replace" : "push");
|
|
73
|
+
else if (u.navigation && D && B() !== r) {
|
|
70
74
|
let i = globalThis.location.href;
|
|
71
75
|
if (u.server || n.server) {
|
|
72
|
-
let t = O?.proxy?.$inertia,
|
|
76
|
+
let t = O?.proxy?.$inertia, a = U(n), s = Object.fromEntries(Object.entries(a).filter(([e, t]) => o(t))), c = new URL(i, window.location.origin);
|
|
73
77
|
c.searchParams.set(u.queryKey, r), t.visit(c.toString(), {
|
|
74
78
|
...s,
|
|
75
|
-
onSuccess: (...t) => (W(e),
|
|
79
|
+
onSuccess: (...t) => (W(e), a.onSuccess?.(...t))
|
|
76
80
|
});
|
|
77
81
|
return;
|
|
78
82
|
}
|
|
79
|
-
|
|
83
|
+
S.write(r, t ? "replace" : "push", i);
|
|
80
84
|
}
|
|
81
85
|
W(e);
|
|
82
86
|
}, K = () => {
|
|
83
|
-
I.value || M.value && u.modelValue !== M.value &&
|
|
87
|
+
I.value || M.value && u.modelValue !== M.value && b("update:modelValue", M.value);
|
|
84
88
|
};
|
|
85
89
|
K();
|
|
86
90
|
let q = (e, t) => {
|
|
@@ -105,7 +109,7 @@ var y = Symbol("BbTabsContext"), b = _(/* @__PURE__ */ new Map()), x = /* @__PUR
|
|
|
105
109
|
let r = u.items[n];
|
|
106
110
|
return !r || r.disabled ? null : n;
|
|
107
111
|
}, J = (e) => {
|
|
108
|
-
document.getElementById(`${j}_tab_${
|
|
112
|
+
document.getElementById(`${j}_tab_${s(u.items[e].value)}`)?.focus();
|
|
109
113
|
}, Y = (e) => {
|
|
110
114
|
if (![
|
|
111
115
|
"first",
|
|
@@ -113,40 +117,40 @@ var y = Symbol("BbTabsContext"), b = _(/* @__PURE__ */ new Map()), x = /* @__PUR
|
|
|
113
117
|
"next",
|
|
114
118
|
"last"
|
|
115
119
|
].includes(e)) {
|
|
116
|
-
|
|
120
|
+
E(`Invalid goTo target "${e}" on tabs "${A}". Valid targets: 'first', 'previous', 'next', 'last'. Selection unchanged.`);
|
|
117
121
|
return;
|
|
118
122
|
}
|
|
119
123
|
if (!u.items.length) return;
|
|
120
124
|
let t = q(e, N.value);
|
|
121
125
|
t !== null && (J(t), G(u.items[t].value));
|
|
122
|
-
},
|
|
123
|
-
if (!
|
|
126
|
+
}, re = l(() => u.manualActivation ?? (!!u.server || u.items.some((e) => !!e.server))), X = (e, t) => {
|
|
127
|
+
if (!re.value) {
|
|
124
128
|
Y(e);
|
|
125
129
|
return;
|
|
126
130
|
}
|
|
127
131
|
if (!u.items.length) return;
|
|
128
|
-
let n = t.currentTarget?.id, r = u.items.findIndex((e) => `${j}_tab_${
|
|
132
|
+
let n = t.currentTarget?.id, r = u.items.findIndex((e) => `${j}_tab_${s(e.value)}` === n), i = r === -1 ? N.value : r, a = q(e, i);
|
|
129
133
|
a !== null && J(a);
|
|
130
|
-
},
|
|
134
|
+
}, ie = (e) => {
|
|
131
135
|
if (u.disabled) return;
|
|
132
136
|
let t = u.direction === "vertical";
|
|
133
137
|
e.key === "ArrowRight" || t && e.key === "ArrowDown" ? (e.preventDefault(), X("next", e)) : e.key === "ArrowLeft" || t && e.key === "ArrowUp" ? (e.preventDefault(), X("previous", e)) : e.key === "Home" ? (e.preventDefault(), X("first", e)) : e.key === "End" && (e.preventDefault(), X("last", e));
|
|
134
|
-
},
|
|
138
|
+
}, ae = l(() => {
|
|
135
139
|
let e = M.value, t = N.value;
|
|
136
140
|
return u.items.map((n) => {
|
|
137
|
-
let { value: r, label: i, eager: a } = n,
|
|
141
|
+
let { value: r, label: i, eager: a } = n, o = r === e, c = !!(n.disabled || u.disabled);
|
|
138
142
|
return {
|
|
139
143
|
item: n,
|
|
140
144
|
value: r,
|
|
141
145
|
label: i,
|
|
142
146
|
eager: a,
|
|
143
|
-
tabId: `${j}_tab_${
|
|
144
|
-
panelId: `${j}_tabpanel_${
|
|
145
|
-
labelSlotName: `${
|
|
146
|
-
panelSlotName:
|
|
147
|
-
active:
|
|
148
|
-
ariaSelected:
|
|
149
|
-
tabindex:
|
|
147
|
+
tabId: `${j}_tab_${s(r)}`,
|
|
148
|
+
panelId: `${j}_tabpanel_${s(r)}`,
|
|
149
|
+
labelSlotName: `${s(r)}:label`,
|
|
150
|
+
panelSlotName: s(r),
|
|
151
|
+
active: o,
|
|
152
|
+
ariaSelected: o,
|
|
153
|
+
tabindex: o ? 0 : -1,
|
|
150
154
|
disabled: c,
|
|
151
155
|
slotProps: {
|
|
152
156
|
current: e,
|
|
@@ -154,52 +158,52 @@ var y = Symbol("BbTabsContext"), b = _(/* @__PURE__ */ new Map()), x = /* @__PUR
|
|
|
154
158
|
disabled: c,
|
|
155
159
|
isFirst: P.value,
|
|
156
160
|
isLast: F.value,
|
|
157
|
-
selected:
|
|
161
|
+
selected: o,
|
|
158
162
|
label: i,
|
|
159
163
|
value: r,
|
|
160
164
|
goTo: Y
|
|
161
165
|
},
|
|
162
166
|
onClick: () => G(r),
|
|
163
|
-
onKeydown:
|
|
167
|
+
onKeydown: ie
|
|
164
168
|
};
|
|
165
169
|
});
|
|
166
170
|
});
|
|
167
|
-
|
|
171
|
+
g(() => u.modelValue, (e) => {
|
|
168
172
|
I.value ? M.value = e ?? null : e && G(e);
|
|
169
|
-
}),
|
|
170
|
-
if (!e || I.value || !
|
|
173
|
+
}), S.onExternalChange((e) => {
|
|
174
|
+
if (!e || I.value || !w && !u.navigation) return;
|
|
171
175
|
let t = z(e);
|
|
172
176
|
t && (G(t.key, t.legacy || void 0), t.legacy && V(t.key));
|
|
173
177
|
});
|
|
174
|
-
let Z =
|
|
175
|
-
|
|
178
|
+
let Z = m("right");
|
|
179
|
+
g(M, (e, t) => {
|
|
176
180
|
if (e && t) {
|
|
177
181
|
let n = u.items.findIndex((t) => t.value === e), r = u.items.findIndex((e) => e.value === t);
|
|
178
182
|
Z.value = n > r ? "right" : "left";
|
|
179
183
|
}
|
|
180
|
-
}, { flush: "sync" }),
|
|
184
|
+
}, { flush: "sync" }), g(() => c(u.items), () => {
|
|
181
185
|
M.value && !u.items.find((e) => e.value === M.value) && (H(), K());
|
|
182
186
|
}, {
|
|
183
187
|
immediate: !0,
|
|
184
188
|
deep: !0
|
|
185
189
|
});
|
|
186
|
-
let Q =
|
|
190
|
+
let Q = h(/* @__PURE__ */ new Set()), $ = {
|
|
187
191
|
id: A,
|
|
188
192
|
instanceid: j,
|
|
189
|
-
items:
|
|
190
|
-
disabled:
|
|
191
|
-
eager:
|
|
192
|
-
animateX:
|
|
193
|
-
animateY:
|
|
194
|
-
block:
|
|
195
|
-
compact:
|
|
196
|
-
direction:
|
|
197
|
-
variant:
|
|
193
|
+
items: l(() => u.items),
|
|
194
|
+
disabled: l(() => !!u.disabled),
|
|
195
|
+
eager: l(() => !!u.eager),
|
|
196
|
+
animateX: l(() => !u.disableAnimateX),
|
|
197
|
+
animateY: l(() => !u.disableAnimateY),
|
|
198
|
+
block: l(() => !!x.block),
|
|
199
|
+
compact: l(() => !!x.compact),
|
|
200
|
+
direction: l(() => u.direction),
|
|
201
|
+
variant: l(() => u.variant),
|
|
198
202
|
currentTab: M,
|
|
199
203
|
currentTabIndex: N,
|
|
200
204
|
isFirst: P,
|
|
201
205
|
isLast: F,
|
|
202
|
-
mappedItems:
|
|
206
|
+
mappedItems: ae,
|
|
203
207
|
animationDirection: Z,
|
|
204
208
|
select: G,
|
|
205
209
|
goTo: Y,
|
|
@@ -209,46 +213,46 @@ var y = Symbol("BbTabsContext"), b = _(/* @__PURE__ */ new Map()), x = /* @__PUR
|
|
|
209
213
|
href: e.href,
|
|
210
214
|
to: e.to,
|
|
211
215
|
...U(e)
|
|
212
|
-
}).filter(([, e]) =>
|
|
216
|
+
}).filter(([, e]) => o(e))),
|
|
213
217
|
registerPanels: (e) => {
|
|
214
|
-
Q.add(e),
|
|
218
|
+
Q.add(e), f(() => Q.delete(e));
|
|
215
219
|
}
|
|
216
220
|
};
|
|
217
|
-
if (
|
|
218
|
-
|
|
221
|
+
if (p(_, $), typeof window < "u") {
|
|
222
|
+
v.set(A, $);
|
|
219
223
|
let e = {};
|
|
220
|
-
|
|
221
|
-
let t =
|
|
222
|
-
t.add(e),
|
|
223
|
-
let t =
|
|
224
|
-
t && t.size > 1 && [...t].at(-1) === e &&
|
|
224
|
+
d(() => {
|
|
225
|
+
let t = y.get(A) ?? /* @__PURE__ */ new Set();
|
|
226
|
+
t.add(e), y.set(A, t), te(() => {
|
|
227
|
+
let t = y.get(A);
|
|
228
|
+
t && t.size > 1 && [...t].at(-1) === e && T(`Duplicate tabs id "${A}": useBbTabs("${A}") will resolve to the most recently mounted instance.`);
|
|
225
229
|
});
|
|
226
|
-
}),
|
|
227
|
-
let t =
|
|
228
|
-
t?.delete(e), t?.size ||
|
|
229
|
-
}),
|
|
230
|
-
|
|
230
|
+
}), f(() => {
|
|
231
|
+
let t = y.get(A);
|
|
232
|
+
t?.delete(e), t?.size || y.delete(A);
|
|
233
|
+
}), ne(() => {
|
|
234
|
+
v.get(A) === $ && v.delete(A);
|
|
231
235
|
});
|
|
232
236
|
}
|
|
233
237
|
return $;
|
|
234
|
-
},
|
|
235
|
-
let { warn: t } =
|
|
236
|
-
let r =
|
|
238
|
+
}, x = () => u(_, null), S = (e) => {
|
|
239
|
+
let { warn: t } = r(), n = (n) => {
|
|
240
|
+
let r = v.get(e);
|
|
237
241
|
r ? n(r) : t(`[useBbTabs] No mounted <BbTabs>/<BbTabsRoot> with id "${e}"; call ignored.`);
|
|
238
242
|
};
|
|
239
243
|
return {
|
|
240
|
-
isReady:
|
|
241
|
-
current:
|
|
242
|
-
get: () =>
|
|
243
|
-
set: (
|
|
244
|
-
|
|
244
|
+
isReady: l(() => v.has(e)),
|
|
245
|
+
current: l({
|
|
246
|
+
get: () => v.get(e)?.currentTab.value ?? null,
|
|
247
|
+
set: (r) => {
|
|
248
|
+
r == null ? t(`[useBbTabs] "current" cannot be set to null for id "${e}"; a tab is always selected. Assignment ignored.`) : n((e) => e.select(r));
|
|
245
249
|
}
|
|
246
250
|
}),
|
|
247
|
-
currentIndex:
|
|
248
|
-
isFirst:
|
|
249
|
-
isLast:
|
|
250
|
-
goTo: (e) =>
|
|
251
|
-
select: (e) =>
|
|
251
|
+
currentIndex: l(() => v.get(e)?.currentTabIndex.value ?? -1),
|
|
252
|
+
isFirst: l(() => v.get(e)?.isFirst.value ?? !1),
|
|
253
|
+
isLast: l(() => v.get(e)?.isLast.value ?? !1),
|
|
254
|
+
goTo: (e) => n((t) => t.goTo(e)),
|
|
255
|
+
select: (e) => n((t) => t.select(e))
|
|
252
256
|
};
|
|
253
257
|
};
|
|
254
|
-
export {
|
|
258
|
+
export { b as createTabsContext, S as useBbTabs, x as useInternalTabsContext };
|
|
@@ -5,14 +5,7 @@ import { config as i } from "virtual:bitboss-ui/config";
|
|
|
5
5
|
var a = Symbol("bitboss-ui:config"), o = (t) => r({
|
|
6
6
|
...i,
|
|
7
7
|
...t,
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
...t?.formControls
|
|
11
|
-
},
|
|
12
|
-
confirm: {
|
|
13
|
-
...i.confirm,
|
|
14
|
-
...t?.confirm
|
|
15
|
-
},
|
|
16
|
-
pt: e()
|
|
8
|
+
pt: e(),
|
|
9
|
+
components: i.components
|
|
17
10
|
}), s = () => t() ? n(a, i) : i;
|
|
18
11
|
export { a as BB_CONFIG_KEY, o as createAppConfig, s as useConfig };
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { ComputedRef } from 'vue';
|
|
2
|
+
import { ConfigLayer } from '../utils/configScope';
|
|
3
|
+
import { BbAllConfig, BbComponentDefaults, BbDefaultsComponent } from '../types/ConfigDefaults';
|
|
4
|
+
import { Sizes } from '../types/SizeScale';
|
|
5
|
+
/**
|
|
6
|
+
* Test lever: swaps the app's `components` map and the named scopes for one
|
|
7
|
+
* test file. Not exported from the package; no argument restores them.
|
|
8
|
+
* @internal
|
|
9
|
+
*/
|
|
10
|
+
export declare const __setConfigDefaultsForTest: (components?: Record<string, unknown>, scopes?: Record<string, Record<string, unknown>>) => void;
|
|
11
|
+
type Chain = ComputedRef<readonly ConfigLayer[]> | null;
|
|
12
|
+
/** The active scope chain, or `null` outside a component / with no scope in use. */
|
|
13
|
+
export declare const useConfigChain: () => Chain;
|
|
14
|
+
/**
|
|
15
|
+
* The config value of one allowlisted prop, without the instance's own: the
|
|
16
|
+
* nearest scope's component entry, that scope's `all`, outer scopes likewise,
|
|
17
|
+
* the app's entry, the app's `all`. For a prop with a source between the
|
|
18
|
+
* instance and the config (a `BbForm`'s `validation-mode`).
|
|
19
|
+
*/
|
|
20
|
+
export declare const useConfigFallback: (component: string, key: string) => (() => unknown);
|
|
21
|
+
/**
|
|
22
|
+
* The allowlisted props of one component, resolved: the instance's own value,
|
|
23
|
+
* else the nearest `<BbConfigScope>` that sets it (its component entry, then
|
|
24
|
+
* its `all`), outer scopes likewise, then the plugin's `components` map (the
|
|
25
|
+
* entry, then `all`), else `fallback` (the component's own default). Each key
|
|
26
|
+
* is a getter over reactive sources (the props and the scope chain), so a read
|
|
27
|
+
* in a render or a `computed` tracks all of them.
|
|
28
|
+
*
|
|
29
|
+
* The props it resolves are declared with `default: undefined`: unset is what
|
|
30
|
+
* lets a default show through, and `false` stays an explicit choice.
|
|
31
|
+
*/
|
|
32
|
+
export declare const useConfigDefaults: <C extends BbDefaultsComponent, F extends BbComponentDefaults<C>>(component: C, props: Readonly<Partial<Record<keyof BbComponentDefaults<C>, unknown>>>, fallback: F) => { readonly [P in keyof BbComponentDefaults<C>]-?: P extends keyof F ? NonNullable<BbComponentDefaults<C>[P]> : BbComponentDefaults<C>[P]; };
|
|
33
|
+
/**
|
|
34
|
+
* A non-prop setting: a component's (`BbToast.position`, `BbConfirm.size`)
|
|
35
|
+
* when `component` is given, else one of `all`'s (`requiredAsterisk`). A
|
|
36
|
+
* getter over the scope chain this was called under; `undefined` when unset.
|
|
37
|
+
*/
|
|
38
|
+
export declare const useConfigSetting: <T>(component: string | null, key: string) => (() => T | undefined);
|
|
39
|
+
/**
|
|
40
|
+
* A component's non-prop setting from the active scopes only, the app map left
|
|
41
|
+
* out: what a call made inside a scope stamps on its message (`useToast`), so
|
|
42
|
+
* the host's own default still applies outside any scope.
|
|
43
|
+
*/
|
|
44
|
+
export declare const useScopedSetting: <T>(component: string, key: string) => (() => T | undefined);
|
|
45
|
+
/** One of `all`'s settings outside any component: the app map only. */
|
|
46
|
+
export declare const appAllSetting: <K extends keyof BbAllConfig>(key: K) => BbAllConfig[K];
|
|
47
|
+
/** An allowlisted prop's app-level default, no scope (a directive's trigger). */
|
|
48
|
+
export declare const appConfigDefault: (component: string, key: string) => unknown;
|
|
49
|
+
/**
|
|
50
|
+
* A component's size scale: the built-in, then the app's `sizeMap`, then each
|
|
51
|
+
* active scope's, outermost first, name by name.
|
|
52
|
+
*/
|
|
53
|
+
export declare const useSizeMap: (component: string, builtIn: Sizes) => ComputedRef<Sizes>;
|
|
54
|
+
export {};
|