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
@@ -1,19 +1,20 @@
1
- import { usePassthrough as e } from "../../composables/usePassthrough.js";
2
- import { useId as t } from "../../composables/useId.js";
3
- import { isTopEscapeEntry as n, pushEscapeEntry as ee, removeEscapeEntry as r } from "../../utils/overlayEscapeStack.js";
1
+ import { usePassthrough as e, variantPt as t } from "../../composables/usePassthrough.js";
2
+ import { useId as n } from "../../composables/useId.js";
3
+ import { isTopEscapeEntry as ee, pushEscapeEntry as te, removeEscapeEntry as r } from "../../utils/overlayEscapeStack.js";
4
4
  import { useUntil as i } from "../../composables/useUntil.js";
5
- import { useOverlayYield as te } from "../../composables/useOverlayYield.js";
6
- import { isWarm as ne, markHidden as a, markShown as re } from "./tooltipWarmup.js";
7
- import { removedPropsFor as ie } from "../../deprecation/removedProps.js";
8
- import { warnRemovedAttrs as ae } from "../../utilities/functions/warnRemovedAttrs.js";
9
- import { extractDomContainer as o } from "../../utilities/functions/extractDomContainer.js";
5
+ import { useOverlayYield as ne } from "../../composables/useOverlayYield.js";
6
+ import { isWarm as re, markHidden as a, markShown as ie } from "./tooltipWarmup.js";
7
+ import { removedPropsFor as ae } from "../../deprecation/removedProps.js";
8
+ import { warnRemovedAttrs as oe } from "../../utilities/functions/warnRemovedAttrs.js";
9
+ import { domElement as se, extractDomContainer as o } from "../../utilities/functions/extractDomContainer.js";
10
10
  import { transitions as s } from "../../utilities/misc/transitions.js";
11
- import oe from "../CommonPopover/CommonPopover.vue.js";
11
+ import ce from "../CommonPopover/CommonPopover.vue.js";
12
12
  import { BB_TOOLTIP_PT as c } from "./types.js";
13
- import { Comment as se, Fragment as ce, computed as l, createBlock as le, createCommentVNode as u, createElementBlock as d, createElementVNode as ue, createTextVNode as de, defineComponent as f, mergeModels as p, mergeProps as m, normalizeProps as fe, onBeforeUnmount as pe, onDeactivated as me, onMounted as he, openBlock as h, ref as g, renderSlot as _, toDisplayString as v, unref as y, useModel as ge, useSlots as _e, useTemplateRef as ve, watch as b, withCtx as ye } from "vue";
14
- import { useElementSize as be } from "@vueuse/core";
13
+ import { Comment as le, Fragment as ue, computed as l, createBlock as de, createCommentVNode as u, createElementBlock as d, createElementVNode as fe, createTextVNode as pe, defineComponent as f, mergeModels as p, mergeProps as m, normalizeProps as me, onBeforeUnmount as he, onDeactivated as ge, onMounted as h, openBlock as g, ref as _, renderSlot as v, toDisplayString as y, unref as b, useModel as _e, useSlots as ve, useTemplateRef as ye, watch as x, withCtx as be } from "vue";
14
+ import { useElementSize as xe } from "@vueuse/core";
15
15
  //#region src/components/BbTooltip/BbTooltip.vue?vue&type=script&setup=true&lang.ts
16
- var x = /*@__PURE__*/ f({
16
+ var S = /*@__PURE__*/ f({
17
+ mixins: [t(c)],
17
18
  inheritAttrs: !1,
18
19
  __name: "BbTooltip",
19
20
  props: /*@__PURE__*/ p({
@@ -21,6 +22,10 @@ var x = /*@__PURE__*/ f({
21
22
  "pt:panel": {},
22
23
  "pt:root:open": {},
23
24
  "pt:panel:open": {},
25
+ "pt:root:default": {},
26
+ "pt:root:destructive": {},
27
+ "pt:panel:default": {},
28
+ "pt:panel:destructive": {},
24
29
  pt: {},
25
30
  arrowPadding: { default: 10 },
26
31
  disabled: { type: Boolean },
@@ -44,30 +49,34 @@ var x = /*@__PURE__*/ f({
44
49
  modelModifiers: {}
45
50
  }),
46
51
  emits: ["update:modelValue"],
47
- setup(s) {
48
- let f = ge(s, "modelValue"), p = s, x = _e(), S = e({
52
+ setup(t) {
53
+ let s = _e(t, "modelValue"), f = t, p = ve(), S = e({
49
54
  component: "BbTooltip",
50
- props: p,
55
+ props: f,
51
56
  parts: c.parts,
52
57
  states: c.states,
53
- active: { open: () => f.value }
58
+ active: { open: () => s.value },
59
+ variant: {
60
+ ...c.variant,
61
+ current: () => f.variant
62
+ }
54
63
  });
55
- process.env.NODE_ENV !== "production" && ae("BbTooltip", ie("BbTooltip"));
56
- let xe = t().id.value, C = `bb_${p.id ?? xe}`, w = `${C}_desc`, T = (e) => {
64
+ process.env.NODE_ENV !== "production" && oe("BbTooltip", ae("BbTooltip"));
65
+ let Se = n().id.value, C = `bb_${f.id ?? Se}`, w = `${C}_desc`, T = (e) => {
57
66
  if (!e) return "";
58
67
  let t = "";
59
68
  for (let n of e) {
60
- if (n.type === se) continue;
69
+ if (n.type === le) continue;
61
70
  let e = n.children;
62
71
  typeof e == "string" ? t += e : Array.isArray(e) && (t += T(e));
63
72
  }
64
73
  return t;
65
- }, E = g(!1), D = l(() => (p.text ?? (E.value ? T(x.default?.({})) : "")).replace(/\s+/g, " ").trim()), O = g(), Se = l(() => p.activator != null), Ce = ve("popover"), k = l(() => o(Ce.value)), A = i(f), we = i(() => !!p.eager || f.value), j = g(!1), Te = () => {
74
+ }, E = _(!1), D = l(() => (f.text ?? (E.value ? T(p.default?.({})) : "")).replace(/\s+/g, " ").trim()), O = _(), Ce = l(() => f.activator != null), we = ye("popover"), k = l(() => o(we.value)), A = i(s), Te = i(() => !!f.eager || s.value), j = _(!1), Ee = () => {
66
75
  k.value?.getBoundingClientRect(), j.value = !0;
67
76
  }, M = l({
68
- get: () => f.value && j.value,
77
+ get: () => s.value && j.value,
69
78
  set: (e) => {
70
- f.value = e;
79
+ s.value = e;
71
80
  }
72
81
  }), N = (e) => {
73
82
  let t = o(e);
@@ -75,92 +84,97 @@ var x = /*@__PURE__*/ f({
75
84
  }, P, F, I = () => {
76
85
  clearTimeout(F);
77
86
  }, L = () => {
78
- clearTimeout(P), clearTimeout(F), f.value = !1;
87
+ clearTimeout(P), clearTimeout(F), s.value = !1;
79
88
  }, R = () => {
80
89
  clearTimeout(P), clearTimeout(F), F = setTimeout(L, 50);
81
90
  }, z = () => {
82
- I(), !(f.value || p.disabled || V()) && (P = setTimeout(() => {
83
- V() || (f.value = !0);
84
- }, ne() ? 0 : p.delay));
85
- }, Ee = () => {
86
- I(), clearTimeout(P), !(f.value || p.disabled || V()) && (f.value = !0);
87
- }, B = !1, { blocked: V } = te(() => O.value, () => k.value, () => {
91
+ I(), !(s.value || f.disabled || V()) && (P = setTimeout(() => {
92
+ V() || (s.value = !0);
93
+ }, re() ? 0 : f.delay));
94
+ }, De = () => {
95
+ I(), clearTimeout(P), !(s.value || f.disabled || V()) && (s.value = !0);
96
+ }, B = !1, { blocked: V } = ne(() => O.value, () => k.value, () => {
88
97
  B = !0, L();
89
98
  }), H = () => L(), U = Symbol("bb-tooltip-escape"), W = (e) => {
90
- e.key !== "Escape" || !n(U) || (e.preventDefault(), e.stopImmediatePropagation(), L());
99
+ e.key !== "Escape" || !ee(U) || (e.preventDefault(), e.stopImmediatePropagation(), L());
91
100
  }, G = (e) => {
92
- e.currentTarget?.matches(":focus-visible") && Ee();
101
+ e.currentTarget?.matches(":focus-visible") && De();
93
102
  }, K = !1;
94
- b(f, (e) => {
95
- e && !K ? (K = !0, re()) : !e && K && (K = !1, a(!B)), B = !1, e ? (ee(U, {
103
+ x(s, (e) => {
104
+ e && !K ? (K = !0, ie()) : !e && K && (K = !1, a(!B)), B = !1, e ? (te(U, {
96
105
  element: () => k.value,
97
106
  transient: !0
98
107
  }), document.addEventListener("keydown", W, { capture: !0 })) : (r(U), document.removeEventListener("keydown", W, { capture: !0 }));
99
- }), b(() => p.disabled, (e) => {
108
+ }), x(() => f.disabled, (e) => {
100
109
  e && L();
101
- }), b(() => p.activator, (e) => {
102
- e && N(e);
110
+ });
111
+ let q = _(!1);
112
+ h(() => {
113
+ q.value = !0;
114
+ }), x([() => f.activator, q], ([e, t]) => {
115
+ typeof e == "string" ? t && N(document.querySelector(e)) : e && N(e);
103
116
  }, { immediate: !0 });
104
- let q = null;
105
- b(O, (e) => {
106
- q &&= (q(), null), e && (e.addEventListener("mouseenter", z, { passive: !0 }), e.addEventListener("mouseleave", R, { passive: !0 }), e.addEventListener("focus", G, { passive: !0 }), e.addEventListener("blur", L, { passive: !0 }), e.addEventListener("pointerdown", H, { passive: !0 }), e.addEventListener("contextmenu", H, { passive: !0 }), q = () => {
117
+ let J = null;
118
+ x(O, (e) => {
119
+ J &&= (J(), null), e && (e.addEventListener("mouseenter", z, { passive: !0 }), e.addEventListener("mouseleave", R, { passive: !0 }), e.addEventListener("focus", G, { passive: !0 }), e.addEventListener("blur", L, { passive: !0 }), e.addEventListener("pointerdown", H, { passive: !0 }), e.addEventListener("contextmenu", H, { passive: !0 }), J = () => {
107
120
  e.removeEventListener("mouseenter", z), e.removeEventListener("mouseleave", R), e.removeEventListener("focus", G), e.removeEventListener("blur", L), e.removeEventListener("pointerdown", H), e.removeEventListener("contextmenu", H);
108
121
  });
109
122
  }, { immediate: !0 });
110
- let J = null;
111
- b(k, (e) => {
112
- J &&= (J(), null), e && (e.addEventListener("mouseenter", I, { passive: !0 }), e.addEventListener("mouseleave", R, { passive: !0 }), J = () => {
123
+ let Y = null;
124
+ x(k, (e) => {
125
+ Y &&= (Y(), null), e && (e.addEventListener("mouseenter", I, { passive: !0 }), e.addEventListener("mouseleave", R, { passive: !0 }), Y = () => {
113
126
  e.removeEventListener("mouseenter", I), e.removeEventListener("mouseleave", R);
114
127
  });
115
128
  }, { immediate: !0 });
116
- let De = /* @__PURE__ */ new Set([C, w]), Y = null, X = (e, t) => {
117
- let n = (e.getAttribute("aria-describedby") ?? "").split(/\s+/).filter((e) => e && !De.has(e));
129
+ let Oe = /* @__PURE__ */ new Set([C, w]), X = null, Z = (e, t) => {
130
+ let n = (e.getAttribute("aria-describedby") ?? "").split(/\s+/).filter((e) => e && !Oe.has(e));
118
131
  t && n.push(t), n.length ? e.setAttribute("aria-describedby", n.join(" ")) : e.removeAttribute("aria-describedby");
119
- }, Z = () => {
132
+ }, ke = () => {
120
133
  let e = O.value ?? null;
121
- Y && Y !== e && X(Y, null), Y = e, e && (D.value ? X(e, w) : X(e, A.value ? C : null));
134
+ X && X !== e && Z(X, null), X = e, e && (D.value ? Z(e, w) : Z(e, A.value ? C : null));
122
135
  };
123
- he(() => {
124
- Z(), E.value = !0;
125
- }), b([
136
+ h(() => {
137
+ ke(), E.value = !0;
138
+ }), x([
126
139
  O,
127
140
  A,
128
141
  D
129
- ], Z, { flush: "post" }), pe(() => {
130
- q?.(), J?.(), Y &&= (X(Y, null), null), L(), K && (K = !1, a(!1)), r(U), document.removeEventListener("keydown", W, { capture: !0 });
142
+ ], ke, { flush: "post" }), he(() => {
143
+ J?.(), Y?.(), X &&= (Z(X, null), null), L(), K && (K = !1, a(!1)), r(U), document.removeEventListener("keydown", W, { capture: !0 });
131
144
  });
132
- let Oe = /^-?\d*\.?\d+$/, ke = /^(-?\d*\.?\d+)%$/, Q = l(() => {
133
- if (typeof p.width != "string") return;
134
- let e = p.width.trim().match(ke);
145
+ let Ae = /^-?\d*\.?\d+$/, je = /^(-?\d*\.?\d+)%$/, Q = l(() => {
146
+ if (typeof f.width != "string") return;
147
+ let e = f.width.trim().match(je);
135
148
  return e ? parseFloat(e[1]) : void 0;
136
- }), { width: $ } = be(l(() => Q.value == null ? void 0 : O.value), {
149
+ }), { width: $ } = xe(l(() => se(Q.value == null ? void 0 : O.value)), {
137
150
  width: 0,
138
151
  height: 0
139
- }, { box: "border-box" }), Ae = l(() => {
140
- if (p.width == null || p.width === "") return;
152
+ }, { box: "border-box" }), Me = l(() => {
153
+ if (f.width == null || f.width === "") return;
141
154
  if (Q.value != null) return $.value ? `${$.value * (Q.value / 100)}px` : void 0;
142
- if (typeof p.width == "number") return Number.isFinite(p.width) ? `${p.width}px` : void 0;
143
- let e = p.width.trim();
144
- return Oe.test(e) ? `${e}px` : e;
155
+ if (typeof f.width == "number") return Number.isFinite(f.width) ? `${f.width}px` : void 0;
156
+ let e = f.width.trim();
157
+ return Ae.test(e) ? `${e}px` : e;
145
158
  });
146
- return me(L), (e, t) => (h(), d(ce, null, [
147
- D.value ? (h(), d("span", {
159
+ return ge(L), (e, t) => (g(), d(ue, null, [
160
+ D.value ? (g(), d("span", {
148
161
  key: 0,
149
162
  id: w,
150
163
  hidden: ""
151
- }, v(D.value), 1)) : u("", !0),
152
- Se.value ? u("", !0) : _(e.$slots, "activator", fe(m({ key: 1 }, {
164
+ }, y(D.value), 1)) : u("", !0),
165
+ Ce.value ? u("", !0) : v(e.$slots, "activator", me(m({ key: 1 }, {
153
166
  props: { ref: N },
154
167
  disabled: e.disabled,
155
- open: f.value,
168
+ open: s.value,
156
169
  placement: e.placement
157
170
  }))),
158
- y(we) ? (h(), le(oe, m({
171
+ b(Te) ? (g(), de(ce, m({
159
172
  key: 2,
160
173
  ref: "popover",
161
174
  modelValue: M.value,
162
175
  "onUpdate:modelValue": t[0] ||= (e) => M.value = e,
163
176
  anchor: O.value,
177
+ "aria-hidden": "true",
164
178
  "arrow-padding": e.arrowPadding,
165
179
  boundary: e.boundary,
166
180
  class: ["bb-tooltip", { [`bb-tooltip--${e.variant}`]: !0 }],
@@ -171,13 +185,13 @@ var x = /*@__PURE__*/ f({
171
185
  role: "none",
172
186
  tag: "span",
173
187
  "transition-duration": e.transitionDuration
174
- }, m(e.$attrs, y(S).root), { onVnodeMounted: Te }), {
175
- default: ye(() => [ue("span", m({
188
+ }, m(e.$attrs, b(S).root), { onVnodeMounted: Ee }), {
189
+ default: be(() => [fe("span", m({
176
190
  id: C,
177
191
  class: "bb-tooltip__panel",
178
192
  role: "tooltip",
179
- style: { "--max-w": Ae.value }
180
- }, y(S).panel), [_(e.$slots, "default", {}, () => [de(v(e.text), 1)])], 16)]),
193
+ style: { "--max-w": Me.value }
194
+ }, b(S).panel), [v(e.$slots, "default", {}, () => [pe(y(e.text), 1)])], 16)]),
181
195
  _: 3
182
196
  }, 16, [
183
197
  "modelValue",
@@ -195,4 +209,4 @@ var x = /*@__PURE__*/ f({
195
209
  }
196
210
  });
197
211
  //#endregion
198
- export { x as default };
212
+ export { S as default };
@@ -1,6 +1,6 @@
1
- import { TooltipVariantType } from '../../types/TooltipVariant';
2
- import { PtMap, PtValue } from '../../types/passthrough';
3
- import { ElementOrComponentRef, ElementOrComponentRefOrSelector } from '../../types/CommonProps';
1
+ import { TooltipVariantBuiltIn, TooltipVariantRegistry, TooltipVariantType } from '../../types/TooltipVariant';
2
+ import { PtMap, PtValue, PtVariantAttrs } from '../../types/passthrough';
3
+ import { ElementOrComponentRefOrSelector } from '../../types/CommonProps';
4
4
  import { Placement } from '../../types/Placement';
5
5
  /**
6
6
  * Tooltip variant. Registered variants (vite plugin `tooltipVariants` option)
@@ -26,15 +26,19 @@ export type BbTooltipPtState = 'open';
26
26
  export declare const BB_TOOLTIP_PT: {
27
27
  readonly parts: readonly ["root", "panel"];
28
28
  readonly states: readonly ["open"];
29
+ readonly variant: {
30
+ readonly names: readonly ["default", "destructive"];
31
+ readonly option: "tooltipVariants";
32
+ };
29
33
  };
30
34
  export type BbTooltipProps = {
31
- [K in `pt:${BbTooltipPtPart}` | `pt:${BbTooltipPtPart}:${BbTooltipPtState}`]?: PtValue;
32
- } & {
35
+ [K in `pt:${BbTooltipPtPart}` | `pt:${BbTooltipPtPart}:${BbTooltipPtState}` | `pt:${BbTooltipPtPart}:${TooltipVariantBuiltIn}`]?: PtValue;
36
+ } & /* @vue-ignore */ PtVariantAttrs<BbTooltipPtPart, keyof TooltipVariantRegistry> & {
33
37
  /**
34
38
  * Passthrough, object form: the same keys as the `pt:*` attributes
35
39
  * without the prefix. See the `pt:<part>` row.
36
40
  */
37
- pt?: PtMap<BbTooltipPtPart, BbTooltipPtState>;
41
+ pt?: PtMap<BbTooltipPtPart, BbTooltipPtState | TooltipVariantBuiltIn | keyof TooltipVariantRegistry>;
38
42
  /**
39
43
  * Space the arrow will maintain to the edge of the tooltip bubble.
40
44
  * Useful when the floating element has border radius so it won't appear broken
@@ -91,11 +95,12 @@ export type BbTooltipProps = {
91
95
  */
92
96
  transitionDuration?: number;
93
97
  /**
94
- * External activator element or component ref.
98
+ * External activator: an HTMLElement, a Vue component ref, or a CSS
99
+ * selector string (looked up in the document once the tooltip mounts).
95
100
  * When provided, the activator slot is not rendered and event listeners
96
101
  * are attached programmatically to the referenced element.
97
102
  */
98
- activator?: ElementOrComponentRef;
103
+ activator?: ElementOrComponentRefOrSelector;
99
104
  /**
100
105
  * Constrains the tooltip within a bounding element: it stays inside it
101
106
  * alongside its trigger (sideways for a tooltip above or below); away from
@@ -1,7 +1,12 @@
1
+ import { TOOLTIP_VARIANTS as e } from "../../types/TooltipVariant.js";
1
2
  //#region src/components/BbTooltip/types.ts
2
- var e = {
3
+ var t = {
3
4
  parts: ["root", "panel"],
4
- states: ["open"]
5
+ states: ["open"],
6
+ variant: {
7
+ names: e,
8
+ option: "tooltipVariants"
9
+ }
5
10
  };
6
11
  //#endregion
7
- export { e as BB_TOOLTIP_PT };
12
+ export { t as BB_TOOLTIP_PT };
@@ -3,9 +3,9 @@ import { CommonFieldProps, CommonFieldSlots } from './types';
3
3
  type __VLS_Slots = CommonFieldSlots;
4
4
  declare const __VLS_base: import('vue').DefineComponent<CommonFieldProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<CommonFieldProps> & Readonly<{}>, {
5
5
  reverse: boolean;
6
+ tag: import('../../types/CommonProps').ContainerTag;
6
7
  layout: import('../../types/ResponsiveSize').Responsive<FieldLayout>;
7
8
  labelPosition: "left" | "center" | "right";
8
- tag: import('../../types/CommonProps').ContainerTag;
9
9
  labelTag: import('../../types/CommonProps').LabelTag;
10
10
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
11
11
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
@@ -27,9 +27,9 @@ declare const __VLS_base: import('vue').DefineComponent<__VLS_PublicProps, {}, {
27
27
  onHide?: (() => any) | undefined;
28
28
  onHidden?: (() => any) | undefined;
29
29
  }>, {
30
+ tag: import('../../types/CommonProps').PopoverTag;
30
31
  padding: number;
31
32
  transitionDuration: number;
32
- tag: import('../../types/CommonProps').PopoverTag;
33
33
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
34
34
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
35
35
  declare const _default: typeof __VLS_export;
@@ -5,10 +5,10 @@ import { waitFor as r } from "../../utilities/functions/waitFor.js";
5
5
  import { transitions as i } from "../../utilities/misc/transitions.js";
6
6
  import { overlaySurfaceIsolation as a } from "../../utils/overlaySurfaceIsolation.js";
7
7
  import { providePopoverSubmitBoundary as ee } from "../../composables/formSubmitLock.js";
8
- import { computed as o, createBlock as s, createCommentVNode as c, createElementBlock as te, defineComponent as l, mergeModels as u, mergeProps as d, nextTick as f, onBeforeUnmount as p, onMounted as m, openBlock as h, ref as g, renderSlot as _, resolveDynamicComponent as v, toHandlers as y, unref as b, useModel as x, watch as S, withCtx as C, withModifiers as w } from "vue";
9
- import { arrow as T, autoUpdate as E, flip as D, hide as O, offset as k, shift as A, size as ne, useFloating as re } from "@floating-ui/vue";
8
+ import { computed as o, createBlock as s, createCommentVNode as c, createElementBlock as te, defineComponent as l, mergeModels as u, mergeProps as d, nextTick as f, onBeforeUnmount as p, onMounted as m, openBlock as h, ref as g, renderSlot as _, resolveDynamicComponent as v, toHandlers as y, unref as b, useModel as ne, watch as x, withCtx as S, withModifiers as C } from "vue";
9
+ import { arrow as w, autoUpdate as T, flip as E, hide as D, offset as O, shift as k, size as re, useFloating as ie } from "@floating-ui/vue";
10
10
  //#region src/components/CommonPopover/CommonPopover.vue?vue&type=script&setup=true&lang.ts
11
- var j = /*@__PURE__*/ l({
11
+ var A = /*@__PURE__*/ l({
12
12
  __name: "CommonPopover",
13
13
  props: /*@__PURE__*/ u({
14
14
  arrowPadding: {},
@@ -40,95 +40,95 @@ var j = /*@__PURE__*/ l({
40
40
  "hidden"
41
41
  ], ["update:modelValue"]),
42
42
  setup(i, { emit: l }) {
43
- let u = x(i, "modelValue"), j = i, M = l;
43
+ let u = ne(i, "modelValue"), A = i, j = l;
44
44
  ee();
45
- let N = g(u.value), P = o(() => j.dialog ? "dialog" : j.tag), F = g(), I = g(), L = o(() => {
46
- let e = j.anchor;
45
+ let M = g(u.value), N = o(() => A.dialog ? "dialog" : A.tag), P = g(), F = g(), I = o(() => {
46
+ let e = A.anchor;
47
47
  return e && typeof e == "object" && "getBoundingClientRect" in e && !(e instanceof Element) ? e : n(e);
48
- }), R = e(u, { initialValue: j.eager }), z = (e) => {
48
+ }), L = e(u, { initialValue: A.eager }), R = (e) => {
49
49
  if (e) return typeof e == "string" ? document.querySelector(e) ?? void 0 : n(e) ?? void 0;
50
- }, B = o(() => z(j.boundary)), V = o(() => z(j.overflowBoundary)), H = g(), U = g(), W = o(() => typeof j.bubbleAttrs == "function" ? j.bubbleAttrs({
51
- availableWidth: H.value,
52
- availableHeight: U.value
53
- }) : j.bubbleAttrs), G = o(() => {
54
- let e = B.value, t = V.value;
50
+ }, z = o(() => R(A.boundary)), B = o(() => R(A.overflowBoundary)), V = g(), H = g(), U = o(() => typeof A.bubbleAttrs == "function" ? A.bubbleAttrs({
51
+ availableWidth: V.value,
52
+ availableHeight: H.value
53
+ }) : A.bubbleAttrs), W = o(() => {
54
+ let e = z.value, t = B.value;
55
55
  return [
56
- ...j.disableFlip ? [] : [D()],
57
- k(j.offset),
58
- A({
59
- padding: j.padding,
56
+ ...A.disableFlip ? [] : [E()],
57
+ O(A.offset),
58
+ k({
59
+ padding: A.padding,
60
60
  ...e ? { boundary: e } : {}
61
61
  }),
62
- ne({
63
- padding: j.padding,
62
+ re({
63
+ padding: A.padding,
64
64
  ...t ? { boundary: t } : {},
65
65
  apply({ availableWidth: e, availableHeight: t }) {
66
- H.value = Math.max(0, Math.floor(e)), U.value = Math.max(0, Math.floor(t));
66
+ V.value = Math.max(0, Math.floor(e)), H.value = Math.max(0, Math.floor(t));
67
67
  }
68
68
  }),
69
- O(),
70
- ...j.hideArrow ? [] : [T({
71
- element: I,
72
- padding: j.arrowPadding
69
+ D(),
70
+ ...A.hideArrow ? [] : [w({
71
+ element: F,
72
+ padding: A.arrowPadding
73
73
  })]
74
74
  ];
75
- }), { floatingStyles: K, placement: q, middlewareData: J, update: Y } = re(L, F, {
76
- placement: j.placement,
77
- middleware: G,
75
+ }), G = g(A.placement), { floatingStyles: K, placement: q, middlewareData: J, update: Y } = ie(I, P, {
76
+ placement: G,
77
+ middleware: W,
78
78
  strategy: "fixed",
79
79
  whileElementsMounted: () => () => {}
80
80
  }), X = null;
81
- S([
82
- N,
83
- L,
84
- F,
85
- () => j.forceAutoUpdate
81
+ x([
82
+ M,
83
+ I,
84
+ P,
85
+ () => A.forceAutoUpdate
86
86
  ], ([e, t, n, r]) => {
87
- X?.(), X = null, (e || r) && t && n && (X = E(t, n, Y));
87
+ X?.(), X = null, (e || r) && t && n && (X = T(t, n, Y));
88
88
  }, { immediate: !0 }), p(() => {
89
- X?.(), X = null, ae();
89
+ X?.(), X = null, oe();
90
90
  });
91
- let { execute: ie, cancel: ae } = t(({ signal: e }, t) => new Promise((n) => {
91
+ let { execute: ae, cancel: oe } = t(({ signal: e }, t) => new Promise((n) => {
92
92
  let i, a = () => {
93
93
  i && clearTimeout(i);
94
94
  };
95
- e.addEventListener("abort", a), t ? (M("show"), oe(), Y(), r(() => !!F.value, { signal: e }).then(() => {
96
- e.aborted || (N.value = !0, i = setTimeout(() => {
97
- e.removeEventListener("abort", a), M("shown"), n(void 0);
98
- }, j.transitionDuration));
99
- })) : (M("hide"), N.value = !1, i = setTimeout(() => {
95
+ e.addEventListener("abort", a), t ? (j("show"), G.value = A.placement, se(), Y(), r(() => !!P.value, { signal: e }).then(() => {
96
+ e.aborted || (M.value = !0, i = setTimeout(() => {
97
+ e.removeEventListener("abort", a), j("shown"), n(void 0);
98
+ }, A.transitionDuration));
99
+ })) : (j("hide"), M.value = !1, i = setTimeout(() => {
100
100
  f(() => {
101
- se(), e.removeEventListener("abort", a), Y(), M("hidden"), n(void 0);
101
+ ce(), e.removeEventListener("abort", a), Y(), j("hidden"), n(void 0);
102
102
  });
103
- }, j.transitionDuration));
103
+ }, A.transitionDuration));
104
104
  })), Z = () => {
105
- let e = F.value;
106
- return e ? j.dialog ? e.open : e.matches(":popover-open") : !1;
107
- }, oe = () => {
108
- let e = F.value;
109
- !e || Z() || (j.dialog ? e.showModal() : e.showPopover());
105
+ let e = P.value;
106
+ return e ? A.dialog ? e.open : e.matches(":popover-open") : !1;
110
107
  }, se = () => {
111
- let e = F.value;
112
- !e || !Z() || (j.dialog ? e.close() : e.hidePopover());
113
- }, Q = (e) => ie(e).catch((e) => {
108
+ let e = P.value;
109
+ !e || Z() || (A.dialog ? e.showModal() : e.showPopover());
110
+ }, ce = () => {
111
+ let e = P.value;
112
+ !e || !Z() || (A.dialog ? e.close() : e.hidePopover());
113
+ }, Q = (e) => ae(e).catch((e) => {
114
114
  if (!(e instanceof Error && (e.message === "Operation was cancelled" || e.name === "AbortError"))) throw e;
115
115
  });
116
- S(u, Q), m(() => {
116
+ x(u, Q), m(() => {
117
117
  u.value && Q(u.value);
118
118
  });
119
- let ce = o(() => {
120
- let e = u.value ? void 0 : -1, t = J.value.arrow?.x, n = j.hideArrow || t == null ? "50%" : `${Math.round(t)}px`, r = j.dialog ? void 0 : "manual";
119
+ let le = o(() => {
120
+ let e = u.value ? void 0 : -1, t = J.value.arrow?.x, n = A.hideArrow || t == null ? "50%" : `${Math.round(t)}px`, r = A.dialog ? void 0 : "manual";
121
121
  return {
122
122
  style: {
123
123
  ...K.value,
124
- "--transition-duration": `${j.transitionDuration}ms`,
125
- "--page-padding": `${j.padding}px`,
124
+ "--transition-duration": `${A.transitionDuration}ms`,
125
+ "--page-padding": `${A.padding}px`,
126
126
  "--arrow-offset-x": n
127
127
  },
128
128
  popover: r,
129
129
  tabindex: e
130
130
  };
131
- }), le = o(() => {
131
+ }), ue = o(() => {
132
132
  if (J.value.arrow) {
133
133
  let { x: e, y: t } = J.value.arrow;
134
134
  return { style: {
@@ -139,31 +139,31 @@ var j = /*@__PURE__*/ l({
139
139
  }), $ = () => {
140
140
  u.value = !1;
141
141
  };
142
- return (e, t) => (h(), s(v(P.value), d({
142
+ return (e, t) => (h(), s(v(N.value), d({
143
143
  ref_key: "wrapper",
144
- ref: F,
144
+ ref: P,
145
145
  class: ["bb-common-popover", {
146
- "bb-common-popover--open": N.value,
146
+ "bb-common-popover--open": M.value,
147
147
  "bb-common-popover--no-arrow": e.hideArrow,
148
148
  [`bb-common-popover--${b(q)}`]: !0
149
149
  }]
150
- }, ce.value, y(b(a)), {
151
- onClick: w($, ["self"]),
150
+ }, le.value, y(b(a)), {
151
+ onClick: C($, ["self"]),
152
152
  onClose: $,
153
- onContextmenu: w($, ["self", "prevent"])
153
+ onContextmenu: C($, ["self", "prevent"])
154
154
  }), {
155
- default: C(() => [e.hideArrow ? c("", !0) : (h(), te("span", d({
155
+ default: S(() => [e.hideArrow ? c("", !0) : (h(), te("span", d({
156
156
  key: 0,
157
157
  ref_key: "bubblearrow",
158
- ref: I,
158
+ ref: F,
159
159
  class: "bb-common-popover__arrow"
160
- }, le.value), null, 16)), b(R) ? (h(), s(v(j.tag), d({
160
+ }, ue.value), null, 16)), b(L) ? (h(), s(v(A.tag), d({
161
161
  key: 1,
162
162
  class: "bb-common-popover__bubble"
163
- }, W.value), {
164
- default: C(() => [_(e.$slots, "default", {
165
- availableHeight: U.value,
166
- availableWidth: H.value
163
+ }, U.value), {
164
+ default: S(() => [_(e.$slots, "default", {
165
+ availableHeight: H.value,
166
+ availableWidth: V.value
167
167
  })]),
168
168
  _: 3
169
169
  }, 16)) : c("", !0)]),
@@ -172,4 +172,4 @@ var j = /*@__PURE__*/ l({
172
172
  }
173
173
  });
174
174
  //#endregion
175
- export { j as default };
175
+ export { A as default };