bitboss-ui 3.0.0-beta.70 → 3.0.0-beta.72

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.
Files changed (413) hide show
  1. package/README.md +2 -2
  2. package/bin/cli.mjs +6 -1
  3. package/dist/ai/BbAccordion.md +38 -19
  4. package/dist/ai/BbBadge.md +25 -22
  5. package/dist/ai/BbBreadcrumbs.md +4 -1
  6. package/dist/ai/BbButton.md +32 -27
  7. package/dist/ai/BbCalendar.md +1 -0
  8. package/dist/ai/BbCarousel.md +6 -4
  9. package/dist/ai/BbCheckbox.md +5 -6
  10. package/dist/ai/BbCheckboxGroup.md +27 -27
  11. package/dist/ai/BbColorInput.md +4 -5
  12. package/dist/ai/BbConfirm.md +65 -81
  13. package/dist/ai/BbConfirmPortal.md +2 -2
  14. package/dist/ai/BbDatePicker.md +1 -6
  15. package/dist/ai/BbDatePickerInput.md +5 -6
  16. package/dist/ai/BbDialog.md +230 -164
  17. package/dist/ai/BbDropdown.md +87 -17
  18. package/dist/ai/BbDropdownButton.md +15 -15
  19. package/dist/ai/BbDropzone.md +12 -8
  20. package/dist/ai/BbForm.md +93 -7
  21. package/dist/ai/BbHost.md +2 -2
  22. package/dist/ai/BbHoverCardPortal.md +1 -1
  23. package/dist/ai/BbIcon.md +1 -1
  24. package/dist/ai/BbIndicator.md +17 -15
  25. package/dist/ai/BbNumberInput.md +10 -9
  26. package/dist/ai/BbOffCanvas.md +29 -7
  27. package/dist/ai/BbPagination.md +2 -2
  28. package/dist/ai/BbPopover.md +15 -9
  29. package/dist/ai/BbPopoverPortal.md +1 -1
  30. package/dist/ai/BbRadio.md +5 -6
  31. package/dist/ai/BbRadioGroup.md +53 -37
  32. package/dist/ai/BbRating.md +11 -16
  33. package/dist/ai/BbSelect.md +25 -5
  34. package/dist/ai/BbSelectPopover.md +9 -3
  35. package/dist/ai/BbSlider.md +15 -17
  36. package/dist/ai/BbSpinner.md +3 -2
  37. package/dist/ai/BbSwitch.md +9 -9
  38. package/dist/ai/BbSwitchGroup.md +11 -13
  39. package/dist/ai/BbTable.md +205 -82
  40. package/dist/ai/BbTabs.md +29 -4
  41. package/dist/ai/BbTag.md +4 -5
  42. package/dist/ai/BbTextInput.md +18 -16
  43. package/dist/ai/BbTextarea.md +12 -11
  44. package/dist/ai/BbTimePickerInput.md +4 -5
  45. package/dist/ai/BbToast.md +3 -2
  46. package/dist/ai/BbTooltip.md +39 -30
  47. package/dist/ai/BbTree.md +49 -24
  48. package/dist/ai/CommonField.md +2 -10
  49. package/dist/ai/CommonFieldInput.md +1 -1
  50. package/dist/ai/OptionsContainer.md +5 -13
  51. package/dist/ai/changelog.json +278 -10
  52. package/dist/ai/components.json +59 -58
  53. package/dist/ai/composables/useBbDialog.md +5 -8
  54. package/dist/ai/composables/useBbForm.md +3 -0
  55. package/dist/ai/composables/useConfirm.md +65 -56
  56. package/dist/ai/composables/useToast.md +2 -1
  57. package/dist/ai/guides/agent-contract.md +3 -3
  58. package/dist/ai/guides/app-layout.md +3 -2
  59. package/dist/ai/guides/eslint-rules.md +3 -1
  60. package/dist/ai/guides/fetch-items-playbook.md +1 -1
  61. package/dist/ai/guides/floating-bottom-panel.md +3 -2
  62. package/dist/ai/guides/icons-policy.md +7 -5
  63. package/dist/ai/guides/inertia-helpers.md +35 -30
  64. package/dist/ai/guides/installation-and-plugin-setup.md +17 -14
  65. package/dist/ai/guides/migration/adoption-checklist.md +2 -2
  66. package/dist/ai/guides/migration/components/bb-badge.md +12 -1
  67. package/dist/ai/guides/migration/components/bb-button.md +24 -0
  68. package/dist/ai/guides/migration/components/bb-dropdown-button.md +11 -0
  69. package/dist/ai/guides/migration/components/bb-tabs.md +2 -2
  70. package/dist/ai/guides/migration/components/bb-toast.md +11 -0
  71. package/dist/ai/guides/migration/components/use-confirm.md +69 -26
  72. package/dist/ai/guides/migration/v2-to-v3.md +78 -12
  73. package/dist/ai/guides/migration/v3-beta-css-classes.md +1 -1
  74. package/dist/ai/guides/options-items-playbook.md +4 -3
  75. package/dist/ai/guides/passthrough.md +2 -2
  76. package/dist/ai/guides/preset-components.md +35 -10
  77. package/dist/ai/helpers/definePreset.json +8 -1
  78. package/dist/ai/helpers/definePreset.ts +35 -10
  79. package/dist/ai/helpers/inertia/manifest.json +28 -15
  80. package/dist/ai/helpers/inertia/messages.ts +3 -3
  81. package/dist/ai/helpers/inertia/useConfirmOnRouteLeave.ts +10 -10
  82. package/dist/ai/helpers/inertia/usePromiseForm.ts +1 -1
  83. package/dist/ai/helpers/inertia/usePromiseRouter.ts +7 -2
  84. package/dist/ai/index.md +3 -3
  85. package/dist/ai/manifest/common.json +5 -5
  86. package/dist/ai/manifest/components/BbAccordion.json +8 -5
  87. package/dist/ai/manifest/components/BbAccordion.tree.json +1 -0
  88. package/dist/ai/manifest/components/BbBadge.json +8 -7
  89. package/dist/ai/manifest/components/BbBadge.removed.json +3 -1
  90. package/dist/ai/manifest/components/BbBadge.tree.json +73 -0
  91. package/dist/ai/manifest/components/BbBreadcrumbs.json +2 -2
  92. package/dist/ai/manifest/components/BbButton.json +5 -6
  93. package/dist/ai/manifest/components/BbButton.removed.json +3 -1
  94. package/dist/ai/manifest/components/BbButton.tree.json +24 -7
  95. package/dist/ai/manifest/components/BbCalendar.json +2 -1
  96. package/dist/ai/manifest/components/BbCheckbox.json +2 -2
  97. package/dist/ai/manifest/components/BbCheckbox.tree.json +1 -1
  98. package/dist/ai/manifest/components/BbCheckboxGroup.json +2 -2
  99. package/dist/ai/manifest/components/BbCheckboxGroup.tree.json +9 -19
  100. package/dist/ai/manifest/components/BbColorInput.json +3 -3
  101. package/dist/ai/manifest/components/BbColorInput.tree.json +2 -2
  102. package/dist/ai/manifest/components/BbConfirm.json +2 -2
  103. package/dist/ai/manifest/components/BbConfirm.removed.json +9 -0
  104. package/dist/ai/manifest/components/BbConfirm.tree.json +4 -5
  105. package/dist/ai/manifest/components/BbConfirmPortal.json +3 -3
  106. package/dist/ai/manifest/components/BbConfirmPortal.removed.json +7 -0
  107. package/dist/ai/manifest/components/BbDatePicker.json +2 -1
  108. package/dist/ai/manifest/components/BbDatePicker.tree.json +0 -6
  109. package/dist/ai/manifest/components/BbDatePickerInput.json +2 -2
  110. package/dist/ai/manifest/components/BbDatePickerInput.tree.json +2 -2
  111. package/dist/ai/manifest/components/BbDialog.json +6 -1
  112. package/dist/ai/manifest/components/BbDialog.tree.json +41 -1
  113. package/dist/ai/manifest/components/BbDropdown.json +10 -9
  114. package/dist/ai/manifest/components/BbDropdown.tree.json +4 -0
  115. package/dist/ai/manifest/components/BbDropdownButton.json +9 -10
  116. package/dist/ai/manifest/components/BbDropdownButton.removed.json +3 -1
  117. package/dist/ai/manifest/components/BbForm.json +3 -1
  118. package/dist/ai/manifest/components/BbNumberInput.json +1 -1
  119. package/dist/ai/manifest/components/BbNumberInput.tree.json +2 -2
  120. package/dist/ai/manifest/components/BbOffCanvas.json +6 -1
  121. package/dist/ai/manifest/components/BbOffCanvas.tree.json +40 -0
  122. package/dist/ai/manifest/components/BbPagination.json +1 -1
  123. package/dist/ai/manifest/components/BbRadio.tree.json +1 -1
  124. package/dist/ai/manifest/components/BbRadioGroup.json +4 -3
  125. package/dist/ai/manifest/components/BbRadioGroup.tree.json +8 -18
  126. package/dist/ai/manifest/components/BbRating.json +2 -2
  127. package/dist/ai/manifest/components/BbRating.tree.json +1 -1
  128. package/dist/ai/manifest/components/BbSelect.json +2 -1
  129. package/dist/ai/manifest/components/BbSelect.tree.json +2 -2
  130. package/dist/ai/manifest/components/BbSelectPopover.json +1 -0
  131. package/dist/ai/manifest/components/BbSlider.tree.json +1 -1
  132. package/dist/ai/manifest/components/BbSwitch.json +4 -4
  133. package/dist/ai/manifest/components/BbSwitch.tree.json +1 -1
  134. package/dist/ai/manifest/components/BbSwitchGroup.json +7 -7
  135. package/dist/ai/manifest/components/BbSwitchGroup.tree.json +2 -2
  136. package/dist/ai/manifest/components/BbTable.json +15 -14
  137. package/dist/ai/manifest/components/BbTable.tree.json +2 -0
  138. package/dist/ai/manifest/components/BbTabs.json +3 -3
  139. package/dist/ai/manifest/components/BbTabsList.json +1 -1
  140. package/dist/ai/manifest/components/BbTabsRoot.json +1 -1
  141. package/dist/ai/manifest/components/BbTag.json +1 -1
  142. package/dist/ai/manifest/components/BbTag.tree.json +2 -2
  143. package/dist/ai/manifest/components/BbTextInput.json +1 -1
  144. package/dist/ai/manifest/components/BbTextInput.tree.json +2 -2
  145. package/dist/ai/manifest/components/BbTextarea.json +1 -1
  146. package/dist/ai/manifest/components/BbTextarea.tree.json +2 -2
  147. package/dist/ai/manifest/components/BbTimePicker.json +1 -1
  148. package/dist/ai/manifest/components/BbTimePickerInput.json +1 -1
  149. package/dist/ai/manifest/components/BbTimePickerInput.tree.json +2 -2
  150. package/dist/ai/manifest/components/BbToast.removed.json +2 -1
  151. package/dist/ai/manifest/components/BbTooltip.json +1 -1
  152. package/dist/ai/manifest/components/BbTooltip.tree.json +2 -2
  153. package/dist/ai/manifest/components/BbTree.json +2 -2
  154. package/dist/ai/manifest/components/CommonField.tree.json +5 -10
  155. package/dist/ai/manifest/components/CommonFieldInput.tree.json +3 -3
  156. package/dist/ai/manifest/components/OptionsContainer.tree.json +5 -13
  157. package/dist/ai/manifest/index.json +4 -4
  158. package/dist/ai/manifest/meta.json +5 -1
  159. package/dist/ai/manifest/types.advanced.json +9 -9
  160. package/dist/ai/manifest/types.api.json +7 -6
  161. package/dist/ai/recipes/inertia/approvals-inbox.md +23 -16
  162. package/dist/ai/recipes/inertia/inline-edit-workspace.md +12 -5
  163. package/dist/ai/recipes/inertia/layout-scaffold.md +5 -3
  164. package/dist/ai/recipes/inertia/onboarding.md +23 -12
  165. package/dist/ai/recipes/inertia/ownership-atlas.md +34 -18
  166. package/dist/ai/recipes/inertia/record-form.md +12 -8
  167. package/dist/ai/recipes/inertia/records-workspace.md +14 -7
  168. package/dist/ai/recipes/inertia/settings-workspace.md +75 -60
  169. package/dist/ai/recipes/inertia/upload-center.md +17 -9
  170. package/dist/ai/recipes/inertia/wizard-form.md +2 -2
  171. package/dist/ai/recipes/nuxt/approvals-inbox.md +23 -16
  172. package/dist/ai/recipes/nuxt/inline-edit-workspace.md +12 -5
  173. package/dist/ai/recipes/nuxt/layout-scaffold.md +5 -3
  174. package/dist/ai/recipes/nuxt/onboarding.md +5 -4
  175. package/dist/ai/recipes/nuxt/ownership-atlas.md +34 -18
  176. package/dist/ai/recipes/nuxt/record-form.md +14 -10
  177. package/dist/ai/recipes/nuxt/records-workspace.md +14 -7
  178. package/dist/ai/recipes/nuxt/settings-workspace.md +70 -60
  179. package/dist/ai/recipes/nuxt/upload-center.md +17 -9
  180. package/dist/ai/recipes/nuxt/wizard-form.md +4 -4
  181. package/dist/ai/recipes/vue/approvals-inbox.md +23 -16
  182. package/dist/ai/recipes/vue/inline-edit-workspace.md +12 -5
  183. package/dist/ai/recipes/vue/layout-scaffold.md +5 -3
  184. package/dist/ai/recipes/vue/onboarding.md +5 -4
  185. package/dist/ai/recipes/vue/ownership-atlas.md +34 -18
  186. package/dist/ai/recipes/vue/record-form.md +14 -10
  187. package/dist/ai/recipes/vue/records-workspace.md +14 -7
  188. package/dist/ai/recipes/vue/settings-workspace.md +70 -60
  189. package/dist/ai/recipes/vue/upload-center.md +17 -9
  190. package/dist/ai/recipes/vue/wizard-form.md +4 -4
  191. package/dist/ai/source/BbAccordion.md +50 -16
  192. package/dist/ai/source/BbBadge.md +420 -26
  193. package/dist/ai/source/BbBadgeButton.md +378 -12
  194. package/dist/ai/source/BbBreadcrumbs.md +31 -12
  195. package/dist/ai/source/BbButton.md +205 -55
  196. package/dist/ai/source/BbCalendar.md +5 -0
  197. package/dist/ai/source/BbCheckbox.md +36 -42
  198. package/dist/ai/source/BbCheckboxGroup.md +40 -17
  199. package/dist/ai/source/BbColorInput.md +2 -4
  200. package/dist/ai/source/BbConfigScope.md +19 -2
  201. package/dist/ai/source/BbConfirm.md +74 -80
  202. package/dist/ai/source/BbConfirmPortal.md +6 -6
  203. package/dist/ai/source/BbDatePicker.md +9 -2
  204. package/dist/ai/source/BbDatePickerInput.md +5 -5
  205. package/dist/ai/source/BbDialog.md +53 -2
  206. package/dist/ai/source/BbDropdown.md +360 -99
  207. package/dist/ai/source/BbDropdownButton.md +24 -13
  208. package/dist/ai/source/BbDropdownGroup.md +145 -60
  209. package/dist/ai/source/BbForm.md +144 -10
  210. package/dist/ai/source/BbNumberInput.md +2 -4
  211. package/dist/ai/source/BbOffCanvas.md +53 -2
  212. package/dist/ai/source/BbPagination.md +1 -1
  213. package/dist/ai/source/BbRadio.md +36 -42
  214. package/dist/ai/source/BbRadioGroup.md +74 -14
  215. package/dist/ai/source/BbRating.md +32 -36
  216. package/dist/ai/source/BbSelect.md +40 -13
  217. package/dist/ai/source/BbSelectPopover.md +105 -34
  218. package/dist/ai/source/BbSlider.md +2 -4
  219. package/dist/ai/source/BbSwitch.md +57 -46
  220. package/dist/ai/source/BbSwitchGroup.md +67 -21
  221. package/dist/ai/source/BbTable.md +363 -49
  222. package/dist/ai/source/BbTabs.md +6 -0
  223. package/dist/ai/source/BbTabsList.md +10 -0
  224. package/dist/ai/source/BbTabsPanels.md +6 -0
  225. package/dist/ai/source/BbTabsRoot.md +6 -0
  226. package/dist/ai/source/BbTag.md +2 -4
  227. package/dist/ai/source/BbTextInput.md +2 -4
  228. package/dist/ai/source/BbTextarea.md +2 -4
  229. package/dist/ai/source/BbTimePickerInput.md +2 -4
  230. package/dist/ai/source/BbTooltip.md +9 -3
  231. package/dist/ai/source/BbTree.md +14 -4
  232. package/dist/ai/source/CommonField.md +17 -106
  233. package/dist/ai/source/CommonFieldInput.md +2 -1
  234. package/dist/ai/source/GuidesComponent.md +3 -0
  235. package/dist/components/BbAccordion/BbAccordion.vue.d.ts +7 -3
  236. package/dist/components/BbAccordion/BbAccordion.vue_vue_type_script_setup_true_lang.js +52 -38
  237. package/dist/components/BbAccordion/ptKeys.generated.d.ts +20 -0
  238. package/dist/components/BbAccordion/types.d.ts +21 -7
  239. package/dist/components/BbAccordion/types.js +1 -1
  240. package/dist/components/BbAlert/BbAlert.vue.d.ts +1 -1
  241. package/dist/components/BbBadge/BadgeBodyContent.vue_vue_type_script_setup_true_lang.js +5 -5
  242. package/dist/components/BbBadge/BbBadge.vue.d.ts +1 -1
  243. package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +65 -42
  244. package/dist/components/BbBadge/types.d.ts +15 -12
  245. package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue_vue_type_script_setup_true_lang.js +106 -106
  246. package/dist/components/BbBreadcrumbs/types.d.ts +6 -0
  247. package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +79 -73
  248. package/dist/components/BbButton/types.d.ts +7 -6
  249. package/dist/components/BbCalendar/BbCalendar.vue.d.ts +2 -1
  250. package/dist/components/BbCalendar/BbCalendar.vue_vue_type_script_setup_true_lang.js +2 -1
  251. package/dist/components/BbCalendar/types.d.ts +5 -0
  252. package/dist/components/BbCalendar/useCalendarGrid.js +1 -1
  253. package/dist/components/BbCalendar/useDayGrid.js +1 -1
  254. package/dist/components/BbCheckbox/types.d.ts +2 -4
  255. package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.d.ts +10 -4
  256. package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +2 -2
  257. package/dist/components/BbCheckboxGroup/types.d.ts +4 -6
  258. package/dist/components/BbColorInput/types.d.ts +2 -4
  259. package/dist/components/BbConfigScope/BbConfigScope.vue_vue_type_script_setup_true_lang.js +8 -8
  260. package/dist/components/BbConfirm/BbConfirm.vue_vue_type_script_setup_true_lang.js +71 -132
  261. package/dist/components/BbConfirm/ptKeys.generated.d.ts +5 -5
  262. package/dist/components/BbConfirm/types.d.ts +5 -5
  263. package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +2 -1
  264. package/dist/components/BbDatePicker/BbDatePicker.vue_vue_type_script_setup_true_lang.js +3 -0
  265. package/dist/components/BbDatePicker/types.d.ts +5 -0
  266. package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +1 -1
  267. package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +2 -0
  268. package/dist/components/BbDatePickerInput/types.d.ts +4 -5
  269. package/dist/components/BbDialog/BbDialog.vue.d.ts +3 -0
  270. package/dist/components/BbDialog/BbDialog.vue_vue_type_script_setup_true_lang.js +263 -235
  271. package/dist/components/BbDialog/overlayActions.js +94 -0
  272. package/dist/components/BbDialog/types.d.ts +24 -0
  273. package/dist/components/BbDropdown/AdaptiveDropdown.vue_vue_type_script_setup_true_lang.js +4 -3
  274. package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +384 -332
  275. package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +121 -120
  276. package/dist/components/BbDropdown/dropdownHandle.js +6 -0
  277. package/dist/components/BbDropdown/normalizeGroups.js +58 -44
  278. package/dist/components/BbDropdown/types.d.ts +116 -50
  279. package/dist/components/BbDropdown/types.js +2 -2
  280. package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +105 -104
  281. package/dist/components/BbDropdownButton/types.d.ts +2 -4
  282. package/dist/components/BbForm/BbForm.vue.d.ts +2 -1
  283. package/dist/components/BbForm/BbForm.vue_vue_type_script_setup_true_lang.js +240 -198
  284. package/dist/components/BbForm/recognizeValidation.d.ts +9 -0
  285. package/dist/components/BbForm/recognizeValidation.js +55 -0
  286. package/dist/components/BbForm/validationError.d.ts +10 -0
  287. package/dist/components/BbForm/validationError.js +11 -0
  288. package/dist/components/BbNumberInput/types.d.ts +2 -4
  289. package/dist/components/BbOffCanvas/BbOffCanvas.vue.d.ts +3 -0
  290. package/dist/components/BbOffCanvas/BbOffCanvas.vue_vue_type_script_setup_true_lang.js +414 -389
  291. package/dist/components/BbOffCanvas/sheetAttrs.js +5 -5
  292. package/dist/components/BbOffCanvas/types.d.ts +24 -0
  293. package/dist/components/BbPagination/BbPagination.vue_vue_type_script_setup_true_lang.js +3 -3
  294. package/dist/components/BbRadio/types.d.ts +2 -4
  295. package/dist/components/BbRadioGroup/BbRadioGroup.vue.d.ts +10 -4
  296. package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +173 -157
  297. package/dist/components/BbRadioGroup/types.d.ts +11 -7
  298. package/dist/components/BbRating/BbRating.vue_vue_type_script_setup_true_lang.js +126 -119
  299. package/dist/components/BbRating/types.d.ts +5 -6
  300. package/dist/components/BbSelect/BbSelect.vue.d.ts +17 -10
  301. package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +3 -1
  302. package/dist/components/BbSelect/types.d.ts +12 -6
  303. package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +11 -4
  304. package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +513 -502
  305. package/dist/components/BbSelectPopover/types.d.ts +10 -2
  306. package/dist/components/BbSlider/types.d.ts +2 -4
  307. package/dist/components/BbSwitch/BbSwitch.vue.d.ts +2 -0
  308. package/dist/components/BbSwitch/BbSwitch.vue_vue_type_script_setup_true_lang.js +85 -73
  309. package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.d.ts +10 -4
  310. package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +171 -152
  311. package/dist/components/BbSwitchGroup/types.d.ts +1 -1
  312. package/dist/components/BbTable/BbTable.vue.d.ts +36 -25
  313. package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +1338 -1215
  314. package/dist/components/BbTable/BbTableDataRow.js +2 -1
  315. package/dist/components/BbTable/BbTableRowMenu.js +36 -0
  316. package/dist/components/BbTable/types.d.ts +33 -18
  317. package/dist/components/BbTabs/BbTabsList.vue_vue_type_script_setup_true_lang.js +2 -2
  318. package/dist/components/BbTabs/types.d.ts +6 -0
  319. package/dist/components/BbTag/types.d.ts +2 -4
  320. package/dist/components/BbTextInput/BbTextInput.vue.d.ts +1 -1
  321. package/dist/components/BbTextInput/types.d.ts +2 -4
  322. package/dist/components/BbTextarea/BbTextarea.vue.d.ts +1 -1
  323. package/dist/components/BbTextarea/types.d.ts +2 -4
  324. package/dist/components/BbTimePickerInput/BbTimePickerInput.vue.d.ts +1 -1
  325. package/dist/components/BbTimePickerInput/types.d.ts +2 -4
  326. package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +88 -94
  327. package/dist/components/BbTooltip/ptKeys.generated.d.ts +4 -4
  328. package/dist/components/BbTooltip/types.d.ts +3 -1
  329. package/dist/components/BbTree/BbTree.vue_vue_type_script_setup_true_lang.js +1 -1
  330. package/dist/components/BbTree/BbTreeLevel.vue_vue_type_script_setup_true_lang.js +9 -9
  331. package/dist/components/BbTree/types.d.ts +8 -2
  332. package/dist/components/CommonField/types.d.ts +2 -4
  333. package/dist/components/CommonFieldInput/CommonFieldInput.vue_vue_type_script_setup_true_lang.js +39 -39
  334. package/dist/composables/formSubmitLock.js +15 -8
  335. package/dist/composables/overlayRegistry.d.ts +5 -0
  336. package/dist/composables/overlayRegistry.js +154 -148
  337. package/dist/composables/useBbDropdown.d.ts +8 -0
  338. package/dist/composables/useBbDropdown.js +3 -1
  339. package/dist/composables/useBbTabs.js +138 -138
  340. package/dist/composables/useChoiceIndicator.js +67 -64
  341. package/dist/composables/useConfirm.d.ts +63 -52
  342. package/dist/composables/useConfirm.js +22 -18
  343. package/dist/deprecation/ai-deprecations.json.js +1 -1
  344. package/dist/directives/bbDropdown.d.ts +7 -7
  345. package/dist/directives/bbDropdown.js +22 -15
  346. package/dist/directives/bbTooltip.d.ts +3 -3
  347. package/dist/directives/createPopoverDirective.js +57 -35
  348. package/dist/i18n/locales/ar.json +5 -1
  349. package/dist/i18n/locales/cs.json +5 -1
  350. package/dist/i18n/locales/da.json +5 -1
  351. package/dist/i18n/locales/de-CH.json +5 -1
  352. package/dist/i18n/locales/de.json +5 -1
  353. package/dist/i18n/locales/el.json +5 -1
  354. package/dist/i18n/locales/en-GB.json +5 -1
  355. package/dist/i18n/locales/en.json +5 -1
  356. package/dist/i18n/locales/es-MX.json +5 -1
  357. package/dist/i18n/locales/es.json +5 -1
  358. package/dist/i18n/locales/fa.json +5 -1
  359. package/dist/i18n/locales/fi.json +5 -1
  360. package/dist/i18n/locales/fr.json +5 -1
  361. package/dist/i18n/locales/he.json +5 -1
  362. package/dist/i18n/locales/hu.json +5 -1
  363. package/dist/i18n/locales/it.json +5 -1
  364. package/dist/i18n/locales/ja.json +5 -1
  365. package/dist/i18n/locales/ko.json +5 -1
  366. package/dist/i18n/locales/nb.json +5 -1
  367. package/dist/i18n/locales/nl.json +5 -1
  368. package/dist/i18n/locales/pl.json +5 -1
  369. package/dist/i18n/locales/pt-BR.json +5 -1
  370. package/dist/i18n/locales/pt-PT.json +5 -1
  371. package/dist/i18n/locales/ro.json +5 -1
  372. package/dist/i18n/locales/ru.json +5 -1
  373. package/dist/i18n/locales/sv.json +5 -1
  374. package/dist/i18n/locales/tr.json +5 -1
  375. package/dist/i18n/locales/uk.json +5 -1
  376. package/dist/i18n/locales/zh-CN.json +5 -1
  377. package/dist/i18n/locales/zh-HK.json +5 -1
  378. package/dist/i18n/locales/zh-TW.json +5 -1
  379. package/dist/index.d.ts +2 -0
  380. package/dist/index.js +4 -3
  381. package/dist/llms-full.txt +2216 -1332
  382. package/dist/llms-medium.txt +21 -18
  383. package/dist/llms.txt +2 -2
  384. package/dist/locale-blueprint.json +5 -1
  385. package/dist/plugin.js +17 -40
  386. package/dist/pluginCore.js +30 -0
  387. package/dist/styles.css +2 -2
  388. package/dist/types/ActionButton.d.ts +26 -5
  389. package/dist/types/ActionButton.js +11 -0
  390. package/dist/types/ConfigDefaults.d.ts +34 -3
  391. package/dist/types/ConfigDefaults.js +14 -8
  392. package/dist/types/FieldLayout.d.ts +4 -1
  393. package/dist/types/ItemAccessor.d.ts +3 -1
  394. package/dist/types/ItemPath.d.ts +62 -0
  395. package/dist/types/ptComponentMap.d.ts +1 -1
  396. package/dist/utilities/functions/clickCount.js +14 -0
  397. package/dist/utils/versionCheck.js +1 -1
  398. package/llms.txt +2 -2
  399. package/package.json +16 -4
  400. package/scripts/README.md +35 -29
  401. package/scripts/lib/adoption-checklist.json +2 -2
  402. package/scripts/lib/define-preset-copy.mjs +1 -1
  403. package/scripts/lib/eslint-disable.mjs +5 -3
  404. package/scripts/lib/eslint-plugin.d.ts +2 -0
  405. package/scripts/lib/eslint-plugin.mjs +213 -1
  406. package/scripts/lib/redundant-item-accessor.mjs +4 -1
  407. package/scripts/lib/release-results.mjs +32 -1
  408. package/scripts/lib/renamed-item-field.mjs +4 -1
  409. package/scripts/lib/setup.mjs +8 -0
  410. package/scripts/lib/tab-links.mjs +4 -1
  411. package/scripts/lib/toolchain-check.mjs +125 -7
  412. package/scripts/lib/tree-default-expandable.mjs +53 -0
  413. package/scripts/lib/validate-bb-markup.mjs +537 -53
@@ -22,6 +22,13 @@ type DropdownEntryBase = {
22
22
  * group (the check is), or when an append slot fills the region.
23
23
  */
24
24
  'append:icon'?: IconType;
25
+ /**
26
+ * Leaves the entry out: not rendered, not reachable by keyboard or
27
+ * search. A row takes its submenu with it, a group all its rows; a group
28
+ * left with no visible row drops with its divider and label. A selected
29
+ * value stays in the model.
30
+ */
31
+ hidden?: boolean;
25
32
  /**
26
33
  * Your own data for this entry, carried untouched to its slots (as
27
34
  * `item.meta`) and to per-item `pt` functions. The dropdown never reads it
@@ -77,7 +84,7 @@ export type BbDropdownItemProps<T = any> = ItemProps<T, DropdownItemFields>;
77
84
  * discriminates `group`/`selectable`/`multiple` a few lines below.
78
85
  */
79
86
  type SubmenuExclusive = {
80
- items: Item[];
87
+ items: ItemEntry[];
81
88
  /** A submenu row opens its submenu; it cannot also run an action. */
82
89
  onClick?: never;
83
90
  /** A submenu row opens its submenu; it cannot also navigate. */
@@ -88,6 +95,8 @@ type SubmenuExclusive = {
88
95
  items?: undefined;
89
96
  };
90
97
  export type InternalItem = Omit<BbBaseButtonProps, 'block' | 'tag' | 'type' | 'text'> & SubmenuExclusive & DropdownEntryBase & {
98
+ /** Rows have no search box (a group has); declared so a group's `searchable` discriminates. */
99
+ searchable?: never;
91
100
  /** The row's text. */
92
101
  label: string;
93
102
  /**
@@ -148,27 +157,32 @@ export type InternalItem = Omit<BbBaseButtonProps, 'block' | 'tag' | 'type' | 't
148
157
  * when its latest load FAILED (`'failed'`: the footer under whatever rows a
149
158
  * `stash` keeps listed). Rendered as a non-interactive row that
150
159
  * shows `label` or, when provided, the dropdown's `loading` / `empty` slot.
151
- * Internal — set by `BbDropdownGroup`.
160
+ *
161
+ * @internal Set by `BbDropdownGroup`.
152
162
  */
153
163
  placeholder?: 'loading' | 'empty' | 'failed';
154
164
  /**
155
165
  * On a `'failed'` placeholder: what the group's `items` load rejected
156
- * with. Internal — set by the pipeline resolver, handed to the `empty`
157
- * slot as `error`.
166
+ * with, handed to the `empty` slot as `error`.
167
+ *
168
+ * @internal Set by the pipeline resolver.
158
169
  */
159
170
  error?: unknown;
160
171
  /**
161
172
  * Marks a row built by the pipeline resolver from a fetched item. Its
162
173
  * `selectable` predicate already ran against the RAW item there, so
163
174
  * `normalizeGroups` must not run it again against this row object.
164
- * Internal.
175
+ *
176
+ * @internal
165
177
  */
166
178
  fetched?: true;
167
179
  /**
168
180
  * Optional slot token used to resolve per-item named slots. Primarily set
169
181
  * by the pipeline resolver so slot names can be derived from the resolved
170
182
  * `itemValue` (readable), while `rowKey` remains the hash-based selection
171
- * id. Internal.
183
+ * id.
184
+ *
185
+ * @internal
172
186
  */
173
187
  slotKey?: string;
174
188
  };
@@ -198,12 +212,18 @@ export type InternalItem = Omit<BbBaseButtonProps, 'block' | 'tag' | 'type' | 't
198
212
  *
199
213
  * A provider signals a failure by THROWING, never by returning `[]`: the
200
214
  * rows are cleared, nothing is pruned, and the `empty` placeholder shows
201
- * `failedText` with the error. Zero-argument providers keep working. Annotate
202
- * the parameter `BbDropdownGroupItemsContext`.
215
+ * `failedText` with the error. Zero-argument providers keep working. An
216
+ * unannotated getter reads its context typed (`query` a string on a
217
+ * `searchable` group); a provider shared with other components is annotated
218
+ * `BbDropdownGroupItemsContext`.
203
219
  */
204
- export type DropdownGroupItemsGetter = ((context: BbDropdownGroupItemsContext) => any[] | Promise<any[]>) | ((context: BbDropdownGroupItemsContext & {
220
+ export type DropdownGroupItemsGetter = PlainGetter | SearchGetter;
221
+ /** A group without a search box: no `query` arrives. */
222
+ type PlainGetter = (context: BbDropdownGroupItemsContext) => any[] | Promise<any[]>;
223
+ /** A `searchable` group: `query` always arrives, `''` until typed. */
224
+ type SearchGetter = (context: BbDropdownGroupItemsContext & {
205
225
  query: string;
206
- }) => any[] | Promise<any[]>);
226
+ }) => any[] | Promise<any[]>;
207
227
  export type InternalGroup = DropdownEntryBase & {
208
228
  /**
209
229
  * The group's identity: REQUIRED on a `selectable` group (its picks are
@@ -242,19 +262,9 @@ export type InternalGroup = DropdownEntryBase & {
242
262
  */
243
263
  group?: true;
244
264
  /**
245
- * Items of the group. Plain arrays are flattened.
246
- *
247
- * For a **pipeline group**, pass raw objects (`any[]`) or an (async) getter
248
- * `({ reason, modelValue, signal }) => Item[] | Promise<Item[]>` (plus
249
- * `query` when the group is `searchable`; see {@link DropdownGroupItemsGetter})
250
- * and pair it with `itemText`/`itemValue`. A `<BbDropdownGroup :id v-model>`
251
- * companion resolves such a group and surfaces the selected `itemValue`(s)
252
- * through `v-model`.
253
- */
254
- items: Array<InternalItem | InternalItem[]> | any[] | DropdownGroupItemsGetter;
255
- /**
256
- * Pipeline groups only. Path/getter producing each item's display text
257
- * (a primitive item is its own text; a getter still maps it).
265
+ * Pipeline groups only. Path/getter producing each item's display text.
266
+ * A string or number row needs none, fetched or written: it is its own
267
+ * text and value (a getter here still maps a fetched one).
258
268
  *
259
269
  * Unset: own `label`, else `text` (`{ label, value }` needs no accessor).
260
270
  *
@@ -349,17 +359,6 @@ export type InternalGroup = DropdownEntryBase & {
349
359
  * @defaultValue `'interaction'`
350
360
  */
351
361
  prefill?: boolean | 'interaction';
352
- /**
353
- * Renders a search field at the top of THIS group (so, inside its submenu when
354
- * the group is one), scoped to this group alone — the nested "category ›
355
- * searchable options" pattern. Typing narrows this group's rows by
356
- * the ranked search (see `filterBy`) and, for an async group, passes
357
- * the typed text to its getter as the context's `query` (a user search arrives
358
- * with `reason: 'search'`, as on `BbSelect`; see
359
- * `BbDropdownGroupItemsContext`). Each searchable group owns its own query,
360
- * independent of its siblings.
361
- */
362
- searchable?: boolean;
363
362
  /** Placeholder for this group's search field. Defaults to the localized label. */
364
363
  searchPlaceholder?: string;
365
364
  /**
@@ -414,7 +413,55 @@ export type InternalGroup = DropdownEntryBase & {
414
413
  * category, yet still wants a label for chips.
415
414
  */
416
415
  hideLabel?: boolean;
416
+ } & GroupSource;
417
+ type GroupSource = {
418
+ /**
419
+ * Renders a search field at the top of THIS group (so, inside its submenu when
420
+ * the group is one), scoped to this group alone — the nested "category ›
421
+ * searchable options" pattern. Typing narrows this group's rows by
422
+ * the ranked search (see `filterBy`) and, for an async group, passes
423
+ * the typed text to its getter as the context's `query` (a user search arrives
424
+ * with `reason: 'search'`, as on `BbSelect`; see
425
+ * `BbDropdownGroupItemsContext`). Each searchable group owns its own query,
426
+ * independent of its siblings.
427
+ */
428
+ searchable: true;
429
+ /**
430
+ * Items of the group. Plain arrays are flattened.
431
+ *
432
+ * For a **pipeline group**, pass raw objects (`any[]`) or an (async) getter
433
+ * `({ reason, modelValue, signal }) => Item[] | Promise<Item[]>` (plus
434
+ * `query` when the group is `searchable`; see {@link DropdownGroupItemsGetter})
435
+ * and pair it with `itemText`/`itemValue`. A `<BbDropdownGroup :id v-model>`
436
+ * companion resolves such a group and surfaces the selected `itemValue`(s)
437
+ * through `v-model`.
438
+ */
439
+ items: GroupRows | SearchGetter;
440
+ } | {
441
+ /**
442
+ * Renders a search field at the top of THIS group (so, inside its submenu when
443
+ * the group is one), scoped to this group alone — the nested "category ›
444
+ * searchable options" pattern. Typing narrows this group's rows by
445
+ * the ranked search (see `filterBy`) and, for an async group, passes
446
+ * the typed text to its getter as the context's `query` (a user search arrives
447
+ * with `reason: 'search'`, as on `BbSelect`; see
448
+ * `BbDropdownGroupItemsContext`). Each searchable group owns its own query,
449
+ * independent of its siblings.
450
+ */
451
+ searchable?: false;
452
+ /**
453
+ * Items of the group. Plain arrays are flattened.
454
+ *
455
+ * For a **pipeline group**, pass raw objects (`any[]`) or an (async) getter
456
+ * `({ reason, modelValue, signal }) => Item[] | Promise<Item[]>` (plus
457
+ * `query` when the group is `searchable`; see {@link DropdownGroupItemsGetter})
458
+ * and pair it with `itemText`/`itemValue`. A `<BbDropdownGroup :id v-model>`
459
+ * companion resolves such a group and surfaces the selected `itemValue`(s)
460
+ * through `v-model`.
461
+ */
462
+ items: GroupRows | PlainGetter;
417
463
  };
464
+ type GroupRows = Array<InternalItem | InternalItem[]> | any[];
418
465
  /**
419
466
  * A group's items as a raw array, or `[]` when the items are still an
420
467
  * unresolved async getter. Used by the synchronous traversal/normalization,
@@ -422,6 +469,17 @@ export type InternalGroup = DropdownEntryBase & {
422
469
  * the `<BbDropdownGroup>` companion before they reach here).
423
470
  */
424
471
  export declare const groupItemsAsArray: (items: InternalGroup["items"] | undefined) => Array<InternalItem | InternalItem[]>;
472
+ /**
473
+ * A string or number row: its own text and value (`'Google'` reads "Google"
474
+ * and picks `'Google'`), loose, in a section, in a group's `items` or in a
475
+ * submenu's `items`. It declares `searchable` like every entry, so a group
476
+ * literal beside it still picks its plain or searchable getter.
477
+ */
478
+ export type PrimitiveRow = (string | number) & {
479
+ searchable?: never;
480
+ };
481
+ /** One entry of an `items` array: an {@link Item} or a {@link PrimitiveRow}. */
482
+ export type ItemEntry = Item | PrimitiveRow;
425
483
  /**
426
484
  * Items accepted by the dropdown. Entries can be:
427
485
  * - a single {@link InternalItem};
@@ -430,7 +488,9 @@ export declare const groupItemsAsArray: (items: InternalGroup["items"] | undefin
430
488
  *
431
489
  * The shapes can be mixed, e.g. `[item, [item, item], { id, label, items }]`.
432
490
  */
433
- export type Item = InternalItem | InternalGroup | Item[];
491
+ export type Item = InternalItem | InternalGroup | (ItemEntry[] & {
492
+ searchable?: never;
493
+ });
434
494
  /** Unwraps the item type out of the (possibly nested) {@link Items} shape. */
435
495
  export type FlatItem<T> = T extends Array<infer U> ? U : T;
436
496
  /**
@@ -450,7 +510,9 @@ export type FlatItem<T> = T extends Array<infer U> ? U : T;
450
510
  export declare const isSelectableGroup: (entry: Pick<InternalGroup, "selectable" | "multiple">) => boolean;
451
511
  /** The group's per-row `selectable` predicate, when it passed one. */
452
512
  export declare const selectablePredicateOf: (entry: Pick<InternalGroup, "selectable">) => ((item: any) => boolean) | undefined;
453
- export declare const isGroup: (entry: Item) => entry is InternalGroup;
513
+ /** A string or number row: its own text and value (normalizeGroups maps it). */
514
+ export declare const isPrimitiveRow: (entry: ItemEntry | InternalItem | InternalItem[]) => entry is PrimitiveRow;
515
+ export declare const isGroup: (entry: ItemEntry) => entry is InternalGroup;
454
516
  /**
455
517
  * A group after normalization: anonymous arrays and loose items become
456
518
  * non-selectable groups; {@link InternalGroup} objects keep their metadata. Selection
@@ -688,7 +750,13 @@ export type BbDropdownProps = BbDropdownPtProps & {
688
750
  *
689
751
  * @defaultValue `[]`
690
752
  */
691
- items: Item[];
753
+ items: Array<Item | PrimitiveRow>;
754
+ /**
755
+ * Keeps the trigger when no row is visible (by default it is hidden):
756
+ * inert, no popup ARIA, `empty` in the activator slot. A `contextMenu`
757
+ * trigger always stays.
758
+ */
759
+ keepActivator?: boolean;
692
760
  /**
693
761
  * Default placeholder text shown while a pipeline group's async items load.
694
762
  * A group's own `loadingText` overrides this; both fall back to the localized
@@ -727,9 +795,8 @@ export type BbDropdownProps = BbDropdownPtProps & {
727
795
  */
728
796
  padding?: number;
729
797
  /**
730
- * Position of the dropdown relative to the activator.
731
- * Use `'cursor'` to anchor at the mouse/touch coordinates.
732
- * (No arrow is drawn either way — arrows are tooltip-only in v3.)
798
+ * Position relative to the activator; `'cursor'` anchors at the
799
+ * mouse/touch point. No arrow (tooltips only).
733
800
  *
734
801
  * @defaultValue `'bottom'`
735
802
  */
@@ -743,8 +810,8 @@ export type BbDropdownProps = BbDropdownPtProps & {
743
810
  queryDebounceTime?: number;
744
811
  /**
745
812
  * The open / close transition in milliseconds. Menus take the fast one
746
- * (150), not the popovers' medium 250: a menu is opened to pick one command
747
- * and gone again, so it answers faster than a panel you read or edit in.
813
+ * (150), not the popovers' medium 250: a menu is picked from and gone, so
814
+ * it answers faster than a panel you read or edit in.
748
815
  *
749
816
  * @defaultValue `150`
750
817
  */
@@ -777,8 +844,7 @@ export type BbDropdownEvents = {
777
844
  /**
778
845
  * The user selected a row in a selectable group, at the click — also when a
779
846
  * controlled companion's app then refuses the value. The payload is the
780
- * row's value (its `item-value` for pipeline groups, else its `value`) —
781
- * symmetric with `BbTable`'s `item:selected`.
847
+ * row's value (its `item-value` for pipeline groups, else its `value`).
782
848
  */
783
849
  (e: 'item:selected', value: any): void;
784
850
  /**
@@ -797,6 +863,8 @@ export type BbDropdownActivatorProps = {
797
863
  export type BbDropdownActivatorSlotProps = {
798
864
  /** Whether the dropdown is globally disabled. */
799
865
  disabled?: boolean;
866
+ /** No row is visible: the trigger is inert. */
867
+ empty: boolean;
800
868
  /**
801
869
  * Whether any item's async `onClick` is currently in flight. Use to reflect a
802
870
  * global busy state on the trigger.
@@ -944,9 +1012,8 @@ export type BbDropdownSlots = {
944
1012
  */
945
1013
  activator?: (props: BbDropdownActivatorSlotProps) => any;
946
1014
  /**
947
- * Content pinned to the top of the dropdown panel, outside the scroll area.
948
- * Stays visible while the items scroll and is separated from them by a
949
- * divider — for a title or a filter field.
1015
+ * Pinned above the rows, outside their scroll, with a divider — for a
1016
+ * title or a filter field.
950
1017
  */
951
1018
  header?: (props: BbDropdownEdgeSlotProps) => any;
952
1019
  /**
@@ -961,9 +1028,8 @@ export type BbDropdownSlots = {
961
1028
  */
962
1029
  'item:append'?: (props: BbDropdownItemSlotProps) => any;
963
1030
  /**
964
- * Content pinned to the bottom of the dropdown panel, outside the scroll
965
- * area. Stays visible while the items scroll and is separated from them by a
966
- * divider — for action buttons.
1031
+ * Pinned below the rows, outside their scroll, with a divider — for
1032
+ * action buttons.
967
1033
  */
968
1034
  footer?: (props: BbDropdownEdgeSlotProps) => any;
969
1035
  } & Record<string, (props: BbDropdownItemSlotProps) => any>;
@@ -1,6 +1,6 @@
1
1
  import { DROPDOWN_ITEM_VARIANTS as e } from "../../types/DropdownItemVariant.js";
2
2
  // src/components/BbDropdown/types.ts
3
- var t = (e) => Array.isArray(e) ? e : [], n = (e) => e.selectable == null ? e.multiple != null : !!e.selectable, r = (e) => typeof e.selectable == "function" ? e.selectable : void 0, i = (e) => !Array.isArray(e) && (e.group === !0 || "selectable" in e || "multiple" in e || typeof e.items == "function"), a = {
3
+ var t = (e) => Array.isArray(e) ? e : [], n = (e) => e.selectable == null ? e.multiple != null : !!e.selectable, r = (e) => typeof e.selectable == "function" ? e.selectable : void 0, i = (e) => typeof e == "string" || typeof e == "number", a = (e) => typeof e == "object" && !!e && !Array.isArray(e) && (e.group === !0 || "selectable" in e || "multiple" in e || typeof e.items == "function"), o = {
4
4
  parts: [
5
5
  "root",
6
6
  "panel",
@@ -68,4 +68,4 @@ var t = (e) => Array.isArray(e) ? e : [], n = (e) => e.selectable == null ? e.mu
68
68
  ]
69
69
  }
70
70
  };
71
- export { a as BB_DROPDOWN_PT, t as groupItemsAsArray, i as isGroup, n as isSelectableGroup, r as selectablePredicateOf };
71
+ export { o as BB_DROPDOWN_PT, t as groupItemsAsArray, a as isGroup, i as isPrimitiveRow, n as isSelectableGroup, r as selectablePredicateOf };
@@ -1,21 +1,22 @@
1
1
  import e from "../BbButton/BbButton.vue.js";
2
2
  import { useLinkState as t } from "../BbBaseButton/useLinkState.js";
3
3
  import n from "../BbDropdown/BbDropdown.vue.js";
4
- import { BB_BUTTON_PT as r } from "../BbButton/types.js";
5
- import { BB_DROPDOWN_PT as i } from "../BbDropdown/types.js";
6
- import { BUTTON_VARIANTS as a } from "../../types/ButtonVariant.js";
7
- import { DROPDOWN_ITEM_VARIANTS as o } from "../../types/DropdownItemVariant.js";
8
- import { useLocale as s } from "../../composables/useLocale.js";
9
- import { removedPropsFor as c } from "../../deprecation/removedProps.js";
10
- import { warnRemovedAttrs as l } from "../../utilities/functions/warnRemovedAttrs.js";
4
+ import { hasVisibleRow as r } from "../BbDropdown/normalizeGroups.js";
5
+ import { BB_BUTTON_PT as i } from "../BbButton/types.js";
6
+ import { BB_DROPDOWN_PT as a } from "../BbDropdown/types.js";
7
+ import { BUTTON_VARIANTS as o } from "../../types/ButtonVariant.js";
8
+ import { DROPDOWN_ITEM_VARIANTS as s } from "../../types/DropdownItemVariant.js";
9
+ import { useLocale as c } from "../../composables/useLocale.js";
10
+ import { removedPropsFor as l } from "../../deprecation/removedProps.js";
11
+ import { warnRemovedAttrs as u } from "../../utilities/functions/warnRemovedAttrs.js";
11
12
  import "../../assets/svgs/chevron_down.svg_raw.js";
12
- import { BB_DROPDOWN_BUTTON_PT as u } from "./types.js";
13
- import { registeredVariantNames as d, usePassthrough as f, variantPt as p } from "../../composables/usePassthrough.js";
14
- import { useConfigDefaults as m } from "../../composables/useConfigDefaults.js";
15
- import { computed as h, createBlock as g, createCommentVNode as _, createElementBlock as v, createSlots as y, createVNode as b, defineComponent as x, guardReactiveProps as S, mergeProps as C, normalizeProps as w, openBlock as T, ref as E, renderList as D, renderSlot as O, unref as k, useAttrs as A, useSlots as j, useTemplateRef as ee, withCtx as M } from "vue";
13
+ import { BB_DROPDOWN_BUTTON_PT as d } from "./types.js";
14
+ import { registeredVariantNames as f, usePassthrough as p, variantPt as m } from "../../composables/usePassthrough.js";
15
+ import { useConfigDefaults as h } from "../../composables/useConfigDefaults.js";
16
+ import { computed as g, createBlock as _, createCommentVNode as v, createElementBlock as y, createSlots as b, createVNode as x, defineComponent as S, guardReactiveProps as C, mergeProps as w, normalizeProps as T, onMounted as E, openBlock as D, ref as O, renderList as k, renderSlot as A, unref as j, useAttrs as M, useSlots as N, useTemplateRef as ee, withCtx as P } from "vue";
16
17
  // src/components/BbDropdownButton/BbDropdownButton.vue?vue&type=script&setup=true&lang.ts
17
- var N = /*@__PURE__*/ x({
18
- mixins: [p(u)],
18
+ var F = /*@__PURE__*/ S({
19
+ mixins: [m(d)],
19
20
  inheritAttrs: !1,
20
21
  __name: "BbDropdownButton",
21
22
  props: {
@@ -200,7 +201,7 @@ var N = /*@__PURE__*/ x({
200
201
  href: {},
201
202
  download: { type: [Boolean, String] },
202
203
  external: { type: Boolean },
203
- icon: {},
204
+ iconOnly: { type: [Boolean, Object] },
204
205
  loading: { type: Boolean },
205
206
  method: {},
206
207
  onBefore: {},
@@ -262,18 +263,19 @@ var N = /*@__PURE__*/ x({
262
263
  "item:selected",
263
264
  "item:unselected"
264
265
  ],
265
- setup(p, { emit: x }) {
266
- let N = p, P = x, F = j(), I = m("BbDropdownButton", N, { block: !1 }), L = m("BbButton", N, {
266
+ setup(m, { emit: S }) {
267
+ let F = m, I = S, L = N(), R = h("BbDropdownButton", F, { block: !1 }), z = h("BbButton", F, {
267
268
  size: "md",
268
269
  variant: "primary"
269
- }), R = /* @__PURE__ */ new Set([
270
+ }), B = /* @__PURE__ */ new Set([
270
271
  "activator",
271
272
  "default",
272
273
  "dropdown",
273
- "icon",
274
274
  "prepend:icon",
275
275
  "append:icon"
276
- ]), z = () => Object.keys(F).filter((e) => !R.has(e)), B = () => N.items ?? [], V = () => B().length > 0 || !!F.dropdown, H = /* @__PURE__ */ new Set([
276
+ ]), V = () => Object.keys(L).filter((e) => !B.has(e)), H = () => F.items ?? [], U = () => r(H()) || !!L.dropdown, W = O(!1), G = O(!1);
277
+ E(() => G.value = !0);
278
+ let K = () => U() && (!G.value || W.value), q = /* @__PURE__ */ new Set([
277
279
  "adaptive",
278
280
  "closeOnSelect",
279
281
  "compact",
@@ -289,139 +291,138 @@ var N = /*@__PURE__*/ x({
289
291
  "toggle:icon",
290
292
  "block",
291
293
  "pt"
292
- ]), U = () => Object.fromEntries(Object.entries(N).filter(([e, t]) => t !== void 0 && !H.has(e) && !e.startsWith("pt:"))), W = /^(on[A-Z].*|aria-.*|name|value|autofocus|title|formaction|formenctype|formmethod|formnovalidate|formtarget)$/, G = () => {
294
+ ]), J = () => Object.fromEntries(Object.entries(F).filter(([e, t]) => t !== void 0 && !q.has(e) && !e.startsWith("pt:"))), Y = /^(on[A-Z].*|aria-.*|name|value|autofocus|title|formaction|formenctype|formmethod|formnovalidate|formtarget)$/, X = () => {
293
295
  let e = {}, t = {};
294
- for (let [n, r] of Object.entries(q.rootAttrs)) (W.test(n) ? e : t)[n] = r;
296
+ for (let [n, r] of Object.entries(Q.rootAttrs)) (Y.test(n) ? e : t)[n] = r;
295
297
  return {
296
298
  main: e,
297
299
  root: t
298
300
  };
299
- }, K = t(N), q = f({
301
+ }, Z = t(F), Q = p({
300
302
  component: "BbDropdownButton",
301
- attrs: A(),
302
- props: N,
303
- parts: u.parts,
304
- states: u.states,
303
+ attrs: M(),
304
+ props: F,
305
+ parts: d.parts,
306
+ states: d.states,
305
307
  active: {
306
- loading: () => !!N.loading,
307
- disabled: () => !!N.disabled,
308
+ loading: () => !!F.loading,
309
+ disabled: () => !!F.disabled,
308
310
  open: () => $.value,
309
- activeLink: () => K.value.activeLink,
310
- exactActiveLink: () => K.value.exactActiveLink
311
+ activeLink: () => Z.value.activeLink,
312
+ exactActiveLink: () => Z.value.exactActiveLink
311
313
  },
312
314
  variant: [{
313
- ...u.variant[0],
314
- current: () => L.variant
315
- }, u.variant[1]]
316
- }), J = [...r.states, ...d(a, "buttonVariants")], Y = [...i.states, ...d(o, "dropdownItemVariants")], X = ["activeLink", "exactActiveLink"], Z = () => q.forward({ toggle: "root" }, ["disabled", ...d(a, "buttonVariants")]), Q = () => ({
317
- ...q.forward([
315
+ ...d.variant[0],
316
+ current: () => z.variant
317
+ }, d.variant[1]]
318
+ }), te = [...i.states, ...f(o, "buttonVariants")], ne = [...a.states, ...f(s, "dropdownItemVariants")], re = ["activeLink", "exactActiveLink"], ie = () => Q.forward({ toggle: "root" }, ["disabled", ...f(o, "buttonVariants")]), ae = () => ({
319
+ ...Q.forward([
318
320
  "panel",
319
321
  "sheet",
320
322
  "header",
321
323
  "footer",
322
324
  "input",
323
325
  "submenu"
324
- ], i.states.filter((e) => e !== "disabled" && !X.includes(e))),
325
- ...q.forward([
326
+ ], a.states.filter((e) => e !== "disabled" && !re.includes(e))),
327
+ ...Q.forward([
326
328
  "item",
327
329
  "itemText",
328
330
  "itemIcon",
329
331
  "itemDescription",
330
332
  "check"
331
- ], Y)
333
+ ], ne)
332
334
  });
333
- process.env.NODE_ENV !== "production" && l("BbDropdownButton", c("BbDropdownButton"));
334
- let te = h(() => N["toggle:icon"] ?? "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"icon icon-tabler icons-tabler-outline icon-tabler-chevron-down\">\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path d=\"M6 9l6 6l6 -6\" />\n</svg>\n"), { t: ne } = s(), re = ee("root-el"), $ = E(!1), ie = () => {
335
- $.value = !0, P("show");
336
- }, ae = () => {
337
- $.value = !1, P("hide");
338
- }, oe = h(() => ne("dropdownButton.open").value);
339
- return (t, r) => (T(), v("span", C({
335
+ process.env.NODE_ENV !== "production" && u("BbDropdownButton", l("BbDropdownButton"));
336
+ let oe = g(() => F["toggle:icon"] ?? "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"icon icon-tabler icons-tabler-outline icon-tabler-chevron-down\">\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path d=\"M6 9l6 6l6 -6\" />\n</svg>\n"), { t: se } = c(), ce = ee("root-el"), $ = O(!1), le = () => {
337
+ $.value = !0, I("show");
338
+ }, ue = () => {
339
+ $.value = !1, I("hide");
340
+ }, de = g(() => se("dropdownButton.open").value);
341
+ return (t, r) => (D(), y("span", w({
340
342
  ref: "root-el",
341
- class: ["bb-dropdown-button", { "bb-dropdown-button--block": k(I).block }]
342
- }, G().root), [b(e, C({
343
- ...U(),
344
- ...G().main
343
+ class: ["bb-dropdown-button", { "bb-dropdown-button--block": j(R).block }]
344
+ }, X().root), [x(e, w({
345
+ ...J(),
346
+ ...X().main
345
347
  }, {
346
348
  class: "bb-dropdown-button__main",
347
- group: V(),
348
- pt: k(q).forward({
349
+ group: K(),
350
+ pt: j(Q).forward({
349
351
  main: "root",
350
352
  icon: "icon",
351
353
  spinner: "spinner",
352
354
  text: "text"
353
- }, J)
354
- }), y({ _: 2 }, [
355
- F.default ? {
355
+ }, te)
356
+ }), b({ _: 2 }, [
357
+ L.default ? {
356
358
  name: "default",
357
- fn: M(() => [O(t.$slots, "default")]),
359
+ fn: P(() => [A(t.$slots, "default")]),
358
360
  key: "0"
359
361
  } : void 0,
360
- F.icon ? {
361
- name: "icon",
362
- fn: M((e) => [O(t.$slots, "icon", w(S(e)))]),
363
- key: "1"
364
- } : void 0,
365
- F["prepend:icon"] ? {
362
+ L["prepend:icon"] ? {
366
363
  name: "prepend:icon",
367
- fn: M((e) => [O(t.$slots, "prepend:icon", w(S(e)))]),
368
- key: "2"
364
+ fn: P((e) => [A(t.$slots, "prepend:icon", T(C(e)))]),
365
+ key: "1"
369
366
  } : void 0,
370
- F["append:icon"] ? {
367
+ L["append:icon"] ? {
371
368
  name: "append:icon",
372
- fn: M((e) => [O(t.$slots, "append:icon", w(S(e)))]),
373
- key: "3"
369
+ fn: P((e) => [A(t.$slots, "append:icon", T(C(e)))]),
370
+ key: "2"
374
371
  } : void 0
375
- ]), 1040, ["group", "pt"]), V() ? (T(), g(n, {
372
+ ]), 1040, ["group", "pt"]), U() ? (D(), _(n, {
376
373
  key: 0,
377
- id: p.id,
378
- adaptive: p.adaptive,
379
- anchor: re.value,
380
- "close-on-select": p.closeOnSelect,
381
- compact: p.compact,
382
- disabled: p.disabled,
383
- eager: p.eager,
384
- items: B(),
385
- "off-canvas-props": p.offCanvasProps,
386
- offset: p.offset,
387
- padding: p.padding,
388
- placement: p.placement,
389
- pt: Q(),
390
- "transition-duration": p.transitionDuration,
391
- width: p.width,
392
- onHidden: r[0] ||= (e) => P("hidden"),
393
- onHide: ae,
394
- "onItem:selected": r[1] ||= (e) => P("item:selected", e),
395
- "onItem:unselected": r[2] ||= (e) => P("item:unselected", e),
396
- onShow: ie,
397
- onShown: r[3] ||= (e) => P("shown")
398
- }, y({
399
- activator: M(({ props: t, loading: n }) => [b(e, C({
400
- "aria-label": oe.value,
374
+ id: m.id,
375
+ adaptive: m.adaptive,
376
+ anchor: ce.value,
377
+ "close-on-select": m.closeOnSelect,
378
+ compact: m.compact,
379
+ disabled: m.disabled,
380
+ eager: m.eager,
381
+ items: H(),
382
+ "off-canvas-props": m.offCanvasProps,
383
+ offset: m.offset,
384
+ padding: m.padding,
385
+ placement: m.placement,
386
+ pt: ae(),
387
+ "transition-duration": m.transitionDuration,
388
+ width: m.width,
389
+ onHidden: r[2] ||= (e) => I("hidden"),
390
+ onHide: ue,
391
+ "onItem:selected": r[3] ||= (e) => I("item:selected", e),
392
+ "onItem:unselected": r[4] ||= (e) => I("item:unselected", e),
393
+ onShow: le,
394
+ onShown: r[5] ||= (e) => I("shown")
395
+ }, b({
396
+ activator: P(({ props: t, loading: n }) => [x(e, w({
401
397
  class: "bb-dropdown-button__toggle",
402
398
  "disable-auto-loading": "",
403
- disabled: p.disabled,
399
+ disabled: m.disabled,
404
400
  group: "",
405
- icon: te.value,
401
+ "icon-only": "",
406
402
  "interactive-while-loading": "",
407
403
  loading: n,
408
- pt: Z(),
409
- size: k(L).size,
410
- variant: k(L).variant
411
- }, t), null, 16, [
412
- "aria-label",
404
+ "prepend:icon": oe.value,
405
+ pt: ie(),
406
+ size: j(z).size,
407
+ text: de.value,
408
+ variant: j(z).variant
409
+ }, t, {
410
+ onVnodeMounted: r[0] ||= (e) => W.value = !0,
411
+ onVnodeUnmounted: r[1] ||= (e) => W.value = !1
412
+ }), null, 16, [
413
413
  "disabled",
414
- "icon",
415
414
  "loading",
415
+ "prepend:icon",
416
416
  "pt",
417
417
  "size",
418
+ "text",
418
419
  "variant"
419
420
  ])]),
420
- default: M(() => [O(t.$slots, "dropdown")]),
421
+ default: P(() => [A(t.$slots, "dropdown")]),
421
422
  _: 2
422
- }, [D(z(), (e) => ({
423
+ }, [k(V(), (e) => ({
423
424
  name: e,
424
- fn: M((n) => [O(t.$slots, e, w(S(n)))])
425
+ fn: P((n) => [A(t.$slots, e, T(C(n)))])
425
426
  }))]), 1032, [
426
427
  "id",
427
428
  "adaptive",
@@ -438,7 +439,7 @@ var N = /*@__PURE__*/ x({
438
439
  "pt",
439
440
  "transition-duration",
440
441
  "width"
441
- ])) : _("", !0)], 16));
442
+ ])) : v("", !0)], 16));
442
443
  }
443
444
  });
444
- export { N as default };
445
+ export { F as default };
@@ -258,11 +258,9 @@ export type BbDropdownButtonSlots = {
258
258
  */
259
259
  default?: () => any;
260
260
  /**
261
- * The main button's icon, replacing the `icon` prop; inside its `icon` part
262
- * (`pt:icon`, `--icon-size`, the loading spinner), with its states.
261
+ * The main button's leading icon, replacing `prepend:icon` (the one
262
+ * `icon-only` shows); inside its `icon` part, with its states.
263
263
  */
264
- icon?: (props: BbButtonIconSlotProps) => any;
265
- /** The main button's leading icon, replacing `prepend:icon`. */
266
264
  'prepend:icon'?: (props: BbButtonIconSlotProps) => any;
267
265
  /** The main button's trailing icon, replacing `append:icon`. */
268
266
  'append:icon'?: (props: BbButtonIconSlotProps) => any;