bitboss-ui 2.0.88 → 2.0.90

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 (316) hide show
  1. package/dist/assets/css/index.css +1 -0
  2. package/dist/components/BaseButton/BaseButton.css +1 -0
  3. package/dist/components/BaseCheckbox/BaseCheckbox.css +1 -0
  4. package/dist/components/BaseColorInput/BaseColorInput.css +1 -0
  5. package/dist/components/BaseDatePicker/BaseDatePicker.css +1 -0
  6. package/dist/components/BaseDatePickerInput/BaseDatePickerInput.css +1 -0
  7. package/dist/components/BaseDialog/BaseDialog.css +1 -0
  8. package/dist/components/BaseInputContainer/BaseInputContainer.css +1 -0
  9. package/dist/components/BaseNumberInput/BaseNumberInput.css +1 -0
  10. package/dist/components/BaseRadio/BaseRadio.css +1 -0
  11. package/dist/components/BaseRating/BaseRating.css +1 -0
  12. package/dist/components/BaseSelect/BaseSelect.css +1 -0
  13. package/dist/components/BaseSlider/BaseSlider.css +1 -0
  14. package/dist/components/BaseSwitch/BaseSwitch.css +1 -0
  15. package/dist/components/BaseTag/BaseTag.css +1 -0
  16. package/dist/components/BaseTextarea/BaseTextarea.css +1 -0
  17. package/dist/components/BbAccordion/BbAccordion.css +1 -0
  18. package/dist/components/BbAlert/BbAlert.css +1 -0
  19. package/dist/components/BbAvatar/BbAvatar.css +1 -0
  20. package/dist/components/BbBadge/BbBadge.css +1 -0
  21. package/dist/components/BbBreadcrumbs/BbBreadcrumbs.css +1 -0
  22. package/dist/components/BbButton/BbButton.css +1 -0
  23. package/dist/components/BbCheckbox/BbCheckbox.css +1 -0
  24. package/dist/components/BbChip/BbChip.css +1 -0
  25. package/dist/components/BbCollapsible/BbCollapsible.css +1 -0
  26. package/dist/components/BbColorInput/BbColorInput.css +1 -0
  27. package/dist/components/BbConfirm/BbConfirm.css +1 -0
  28. package/dist/components/BbDatePickerInput/BbDatePickerInput.css +1 -0
  29. package/dist/components/BbDropdown/BbDropdown.css +1 -0
  30. package/dist/components/BbDropdown/BbDropdown.vue.d.ts +8 -0
  31. package/dist/components/BbDropdownButton/BbDropdownButton.css +1 -0
  32. package/dist/components/BbDropzone/BbDropzone.css +1 -0
  33. package/dist/components/BbIcon/BbIcon.css +1 -0
  34. package/dist/components/BbNumberInput/BbNumberInput.css +1 -0
  35. package/dist/components/BbOffCanvas/BbOffCanvas.css +1 -0
  36. package/dist/components/BbPagination/BbPagination.css +1 -0
  37. package/dist/components/BbPopover/BbPopover.css +1 -0
  38. package/dist/components/BbProgress/BbProgress.css +1 -0
  39. package/dist/components/BbRadio/BbRadio.css +1 -0
  40. package/dist/components/BbRatio/BbRatio.css +1 -0
  41. package/dist/components/BbSelect/BbSelect.css +1 -0
  42. package/dist/components/BbSlider/BbSlider.css +1 -0
  43. package/dist/components/BbSmoothHeight/BbSmoothHeight.css +1 -0
  44. package/dist/components/BbSpinner/BbSpinner.css +1 -0
  45. package/dist/components/BbSwitch/BbSwitch.css +1 -0
  46. package/dist/components/BbTab/BbTab.css +1 -0
  47. package/dist/components/BbTable/BbTable.css +1 -0
  48. package/dist/components/BbTag/BbTag.css +1 -0
  49. package/dist/components/BbTextInput/BbTextInput.css +1 -0
  50. package/dist/components/BbTextarea/BbTextarea.css +1 -0
  51. package/dist/components/BbToast/BbToast.css +1 -0
  52. package/dist/components/BbTooltip/BbTooltip.css +1 -0
  53. package/dist/components/BbTree/BbTree.css +1 -0
  54. package/dist/components/ChipsBox.css +1 -0
  55. package/dist/components/CommaBox.css +1 -0
  56. package/dist/components/CommonFloating.css +1 -0
  57. package/dist/components/CommonFloating.vue.d.ts +1 -3
  58. package/dist/components/CommonInputOuterContainer.css +1 -0
  59. package/dist/components/ErrorIcon.css +1 -0
  60. package/dist/components/OptionsContainer.css +1 -0
  61. package/dist/components/Transitions/Slide.css +1 -0
  62. package/dist/components/Transitions/SlideBack.css +1 -0
  63. package/dist/index.js +141 -142
  64. package/dist/index10.js +35 -74
  65. package/dist/{index102.js → index101.js} +2 -2
  66. package/dist/{index104.js → index103.js} +2 -2
  67. package/dist/{index106.js → index105.js} +2 -2
  68. package/dist/{index108.js → index107.js} +7 -7
  69. package/dist/{index110.js → index109.js} +9 -9
  70. package/dist/index11.js +189 -36
  71. package/dist/{index112.js → index111.js} +2 -2
  72. package/dist/{index114.js → index113.js} +2 -2
  73. package/dist/{index116.js → index115.js} +2 -2
  74. package/dist/{index118.js → index117.js} +3 -3
  75. package/dist/{index120.js → index119.js} +7 -7
  76. package/dist/index12.js +80 -191
  77. package/dist/index123.js +42 -0
  78. package/dist/index124.js +39 -35
  79. package/dist/index125.js +46 -39
  80. package/dist/index126.js +42 -46
  81. package/dist/index127.js +31 -43
  82. package/dist/index128.js +2 -35
  83. package/dist/index129.js +21 -2
  84. package/dist/index130.js +2 -21
  85. package/dist/index131.js +340 -2
  86. package/dist/index132.js +22 -337
  87. package/dist/index133.js +2 -25
  88. package/dist/index134.js +5 -2
  89. package/dist/index135.js +9 -5
  90. package/dist/index136.js +5 -8
  91. package/dist/index137.js +3 -6
  92. package/dist/index138.js +1 -1
  93. package/dist/index139.js +1 -1
  94. package/dist/{index15.js → index14.js} +4 -4
  95. package/dist/index140.js +1 -1
  96. package/dist/index141.js +1 -1
  97. package/dist/index142.js +1 -1
  98. package/dist/index143.js +1 -1
  99. package/dist/index144.js +1 -1
  100. package/dist/index145.js +1 -1
  101. package/dist/index146.js +1 -1
  102. package/dist/index147.js +1 -1
  103. package/dist/index148.js +1 -1
  104. package/dist/index149.js +1 -1
  105. package/dist/index150.js +1 -1
  106. package/dist/index151.js +1 -1
  107. package/dist/index152.js +1 -1
  108. package/dist/index153.js +1 -1
  109. package/dist/index154.js +1 -1
  110. package/dist/index155.js +1 -1
  111. package/dist/index156.js +1 -1
  112. package/dist/index157.js +1 -1
  113. package/dist/index158.js +1 -1
  114. package/dist/index159.js +1 -1
  115. package/dist/{index17.js → index16.js} +3 -3
  116. package/dist/index160.js +1 -1
  117. package/dist/index161.js +1 -1
  118. package/dist/index162.js +1 -1
  119. package/dist/index163.js +1 -1
  120. package/dist/index164.js +2 -2
  121. package/dist/index168.js +5 -0
  122. package/dist/index169.js +1 -1
  123. package/dist/index170.js +1 -1
  124. package/dist/index171.js +1 -1
  125. package/dist/index172.js +1 -1
  126. package/dist/index173.js +1 -1
  127. package/dist/index174.js +1 -1
  128. package/dist/index175.js +2 -2
  129. package/dist/index177.js +4 -0
  130. package/dist/index178.js +3 -2
  131. package/dist/index179.js +1 -1
  132. package/dist/{index19.js → index18.js} +3 -3
  133. package/dist/index180.js +1 -1
  134. package/dist/index181.js +1 -1
  135. package/dist/index182.js +1 -1
  136. package/dist/index183.js +1 -1
  137. package/dist/index184.js +1 -1
  138. package/dist/index185.js +1 -1
  139. package/dist/index186.js +1 -1
  140. package/dist/index187.js +2 -2
  141. package/dist/index188.js +1 -1
  142. package/dist/index189.js +1 -1
  143. package/dist/{index167.js → index193.js} +1 -1
  144. package/dist/index194.js +1 -1
  145. package/dist/index195.js +1 -1
  146. package/dist/index196.js +1 -1
  147. package/dist/index197.js +1 -1
  148. package/dist/index198.js +1 -1
  149. package/dist/index199.js +1 -1
  150. package/dist/{index21.js → index20.js} +17 -18
  151. package/dist/index200.js +1 -1
  152. package/dist/index201.js +1 -1
  153. package/dist/index202.js +1 -1
  154. package/dist/index203.js +81 -3
  155. package/dist/index205.js +51 -80
  156. package/dist/index207.js +13 -84
  157. package/dist/index208.js +10 -0
  158. package/dist/index209.js +2 -126
  159. package/dist/index210.js +4 -5
  160. package/dist/index211.js +123 -122
  161. package/dist/index212.js +5 -19
  162. package/dist/index213.js +122 -13
  163. package/dist/index214.js +18 -15
  164. package/dist/index215.js +16 -2
  165. package/dist/index216.js +16 -2
  166. package/dist/index217.js +2 -41
  167. package/dist/index218.js +2 -20
  168. package/dist/index219.js +41 -6
  169. package/dist/{index23.js → index22.js} +21 -21
  170. package/dist/index220.js +18 -51
  171. package/dist/index221.js +8 -0
  172. package/dist/index222.js +4 -12
  173. package/dist/index223.js +12 -5
  174. package/dist/index224.js +369 -12
  175. package/dist/index225.js +2 -369
  176. package/dist/index226.js +3 -3
  177. package/dist/index227.js +4 -7
  178. package/dist/index228.js +3 -8
  179. package/dist/index229.js +7 -19
  180. package/dist/index230.js +162 -25
  181. package/dist/index231.js +84 -3
  182. package/dist/index233.js +18 -51
  183. package/dist/index234.js +27 -44
  184. package/dist/index235.js +3 -5
  185. package/dist/index236.js +242 -53
  186. package/dist/index237.js +52 -4
  187. package/dist/index238.js +44 -2
  188. package/dist/index239.js +5 -4
  189. package/dist/{index25.js → index24.js} +8 -8
  190. package/dist/index240.js +60 -2
  191. package/dist/index241.js +2 -3
  192. package/dist/index242.js +18 -2
  193. package/dist/index243.js +105 -17
  194. package/dist/{index246.js → index245.js} +2 -2
  195. package/dist/index247.js +4 -0
  196. package/dist/index250.js +3 -2
  197. package/dist/index252.js +7 -16
  198. package/dist/index255.js +3 -3
  199. package/dist/index257.js +4 -3
  200. package/dist/index258.js +281 -12
  201. package/dist/index259.js +5 -8
  202. package/dist/{index27.js → index26.js} +5 -5
  203. package/dist/index260.js +2 -9
  204. package/dist/index261.js +2 -17
  205. package/dist/index262.js +2 -4
  206. package/dist/index263.js +2 -281
  207. package/dist/index264.js +2 -6
  208. package/dist/index265.js +126 -2
  209. package/dist/index266.js +431 -2
  210. package/dist/index267.js +176 -2
  211. package/dist/index268.js +22 -2
  212. package/dist/index270.js +2 -126
  213. package/dist/index271.js +219 -426
  214. package/dist/index272.js +6 -176
  215. package/dist/index273.js +16 -3
  216. package/dist/index274.js +11 -0
  217. package/dist/index275.js +199 -6
  218. package/dist/index276.js +435 -21
  219. package/dist/index277.js +129 -0
  220. package/dist/index278.js +89 -2
  221. package/dist/index279.js +3 -89
  222. package/dist/{index29.js → index28.js} +2 -2
  223. package/dist/index280.js +12 -2
  224. package/dist/index281.js +9 -2
  225. package/dist/index282.js +9 -2
  226. package/dist/index283.js +17 -2
  227. package/dist/index284.js +4 -2
  228. package/dist/index285.js +2 -2
  229. package/dist/index286.js +2 -28
  230. package/dist/index287.js +1 -21
  231. package/dist/index288.js +4 -0
  232. package/dist/index289.js +2 -9
  233. package/dist/index290.js +2 -200
  234. package/dist/index291.js +23 -431
  235. package/dist/index292.js +21 -126
  236. package/dist/index294.js +2 -224
  237. package/dist/index295.js +1 -1
  238. package/dist/index296.js +1 -1
  239. package/dist/index297.js +4 -4
  240. package/dist/index299.js +66 -2
  241. package/dist/index3.js +16 -0
  242. package/dist/{index31.js → index30.js} +2 -2
  243. package/dist/index300.js +32 -65
  244. package/dist/index301.js +1 -1
  245. package/dist/index302.js +1 -1
  246. package/dist/index303.js +4 -3
  247. package/dist/index304.js +3 -3
  248. package/dist/index305.js +3 -58
  249. package/dist/index306.js +3 -3
  250. package/dist/index307.js +57 -32
  251. package/dist/index308.js +10 -3
  252. package/dist/index309.js +6 -10
  253. package/dist/index312.js +46 -6
  254. package/dist/index313.js +2 -47
  255. package/dist/index315.js +2 -2
  256. package/dist/index316.js +426 -0
  257. package/dist/index317.js +43 -420
  258. package/dist/index318.js +2 -47
  259. package/dist/{index33.js → index32.js} +3 -3
  260. package/dist/{index35.js → index34.js} +4 -4
  261. package/dist/{index37.js → index36.js} +22 -23
  262. package/dist/{index39.js → index38.js} +6 -6
  263. package/dist/index4.js +40 -14
  264. package/dist/{index41.js → index40.js} +2 -2
  265. package/dist/{index43.js → index42.js} +3 -3
  266. package/dist/{index45.js → index44.js} +20 -21
  267. package/dist/{index47.js → index46.js} +3 -3
  268. package/dist/{index49.js → index48.js} +2 -2
  269. package/dist/index5.js +76 -38
  270. package/dist/{index51.js → index50.js} +3 -3
  271. package/dist/{index53.js → index52.js} +2 -2
  272. package/dist/{index55.js → index54.js} +2 -2
  273. package/dist/{index57.js → index56.js} +2 -2
  274. package/dist/{index59.js → index58.js} +1 -1
  275. package/dist/index6.js +62 -78
  276. package/dist/{index61.js → index60.js} +5 -6
  277. package/dist/{index63.js → index62.js} +2 -2
  278. package/dist/{index65.js → index64.js} +2 -2
  279. package/dist/{index67.js → index66.js} +2 -2
  280. package/dist/{index69.js → index68.js} +4 -4
  281. package/dist/index7.js +10 -60
  282. package/dist/{index71.js → index70.js} +2 -2
  283. package/dist/{index73.js → index72.js} +1 -1
  284. package/dist/{index75.js → index74.js} +99 -85
  285. package/dist/{index77.js → index76.js} +6 -7
  286. package/dist/{index79.js → index78.js} +4 -4
  287. package/dist/index8.js +7 -11
  288. package/dist/index80.js +46 -0
  289. package/dist/index81.js +120 -37
  290. package/dist/{index84.js → index83.js} +5 -5
  291. package/dist/{index86.js → index85.js} +17 -18
  292. package/dist/{index88.js → index87.js} +6 -6
  293. package/dist/{index90.js → index89.js} +1 -1
  294. package/dist/index9.js +78 -7
  295. package/dist/{index92.js → index91.js} +2 -2
  296. package/dist/{index94.js → index93.js} +2 -2
  297. package/dist/{index96.js → index95.js} +2 -2
  298. package/dist/{index100.js → index99.js} +2 -2
  299. package/package.json +3 -3
  300. package/dist/index13.js +0 -84
  301. package/dist/index176.js +0 -5
  302. package/dist/index192.js +0 -5
  303. package/dist/index206.js +0 -166
  304. package/dist/index232.js +0 -251
  305. package/dist/index244.js +0 -108
  306. package/dist/index251.js +0 -8
  307. package/dist/index269.js +0 -4
  308. package/dist/index293.js +0 -6
  309. package/dist/index314.js +0 -4
  310. package/dist/index319.js +0 -4
  311. package/dist/index82.js +0 -129
  312. package/dist/style.css +0 -1
  313. /package/dist/{index122.js → index121.js} +0 -0
  314. /package/dist/{index165.js → index166.js} +0 -0
  315. /package/dist/{index190.js → index191.js} +0 -0
  316. /package/dist/{index98.js → index97.js} +0 -0
package/dist/index7.js CHANGED
@@ -1,64 +1,14 @@
1
- import { getAsPercentage as p } from "./index130.js";
2
- import { wait as w } from "./index131.js";
3
- import { ref as c, computed as o, onBeforeUnmount as H } from "vue";
4
- const Y = ({
5
- duration: t,
6
- onStart: f,
7
- onFinish: i,
8
- onStop: s
9
- }) => {
10
- if (!t)
11
- throw new Error("You must define a duration for the coundown");
12
- const e = c(t), u = c(0), M = o(() => p(u.value, t)), m = 100, r = c(!1), n = c(!1);
13
- let a;
14
- const I = () => {
15
- u.value === t || r.value && !n.value || (f && f(), n.value = !1, r.value = !0, a = setInterval(() => {
16
- e.value = Math.max(e.value - m, 0), u.value = Math.min(u.value + m, t), e.value === 0 && w(0).then(() => {
17
- clearInterval(a), r.value = !1, s && s(), i && i();
18
- });
19
- }, m));
20
- }, d = () => {
21
- A(), I();
22
- }, A = () => {
23
- a && clearInterval(a), n.value || s && s(), e.value = t, u.value = 0, r.value = !1, n.value = !1;
24
- }, g = () => {
25
- a && clearInterval(a), n.value || s && s(), n.value = !0;
26
- }, y = o(() => {
27
- const l = Math.trunc(e.value / 864e5), v = Math.trunc((e.value - l * 864e5) / 36e5), h = Math.trunc(
28
- (e.value - v * 36e5 - l * 864e5) / 6e4
29
- ), D = Math.trunc(
30
- (e.value - h * 6e4 - v * 36e5 - l * 864e5) / 1e3
31
- );
32
- return {
33
- days: l,
34
- hours: v,
35
- minutes: h,
36
- seconds: D
37
- };
38
- });
39
- return H(() => clearInterval(a)), {
40
- /** Elapsed milliseconds since starting the timer */
41
- elapsed: o(() => u.value),
42
- /** Remaining milliseconds */
43
- remaining: o(() => e.value),
44
- /** Remaining as a formatted object for display */
45
- remainingFormatted: y,
46
- /** Percentage of elapsed time against duration */
47
- progress: M,
48
- /** Starts the timer */
49
- start: I,
50
- /** Reset the timer to intiial state and starts again */
51
- restart: d,
52
- /** Pauses the timer */
53
- pause: g,
54
- /** Reset the timer to initial state, if the timer is running it is stopped */
55
- reset: A,
56
- /** Boolean, is the timer running (paused doesn't change running state) */
57
- running: r,
58
- /** Boolean is the timer paused */
59
- paused: n
1
+ import { ref as s, useId as t } from "vue";
2
+ const r = () => "bb-ui-" + t(), n = () => {
3
+ const e = s(r());
4
+ return {
5
+ /**
6
+ * The generated id
7
+ */
8
+ id: e,
9
+ refresh: () => e.value = r()
60
10
  };
61
11
  };
62
12
  export {
63
- Y as useCountdown
13
+ n as useId
64
14
  };
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as m, ref as u, computed as c, openBlock as h, createBlock as f, withCtx as l, renderSlot as b, normalizeProps as v, guardReactiveProps as y, createVNode as w, mergeProps as g } from "vue";
2
- import B from "./index23.js";
2
+ import B from "./index22.js";
3
3
  /* empty css */
4
- import k from "./index27.js";
4
+ import k from "./index26.js";
5
5
  /* empty css */
6
6
  const E = /* @__PURE__ */ m({
7
7
  __name: "BbDatePickerInput",
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as d, computed as u, openBlock as m, createBlock as f, mergeProps as y, withCtx as l, renderSlot as t, normalizeProps as a, guardReactiveProps as r } from "vue";
2
- import $ from "./index25.js";
2
+ import $ from "./index24.js";
3
3
  /* empty css */
4
4
  const b = /* @__PURE__ */ d({
5
5
  __name: "BbDialog",
@@ -1,14 +1,16 @@
1
- import { defineComponent as J, computed as A, ref as w, openBlock as T, createElementBlock as D, mergeProps as B, createElementVNode as C, renderSlot as g, normalizeProps as Q, guardReactiveProps as W, unref as h, createVNode as O, withCtx as K, normalizeStyle as X, Fragment as P, renderList as Y } from "vue";
2
- import { findRightIndex as H } from "./index253.js";
3
- import { useId as Z } from "./index8.js";
4
- import { wait as x } from "./index131.js";
5
- import { useIntersectionObserver as ee } from "./index132.js";
6
- import te from "./index13.js";
1
+ import { defineComponent as X, computed as A, ref as y, openBlock as h, createElementBlock as T, mergeProps as B, createElementVNode as H, renderSlot as w, normalizeProps as Y, guardReactiveProps as Z, unref as $, createVNode as C, withCtx as O, normalizeStyle as x, Fragment as K, renderList as ee, createBlock as P, createCommentVNode as N, toDisplayString as te } from "vue";
2
+ import { findRightIndex as I } from "./index253.js";
3
+ import { useId as ne } from "./index7.js";
4
+ import { wait as oe } from "./index130.js";
5
+ import { useIntersectionObserver as ae } from "./index131.js";
6
+ import le from "./index12.js";
7
7
  /* empty css */
8
- import j from "./index254.js";
9
- import ne from "./index255.js";
8
+ import V from "./index254.js";
9
+ import se from "./index255.js";
10
10
  /* empty css */
11
- const pe = /* @__PURE__ */ J({
11
+ import j from "./index125.js";
12
+ /* empty css */
13
+ const ie = { class: "item__content" }, ke = /* @__PURE__ */ X({
12
14
  __name: "BbDropdown",
13
15
  props: {
14
16
  arrowPadding: { default: 10 },
@@ -25,47 +27,47 @@ const pe = /* @__PURE__ */ J({
25
27
  width: { default: 200 }
26
28
  },
27
29
  setup(z) {
28
- const r = z, d = r.id ?? `bb_${Z().id.value}`, m = A(() => {
29
- let e = r.items.findIndex((t) => !t.disabled), o = H(
30
+ const r = z, u = r.id ?? `bb_${ne().id.value}`, m = A(() => {
31
+ let e = r.items.findIndex((t) => !t.disabled), o = I(
30
32
  r.items,
31
33
  (t) => !t.disabled
32
34
  );
33
35
  return r.items.map((t, n) => {
34
- const i = `${d}-item-${t.key}`, { onClick: q, ...F } = t, _ = async () => {
36
+ const i = `${u}-item-${t.key}`, { onClick: q, ...F } = t, Q = async () => {
35
37
  await b();
36
- const s = document.querySelector(`#${d}`);
38
+ const s = document.querySelector(`#${u}`);
37
39
  if (s) s instanceof HTMLElement && s.focus();
38
40
  else return;
39
41
  q && q();
40
- }, G = (s) => {
42
+ }, W = (s) => {
41
43
  if (s.target instanceof HTMLElement && s.target.dataset.dropdownItem) {
42
44
  if (!a.value) return;
43
45
  if (s.key === "ArrowDown") {
44
46
  if (s.preventDefault(), a.value && n !== o) {
45
- const u = a.value.querySelector(
46
- j.map((y) => `#${i} ~ ${y}`).join(",")
47
+ const d = a.value.querySelector(
48
+ V.map((g) => `#${i} ~ ${g}`).join(",")
47
49
  );
48
- u && u instanceof HTMLElement && u.focus();
50
+ d && d instanceof HTMLElement && d.focus();
49
51
  }
50
52
  } else if (s.key === "ArrowUp") {
51
53
  if (s.preventDefault(), a.value && n !== e) {
52
- const u = H(r.items, (E, L) => L < n && !E.disabled), k = Array.from(
54
+ const d = I(r.items, (E, D) => D < n && !E.disabled), k = Array.from(
53
55
  a.value.querySelectorAll(".bb-dropdown__item")
54
- )[u];
56
+ )[d];
55
57
  k && k instanceof HTMLElement && k.focus();
56
58
  }
57
59
  } else if (s.key === "Tab") {
58
60
  if (n === o && !s.shiftKey) {
59
- const u = j.join(","), y = Array.from(
60
- document.querySelectorAll(u)
61
- ), k = y.findIndex(
62
- (L) => L.id === d
63
- ), E = y[k + 1];
61
+ const d = V.join(","), g = Array.from(
62
+ document.querySelectorAll(d)
63
+ ), k = g.findIndex(
64
+ (D) => D.id === u
65
+ ), E = g[k + 1];
64
66
  if (E) E instanceof HTMLElement && (s.preventDefault(), b(), E.focus());
65
67
  else return;
66
68
  } else if (n === e && s.shiftKey) {
67
- const u = document.querySelector(`#${d}`);
68
- if (u) u instanceof HTMLElement && (s.preventDefault(), u.focus());
69
+ const d = document.querySelector(`#${u}`);
70
+ if (d) d instanceof HTMLElement && (s.preventDefault(), d.focus());
69
71
  else return;
70
72
  }
71
73
  }
@@ -75,34 +77,34 @@ const pe = /* @__PURE__ */ J({
75
77
  ...F,
76
78
  disabled: F.disabled || r.disabled,
77
79
  id: i,
78
- onClick: _,
79
- onKeydown: G
80
+ onClick: Q,
81
+ onKeydown: W
80
82
  };
81
83
  });
82
- }), v = w(), a = w();
83
- ee(
84
+ }), v = y(), a = y();
85
+ ae(
84
86
  v,
85
87
  ([{ intersectionRatio: e }]) => {
86
88
  e !== 1 && l.value && b();
87
89
  },
88
90
  { threshold: [0, 1] }
89
91
  );
90
- const c = w(!1), l = w(!1), f = w(!1), p = w(!0), N = () => {
91
- c.value || f.value || (l.value ? b() : $());
92
- }, R = async (e) => {
93
- let o = r.items.findIndex((n) => !n.disabled), t = H(
92
+ const c = y(!1), l = y(!1), p = y(!1), f = y(!0), R = () => {
93
+ c.value || p.value || (l.value ? b() : L());
94
+ }, U = async (e) => {
95
+ let o = r.items.findIndex((n) => !n.disabled), t = I(
94
96
  r.items,
95
97
  (n) => !n.disabled
96
98
  );
97
99
  if (e.key === "ArrowDown") {
98
- if (e.preventDefault(), f.value || c.value) return;
99
- if (p.value && await $(), a.value && m.value.length && o !== -1) {
100
+ if (e.preventDefault(), p.value || c.value) return;
101
+ if (f.value && await L(), a.value && m.value.length && o !== -1) {
100
102
  const n = m.value[o].id, i = a.value.querySelector(`#${n}`);
101
103
  i && i instanceof HTMLElement && i.focus();
102
104
  }
103
105
  } else if (e.key === "ArrowUp") {
104
- if (e.preventDefault(), f.value || c.value) return;
105
- if (p.value && await $(), a.value && m.value.length && t !== -1) {
106
+ if (e.preventDefault(), p.value || c.value) return;
107
+ if (f.value && await L(), a.value && m.value.length && t !== -1) {
106
108
  const n = m.value[t].id, i = a.value.querySelector(`#${n}`);
107
109
  i && i instanceof HTMLElement && i.focus();
108
110
  }
@@ -110,66 +112,66 @@ const pe = /* @__PURE__ */ J({
110
112
  const n = m.value[o].id, i = a.value.querySelector(`#${n}`);
111
113
  i && i instanceof HTMLElement && i.focus();
112
114
  }
113
- }, I = (e) => {
115
+ }, M = (e) => {
114
116
  const o = e.target;
115
117
  if (o && o instanceof HTMLElement) {
116
118
  let t = !0;
117
119
  v.value && v.value.contains(o) && (t = !1), a.value && a.value.contains(o) && (t = !1), t && b();
118
120
  }
119
- }, M = (e) => {
121
+ }, S = (e) => {
120
122
  const o = e.target;
121
123
  if (o && o instanceof HTMLElement) {
122
124
  let t = !0;
123
125
  v.value && v.value.contains(o) && (t = !1), a.value && a.value.contains(o) && (t = !1), t && b();
124
126
  }
125
- }, S = (e) => {
127
+ }, _ = (e) => {
126
128
  var o;
127
129
  if (l.value && e.key === "Escape") {
128
- if (((o = document.activeElement) == null ? void 0 : o.id) !== d) {
129
- const t = document.querySelector(`#${d}`);
130
+ if (((o = document.activeElement) == null ? void 0 : o.id) !== u) {
131
+ const t = document.querySelector(`#${u}`);
130
132
  t instanceof HTMLElement && t.focus();
131
133
  }
132
134
  b();
133
135
  }
134
- }, U = w(!1), $ = async () => {
135
- U.value = !0, await x(50), l.value = !0, document.addEventListener("click", I, { passive: !0 }), document.addEventListener("focusin", M, { passive: !0 }), document.addEventListener("keydown", S, { passive: !0 });
136
+ }, G = y(!1), L = async () => {
137
+ G.value = !0, await oe(50), l.value = !0, document.addEventListener("click", M, { passive: !0 }), document.addEventListener("focusin", S, { passive: !0 }), document.addEventListener("keydown", _, { passive: !0 });
136
138
  }, b = async () => {
137
- l.value = !1, document.removeEventListener("click", I), document.removeEventListener("focusin", M), document.removeEventListener("keydown", S);
138
- }, V = A(() => ({
139
+ l.value = !1, document.removeEventListener("click", M), document.removeEventListener("focusin", S), document.removeEventListener("keydown", _);
140
+ }, J = A(() => ({
139
141
  class: {
140
142
  "bb-dropdown--block": r.block,
141
143
  [`bb-dropdown--theme-${r.theme}`]: r.theme
142
144
  }
143
145
  }));
144
- return (e, o) => (T(), D("span", B({ class: "bb-dropdown" }, V.value), [
145
- C("span", {
146
+ return (e, o) => (h(), T("span", B({ class: "bb-dropdown" }, J.value), [
147
+ H("span", {
146
148
  ref_key: "wrapper",
147
149
  ref: v,
148
150
  class: "bb-dropdown__wrapper"
149
151
  }, [
150
- g(e.$slots, "activator", Q(W({
152
+ w(e.$slots, "activator", Y(Z({
151
153
  props: {
152
154
  "aria-expanded": l.value,
153
- "aria-controls": `menu_${h(d)}`,
154
- id: h(d),
155
- onClick: N,
156
- onKeydown: R,
155
+ "aria-controls": `menu_${$(u)}`,
156
+ id: $(u),
157
+ onClick: R,
158
+ onKeydown: U,
157
159
  disabled: e.disabled
158
160
  },
159
- closed: p.value,
160
- closing: f.value,
161
+ closed: f.value,
162
+ closing: p.value,
161
163
  disabled: e.disabled,
162
164
  open: l.value,
163
165
  opening: c.value,
164
166
  placement: e.placement
165
167
  })))
166
168
  ], 512),
167
- O(ne, {
169
+ C(se, {
168
170
  "arrow-padding": e.arrowPadding,
169
171
  "base-class": "bb-dropdown",
170
172
  "container-attributes": {
171
- id: `menu_${h(d)}`,
172
- "aria-labelledby": h(d),
173
+ id: `menu_${$(u)}`,
174
+ "aria-labelledby": $(u),
173
175
  "aria-role": "menu"
174
176
  },
175
177
  eager: e.eager,
@@ -181,27 +183,27 @@ const pe = /* @__PURE__ */ J({
181
183
  "transition-duration": e.transitionDuration,
182
184
  wrapper: v.value
183
185
  }, {
184
- default: K(() => [
185
- C("span", {
186
+ default: O(() => [
187
+ H("span", {
186
188
  ref_key: "content",
187
189
  ref: a,
188
190
  class: "bb-dropdown__items-container",
189
- style: X({ width: `${e.width}px` })
191
+ style: x({ width: `${e.width}px` })
190
192
  }, [
191
- g(e.$slots, "prepend", {
192
- closed: p.value,
193
- closing: f.value,
193
+ w(e.$slots, "prepend", {
194
+ closed: f.value,
195
+ closing: p.value,
194
196
  disabled: e.disabled,
195
197
  open: l.value,
196
198
  opening: c.value,
197
199
  placement: e.placement
198
200
  }),
199
- (T(!0), D(P, null, Y(m.value, (t, n) => (T(), D(P, {
201
+ (h(!0), T(K, null, ee(m.value, (t, n) => (h(), T(K, {
200
202
  key: t.key
201
203
  }, [
202
- g(e.$slots, "item:prepend", {
203
- closed: p.value,
204
- closing: f.value,
204
+ w(e.$slots, "item:prepend", {
205
+ closed: f.value,
206
+ closing: p.value,
205
207
  disabled: t.disabled,
206
208
  index: n,
207
209
  item: e.items[n],
@@ -210,7 +212,7 @@ const pe = /* @__PURE__ */ J({
210
212
  placement: e.placement,
211
213
  text: t.text
212
214
  }),
213
- O(te, B({
215
+ C(le, B({
214
216
  "aria-role": "menuitem",
215
217
  class: ["bb-dropdown__item", {
216
218
  "bb-dropdown__item--first": n === 0,
@@ -219,10 +221,10 @@ const pe = /* @__PURE__ */ J({
219
221
  "data-dropdown-item": !0,
220
222
  ref_for: !0
221
223
  }, t), {
222
- default: K(() => [
223
- g(e.$slots, t.key, {
224
- closed: p.value,
225
- closing: f.value,
224
+ default: O(() => [
225
+ w(e.$slots, t.key, {
226
+ closed: f.value,
227
+ closing: p.value,
226
228
  disabled: t.disabled,
227
229
  index: n,
228
230
  item: t,
@@ -231,9 +233,9 @@ const pe = /* @__PURE__ */ J({
231
233
  placement: e.placement,
232
234
  text: t.text
233
235
  }, () => [
234
- g(e.$slots, "item", {
235
- closed: p.value,
236
- closing: f.value,
236
+ w(e.$slots, "item", {
237
+ closed: f.value,
238
+ closing: p.value,
237
239
  disabled: t.disabled,
238
240
  index: n,
239
241
  item: t,
@@ -241,14 +243,26 @@ const pe = /* @__PURE__ */ J({
241
243
  opening: c.value,
242
244
  placement: e.placement,
243
245
  text: t.text
244
- })
246
+ }, () => [
247
+ t["prepend:icon"] ? (h(), P(j, {
248
+ key: 0,
249
+ class: "item__prepend-icon",
250
+ type: t["prepend:icon"]
251
+ }, null, 8, ["type"])) : N("", !0),
252
+ H("span", ie, te(t.text), 1),
253
+ t["append:icon"] ? (h(), P(j, {
254
+ key: 1,
255
+ class: "item__append-icon",
256
+ type: t["append:icon"]
257
+ }, null, 8, ["type"])) : N("", !0)
258
+ ])
245
259
  ])
246
260
  ]),
247
261
  _: 2
248
262
  }, 1040, ["class"]),
249
- g(e.$slots, "item:append", {
250
- closed: p.value,
251
- closing: f.value,
263
+ w(e.$slots, "item:append", {
264
+ closed: f.value,
265
+ closing: p.value,
252
266
  disabled: t.disabled,
253
267
  index: n,
254
268
  item: e.items[n],
@@ -258,9 +272,9 @@ const pe = /* @__PURE__ */ J({
258
272
  text: t.text
259
273
  })
260
274
  ], 64))), 128)),
261
- g(e.$slots, "append", {
262
- closed: p.value,
263
- closing: f.value,
275
+ w(e.$slots, "append", {
276
+ closed: f.value,
277
+ closing: p.value,
264
278
  disabled: e.disabled,
265
279
  open: l.value,
266
280
  opening: c.value,
@@ -274,5 +288,5 @@ const pe = /* @__PURE__ */ J({
274
288
  }
275
289
  });
276
290
  export {
277
- pe as default
291
+ ke as default
278
292
  };
@@ -1,18 +1,17 @@
1
1
  import { defineComponent as z, ref as E, computed as B, openBlock as s, createElementBlock as $, normalizeClass as W, createVNode as l, mergeProps as C, withCtx as t, unref as m, createBlock as L, createCommentVNode as w, createElementVNode as u, toDisplayString as P, createSlots as A, renderSlot as a, normalizeProps as d, guardReactiveProps as r, renderList as I } from "vue";
2
- import D from "./index13.js";
2
+ import D from "./index12.js";
3
3
  /* empty css */
4
- import M from "./index75.js";
4
+ import M from "./index74.js";
5
5
  /* empty css */
6
6
  /* empty css */
7
- /* empty css */
8
- import N from "./index126.js";
7
+ import N from "./index125.js";
9
8
  /* empty css */
10
- import R from "./index128.js";
9
+ import R from "./index127.js";
11
10
  /* empty css */
12
11
  const Z = { class: "bb-dropdown-button__content" }, j = {
13
12
  key: 1,
14
13
  class: "bb-dropdown-button__loading-label sr-only"
15
- }, q = { class: "bb-dropdown-button__dropdown-label sr-only" }, x = /* @__PURE__ */ z({
14
+ }, q = { class: "bb-dropdown-button__dropdown-label sr-only" }, Y = /* @__PURE__ */ z({
16
15
  __name: "BbDropdownButton",
17
16
  props: {
18
17
  arrowPadding: {},
@@ -155,5 +154,5 @@ const Z = { class: "bb-dropdown-button__content" }, j = {
155
154
  }
156
155
  });
157
156
  export {
158
- x as default
157
+ Y as default
159
158
  };
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as j, ref as g, watch as x, computed as m, openBlock as V, createBlock as G, resolveDynamicComponent as K, normalizeClass as O, withCtx as M, createElementVNode as c, withModifiers as y, renderSlot as U, normalizeProps as Y, guardReactiveProps as Z, createTextVNode as J, unref as Q, createVNode as W, createElementBlock as F, Fragment as X, renderList as ee, toDisplayString as te } from "vue";
2
- import { findInTree as ae } from "./index252.js";
3
- import { useId as re } from "./index8.js";
4
- import oe from "./index127.js";
2
+ import { findInTree as ae } from "./index273.js";
3
+ import { useId as re } from "./index7.js";
4
+ import oe from "./index126.js";
5
5
  /* empty css */
6
6
  const le = ["accept", "autofocus", "disabled", "multiple"], se = { class: "bb-dropzone__submittable-label" }, ne = ["id", "disabled", "multiple", "name"], ie = { class: "bb-dropzone__errors" }, fe = /* @__PURE__ */ j({
7
7
  __name: "BbDropzone",
@@ -53,7 +53,7 @@ const le = ["accept", "autofocus", "disabled", "multiple"], se = { class: "bb-dr
53
53
  const r = a.accept[t];
54
54
  if (r.includes("/")) e.push(r);
55
55
  else {
56
- b || (b = (await import("./index251.js")).default);
56
+ b || (b = (await import("./index272.js")).default);
57
57
  const o = b.getType(r);
58
58
  if (!o)
59
59
  throw new Error(
package/dist/index8.js CHANGED
@@ -1,14 +1,10 @@
1
- import { ref as s, useId as t } from "vue";
2
- const r = () => "bb-ui-" + t(), n = () => {
3
- const e = s(r());
4
- return {
5
- /**
6
- * The generated id
7
- */
8
- id: e,
9
- refresh: () => e.value = r()
10
- };
1
+ import { useWindowSize as i } from "./index131.js";
2
+ import { computed as e } from "vue";
3
+ import { _config as t } from "./index3.js";
4
+ const c = () => {
5
+ const { width: o } = i();
6
+ return { isMobile: e(() => o.value < t.mobileMaxWidth) };
11
7
  };
12
8
  export {
13
- n as useId
9
+ c as useMobile
14
10
  };
@@ -0,0 +1,46 @@
1
+ import { defineComponent as h, ref as t, onMounted as m, onBeforeUnmount as p, openBlock as g, createBlock as b, resolveDynamicComponent as w, withCtx as _, renderSlot as I } from "vue";
2
+ import { throttle as c } from "./index228.js";
3
+ const M = /* @__PURE__ */ h({
4
+ __name: "BbIntersection",
5
+ props: {
6
+ debounceTime: { default: 0 },
7
+ options: { default: () => ({
8
+ root: null,
9
+ threshold: [0, 0.2, 0.4, 0.6, 0.8, 1]
10
+ }) },
11
+ tag: { default: "div" }
12
+ },
13
+ emits: ["shown", "hidden", "intersected"],
14
+ setup(u, { emit: d }) {
15
+ const r = u, i = d, n = t(null), l = t(null), o = t(!1), s = t(!0), a = t(0);
16
+ m(() => {
17
+ n.value = new IntersectionObserver((e) => {
18
+ f(e[0]);
19
+ }, r.options), l.value && n.value.observe(l.value);
20
+ }), p(() => {
21
+ n.value && n.value.disconnect();
22
+ });
23
+ const f = c((e) => {
24
+ e.isIntersecting ? (a.value = Math.trunc(e.intersectionRatio * 100), e.intersectionRatio === 1 ? (o.value = !0, s.value = !1, i("shown")) : (o.value = !1, s.value = !1, v(Math.trunc(e.intersectionRatio * 100)))) : (o.value = !1, s.value = !0, i("hidden"));
25
+ }), v = c((e) => {
26
+ i("intersected", e);
27
+ }, r.debounceTime);
28
+ return (e, B) => (g(), b(w(e.tag), {
29
+ ref_key: "infinitescrolltrigger",
30
+ ref: l,
31
+ class: "bb-intersection"
32
+ }, {
33
+ default: _(() => [
34
+ I(e.$slots, "default", {
35
+ hidden: s.value,
36
+ percentage: a.value,
37
+ shown: o.value
38
+ })
39
+ ]),
40
+ _: 3
41
+ }, 512));
42
+ }
43
+ });
44
+ export {
45
+ M as default
46
+ };