bitboss-ui 3.0.0-beta.63 → 3.0.0-beta.65
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 +25 -20
- package/bin/bitboss-ui.mjs +73 -7
- package/dist/ai/BbAlert.md +10 -1
- package/dist/ai/BbBadge.md +35 -3
- package/dist/ai/BbBadgeButton.md +4 -2
- package/dist/ai/BbBaseButton.md +9 -3
- package/dist/ai/BbBreadcrumbs.md +2 -2
- package/dist/ai/BbButton.md +113 -8
- package/dist/ai/BbCheckbox.md +1 -1
- package/dist/ai/BbCheckboxGroup.md +94 -6
- package/dist/ai/BbColorInput.md +4 -1
- package/dist/ai/BbColorPalette.md +2 -1
- package/dist/ai/BbConfirm.md +7 -3
- package/dist/ai/BbDatePicker.md +2 -1
- package/dist/ai/BbDatePickerInput.md +4 -1
- package/dist/ai/BbDialog.md +12 -11
- package/dist/ai/BbDropdown.md +189 -38
- package/dist/ai/BbDropdownButton.md +27 -7
- package/dist/ai/BbForm.md +55 -22
- package/dist/ai/BbHost.md +2 -2
- package/dist/ai/BbHoverCard.md +7 -3
- package/dist/ai/BbIcon.md +12 -6
- package/dist/ai/BbIndicator.md +11 -1
- package/dist/ai/BbNumberInput.md +4 -1
- package/dist/ai/BbOffCanvas.md +37 -3
- package/dist/ai/BbPopover.md +2 -1
- package/dist/ai/BbRadio.md +1 -1
- package/dist/ai/BbRadioGroup.md +102 -10
- package/dist/ai/BbSelect.md +52 -17
- package/dist/ai/BbSelectPopover.md +93 -26
- package/dist/ai/BbSwitch.md +1 -1
- package/dist/ai/BbSwitchGroup.md +30 -3
- package/dist/ai/BbTable.md +17 -10
- package/dist/ai/BbTabs.md +8 -3
- package/dist/ai/BbTabsList.md +4 -1
- package/dist/ai/BbTag.md +5 -2
- package/dist/ai/BbTextInput.md +4 -1
- package/dist/ai/BbTextarea.md +4 -1
- package/dist/ai/BbTimePicker.md +2 -1
- package/dist/ai/BbTimePickerInput.md +4 -1
- package/dist/ai/BbToast.md +9 -3
- package/dist/ai/BbTooltip.md +71 -9
- package/dist/ai/ChipsBox.md +1 -1
- package/dist/ai/CommonField.md +1 -1
- package/dist/ai/OptionsContainer.md +42 -0
- package/dist/ai/changelog.json +494 -6
- package/dist/ai/components.json +50 -48
- package/dist/ai/composables/useBbConfig.md +8 -1
- package/dist/ai/composables/useConfirm.md +39 -1
- package/dist/ai/design-tokens.json +6 -6
- package/dist/ai/guides/agent-contract.md +2 -2
- package/dist/ai/guides/ai-router.md +24 -23
- package/dist/ai/guides/app-layout.md +5 -0
- package/dist/ai/guides/component-picker.md +9 -2
- package/dist/ai/guides/design-language.md +24 -24
- package/dist/ai/guides/design-tokens.md +15 -8
- package/dist/ai/guides/icons-policy.md +9 -2
- package/dist/ai/guides/inertia-helpers.md +1183 -301
- package/dist/ai/guides/installation-and-plugin-setup.md +12 -2
- package/dist/ai/guides/migration/adoption-checklist.md +235 -0
- package/dist/ai/guides/migration/components/bb-checkbox-group.md +16 -15
- package/dist/ai/guides/migration/components/bb-dialog.md +9 -9
- package/dist/ai/guides/migration/components/bb-dropdown.md +7 -2
- package/dist/ai/guides/migration/components/bb-popover.md +4 -2
- package/dist/ai/guides/migration/components/bb-select.md +19 -0
- package/dist/ai/guides/migration/components/bb-table.md +1 -0
- package/dist/ai/guides/migration/components/bb-toast.md +4 -0
- package/dist/ai/guides/migration/components/bb-tooltip.md +15 -12
- package/dist/ai/guides/migration/components/use-confirm.md +25 -2
- package/dist/ai/guides/migration/v2-to-v3.md +211 -9
- package/dist/ai/guides/migration/v3-beta-css-classes.md +7 -3
- package/dist/ai/guides/options-items-playbook.md +2 -1
- package/dist/ai/guides/passthrough.md +149 -85
- package/dist/ai/guides/preset-components.md +140 -15
- package/dist/ai/helpers/definePreset.json +7 -0
- package/dist/ai/helpers/definePreset.ts +123 -11
- package/dist/ai/helpers/inertia/manifest.json +151 -62
- package/dist/ai/helpers/inertia/messages.ts +33 -0
- package/dist/ai/helpers/inertia/useConfirmOnRouteLeave.ts +120 -20
- package/dist/ai/helpers/inertia/useHasChanged.ts +34 -16
- package/dist/ai/helpers/inertia/useLazyProp.ts +102 -36
- package/dist/ai/helpers/inertia/useLazyPropGetter.ts +3 -1
- package/dist/ai/helpers/inertia/usePaginatedResponseContext.ts +154 -34
- package/dist/ai/helpers/inertia/usePromiseForm.ts +121 -14
- package/dist/ai/helpers/inertia/useQuery.ts +133 -11
- package/dist/ai/helpers/inertia/useQueryObject.ts +74 -67
- package/dist/ai/helpers/inertia/useResourceContext.ts +60 -14
- package/dist/ai/helpers/inertia/useRouteQuery.ts +38 -27
- package/dist/ai/helpers/inertia/useScreenSizes.ts +9 -7
- package/dist/ai/helpers/inertia/useTableContext.ts +5 -2
- package/dist/ai/helpers/inertia/utils.ts +14 -0
- package/dist/ai/index.md +1 -0
- package/dist/ai/manifest/common.json +0 -1
- package/dist/ai/manifest/components/BbAlert.json +7 -2
- package/dist/ai/manifest/components/BbBadge.json +13 -4
- package/dist/ai/manifest/components/BbBadge.tree.json +2 -0
- package/dist/ai/manifest/components/BbBadgeButton.json +4 -2
- package/dist/ai/manifest/components/BbBaseButton.json +4 -2
- package/dist/ai/manifest/components/BbBreadcrumbs.tree.json +1 -1
- package/dist/ai/manifest/components/BbButton.json +14 -3
- package/dist/ai/manifest/components/BbButton.tree.json +5 -1
- package/dist/ai/manifest/components/BbCheckboxGroup.json +13 -8
- package/dist/ai/manifest/components/BbCheckboxGroup.tree.json +11 -1
- package/dist/ai/manifest/components/BbColorInput.json +18 -15
- package/dist/ai/manifest/components/BbColorPalette.json +1 -1
- package/dist/ai/manifest/components/BbConfirm.json +4 -2
- package/dist/ai/manifest/components/BbConfirm.tree.json +1 -1
- package/dist/ai/manifest/components/BbDatePicker.json +1 -1
- package/dist/ai/manifest/components/BbDatePickerInput.json +17 -14
- package/dist/ai/manifest/components/BbDialog.tree.json +2 -1
- package/dist/ai/manifest/components/BbDropdown.json +24 -19
- package/dist/ai/manifest/components/BbDropdown.tree.json +9 -2
- package/dist/ai/manifest/components/BbDropdownButton.json +33 -20
- package/dist/ai/manifest/components/BbDropdownButton.tree.json +2 -2
- package/dist/ai/manifest/components/BbForm.json +2 -2
- package/dist/ai/manifest/components/BbHost.tree.json +1 -1
- package/dist/ai/manifest/components/BbHoverCard.json +1 -1
- package/dist/ai/manifest/components/BbIndicator.json +8 -2
- package/dist/ai/manifest/components/BbNumberInput.json +5 -2
- package/dist/ai/manifest/components/BbOffCanvas.json +2 -2
- package/dist/ai/manifest/components/BbOffCanvas.tree.json +1 -1
- package/dist/ai/manifest/components/BbPopover.json +1 -1
- package/dist/ai/manifest/components/BbRadioGroup.json +17 -12
- package/dist/ai/manifest/components/BbRadioGroup.tree.json +8 -1
- package/dist/ai/manifest/components/BbSelect.json +21 -18
- package/dist/ai/manifest/components/BbSelect.tree.json +2 -2
- package/dist/ai/manifest/components/BbSelectPopover.json +10 -10
- package/dist/ai/manifest/components/BbSelectPopover.tree.json +3 -2
- package/dist/ai/manifest/components/BbSwitchGroup.json +1 -1
- package/dist/ai/manifest/components/BbSwitchGroup.tree.json +3 -1
- package/dist/ai/manifest/components/BbTable.tree.json +14 -1
- package/dist/ai/manifest/components/BbTabs.json +9 -6
- package/dist/ai/manifest/components/BbTabs.tree.json +1 -1
- package/dist/ai/manifest/components/BbTabsList.json +6 -3
- package/dist/ai/manifest/components/BbTag.json +19 -16
- package/dist/ai/manifest/components/BbTag.tree.json +1 -1
- package/dist/ai/manifest/components/BbTextInput.json +6 -3
- package/dist/ai/manifest/components/BbTextarea.json +6 -3
- package/dist/ai/manifest/components/BbTimePicker.json +1 -1
- package/dist/ai/manifest/components/BbTimePickerInput.json +10 -7
- package/dist/ai/manifest/components/BbToast.json +7 -2
- package/dist/ai/manifest/components/BbToast.tree.json +4 -2
- package/dist/ai/manifest/components/BbTooltip.json +6 -5
- package/dist/ai/manifest/components/ChipsBox.tree.json +1 -1
- package/dist/ai/manifest/components/CommonField.json +1 -1
- package/dist/ai/manifest/components/OptionsContainer.json +3 -1
- package/dist/ai/manifest/components/OptionsContainer.tree.json +38 -0
- package/dist/ai/manifest/index.json +3 -3
- package/dist/ai/manifest/meta.json +5 -3
- package/dist/ai/manifest/types.advanced.json +5 -2
- package/dist/ai/manifest/types.api.json +9 -7
- package/dist/ai/recipes/inertia/approvals-inbox.md +1 -1
- package/dist/ai/recipes/inertia/inline-edit-workspace.md +1 -1
- package/dist/ai/recipes/inertia/layout-scaffold.md +19 -6
- package/dist/ai/recipes/inertia/ownership-atlas.md +1 -1
- package/dist/ai/recipes/inertia/records-workspace.md +50 -14
- package/dist/ai/recipes/inertia/upload-center.md +1 -1
- package/dist/ai/recipes/nuxt/layout-scaffold.md +19 -6
- package/dist/ai/recipes/nuxt/records-workspace.md +42 -12
- package/dist/ai/recipes/vue/layout-scaffold.md +19 -6
- package/dist/ai/recipes/vue/records-workspace.md +42 -12
- package/dist/ai/source/BbAlert.md +94 -76
- package/dist/ai/source/BbBadge.md +174 -72
- package/dist/ai/source/BbBadgeButton.md +130 -65
- package/dist/ai/source/BbBaseButton.md +46 -124
- package/dist/ai/source/BbBaseCheckboxIcon.md +38 -0
- package/dist/ai/source/BbBaseRadioIcon.md +18 -0
- package/dist/ai/source/BbBaseSwitchIcon.md +51 -0
- package/dist/ai/source/BbButton.md +153 -36
- package/dist/ai/source/BbCheckboxGroup.md +142 -18
- package/dist/ai/source/BbColorInput.md +240 -204
- package/dist/ai/source/BbColorPalette.md +7 -4
- package/dist/ai/source/BbConfirm.md +34 -11
- package/dist/ai/source/BbConfirmPortal.md +24 -9
- package/dist/ai/source/BbDatePicker.md +11 -7
- package/dist/ai/source/BbDatePickerInput.md +306 -269
- package/dist/ai/source/BbDialog.md +49 -14
- package/dist/ai/source/BbDropdown.md +314 -197
- package/dist/ai/source/BbDropdownButton.md +197 -31
- package/dist/ai/source/BbDropdownGroup.md +274 -176
- package/dist/ai/source/BbForm.md +50 -6
- package/dist/ai/source/BbHoverCard.md +12 -5
- package/dist/ai/source/BbIcon.md +4 -3
- package/dist/ai/source/BbIndicator.md +73 -52
- package/dist/ai/source/BbNumberInput.md +293 -257
- package/dist/ai/source/BbOffCanvas.md +55 -29
- package/dist/ai/source/BbPopover.md +14 -10
- package/dist/ai/source/BbRadioGroup.md +413 -297
- package/dist/ai/source/BbSelect.md +549 -435
- package/dist/ai/source/BbSelectPopover.md +153 -34
- package/dist/ai/source/BbSwitchGroup.md +70 -10
- package/dist/ai/source/BbTable.md +369 -37
- package/dist/ai/source/BbTabs.md +115 -39
- package/dist/ai/source/BbTabsList.md +106 -38
- package/dist/ai/source/BbTabsPanels.md +96 -36
- package/dist/ai/source/BbTabsRoot.md +96 -36
- package/dist/ai/source/BbTag.md +267 -233
- package/dist/ai/source/BbTextInput.md +261 -225
- package/dist/ai/source/BbTextarea.md +251 -215
- package/dist/ai/source/BbTimePicker.md +11 -7
- package/dist/ai/source/BbTimePickerInput.md +257 -220
- package/dist/ai/source/BbToast.md +73 -32
- package/dist/ai/source/BbToastPortal.md +65 -30
- package/dist/ai/source/BbTooltip.md +148 -113
- package/dist/ai/source/CommonPopover.md +6 -1
- package/dist/ai/source/FlatListBox.md +19 -9
- package/dist/ai/source/GroupedListBox.md +19 -9
- package/dist/ai/source/OptionsContainer.md +25 -9
- package/dist/components/BbAlert/BbAlert.vue_vue_type_script_setup_true_lang.js +61 -36
- package/dist/components/BbAlert/types.d.ts +9 -5
- package/dist/components/BbAlert/types.js +8 -3
- package/dist/components/BbBadge/BadgeBodyContent.vue.d.ts +3 -3
- package/dist/components/BbBadge/BadgeBodyContent.vue_vue_type_script_setup_true_lang.js +26 -17
- package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +103 -50
- package/dist/components/BbBadge/BbBadgeButton.vue_vue_type_script_setup_true_lang.js +20 -15
- package/dist/components/BbBadge/badgeButtonContext.d.ts +12 -1
- package/dist/components/BbBadge/types.d.ts +45 -15
- package/dist/components/BbBadge/types.js +12 -3
- package/dist/components/BbBaseButton/BbBaseButton.vue_vue_type_script_setup_true_lang.js +89 -126
- package/dist/components/BbBaseButton/types.d.ts +23 -4
- package/dist/components/BbBaseButton/types.js +7 -1
- package/dist/components/BbBaseButton/useLinkState.d.ts +41 -0
- package/dist/components/BbBaseButton/useLinkState.js +70 -0
- package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +130 -74
- package/dist/components/BbButton/types.d.ts +50 -13
- package/dist/components/BbButton/types.js +10 -3
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +148 -95
- package/dist/components/BbCheckboxGroup/types.d.ts +34 -11
- package/dist/components/BbCheckboxGroup/types.js +9 -4
- package/dist/components/BbCollapsible/BbCollapsible.vue.d.ts +1 -1
- package/dist/components/BbColorInput/BbColorInput.vue_vue_type_script_setup_true_lang.js +134 -93
- package/dist/components/BbColorInput/types.d.ts +11 -4
- package/dist/components/BbColorInput/types.js +9 -3
- package/dist/components/BbConfirm/BbConfirm.vue_vue_type_script_setup_true_lang.js +82 -59
- package/dist/components/BbConfirm/types.d.ts +9 -4
- package/dist/components/BbConfirm/types.js +8 -3
- package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +1 -1
- package/dist/components/BbDatePicker/BbDatePicker.vue_vue_type_script_setup_true_lang.js +68 -67
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +1 -1
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +259 -215
- package/dist/components/BbDatePickerInput/types.d.ts +12 -5
- package/dist/components/BbDatePickerInput/types.js +9 -3
- package/dist/components/BbDialog/BbDialog.vue_vue_type_script_setup_true_lang.js +223 -219
- package/dist/components/BbDialog/useDialogStack.d.ts +1 -1
- package/dist/components/BbDropdown/AdaptiveDropdown.vue_vue_type_script_setup_true_lang.js +104 -89
- package/dist/components/BbDropdown/BbDropdown.vue.d.ts +1 -0
- package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +323 -285
- package/dist/components/BbDropdown/BbDropdownList.vue.d.ts +1 -0
- package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +411 -319
- package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +100 -98
- package/dist/components/BbDropdown/DropdownRow.vue.d.ts +4 -3
- package/dist/components/BbDropdown/DropdownRow.vue_vue_type_script_setup_true_lang.js +49 -28
- package/dist/components/BbDropdown/normalizeGroups.d.ts +6 -0
- package/dist/components/BbDropdown/normalizeGroups.js +21 -15
- package/dist/components/BbDropdown/types.d.ts +59 -12
- package/dist/components/BbDropdown/types.js +16 -3
- package/dist/components/BbDropdown/useDropdownContext.d.ts +6 -0
- package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +2 -1
- package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +179 -68
- package/dist/components/BbDropdownButton/types.d.ts +44 -16
- package/dist/components/BbDropdownButton/types.js +28 -3
- package/dist/components/BbForm/BbForm.vue_vue_type_script_setup_true_lang.js +111 -89
- package/dist/components/BbForm/formSchema.d.ts +13 -0
- package/dist/components/BbHoverCard/BbHoverCard.vue_vue_type_script_setup_true_lang.js +100 -100
- package/dist/components/BbIndicator/BbIndicator.vue_vue_type_script_setup_true_lang.js +40 -25
- package/dist/components/BbIndicator/types.d.ts +9 -5
- package/dist/components/BbIndicator/types.js +8 -3
- package/dist/components/BbNumberInput/BbNumberInput.vue_vue_type_script_setup_true_lang.js +243 -202
- package/dist/components/BbNumberInput/types.d.ts +12 -5
- package/dist/components/BbNumberInput/types.js +9 -3
- package/dist/components/BbOffCanvas/BbOffCanvas.vue.d.ts +1 -1
- package/dist/components/BbOffCanvas/BbOffCanvas.vue_vue_type_script_setup_true_lang.js +401 -399
- package/dist/components/BbOffCanvas/types.d.ts +6 -2
- package/dist/components/BbPopover/BbPopover.vue_vue_type_script_setup_true_lang.js +81 -80
- package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +158 -105
- package/dist/components/BbRadioGroup/types.d.ts +21 -7
- package/dist/components/BbRadioGroup/types.js +9 -4
- package/dist/components/BbSelect/BbSelect.vue.d.ts +4 -3
- package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +181 -137
- package/dist/components/BbSelect/types.d.ts +36 -22
- package/dist/components/BbSelect/types.js +22 -3
- package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +4 -4
- package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +600 -577
- package/dist/components/BbSelectPopover/knownItems.d.ts +5 -0
- package/dist/components/BbSelectPopover/types.d.ts +46 -12
- package/dist/components/BbSmoothHeight/BbSmoothHeight.vue.d.ts +1 -1
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +2 -2
- package/dist/components/BbSwitchGroup/types.d.ts +14 -4
- package/dist/components/BbSwitchGroup/types.js +8 -3
- package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +1102 -995
- package/dist/components/BbTable/estimatedFloors.golden.d.ts +25 -0
- package/dist/components/BbTable/measuredFloors.d.ts +46 -0
- package/dist/components/BbTable/measuredFloors.js +322 -0
- package/dist/components/BbTable/measuredFloorsTestKit.d.ts +27 -0
- package/dist/components/BbTable/textRuler.d.ts +71 -0
- package/dist/components/BbTable/textRuler.js +121 -0
- package/dist/components/BbTable/utils.d.ts +113 -6
- package/dist/components/BbTable/utils.js +118 -65
- package/dist/components/BbTabs/BbTabs.vue_vue_type_script_setup_true_lang.js +53 -35
- package/dist/components/BbTabs/BbTabsList.vue_vue_type_script_setup_true_lang.js +62 -45
- package/dist/components/BbTabs/types.d.ts +26 -11
- package/dist/components/BbTabs/types.js +23 -8
- package/dist/components/BbTag/BbTag.vue_vue_type_script_setup_true_lang.js +205 -164
- package/dist/components/BbTag/types.d.ts +11 -4
- package/dist/components/BbTag/types.js +9 -3
- package/dist/components/BbTextInput/BbTextInput.vue_vue_type_script_setup_true_lang.js +98 -57
- package/dist/components/BbTextInput/types.d.ts +12 -5
- package/dist/components/BbTextInput/types.js +9 -3
- package/dist/components/BbTextarea/BbTextarea.vue_vue_type_script_setup_true_lang.js +137 -96
- package/dist/components/BbTextarea/types.d.ts +12 -5
- package/dist/components/BbTextarea/types.js +9 -3
- package/dist/components/BbTimePicker/BbTimePicker.vue_vue_type_script_setup_true_lang.js +105 -104
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +241 -197
- package/dist/components/BbTimePickerInput/types.d.ts +12 -5
- package/dist/components/BbTimePickerInput/types.js +9 -3
- package/dist/components/BbToast/BbToast.vue_vue_type_script_setup_true_lang.js +74 -32
- package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +47 -47
- package/dist/components/BbToast/types.d.ts +10 -5
- package/dist/components/BbToast/types.js +18 -3
- package/dist/components/BbTooltip/BbTooltip.vue_vue_type_script_setup_true_lang.js +85 -71
- package/dist/components/BbTooltip/types.d.ts +13 -8
- package/dist/components/BbTooltip/types.js +8 -3
- package/dist/components/CommonField/CommonField.vue.d.ts +1 -1
- package/dist/components/CommonPopover/CommonPopover.vue.d.ts +1 -1
- package/dist/components/CommonPopover/CommonPopover.vue_vue_type_script_setup_true_lang.js +69 -69
- package/dist/components/FlatListBox/FlatListBox.vue_vue_type_script_setup_true_lang.js +53 -50
- package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js +146 -143
- package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js +7 -2
- package/dist/components/OptionsContainer/types.d.ts +14 -3
- package/dist/composables/useBbConfig.d.ts +1 -0
- package/dist/composables/useBbConfig.js +11 -7
- package/dist/composables/useBbFormContext.d.ts +4 -3
- package/dist/composables/useBbTabsContext.js +99 -85
- package/dist/composables/useChoiceIndicator.d.ts +58 -0
- package/dist/composables/useChoiceIndicator.js +197 -0
- package/dist/composables/useConfirm.d.ts +4 -4
- package/dist/composables/usePassthrough.d.ts +54 -1
- package/dist/composables/usePassthrough.js +100 -71
- package/dist/directives/bbTooltip.d.ts +12 -6
- package/dist/directives/createPopoverDirective.js +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/llms-full.txt +3467 -801
- package/dist/llms-medium.txt +71 -53
- package/dist/llms.txt +2 -1
- package/dist/passthrough-deduper.js +6 -3
- package/dist/project-dts.d.ts +24 -0
- package/dist/project-dts.js +43 -17
- package/dist/styles.css +2 -2
- package/dist/types/AlertVariant.d.ts +14 -0
- package/dist/types/AlertVariant.js +9 -0
- package/dist/types/BadgeVariant.d.ts +14 -0
- package/dist/types/BadgeVariant.js +9 -0
- package/dist/types/ButtonVariant.d.ts +16 -0
- package/dist/types/ButtonVariant.js +11 -0
- package/dist/types/CheckboxVariant.d.ts +38 -0
- package/dist/types/CheckboxVariant.js +4 -0
- package/dist/types/CommonProps.d.ts +4 -3
- package/dist/types/Config.d.ts +7 -0
- package/dist/types/ConfirmVariant.d.ts +12 -0
- package/dist/types/ConfirmVariant.js +4 -0
- package/dist/types/DropdownItemVariant.d.ts +12 -0
- package/dist/types/DropdownItemVariant.js +4 -0
- package/dist/types/IndicatorVariant.d.ts +15 -0
- package/dist/types/IndicatorVariant.js +10 -0
- package/dist/types/InputVariant.d.ts +13 -0
- package/dist/types/InputVariant.js +8 -0
- package/dist/types/RadioVariant.d.ts +38 -0
- package/dist/types/RadioVariant.js +4 -0
- package/dist/types/TabsVariant.d.ts +13 -0
- package/dist/types/TabsVariant.js +8 -0
- package/dist/types/ToastVariant.d.ts +15 -0
- package/dist/types/ToastVariant.js +10 -0
- package/dist/types/TooltipVariant.d.ts +12 -0
- package/dist/types/TooltipVariant.js +4 -0
- package/dist/types/passthrough.d.ts +83 -15
- package/dist/types/passthrough.js +2 -2
- package/dist/types/ptComponentMap.d.ts +35 -23
- package/dist/utilities/functions/extractDomContainer.d.ts +20 -1
- package/dist/utilities/functions/extractDomContainer.js +8 -3
- package/dist/utils/focusVisibility.d.ts +6 -0
- package/dist/utils/focusVisibility.js +4 -1
- package/dist/utils/passthroughDeduper.d.ts +14 -0
- package/dist/utils/versionCheck.js +1 -1
- package/dist/vite-plugin.d.ts +64 -7
- package/dist/vite.js +385 -259
- package/llms.txt +2 -1
- package/package.json +5 -4
- package/scripts/lib/adoption-checklist.json +312 -0
- package/scripts/lib/eslint-plugin.d.ts +13 -0
- package/scripts/lib/eslint-plugin.mjs +75 -11
- package/scripts/lib/helpers-add.mjs +26 -2
- package/scripts/lib/idiom-scan.mjs +65 -0
- package/scripts/lib/mcp-config.mjs +203 -9
- package/scripts/lib/migrate-fix.mjs +42 -1
- package/scripts/lib/project-variant-dts.mjs +18 -0
- package/scripts/lib/validate-bb-markup.mjs +99 -2
package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js
CHANGED
|
@@ -9,13 +9,16 @@ import { listboxHeaderHeight as s, listboxOptionFontSize as c, listboxOptionHeig
|
|
|
9
9
|
import { isNotNil as u } from "../../utilities/functions/isNotNil.js";
|
|
10
10
|
import { useListboxFocus as d } from "../../composables/useListboxFocus.js";
|
|
11
11
|
import { indexBy as f } from "../../utilities/functions/indexBy.js";
|
|
12
|
-
import { Fragment as p, computed as m, createBlock as h, createCommentVNode as g, createElementBlock as _, createElementVNode as v, createTextVNode as y, createVNode as ee, defineComponent as b, mergeProps as x, nextTick as te, normalizeClass as
|
|
13
|
-
import { useVirtualizer as
|
|
12
|
+
import { Fragment as p, computed as m, createBlock as h, createCommentVNode as g, createElementBlock as _, createElementVNode as v, createTextVNode as y, createVNode as ee, defineComponent as b, mergeProps as x, nextTick as te, normalizeClass as S, normalizeStyle as C, openBlock as w, ref as ne, renderList as T, renderSlot as E, toDisplayString as D, unref as O, useId as re, useSlots as ie, useTemplateRef as k, watch as A, withModifiers as j } from "vue";
|
|
13
|
+
import { useVirtualizer as ae } from "@tanstack/vue-virtual";
|
|
14
14
|
//#region src/components/GroupedListBox/GroupedListBox.vue?vue&type=script&setup=true&lang.ts
|
|
15
|
-
var
|
|
15
|
+
var oe = { class: "bb-listbox__outer-container scrollbar-border" }, se = {
|
|
16
16
|
ref: "inner",
|
|
17
17
|
class: "bb-listbox__inner-container",
|
|
18
18
|
tabindex: "-1"
|
|
19
|
+
}, ce = {
|
|
20
|
+
class: "bb-listbox__status",
|
|
21
|
+
role: "status"
|
|
19
22
|
}, le = {
|
|
20
23
|
key: 0,
|
|
21
24
|
class: "bb-listbox__loading"
|
|
@@ -42,9 +45,9 @@ var se = { class: "bb-listbox__outer-container scrollbar-border" }, ce = {
|
|
|
42
45
|
key: 0,
|
|
43
46
|
class: "bb-listbox__option-content"
|
|
44
47
|
}, _e = ["id"], ve = ["id"], ye = {
|
|
45
|
-
key:
|
|
48
|
+
key: 1,
|
|
46
49
|
class: "bb-listbox__loading bb-listbox__loading--below"
|
|
47
|
-
}, be = ["id"], xe = { class: "bb-listbox__failed-text" },
|
|
50
|
+
}, be = ["id"], xe = { class: "bb-listbox__failed-text" }, M = /*@__PURE__*/ b({
|
|
48
51
|
__name: "GroupedListBox",
|
|
49
52
|
props: {
|
|
50
53
|
passthrough: {},
|
|
@@ -70,11 +73,11 @@ var se = { class: "bb-listbox__outer-container scrollbar-border" }, ce = {
|
|
|
70
73
|
"option:unselected",
|
|
71
74
|
"focused:change"
|
|
72
75
|
],
|
|
73
|
-
setup(t, { expose: b, emit:
|
|
74
|
-
let
|
|
76
|
+
setup(t, { expose: b, emit: M }) {
|
|
77
|
+
let N = t, P = M, Se = ie(), { t: F } = r(), I = k("inner"), Ce = k("listbox"), { touch: L } = n(), R = m(() => N.optionHeight ? N.optionHeight : l(L.value, !!N.compact, !!N.described)), z = m(() => N.headerHeight ? N.headerHeight : s(L.value, !!N.compact)), we = m(() => c(L.value)), B = (t) => e(N.groups[t].data) ? 0 : z.value, Te = m(() => {
|
|
75
78
|
let t = 0;
|
|
76
|
-
return
|
|
77
|
-
let i = n.id, a = t, o = n.options.length, s =
|
|
79
|
+
return N.groups.map((n, r) => {
|
|
80
|
+
let i = n.id, a = t, o = n.options.length, s = X(r), c = e(n.data) ? void 0 : `${W}-group-header-${n.id}`, l = typeof n.data == "string" ? n.data : e(n.data) ? "" : JSON.stringify(n.data), u = n.options.every((e) => e.disabled), d = n.data, f = n.options;
|
|
78
81
|
return t += o, {
|
|
79
82
|
offset: a,
|
|
80
83
|
length: o,
|
|
@@ -88,15 +91,15 @@ var se = { class: "bb-listbox__outer-container scrollbar-border" }, ce = {
|
|
|
88
91
|
options: f
|
|
89
92
|
};
|
|
90
93
|
});
|
|
91
|
-
}),
|
|
94
|
+
}), V = m(() => f(Te.value, "index")), H = m(() => {
|
|
92
95
|
let e = /* @__PURE__ */ new Map();
|
|
93
|
-
return
|
|
96
|
+
return N.groups.flatMap((t, n) => t.options.map((r, i) => {
|
|
94
97
|
let a = r.valueHash, o = Ee(`${t.id}-${r.valueHash}`), s = (e.get(o) ?? 0) + 1;
|
|
95
98
|
e.set(o, s);
|
|
96
99
|
let c = s === 1 ? o : `${o}-${s}`;
|
|
97
100
|
return {
|
|
98
101
|
id: a,
|
|
99
|
-
globalIndex:
|
|
102
|
+
globalIndex: V.value[n].offset + i,
|
|
100
103
|
groupIndex: n,
|
|
101
104
|
groupId: t.id,
|
|
102
105
|
indexInGroup: i,
|
|
@@ -112,52 +115,52 @@ var se = { class: "bb-listbox__outer-container scrollbar-border" }, ce = {
|
|
|
112
115
|
domId: c
|
|
113
116
|
};
|
|
114
117
|
}));
|
|
115
|
-
}),
|
|
116
|
-
let e =
|
|
117
|
-
for (let t of
|
|
118
|
+
}), U = m(() => {
|
|
119
|
+
let e = N.groups.map(() => []);
|
|
120
|
+
for (let t of H.value) e[t.groupIndex].push(t);
|
|
118
121
|
return e;
|
|
119
|
-
}),
|
|
120
|
-
if (e(
|
|
121
|
-
let t =
|
|
122
|
+
}), W = re(), Ee = (e) => `${W}-listbox-option-${e}`, G = (e) => `${e}__label`, K = (e) => `${e}__description`, q = (e) => !!e && !Se.option, J = m(() => {
|
|
123
|
+
if (e(Q.value)) return;
|
|
124
|
+
let t = H.value[Q.value];
|
|
122
125
|
if (t) return t.domId;
|
|
123
|
-
}),
|
|
124
|
-
function
|
|
125
|
-
return
|
|
126
|
+
}), Y = m(() => H.value.length > 0);
|
|
127
|
+
function X(e) {
|
|
128
|
+
return B(e) + N.groups[e].options.length * R.value;
|
|
126
129
|
}
|
|
127
|
-
let
|
|
130
|
+
let Z = ae({
|
|
128
131
|
get count() {
|
|
129
|
-
return
|
|
132
|
+
return N.groups.length;
|
|
130
133
|
},
|
|
131
|
-
getScrollElement: () =>
|
|
132
|
-
estimateSize: (e) =>
|
|
134
|
+
getScrollElement: () => I.value ?? null,
|
|
135
|
+
estimateSize: (e) => X(e),
|
|
133
136
|
overscan: 2
|
|
134
|
-
}), De = m(() =>
|
|
135
|
-
if (!
|
|
136
|
-
let t =
|
|
137
|
-
u(t) && (
|
|
138
|
-
let n =
|
|
137
|
+
}), De = m(() => Z.value.getVirtualItems()), Oe = m(() => Z.value.getTotalSize()), { focusedIndex: Q, focusNext: ke, focusPrevious: Ae, focusFirst: je, focusLast: Me, focusFirstSelected: Ne, focusLastSelected: Pe, focusByHash: Fe, focusByPointer: Ie, blurPointerFocus: Le, blur: Re, getHighlighted: ze } = d(m(() => H.value), { disabled: () => !N.open }), $ = ne(!1), Be = async () => {
|
|
138
|
+
if (!I.value || e(Q.value)) return;
|
|
139
|
+
let t = H.value[Q.value]?.groupIndex;
|
|
140
|
+
u(t) && (Z.value.scrollToIndex(t, { align: "auto" }), await te());
|
|
141
|
+
let n = I.value.querySelector(`[data-index="${Q.value}"]`);
|
|
139
142
|
n && n.scrollIntoView({ block: "nearest" });
|
|
140
143
|
};
|
|
141
|
-
|
|
142
|
-
$.value ||
|
|
144
|
+
A(Q, () => {
|
|
145
|
+
$.value || Be(), $.value = !1, P("focused:change", J.value);
|
|
143
146
|
});
|
|
144
|
-
let
|
|
145
|
-
let e =
|
|
146
|
-
if (!e) return
|
|
147
|
-
|
|
148
|
-
let t =
|
|
149
|
-
t &&
|
|
147
|
+
let Ve = () => Z.value.scrollToOffset(0), He = () => {
|
|
148
|
+
let e = H.value.find((e) => e.selected);
|
|
149
|
+
if (!e) return Ve();
|
|
150
|
+
Z.value.getTotalSize();
|
|
151
|
+
let t = Z.value.measurementsCache[e.groupIndex];
|
|
152
|
+
t && Z.value.scrollToOffset(t.start + B(e.groupIndex) + e.indexInGroup * R.value);
|
|
150
153
|
};
|
|
151
|
-
|
|
152
|
-
e &&
|
|
154
|
+
A(() => N.open && !!I.value, (e) => {
|
|
155
|
+
e && He();
|
|
153
156
|
}, { flush: "post" });
|
|
154
|
-
let
|
|
155
|
-
|
|
156
|
-
}, Ue = () => {
|
|
157
|
-
Le();
|
|
157
|
+
let Ue = (e) => {
|
|
158
|
+
N.open && ($.value = !0, Ie(e));
|
|
158
159
|
}, We = () => {
|
|
159
|
-
|
|
160
|
-
|
|
160
|
+
Le();
|
|
161
|
+
}, Ge = () => {
|
|
162
|
+
if (e(Q.value) || !N.open) return;
|
|
163
|
+
let t = H.value[Q.value];
|
|
161
164
|
if (!t || t.disabled) return;
|
|
162
165
|
let n = {
|
|
163
166
|
text: t.text,
|
|
@@ -167,21 +170,21 @@ var se = { class: "bb-listbox__outer-container scrollbar-border" }, ce = {
|
|
|
167
170
|
selected: t.selected,
|
|
168
171
|
disabled: t.disabled
|
|
169
172
|
};
|
|
170
|
-
t.selected ?
|
|
171
|
-
},
|
|
172
|
-
if (t.preventDefault(),
|
|
173
|
+
t.selected ? P("option:unselected", n) : P("option:selected", n);
|
|
174
|
+
}, Ke = (t) => {
|
|
175
|
+
if (t.preventDefault(), I.value && t.target instanceof HTMLElement && Ce.value) {
|
|
173
176
|
let n = t.target, r = n.dataset.index;
|
|
174
177
|
for (; e(r) && n.parentElement;) n = n.parentElement, r = n.dataset.index;
|
|
175
178
|
if (r) {
|
|
176
|
-
let e =
|
|
177
|
-
e && !e.disabled && (
|
|
179
|
+
let e = H.value[+r];
|
|
180
|
+
e && !e.disabled && (Q.value = +r, Ge());
|
|
178
181
|
}
|
|
179
182
|
}
|
|
180
183
|
};
|
|
181
|
-
return
|
|
182
|
-
e.flatMap((e) => [e.id, ...e.options.map((e) => e.valueHash)]).join(",") !== t.flatMap((e) => [e.id, ...e.options.map((e) => e.valueHash)]).join(",") && (
|
|
183
|
-
}, { flush: "post" }),
|
|
184
|
-
|
|
184
|
+
return A(() => N.groups, (e, t) => {
|
|
185
|
+
e.flatMap((e) => [e.id, ...e.options.map((e) => e.valueHash)]).join(",") !== t.flatMap((e) => [e.id, ...e.options.map((e) => e.valueHash)]).join(",") && (Z.value.measure(), Re());
|
|
186
|
+
}, { flush: "post" }), A([R, z], () => {
|
|
187
|
+
Z.value.measure();
|
|
185
188
|
}, { flush: "post" }), b({
|
|
186
189
|
focusNext: ke,
|
|
187
190
|
focusPrevious: Ae,
|
|
@@ -189,39 +192,39 @@ var se = { class: "bb-listbox__outer-container scrollbar-border" }, ce = {
|
|
|
189
192
|
focusFirstSelected: Ne,
|
|
190
193
|
focusLast: Me,
|
|
191
194
|
focusLastSelected: Pe,
|
|
192
|
-
blur:
|
|
193
|
-
confirmOption:
|
|
195
|
+
blur: Re,
|
|
196
|
+
confirmOption: Ge,
|
|
194
197
|
focusByHash: Fe,
|
|
195
|
-
getHighlighted:
|
|
196
|
-
getActiveDescendantId: () =>
|
|
197
|
-
scrollToTop:
|
|
198
|
-
scrollToSelected:
|
|
199
|
-
}), (e, t) => (
|
|
200
|
-
class:
|
|
198
|
+
getHighlighted: ze,
|
|
199
|
+
getActiveDescendantId: () => J.value,
|
|
200
|
+
scrollToTop: Ve,
|
|
201
|
+
scrollToSelected: He
|
|
202
|
+
}), (e, t) => (w(), _("span", {
|
|
203
|
+
class: S(["bb-listbox bb-listbox--grouped", {
|
|
201
204
|
"bb-listbox--compact": e.compact,
|
|
202
205
|
"bb-listbox--described": e.described,
|
|
203
206
|
"bb-listbox--loading": e.loading,
|
|
204
207
|
"bb-listbox--multiple": e.multiple,
|
|
205
|
-
"bb-listbox--empty": !
|
|
208
|
+
"bb-listbox--empty": !Y.value,
|
|
206
209
|
"bb-listbox--open": e.open
|
|
207
210
|
}]),
|
|
208
|
-
style:
|
|
211
|
+
style: C({
|
|
209
212
|
"--transition-duration": `${e.transitionDuration}ms`,
|
|
210
|
-
"--option-height": `${
|
|
211
|
-
"--group-header-height": `${
|
|
213
|
+
"--option-height": `${R.value}px`,
|
|
214
|
+
"--group-header-height": `${z.value}px`,
|
|
212
215
|
"--option-font-size": we.value
|
|
213
216
|
}),
|
|
214
|
-
onClickCapture:
|
|
215
|
-
onClick: t[0] ||=
|
|
216
|
-
onMousedown: t[1] ||=
|
|
217
|
-
}, [v("span",
|
|
218
|
-
|
|
219
|
-
e.loading && !
|
|
220
|
-
|
|
221
|
-
key:
|
|
217
|
+
onClickCapture: Ke,
|
|
218
|
+
onClick: t[0] ||= j(() => {}, ["stop"]),
|
|
219
|
+
onMousedown: t[1] ||= j(() => {}, ["prevent"])
|
|
220
|
+
}, [v("span", oe, [v("span", se, [
|
|
221
|
+
E(e.$slots, "options:prepend"),
|
|
222
|
+
v("span", ce, [e.loading && !Y.value ? (w(), _("span", le, [E(e.$slots, "loading", {}, () => [y(D(e.loadingText || O(F)("common.loadingText").value), 1)])])) : !Y.value && !e.failedText ? (w(), _("span", ue, [E(e.$slots, "empty", {}, () => [y(D(e.emptyText || O(F)("common.emptyText").value), 1)])])) : g("", !0)]),
|
|
223
|
+
Y.value ? (w(), _("span", x({
|
|
224
|
+
key: 0,
|
|
222
225
|
id: e.id,
|
|
223
226
|
ref: "listbox",
|
|
224
|
-
"aria-activedescendant":
|
|
227
|
+
"aria-activedescendant": J.value,
|
|
225
228
|
"aria-label": e.listLabelledby ? void 0 : e.listLabel,
|
|
226
229
|
"aria-labelledby": e.listLabelledby,
|
|
227
230
|
"aria-multiselectable": e.multiple ? !0 : void 0,
|
|
@@ -229,113 +232,113 @@ var se = { class: "bb-listbox__outer-container scrollbar-border" }, ce = {
|
|
|
229
232
|
role: "listbox",
|
|
230
233
|
style: { height: `${Oe.value}px` },
|
|
231
234
|
tabindex: "-1",
|
|
232
|
-
onMouseleave:
|
|
233
|
-
}, e.passthrough?.list), [(
|
|
234
|
-
key:
|
|
235
|
-
"aria-disabled":
|
|
236
|
-
"aria-labelledby":
|
|
235
|
+
onMouseleave: We
|
|
236
|
+
}, e.passthrough?.list), [(w(!0), _(p, null, T(De.value, (t) => (w(), _("span", {
|
|
237
|
+
key: V.value[t.index].id,
|
|
238
|
+
"aria-disabled": V.value[t.index].allOptionsAreDisabled,
|
|
239
|
+
"aria-labelledby": V.value[t.index].headerId,
|
|
237
240
|
class: "bb-listbox__group",
|
|
238
241
|
role: "group",
|
|
239
|
-
style:
|
|
240
|
-
}, [
|
|
242
|
+
style: C({ transform: `translateY(${t.start}px)` })
|
|
243
|
+
}, [V.value[t.index].headerId ? (w(), _("span", {
|
|
241
244
|
key: 0,
|
|
242
|
-
id:
|
|
245
|
+
id: V.value[t.index].headerId,
|
|
243
246
|
class: "bb-listbox__group-header",
|
|
244
247
|
role: "presentation"
|
|
245
|
-
}, [
|
|
246
|
-
disabled:
|
|
248
|
+
}, [E(e.$slots, "group", {
|
|
249
|
+
disabled: V.value[t.index].allOptionsAreDisabled,
|
|
247
250
|
index: t.index,
|
|
248
|
-
item:
|
|
249
|
-
length:
|
|
250
|
-
text:
|
|
251
|
-
}, () => [v("span", me,
|
|
252
|
-
id:
|
|
251
|
+
item: V.value[t.index].data,
|
|
252
|
+
length: V.value[t.index].length,
|
|
253
|
+
text: V.value[t.index].label
|
|
254
|
+
}, () => [v("span", me, D(V.value[t.index].label), 1)])], 8, pe)) : g("", !0), (w(!0), _(p, null, T(V.value[t.index].options, (n, r) => (w(), _("span", x({
|
|
255
|
+
id: U.value[t.index][r].domId,
|
|
253
256
|
key: n.valueHash,
|
|
254
|
-
"aria-describedby":
|
|
255
|
-
"aria-disabled":
|
|
256
|
-
"aria-labelledby":
|
|
257
|
-
"aria-posinset":
|
|
258
|
-
"aria-selected":
|
|
259
|
-
"aria-setsize":
|
|
257
|
+
"aria-describedby": q(U.value[t.index][r].description) ? K(U.value[t.index][r].domId) : void 0,
|
|
258
|
+
"aria-disabled": U.value[t.index][r].disabled ? !0 : void 0,
|
|
259
|
+
"aria-labelledby": q(U.value[t.index][r].description) ? G(U.value[t.index][r].domId) : void 0,
|
|
260
|
+
"aria-posinset": U.value[t.index][r].indexInGroup + 1,
|
|
261
|
+
"aria-selected": U.value[t.index][r].selected,
|
|
262
|
+
"aria-setsize": V.value[t.index].length,
|
|
260
263
|
class: ["bb-listbox__option", {
|
|
261
|
-
"bb-listbox__option--focused":
|
|
262
|
-
"bb-listbox__option--selected":
|
|
263
|
-
"bb-listbox__option--disabled":
|
|
264
|
+
"bb-listbox__option--focused": O(Q) === U.value[t.index][r].globalIndex,
|
|
265
|
+
"bb-listbox__option--selected": U.value[t.index][r].selected,
|
|
266
|
+
"bb-listbox__option--disabled": U.value[t.index][r].disabled
|
|
264
267
|
}],
|
|
265
|
-
"data-index":
|
|
268
|
+
"data-index": U.value[t.index][r].globalIndex,
|
|
266
269
|
role: "option",
|
|
267
|
-
onMouseenter:
|
|
270
|
+
onMouseenter: j((e) => Ue(U.value[t.index][r].globalIndex), ["stop"]),
|
|
268
271
|
ref_for: !0
|
|
269
272
|
}, e.passthrough?.part?.("option", {
|
|
270
|
-
selected:
|
|
271
|
-
disabled:
|
|
272
|
-
},
|
|
273
|
-
|
|
273
|
+
selected: U.value[t.index][r].selected,
|
|
274
|
+
disabled: U.value[t.index][r].disabled || void 0
|
|
275
|
+
}, U.value[t.index][r].item)), [
|
|
276
|
+
U.value[t.index][r]["prepend:icon"] ? (w(), h(i, x({
|
|
274
277
|
key: 0,
|
|
275
278
|
"aria-hidden": "true",
|
|
276
279
|
class: "bb-listbox__item-icon bb-listbox__option-prepend-icon",
|
|
277
|
-
icon:
|
|
280
|
+
icon: U.value[t.index][r]["prepend:icon"],
|
|
278
281
|
ref_for: !0
|
|
279
282
|
}, e.passthrough?.part?.("itemIcon", {
|
|
280
|
-
selected:
|
|
281
|
-
disabled:
|
|
282
|
-
},
|
|
283
|
-
|
|
284
|
-
description:
|
|
285
|
-
disabled: !!
|
|
286
|
-
focused:
|
|
287
|
-
index:
|
|
288
|
-
item:
|
|
289
|
-
selected: !!
|
|
290
|
-
text:
|
|
291
|
-
value:
|
|
292
|
-
}, () => [
|
|
293
|
-
id:
|
|
283
|
+
selected: U.value[t.index][r].selected,
|
|
284
|
+
disabled: U.value[t.index][r].disabled || void 0
|
|
285
|
+
}, U.value[t.index][r].item)), null, 16, ["icon"])) : g("", !0),
|
|
286
|
+
E(e.$slots, "option", {
|
|
287
|
+
description: U.value[t.index][r].description,
|
|
288
|
+
disabled: !!U.value[t.index][r].disabled,
|
|
289
|
+
focused: O(Q) === U.value[t.index][r].globalIndex,
|
|
290
|
+
index: U.value[t.index][r].globalIndex,
|
|
291
|
+
item: U.value[t.index][r].item,
|
|
292
|
+
selected: !!U.value[t.index][r].selected,
|
|
293
|
+
text: U.value[t.index][r].text,
|
|
294
|
+
value: U.value[t.index][r].value
|
|
295
|
+
}, () => [U.value[t.index][r].description ? (w(), _("span", ge, [v("span", x({
|
|
296
|
+
id: G(U.value[t.index][r].domId),
|
|
294
297
|
class: "bb-listbox__item-text",
|
|
295
298
|
ref_for: !0
|
|
296
299
|
}, e.passthrough?.part?.("itemText", {
|
|
297
|
-
selected:
|
|
298
|
-
disabled:
|
|
299
|
-
},
|
|
300
|
-
id:
|
|
300
|
+
selected: U.value[t.index][r].selected,
|
|
301
|
+
disabled: U.value[t.index][r].disabled || void 0
|
|
302
|
+
}, U.value[t.index][r].item)), D(U.value[t.index][r].text), 17, _e), v("span", x({
|
|
303
|
+
id: K(U.value[t.index][r].domId),
|
|
301
304
|
class: "bb-listbox__item-description",
|
|
302
305
|
ref_for: !0
|
|
303
306
|
}, e.passthrough?.part?.("itemDescription", {
|
|
304
|
-
selected:
|
|
305
|
-
disabled:
|
|
306
|
-
},
|
|
307
|
+
selected: U.value[t.index][r].selected,
|
|
308
|
+
disabled: U.value[t.index][r].disabled || void 0
|
|
309
|
+
}, U.value[t.index][r].item)), D(U.value[t.index][r].description), 17, ve)])) : (w(), _("span", x({
|
|
307
310
|
key: 1,
|
|
308
311
|
class: "bb-listbox__item-text",
|
|
309
312
|
ref_for: !0
|
|
310
313
|
}, e.passthrough?.part?.("itemText", {
|
|
311
|
-
selected:
|
|
312
|
-
disabled:
|
|
313
|
-
},
|
|
314
|
-
|
|
314
|
+
selected: U.value[t.index][r].selected,
|
|
315
|
+
disabled: U.value[t.index][r].disabled || void 0
|
|
316
|
+
}, U.value[t.index][r].item)), D(U.value[t.index][r].text), 17))]),
|
|
317
|
+
U.value[t.index][r]["append:icon"] && !U.value[t.index][r].selected ? (w(), h(i, x({
|
|
315
318
|
key: 1,
|
|
316
319
|
"aria-hidden": "true",
|
|
317
320
|
class: "bb-listbox__item-icon bb-listbox__option-append-icon",
|
|
318
|
-
icon:
|
|
321
|
+
icon: U.value[t.index][r]["append:icon"],
|
|
319
322
|
ref_for: !0
|
|
320
323
|
}, e.passthrough?.part?.("itemIcon", {
|
|
321
|
-
selected:
|
|
322
|
-
disabled:
|
|
323
|
-
},
|
|
324
|
+
selected: U.value[t.index][r].selected,
|
|
325
|
+
disabled: U.value[t.index][r].disabled || void 0
|
|
326
|
+
}, U.value[t.index][r].item)), null, 16, ["icon"])) : g("", !0),
|
|
324
327
|
ee(i, {
|
|
325
328
|
"aria-hidden": "true",
|
|
326
329
|
class: "bb-listbox__option-check",
|
|
327
|
-
icon:
|
|
330
|
+
icon: O(o)
|
|
328
331
|
}, null, 8, ["icon"])
|
|
329
332
|
], 16, he))), 128))], 12, fe))), 128))], 16, de)) : g("", !0),
|
|
330
|
-
e.loading && e.loadingBelow &&
|
|
331
|
-
|
|
332
|
-
], 512)]), e.failedText ? (
|
|
333
|
+
e.loading && e.loadingBelow && Y.value ? (w(), _("span", ye, [E(e.$slots, "loading", {}, () => [y(D(e.loadingText || O(F)("common.loadingText").value), 1)])])) : g("", !0),
|
|
334
|
+
E(e.$slots, "options:append")
|
|
335
|
+
], 512)]), e.failedText ? (w(), _("span", {
|
|
333
336
|
key: 0,
|
|
334
337
|
id: `${e.id}_failed`,
|
|
335
|
-
class:
|
|
338
|
+
class: S(["bb-listbox__failed", { "bb-listbox__failed--divided": Y.value }]),
|
|
336
339
|
role: "status"
|
|
337
|
-
}, [ee(a, { class: "bb-listbox__failed-icon" }), v("span", xe, [
|
|
340
|
+
}, [ee(a, { class: "bb-listbox__failed-icon" }), v("span", xe, [E(e.$slots, "empty", {}, () => [y(D(e.failedText), 1)])])], 10, be)) : g("", !0)], 38));
|
|
338
341
|
}
|
|
339
342
|
});
|
|
340
343
|
//#endregion
|
|
341
|
-
export {
|
|
344
|
+
export { M as default };
|
package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js
CHANGED
|
@@ -12,6 +12,8 @@ var v = ["id"], y = ["id"], b = /*@__PURE__*/ l({
|
|
|
12
12
|
itemLabelAlign: {},
|
|
13
13
|
itemInputAlign: {},
|
|
14
14
|
listLayout: {},
|
|
15
|
+
variant: {},
|
|
16
|
+
indicatorReady: { type: Boolean },
|
|
15
17
|
hasErrors: { type: Boolean },
|
|
16
18
|
hasWarnings: { type: Boolean },
|
|
17
19
|
hideLabel: { type: Boolean },
|
|
@@ -67,7 +69,10 @@ var v = ["id"], y = ["id"], b = /*@__PURE__*/ l({
|
|
|
67
69
|
return (e, t) => (f(), o("span", u({ class: [C.value.root, {
|
|
68
70
|
[`${C.value.root}--errors`]: e.hasErrors,
|
|
69
71
|
[`${C.value.root}--warnings`]: x.value,
|
|
70
|
-
[`${C.value.root}--${w.value}`]: !0
|
|
72
|
+
[`${C.value.root}--${w.value}`]: !0,
|
|
73
|
+
[`${C.value.root}--strip`]: !!e.variant,
|
|
74
|
+
[`${C.value.root}--${e.variant}`]: !!e.variant,
|
|
75
|
+
[`${C.value.root}--no-transition`]: !!e.variant && !e.indicatorReady
|
|
71
76
|
}] }, e.passthrough?.list), [
|
|
72
77
|
h(e.$slots, "prepend"),
|
|
73
78
|
!e.options.length && e.loading ? (f(), o("span", {
|
|
@@ -97,7 +102,7 @@ var v = ["id"], y = ["id"], b = /*@__PURE__*/ l({
|
|
|
97
102
|
h(e.$slots, "input", {
|
|
98
103
|
descriptionId: t.description ? P(n) : void 0,
|
|
99
104
|
index: n,
|
|
100
|
-
labelId:
|
|
105
|
+
labelId: N(n),
|
|
101
106
|
option: t,
|
|
102
107
|
rowStates: B(t, n)
|
|
103
108
|
}),
|
|
@@ -34,6 +34,17 @@ export type OptionsContainerProps<T = any> = {
|
|
|
34
34
|
* @defaultValue `'horizontal'`
|
|
35
35
|
*/
|
|
36
36
|
listLayout?: ListLayout;
|
|
37
|
+
/**
|
|
38
|
+
* A tab-strip look on the list (Q76.11 d): `--strip` plus the variant's
|
|
39
|
+
* class hook (`--pill`, `--line`, a registered name), the strip and its
|
|
40
|
+
* triggers (choice-strip.css). The owning group renders the indicators.
|
|
41
|
+
*/
|
|
42
|
+
variant?: string;
|
|
43
|
+
/**
|
|
44
|
+
* With a `variant`: the indicators have been measured and painted, so they
|
|
45
|
+
* may transition. Until then the list is `--no-transition`.
|
|
46
|
+
*/
|
|
47
|
+
indicatorReady?: boolean;
|
|
37
48
|
/**
|
|
38
49
|
* Define if the component should be in an error state.
|
|
39
50
|
* It usually attaches a CSS class for styling purposes.
|
|
@@ -92,10 +103,10 @@ export type OptionsContainerInputSlotProps<T = any> = {
|
|
|
92
103
|
/** The full internal Option object for this row. */
|
|
93
104
|
option: Option<T>;
|
|
94
105
|
/**
|
|
95
|
-
* Id of the row's text
|
|
96
|
-
*
|
|
106
|
+
* Id of the row's text. Pass as `aria-labelledby` so the `icon` slot and the
|
|
107
|
+
* description stay out of the input's name.
|
|
97
108
|
*/
|
|
98
|
-
labelId: string
|
|
109
|
+
labelId: string;
|
|
99
110
|
/**
|
|
100
111
|
* Id of the row's description, set only when it has one. Add it to the
|
|
101
112
|
* input's `aria-describedby` (see `withItemDescribedby`).
|
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
import { useConfig as e } from "./useConfig.js";
|
|
2
|
-
import {
|
|
2
|
+
import { computed as t } from "vue";
|
|
3
|
+
import { config as n } from "virtual:bitboss-ui/config";
|
|
3
4
|
//#region src/composables/useBbConfig.ts
|
|
4
|
-
var
|
|
5
|
-
let
|
|
6
|
-
return {
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
var r = () => {
|
|
6
|
+
let r = e(), i = r === n;
|
|
7
|
+
return {
|
|
8
|
+
setConfig: (e) => {
|
|
9
|
+
process.env.NODE_ENV !== "production" && i && typeof window > "u" && console.warn("[bitboss-ui] setConfig() wrote the process-global defaults rather than one app, during a SERVER render — that leaks into other visitors being served concurrently. This app has no per-app config to write to, which means either the call is outside any app context, or the library plugin was never installed on it. Fix, by framework: Vue/Inertia — pass per-request values where the app is created, `app.use(bitbossUiPlugin, { locale })`. Nuxt — the module provides the config for you, so call setConfig from a component, or from your own Nuxt plugin inside `nuxtApp.vueApp.runWithContext(() => …)`; if this still fires, the bitboss-ui Nuxt module is not registered in `modules`."), Object.assign(r, e);
|
|
10
|
+
},
|
|
11
|
+
locale: t(() => r.locale)
|
|
12
|
+
};
|
|
9
13
|
};
|
|
10
14
|
//#endregion
|
|
11
|
-
export {
|
|
15
|
+
export { r as useBbConfig };
|
|
@@ -181,9 +181,10 @@ export type BbFormContextHandle = {
|
|
|
181
181
|
* (`setErrors({ ...body.errors, _request: [body.message] })`). A message
|
|
182
182
|
* you take back yourself (your own cross-field check) belongs in BbForm's
|
|
183
183
|
* `field-errors`, computed.
|
|
184
|
-
* Returns nothing
|
|
185
|
-
*
|
|
186
|
-
*
|
|
184
|
+
* Returns nothing; a non-empty map emits BbForm's `invalid` with
|
|
185
|
+
* `source: 'server'` (before any focus), and `fields` / `unmatchedErrors`
|
|
186
|
+
* hold the same answer afterwards (to jump to the step that holds an
|
|
187
|
+
* error, or show a summary). It moves focus to the first
|
|
187
188
|
* field that got an error and is on screen, like a failed submit — unless
|
|
188
189
|
* focus has left the form meanwhile, or the form was never submitted and
|
|
189
190
|
* focus is on `<body>`; `{ focus: false }` turns it off. No-op until the
|