@rocketui/vue 0.2.20 → 0.2.21

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.
@@ -7957,11 +7957,11 @@ const n5 = async (H, V, C) => {
7957
7957
  x: l,
7958
7958
  y: o
7959
7959
  } = G1(t, M, d), r = M, a = {}, u = 0;
7960
- for (let b = 0; b < e.length; b++) {
7960
+ for (let k = 0; k < e.length; k++) {
7961
7961
  const {
7962
- name: k,
7962
+ name: B,
7963
7963
  fn: y
7964
- } = e[b], {
7964
+ } = e[k], {
7965
7965
  x: P,
7966
7966
  y: v,
7967
7967
  data: R,
@@ -7982,8 +7982,8 @@ const n5 = async (H, V, C) => {
7982
7982
  });
7983
7983
  if (l = P ?? l, o = v ?? o, a = {
7984
7984
  ...a,
7985
- [k]: {
7986
- ...a[k],
7985
+ [B]: {
7986
+ ...a[B],
7987
7987
  ...R
7988
7988
  }
7989
7989
  }, F && u <= 50) {
@@ -7994,7 +7994,7 @@ const n5 = async (H, V, C) => {
7994
7994
  }) : F.rects), {
7995
7995
  x: l,
7996
7996
  y: o
7997
- } = G1(t, r, d)), b = -1;
7997
+ } = G1(t, r, d)), k = -1;
7998
7998
  continue;
7999
7999
  }
8000
8000
  }
@@ -8022,8 +8022,8 @@ async function k1(H, V) {
8022
8022
  elementContext: o = "floating",
8023
8023
  altBoundary: r = !1,
8024
8024
  padding: a = 0
8025
- } = t1(V, H), u = L2(a), k = e[r ? o === "floating" ? "reference" : "floating" : o], y = g1(await L.getClippingRect({
8026
- element: (C = await (L.isElement == null ? void 0 : L.isElement(k))) == null || C ? k : k.contextElement || await (L.getDocumentElement == null ? void 0 : L.getDocumentElement(e.floating)),
8025
+ } = t1(V, H), u = L2(a), B = e[r ? o === "floating" ? "reference" : "floating" : o], y = g1(await L.getClippingRect({
8026
+ element: (C = await (L.isElement == null ? void 0 : L.isElement(B))) == null || C ? B : B.contextElement || await (L.getDocumentElement == null ? void 0 : L.getDocumentElement(e.floating)),
8027
8027
  boundary: t,
8028
8028
  rootBoundary: l,
8029
8029
  strategy: d
@@ -8070,10 +8070,10 @@ const r5 = (H) => ({
8070
8070
  const o = L2(l), r = {
8071
8071
  x: C,
8072
8072
  y: M
8073
- }, a = _1(A), u = D1(a), b = await i.getDimensions(t), k = a === "y", y = k ? "top" : "left", P = k ? "bottom" : "right", v = k ? "clientHeight" : "clientWidth", R = L.reference[u] + L.reference[a] - r[a] - L.floating[u], F = r[a] - L.reference[a], z = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(t));
8073
+ }, a = _1(A), u = D1(a), k = await i.getDimensions(t), B = a === "y", y = B ? "top" : "left", P = B ? "bottom" : "right", v = B ? "clientHeight" : "clientWidth", R = L.reference[u] + L.reference[a] - r[a] - L.floating[u], F = r[a] - L.reference[a], z = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(t));
8074
8074
  let I = z ? z[v] : 0;
8075
8075
  (!I || !await (i.isElement == null ? void 0 : i.isElement(z))) && (I = e.floating[v] || L.floating[u]);
8076
- const O = R / 2 - F / 2, N = I / 2 - b[u] / 2 - 1, n = r1(o[y], N), h = r1(o[P], N), B = n, D = I - b[u] - h, s = I / 2 - b[u] / 2 + O, E = v1(B, s, D), $ = !d.arrow && u1(A) != null && s != E && L.reference[u] / 2 - (s < B ? n : h) - b[u] / 2 < 0, j = $ ? s < B ? s - B : s - D : 0;
8076
+ const O = R / 2 - F / 2, N = I / 2 - k[u] / 2 - 1, n = r1(o[y], N), h = r1(o[P], N), b = n, D = I - k[u] - h, s = I / 2 - k[u] / 2 + O, E = v1(b, s, D), $ = !d.arrow && u1(A) != null && s != E && L.reference[u] / 2 - (s < b ? n : h) - k[u] / 2 < 0, j = $ ? s < b ? s - b : s - D : 0;
8077
8077
  return {
8078
8078
  [a]: r[a] + j,
8079
8079
  data: {
@@ -8105,29 +8105,29 @@ const r5 = (H) => ({
8105
8105
  fallbackPlacements: r,
8106
8106
  fallbackStrategy: a = "bestFit",
8107
8107
  fallbackAxisSideDirection: u = "none",
8108
- flipAlignment: b = !0,
8109
- ...k
8108
+ flipAlignment: k = !0,
8109
+ ...B
8110
8110
  } = t1(H, V);
8111
8111
  if ((C = L.arrow) != null && C.alignmentOffset)
8112
8112
  return {};
8113
- const y = L1(A), P = L1(e) === e, v = await (d.isRTL == null ? void 0 : d.isRTL(t.floating)), R = r || (P || !b ? [h1(e)] : t5(e));
8114
- !r && u !== "none" && R.push(...l5(e, b, u, v));
8115
- const F = [e, ...R], z = await k1(V, k), I = [];
8113
+ const y = L1(A), P = L1(e) === e, v = await (d.isRTL == null ? void 0 : d.isRTL(t.floating)), R = r || (P || !k ? [h1(e)] : t5(e));
8114
+ !r && u !== "none" && R.push(...l5(e, k, u, v));
8115
+ const F = [e, ...R], z = await k1(V, B), I = [];
8116
8116
  let O = ((M = L.flip) == null ? void 0 : M.overflows) || [];
8117
8117
  if (l && I.push(z[y]), o) {
8118
- const B = d5(A, i, v);
8119
- I.push(z[B[0]], z[B[1]]);
8118
+ const b = d5(A, i, v);
8119
+ I.push(z[b[0]], z[b[1]]);
8120
8120
  }
8121
8121
  if (O = [...O, {
8122
8122
  placement: A,
8123
8123
  overflows: I
8124
- }], !I.every((B) => B <= 0)) {
8124
+ }], !I.every((b) => b <= 0)) {
8125
8125
  var N, n;
8126
- const B = (((N = L.flip) == null ? void 0 : N.index) || 0) + 1, D = F[B];
8126
+ const b = (((N = L.flip) == null ? void 0 : N.index) || 0) + 1, D = F[b];
8127
8127
  if (D)
8128
8128
  return {
8129
8129
  data: {
8130
- index: B,
8130
+ index: b,
8131
8131
  overflows: O
8132
8132
  },
8133
8133
  reset: {
@@ -8268,11 +8268,11 @@ const S5 = function(H) {
8268
8268
  mainAxis: L = !0,
8269
8269
  crossAxis: i = !1,
8270
8270
  limiter: e = {
8271
- fn: (k) => {
8271
+ fn: (B) => {
8272
8272
  let {
8273
8273
  x: y,
8274
8274
  y: P
8275
- } = k;
8275
+ } = B;
8276
8276
  return {
8277
8277
  x: y,
8278
8278
  y: P
@@ -8286,23 +8286,23 @@ const S5 = function(H) {
8286
8286
  }, l = await k1(V, d), o = B1(L1(A)), r = V2(o);
8287
8287
  let a = t[r], u = t[o];
8288
8288
  if (L) {
8289
- const k = r === "y" ? "top" : "left", y = r === "y" ? "bottom" : "right", P = a + l[k], v = a - l[y];
8289
+ const B = r === "y" ? "top" : "left", y = r === "y" ? "bottom" : "right", P = a + l[B], v = a - l[y];
8290
8290
  a = v1(P, a, v);
8291
8291
  }
8292
8292
  if (i) {
8293
- const k = o === "y" ? "top" : "left", y = o === "y" ? "bottom" : "right", P = u + l[k], v = u - l[y];
8293
+ const B = o === "y" ? "top" : "left", y = o === "y" ? "bottom" : "right", P = u + l[B], v = u - l[y];
8294
8294
  u = v1(P, u, v);
8295
8295
  }
8296
- const b = e.fn({
8296
+ const k = e.fn({
8297
8297
  ...V,
8298
8298
  [r]: a,
8299
8299
  [o]: u
8300
8300
  });
8301
8301
  return {
8302
- ...b,
8302
+ ...k,
8303
8303
  data: {
8304
- x: b.x - C,
8305
- y: b.y - M
8304
+ x: k.x - C,
8305
+ y: k.y - M
8306
8306
  }
8307
8307
  };
8308
8308
  }
@@ -8446,8 +8446,8 @@ function a1(H, V, C, M) {
8446
8446
  const r = Q(L), a = M && Y(M) ? Q(M) : M;
8447
8447
  let u = r.frameElement;
8448
8448
  for (; u && M && a !== r; ) {
8449
- const b = A1(u), k = u.getBoundingClientRect(), y = U(u), P = k.left + (u.clientLeft + parseFloat(y.paddingLeft)) * b.x, v = k.top + (u.clientTop + parseFloat(y.paddingTop)) * b.y;
8450
- d *= b.x, t *= b.y, l *= b.x, o *= b.y, d += P, t += v, u = Q(u).frameElement;
8449
+ const k = A1(u), B = u.getBoundingClientRect(), y = U(u), P = B.left + (u.clientLeft + parseFloat(y.paddingLeft)) * k.x, v = B.top + (u.clientTop + parseFloat(y.paddingTop)) * k.y;
8450
+ d *= k.x, t *= k.y, l *= k.x, o *= k.y, d += P, t += v, u = Q(u).frameElement;
8451
8451
  }
8452
8452
  }
8453
8453
  return g1({
@@ -8666,18 +8666,18 @@ async function D5({ value: H }, { value: V }, { value: C }, M, A, L, i = 300, e)
8666
8666
  Z5()
8667
8667
  ]
8668
8668
  }).then(({ x: d, y: t, placement: l, middlewareData: o }) => {
8669
- var a;
8669
+ var u, k;
8670
8670
  if (!V)
8671
8671
  return;
8672
- const r = ((a = H.offsetParent) == null ? void 0 : a.getBoundingClientRect().left) || 0;
8672
+ const r = ((u = H.offsetParent) == null ? void 0 : u.getBoundingClientRect().left) || 0, a = ((k = H.offsetParent) == null ? void 0 : k.getBoundingClientRect().bottom) || 0;
8673
8673
  if (Object.assign(V.style, {
8674
8674
  maxWidth: e === "dropdown" ? `${H.offsetWidth}px` : "auto",
8675
8675
  left: e === "dropdown" ? `${r}px` : `${d}px`,
8676
- top: `${t}px`,
8676
+ top: e === "dropdown" ? `${a}px` : `${t}px`,
8677
8677
  animation: `r-tooltip-show ${i}ms ease-in-out forwards`,
8678
8678
  transformOrigin: "start"
8679
8679
  }), C && o.arrow) {
8680
- const { x: u, y: b } = o.arrow, k = {
8680
+ const { x: B, y } = o.arrow, P = {
8681
8681
  top: "bottom",
8682
8682
  right: "left",
8683
8683
  bottom: "top",
@@ -8685,11 +8685,11 @@ async function D5({ value: H }, { value: V }, { value: C }, M, A, L, i = 300, e)
8685
8685
  /* Right */
8686
8686
  }[l.split("-")[0]];
8687
8687
  Object.assign(C.style, {
8688
- left: d != null ? `${u}px` : "",
8689
- top: t != null ? `${b}px` : "",
8688
+ left: d != null ? `${B}px` : "",
8689
+ top: t != null ? `${y}px` : "",
8690
8690
  right: "",
8691
8691
  bottom: "",
8692
- [`${k}`]: "-4px"
8692
+ [`${P}`]: "-4px"
8693
8693
  });
8694
8694
  }
8695
8695
  });
@@ -8743,10 +8743,10 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
8743
8743
  C.triggers.includes(X.Hover) && u();
8744
8744
  }
8745
8745
  function u() {
8746
- const { placement: k, offset: y, padding: P, disabled: v, showDelay: R, type: F } = C;
8747
- v || D5(A, L, i, k, y, P, R, F);
8746
+ const { placement: B, offset: y, padding: P, disabled: v, showDelay: R, type: F } = C;
8747
+ v || D5(A, L, i, B, y, P, R, F);
8748
8748
  }
8749
- const b = g(() => ({
8749
+ const k = g(() => ({
8750
8750
  "r-tooltip": !0,
8751
8751
  "r-tooltip--dark": C.dark && !C.light,
8752
8752
  "r-tooltip--light": C.light
@@ -8771,18 +8771,18 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
8771
8771
  ignore: [L.value]
8772
8772
  }
8773
8773
  );
8774
- }), (k, y) => (m(), Z(i1, null, [
8774
+ }), (B, y) => (m(), Z(i1, null, [
8775
8775
  S("div", {
8776
8776
  ref_key: "trigger",
8777
8777
  ref: A,
8778
8778
  "aria-disabled": C.disabled,
8779
- class: c(["r-tooltip-trigger", k.triggerClass]),
8779
+ class: c(["r-tooltip-trigger", B.triggerClass]),
8780
8780
  onClick: l,
8781
8781
  onMouseenter: o,
8782
8782
  onMouseleave: r,
8783
8783
  onMousemove: a
8784
8784
  }, [
8785
- f(k.$slots, "default", {
8785
+ f(B.$slots, "default", {
8786
8786
  activators: {
8787
8787
  click: l,
8788
8788
  mouseenter: o,
@@ -8801,10 +8801,10 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
8801
8801
  id: "tooltip",
8802
8802
  ref_key: "tooltip",
8803
8803
  ref: L,
8804
- class: c([b.value, k.tooltipClass]),
8804
+ class: c([k.value, B.tooltipClass]),
8805
8805
  role: "tooltip"
8806
8806
  }, [
8807
- f(k.$slots, "content", {
8807
+ f(B.$slots, "content", {
8808
8808
  hide: d,
8809
8809
  updatePosition: u
8810
8810
  }, () => [
@@ -8891,27 +8891,27 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
8891
8891
  };
8892
8892
  }), o = W(), r = W(), a = W();
8893
8893
  function u(n, h) {
8894
- var B, D, s;
8894
+ var b, D, s;
8895
8895
  if (n.stopPropagation(), !C.disabled) {
8896
8896
  if (i.value = !0, h && h(), i.value) {
8897
- (B = o.value) == null || B.classList.add("r-dropdown--active"), (D = o.value) == null || D.focus(), (s = r.value) == null || s.focus();
8897
+ (b = o.value) == null || b.classList.add("r-dropdown--active"), (D = o.value) == null || D.focus(), (s = r.value) == null || s.focus();
8898
8898
  return;
8899
8899
  }
8900
- b();
8900
+ k();
8901
8901
  }
8902
8902
  }
8903
- function b() {
8904
- var n, h, B;
8905
- i.value = !1, (n = o.value) == null || n.classList.remove("r-dropdown--active"), (h = o.value) == null || h.blur(), (B = r.value) == null || B.blur();
8903
+ function k() {
8904
+ var n, h, b;
8905
+ i.value = !1, (n = o.value) == null || n.classList.remove("r-dropdown--active"), (h = o.value) == null || h.blur(), (b = r.value) == null || b.blur();
8906
8906
  }
8907
- function k(n, h, B, D) {
8907
+ function B(n, h, b, D) {
8908
8908
  var s;
8909
8909
  if (n.stopPropagation(), D(), !h.disabled) {
8910
8910
  if (C.multiple) {
8911
8911
  L.value.find((E) => E.value === h.value) ? L.value.splice(L.value.indexOf(h), 1) : L.value.push(h), e.value = "", C.searchable && ((s = r.value) == null || s.focus());
8912
8912
  return;
8913
8913
  }
8914
- y(n, h), C.closeOnSelect && (B(), b());
8914
+ y(n, h), C.closeOnSelect && (b(), k());
8915
8915
  }
8916
8916
  }
8917
8917
  function y(n, h) {
@@ -8921,10 +8921,10 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
8921
8921
  }
8922
8922
  e.value = h.label, A.value = h, u(n), M("update:modelValue", h);
8923
8923
  }
8924
- function P(n, h, B) {
8924
+ function P(n, h, b) {
8925
8925
  if (n instanceof KeyboardEvent && n.key !== "Backspace" || e.value !== "")
8926
8926
  return;
8927
- n.stopPropagation(), B();
8927
+ n.stopPropagation(), b();
8928
8928
  const D = L.value.findIndex((s) => s.value === h.value);
8929
8929
  L.value.splice(D, 1);
8930
8930
  }
@@ -8933,14 +8933,14 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
8933
8933
  if (!C.multiple)
8934
8934
  return;
8935
8935
  n.stopPropagation(), h();
8936
- const B = e.value;
8937
- if (B === "")
8936
+ const b = e.value;
8937
+ if (b === "")
8938
8938
  return;
8939
- t.value.find((E) => E.label === B) || (L.value.push({ value: B, label: B }), e.value = "", (s = r.value) == null || s.focus());
8939
+ t.value.find((E) => E.label === b) || (L.value.push({ value: b, label: b }), e.value = "", (s = r.value) == null || s.focus());
8940
8940
  }
8941
8941
  function R(n) {
8942
8942
  var h;
8943
- return !n || (n == null ? void 0 : n.value) === void 0 || (n == null ? void 0 : n.value) === null ? !1 : C.multiple ? L.value.find((B) => (B == null ? void 0 : B.value) === (n == null ? void 0 : n.value)) : ((h = A.value) == null ? void 0 : h.value) === (n == null ? void 0 : n.value);
8943
+ return !n || (n == null ? void 0 : n.value) === void 0 || (n == null ? void 0 : n.value) === null ? !1 : C.multiple ? L.value.find((b) => (b == null ? void 0 : b.value) === (n == null ? void 0 : n.value)) : ((h = A.value) == null ? void 0 : h.value) === (n == null ? void 0 : n.value);
8944
8944
  }
8945
8945
  const F = g(() => !C.searchable || A.value.label === e.value ? t.value : t.value.filter((h) => h.label.toLowerCase().includes(e.value.toLowerCase()))), z = g(() => !C.searchable);
8946
8946
  function I() {
@@ -8977,9 +8977,9 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
8977
8977
  "trigger-class": "w-full",
8978
8978
  triggers: ["click"],
8979
8979
  type: "dropdown",
8980
- onHide: b
8980
+ onHide: k
8981
8981
  }, {
8982
- default: n1(({ activators: B, updatePosition: D }) => [
8982
+ default: n1(({ activators: b, updatePosition: D }) => [
8983
8983
  S("div", {
8984
8984
  ref_key: "dropdown",
8985
8985
  ref: o,
@@ -8991,7 +8991,7 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
8991
8991
  group: e.value !== "" || L.value.length
8992
8992
  }]),
8993
8993
  role: "select",
8994
- onClick: (s) => u(s, B.click)
8994
+ onClick: (s) => u(s, b.click)
8995
8995
  }, [
8996
8996
  C.prependIcon || n.$slots.prepend ? (m(), Z("div", {
8997
8997
  key: 0,
@@ -9073,7 +9073,7 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
9073
9073
  ], 2)) : p("", !0)
9074
9074
  ], 10, N5)
9075
9075
  ]),
9076
- content: n1(({ hide: B, updatePosition: D }) => [
9076
+ content: n1(({ hide: b, updatePosition: D }) => [
9077
9077
  S("ul", {
9078
9078
  class: c(["r-dropdown-options", {
9079
9079
  "r-dropdown-options--active": i.value,
@@ -9087,7 +9087,7 @@ const _5 = ["aria-disabled"], E5 = ["innerHTML"], W5 = /* @__PURE__ */ T({
9087
9087
  "r-dropdown-options__option--active": R(s),
9088
9088
  "r-dropdown-options__option--disabled": s.disabled
9089
9089
  }]),
9090
- onClick: e1((E) => k(E, s, B, D), ["prevent"])
9090
+ onClick: e1((E) => B(E, s, b, D), ["prevent"])
9091
9091
  }, [
9092
9092
  f(n.$slots, "option", {
9093
9093
  isSelected: R(s)
@@ -9651,11 +9651,11 @@ const s3 = ["aria-disabled", "aria-selected", "disabled"], c3 = {
9651
9651
  "r-textfield__prepend-icon": !0,
9652
9652
  "r-textfield__prepend-icon--loading": C.loading,
9653
9653
  "r-textfield__prepend-icon--error": o.value && t.value
9654
- })), b = g(() => ({
9654
+ })), k = g(() => ({
9655
9655
  "r-textfield__append-icon": !0,
9656
9656
  "r-textfield__append-icon--clear": r.value,
9657
9657
  "r-textfield__append-icon--error": o.value
9658
- })), k = g(() => {
9658
+ })), B = g(() => {
9659
9659
  const { prependIcon: O, type: N } = C;
9660
9660
  return O === "none" ? "" : O || e[N];
9661
9661
  }), y = g(() => {
@@ -9720,10 +9720,10 @@ const s3 = ["aria-disabled", "aria-selected", "disabled"], c3 = {
9720
9720
  class: c(a.value)
9721
9721
  }, [
9722
9722
  f(O.$slots, "prepend"),
9723
- k.value && !O.$slots.prepend ? (m(), _(x, {
9723
+ B.value && !O.$slots.prepend ? (m(), _(x, {
9724
9724
  key: 0,
9725
9725
  class: c(u.value),
9726
- name: k.value,
9726
+ name: B.value,
9727
9727
  size: 20
9728
9728
  }, null, 8, ["class", "name"])) : p("", !0),
9729
9729
  S("input", {
@@ -9745,7 +9745,7 @@ const s3 = ["aria-disabled", "aria-selected", "disabled"], c3 = {
9745
9745
  o.value ? p("", !0) : f(O.$slots, "append", { key: 1 }),
9746
9746
  y.value && !O.$slots.append || o.value ? (m(), _(x, {
9747
9747
  key: 2,
9748
- class: c(b.value),
9748
+ class: c(k.value),
9749
9749
  name: `${y.value}`,
9750
9750
  size: 20,
9751
9751
  onClick: F