bitboss-ui 2.0.51 → 2.0.53

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 (159) hide show
  1. package/dist/components/BaseCheckboxGroup/BaseCheckboxGroup.vue.d.ts +7 -0
  2. package/dist/components/BaseSelect/BaseSelect.vue.d.ts +6 -1
  3. package/dist/components/BaseSwitchGroup/BaseSwitchGroup.vue.d.ts +3 -0
  4. package/dist/components/BaseTag/BaseTag.vue.d.ts +4 -0
  5. package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.d.ts +7 -0
  6. package/dist/components/BbSelect/BbSelect.vue.d.ts +7 -0
  7. package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.d.ts +3 -0
  8. package/dist/components/BbTable/BbTable.vue.d.ts +1 -0
  9. package/dist/components/BbTable/types.d.ts +4 -0
  10. package/dist/components/BbTag/BbTag.vue.d.ts +4 -0
  11. package/dist/composables/useOptions.d.ts +1 -0
  12. package/dist/index100.js +12 -10
  13. package/dist/index106.js +3 -1
  14. package/dist/index108.js +1 -1
  15. package/dist/index110.js +66 -64
  16. package/dist/index112.js +3 -1
  17. package/dist/index118.js +1 -1
  18. package/dist/index120.js +5 -5
  19. package/dist/index122.js +1 -1
  20. package/dist/index126.js +1 -1
  21. package/dist/index127.js +1 -1
  22. package/dist/index128.js +1 -1
  23. package/dist/index13.js +1 -1
  24. package/dist/index130.js +1 -1
  25. package/dist/index132.js +2 -2
  26. package/dist/index15.js +4 -4
  27. package/dist/index17.js +3 -3
  28. package/dist/index19.js +6 -4
  29. package/dist/index204.js +116 -2
  30. package/dist/index205.js +2 -116
  31. package/dist/index206.js +51 -124
  32. package/dist/index208.js +13 -125
  33. package/dist/index209.js +20 -19
  34. package/dist/index21.js +14 -14
  35. package/dist/index210.js +4 -16
  36. package/dist/index211.js +8 -16
  37. package/dist/index212.js +162 -2
  38. package/dist/index213.js +84 -2
  39. package/dist/index215.js +3 -20
  40. package/dist/index216.js +2 -6
  41. package/dist/index217.js +4 -53
  42. package/dist/index218.js +4 -0
  43. package/dist/index219.js +3 -13
  44. package/dist/index220.js +41 -5
  45. package/dist/index221.js +6 -369
  46. package/dist/index222.js +7 -3
  47. package/dist/index223.js +281 -4
  48. package/dist/index224.js +16 -3
  49. package/dist/index225.js +16 -7
  50. package/dist/index226.js +19 -8
  51. package/dist/index227.js +19 -2
  52. package/dist/index228.js +27 -4
  53. package/dist/index229.js +3 -2
  54. package/dist/index23.js +15 -15
  55. package/dist/index230.js +2 -19
  56. package/dist/index231.js +247 -25
  57. package/dist/index232.js +52 -3
  58. package/dist/index233.js +36 -241
  59. package/dist/index234.js +5 -52
  60. package/dist/index235.js +35 -30
  61. package/dist/index236.js +126 -5
  62. package/dist/index237.js +125 -49
  63. package/dist/index238.js +2 -158
  64. package/dist/index239.js +5 -84
  65. package/dist/index240.js +371 -0
  66. package/dist/index243.js +1 -1
  67. package/dist/index245.js +1 -1
  68. package/dist/index247.js +10 -2
  69. package/dist/index248.js +2 -9
  70. package/dist/index249.js +2 -3
  71. package/dist/index25.js +5 -5
  72. package/dist/index250.js +1 -1
  73. package/dist/index252.js +7 -23
  74. package/dist/index253.js +176 -6
  75. package/dist/index254.js +3 -16
  76. package/dist/index255.js +12 -281
  77. package/dist/index256.js +8 -5
  78. package/dist/index257.js +9 -2
  79. package/dist/index258.js +17 -2
  80. package/dist/index259.js +4 -2
  81. package/dist/index260.js +224 -2
  82. package/dist/index261.js +3 -2
  83. package/dist/index262.js +8 -125
  84. package/dist/index263.js +23 -431
  85. package/dist/index264.js +6 -176
  86. package/dist/index265.js +16 -3
  87. package/dist/index266.js +6 -0
  88. package/dist/index267.js +429 -5
  89. package/dist/index268.js +89 -22
  90. package/dist/index269.js +8 -0
  91. package/dist/index27.js +1 -1
  92. package/dist/index270.js +2 -224
  93. package/dist/index271.js +2 -200
  94. package/dist/index272.js +2 -436
  95. package/dist/index273.js +2 -127
  96. package/dist/index274.js +2 -89
  97. package/dist/index275.js +2 -4
  98. package/dist/index276.js +2 -9
  99. package/dist/index277.js +2 -2
  100. package/dist/index278.js +2 -2
  101. package/dist/index279.js +1 -1
  102. package/dist/index280.js +28 -2
  103. package/dist/index281.js +21 -1
  104. package/dist/index283.js +197 -25
  105. package/dist/index284.js +9 -22
  106. package/dist/index285.js +4 -0
  107. package/dist/index286.js +126 -3
  108. package/dist/index287.js +22 -12
  109. package/dist/index289.js +436 -9
  110. package/dist/index29.js +3 -3
  111. package/dist/index290.js +126 -16
  112. package/dist/index293.js +2 -2
  113. package/dist/index294.js +2 -66
  114. package/dist/index295.js +66 -2
  115. package/dist/index296.js +5 -33
  116. package/dist/index297.js +1 -1
  117. package/dist/index298.js +1 -1
  118. package/dist/index299.js +33 -79
  119. package/dist/index300.js +6 -0
  120. package/dist/index301.js +79 -4
  121. package/dist/index303.js +10 -58
  122. package/dist/index304.js +4 -4
  123. package/dist/index305.js +4 -5
  124. package/dist/index306.js +58 -6
  125. package/dist/index307.js +46 -6
  126. package/dist/index308.js +5 -17
  127. package/dist/index309.js +6 -46
  128. package/dist/index31.js +2 -2
  129. package/dist/index310.js +18 -10
  130. package/dist/index311.js +1 -1
  131. package/dist/index313.js +1 -1
  132. package/dist/index33.js +2 -2
  133. package/dist/index35.js +3 -3
  134. package/dist/index37.js +69 -67
  135. package/dist/index39.js +4 -4
  136. package/dist/index41.js +2 -2
  137. package/dist/index43.js +4 -2
  138. package/dist/index45.js +52 -45
  139. package/dist/index47.js +2 -2
  140. package/dist/index49.js +2 -2
  141. package/dist/index55.js +1 -1
  142. package/dist/index57.js +1 -1
  143. package/dist/index61.js +2 -2
  144. package/dist/index65.js +3 -1
  145. package/dist/index75.js +3 -3
  146. package/dist/index79.js +2 -2
  147. package/dist/index81.js +1 -1
  148. package/dist/index84.js +2 -2
  149. package/dist/index86.js +1 -1
  150. package/dist/index88.js +3 -3
  151. package/dist/index90.js +1 -1
  152. package/dist/style.css +1 -1
  153. package/package.json +2 -2
  154. package/dist/index207.js +0 -7
  155. package/dist/index214.js +0 -43
  156. package/dist/index251.js +0 -11
  157. package/dist/index282.js +0 -4
  158. package/dist/index288.js +0 -11
  159. package/dist/index302.js +0 -6
package/dist/index112.js CHANGED
@@ -21,6 +21,7 @@ const K = /* @__PURE__ */ v({
21
21
  label: {},
22
22
  labelPosition: {},
23
23
  loading: { type: Boolean },
24
+ max: {},
24
25
  modelValue: {},
25
26
  multiple: { type: Boolean, default: !0 },
26
27
  name: {},
@@ -79,6 +80,7 @@ const K = /* @__PURE__ */ v({
79
80
  divider: e.divider,
80
81
  "has-errors": b,
81
82
  loading: e.loading,
83
+ max: e.max,
82
84
  "model-value": e.modelValue,
83
85
  multiple: e.multiple,
84
86
  name: h,
@@ -106,7 +108,7 @@ const K = /* @__PURE__ */ v({
106
108
  r(e.$slots, "append-outer", n(i(o)))
107
109
  ]),
108
110
  _: 2
109
- }, 1040, ["id", "append:icon", "aria-describedby", "autocomplete", "autofocus", "comma", "disabled", "divider", "has-errors", "loading", "model-value", "multiple", "name", "placeholder", "prepend:icon", "readonly", "required"])
111
+ }, 1040, ["id", "append:icon", "aria-describedby", "autocomplete", "autofocus", "comma", "disabled", "divider", "has-errors", "loading", "max", "model-value", "multiple", "name", "placeholder", "prepend:icon", "readonly", "required"])
110
112
  ]),
111
113
  _: 3
112
114
  }, 8, ["id", "direction", "errors", "has-errors", "hide-label", "hint", "label", "label-position", "model-value", "name", "reverse", "show-hint"]));
package/dist/index118.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as s, openBlock as e, createBlock as o, Teleport as l, createElementVNode as c, normalizeClass as m, createVNode as i, TransitionGroup as p, withCtx as u, createElementBlock as f, Fragment as d, renderList as _, unref as r, mergeProps as b } from "vue";
2
2
  import { state as k, useToast as C } from "./index11.js";
3
- import B from "./index294.js";
3
+ import B from "./index295.js";
4
4
  const N = /* @__PURE__ */ s({
5
5
  __name: "BbToast",
6
6
  props: {
package/dist/index120.js CHANGED
@@ -1,12 +1,12 @@
1
1
  import { defineComponent as z, defineAsyncComponent as A, ref as a, watch as I, computed as R, openBlock as v, createElementBlock as S, mergeProps as U, createElementVNode as c, renderSlot as E, normalizeProps as W, guardReactiveProps as j, unref as u, createBlock as D, withCtx as L, createCommentVNode as M } from "vue";
2
- import { useFloating as q, arrow as G } from "./index206.js";
2
+ import { useFloating as q, arrow as G } from "./index236.js";
3
3
  import { useId as J } from "./index8.js";
4
4
  import { wait as P } from "./index131.js";
5
5
  import K from "./index13.js";
6
6
  /* empty css */
7
- import { throttle as b } from "./index224.js";
8
- import { waitFor as Q } from "./index216.js";
9
- import { autoUpdate as X, flip as Y, shift as Z, hide as x } from "./index221.js";
7
+ import { throttle as b } from "./index219.js";
8
+ import { waitFor as Q } from "./index221.js";
9
+ import { autoUpdate as X, flip as Y, shift as Z, hide as x } from "./index240.js";
10
10
  const ue = /* @__PURE__ */ z({
11
11
  __name: "BbTooltip",
12
12
  props: {
@@ -24,7 +24,7 @@ const ue = /* @__PURE__ */ z({
24
24
  },
25
25
  setup(F) {
26
26
  const O = A(
27
- () => import("./index250.js")
27
+ () => import("./index261.js")
28
28
  ), t = F, w = `bb_${t.id ?? J().id.value}`, s = a(), d = a(), _ = a(), { placement: g, middlewareData: $ } = q(s, d, {
29
29
  placement: t.placement,
30
30
  whileElementsMounted: X,
package/dist/index122.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as $, computed as g, resolveComponent as y, openBlock as f, createElementBlock as i, Fragment as k, renderList as h, normalizeClass as b, createElementVNode as s, renderSlot as t, createVNode as v, createSlots as B, withCtx as _, mergeProps as C } from "vue";
2
- import { flattenTree as T } from "./index305.js";
2
+ import { flattenTree as T } from "./index296.js";
3
3
  const w = { class: "bb-tree-row" }, E = { class: "bb-tree-main-content" }, N = /* @__PURE__ */ $({
4
4
  __name: "BbTree",
5
5
  props: {
package/dist/index126.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as m, getCurrentInstance as d, inject as x, computed as l, ref as y, watchEffect as z, openBlock as _, createElementBlock as b, mergeProps as h } from "vue";
2
- import { isCssColor as w } from "./index227.js";
2
+ import { isCssColor as w } from "./index216.js";
3
3
  const g = ["innerHTML"], $ = /* @__PURE__ */ m({
4
4
  __name: "BbIcon",
5
5
  props: {
package/dist/index127.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as v, ref as r, onMounted as p, onBeforeUnmount as h, openBlock as i, createBlock as l, resolveDynamicComponent as u, normalizeStyle as m, withCtx as f, renderSlot as d } from "vue";
2
- import { throttle as g } from "./index224.js";
2
+ import { throttle as g } from "./index219.js";
3
3
  const O = /* @__PURE__ */ v({
4
4
  __name: "BbSmoothHeight",
5
5
  props: {
package/dist/index128.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as p, computed as s, openBlock as b, createElementBlock as a, normalizeProps as _, guardReactiveProps as x, createStaticVNode as m } from "vue";
2
- import { isCssColor as u } from "./index227.js";
2
+ import { isCssColor as u } from "./index216.js";
3
3
  const f = /* @__PURE__ */ p({
4
4
  __name: "BbSpinner",
5
5
  props: {
package/dist/index13.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as y, getCurrentInstance as p, computed as s, resolveComponent as d, openBlock as k, createBlock as h, resolveDynamicComponent as C, mergeProps as x, withCtx as S, renderSlot as L, createTextVNode as B, toDisplayString as N } from "vue";
2
2
  import { _config as o } from "./index4.js";
3
- import { useLogger as m } from "./index226.js";
3
+ import { useLogger as m } from "./index211.js";
4
4
  const P = /* @__PURE__ */ y({
5
5
  __name: "BaseButton",
6
6
  props: {
package/dist/index130.js CHANGED
@@ -1,4 +1,4 @@
1
- import { clamp as o } from "./index204.js";
1
+ import { clamp as o } from "./index205.js";
2
2
  const r = (t, e) => t * 100 / e, p = (t, e) => t / 100 * e, l = (t, e, n) => r(t - e, n - e), P = ({
3
3
  value: t = 0,
4
4
  originalBounds: e,
package/dist/index132.js CHANGED
@@ -1,5 +1,5 @@
1
- import { toValue as S, notNullish as $, noop as _, tryOnScopeDispose as R, useDebounceFn as q, useThrottleFn as G, tryOnMounted as Q, isClient as J, isObject as K } from "./index205.js";
2
- import { bypassFilter as fe, createFilterWrapper as ve, debounceFilter as de, getLifeCycleTarget as he, throttleFilter as me, throttledWatch as pe, throttledWatch as ge, watchWithFilter as be } from "./index205.js";
1
+ import { toValue as S, notNullish as $, noop as _, tryOnScopeDispose as R, useDebounceFn as q, useThrottleFn as G, tryOnMounted as Q, isClient as J, isObject as K } from "./index204.js";
2
+ import { bypassFilter as fe, createFilterWrapper as ve, debounceFilter as de, getLifeCycleTarget as he, throttleFilter as me, throttledWatch as pe, throttledWatch as ge, watchWithFilter as be } from "./index204.js";
3
3
  import { computed as T, ref as O, watch as V, reactive as k, watchEffect as U, getCurrentInstance as Z, onMounted as ee } from "vue";
4
4
  function N(l) {
5
5
  var o;
package/dist/index15.js CHANGED
@@ -1,9 +1,9 @@
1
1
  import { defineComponent as k, ref as y, computed as v, watchPostEffect as h, openBlock as g, createElementBlock as C, Fragment as w, createVNode as d, normalizeClass as V, withCtx as n, renderSlot as l, createElementVNode as s, normalizeStyle as H, withModifiers as B, withDirectives as E, mergeProps as q, unref as $ } from "vue";
2
- import z from "./index217.js";
2
+ import z from "./index206.js";
3
3
  /* empty css */
4
- import I from "./index219.js";
5
- import { vMaska as M } from "./index215.js";
6
- import { isHex as D } from "./index223.js";
4
+ import I from "./index208.js";
5
+ import { vMaska as M } from "./index209.js";
6
+ import { isHex as D } from "./index210.js";
7
7
  const F = ["id", "aria-describedby", "aria-invalid", "autocomplete", "autofocus", "disabled", "name", "placeholder", "readonly", "required", "value"], P = ["aria-invalid", "disabled", "required"], T = /* @__PURE__ */ k({
8
8
  __name: "BaseColorInput",
9
9
  props: {
package/dist/index17.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as E, ref as m, computed as n, watch as _, openBlock as p, createElementBlock as h, normalizeProps as i, guardReactiveProps as f, mergeProps as k, createCommentVNode as I, createElementVNode as s, renderSlot as q } from "vue";
2
- import { isCssColor as y } from "./index227.js";
3
- import { when as F } from "./index228.js";
4
- import { booleanishToBoolean as N } from "./index229.js";
2
+ import { isCssColor as y } from "./index216.js";
3
+ import { when as F } from "./index217.js";
4
+ import { booleanishToBoolean as N } from "./index218.js";
5
5
  const S = {
6
6
  "aria-hidden": "true",
7
7
  class: "bb-base-checkbox-container"
package/dist/index19.js CHANGED
@@ -1,10 +1,10 @@
1
1
  import { defineComponent as $, ref as p, toRef as l, openBlock as B, createBlock as w, unref as f, withCtx as i, renderSlot as s, normalizeProps as b, guardReactiveProps as h, createVNode as O, mergeProps as v } from "vue";
2
- import { useOptions as z } from "./index238.js";
2
+ import { useOptions as z } from "./index212.js";
3
3
  import F from "./index17.js";
4
4
  /* empty css */
5
- import M from "./index239.js";
5
+ import M from "./index213.js";
6
6
  /* empty css */
7
- const G = /* @__PURE__ */ $({
7
+ const A = /* @__PURE__ */ $({
8
8
  __name: "BaseCheckboxGroup",
9
9
  props: {
10
10
  ariaDescribedby: {},
@@ -22,6 +22,7 @@ const G = /* @__PURE__ */ $({
22
22
  itemText: {},
23
23
  itemValue: {},
24
24
  loadingText: { default: "Caricamento..." },
25
+ max: {},
25
26
  modelValue: {},
26
27
  modelValueDebounceTime: { default: 0 },
27
28
  name: {},
@@ -44,6 +45,7 @@ const G = /* @__PURE__ */ $({
44
45
  items: l(a, "items"),
45
46
  itemText: a.itemText,
46
47
  itemValue: a.itemValue,
48
+ max: a.max,
47
49
  modelValue: l(a, "modelValue"),
48
50
  modelValueDebounceTime: a.modelValueDebounceTime,
49
51
  multiple: !0,
@@ -127,5 +129,5 @@ const G = /* @__PURE__ */ $({
127
129
  }
128
130
  });
129
131
  export {
130
- G as default
132
+ A as default
131
133
  };
package/dist/index204.js CHANGED
@@ -1,4 +1,118 @@
1
- const n = (t, a, m) => Math.min(Math.max(t, a), m);
1
+ import { getCurrentScope as F, onScopeDispose as O, unref as D, isRef as x, watch as S, onMounted as C, nextTick as W, getCurrentInstance as P } from "vue";
2
+ function V(t) {
3
+ return F() ? (O(t), !0) : !1;
4
+ }
5
+ function d(t) {
6
+ return typeof t == "function" ? t() : D(t);
7
+ }
8
+ const A = typeof window < "u" && typeof document < "u";
9
+ typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
10
+ const E = (t) => t != null, M = Object.prototype.toString, I = (t) => M.call(t) === "[object Object]", p = () => {
11
+ };
12
+ function h(t, r) {
13
+ function e(...n) {
14
+ return new Promise((o, i) => {
15
+ Promise.resolve(t(() => r.apply(this, n), { fn: r, thisArg: this, args: n })).then(o).catch(i);
16
+ });
17
+ }
18
+ return e;
19
+ }
20
+ const R = (t) => t();
21
+ function k(t, r = {}) {
22
+ let e, n, o = p;
23
+ const i = (l) => {
24
+ clearTimeout(l), o(), o = p;
25
+ };
26
+ return (l) => {
27
+ const c = d(t), u = d(r.maxWait);
28
+ return e && i(e), c <= 0 || u !== void 0 && u <= 0 ? (n && (i(n), n = null), Promise.resolve(l())) : new Promise((a, w) => {
29
+ o = r.rejectOnCancel ? w : a, u && !n && (n = setTimeout(() => {
30
+ e && i(e), n = null, a(l());
31
+ }, u)), e = setTimeout(() => {
32
+ n && i(n), n = null, a(l());
33
+ }, c);
34
+ });
35
+ };
36
+ }
37
+ function b(...t) {
38
+ let r = 0, e, n = !0, o = p, i, s, l, c, u;
39
+ !x(t[0]) && typeof t[0] == "object" ? { delay: s, trailing: l = !0, leading: c = !0, rejectOnCancel: u = !1 } = t[0] : [s, l = !0, c = !0, u = !1] = t;
40
+ const a = () => {
41
+ e && (clearTimeout(e), e = void 0, o(), o = p);
42
+ };
43
+ return (g) => {
44
+ const f = d(s), T = Date.now() - r, m = () => i = g();
45
+ return a(), f <= 0 ? (r = Date.now(), m()) : (T > f && (c || !n) ? (r = Date.now(), m()) : l && (i = new Promise((y, j) => {
46
+ o = u ? j : y, e = setTimeout(() => {
47
+ r = Date.now(), n = !0, y(m()), a();
48
+ }, Math.max(0, f - T));
49
+ })), !c && !e && (e = setTimeout(() => n = !0, f)), n = !1, i);
50
+ };
51
+ }
52
+ function v(t) {
53
+ return P();
54
+ }
55
+ function N(t, r = 200, e = {}) {
56
+ return h(
57
+ k(r, e),
58
+ t
59
+ );
60
+ }
61
+ function _(t, r = 200, e = !1, n = !0, o = !1) {
62
+ return h(
63
+ b(r, e, n, o),
64
+ t
65
+ );
66
+ }
67
+ function G(t, r, e = {}) {
68
+ const {
69
+ eventFilter: n = R,
70
+ ...o
71
+ } = e;
72
+ return S(
73
+ t,
74
+ h(
75
+ n,
76
+ r
77
+ ),
78
+ o
79
+ );
80
+ }
81
+ function q(t, r = !0, e) {
82
+ v() ? C(t, e) : r ? t() : W(t);
83
+ }
84
+ function z(t, r, e = {}) {
85
+ const {
86
+ throttle: n = 0,
87
+ trailing: o = !0,
88
+ leading: i = !0,
89
+ ...s
90
+ } = e;
91
+ return G(
92
+ t,
93
+ r,
94
+ {
95
+ ...s,
96
+ eventFilter: b(n, o, i)
97
+ }
98
+ );
99
+ }
2
100
  export {
3
- n as clamp
101
+ R as bypassFilter,
102
+ h as createFilterWrapper,
103
+ k as debounceFilter,
104
+ v as getLifeCycleTarget,
105
+ A as isClient,
106
+ I as isObject,
107
+ p as noop,
108
+ E as notNullish,
109
+ b as throttleFilter,
110
+ z as throttledWatch,
111
+ d as toValue,
112
+ q as tryOnMounted,
113
+ V as tryOnScopeDispose,
114
+ N as useDebounceFn,
115
+ _ as useThrottleFn,
116
+ z as watchThrottled,
117
+ G as watchWithFilter
4
118
  };
package/dist/index205.js CHANGED
@@ -1,118 +1,4 @@
1
- import { getCurrentScope as F, onScopeDispose as O, unref as D, isRef as x, watch as S, onMounted as C, nextTick as W, getCurrentInstance as P } from "vue";
2
- function V(t) {
3
- return F() ? (O(t), !0) : !1;
4
- }
5
- function d(t) {
6
- return typeof t == "function" ? t() : D(t);
7
- }
8
- const A = typeof window < "u" && typeof document < "u";
9
- typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
10
- const E = (t) => t != null, M = Object.prototype.toString, I = (t) => M.call(t) === "[object Object]", p = () => {
11
- };
12
- function h(t, r) {
13
- function e(...n) {
14
- return new Promise((o, i) => {
15
- Promise.resolve(t(() => r.apply(this, n), { fn: r, thisArg: this, args: n })).then(o).catch(i);
16
- });
17
- }
18
- return e;
19
- }
20
- const R = (t) => t();
21
- function k(t, r = {}) {
22
- let e, n, o = p;
23
- const i = (l) => {
24
- clearTimeout(l), o(), o = p;
25
- };
26
- return (l) => {
27
- const c = d(t), u = d(r.maxWait);
28
- return e && i(e), c <= 0 || u !== void 0 && u <= 0 ? (n && (i(n), n = null), Promise.resolve(l())) : new Promise((a, w) => {
29
- o = r.rejectOnCancel ? w : a, u && !n && (n = setTimeout(() => {
30
- e && i(e), n = null, a(l());
31
- }, u)), e = setTimeout(() => {
32
- n && i(n), n = null, a(l());
33
- }, c);
34
- });
35
- };
36
- }
37
- function b(...t) {
38
- let r = 0, e, n = !0, o = p, i, s, l, c, u;
39
- !x(t[0]) && typeof t[0] == "object" ? { delay: s, trailing: l = !0, leading: c = !0, rejectOnCancel: u = !1 } = t[0] : [s, l = !0, c = !0, u = !1] = t;
40
- const a = () => {
41
- e && (clearTimeout(e), e = void 0, o(), o = p);
42
- };
43
- return (g) => {
44
- const f = d(s), T = Date.now() - r, m = () => i = g();
45
- return a(), f <= 0 ? (r = Date.now(), m()) : (T > f && (c || !n) ? (r = Date.now(), m()) : l && (i = new Promise((y, j) => {
46
- o = u ? j : y, e = setTimeout(() => {
47
- r = Date.now(), n = !0, y(m()), a();
48
- }, Math.max(0, f - T));
49
- })), !c && !e && (e = setTimeout(() => n = !0, f)), n = !1, i);
50
- };
51
- }
52
- function v(t) {
53
- return P();
54
- }
55
- function N(t, r = 200, e = {}) {
56
- return h(
57
- k(r, e),
58
- t
59
- );
60
- }
61
- function _(t, r = 200, e = !1, n = !0, o = !1) {
62
- return h(
63
- b(r, e, n, o),
64
- t
65
- );
66
- }
67
- function G(t, r, e = {}) {
68
- const {
69
- eventFilter: n = R,
70
- ...o
71
- } = e;
72
- return S(
73
- t,
74
- h(
75
- n,
76
- r
77
- ),
78
- o
79
- );
80
- }
81
- function q(t, r = !0, e) {
82
- v() ? C(t, e) : r ? t() : W(t);
83
- }
84
- function z(t, r, e = {}) {
85
- const {
86
- throttle: n = 0,
87
- trailing: o = !0,
88
- leading: i = !0,
89
- ...s
90
- } = e;
91
- return G(
92
- t,
93
- r,
94
- {
95
- ...s,
96
- eventFilter: b(n, o, i)
97
- }
98
- );
99
- }
1
+ const n = (t, a, m) => Math.min(Math.max(t, a), m);
100
2
  export {
101
- R as bypassFilter,
102
- h as createFilterWrapper,
103
- k as debounceFilter,
104
- v as getLifeCycleTarget,
105
- A as isClient,
106
- I as isObject,
107
- p as noop,
108
- E as notNullish,
109
- b as throttleFilter,
110
- z as throttledWatch,
111
- d as toValue,
112
- q as tryOnMounted,
113
- V as tryOnScopeDispose,
114
- N as useDebounceFn,
115
- _ as useThrottleFn,
116
- z as watchThrottled,
117
- G as watchWithFilter
3
+ n as clamp
118
4
  };
package/dist/index206.js CHANGED
@@ -1,128 +1,55 @@
1
- import { arrow as j, computePosition as A } from "./index221.js";
2
- import { autoUpdate as W, flip as X, hide as Y, offset as Z, platform as ee, shift as ne } from "./index221.js";
3
- import { isNode as B, getNodeName as F } from "./index262.js";
4
- import { getOverflowAncestors as le } from "./index262.js";
5
- import { computed as a, ref as f, shallowRef as I, watch as h, getCurrentScope as U, onScopeDispose as k, shallowReadonly as r, unref as q } from "vue";
6
- function z(e) {
7
- return e != null && typeof e == "object" && "$el" in e;
8
- }
9
- function g(e) {
10
- if (z(e)) {
11
- const l = e.$el;
12
- return B(l) && F(l) === "#comment" ? null : l;
13
- }
14
- return e;
15
- }
16
- function o(e) {
17
- return typeof e == "function" ? e() : q(e);
18
- }
19
- function K(e) {
20
- return {
21
- name: "arrow",
22
- options: e,
23
- fn(l) {
24
- const t = g(o(e.element));
25
- return t == null ? {} : j({
26
- element: t,
27
- padding: e.padding
28
- }).fn(l);
29
- }
30
- };
31
- }
32
- function M(e) {
33
- return typeof window > "u" ? 1 : (e.ownerDocument.defaultView || window).devicePixelRatio || 1;
34
- }
35
- function C(e, l) {
36
- const t = M(e);
37
- return Math.round(l * t) / t;
38
- }
39
- function L(e, l, t) {
40
- t === void 0 && (t = {});
41
- const x = t.whileElementsMounted, V = a(() => {
42
- var n;
43
- return (n = o(t.open)) != null ? n : !0;
44
- }), D = a(() => o(t.middleware)), d = a(() => {
45
- var n;
46
- return (n = o(t.placement)) != null ? n : "bottom";
47
- }), v = a(() => {
48
- var n;
49
- return (n = o(t.strategy)) != null ? n : "absolute";
50
- }), S = a(() => {
51
- var n;
52
- return (n = o(t.transform)) != null ? n : !0;
53
- }), i = a(() => g(e.value)), u = a(() => g(l.value)), p = f(0), w = f(0), c = f(v.value), O = f(d.value), P = I({}), y = f(!1), _ = a(() => {
54
- const n = {
55
- position: c.value,
56
- left: "0",
57
- top: "0"
58
- };
59
- if (!u.value)
60
- return n;
61
- const R = C(u.value, p.value), b = C(u.value, w.value);
62
- return S.value ? {
63
- ...n,
64
- transform: "translate(" + R + "px, " + b + "px)",
65
- ...M(u.value) >= 1.5 && {
66
- willChange: "transform"
67
- }
68
- } : {
69
- position: c.value,
70
- left: R + "px",
71
- top: b + "px"
1
+ import { defineComponent as f, ref as d, openBlock as r, createElementBlock as _, renderSlot as e, createElementVNode as t, createBlock as s, unref as p, createCommentVNode as i, createVNode as c } from "vue";
2
+ /* empty css */
3
+ /* empty css */
4
+ import a from "./index126.js";
5
+ /* empty css */
6
+ import $ from "./index128.js";
7
+ /* empty css */
8
+ import b from "./index299.js";
9
+ const y = { class: "bb-common-input-inner-container__prefix" }, k = { class: "bb-common-input-inner-container__suffix" }, S = /* @__PURE__ */ f({
10
+ __name: "CommonInputInnerContainer",
11
+ props: {
12
+ "append:icon": {},
13
+ "prepend:icon": {},
14
+ preventFocus: { type: Boolean }
15
+ },
16
+ setup(m) {
17
+ const u = m, o = d(), l = () => {
18
+ var n;
19
+ !o.value || u.preventFocus || (n = o.value.querySelector("input")) == null || n.focus();
72
20
  };
73
- });
74
- let s;
75
- function m() {
76
- i.value == null || u.value == null || A(i.value, u.value, {
77
- middleware: D.value,
78
- placement: d.value,
79
- strategy: v.value
80
- }).then((n) => {
81
- p.value = n.x, w.value = n.y, c.value = n.strategy, O.value = n.placement, P.value = n.middlewareData, y.value = !0;
82
- });
83
- }
84
- function E() {
85
- typeof s == "function" && (s(), s = void 0);
86
- }
87
- function N() {
88
- if (E(), x === void 0) {
89
- m();
90
- return;
91
- }
92
- if (i.value != null && u.value != null) {
93
- s = x(i.value, u.value, m);
94
- return;
95
- }
96
- }
97
- function $() {
98
- V.value || (y.value = !1);
21
+ return (n, C) => (r(), _("span", {
22
+ ref_key: "container",
23
+ ref: o,
24
+ class: "bb-common-input-inner-container",
25
+ onClick: l
26
+ }, [
27
+ e(n.$slots, "prepend", {}, () => [
28
+ t("span", y, [
29
+ e(n.$slots, "prefix")
30
+ ])
31
+ ]),
32
+ n.$props["prepend:icon"] ? (r(), s(p(a), {
33
+ key: 0,
34
+ class: "bb-common-input-inner-container__prepend-icon",
35
+ type: n.$props["prepend:icon"]
36
+ }, null, 8, ["type"])) : i("", !0),
37
+ e(n.$slots, "default"),
38
+ n.$props["append:icon"] ? (r(), s(p(a), {
39
+ key: 1,
40
+ class: "bb-common-input-inner-container__append-icon",
41
+ type: n.$props["append:icon"]
42
+ }, null, 8, ["type"])) : i("", !0),
43
+ c(p($)),
44
+ c(b),
45
+ e(n.$slots, "append", {}, () => [
46
+ t("span", k, [
47
+ e(n.$slots, "suffix")
48
+ ])
49
+ ])
50
+ ], 512));
99
51
  }
100
- return h([D, d, v], m, {
101
- flush: "sync"
102
- }), h([i, u], N, {
103
- flush: "sync"
104
- }), h(V, $, {
105
- flush: "sync"
106
- }), U() && k(E), {
107
- x: r(p),
108
- y: r(w),
109
- strategy: r(c),
110
- placement: r(O),
111
- middlewareData: r(P),
112
- isPositioned: r(y),
113
- floatingStyles: _,
114
- update: m
115
- };
116
- }
52
+ });
117
53
  export {
118
- K as arrow,
119
- W as autoUpdate,
120
- A as computePosition,
121
- X as flip,
122
- le as getOverflowAncestors,
123
- Y as hide,
124
- Z as offset,
125
- ee as platform,
126
- ne as shift,
127
- L as useFloating
54
+ S as default
128
55
  };