bitboss-ui 3.0.0-beta.74 → 3.0.0-beta.76

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 (321) hide show
  1. package/README.md +5 -5
  2. package/bin/cli.mjs +16 -10
  3. package/dist/ai/BbAlert.md +1 -1
  4. package/dist/ai/BbAvatar.md +86 -58
  5. package/dist/ai/BbBadge.md +1 -1
  6. package/dist/ai/BbBreadcrumbs.md +3 -3
  7. package/dist/ai/BbButton.md +4 -4
  8. package/dist/ai/BbCalendar.md +5 -2
  9. package/dist/ai/BbCheckboxGroup.md +5 -4
  10. package/dist/ai/BbColorInput.md +13 -1
  11. package/dist/ai/BbColorPalette.md +12 -7
  12. package/dist/ai/BbConfirm.md +1 -1
  13. package/dist/ai/BbDatePicker.md +13 -1
  14. package/dist/ai/BbDatePickerInput.md +18 -2
  15. package/dist/ai/BbDialog.md +6 -3
  16. package/dist/ai/BbDropdown.md +174 -77
  17. package/dist/ai/BbDropdownButton.md +37 -16
  18. package/dist/ai/BbGallery.md +3 -2
  19. package/dist/ai/BbIcon.md +10 -10
  20. package/dist/ai/BbNumberInput.md +3 -1
  21. package/dist/ai/BbOffCanvas.md +3 -2
  22. package/dist/ai/BbPopover.md +1 -1
  23. package/dist/ai/BbRadioGroup.md +4 -4
  24. package/dist/ai/BbSelect.md +227 -105
  25. package/dist/ai/BbSelectPopover.md +139 -14
  26. package/dist/ai/BbSwitchGroup.md +5 -4
  27. package/dist/ai/BbTable.md +18 -17
  28. package/dist/ai/BbTimePicker.md +13 -1
  29. package/dist/ai/BbTimePickerInput.md +16 -2
  30. package/dist/ai/BbToast.md +3 -2
  31. package/dist/ai/BbTree.md +5 -1
  32. package/dist/ai/CommonPopover.md +1 -0
  33. package/dist/ai/FlatListBox.md +1 -0
  34. package/dist/ai/GroupedListBox.md +3 -2
  35. package/dist/ai/ListBox.md +4 -2
  36. package/dist/ai/OptionsContainer.md +4 -4
  37. package/dist/ai/changelog.json +310 -7
  38. package/dist/ai/components.json +33 -35
  39. package/dist/ai/composables/useToast.md +2 -2
  40. package/dist/ai/design-tokens.json +60 -0
  41. package/dist/ai/guides/agent-contract.md +9 -5
  42. package/dist/ai/guides/calendars-and-digits.md +1 -1
  43. package/dist/ai/guides/design-tokens.md +13 -0
  44. package/dist/ai/guides/eslint-rules.md +1 -1
  45. package/dist/ai/guides/fetch-items-playbook.md +7 -11
  46. package/dist/ai/guides/icons-policy.md +32 -11
  47. package/dist/ai/guides/installation-and-plugin-setup.md +24 -23
  48. package/dist/ai/guides/migration/adoption-checklist.md +1 -1
  49. package/dist/ai/guides/migration/components/bb-color-palette.md +11 -11
  50. package/dist/ai/guides/migration/components/bb-dropdown-button.md +1 -0
  51. package/dist/ai/guides/migration/components/bb-dropdown.md +1 -0
  52. package/dist/ai/guides/migration/components/bb-icon.md +4 -4
  53. package/dist/ai/guides/migration/components/bb-table.md +2 -1
  54. package/dist/ai/guides/migration/components/bb-toast.md +2 -2
  55. package/dist/ai/guides/migration/v2-to-v3.md +70 -24
  56. package/dist/ai/guides/migration/v3-beta-css-classes.md +18 -3
  57. package/dist/ai/guides/migration/v3-beta-tooling.md +1 -0
  58. package/dist/ai/guides/passthrough.md +58 -58
  59. package/dist/ai/helpers/inertia/manifest.json +1 -1
  60. package/dist/ai/index.md +1 -1
  61. package/dist/ai/manifest/common.json +1 -0
  62. package/dist/ai/manifest/components/BbAvatar.json +5 -2
  63. package/dist/ai/manifest/components/BbAvatar.tree.json +32 -2
  64. package/dist/ai/manifest/components/BbCarousel.json +0 -3
  65. package/dist/ai/manifest/components/BbCheckboxGroup.json +2 -2
  66. package/dist/ai/manifest/components/BbCheckboxGroup.tree.json +2 -0
  67. package/dist/ai/manifest/components/BbColorInput.json +5 -2
  68. package/dist/ai/manifest/components/BbColorPalette.json +5 -2
  69. package/dist/ai/manifest/components/BbColorPalette.removed.json +1 -2
  70. package/dist/ai/manifest/components/BbDatePicker.json +3 -0
  71. package/dist/ai/manifest/components/BbDatePickerInput.json +3 -0
  72. package/dist/ai/manifest/components/BbDialog.tree.json +3 -1
  73. package/dist/ai/manifest/components/BbDropdown.json +36 -28
  74. package/dist/ai/manifest/components/BbDropdown.removed.json +2 -1
  75. package/dist/ai/manifest/components/BbDropdown.tree.json +21 -11
  76. package/dist/ai/manifest/components/BbDropdownButton.json +24 -16
  77. package/dist/ai/manifest/components/BbDropdownButton.removed.json +2 -1
  78. package/dist/ai/manifest/components/BbDropdownButton.tree.json +4 -0
  79. package/dist/ai/manifest/components/BbGallery.tree.json +1 -1
  80. package/dist/ai/manifest/components/BbOffCanvas.tree.json +3 -1
  81. package/dist/ai/manifest/components/BbRadioGroup.json +2 -2
  82. package/dist/ai/manifest/components/BbRadioGroup.tree.json +2 -0
  83. package/dist/ai/manifest/components/BbSelect.json +47 -40
  84. package/dist/ai/manifest/components/BbSelect.tree.json +2 -1
  85. package/dist/ai/manifest/components/BbSelectPopover.json +14 -7
  86. package/dist/ai/manifest/components/BbSelectPopover.tree.json +9 -2
  87. package/dist/ai/manifest/components/BbSwitchGroup.json +2 -2
  88. package/dist/ai/manifest/components/BbSwitchGroup.tree.json +2 -0
  89. package/dist/ai/manifest/components/BbTable.json +6 -6
  90. package/dist/ai/manifest/components/BbTable.tree.json +9 -1
  91. package/dist/ai/manifest/components/BbTimePicker.json +5 -2
  92. package/dist/ai/manifest/components/BbTimePickerInput.json +5 -2
  93. package/dist/ai/manifest/components/BbTree.json +1 -1
  94. package/dist/ai/manifest/components/CommonPopover.json +1 -0
  95. package/dist/ai/manifest/components/FlatListBox.json +2 -1
  96. package/dist/ai/manifest/components/GroupedListBox.json +3 -2
  97. package/dist/ai/manifest/components/GroupedListBox.tree.json +1 -0
  98. package/dist/ai/manifest/components/ListBox.json +3 -2
  99. package/dist/ai/manifest/components/ListBox.tree.json +1 -1
  100. package/dist/ai/manifest/components/OptionsContainer.json +6 -4
  101. package/dist/ai/manifest/index.json +2 -2
  102. package/dist/ai/manifest/meta.json +0 -3
  103. package/dist/ai/manifest/types.advanced.json +6 -6
  104. package/dist/ai/manifest/types.api.json +1 -3
  105. package/dist/ai/recipes/inertia/inline-edit-workspace.md +1 -1
  106. package/dist/ai/recipes/inertia/onboarding.md +1 -1
  107. package/dist/ai/recipes/nuxt/inline-edit-workspace.md +1 -1
  108. package/dist/ai/recipes/nuxt/onboarding.md +1 -1
  109. package/dist/ai/recipes/vue/inline-edit-workspace.md +1 -1
  110. package/dist/ai/recipes/vue/onboarding.md +2 -2
  111. package/dist/ai/source/BbAccordion.md +4 -5
  112. package/dist/ai/source/BbAvatar.md +128 -11
  113. package/dist/ai/source/BbBadge.md +18 -7
  114. package/dist/ai/source/BbBreadcrumbs.md +57 -56
  115. package/dist/ai/source/BbButton.md +41 -25
  116. package/dist/ai/source/BbCalendar.md +8 -6
  117. package/dist/ai/source/BbCarousel.md +41 -34
  118. package/dist/ai/source/BbCheckboxGroup.md +15 -9
  119. package/dist/ai/source/BbColorInput.md +19 -0
  120. package/dist/ai/source/BbColorPalette.md +23 -2
  121. package/dist/ai/source/BbDatePicker.md +18 -0
  122. package/dist/ai/source/BbDatePickerInput.md +47 -3
  123. package/dist/ai/source/BbDialog.md +14 -1
  124. package/dist/ai/source/BbDropdown.md +296 -99
  125. package/dist/ai/source/BbDropdownButton.md +61 -19
  126. package/dist/ai/source/BbDropdownGroup.md +189 -98
  127. package/dist/ai/source/BbGallery.md +82 -60
  128. package/dist/ai/source/BbHost.md +12 -0
  129. package/dist/ai/source/BbNumberInput.md +17 -10
  130. package/dist/ai/source/BbOffCanvas.md +14 -1
  131. package/dist/ai/source/BbPagination.md +12 -28
  132. package/dist/ai/source/BbRadioGroup.md +12 -5
  133. package/dist/ai/source/BbRating.md +4 -4
  134. package/dist/ai/source/BbSelect.md +151 -112
  135. package/dist/ai/source/BbSelectPopover.md +244 -29
  136. package/dist/ai/source/BbSwitchGroup.md +11 -4
  137. package/dist/ai/source/BbTable.md +114 -35
  138. package/dist/ai/source/BbTimePicker.md +19 -0
  139. package/dist/ai/source/BbTimePickerInput.md +21 -2
  140. package/dist/ai/source/BbToast.md +2 -2
  141. package/dist/ai/source/BbToastPortal.md +2 -2
  142. package/dist/ai/source/BbTree.md +1 -1
  143. package/dist/ai/source/ClearableButton.md +4 -2
  144. package/dist/ai/source/CommonPopover.md +24 -1
  145. package/dist/ai/source/ErrorIcon.md +4 -3
  146. package/dist/ai/source/FlatListBox.md +33 -7
  147. package/dist/ai/source/GroupedListBox.md +85 -14
  148. package/dist/ai/source/ListBox.md +11 -1
  149. package/dist/ai/source/OptionsContainer.md +29 -11
  150. package/dist/ai/source/WarningIcon.md +4 -3
  151. package/dist/assets/svgs/close.svg_raw.js +1 -1
  152. package/dist/components/BbAccordion/BbAccordion.vue.d.ts +1 -1
  153. package/dist/components/BbAccordion/BbAccordion.vue_vue_type_script_setup_true_lang.js +35 -34
  154. package/dist/components/BbAvatar/BbAvatar.vue.d.ts +1 -0
  155. package/dist/components/BbAvatar/BbAvatar.vue_vue_type_script_setup_true_lang.js +62 -43
  156. package/dist/components/BbAvatar/avatarIdentity.js +25 -0
  157. package/dist/components/BbAvatar/ptKeys.generated.d.ts +5 -1
  158. package/dist/components/BbAvatar/types.d.ts +24 -5
  159. package/dist/components/BbAvatar/types.js +5 -1
  160. package/dist/components/BbBadge/BadgeBodyContent.vue_vue_type_script_setup_true_lang.js +24 -23
  161. package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +66 -64
  162. package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue_vue_type_script_setup_true_lang.js +141 -146
  163. package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +100 -85
  164. package/dist/components/BbCalendar/BbCalendar.vue.d.ts +1 -1
  165. package/dist/components/BbCalendar/BbCalendar.vue_vue_type_script_setup_true_lang.js +240 -239
  166. package/dist/components/BbCalendar/useDayGrid.js +120 -123
  167. package/dist/components/BbCarousel/BbCarousel.vue_vue_type_script_setup_true_lang.js +503 -502
  168. package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.d.ts +4 -4
  169. package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +126 -122
  170. package/dist/components/BbCheckboxGroup/types.d.ts +7 -11
  171. package/dist/components/BbColorInput/BbColorInput.vue.d.ts +2 -0
  172. package/dist/components/BbColorInput/BbColorInput.vue_vue_type_script_setup_true_lang.js +148 -141
  173. package/dist/components/BbColorInput/types.d.ts +7 -0
  174. package/dist/components/BbColorPalette/BbColorPalette.vue.d.ts +2 -0
  175. package/dist/components/BbColorPalette/BbColorPalette.vue_vue_type_script_setup_true_lang.js +208 -196
  176. package/dist/components/BbColorPalette/types.d.ts +7 -0
  177. package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +3 -1
  178. package/dist/components/BbDatePicker/BbDatePicker.vue_vue_type_script_setup_true_lang.js +84 -73
  179. package/dist/components/BbDatePicker/types.d.ts +7 -0
  180. package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +4 -2
  181. package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +496 -510
  182. package/dist/components/BbDatePickerInput/types.d.ts +7 -0
  183. package/dist/components/BbDialog/BbDialog.vue_vue_type_script_setup_true_lang.js +219 -211
  184. package/dist/components/BbDialog/leaveGhost.js +22 -17
  185. package/dist/components/BbDropdown/AdaptiveDropdown.vue_vue_type_script_setup_true_lang.js +106 -100
  186. package/dist/components/BbDropdown/BbDropdown.vue.d.ts +3 -0
  187. package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +416 -369
  188. package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +404 -354
  189. package/dist/components/BbDropdown/DropdownFailures.vue.js +4 -0
  190. package/dist/components/BbDropdown/DropdownFailures.vue_vue_type_script_setup_true_lang.js +24 -0
  191. package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +117 -102
  192. package/dist/components/BbDropdown/DropdownRow.vue_vue_type_script_setup_true_lang.js +67 -38
  193. package/dist/components/BbDropdown/normalizeGroups.js +6 -2
  194. package/dist/components/BbDropdown/ptKeys.generated.d.ts +44 -20
  195. package/dist/components/BbDropdown/types.d.ts +109 -87
  196. package/dist/components/BbDropdown/types.js +3 -0
  197. package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +3 -1
  198. package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +101 -65
  199. package/dist/components/BbDropdownButton/ptKeys.generated.d.ts +153 -57
  200. package/dist/components/BbDropdownButton/types.d.ts +23 -10
  201. package/dist/components/BbDropdownButton/types.js +4 -0
  202. package/dist/components/BbDropzone/BbDropzone.vue.d.ts +1 -1
  203. package/dist/components/BbGallery/BbGallery.vue_vue_type_script_setup_true_lang.js +335 -312
  204. package/dist/components/BbHost/BbHost.vue_vue_type_script_setup_true_lang.js +7 -1
  205. package/dist/components/BbIcon/iconCache.js +1 -1
  206. package/dist/components/BbNumberInput/BbNumberInput.vue.d.ts +1 -1
  207. package/dist/components/BbNumberInput/BbNumberInput.vue_vue_type_script_setup_true_lang.js +9 -5
  208. package/dist/components/BbOffCanvas/BbOffCanvas.vue_vue_type_script_setup_true_lang.js +152 -144
  209. package/dist/components/BbPagination/BbPagination.vue.d.ts +2 -2
  210. package/dist/components/BbPagination/BbPagination.vue_vue_type_script_setup_true_lang.js +138 -136
  211. package/dist/components/BbProgress/BbProgress.vue.d.ts +1 -1
  212. package/dist/components/BbRadioGroup/BbRadioGroup.vue.d.ts +4 -4
  213. package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +108 -104
  214. package/dist/components/BbRadioGroup/types.d.ts +4 -7
  215. package/dist/components/BbRating/BbRating.vue.d.ts +1 -1
  216. package/dist/components/BbRating/BbRating.vue_vue_type_script_setup_true_lang.js +100 -99
  217. package/dist/components/BbSelect/BbSelect.vue.d.ts +32 -20
  218. package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +217 -196
  219. package/dist/components/BbSelect/ptKeys.generated.d.ts +128 -96
  220. package/dist/components/BbSelect/types.d.ts +110 -111
  221. package/dist/components/BbSelect/types.js +1 -27
  222. package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +8 -3
  223. package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +728 -653
  224. package/dist/components/BbSelectPopover/ptKeys.generated.d.ts +22 -10
  225. package/dist/components/BbSelectPopover/types.d.ts +32 -17
  226. package/dist/components/BbSelectPopover/types.js +3 -1
  227. package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.d.ts +1 -1
  228. package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +159 -155
  229. package/dist/components/BbSwitchGroup/types.d.ts +3 -6
  230. package/dist/components/BbTable/BbTable.vue.d.ts +2 -4
  231. package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +1171 -1152
  232. package/dist/components/BbTable/BbTableDataRow.js +97 -90
  233. package/dist/components/BbTable/types.d.ts +11 -10
  234. package/dist/components/BbTabs/BbTabs.vue.d.ts +3 -3
  235. package/dist/components/BbTimePicker/BbTimePicker.vue.d.ts +4 -2
  236. package/dist/components/BbTimePicker/BbTimePicker.vue_vue_type_script_setup_true_lang.js +145 -134
  237. package/dist/components/BbTimePicker/types.d.ts +7 -0
  238. package/dist/components/BbTimePickerInput/BbTimePickerInput.vue.d.ts +4 -2
  239. package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +290 -280
  240. package/dist/components/BbTimePickerInput/types.d.ts +7 -0
  241. package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +79 -78
  242. package/dist/components/BbToast/types.d.ts +2 -2
  243. package/dist/components/BbTree/BbTreeLevel.vue_vue_type_script_setup_true_lang.js +56 -46
  244. package/dist/components/BbTree/types.d.ts +1 -1
  245. package/dist/components/ClearableButton/ClearableButton.vue_vue_type_script_setup_true_lang.js +9 -8
  246. package/dist/components/CloseIcon/CloseButton.vue.js +1 -1
  247. package/dist/components/CloseIcon/CloseButton.vue_vue_type_script_setup_true_lang.js +9 -7
  248. package/dist/components/CommonPopover/CommonPopover.vue_vue_type_script_setup_true_lang.js +13 -1
  249. package/dist/components/ErrorIcon/ErrorIcon.vue_vue_type_script_setup_true_lang.js +8 -6
  250. package/dist/components/FlatListBox/FlatListBox.vue_vue_type_script_setup_true_lang.js +122 -102
  251. package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js +182 -153
  252. package/dist/components/ListBox/ListBox.vue_vue_type_script_setup_true_lang.js +7 -4
  253. package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js +86 -77
  254. package/dist/components/WarningIcon/WarningIcon.vue_vue_type_script_setup_true_lang.js +8 -6
  255. package/dist/composables/useInternalIcon.js +25 -0
  256. package/dist/composables/useItemsGetter.js +34 -32
  257. package/dist/composables/useOpenModel.js +20 -0
  258. package/dist/deprecation/ai-deprecations.json.js +1 -1
  259. package/dist/i18n/locales/ar.json +2 -0
  260. package/dist/i18n/locales/cs.json +2 -0
  261. package/dist/i18n/locales/da.json +2 -0
  262. package/dist/i18n/locales/de-CH.json +2 -0
  263. package/dist/i18n/locales/de.json +2 -0
  264. package/dist/i18n/locales/el.json +2 -0
  265. package/dist/i18n/locales/en-GB.json +2 -0
  266. package/dist/i18n/locales/en.json +2 -0
  267. package/dist/i18n/locales/es-MX.json +2 -0
  268. package/dist/i18n/locales/es.json +2 -0
  269. package/dist/i18n/locales/fa.json +2 -0
  270. package/dist/i18n/locales/fi.json +2 -0
  271. package/dist/i18n/locales/fr.json +2 -0
  272. package/dist/i18n/locales/he.json +2 -0
  273. package/dist/i18n/locales/hu.json +2 -0
  274. package/dist/i18n/locales/it.json +2 -0
  275. package/dist/i18n/locales/ja.json +2 -0
  276. package/dist/i18n/locales/ko.json +2 -0
  277. package/dist/i18n/locales/nb.json +2 -0
  278. package/dist/i18n/locales/nl.json +2 -0
  279. package/dist/i18n/locales/pl.json +2 -0
  280. package/dist/i18n/locales/pt-BR.json +2 -0
  281. package/dist/i18n/locales/pt-PT.json +2 -0
  282. package/dist/i18n/locales/ro.json +2 -0
  283. package/dist/i18n/locales/ru.json +2 -0
  284. package/dist/i18n/locales/sv.json +2 -0
  285. package/dist/i18n/locales/tr.json +2 -0
  286. package/dist/i18n/locales/uk.json +2 -0
  287. package/dist/i18n/locales/zh-CN.json +2 -0
  288. package/dist/i18n/locales/zh-HK.json +2 -0
  289. package/dist/i18n/locales/zh-TW.json +2 -0
  290. package/dist/icon-scan.d.ts +1 -1
  291. package/dist/icon-scan.js +68 -61
  292. package/dist/index.d.ts +2 -2
  293. package/dist/llms-full.txt +1038 -451
  294. package/dist/llms-medium.txt +33 -28
  295. package/dist/llms.txt +2 -2
  296. package/dist/locale-blueprint.json +2 -0
  297. package/dist/nuxt.js +1 -1
  298. package/dist/styles.css +2 -2
  299. package/dist/types/ActionButton.d.ts +2 -3
  300. package/dist/types/Config.d.ts +8 -1
  301. package/dist/types/ConfigDefaults.d.ts +10 -2
  302. package/dist/types/Option.d.ts +10 -0
  303. package/dist/types/internalIcons.d.ts +89 -0
  304. package/dist/types/internalIcons.js +158 -0
  305. package/dist/types/ptComponentMap.d.ts +5 -5
  306. package/dist/utilities/functions/slotContent.js +19 -0
  307. package/dist/utils/configDefaults.js +75 -64
  308. package/dist/utils/iconsOption.js +48 -0
  309. package/dist/utils/loadRetry.js +8 -0
  310. package/dist/utils/versionCheck.js +1 -1
  311. package/dist/vite-plugin.d.ts +10 -16
  312. package/dist/vite.js +323 -307
  313. package/llms.txt +2 -2
  314. package/package.json +3 -1
  315. package/scripts/README.md +2 -0
  316. package/scripts/lib/adoption-checklist.json +1 -1
  317. package/scripts/lib/agent-setup.mjs +44 -26
  318. package/scripts/lib/update-install.mjs +48 -0
  319. package/scripts/lib/validate-bb-markup.mjs +93 -12
  320. package/dist/ai/manifest/components/BbAvatar.removed.json +0 -6
  321. package/dist/assets/svgs/caret_down.svg_raw.js +0 -3
@@ -7,36 +7,38 @@ import { extractDomContainer as o } from "../../utilities/functions/extractDomCo
7
7
  import { useClosingInert as s } from "../../composables/useClosingInert.js";
8
8
  import { useId as ee } from "../../composables/useId.js";
9
9
  import { useOwnModel as te } from "../../composables/useOwnModel.js";
10
- import { useLocale as ne } from "../../composables/useLocale.js";
11
- import { useEscapeStackEntry as re } from "../../composables/useEscapeStackEntry.js";
12
- import { useMobile as ie } from "../../composables/useMobile.js";
13
- import ae from "../BbOffCanvas/BbOffCanvas.vue.js";
14
- import { BB_OFF_CANVAS_PT as oe } from "../BbOffCanvas/types.js";
15
- import se from "../CommonPopover/CommonPopover.vue.js";
16
- import { removedPropsFor as ce } from "../../deprecation/removedProps.js";
17
- import { warnRemovedAttrs as le } from "../../utilities/functions/warnRemovedAttrs.js";
18
- import { BB_COLOR_PALETTE_PT as ue } from "./types.js";
19
- import { usePassthrough as de } from "../../composables/usePassthrough.js";
20
- import { withoutPt as fe } from "../../utils/passthrough.js";
10
+ import { useOpenModel as ne } from "../../composables/useOpenModel.js";
11
+ import { useLocale as re } from "../../composables/useLocale.js";
12
+ import { useEscapeStackEntry as ie } from "../../composables/useEscapeStackEntry.js";
13
+ import { useMobile as ae } from "../../composables/useMobile.js";
14
+ import oe from "../BbOffCanvas/BbOffCanvas.vue.js";
15
+ import { BB_OFF_CANVAS_PT as se } from "../BbOffCanvas/types.js";
16
+ import ce from "../CommonPopover/CommonPopover.vue.js";
17
+ import { removedPropsFor as le } from "../../deprecation/removedProps.js";
18
+ import { warnRemovedAttrs as ue } from "../../utilities/functions/warnRemovedAttrs.js";
19
+ import { BB_COLOR_PALETTE_PT as de } from "./types.js";
20
+ import { usePassthrough as fe } from "../../composables/usePassthrough.js";
21
+ import { withoutPt as pe } from "../../utils/passthrough.js";
21
22
  import { transitions as c } from "../../utilities/misc/transitions.js";
22
- import { Fragment as pe, computed as l, createBlock as me, createCommentVNode as u, createElementBlock as d, createElementVNode as f, createVNode as p, defineComponent as he, guardReactiveProps as ge, mergeProps as m, nextTick as _e, normalizeClass as ve, normalizeProps as ye, normalizeStyle as h, onBeforeUnmount as be, onDeactivated as xe, openBlock as g, ref as _, renderList as Se, renderSlot as Ce, toDisplayString as we, unref as v, useAttrs as Te, watch as y, withCtx as b } from "vue";
23
- import { createReusableTemplate as Ee } from "@vueuse/core";
23
+ import { useInternalIcon as me } from "../../composables/useInternalIcon.js";
24
+ import { Fragment as he, computed as l, createBlock as ge, createCommentVNode as u, createElementBlock as d, createElementVNode as f, createVNode as p, defineComponent as _e, guardReactiveProps as ve, mergeProps as m, nextTick as ye, normalizeClass as be, normalizeProps as xe, normalizeStyle as h, onBeforeUnmount as Se, onDeactivated as Ce, openBlock as g, ref as _, renderList as we, renderSlot as Te, toDisplayString as Ee, unref as v, useAttrs as De, watch as y, withCtx as Oe } from "vue";
25
+ import { createReusableTemplate as ke } from "@vueuse/core";
24
26
  // src/components/BbColorPalette/BbColorPalette.vue?vue&type=script&setup=true&lang.ts
25
- var De = ["aria-label"], Oe = {
27
+ var Ae = ["aria-label"], je = {
26
28
  "aria-live": "polite",
27
29
  class: "bb-color-palette__canvas-announcer",
28
30
  role: "status"
29
- }, ke = { class: "bb-color-palette__controls" }, Ae = { class: "bb-color-palette__preview-wrap" }, je = { class: "bb-color-palette__sliders" }, Me = ["aria-label", "aria-valuenow"], Ne = ["aria-label", "aria-valuenow"], Pe = ["aria-label", "disabled"], Fe = {
31
+ }, Me = { class: "bb-color-palette__controls" }, Ne = { class: "bb-color-palette__preview-wrap" }, Pe = { class: "bb-color-palette__sliders" }, Fe = ["aria-label", "aria-valuenow"], Ie = ["aria-label", "aria-valuenow"], Le = ["aria-label", "disabled"], Re = {
30
32
  key: 0,
31
33
  class: "bb-color-palette__swatches"
32
- }, Ie = [
34
+ }, ze = [
33
35
  "aria-label",
34
36
  "aria-pressed",
35
37
  "tabindex",
36
38
  "onClick",
37
39
  "onFocus",
38
40
  "onKeydown"
39
- ], x = /*@__PURE__*/ he({
41
+ ], b = /*@__PURE__*/ _e({
40
42
  inheritAttrs: !1,
41
43
  __name: "BbColorPalette",
42
44
  props: {
@@ -49,6 +51,7 @@ var De = ["aria-label"], Oe = {
49
51
  "pt:swatch": {},
50
52
  "pt:swatch:selected": {},
51
53
  "pt:swatch:open": {},
54
+ open: { type: Boolean },
52
55
  pt: {},
53
56
  activator: {},
54
57
  adaptive: {
@@ -82,82 +85,91 @@ var De = ["aria-label"], Oe = {
82
85
  "show",
83
86
  "shown",
84
87
  "hide",
88
+ "update:open",
85
89
  "hidden",
86
90
  "update:modelValue"
87
91
  ],
88
- setup(c, { emit: he }) {
89
- let x = c, S = he, { model: Le, set: Re } = te(x, "modelValue", (e, t) => t !== null && S(e, t), () => null), ze = a(null, "popoverOffset"), C = de({
92
+ setup(c, { emit: _e }) {
93
+ let b = c, x = _e, Be = me("eyedropper", n), { model: Ve, set: He } = te(b, "modelValue", (e, t) => t !== null && x(e, t), () => null), Ue = a(null, "popoverOffset"), S = fe({
90
94
  component: "BbColorPalette",
91
- props: x,
92
- parts: ue.parts,
93
- states: ue.states,
95
+ props: b,
96
+ parts: de.parts,
97
+ states: de.states,
94
98
  active: { open: () => E.value },
95
- attrs: Te()
99
+ attrs: De()
96
100
  });
97
- process.env.NODE_ENV !== "production" && le("BbColorPalette", ce("BbColorPalette"));
98
- let { t: w } = ne(), { isMobile: Be } = ie(), Ve = ee().id.value, He = `${Ve}_panel`, [Ue, We] = Ee(), T = _(), Ge = _(), Ke = l(() => x.activator != null), qe = (e) => {
101
+ process.env.NODE_ENV !== "production" && ue("BbColorPalette", le("BbColorPalette"));
102
+ let { t: C } = re(), { isMobile: We } = ae(), w = ee().id.value, Ge = `${w}_panel`, [Ke, qe] = ke(), T = _(), Je = _(), Ye = l(() => b.activator != null), Xe = (e) => {
99
103
  T.value = o(e) ?? void 0;
100
- }, Je = (e) => {
101
- Ge.value = o(e) ?? void 0;
104
+ }, Ze = (e) => {
105
+ Je.value = o(e) ?? void 0;
102
106
  };
103
- y(() => x.activator, (e) => {
107
+ y(() => b.activator, (e) => {
104
108
  T.value = o(e) ?? void 0;
105
- }, { immediate: !0 }), y(() => x.anchor, (e) => {
106
- Ge.value = e == null ? void 0 : o(e) ?? void 0;
109
+ }, { immediate: !0 }), y(() => b.anchor, (e) => {
110
+ Je.value = e == null ? void 0 : o(e) ?? void 0;
107
111
  }, { immediate: !0 });
108
- let Ye = l(() => Ge.value ?? T.value), E = _(!1), Xe = s(E, () => x.transitionDuration), Ze = null, Qe = (e) => {
109
- x.disabled || x.readonly || (e.stopPropagation(), E.value = !E.value);
110
- }, $e = (e) => {
112
+ let Qe = l(() => Je.value ?? T.value), E = _(!1), $e = s(E, () => b.transitionDuration), et = null, tt = (e) => {
113
+ b.disabled || b.readonly || (e.stopPropagation(), E.value = !E.value);
114
+ };
115
+ ne(b, x, {
116
+ isOpen: () => E.value,
117
+ open: () => {
118
+ b.disabled || b.readonly || (E.value = !0);
119
+ },
120
+ close: () => E.value = !1
121
+ });
122
+ let nt = (e) => {
111
123
  let t = e.target;
112
124
  t instanceof Node && ((H.value?.closest(".bb-common-popover"))?.contains(t) || T.value?.contains(t) || (E.value = !1));
113
125
  };
114
126
  y(E, async (e) => {
115
- e ? (nt.value = tt(), Ze = document.activeElement instanceof HTMLElement ? document.activeElement : null, D.value || document.addEventListener("click", $e, {
127
+ e ? (at.value = it(), et = document.activeElement instanceof HTMLElement ? document.activeElement : null, D.value || document.addEventListener("click", nt, {
116
128
  passive: !0,
117
129
  capture: !0
118
- }), await _e(), H.value?.focus()) : (document.removeEventListener("click", $e, { capture: !0 }), Ze?.focus(), Ze = null);
130
+ }), await ye(), H.value?.focus()) : (document.removeEventListener("click", nt, { capture: !0 }), et?.focus(), et = null);
119
131
  });
120
- let et = i("BbColorPalette", x, { adaptive: !0 }), tt = () => et.adaptive && Be.value ? "canvas" : "popover", nt = _(tt()), D = l(() => nt.value === "canvas");
132
+ let rt = i("BbColorPalette", b, { adaptive: !0 }), it = () => rt.adaptive && We.value ? "canvas" : "popover", at = _(it()), D = l(() => at.value === "canvas");
121
133
  y([
122
- () => et.adaptive,
123
- Be,
134
+ () => rt.adaptive,
135
+ We,
124
136
  E
125
137
  ], () => {
126
- E.value || (nt.value = tt());
127
- }), re(() => E.value && !D.value, () => E.value = !1);
128
- let rt = l(() => ({
138
+ E.value || (at.value = it());
139
+ }), ie(() => E.value && !D.value, () => E.value = !1);
140
+ let ot = l(() => ({
129
141
  side: "bottom",
130
142
  size: "auto",
131
143
  draggable: !0,
132
144
  hideClose: !0,
133
- eager: x.eager,
134
- transitionDuration: x.transitionDuration,
135
- ...x.offCanvasProps?.title ? {} : { "aria-labelledby": ot.value },
136
- ...fe(x.offCanvasProps)
137
- })), it = () => {
138
- T.value?.focus(), S("hidden");
145
+ eager: b.eager,
146
+ transitionDuration: b.transitionDuration,
147
+ ...b.offCanvasProps?.title ? {} : { "aria-labelledby": lt.value },
148
+ ...pe(b.offCanvasProps)
149
+ })), st = () => {
150
+ T.value?.focus(), x("hidden");
139
151
  }, O = null, k = _();
140
152
  y(T, (e) => {
141
153
  if (O?.(), O = null, !e) return;
142
154
  let t = !e.id;
143
- t && (e.id = `${Ve}_activator`), k.value = e.id, e.addEventListener("click", Qe), O = () => {
144
- e.removeEventListener("click", Qe), e.removeAttribute("aria-haspopup"), e.removeAttribute("aria-expanded"), e.removeAttribute("aria-labelledby"), e.removeAttribute("aria-controls"), j.has(e) && (e.removeAttribute("disabled"), e.removeAttribute("aria-disabled"), j.delete(e)), t && e.removeAttribute("id"), k.value = void 0;
155
+ t && (e.id = `${w}_activator`), k.value = e.id, e.addEventListener("click", tt), O = () => {
156
+ e.removeEventListener("click", tt), e.removeAttribute("aria-haspopup"), e.removeAttribute("aria-expanded"), e.removeAttribute("aria-labelledby"), e.removeAttribute("aria-controls"), j.has(e) && (e.removeAttribute("disabled"), e.removeAttribute("aria-disabled"), j.delete(e)), t && e.removeAttribute("id"), k.value = void 0;
145
157
  };
146
158
  }, { immediate: !0 });
147
- let at = l(() => x.label ?? w("colorInput.openPicker").value), A = `${Ve}_label`, ot = l(() => k.value ? `${A} ${k.value}` : A), j = /* @__PURE__ */ new WeakSet(), st = l(() => x.disabled ? {
148
- ref: qe,
159
+ let ct = l(() => b.label ?? C("colorInput.openPicker").value), A = `${w}_label`, lt = l(() => k.value ? `${A} ${k.value}` : A), j = /* @__PURE__ */ new WeakSet(), ut = l(() => b.disabled ? {
160
+ ref: Xe,
149
161
  disabled: !0,
150
162
  "aria-disabled": "true"
151
- } : { ref: qe });
163
+ } : { ref: Xe });
152
164
  y([
153
165
  T,
154
166
  E,
155
- () => x.disabled,
156
- () => x.readonly
167
+ () => b.disabled,
168
+ () => b.readonly
157
169
  ], ([e, t, n, r]) => {
158
- e && (e.setAttribute("aria-labelledby", `${A} ${e.id}`), n ? (e.setAttribute("disabled", ""), e.setAttribute("aria-disabled", "true"), j.add(e)) : j.has(e) && (e.removeAttribute("disabled"), e.removeAttribute("aria-disabled"), j.delete(e)), n || r ? (e.removeAttribute("aria-haspopup"), e.removeAttribute("aria-expanded"), e.removeAttribute("aria-controls")) : (e.setAttribute("aria-haspopup", "dialog"), e.setAttribute("aria-expanded", t ? "true" : "false"), t ? e.setAttribute("aria-controls", He) : e.removeAttribute("aria-controls")));
159
- }, { immediate: !0 }), be(() => {
160
- O?.(), document.removeEventListener("click", $e, { capture: !0 });
170
+ e && (e.setAttribute("aria-labelledby", `${A} ${e.id}`), n ? (e.setAttribute("disabled", ""), e.setAttribute("aria-disabled", "true"), j.add(e)) : j.has(e) && (e.removeAttribute("disabled"), e.removeAttribute("aria-disabled"), j.delete(e)), n || r ? (e.removeAttribute("aria-haspopup"), e.removeAttribute("aria-expanded"), e.removeAttribute("aria-controls")) : (e.setAttribute("aria-haspopup", "dialog"), e.setAttribute("aria-expanded", t ? "true" : "false"), t ? e.setAttribute("aria-controls", Ge) : e.removeAttribute("aria-controls")));
171
+ }, { immediate: !0 }), Se(() => {
172
+ O?.(), document.removeEventListener("click", nt, { capture: !0 });
161
173
  });
162
174
  function M(e, t, n) {
163
175
  let r = (r) => {
@@ -170,7 +182,7 @@ var De = ["aria-label"], Oe = {
170
182
  Math.round(r(1) * 255)
171
183
  ];
172
184
  }
173
- function ct(e, t, n) {
185
+ function dt(e, t, n) {
174
186
  let r = e / 255, i = t / 255, a = n / 255, o = Math.max(r, i, a), s = o - Math.min(r, i, a), ee = o === 0 ? 0 : s / o, te = o, ne = 0;
175
187
  return s !== 0 && (ne = o === r ? ((i - a) / s + (i < a ? 6 : 0)) / 6 : o === i ? ((a - r) / s + 2) / 6 : ((r - i) / s + 4) / 6), [
176
188
  ne * 360,
@@ -178,7 +190,7 @@ var De = ["aria-label"], Oe = {
178
190
  te
179
191
  ];
180
192
  }
181
- function lt(e) {
193
+ function ft(e) {
182
194
  let t = e.replace(/^#/, "");
183
195
  return t.length === 3 ? [
184
196
  parseInt(t[0] + t[0], 16),
@@ -205,11 +217,11 @@ var De = ["aria-label"], Oe = {
205
217
  function N(e) {
206
218
  return Math.round(Math.max(0, Math.min(255, e))).toString(16).padStart(2, "0");
207
219
  }
208
- function ut(e, t, n, r, i) {
220
+ function pt(e, t, n, r, i) {
209
221
  let a = `#${N(e)}${N(t)}${N(n)}`;
210
222
  return i ? a + N(r * 255) : a;
211
223
  }
212
- let dt = [
224
+ let mt = [
213
225
  [
214
226
  "#FFCDD2",
215
227
  "#EF9A9A",
@@ -254,11 +266,11 @@ var De = ["aria-label"], Oe = {
254
266
  ]
255
267
  ], P = _(0), F = _(1), I = _(1), L = _(1), R = l(() => {
256
268
  let [e, t, n] = M(P.value, F.value, I.value);
257
- return ut(e, t, n, L.value, x.alpha);
258
- }), ft = l(() => {
269
+ return pt(e, t, n, L.value, b.alpha);
270
+ }), ht = l(() => {
259
271
  let [e, t, n] = M(P.value, F.value, I.value);
260
- return x.alpha ? `rgba(${e},${t},${n},${L.value})` : `rgb(${e},${t},${n})`;
261
- }), pt = l(() => !!x.swatches), z = l(() => Array.isArray(x.swatches) ? x.swatches : dt), B = _(null), mt = _(null), V = _(null), H = _(null), U = _(null), W = _(null), G = () => {
272
+ return b.alpha ? `rgba(${e},${t},${n},${L.value})` : `rgb(${e},${t},${n})`;
273
+ }), gt = l(() => !!b.swatches), z = l(() => Array.isArray(b.swatches) ? b.swatches : mt), B = _(null), _t = _(null), V = _(null), H = _(null), U = _(null), W = _(null), G = () => {
262
274
  let e = B.value;
263
275
  if (!e || e.width === 0 || e.height === 0) return;
264
276
  let t = e.getContext("2d");
@@ -267,8 +279,8 @@ var De = ["aria-label"], Oe = {
267
279
  a.addColorStop(0, "#ffffff"), a.addColorStop(1, `rgb(${n},${r},${i})`), t.fillStyle = a, t.fillRect(0, 0, e.width, e.height);
268
280
  let o = t.createLinearGradient(0, 0, 0, e.height);
269
281
  o.addColorStop(0, "rgba(0,0,0,0)"), o.addColorStop(1, "rgba(0,0,0,1)"), t.fillStyle = o, t.fillRect(0, 0, e.width, e.height);
270
- }, ht = () => {
271
- let e = mt.value;
282
+ }, vt = () => {
283
+ let e = _t.value;
272
284
  if (!e || e.width === 0 || e.height === 0) return;
273
285
  let t = e.getContext("2d");
274
286
  if (!t) return;
@@ -283,33 +295,33 @@ var De = ["aria-label"], Oe = {
283
295
  t.clearRect(0, 0, e.width, e.height);
284
296
  let [n, r, i] = M(P.value, F.value, I.value), a = t.createLinearGradient(0, 0, e.width, 0);
285
297
  a.addColorStop(0, `rgba(${n},${r},${i},0)`), a.addColorStop(1, `rgba(${n},${r},${i},1)`), t.fillStyle = a, t.fillRect(0, 0, e.width, e.height);
286
- }, gt = () => {
287
- G(), ht(), x.alpha && K();
288
- }, q = null, _t = (e) => {
298
+ }, yt = () => {
299
+ G(), vt(), b.alpha && K();
300
+ }, q = null, bt = (e) => {
289
301
  e.width = e.offsetWidth, e.height = e.offsetHeight;
290
- }, vt = () => {
291
- let e = B.value, t = mt.value;
292
- e && t && e.offsetWidth !== 0 && (_t(e), _t(t), x.alpha && V.value && _t(V.value), gt());
293
- }, yt = !1, bt = () => {
294
- P.value = 0, F.value = 1, I.value = 1, L.value = 1, Ot.value = "", Y.value = !1, X.value = !1, Z.value = !1, Q.value = !1, Ht = void 0;
295
302
  }, xt = () => {
296
- yt = !0, q = new ResizeObserver(vt), B.value && q.observe(B.value), wt(Le.value), vt();
297
- }, St = () => {
298
- yt = !1, q?.disconnect(), q = null, bt();
299
- }, Ct = l(() => m({
300
- id: He,
303
+ let e = B.value, t = _t.value;
304
+ e && t && e.offsetWidth !== 0 && (bt(e), bt(t), b.alpha && V.value && bt(V.value), yt());
305
+ }, St = !1, Ct = () => {
306
+ P.value = 0, F.value = 1, I.value = 1, L.value = 1, jt.value = "", Y.value = !1, X.value = !1, Z.value = !1, Q.value = !1, Gt = void 0;
307
+ }, wt = () => {
308
+ St = !0, q = new ResizeObserver(xt), B.value && q.observe(B.value), Dt(Ve.value), xt();
309
+ }, Tt = () => {
310
+ St = !1, q?.disconnect(), q = null, Ct();
311
+ }, Et = l(() => m({
312
+ id: Ge,
301
313
  class: "bb-color-palette__panel",
302
- inert: Xe.value
303
- }, D.value ? {} : C.panel ?? {})), wt = (e) => {
314
+ inert: $e.value
315
+ }, D.value ? {} : S.panel ?? {})), Dt = (e) => {
304
316
  if (e) try {
305
- let [t, n, r, i] = lt(e), [a, o, s] = ct(t, n, r);
317
+ let [t, n, r, i] = ft(e), [a, o, s] = dt(t, n, r);
306
318
  o > .01 && (P.value = a), F.value = o, I.value = s, L.value = i;
307
319
  } catch {}
308
320
  };
309
- y(() => Le.value, (e) => {
310
- yt && (e && e === R.value || (e ? wt(e) : (P.value = 0, F.value = 1, I.value = 1, L.value = 1), G(), x.alpha && K()));
321
+ y(() => Ve.value, (e) => {
322
+ St && (e && e === R.value || (e ? Dt(e) : (P.value = 0, F.value = 1, I.value = 1, L.value = 1), G(), b.alpha && K()));
311
323
  });
312
- let J = () => Re(R.value), Y = _(!1), Tt = (e) => {
324
+ let J = () => He(R.value), Y = _(!1), Ot = (e) => {
313
325
  let t = H.value;
314
326
  if (!t) return {
315
327
  s: F.value,
@@ -320,19 +332,19 @@ var De = ["aria-label"], Oe = {
320
332
  s: Math.max(0, Math.min(1, (e.clientX - n.left) / n.width)),
321
333
  v: Math.max(0, Math.min(1, 1 - (e.clientY - n.top) / n.height))
322
334
  };
323
- }, Et = (e) => {
335
+ }, kt = (e) => {
324
336
  H.value?.setPointerCapture(e.pointerId), Y.value = !0;
325
- let { s: t, v: n } = Tt(e);
326
- F.value = t, I.value = n, x.alpha && K(), J();
327
- }, Dt = (e) => {
328
- if (!Y.value) return;
329
- let { s: t, v: n } = Tt(e);
330
- F.value = t, I.value = n, x.alpha && K(), J();
331
- }, Ot = _(""), kt = () => {
332
- Ot.value = w("colorInput.mainCanvasSelectedColor", R.value).value;
337
+ let { s: t, v: n } = Ot(e);
338
+ F.value = t, I.value = n, b.alpha && K(), J();
333
339
  }, At = (e) => {
334
- H.value?.releasePointerCapture(e.pointerId), Y.value && kt(), Y.value = !1;
335
- }, jt = (e) => {
340
+ if (!Y.value) return;
341
+ let { s: t, v: n } = Ot(e);
342
+ F.value = t, I.value = n, b.alpha && K(), J();
343
+ }, jt = _(""), Mt = () => {
344
+ jt.value = C("colorInput.mainCanvasSelectedColor", R.value).value;
345
+ }, Nt = (e) => {
346
+ H.value?.releasePointerCapture(e.pointerId), Y.value && Mt(), Y.value = !1;
347
+ }, Pt = (e) => {
336
348
  let t = e.shiftKey ? .05 : .01;
337
349
  switch (e.key) {
338
350
  case "ArrowLeft":
@@ -349,19 +361,19 @@ var De = ["aria-label"], Oe = {
349
361
  break;
350
362
  default: return;
351
363
  }
352
- x.alpha && K(), J(), kt(), e.preventDefault();
353
- }, X = _(!1), Mt = (e) => {
364
+ b.alpha && K(), J(), Mt(), e.preventDefault();
365
+ }, X = _(!1), Ft = (e) => {
354
366
  let t = U.value;
355
367
  if (!t) return P.value;
356
368
  let n = t.getBoundingClientRect();
357
369
  return Math.max(0, Math.min(360, (e.clientX - n.left) / n.width * 360));
358
- }, Nt = (e) => {
359
- U.value?.setPointerCapture(e.pointerId), X.value = !0, P.value = Mt(e), G(), x.alpha && K(), J();
360
- }, Pt = (e) => {
361
- X.value && (P.value = Mt(e), G(), x.alpha && K(), J());
362
- }, Ft = (e) => {
363
- U.value?.releasePointerCapture(e.pointerId), X.value = !1;
364
370
  }, It = (e) => {
371
+ U.value?.setPointerCapture(e.pointerId), X.value = !0, P.value = Ft(e), G(), b.alpha && K(), J();
372
+ }, Lt = (e) => {
373
+ X.value && (P.value = Ft(e), G(), b.alpha && K(), J());
374
+ }, Rt = (e) => {
375
+ U.value?.releasePointerCapture(e.pointerId), X.value = !1;
376
+ }, zt = (e) => {
365
377
  let t = e.shiftKey ? 10 : 1;
366
378
  switch (e.key) {
367
379
  case "ArrowLeft":
@@ -372,19 +384,19 @@ var De = ["aria-label"], Oe = {
372
384
  break;
373
385
  default: return;
374
386
  }
375
- G(), x.alpha && K(), J(), e.preventDefault();
376
- }, Z = _(!1), Lt = (e) => {
387
+ G(), b.alpha && K(), J(), e.preventDefault();
388
+ }, Z = _(!1), Bt = (e) => {
377
389
  let t = W.value;
378
390
  if (!t) return L.value;
379
391
  let n = t.getBoundingClientRect();
380
392
  return Math.max(0, Math.min(1, (e.clientX - n.left) / n.width));
381
- }, Rt = (e) => {
382
- W.value?.setPointerCapture(e.pointerId), Z.value = !0, L.value = Lt(e), J();
383
- }, zt = (e) => {
384
- Z.value && (L.value = Lt(e), J());
385
- }, Bt = (e) => {
386
- W.value?.releasePointerCapture(e.pointerId), Z.value = !1;
387
393
  }, Vt = (e) => {
394
+ W.value?.setPointerCapture(e.pointerId), Z.value = !0, L.value = Bt(e), J();
395
+ }, Ht = (e) => {
396
+ Z.value && (L.value = Bt(e), J());
397
+ }, Ut = (e) => {
398
+ W.value?.releasePointerCapture(e.pointerId), Z.value = !1;
399
+ }, Wt = (e) => {
388
400
  let t = e.shiftKey ? .05 : .01;
389
401
  switch (e.key) {
390
402
  case "ArrowLeft":
@@ -396,16 +408,16 @@ var De = ["aria-label"], Oe = {
396
408
  default: return;
397
409
  }
398
410
  J(), e.preventDefault();
399
- }, Ht, Ut = () => Ht ??= typeof window < "u" && "EyeDropper" in window, Q = _(!1), Wt = async () => {
400
- if (Ut()) try {
411
+ }, Gt, Kt = () => Gt ??= typeof window < "u" && "EyeDropper" in window, Q = _(!1), qt = async () => {
412
+ if (Kt()) try {
401
413
  Q.value = !0;
402
414
  let e = await new window.EyeDropper().open();
403
- Xt(e.sRGBHex);
415
+ $t(e.sRGBHex);
404
416
  } catch {} finally {
405
417
  Q.value = !1;
406
418
  }
407
- }, Gt = _(null), Kt = (e) => e && z.value[e[0]]?.[e[1]] !== void 0 ? e : null, qt = l(() => {
408
- let e = Kt(Gt.value);
419
+ }, Jt = _(null), Yt = (e) => e && z.value[e[0]]?.[e[1]] !== void 0 ? e : null, Xt = l(() => {
420
+ let e = Yt(Jt.value);
409
421
  if (e) return e;
410
422
  let t = z.value;
411
423
  for (let e = 0; e < t.length; e++) {
@@ -414,7 +426,7 @@ var De = ["aria-label"], Oe = {
414
426
  }
415
427
  let n = t.findIndex((e) => e.length > 0);
416
428
  return [Math.max(n, 0), 0];
417
- }), Jt = (e, t) => qt.value[0] === e && qt.value[1] === t ? 0 : -1, Yt = (t, n, r) => {
429
+ }), Zt = (e, t) => Xt.value[0] === e && Xt.value[1] === t ? 0 : -1, Qt = (t, n, r) => {
418
430
  if (t.altKey || t.ctrlKey || t.metaKey || t.shiftKey) return;
419
431
  let i = z.value, a = e(t.key, t.currentTarget), o = null;
420
432
  if (a) {
@@ -434,41 +446,41 @@ var De = ["aria-label"], Oe = {
434
446
  e !== -1 && (o = [e, i[e].length - 1]);
435
447
  } else return;
436
448
  t.preventDefault(), o && (t.currentTarget.closest(".bb-color-palette__swatches")?.children[o[0]]?.children[o[1]])?.focus();
437
- }, $ = (e) => R.value.slice(0, 7).toLowerCase() === e.slice(0, 7).toLowerCase(), Xt = (e) => {
438
- let [t, n, r, i] = lt(e), [a, o, s] = ct(t, n, r);
439
- o > .01 && (P.value = a), F.value = o, I.value = s, L.value = i, G(), x.alpha && K(), J();
449
+ }, $ = (e) => R.value.slice(0, 7).toLowerCase() === e.slice(0, 7).toLowerCase(), $t = (e) => {
450
+ let [t, n, r, i] = ft(e), [a, o, s] = dt(t, n, r);
451
+ o > .01 && (P.value = a), F.value = o, I.value = s, L.value = i, G(), b.alpha && K(), J();
440
452
  };
441
- return xe(() => {
453
+ return Ce(() => {
442
454
  E.value = !1;
443
- }), (e, i) => (g(), d(pe, null, [
444
- Ke.value ? u("", !0) : Ce(e.$slots, "activator", ye(ge({
445
- props: st.value,
446
- anchorProps: { ref: Je },
455
+ }), (e, n) => (g(), d(he, null, [
456
+ Ye.value ? u("", !0) : Te(e.$slots, "activator", xe(ve({
457
+ props: ut.value,
458
+ anchorProps: { ref: Ze },
447
459
  open: E.value,
448
- value: v(Le),
460
+ value: v(Ve),
449
461
  disabled: c.disabled
450
462
  })), void 0, void 0, 0),
451
463
  f("span", {
452
464
  id: A,
453
465
  hidden: ""
454
- }, we(at.value), 1),
455
- p(v(Ue), null, {
456
- default: b(() => [
466
+ }, Ee(ct.value), 1),
467
+ p(v(Ke), null, {
468
+ default: Oe(() => [
457
469
  f("div", {
458
470
  ref_key: "canvasWrapRef",
459
471
  ref: H,
460
- "aria-label": v(w)("colorInput.mainCanvasDesc").value,
472
+ "aria-label": v(C)("colorInput.mainCanvasDesc").value,
461
473
  class: "bb-color-palette__canvas-wrap",
462
474
  "data-bb-no-drag": "",
463
475
  role: "application",
464
476
  tabindex: "0",
465
- onKeydown: jt,
466
- onPointercancel: At,
467
- onPointerdown: Et,
468
- onPointermove: Dt,
469
- onPointerup: At,
470
- onVnodeBeforeUnmount: St,
471
- onVnodeMounted: xt
477
+ onKeydown: Pt,
478
+ onPointercancel: Nt,
479
+ onPointerdown: kt,
480
+ onPointermove: At,
481
+ onPointerup: Nt,
482
+ onVnodeBeforeUnmount: Tt,
483
+ onVnodeMounted: wt
472
484
  }, [f("canvas", {
473
485
  ref_key: "mainCanvasRef",
474
486
  ref: B,
@@ -481,17 +493,17 @@ var De = ["aria-label"], Oe = {
481
493
  left: `${F.value * 100}%`,
482
494
  top: `${(1 - I.value) * 100}%`
483
495
  })
484
- }, null, 4)], 40, De),
485
- f("div", Oe, we(Ot.value), 1),
486
- f("div", ke, [
487
- f("div", Ae, [f("div", {
488
- class: ve(["bb-color-palette__preview", { "bb-color-palette__preview--alpha": c.alpha }]),
489
- style: h({ "--picker-preview-color": ft.value })
496
+ }, null, 4)], 40, Ae),
497
+ f("div", je, Ee(jt.value), 1),
498
+ f("div", Me, [
499
+ f("div", Ne, [f("div", {
500
+ class: be(["bb-color-palette__preview", { "bb-color-palette__preview--alpha": c.alpha }]),
501
+ style: h({ "--picker-preview-color": ht.value })
490
502
  }, null, 6)]),
491
- f("div", je, [f("div", {
503
+ f("div", Pe, [f("div", {
492
504
  ref_key: "hueWrapRef",
493
505
  ref: U,
494
- "aria-label": v(w)("colorInput.hueCanvasDesc").value,
506
+ "aria-label": v(C)("colorInput.hueCanvasDesc").value,
495
507
  "aria-valuemax": "360",
496
508
  "aria-valuemin": "0",
497
509
  "aria-valuenow": Math.round(P.value),
@@ -499,25 +511,25 @@ var De = ["aria-label"], Oe = {
499
511
  "data-bb-no-drag": "",
500
512
  role: "slider",
501
513
  tabindex: "0",
502
- onKeydown: It,
503
- onPointercancel: Ft,
504
- onPointerdown: Nt,
505
- onPointermove: Pt,
506
- onPointerup: Ft
514
+ onKeydown: zt,
515
+ onPointercancel: Rt,
516
+ onPointerdown: It,
517
+ onPointermove: Lt,
518
+ onPointerup: Rt
507
519
  }, [f("canvas", {
508
520
  ref_key: "hueCanvasRef",
509
- ref: mt,
521
+ ref: _t,
510
522
  "aria-hidden": "true",
511
523
  class: "bb-color-palette__slider-track"
512
524
  }, null, 512), f("div", {
513
525
  "aria-hidden": "true",
514
526
  class: "bb-color-palette__slider-thumb",
515
527
  style: h({ left: `${P.value / 360 * 100}%` })
516
- }, null, 4)], 40, Me), c.alpha ? (g(), d("div", {
528
+ }, null, 4)], 40, Fe), c.alpha ? (g(), d("div", {
517
529
  key: 0,
518
530
  ref_key: "alphaWrapRef",
519
531
  ref: W,
520
- "aria-label": v(w)("colorInput.alphaSliderDesc").value,
532
+ "aria-label": v(C)("colorInput.alphaSliderDesc").value,
521
533
  "aria-valuemax": "100",
522
534
  "aria-valuemin": "0",
523
535
  "aria-valuenow": Math.round(L.value * 100),
@@ -525,11 +537,11 @@ var De = ["aria-label"], Oe = {
525
537
  "data-bb-no-drag": "",
526
538
  role: "slider",
527
539
  tabindex: "0",
528
- onKeydown: Vt,
529
- onPointercancel: Bt,
530
- onPointerdown: Rt,
531
- onPointermove: zt,
532
- onPointerup: Bt
540
+ onKeydown: Wt,
541
+ onPointercancel: Ut,
542
+ onPointerdown: Vt,
543
+ onPointermove: Ht,
544
+ onPointerup: Ut
533
545
  }, [f("canvas", {
534
546
  ref_key: "alphaCanvasRef",
535
547
  ref: V,
@@ -539,77 +551,77 @@ var De = ["aria-label"], Oe = {
539
551
  "aria-hidden": "true",
540
552
  class: "bb-color-palette__slider-thumb",
541
553
  style: h({ left: `${L.value * 100}%` })
542
- }, null, 4)], 40, Ne)) : u("", !0)]),
543
- Ut() && c.eyeDropper ? (g(), d("button", {
554
+ }, null, 4)], 40, Ie)) : u("", !0)]),
555
+ Kt() && c.eyeDropper ? (g(), d("button", {
544
556
  key: 0,
545
- "aria-label": v(w)("colorInput.eyeDropper").value,
557
+ "aria-label": v(C)("colorInput.eyeDropper").value,
546
558
  class: "bb-color-palette__eyedropper",
547
559
  disabled: Q.value || void 0,
548
560
  type: "button",
549
- onClick: Wt
561
+ onClick: qt
550
562
  }, [p(t, {
551
- icon: v(n),
563
+ icon: v(Be),
552
564
  size: "16"
553
- }, null, 8, ["icon"])], 8, Pe)) : u("", !0)
565
+ }, null, 8, ["icon"])], 8, Le)) : u("", !0)
554
566
  ]),
555
- pt.value ? (g(), d("div", Fe, [(g(!0), d(pe, null, Se(z.value, (e, t) => (g(), d("div", {
567
+ gt.value ? (g(), d("div", Re, [(g(!0), d(he, null, we(z.value, (e, t) => (g(), d("div", {
556
568
  key: t,
557
569
  class: "bb-color-palette__swatch-group"
558
- }, [(g(!0), d(pe, null, Se(e, (e, n) => (g(), d("button", m({
570
+ }, [(g(!0), d(he, null, we(e, (e, n) => (g(), d("button", m({
559
571
  key: e,
560
572
  "aria-label": e,
561
573
  "aria-pressed": $(e),
562
574
  class: ["bb-color-palette__swatch", { "bb-color-palette__swatch--active": $(e) }],
563
575
  style: { background: e },
564
- tabindex: Jt(t, n),
576
+ tabindex: Zt(t, n),
565
577
  type: "button",
566
- onClick: (t) => Xt(e),
567
- onFocus: (e) => Gt.value = [t, n],
568
- onKeydown: (e) => Yt(e, t, n)
569
- }, { ref_for: !0 }, v(C).part?.("swatch", { selected: $(e) })), null, 16, Ie))), 128))]))), 128))])) : u("", !0)
578
+ onClick: (t) => $t(e),
579
+ onFocus: (e) => Jt.value = [t, n],
580
+ onKeydown: (e) => Qt(e, t, n)
581
+ }, { ref_for: !0 }, v(S).part?.("swatch", { selected: $(e) })), null, 16, ze))), 128))]))), 128))])) : u("", !0)
570
582
  ]),
571
583
  _: 1
572
584
  }),
573
- D.value ? (g(), me(ae, m({
585
+ D.value ? (g(), ge(oe, m({
574
586
  key: 1,
575
587
  modelValue: E.value,
576
- "onUpdate:modelValue": i[0] ||= (e) => E.value = e,
588
+ "onUpdate:modelValue": n[0] ||= (e) => E.value = e,
577
589
  class: "bb-color-palette__sheet",
578
- pt: v(C).forward({
590
+ pt: v(S).forward({
579
591
  panel: "root",
580
592
  sheet: "root"
581
- }, v(oe).states, () => c.offCanvasProps?.pt)
582
- }, m(rt.value, v(r)(v(C).forwardAttrs)), {
583
- onHidden: it,
584
- onHide: i[1] ||= (e) => S("hide"),
585
- onShow: i[2] ||= (e) => S("show"),
586
- onShown: i[3] ||= (e) => S("shown")
593
+ }, v(se).states, () => c.offCanvasProps?.pt)
594
+ }, m(ot.value, v(r)(v(S).forwardAttrs)), {
595
+ onHidden: st,
596
+ onHide: n[1] ||= (e) => x("hide"),
597
+ onShow: n[2] ||= (e) => x("show"),
598
+ onShown: n[3] ||= (e) => x("shown")
587
599
  }), {
588
- default: b(() => [f("div", ye(ge(Ct.value)), [p(v(We))], 16)]),
600
+ default: Oe(() => [f("div", xe(ve(Et.value)), [p(v(qe))], 16)]),
589
601
  _: 1
590
- }, 16, ["modelValue", "pt"])) : (g(), me(se, m({
602
+ }, 16, ["modelValue", "pt"])) : (g(), ge(ce, m({
591
603
  key: 2,
592
604
  modelValue: E.value,
593
- "onUpdate:modelValue": i[4] ||= (e) => E.value = e,
594
- anchor: Ye.value,
595
- "aria-label": v(w)("colorInput.dialogLabel").value,
605
+ "onUpdate:modelValue": n[4] ||= (e) => E.value = e,
606
+ anchor: Qe.value,
607
+ "aria-label": v(C)("colorInput.dialogLabel").value,
596
608
  boundary: c.boundary,
597
- "bubble-attrs": Ct.value,
609
+ "bubble-attrs": Et.value,
598
610
  class: "bb-color-palette",
599
611
  dialog: "",
600
612
  "disable-flip": c.disableFlip,
601
613
  eager: c.eager,
602
614
  "hide-arrow": "",
603
- offset: c.offset ?? v(ze)() ?? 4,
615
+ offset: c.offset ?? v(Ue)() ?? 4,
604
616
  padding: c.padding,
605
617
  placement: c.placement,
606
618
  "transition-duration": c.transitionDuration,
607
- onHidden: i[5] ||= (e) => S("hidden"),
608
- onHide: i[6] ||= (e) => S("hide"),
609
- onShow: i[7] ||= (e) => S("show"),
610
- onShown: i[8] ||= (e) => S("shown")
611
- }, v(C).rootAttrs), {
612
- default: b(() => [p(v(We))]),
619
+ onHidden: n[5] ||= (e) => x("hidden"),
620
+ onHide: n[6] ||= (e) => x("hide"),
621
+ onShow: n[7] ||= (e) => x("show"),
622
+ onShown: n[8] ||= (e) => x("shown")
623
+ }, v(S).rootAttrs), {
624
+ default: Oe(() => [p(v(qe))]),
613
625
  _: 1
614
626
  }, 16, [
615
627
  "modelValue",
@@ -627,4 +639,4 @@ var De = ["aria-label"], Oe = {
627
639
  ], 64));
628
640
  }
629
641
  });
630
- export { x as default };
642
+ export { b as default };