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.
Files changed (396) hide show
  1. package/README.md +25 -20
  2. package/bin/bitboss-ui.mjs +73 -7
  3. package/dist/ai/BbAlert.md +10 -1
  4. package/dist/ai/BbBadge.md +35 -3
  5. package/dist/ai/BbBadgeButton.md +4 -2
  6. package/dist/ai/BbBaseButton.md +9 -3
  7. package/dist/ai/BbBreadcrumbs.md +2 -2
  8. package/dist/ai/BbButton.md +113 -8
  9. package/dist/ai/BbCheckbox.md +1 -1
  10. package/dist/ai/BbCheckboxGroup.md +94 -6
  11. package/dist/ai/BbColorInput.md +4 -1
  12. package/dist/ai/BbColorPalette.md +2 -1
  13. package/dist/ai/BbConfirm.md +7 -3
  14. package/dist/ai/BbDatePicker.md +2 -1
  15. package/dist/ai/BbDatePickerInput.md +4 -1
  16. package/dist/ai/BbDialog.md +12 -11
  17. package/dist/ai/BbDropdown.md +189 -38
  18. package/dist/ai/BbDropdownButton.md +27 -7
  19. package/dist/ai/BbForm.md +55 -22
  20. package/dist/ai/BbHost.md +2 -2
  21. package/dist/ai/BbHoverCard.md +7 -3
  22. package/dist/ai/BbIcon.md +12 -6
  23. package/dist/ai/BbIndicator.md +11 -1
  24. package/dist/ai/BbNumberInput.md +4 -1
  25. package/dist/ai/BbOffCanvas.md +37 -3
  26. package/dist/ai/BbPopover.md +2 -1
  27. package/dist/ai/BbRadio.md +1 -1
  28. package/dist/ai/BbRadioGroup.md +102 -10
  29. package/dist/ai/BbSelect.md +52 -17
  30. package/dist/ai/BbSelectPopover.md +93 -26
  31. package/dist/ai/BbSwitch.md +1 -1
  32. package/dist/ai/BbSwitchGroup.md +30 -3
  33. package/dist/ai/BbTable.md +17 -10
  34. package/dist/ai/BbTabs.md +8 -3
  35. package/dist/ai/BbTabsList.md +4 -1
  36. package/dist/ai/BbTag.md +5 -2
  37. package/dist/ai/BbTextInput.md +4 -1
  38. package/dist/ai/BbTextarea.md +4 -1
  39. package/dist/ai/BbTimePicker.md +2 -1
  40. package/dist/ai/BbTimePickerInput.md +4 -1
  41. package/dist/ai/BbToast.md +9 -3
  42. package/dist/ai/BbTooltip.md +71 -9
  43. package/dist/ai/ChipsBox.md +1 -1
  44. package/dist/ai/CommonField.md +1 -1
  45. package/dist/ai/OptionsContainer.md +42 -0
  46. package/dist/ai/changelog.json +494 -6
  47. package/dist/ai/components.json +50 -48
  48. package/dist/ai/composables/useBbConfig.md +8 -1
  49. package/dist/ai/composables/useConfirm.md +39 -1
  50. package/dist/ai/design-tokens.json +6 -6
  51. package/dist/ai/guides/agent-contract.md +2 -2
  52. package/dist/ai/guides/ai-router.md +24 -23
  53. package/dist/ai/guides/app-layout.md +5 -0
  54. package/dist/ai/guides/component-picker.md +9 -2
  55. package/dist/ai/guides/design-language.md +24 -24
  56. package/dist/ai/guides/design-tokens.md +15 -8
  57. package/dist/ai/guides/icons-policy.md +9 -2
  58. package/dist/ai/guides/inertia-helpers.md +1183 -301
  59. package/dist/ai/guides/installation-and-plugin-setup.md +12 -2
  60. package/dist/ai/guides/migration/adoption-checklist.md +235 -0
  61. package/dist/ai/guides/migration/components/bb-checkbox-group.md +16 -15
  62. package/dist/ai/guides/migration/components/bb-dialog.md +9 -9
  63. package/dist/ai/guides/migration/components/bb-dropdown.md +7 -2
  64. package/dist/ai/guides/migration/components/bb-popover.md +4 -2
  65. package/dist/ai/guides/migration/components/bb-select.md +19 -0
  66. package/dist/ai/guides/migration/components/bb-table.md +1 -0
  67. package/dist/ai/guides/migration/components/bb-toast.md +4 -0
  68. package/dist/ai/guides/migration/components/bb-tooltip.md +15 -12
  69. package/dist/ai/guides/migration/components/use-confirm.md +25 -2
  70. package/dist/ai/guides/migration/v2-to-v3.md +211 -9
  71. package/dist/ai/guides/migration/v3-beta-css-classes.md +7 -3
  72. package/dist/ai/guides/options-items-playbook.md +2 -1
  73. package/dist/ai/guides/passthrough.md +149 -85
  74. package/dist/ai/guides/preset-components.md +140 -15
  75. package/dist/ai/helpers/definePreset.json +7 -0
  76. package/dist/ai/helpers/definePreset.ts +123 -11
  77. package/dist/ai/helpers/inertia/manifest.json +151 -62
  78. package/dist/ai/helpers/inertia/messages.ts +33 -0
  79. package/dist/ai/helpers/inertia/useConfirmOnRouteLeave.ts +120 -20
  80. package/dist/ai/helpers/inertia/useHasChanged.ts +34 -16
  81. package/dist/ai/helpers/inertia/useLazyProp.ts +102 -36
  82. package/dist/ai/helpers/inertia/useLazyPropGetter.ts +3 -1
  83. package/dist/ai/helpers/inertia/usePaginatedResponseContext.ts +154 -34
  84. package/dist/ai/helpers/inertia/usePromiseForm.ts +121 -14
  85. package/dist/ai/helpers/inertia/useQuery.ts +133 -11
  86. package/dist/ai/helpers/inertia/useQueryObject.ts +74 -67
  87. package/dist/ai/helpers/inertia/useResourceContext.ts +60 -14
  88. package/dist/ai/helpers/inertia/useRouteQuery.ts +38 -27
  89. package/dist/ai/helpers/inertia/useScreenSizes.ts +9 -7
  90. package/dist/ai/helpers/inertia/useTableContext.ts +5 -2
  91. package/dist/ai/helpers/inertia/utils.ts +14 -0
  92. package/dist/ai/index.md +1 -0
  93. package/dist/ai/manifest/common.json +0 -1
  94. package/dist/ai/manifest/components/BbAlert.json +7 -2
  95. package/dist/ai/manifest/components/BbBadge.json +13 -4
  96. package/dist/ai/manifest/components/BbBadge.tree.json +2 -0
  97. package/dist/ai/manifest/components/BbBadgeButton.json +4 -2
  98. package/dist/ai/manifest/components/BbBaseButton.json +4 -2
  99. package/dist/ai/manifest/components/BbBreadcrumbs.tree.json +1 -1
  100. package/dist/ai/manifest/components/BbButton.json +14 -3
  101. package/dist/ai/manifest/components/BbButton.tree.json +5 -1
  102. package/dist/ai/manifest/components/BbCheckboxGroup.json +13 -8
  103. package/dist/ai/manifest/components/BbCheckboxGroup.tree.json +11 -1
  104. package/dist/ai/manifest/components/BbColorInput.json +18 -15
  105. package/dist/ai/manifest/components/BbColorPalette.json +1 -1
  106. package/dist/ai/manifest/components/BbConfirm.json +4 -2
  107. package/dist/ai/manifest/components/BbConfirm.tree.json +1 -1
  108. package/dist/ai/manifest/components/BbDatePicker.json +1 -1
  109. package/dist/ai/manifest/components/BbDatePickerInput.json +17 -14
  110. package/dist/ai/manifest/components/BbDialog.tree.json +2 -1
  111. package/dist/ai/manifest/components/BbDropdown.json +24 -19
  112. package/dist/ai/manifest/components/BbDropdown.tree.json +9 -2
  113. package/dist/ai/manifest/components/BbDropdownButton.json +33 -20
  114. package/dist/ai/manifest/components/BbDropdownButton.tree.json +2 -2
  115. package/dist/ai/manifest/components/BbForm.json +2 -2
  116. package/dist/ai/manifest/components/BbHost.tree.json +1 -1
  117. package/dist/ai/manifest/components/BbHoverCard.json +1 -1
  118. package/dist/ai/manifest/components/BbIndicator.json +8 -2
  119. package/dist/ai/manifest/components/BbNumberInput.json +5 -2
  120. package/dist/ai/manifest/components/BbOffCanvas.json +2 -2
  121. package/dist/ai/manifest/components/BbOffCanvas.tree.json +1 -1
  122. package/dist/ai/manifest/components/BbPopover.json +1 -1
  123. package/dist/ai/manifest/components/BbRadioGroup.json +17 -12
  124. package/dist/ai/manifest/components/BbRadioGroup.tree.json +8 -1
  125. package/dist/ai/manifest/components/BbSelect.json +21 -18
  126. package/dist/ai/manifest/components/BbSelect.tree.json +2 -2
  127. package/dist/ai/manifest/components/BbSelectPopover.json +10 -10
  128. package/dist/ai/manifest/components/BbSelectPopover.tree.json +3 -2
  129. package/dist/ai/manifest/components/BbSwitchGroup.json +1 -1
  130. package/dist/ai/manifest/components/BbSwitchGroup.tree.json +3 -1
  131. package/dist/ai/manifest/components/BbTable.tree.json +14 -1
  132. package/dist/ai/manifest/components/BbTabs.json +9 -6
  133. package/dist/ai/manifest/components/BbTabs.tree.json +1 -1
  134. package/dist/ai/manifest/components/BbTabsList.json +6 -3
  135. package/dist/ai/manifest/components/BbTag.json +19 -16
  136. package/dist/ai/manifest/components/BbTag.tree.json +1 -1
  137. package/dist/ai/manifest/components/BbTextInput.json +6 -3
  138. package/dist/ai/manifest/components/BbTextarea.json +6 -3
  139. package/dist/ai/manifest/components/BbTimePicker.json +1 -1
  140. package/dist/ai/manifest/components/BbTimePickerInput.json +10 -7
  141. package/dist/ai/manifest/components/BbToast.json +7 -2
  142. package/dist/ai/manifest/components/BbToast.tree.json +4 -2
  143. package/dist/ai/manifest/components/BbTooltip.json +6 -5
  144. package/dist/ai/manifest/components/ChipsBox.tree.json +1 -1
  145. package/dist/ai/manifest/components/CommonField.json +1 -1
  146. package/dist/ai/manifest/components/OptionsContainer.json +3 -1
  147. package/dist/ai/manifest/components/OptionsContainer.tree.json +38 -0
  148. package/dist/ai/manifest/index.json +3 -3
  149. package/dist/ai/manifest/meta.json +5 -3
  150. package/dist/ai/manifest/types.advanced.json +5 -2
  151. package/dist/ai/manifest/types.api.json +9 -7
  152. package/dist/ai/recipes/inertia/approvals-inbox.md +1 -1
  153. package/dist/ai/recipes/inertia/inline-edit-workspace.md +1 -1
  154. package/dist/ai/recipes/inertia/layout-scaffold.md +19 -6
  155. package/dist/ai/recipes/inertia/ownership-atlas.md +1 -1
  156. package/dist/ai/recipes/inertia/records-workspace.md +50 -14
  157. package/dist/ai/recipes/inertia/upload-center.md +1 -1
  158. package/dist/ai/recipes/nuxt/layout-scaffold.md +19 -6
  159. package/dist/ai/recipes/nuxt/records-workspace.md +42 -12
  160. package/dist/ai/recipes/vue/layout-scaffold.md +19 -6
  161. package/dist/ai/recipes/vue/records-workspace.md +42 -12
  162. package/dist/ai/source/BbAlert.md +94 -76
  163. package/dist/ai/source/BbBadge.md +174 -72
  164. package/dist/ai/source/BbBadgeButton.md +130 -65
  165. package/dist/ai/source/BbBaseButton.md +46 -124
  166. package/dist/ai/source/BbBaseCheckboxIcon.md +38 -0
  167. package/dist/ai/source/BbBaseRadioIcon.md +18 -0
  168. package/dist/ai/source/BbBaseSwitchIcon.md +51 -0
  169. package/dist/ai/source/BbButton.md +153 -36
  170. package/dist/ai/source/BbCheckboxGroup.md +142 -18
  171. package/dist/ai/source/BbColorInput.md +240 -204
  172. package/dist/ai/source/BbColorPalette.md +7 -4
  173. package/dist/ai/source/BbConfirm.md +34 -11
  174. package/dist/ai/source/BbConfirmPortal.md +24 -9
  175. package/dist/ai/source/BbDatePicker.md +11 -7
  176. package/dist/ai/source/BbDatePickerInput.md +306 -269
  177. package/dist/ai/source/BbDialog.md +49 -14
  178. package/dist/ai/source/BbDropdown.md +314 -197
  179. package/dist/ai/source/BbDropdownButton.md +197 -31
  180. package/dist/ai/source/BbDropdownGroup.md +274 -176
  181. package/dist/ai/source/BbForm.md +50 -6
  182. package/dist/ai/source/BbHoverCard.md +12 -5
  183. package/dist/ai/source/BbIcon.md +4 -3
  184. package/dist/ai/source/BbIndicator.md +73 -52
  185. package/dist/ai/source/BbNumberInput.md +293 -257
  186. package/dist/ai/source/BbOffCanvas.md +55 -29
  187. package/dist/ai/source/BbPopover.md +14 -10
  188. package/dist/ai/source/BbRadioGroup.md +413 -297
  189. package/dist/ai/source/BbSelect.md +549 -435
  190. package/dist/ai/source/BbSelectPopover.md +153 -34
  191. package/dist/ai/source/BbSwitchGroup.md +70 -10
  192. package/dist/ai/source/BbTable.md +369 -37
  193. package/dist/ai/source/BbTabs.md +115 -39
  194. package/dist/ai/source/BbTabsList.md +106 -38
  195. package/dist/ai/source/BbTabsPanels.md +96 -36
  196. package/dist/ai/source/BbTabsRoot.md +96 -36
  197. package/dist/ai/source/BbTag.md +267 -233
  198. package/dist/ai/source/BbTextInput.md +261 -225
  199. package/dist/ai/source/BbTextarea.md +251 -215
  200. package/dist/ai/source/BbTimePicker.md +11 -7
  201. package/dist/ai/source/BbTimePickerInput.md +257 -220
  202. package/dist/ai/source/BbToast.md +73 -32
  203. package/dist/ai/source/BbToastPortal.md +65 -30
  204. package/dist/ai/source/BbTooltip.md +148 -113
  205. package/dist/ai/source/CommonPopover.md +6 -1
  206. package/dist/ai/source/FlatListBox.md +19 -9
  207. package/dist/ai/source/GroupedListBox.md +19 -9
  208. package/dist/ai/source/OptionsContainer.md +25 -9
  209. package/dist/components/BbAlert/BbAlert.vue_vue_type_script_setup_true_lang.js +61 -36
  210. package/dist/components/BbAlert/types.d.ts +9 -5
  211. package/dist/components/BbAlert/types.js +8 -3
  212. package/dist/components/BbBadge/BadgeBodyContent.vue.d.ts +3 -3
  213. package/dist/components/BbBadge/BadgeBodyContent.vue_vue_type_script_setup_true_lang.js +26 -17
  214. package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +103 -50
  215. package/dist/components/BbBadge/BbBadgeButton.vue_vue_type_script_setup_true_lang.js +20 -15
  216. package/dist/components/BbBadge/badgeButtonContext.d.ts +12 -1
  217. package/dist/components/BbBadge/types.d.ts +45 -15
  218. package/dist/components/BbBadge/types.js +12 -3
  219. package/dist/components/BbBaseButton/BbBaseButton.vue_vue_type_script_setup_true_lang.js +89 -126
  220. package/dist/components/BbBaseButton/types.d.ts +23 -4
  221. package/dist/components/BbBaseButton/types.js +7 -1
  222. package/dist/components/BbBaseButton/useLinkState.d.ts +41 -0
  223. package/dist/components/BbBaseButton/useLinkState.js +70 -0
  224. package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +130 -74
  225. package/dist/components/BbButton/types.d.ts +50 -13
  226. package/dist/components/BbButton/types.js +10 -3
  227. package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +148 -95
  228. package/dist/components/BbCheckboxGroup/types.d.ts +34 -11
  229. package/dist/components/BbCheckboxGroup/types.js +9 -4
  230. package/dist/components/BbCollapsible/BbCollapsible.vue.d.ts +1 -1
  231. package/dist/components/BbColorInput/BbColorInput.vue_vue_type_script_setup_true_lang.js +134 -93
  232. package/dist/components/BbColorInput/types.d.ts +11 -4
  233. package/dist/components/BbColorInput/types.js +9 -3
  234. package/dist/components/BbConfirm/BbConfirm.vue_vue_type_script_setup_true_lang.js +82 -59
  235. package/dist/components/BbConfirm/types.d.ts +9 -4
  236. package/dist/components/BbConfirm/types.js +8 -3
  237. package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +1 -1
  238. package/dist/components/BbDatePicker/BbDatePicker.vue_vue_type_script_setup_true_lang.js +68 -67
  239. package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +1 -1
  240. package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +259 -215
  241. package/dist/components/BbDatePickerInput/types.d.ts +12 -5
  242. package/dist/components/BbDatePickerInput/types.js +9 -3
  243. package/dist/components/BbDialog/BbDialog.vue_vue_type_script_setup_true_lang.js +223 -219
  244. package/dist/components/BbDialog/useDialogStack.d.ts +1 -1
  245. package/dist/components/BbDropdown/AdaptiveDropdown.vue_vue_type_script_setup_true_lang.js +104 -89
  246. package/dist/components/BbDropdown/BbDropdown.vue.d.ts +1 -0
  247. package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +323 -285
  248. package/dist/components/BbDropdown/BbDropdownList.vue.d.ts +1 -0
  249. package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +411 -319
  250. package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +100 -98
  251. package/dist/components/BbDropdown/DropdownRow.vue.d.ts +4 -3
  252. package/dist/components/BbDropdown/DropdownRow.vue_vue_type_script_setup_true_lang.js +49 -28
  253. package/dist/components/BbDropdown/normalizeGroups.d.ts +6 -0
  254. package/dist/components/BbDropdown/normalizeGroups.js +21 -15
  255. package/dist/components/BbDropdown/types.d.ts +59 -12
  256. package/dist/components/BbDropdown/types.js +16 -3
  257. package/dist/components/BbDropdown/useDropdownContext.d.ts +6 -0
  258. package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +2 -1
  259. package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +179 -68
  260. package/dist/components/BbDropdownButton/types.d.ts +44 -16
  261. package/dist/components/BbDropdownButton/types.js +28 -3
  262. package/dist/components/BbForm/BbForm.vue_vue_type_script_setup_true_lang.js +111 -89
  263. package/dist/components/BbForm/formSchema.d.ts +13 -0
  264. package/dist/components/BbHoverCard/BbHoverCard.vue_vue_type_script_setup_true_lang.js +100 -100
  265. package/dist/components/BbIndicator/BbIndicator.vue_vue_type_script_setup_true_lang.js +40 -25
  266. package/dist/components/BbIndicator/types.d.ts +9 -5
  267. package/dist/components/BbIndicator/types.js +8 -3
  268. package/dist/components/BbNumberInput/BbNumberInput.vue_vue_type_script_setup_true_lang.js +243 -202
  269. package/dist/components/BbNumberInput/types.d.ts +12 -5
  270. package/dist/components/BbNumberInput/types.js +9 -3
  271. package/dist/components/BbOffCanvas/BbOffCanvas.vue.d.ts +1 -1
  272. package/dist/components/BbOffCanvas/BbOffCanvas.vue_vue_type_script_setup_true_lang.js +401 -399
  273. package/dist/components/BbOffCanvas/types.d.ts +6 -2
  274. package/dist/components/BbPopover/BbPopover.vue_vue_type_script_setup_true_lang.js +81 -80
  275. package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +158 -105
  276. package/dist/components/BbRadioGroup/types.d.ts +21 -7
  277. package/dist/components/BbRadioGroup/types.js +9 -4
  278. package/dist/components/BbSelect/BbSelect.vue.d.ts +4 -3
  279. package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +181 -137
  280. package/dist/components/BbSelect/types.d.ts +36 -22
  281. package/dist/components/BbSelect/types.js +22 -3
  282. package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +4 -4
  283. package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +600 -577
  284. package/dist/components/BbSelectPopover/knownItems.d.ts +5 -0
  285. package/dist/components/BbSelectPopover/types.d.ts +46 -12
  286. package/dist/components/BbSmoothHeight/BbSmoothHeight.vue.d.ts +1 -1
  287. package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +2 -2
  288. package/dist/components/BbSwitchGroup/types.d.ts +14 -4
  289. package/dist/components/BbSwitchGroup/types.js +8 -3
  290. package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +1102 -995
  291. package/dist/components/BbTable/estimatedFloors.golden.d.ts +25 -0
  292. package/dist/components/BbTable/measuredFloors.d.ts +46 -0
  293. package/dist/components/BbTable/measuredFloors.js +322 -0
  294. package/dist/components/BbTable/measuredFloorsTestKit.d.ts +27 -0
  295. package/dist/components/BbTable/textRuler.d.ts +71 -0
  296. package/dist/components/BbTable/textRuler.js +121 -0
  297. package/dist/components/BbTable/utils.d.ts +113 -6
  298. package/dist/components/BbTable/utils.js +118 -65
  299. package/dist/components/BbTabs/BbTabs.vue_vue_type_script_setup_true_lang.js +53 -35
  300. package/dist/components/BbTabs/BbTabsList.vue_vue_type_script_setup_true_lang.js +62 -45
  301. package/dist/components/BbTabs/types.d.ts +26 -11
  302. package/dist/components/BbTabs/types.js +23 -8
  303. package/dist/components/BbTag/BbTag.vue_vue_type_script_setup_true_lang.js +205 -164
  304. package/dist/components/BbTag/types.d.ts +11 -4
  305. package/dist/components/BbTag/types.js +9 -3
  306. package/dist/components/BbTextInput/BbTextInput.vue_vue_type_script_setup_true_lang.js +98 -57
  307. package/dist/components/BbTextInput/types.d.ts +12 -5
  308. package/dist/components/BbTextInput/types.js +9 -3
  309. package/dist/components/BbTextarea/BbTextarea.vue_vue_type_script_setup_true_lang.js +137 -96
  310. package/dist/components/BbTextarea/types.d.ts +12 -5
  311. package/dist/components/BbTextarea/types.js +9 -3
  312. package/dist/components/BbTimePicker/BbTimePicker.vue_vue_type_script_setup_true_lang.js +105 -104
  313. package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +241 -197
  314. package/dist/components/BbTimePickerInput/types.d.ts +12 -5
  315. package/dist/components/BbTimePickerInput/types.js +9 -3
  316. package/dist/components/BbToast/BbToast.vue_vue_type_script_setup_true_lang.js +74 -32
  317. package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +47 -47
  318. package/dist/components/BbToast/types.d.ts +10 -5
  319. package/dist/components/BbToast/types.js +18 -3
  320. package/dist/components/BbTooltip/BbTooltip.vue_vue_type_script_setup_true_lang.js +85 -71
  321. package/dist/components/BbTooltip/types.d.ts +13 -8
  322. package/dist/components/BbTooltip/types.js +8 -3
  323. package/dist/components/CommonField/CommonField.vue.d.ts +1 -1
  324. package/dist/components/CommonPopover/CommonPopover.vue.d.ts +1 -1
  325. package/dist/components/CommonPopover/CommonPopover.vue_vue_type_script_setup_true_lang.js +69 -69
  326. package/dist/components/FlatListBox/FlatListBox.vue_vue_type_script_setup_true_lang.js +53 -50
  327. package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js +146 -143
  328. package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js +7 -2
  329. package/dist/components/OptionsContainer/types.d.ts +14 -3
  330. package/dist/composables/useBbConfig.d.ts +1 -0
  331. package/dist/composables/useBbConfig.js +11 -7
  332. package/dist/composables/useBbFormContext.d.ts +4 -3
  333. package/dist/composables/useBbTabsContext.js +99 -85
  334. package/dist/composables/useChoiceIndicator.d.ts +58 -0
  335. package/dist/composables/useChoiceIndicator.js +197 -0
  336. package/dist/composables/useConfirm.d.ts +4 -4
  337. package/dist/composables/usePassthrough.d.ts +54 -1
  338. package/dist/composables/usePassthrough.js +100 -71
  339. package/dist/directives/bbTooltip.d.ts +12 -6
  340. package/dist/directives/createPopoverDirective.js +1 -1
  341. package/dist/index.d.ts +3 -1
  342. package/dist/llms-full.txt +3467 -801
  343. package/dist/llms-medium.txt +71 -53
  344. package/dist/llms.txt +2 -1
  345. package/dist/passthrough-deduper.js +6 -3
  346. package/dist/project-dts.d.ts +24 -0
  347. package/dist/project-dts.js +43 -17
  348. package/dist/styles.css +2 -2
  349. package/dist/types/AlertVariant.d.ts +14 -0
  350. package/dist/types/AlertVariant.js +9 -0
  351. package/dist/types/BadgeVariant.d.ts +14 -0
  352. package/dist/types/BadgeVariant.js +9 -0
  353. package/dist/types/ButtonVariant.d.ts +16 -0
  354. package/dist/types/ButtonVariant.js +11 -0
  355. package/dist/types/CheckboxVariant.d.ts +38 -0
  356. package/dist/types/CheckboxVariant.js +4 -0
  357. package/dist/types/CommonProps.d.ts +4 -3
  358. package/dist/types/Config.d.ts +7 -0
  359. package/dist/types/ConfirmVariant.d.ts +12 -0
  360. package/dist/types/ConfirmVariant.js +4 -0
  361. package/dist/types/DropdownItemVariant.d.ts +12 -0
  362. package/dist/types/DropdownItemVariant.js +4 -0
  363. package/dist/types/IndicatorVariant.d.ts +15 -0
  364. package/dist/types/IndicatorVariant.js +10 -0
  365. package/dist/types/InputVariant.d.ts +13 -0
  366. package/dist/types/InputVariant.js +8 -0
  367. package/dist/types/RadioVariant.d.ts +38 -0
  368. package/dist/types/RadioVariant.js +4 -0
  369. package/dist/types/TabsVariant.d.ts +13 -0
  370. package/dist/types/TabsVariant.js +8 -0
  371. package/dist/types/ToastVariant.d.ts +15 -0
  372. package/dist/types/ToastVariant.js +10 -0
  373. package/dist/types/TooltipVariant.d.ts +12 -0
  374. package/dist/types/TooltipVariant.js +4 -0
  375. package/dist/types/passthrough.d.ts +83 -15
  376. package/dist/types/passthrough.js +2 -2
  377. package/dist/types/ptComponentMap.d.ts +35 -23
  378. package/dist/utilities/functions/extractDomContainer.d.ts +20 -1
  379. package/dist/utilities/functions/extractDomContainer.js +8 -3
  380. package/dist/utils/focusVisibility.d.ts +6 -0
  381. package/dist/utils/focusVisibility.js +4 -1
  382. package/dist/utils/passthroughDeduper.d.ts +14 -0
  383. package/dist/utils/versionCheck.js +1 -1
  384. package/dist/vite-plugin.d.ts +64 -7
  385. package/dist/vite.js +385 -259
  386. package/llms.txt +2 -1
  387. package/package.json +5 -4
  388. package/scripts/lib/adoption-checklist.json +312 -0
  389. package/scripts/lib/eslint-plugin.d.ts +13 -0
  390. package/scripts/lib/eslint-plugin.mjs +75 -11
  391. package/scripts/lib/helpers-add.mjs +26 -2
  392. package/scripts/lib/idiom-scan.mjs +65 -0
  393. package/scripts/lib/mcp-config.mjs +203 -9
  394. package/scripts/lib/migrate-fix.mjs +42 -1
  395. package/scripts/lib/project-variant-dts.mjs +18 -0
  396. package/scripts/lib/validate-bb-markup.mjs +99 -2
@@ -34,13 +34,27 @@
34
34
  </Transition>
35
35
  <!-- `passthrough.icon` is a BROADCAST: the same binding lands on whichever content
36
36
  icons render (at most two of the three). Bound LAST on each so a
37
- consumer attribute beats ours and a consumer class appends. -->
37
+ consumer attribute beats ours and a consumer class appends. An icon
38
+ slot (Q81.4) beats its prop and renders INSIDE the part, a box of the
39
+ same class, so `pt:icon`, `--icon-size` and the spinner swap hold. -->
40
+ <span
41
+ v-if="slots.icon"
42
+ class="bb-button__icon bb-button__icon-slot"
43
+ v-bind="passthrough.icon"
44
+ ><slot name="icon" v-bind="iconScope"
45
+ /></span>
38
46
  <BbIcon
39
- v-if="props['icon']"
47
+ v-else-if="props['icon']"
40
48
  class="bb-button__icon"
41
49
  :icon="props['icon']"
42
50
  v-bind="passthrough.icon"
43
51
  />
52
+ <span
53
+ v-else-if="slots['prepend:icon']"
54
+ class="bb-button__prepend-icon bb-button__icon-slot"
55
+ v-bind="passthrough.icon"
56
+ ><slot name="prepend:icon" v-bind="iconScope"
57
+ /></span>
44
58
  <BbIcon
45
59
  v-else-if="props['prepend:icon']"
46
60
  class="bb-button__prepend-icon"
@@ -49,20 +63,28 @@
49
63
  />
50
64
  <span
51
65
  class="bb-button__text"
52
- :class="{ 'bb-sr-only': !!icon }"
66
+ :class="{ 'bb-sr-only': iconOnly }"
53
67
  v-bind="passthrough.text"
54
- ><slot>{{ text }}</slot></span
68
+ ><slot v-bind="linkState">{{ text }}</slot></span
55
69
  >
56
70
  <span v-if="loading" class="bb-button__loading-label bb-sr-only">{{
57
71
  t('common.loadingText')
58
72
  }}</span>
59
73
 
60
- <BbIcon
61
- v-if="!icon && props['append:icon']"
62
- class="bb-button__append-icon"
63
- :icon="props['append:icon']"
64
- v-bind="passthrough.icon"
65
- />
74
+ <template v-if="!iconOnly">
75
+ <span
76
+ v-if="slots['append:icon']"
77
+ class="bb-button__append-icon bb-button__icon-slot"
78
+ v-bind="passthrough.icon"
79
+ ><slot name="append:icon" v-bind="iconScope"
80
+ /></span>
81
+ <BbIcon
82
+ v-else-if="props['append:icon']"
83
+ class="bb-button__append-icon"
84
+ :icon="props['append:icon']"
85
+ v-bind="passthrough.icon"
86
+ />
87
+ </template>
66
88
  </BbBaseButton>
67
89
  </template>
68
90
 
@@ -79,15 +101,23 @@ import { useLogger } from '@/composables/useLogger';
79
101
  import { useUntil } from '../../composables/useUntil';
80
102
  import { removedPropsFor } from '@/deprecation/removedProps';
81
103
  import { warnRemovedAttrs } from '@/utilities/functions/warnRemovedAttrs';
82
- import { extractDomContainer } from '@/utilities/functions/extractDomContainer';
104
+ import { extractHtmlContainer } from '@/utilities/functions/extractDomContainer';
83
105
  import { isEqual } from '@/utilities/functions/isEqual';
84
- import { usePassthrough } from '@/composables/usePassthrough';
85
- import { BB_BUTTON_PT, type BbButtonProps, type BbButtonSlots } from './types';
106
+ import { usePassthrough, variantPt } from '@/composables/usePassthrough';
107
+ import {
108
+ BB_BUTTON_PT,
109
+ type BbButtonIconSlotProps,
110
+ type BbButtonProps,
111
+ type BbButtonSlots,
112
+ } from './types';
86
113
  import { useToggleRoving } from './toggleRoving';
114
+ import { provideLinkState, useLinkState } from '../BbBaseButton/useLinkState';
87
115
  import type { Sizes as SizeMap } from '@/types/SizeScale';
88
116
  type Sizes = keyof SizeMap;
89
117
 
90
118
  defineOptions({
119
+ // An app's own variants as declared `pt:<part>:<name>` props (Q76.7).
120
+ mixins: [variantPt(BB_BUTTON_PT)],
91
121
  inheritAttrs: false,
92
122
  });
93
123
  /**
@@ -102,7 +132,7 @@ const props = withDefaults(defineProps<BbButtonProps>(), {
102
132
  trueValue: true,
103
133
  variant: 'primary',
104
134
  });
105
- defineSlots<BbButtonSlots>();
135
+ const slots = defineSlots<BbButtonSlots>();
106
136
 
107
137
  if (process.env.NODE_ENV !== 'production')
108
138
  warnRemovedAttrs('BbButton', removedPropsFor('BbButton'));
@@ -134,7 +164,7 @@ if (process.env.NODE_ENV !== 'production') {
134
164
  }
135
165
 
136
166
  const setButtonRef = (el: unknown) => {
137
- buttonDom.value = extractDomContainer(el) ?? undefined;
167
+ buttonDom.value = extractHtmlContainer(el) ?? undefined;
138
168
  };
139
169
 
140
170
  // `class` is not forwarded: it is the instance's base `root` passthrough entry
@@ -176,6 +206,21 @@ const loading = computed(
176
206
  /** Latches on the first load; gates the spinner's <Transition> — see the template. */
177
207
  const hasLoadedOnce = useUntil(loading);
178
208
 
209
+ /** Whether the link points at the current page: `pt` states and slot props, here and in the base button. */
210
+ const linkState = useLinkState(props);
211
+ provideLinkState(linkState);
212
+
213
+ /** An icon-only button: the `icon` prop or slot, the label visually hidden. */
214
+ const iconOnly = computed(() => !!props.icon || !!slots.icon);
215
+
216
+ /** What an icon slot sees: the button's `pt` states (Q81.4). */
217
+ const iconScope = computed<BbButtonIconSlotProps>(() => ({
218
+ ...linkState.value,
219
+ pressed: isToggle.value && isPressed.value,
220
+ loading: loading.value,
221
+ disabled: !!props.disabled,
222
+ }));
223
+
179
224
  /**
180
225
  * Passthrough (plans/passthrough/BbButton.md — the exemplar). Named
181
226
  * `passthrough`, not `pt`: in the template a bare `pt` is the `pt` PROP (the
@@ -193,7 +238,10 @@ const passthrough = usePassthrough({
193
238
  loading: () => loading.value,
194
239
  disabled: () => !!props.disabled,
195
240
  pressed: () => isToggle.value && isPressed.value,
241
+ activeLink: () => linkState.value.activeLink,
242
+ exactActiveLink: () => linkState.value.exactActiveLink,
196
243
  },
244
+ variant: { ...BB_BUTTON_PT.variant, current: () => props.variant },
197
245
  });
198
246
 
199
247
  const onClick = async (event: Event) => {
@@ -352,7 +400,7 @@ const rootBindings = computed(() =>
352
400
  'bb-button--loading': loading.value,
353
401
  'bb-button--soft-disabled': softDisabled.value,
354
402
  'bb-button--group': props.group,
355
- 'bb-button--icon': !!props.icon,
403
+ 'bb-button--icon': iconOnly.value,
356
404
  'bb-button--pressed': isToggle.value && isPressed.value,
357
405
  [`bb-button--${props.variant}`]: props.variant !== 'none',
358
406
  },
@@ -384,9 +432,15 @@ defineExpose({ $el: buttonDom });
384
432
  import type { RouteLocationRaw } from 'vue-router';
385
433
  import type { ButtonTag } from '@/types/CommonProps';
386
434
  import type { IconType } from '@/types/Icon';
387
- import type { ButtonVariantType } from '@/types/ButtonVariant';
435
+ import {
436
+ BUTTON_VARIANTS,
437
+ type ButtonVariantBuiltIn,
438
+ type ButtonVariantRegistry,
439
+ type ButtonVariantType,
440
+ } from '@/types/ButtonVariant';
388
441
  import type { Responsive } from '@/types/ResponsiveSize';
389
- import type { PtMap, PtValue } from '@/types/passthrough';
442
+ import type { PtMap, PtValue, PtVariantAttrs } from '@/types/passthrough';
443
+ import type { BbLinkSlotProps } from '../BbBaseButton/types';
390
444
 
391
445
  type Sizes = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';
392
446
 
@@ -411,26 +465,43 @@ type Sizes = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';
411
465
  export type BbButtonPtPart = 'root' | 'icon' | 'spinner' | 'text';
412
466
  /**
413
467
  * Passthrough states of `BbButton`: true while `--loading` / `--disabled` /
414
- * `--pressed`. There is no `active` state (the pointer press is Tailwind's
415
- * `active:` variant) and no `current` state (a link to the current route is
416
- * `activeClass` / `exactActiveClass`).
468
+ * `--pressed`, and for a link while `activeClass` / `exactActiveClass` are on.
469
+ * There is no `active` state (the pointer press is Tailwind's `active:`
470
+ * variant). A link to the current page is `activeLink` / `exactActiveLink`,
471
+ * on every part: the sidebar entry of the page you are on styles its root,
472
+ * icon and text from them, and the default slot gets the same two booleans.
417
473
  *
474
+ * @state activeLink - Component-wide: a link to the current page or one of
475
+ * its ancestors (`/users` on `/users/5`) — exactly when `activeClass` is on.
476
+ * The weakest state: `pressed`, `disabled` and `loading` win a conflict.
477
+ * @state exactActiveLink - Component-wide: a link to the current page itself
478
+ * — exactly when `exactActiveClass` is on (`activeLink` is on too, so its
479
+ * entries apply first and these win).
418
480
  * @state disabled - Component-wide: the button is `disabled`.
419
481
  * @state loading - Component-wide: `loading` is on — the spinner shows and
420
482
  * the button ignores the pointer.
421
483
  * @state pressed - Component-wide: a toggle button (`v-model`) is on —
422
484
  * `aria-pressed="true"`, `--pressed` on the root.
423
485
  */
424
- export type BbButtonPtState = 'loading' | 'disabled' | 'pressed';
486
+ export type BbButtonPtState =
487
+ | 'activeLink'
488
+ | 'exactActiveLink'
489
+ | 'loading'
490
+ | 'disabled'
491
+ | 'pressed';
425
492
  /** The runtime lists the resolver is wired with — kept next to the types so the two cannot drift. */
426
493
  export const BB_BUTTON_PT = {
427
494
  parts: ['root', 'icon', 'spinner', 'text'],
428
495
  // Order = precedence, last wins: a pressed toggle that is also disabled or
429
- // loading shows the disabled / loading styling.
430
- states: ['pressed', 'disabled', 'loading'],
496
+ // loading shows the disabled / loading styling; the link states sit below
497
+ // all three.
498
+ states: ['activeLink', 'exactActiveLink', 'pressed', 'disabled', 'loading'],
499
+ // The `variant` is a state on every part (Q76.7), below the real ones.
500
+ variant: { names: BUTTON_VARIANTS, option: 'buttonVariants' },
431
501
  } as const satisfies {
432
502
  parts: readonly BbButtonPtPart[];
433
503
  states: readonly BbButtonPtState[];
504
+ variant: { names: readonly ButtonVariantBuiltIn[]; option: string };
434
505
  };
435
506
 
436
507
  // The passthrough props are a mapped type written INLINE with this
@@ -445,15 +516,23 @@ export const BB_BUTTON_PT = {
445
516
  export type BbButtonProps = {
446
517
  [K in
447
518
  | `pt:${BbButtonPtPart}`
448
- | `pt:${BbButtonPtPart}:${BbButtonPtState}`]?: PtValue;
449
- } & {
450
- /**
451
- * Passthrough, object form: `{ icon: '…', 'icon:loading': '…' }` — the same
452
- * keys as the `pt:*` attributes without the prefix. Parts: `root`, `icon`,
453
- * `spinner`, `text`. States: `loading`, `disabled`.
454
- */
455
- pt?: PtMap<BbButtonPtPart, BbButtonPtState>;
456
- } & BbButtonOwnProps;
519
+ | `pt:${BbButtonPtPart}:${BbButtonPtState}`
520
+ | `pt:${BbButtonPtPart}:${ButtonVariantBuiltIn}`]?: PtValue;
521
+ } & /* @vue-ignore */ PtVariantAttrs<
522
+ BbButtonPtPart,
523
+ keyof ButtonVariantRegistry
524
+ > & {
525
+ /**
526
+ * Passthrough, object form: `{ icon: '…', 'icon:loading': '…' }` — the same
527
+ * keys as the `pt:*` attributes without the prefix. Parts: `root`, `icon`,
528
+ * `spinner`, `text`. States: `loading`, `disabled`, `pressed`, and the
529
+ * registered variants (an app's own included).
530
+ */
531
+ pt?: PtMap<
532
+ BbButtonPtPart,
533
+ BbButtonPtState | ButtonVariantBuiltIn | keyof ButtonVariantRegistry
534
+ >;
535
+ } & BbButtonOwnProps;
457
536
 
458
537
  /**
459
538
  * BbButton's props without its passthrough. `BbDropdownButton` takes them for
@@ -797,11 +876,35 @@ export type BbButtonOwnProps = {
797
876
  viewTransition?: boolean;
798
877
  };
799
878
 
879
+ /**
880
+ * What `#icon` / `#prepend:icon` / `#append:icon` see: the button's `pt`
881
+ * states, so a glyph can follow them (a filled icon on the current page's link).
882
+ */
883
+ export type BbButtonIconSlotProps = BbLinkSlotProps & {
884
+ /** A toggle (`v-model`) that is on. */
885
+ pressed: boolean;
886
+ /** Loading, the automatic loading included: the spinner shows. */
887
+ loading: boolean;
888
+ /** The `disabled` prop. */
889
+ disabled: boolean;
890
+ };
891
+
800
892
  export type BbButtonSlots = {
801
893
  /**
802
- * Primary content rendered inside the button. Falls back to the `text` prop when empty.
894
+ * Primary content rendered inside the button. Falls back to the `text` prop
895
+ * when empty. A link's slot gets `{ activeLink, exactActiveLink }`: whether it
896
+ * points at the current page (both `false` on a button).
803
897
  */
804
- default?: (props: object) => any;
898
+ default?: (props: BbLinkSlotProps) => any;
899
+ /**
900
+ * The icon of an icon-only button, replacing the `icon` prop. Renders inside
901
+ * the `icon` part: `pt:icon`, `--icon-size` and the loading spinner apply.
902
+ */
903
+ icon?: (props: BbButtonIconSlotProps) => any;
904
+ /** The leading icon, replacing `prepend:icon`; inside the `icon` part. */
905
+ 'prepend:icon'?: (props: BbButtonIconSlotProps) => any;
906
+ /** The trailing icon, replacing `append:icon`; inside the `icon` part. */
907
+ 'append:icon'?: (props: BbButtonIconSlotProps) => any;
805
908
  };
806
909
  ```
807
910
 
@@ -1181,7 +1284,8 @@ export type BbButtonSlots = {
1181
1284
  .bb-spinner {
1182
1285
  /* Whatever icon the spinner is parked on top of — the icon-only glyph
1183
1286
  or the prepend icon — fades out from under it. */
1184
- + .bb-icon {
1287
+ + .bb-icon,
1288
+ + .bb-button__icon-slot {
1185
1289
  opacity: 0;
1186
1290
  }
1187
1291
 
@@ -1322,6 +1426,19 @@ export type BbButtonSlots = {
1322
1426
  width: var(--icon-size);
1323
1427
  }
1324
1428
 
1429
+ /* An icon slot's box (Q81.4): it is the `icon` part, the consumer's glyph
1430
+ sits centred in it, and a BbIcon there takes the part's size, as the
1431
+ prop's own BbIcon does. */
1432
+ .bb-button__icon-slot {
1433
+ align-items: center;
1434
+ display: inline-flex;
1435
+ justify-content: center;
1436
+
1437
+ > .bb-icon {
1438
+ --size: var(--icon-size);
1439
+ }
1440
+ }
1441
+
1325
1442
  /* The spinner mounts only while loading (plus its fade-out), first in the
1326
1443
  DOM and at zero layout cost: its width plus the flex gap are cancelled
1327
1444
  by an equal negative margin, so it lands exactly on top of the neighbour
@@ -59,6 +59,7 @@
59
59
  :has-errors="fieldHasErrors"
60
60
  :has-warnings="fieldHasWarnings"
61
61
  :hide-label="hideLabel"
62
+ :indicator-ready="indicatorReady"
62
63
  :item-input-align="itemInputAlign"
63
64
  :item-label-align="itemLabelAlign"
64
65
  :item-layout="itemLayout"
@@ -68,8 +69,22 @@
68
69
  :loading-text="loadingText"
69
70
  :options="options"
70
71
  :passthrough="passthrough"
72
+ :variant="variant"
71
73
  >
72
- <template #prepend><slot name="prepend"></slot></template>
74
+ <template #prepend>
75
+ <!-- The `variant` indicators (Q76.11 d): first in the list, so the
76
+ positioned rows paint over them; hidden from the tree (the
77
+ checked state is the inputs'). -->
78
+ <span
79
+ v-for="box in indicatorBoxes"
80
+ :key="box.key"
81
+ aria-hidden="true"
82
+ class="bb-checkbox-group__indicator"
83
+ :style="indicatorStyle(box)"
84
+ v-bind="passthrough.indicator"
85
+ ></span>
86
+ <slot name="prepend"></slot>
87
+ </template>
73
88
  <template #loading><slot name="loading"></slot></template>
74
89
  <template #empty="data"
75
90
  ><slot name="empty" v-bind="data"></slot
@@ -135,6 +150,7 @@ import {
135
150
  formControlPtActive,
136
151
  pickActive,
137
152
  usePassthrough,
153
+ variantPt,
138
154
  } from '@/composables/usePassthrough';
139
155
  import {
140
156
  computed,
@@ -159,6 +175,7 @@ import {
159
175
  toggleInputValue,
160
176
  } from '@/utilities/functions/toggleInput';
161
177
  import { useToggleListFocus } from '@/composables/useToggleInput';
178
+ import { useChoiceIndicator } from '@/composables/useChoiceIndicator';
162
179
  import { useItemsGetter } from '@/composables/useItemsGetter';
163
180
  import { useIndexById } from '../../composables/useIndexById';
164
181
  import { useBaseOptions } from '@/composables/useBaseOptions';
@@ -180,7 +197,11 @@ import {
180
197
  } from './types';
181
198
  import { useFormBinding } from '@/composables/useFormBinding';
182
199
 
183
- defineOptions({ inheritAttrs: false });
200
+ defineOptions({
201
+ // An app's own variants as declared `pt:<part>:<name>` props (Q76.7).
202
+ mixins: [variantPt(BB_CHECKBOX_GROUP_PT)],
203
+ inheritAttrs: false,
204
+ });
184
205
  const declaredProps = withDefaults(defineProps<BbCheckboxGroupProps<T>>(), {
185
206
  inputPosition: 'left',
186
207
  multiple: true,
@@ -396,6 +417,7 @@ const passthrough = usePassthrough({
396
417
  props,
397
418
  parts: BB_CHECKBOX_GROUP_PT.parts,
398
419
  states: BB_CHECKBOX_GROUP_PT.states,
420
+ variant: { ...BB_CHECKBOX_GROUP_PT.variant, current: () => props.variant },
399
421
  active: {
400
422
  ...pickActive(
401
423
  formControlPtActive(props, () => passthroughHasValue.value),
@@ -404,6 +426,28 @@ const passthrough = usePassthrough({
404
426
  loading: () => loading.value,
405
427
  },
406
428
  });
429
+ /**
430
+ * BbTabs' look (`variant`, Q76.11 d): the indicators under the checked rows,
431
+ * measured on the list. A pill per run of adjacent picks (`pill`), a bar per pick (`line`).
432
+ */
433
+ /** `list-layout="vertical"` / `"vertical-stretch"` stack the strip into a column. */
434
+ const stripVertical = computed(
435
+ () =>
436
+ props.listLayout === 'vertical' || props.listLayout === 'vertical-stretch'
437
+ );
438
+ const {
439
+ boxes: indicatorBoxes,
440
+ ready: indicatorReady,
441
+ styleOf: indicatorStyle,
442
+ } = useChoiceIndicator({
443
+ kind: 'checkbox',
444
+ variant: () => props.variant,
445
+ vertical: () => stripVertical.value,
446
+ list: () => optionsElement.value,
447
+ rows: () => options.value,
448
+ rowClass: 'bb-checkbox-group__item',
449
+ });
450
+
407
451
  /** The container names the heading `label`; this group names it `legend`, after its props. */
408
452
  const containerPassthrough = aliasParts(passthrough, { label: 'legend' });
409
453
 
@@ -474,7 +518,7 @@ const rowListeners = (option: Option) => ({
474
518
  onMouseup: (event: MouseEvent) => emit('mouseup', event),
475
519
  });
476
520
 
477
- /** One row's native checkbox: named by its text when described, described by the group then its own description. */
521
+ /** One row's native checkbox: named by its text alone, described by the group then its own description. */
478
522
  const rowInputAttrs = (
479
523
  option: Option,
480
524
  index: number,
@@ -535,18 +579,26 @@ const rowIconSlotProps = (
535
579
 
536
580
  ```ts
537
581
  import type { Responsive } from '@/types/ResponsiveSize';
582
+ import {
583
+ CHECKBOX_VARIANTS,
584
+ type CheckboxVariantBuiltIn,
585
+ type CheckboxVariantRegistry,
586
+ type CheckboxVariantType,
587
+ } from '@/types/CheckboxVariant';
538
588
  import type { BbOptionGroupItemProps } from '@/types/ItemProps';
539
589
  import type { HTMLAttributes, InputHTMLAttributes } from 'vue';
540
590
  import {
541
- GROUP_PT_PARTS,
591
+ CHOICE_PT_PARTS,
592
+ type PtVariantAttrs,
542
593
  GROUP_PT_STATES,
543
594
  GROUP_ROW_PT_PARTS,
544
595
  GROUP_ROW_PT_STATES,
596
+ type ChoiceFieldPtPart,
597
+ type ChoicePtMap,
598
+ type ChoicePtPart,
545
599
  type GroupFieldPtPart,
546
- type GroupPtMap,
547
600
  type GroupRowPtPart,
548
601
  type GroupWidePtState,
549
- type GroupPtPart,
550
602
  type GroupPtState,
551
603
  type PtItemCtx,
552
604
  type PtNoInfer,
@@ -569,46 +621,50 @@ import type { CommonFieldAsteriskSlotProps } from '../CommonField/types';
569
621
  *
570
622
  * Per-item functions: on the instance, a row part (`item`, `icon`, `label`, `itemDescription`) also accepts `({ item, checked, … }) => PtValue | false | null | undefined` — `item` is the raw item of that row, and every state a boolean beside it, on for it (`checked`, `disabled`, …) — in the `pt` object or the `:pt:<part>` attribute, never on a `<part>:<state>` key and never in the global map or a scope (they ship as JSON). Its result is merged last, after every state entry, through the same deduper; a falsy result leaves the row as it was. See the passthrough guide, _Per-item functions_.
571
623
  */
572
- export type BbCheckboxGroupPtPart = GroupPtPart;
624
+ export type BbCheckboxGroupPtPart = ChoicePtPart;
573
625
  /** Passthrough states of `BbCheckboxGroup`, true while the matching `--` modifier is on. */
574
626
  export type BbCheckboxGroupPtState = GroupPtState;
575
627
  /** The runtime lists the resolver is wired with — kept next to the types so the two cannot drift. */
576
628
  export const BB_CHECKBOX_GROUP_PT = {
577
- parts: GROUP_PT_PARTS,
629
+ parts: CHOICE_PT_PARTS,
578
630
  states: GROUP_PT_STATES,
579
631
  /** `rowStates` are declared on `rowParts` only — the field parts never have them. */
580
632
  rowParts: GROUP_ROW_PT_PARTS,
581
633
  rowStates: GROUP_ROW_PT_STATES,
634
+ // The `variant` is a state on every part (Q76.7).
635
+ variant: { names: CHECKBOX_VARIANTS, option: 'checkboxVariants' },
582
636
  } as const satisfies {
583
637
  parts: readonly BbCheckboxGroupPtPart[];
584
638
  states: readonly BbCheckboxGroupPtState[];
585
639
  rowParts: readonly GroupRowPtPart[];
586
640
  rowStates: readonly BbCheckboxGroupPtState[];
641
+ variant: { names: readonly CheckboxVariantBuiltIn[]; option: string };
587
642
  };
588
643
 
589
644
  // Spelled INLINE with this component's own unions (Vue's SFC type resolver
590
645
  // does not substitute a generic alias's type parameters — PASSTHROUGH.md T20).
591
646
  // Two mapped types, never `Partial<Record<…>>`: the lint autofix rewrites one
592
647
  // into the other and the SFC resolver reads only the mapped spelling (T23).
648
+ /**
649
+ * The props BbCheckboxGroup shares with BbSwitchGroup: everything but the
650
+ * object `pt` (each spells its own), the `variant` (a tab-strip look, Q76.11
651
+ * d), its `indicator` part and its pt states, which are the checkbox group's
652
+ * alone.
653
+ */
593
654
  /* eslint-disable @typescript-eslint/consistent-indexed-object-style */
594
- export type BbCheckboxGroupProps<T> = {
655
+ export type BbCheckboxGroupBaseProps<T> = {
595
656
  [K in
596
657
  | `pt:${GroupFieldPtPart}`
597
658
  | `pt:${GroupFieldPtPart}:${GroupWidePtState}`
598
- | `pt:${GroupRowPtPart}:${BbCheckboxGroupPtState}`]?: PtValue;
659
+ | `pt:${GroupRowPtPart}:${GroupPtState}`]?: PtValue;
599
660
  } & {
600
661
  // The row parts also take a per-item function, typed on this group's
601
662
  // item — a literal function type, not `PtItemFn<T, …>` (T23).
602
663
  [K in `pt:${GroupRowPtPart}`]?:
603
664
  | PtValue
604
- | ((ctx: PtItemCtx<PtNoInfer<T>, BbCheckboxGroupPtState>) => PtItemResult);
665
+ | ((ctx: PtItemCtx<PtNoInfer<T>, GroupPtState>) => PtItemResult);
605
666
  } & {
606
667
  /* eslint-enable @typescript-eslint/consistent-indexed-object-style */
607
- /**
608
- * Passthrough, object form: the same keys as the `pt:*` attributes
609
- * without the prefix. See the `pt:<part>` row.
610
- */
611
- pt?: GroupPtMap<PtNoInfer<T>>;
612
668
  /**
613
669
  * Focuses the field when it mounts (a dialog already open included), unless the user is typing in another field.
614
670
  */
@@ -945,6 +1001,33 @@ export type BbCheckboxGroupEvents = {
945
1001
  (e: 'update:modelValue', value: any): void;
946
1002
  };
947
1003
 
1004
+ /* eslint-disable @typescript-eslint/consistent-indexed-object-style */
1005
+ export type BbCheckboxGroupProps<T> = BbCheckboxGroupBaseProps<T> & {
1006
+ [K in
1007
+ | `pt:${ChoiceFieldPtPart}`
1008
+ | `pt:${ChoiceFieldPtPart}:${GroupWidePtState}`
1009
+ | `pt:${ChoiceFieldPtPart}:${CheckboxVariantBuiltIn}`
1010
+ | `pt:${GroupRowPtPart}:${CheckboxVariantBuiltIn}`]?: PtValue;
1011
+ } & /* @vue-ignore */ PtVariantAttrs<
1012
+ ChoicePtPart,
1013
+ keyof CheckboxVariantRegistry
1014
+ > & {
1015
+ /**
1016
+ * Passthrough, object form: the same keys as the `pt:*` attributes
1017
+ * without the prefix. See the `pt:<part>` row.
1018
+ */
1019
+ pt?: ChoicePtMap<PtNoInfer<T>> & {
1020
+ [K in `${ChoicePtPart}:${CheckboxVariantBuiltIn | keyof CheckboxVariantRegistry}`]?: PtValue;
1021
+ };
1022
+ /* eslint-enable @typescript-eslint/consistent-indexed-object-style */
1023
+ /**
1024
+ * A tab-strip look (Q76.11 d): `'pill'` (a pill per run of adjacent picks)
1025
+ * or `'line'` (a bar under each pick). `list-layout="vertical"` stacks it.
1026
+ * Register more with `checkboxVariants`. Unset: the group's own rows.
1027
+ */
1028
+ variant?: CheckboxVariantType;
1029
+ };
1030
+
948
1031
  /**
949
1032
  * Props exposed by the `icon` slot for each option: the checkbox state plus
950
1033
  * the source item and its display text.
@@ -1048,6 +1131,8 @@ export type BbCheckboxGroupSlots<T> = {
1048
1131
  ## Styles
1049
1132
 
1050
1133
  ```css
1134
+ @import '../OptionsContainer/choice-strip.css';
1135
+
1051
1136
  .bb-checkbox-group {
1052
1137
  .bb-field__layout--horizontal {
1053
1138
  .bb-field__label {
@@ -1261,7 +1346,7 @@ export type BbCheckboxGroupSlots<T> = {
1261
1346
  }
1262
1347
  > :where(
1263
1348
  :not(
1264
- input,
1349
+ [type='hidden'],
1265
1350
  .bb-checkbox-group__label,
1266
1351
  .bb-checkbox-group__item-description
1267
1352
  )
@@ -1294,7 +1379,7 @@ export type BbCheckboxGroupSlots<T> = {
1294
1379
  )
1295
1380
  > :where(
1296
1381
  :not(
1297
- input,
1382
+ [type='hidden'],
1298
1383
  .bb-checkbox-group__label,
1299
1384
  .bb-checkbox-group__item-description
1300
1385
  )
@@ -1368,6 +1453,19 @@ export type BbCheckboxGroupSlots<T> = {
1368
1453
  }
1369
1454
  }
1370
1455
 
1456
+ /* A side hidden with the library's or Tailwind's hiding classes takes its gap
1457
+ with it (ATT-11 e): `hideLabel` / `pt:label="sr-only"` (out of flow) or
1458
+ `pt:icon="hidden"` would leave an empty track AND the gap beside it (the
1459
+ row gap in a `vertical` item, Q76.11 c), and the side still shown sat
1460
+ off-centre. `:where` keeps the rule at the row's
1461
+ one class, so a consumer `gap-*` on `pt:item` still wins. */
1462
+ .bb-checkbox-group__item:where(
1463
+ :has(> .bb-checkbox-group__label:is(.bb-sr-only, .sr-only)),
1464
+ :has(> .bb-toggle-input + :is(.hidden, .sr-only, .bb-sr-only))
1465
+ ) {
1466
+ gap: 0;
1467
+ }
1468
+
1371
1469
  .bb-checkbox-group__label {
1372
1470
  color: var(--bb-text);
1373
1471
  font-size: var(--bb-label-fs);
@@ -1400,6 +1498,32 @@ export type BbCheckboxGroupSlots<T> = {
1400
1498
  user-select: none;
1401
1499
  }
1402
1500
 
1501
+ /*
1502
+ * `tiles` (ATT-11 d): the invisible native input covers the WHOLE tile,
1503
+ * padding included, not only the glyph's cell, so a click, a hover tooltip on
1504
+ * the input and a test runner's hit-target check land on it anywhere on the
1505
+ * tile. `grid-area: auto` is load-bearing: an absolutely positioned grid child
1506
+ * is sized against its grid area, so `inset: 0` would still be the glyph
1507
+ * cell. A link or a button inside a tile sits above the input and keeps its
1508
+ * own click. List rows keep the cell overlay.
1509
+ */
1510
+ .bb-checkbox-group__list--tiles > .bb-checkbox-group__item {
1511
+ position: relative;
1512
+
1513
+ > .bb-toggle-input {
1514
+ border-radius: inherit;
1515
+ grid-area: auto;
1516
+ inset: 0;
1517
+ position: absolute;
1518
+ z-index: 1;
1519
+ }
1520
+
1521
+ :is(a, button) {
1522
+ position: relative;
1523
+ z-index: 2;
1524
+ }
1525
+ }
1526
+
1403
1527
  /* ---- Touch targets (Q44.19) -------------------------------------------
1404
1528
  * A row is one label line (`--bb-label-lh`, 18px) and the rows sit
1405
1529
  * `--row-gap` (10px) apart. On a coarse pointer only, each row gets an