@rocketui/vue 0.2.42 → 0.2.44

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.
@@ -7986,7 +7986,7 @@ const Z5 = async (H, V, C) => {
7986
7986
  x: b,
7987
7987
  y: F,
7988
7988
  data: R,
7989
- reset: P
7989
+ reset: y
7990
7990
  } = await B({
7991
7991
  x: n,
7992
7992
  y: r,
@@ -8007,12 +8007,12 @@ const Z5 = async (H, V, C) => {
8007
8007
  ...l[w],
8008
8008
  ...R
8009
8009
  }
8010
- }, P && u <= 50) {
8011
- u++, typeof P == "object" && (P.placement && (o = P.placement), P.rects && (t = P.rects === !0 ? await A.getElementRects({
8010
+ }, y && u <= 50) {
8011
+ u++, typeof y == "object" && (y.placement && (o = y.placement), y.rects && (t = y.rects === !0 ? await A.getElementRects({
8012
8012
  reference: H,
8013
8013
  floating: V,
8014
8014
  strategy: i
8015
- }) : P.rects), {
8015
+ }) : y.rects), {
8016
8016
  x: n,
8017
8017
  y: r
8018
8018
  } = K1(t, o, d)), k = -1;
@@ -8058,16 +8058,16 @@ async function v1(H, V) {
8058
8058
  } : {
8059
8059
  x: 1,
8060
8060
  y: 1
8061
- }, P = w1(L.convertOffsetParentRelativeRectToViewportRelativeRect ? await L.convertOffsetParentRelativeRectToViewportRelativeRect({
8061
+ }, y = w1(L.convertOffsetParentRelativeRectToViewportRelativeRect ? await L.convertOffsetParentRelativeRectToViewportRelativeRect({
8062
8062
  rect: b,
8063
8063
  offsetParent: F,
8064
8064
  strategy: d
8065
8065
  }) : b);
8066
8066
  return {
8067
- top: (B.top - P.top + u.top) / R.y,
8068
- bottom: (P.bottom - B.bottom + u.bottom) / R.y,
8069
- left: (B.left - P.left + u.left) / R.x,
8070
- right: (P.right - B.right + u.right) / R.x
8067
+ top: (B.top - y.top + u.top) / R.y,
8068
+ bottom: (y.bottom - B.bottom + u.bottom) / R.y,
8069
+ left: (B.left - y.left + u.left) / R.x,
8070
+ right: (y.right - B.right + u.right) / R.x
8071
8071
  };
8072
8072
  }
8073
8073
  const u5 = (H) => ({
@@ -8091,10 +8091,10 @@ const u5 = (H) => ({
8091
8091
  const r = e2(n), o = {
8092
8092
  x: C,
8093
8093
  y: M
8094
- }, l = I1(i), u = N1(l), k = await A.getDimensions(t), w = l === "y", B = w ? "top" : "left", b = w ? "bottom" : "right", F = w ? "clientHeight" : "clientWidth", R = L.reference[u] + L.reference[l] - o[l] - L.floating[u], P = o[l] - L.reference[l], U = await (A.getOffsetParent == null ? void 0 : A.getOffsetParent(t));
8094
+ }, l = I1(i), u = N1(l), k = await A.getDimensions(t), w = l === "y", B = w ? "top" : "left", b = w ? "bottom" : "right", F = w ? "clientHeight" : "clientWidth", R = L.reference[u] + L.reference[l] - o[l] - L.floating[u], y = o[l] - L.reference[l], U = await (A.getOffsetParent == null ? void 0 : A.getOffsetParent(t));
8095
8095
  let W = U ? U[F] : 0;
8096
8096
  (!W || !await (A.isElement == null ? void 0 : A.isElement(U))) && (W = e.floating[F] || L.floating[u]);
8097
- const h = R / 2 - P / 2, I = W / 2 - k[u] / 2 - 1, M1 = a1(r[B], I), a = a1(r[b], I), s = M1, y = W - k[u] - a, T = W / 2 - k[u] / 2 + h, c = D1(s, T, y), _ = !d.arrow && s1(i) != null && T != c && L.reference[u] / 2 - (T < s ? M1 : a) - k[u] / 2 < 0, $ = _ ? T < s ? T - s : T - y : 0;
8097
+ const h = R / 2 - y / 2, I = W / 2 - k[u] / 2 - 1, M1 = a1(r[B], I), a = a1(r[b], I), s = M1, P = W - k[u] - a, T = W / 2 - k[u] / 2 + h, c = D1(s, T, P), _ = !d.arrow && s1(i) != null && T != c && L.reference[u] / 2 - (T < s ? M1 : a) - k[u] / 2 < 0, $ = _ ? T < s ? T - s : T - P : 0;
8098
8098
  return {
8099
8099
  [l]: o[l] + $,
8100
8100
  data: {
@@ -8133,7 +8133,7 @@ const u5 = (H) => ({
8133
8133
  return {};
8134
8134
  const B = i1(i), b = i1(e) === e, F = await (d.isRTL == null ? void 0 : d.isRTL(t.floating)), R = o || (b || !k ? [b1(e)] : o5(e));
8135
8135
  !o && u !== "none" && R.push(...r5(e, k, u, F));
8136
- const P = [e, ...R], U = await v1(V, w), W = [];
8136
+ const y = [e, ...R], U = await v1(V, w), W = [];
8137
8137
  let h = ((M = L.flip) == null ? void 0 : M.overflows) || [];
8138
8138
  if (n && W.push(U[B]), r) {
8139
8139
  const s = l5(i, A, F);
@@ -8144,15 +8144,15 @@ const u5 = (H) => ({
8144
8144
  overflows: W
8145
8145
  }], !W.every((s) => s <= 0)) {
8146
8146
  var I, M1;
8147
- const s = (((I = L.flip) == null ? void 0 : I.index) || 0) + 1, y = P[s];
8148
- if (y)
8147
+ const s = (((I = L.flip) == null ? void 0 : I.index) || 0) + 1, P = y[s];
8148
+ if (P)
8149
8149
  return {
8150
8150
  data: {
8151
8151
  index: s,
8152
8152
  overflows: h
8153
8153
  },
8154
8154
  reset: {
8155
- placement: y
8155
+ placement: P
8156
8156
  }
8157
8157
  };
8158
8158
  let T = (M1 = h.filter((c) => c.overflows[0] <= 0).sort((c, _) => c.overflows[1] - _.overflows[1])[0]) == null ? void 0 : M1.placement;
@@ -8770,8 +8770,8 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
8770
8770
  C.triggers.includes(Y.Hover) && k();
8771
8771
  }
8772
8772
  function k(B) {
8773
- const { placement: b, offset: F, padding: R, disabled: P, showDelay: U, type: W } = C;
8774
- P || W5(i, L, A, b, F, R, U, W);
8773
+ const { placement: b, offset: F, padding: R, disabled: y, showDelay: U, type: W } = C;
8774
+ y || W5(i, L, A, b, F, R, U, W);
8775
8775
  }
8776
8776
  const w = g(() => ({
8777
8777
  "r-tooltip": !0,
@@ -8941,7 +8941,7 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
8941
8941
  const s = document.getElementById(a);
8942
8942
  s == null || s.classList.remove("r-dropdown--active"), A.value = !1;
8943
8943
  }
8944
- function w(a, s, y, T) {
8944
+ function w(a, s, P, T) {
8945
8945
  var c;
8946
8946
  if (T(), !s.disabled) {
8947
8947
  if (s.value === "select-all") {
@@ -8952,7 +8952,7 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
8952
8952
  L.value.find((_) => _.value === s.value) ? L.value.splice(L.value.indexOf(s), 1) : L.value.push(s), e.value = "", C.searchable && ((c = o.value) == null || c.focus());
8953
8953
  return;
8954
8954
  }
8955
- B(a, s), C.closeOnSelect && y();
8955
+ B(a, s), C.closeOnSelect && P();
8956
8956
  }
8957
8957
  }
8958
8958
  function B(a, s) {
@@ -8962,10 +8962,10 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
8962
8962
  }
8963
8963
  e.value = s.label, i.value = s, M("update:modelValue", s);
8964
8964
  }
8965
- function b(a, s, y) {
8965
+ function b(a, s, P) {
8966
8966
  if (a instanceof KeyboardEvent && a.key !== "Backspace" || e.value !== "")
8967
8967
  return;
8968
- a.stopPropagation(), y();
8968
+ a.stopPropagation(), P();
8969
8969
  const T = L.value.findIndex((c) => c.value === s.value);
8970
8970
  L.value.splice(T, 1);
8971
8971
  }
@@ -8974,16 +8974,16 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
8974
8974
  if (!C.multiple)
8975
8975
  return;
8976
8976
  a.stopPropagation(), s();
8977
- const y = e.value;
8978
- if (y === "")
8977
+ const P = e.value;
8978
+ if (P === "")
8979
8979
  return;
8980
- t.value.find((_) => _.label === y) || (L.value.push({ value: y, label: y }), e.value = "", (c = o.value) == null || c.focus());
8980
+ t.value.find((_) => _.label === P) || (L.value.push({ value: P, label: P }), e.value = "", (c = o.value) == null || c.focus());
8981
8981
  }
8982
8982
  function R(a) {
8983
8983
  var s;
8984
- return !a || (a == null ? void 0 : a.value) === void 0 || (a == null ? void 0 : a.value) === null ? !1 : C.multiple ? L.value.find((y) => (y == null ? void 0 : y.value) === (a == null ? void 0 : a.value)) : ((s = i.value) == null ? void 0 : s.value) === (a == null ? void 0 : a.value);
8984
+ return !a || (a == null ? void 0 : a.value) === void 0 || (a == null ? void 0 : a.value) === null ? !1 : C.multiple ? L.value.find((P) => (P == null ? void 0 : P.value) === (a == null ? void 0 : a.value)) : ((s = i.value) == null ? void 0 : s.value) === (a == null ? void 0 : a.value);
8985
8985
  }
8986
- const P = g(() => !C.searchable || i.value.label === e.value ? t.value : t.value.filter((s) => s.label.toLowerCase().includes(e.value.toLowerCase()))), U = g(() => !C.searchable);
8986
+ const y = g(() => !C.searchable || i.value.label === e.value ? t.value : t.value.filter((s) => s.label.toLowerCase().includes(e.value.toLowerCase()))), U = g(() => !C.searchable);
8987
8987
  function W() {
8988
8988
  n.value ? C.multiple ? L.value = n.value : (i.value = n.value, e.value = n.value.label) : (i.value = {}, L.value.splice(0, L.value.length));
8989
8989
  }
@@ -8998,11 +8998,11 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
8998
8998
  i.value = {}, e.value = "", M("update:modelValue", "");
8999
8999
  }
9000
9000
  function M1() {
9001
- if (L.value.length === P.value.length) {
9001
+ if (L.value.length === y.value.length) {
9002
9002
  L.value.splice(0, L.value.length);
9003
9003
  return;
9004
9004
  }
9005
- L.value = P.value;
9005
+ L.value = y.value;
9006
9006
  }
9007
9007
  return H2(() => {
9008
9008
  W(), navigator.userAgent.includes("iPhone") && document.querySelector("[name=viewport]").setAttribute("content", "width=device-width, initial-scale=1, maximum-scale=1");
@@ -9030,11 +9030,11 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
9030
9030
  "trigger-class": "w-full",
9031
9031
  triggers: ["click"],
9032
9032
  type: "dropdown",
9033
- onHide: s[1] || (s[1] = (y) => {
9034
- k(y);
9033
+ onHide: s[1] || (s[1] = (P) => {
9034
+ k(P);
9035
9035
  })
9036
9036
  }, {
9037
- default: k1(({ updatePosition: y, tooltipId: T }) => [
9037
+ default: k1(({ updatePosition: P, tooltipId: T }) => [
9038
9038
  S("div", {
9039
9039
  id: T,
9040
9040
  ref_key: "dropdown",
@@ -9082,7 +9082,7 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
9082
9082
  label: c.label,
9083
9083
  "no-wrap": "",
9084
9084
  variant: "primary",
9085
- "onClick:close": ($) => b($, c, y)
9085
+ "onClick:close": ($) => b($, c, P)
9086
9086
  }, null, 8, ["clearable", "label", "onClick:close"])) : (m(), Z("p", z5, v(`${c.label}, `), 1))
9087
9087
  ])), 128)),
9088
9088
  V2(S("input", {
@@ -9099,10 +9099,10 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
9099
9099
  readonly: U.value,
9100
9100
  role: "presentation",
9101
9101
  type: "text",
9102
- onInput: A1((c) => h(y), ["prevent"]),
9102
+ onInput: A1((c) => h(P), ["prevent"]),
9103
9103
  onKeydown: [
9104
- $1((c) => b(c, L.value[L.value.length - 1], y), ["backspace"]),
9105
- $1((c) => F(c, y), ["enter"])
9104
+ $1((c) => b(c, L.value[L.value.length - 1], P), ["backspace"]),
9105
+ $1((c) => F(c, P), ["enter"])
9106
9106
  ]
9107
9107
  }, null, 42, K5), [
9108
9108
  [f2, e.value]
@@ -9112,7 +9112,7 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
9112
9112
  key: 1,
9113
9113
  class: "r-dropdown__clearable",
9114
9114
  "data-has-value": (e.value !== "" || L.value.length) && A.value,
9115
- onClick: (c) => I(c, y)
9115
+ onClick: (c) => I(c, P)
9116
9116
  }, [
9117
9117
  f(a.$slots, "clearable", {}, () => [
9118
9118
  q(D, {
@@ -9142,41 +9142,41 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
9142
9142
  ], 2)) : O("", !0)
9143
9143
  ], 10, $5)
9144
9144
  ]),
9145
- content: k1(({ hide: y, updatePosition: T }) => [
9145
+ content: k1(({ hide: P, updatePosition: T }) => [
9146
9146
  S("ul", {
9147
9147
  class: p(["r-dropdown-options", {
9148
9148
  "r-dropdown-options--active": A.value,
9149
9149
  [C.optionsClass]: C.optionsClass
9150
9150
  }])
9151
9151
  }, [
9152
- C.showSelectAll && C.multiple ? (m(), Z("li", {
9152
+ C.showSelectAll && C.multiple && y.value.length > 0 ? (m(), Z("li", {
9153
9153
  key: 0,
9154
9154
  class: p(["r-dropdown-options__option", {
9155
- "r-dropdown-options__option--active": L.value.length === P.value.length,
9155
+ "r-dropdown-options__option--active": L.value.length === y.value.length,
9156
9156
  "r-dropdown-options__option--disabled": !1
9157
9157
  }]),
9158
- onClick: A1((c) => w(c, { label: C.selectAllText, value: "select-all" }, y, T), ["prevent"])
9158
+ onClick: A1((c) => w(c, { label: C.selectAllText, value: "select-all" }, P, T), ["prevent"])
9159
9159
  }, [
9160
9160
  S("div", X5, [
9161
9161
  S("p", Y5, v(C.selectAllText), 1)
9162
9162
  ]),
9163
- L.value.length === P.value.length && !C.hideOptionCheckIcon ? (m(), E(D, {
9163
+ L.value.length === y.value.length && !C.hideOptionCheckIcon ? (m(), E(D, {
9164
9164
  key: 0,
9165
9165
  class: p(["r-dropdown-options__option__append-icon", {
9166
- "r-dropdown-options__option__append-icon--active": L.value.length === P.value.length
9166
+ "r-dropdown-options__option__append-icon--active": L.value.length === y.value.length
9167
9167
  }]),
9168
9168
  name: "mdiCheck"
9169
9169
  }, null, 8, ["class"])) : O("", !0)
9170
9170
  ], 10, j5)) : O("", !0),
9171
- C.showSelectAll ? (m(), Z("hr", J5)) : O("", !0),
9172
- (m(!0), Z(t1, null, r1(P.value, (c) => (m(), Z("li", {
9171
+ C.showSelectAll && y.value.length > 0 ? (m(), Z("hr", J5)) : O("", !0),
9172
+ (m(!0), Z(t1, null, r1(y.value, (c) => (m(), Z("li", {
9173
9173
  key: c.value,
9174
9174
  "aria-disabled": c.disabled,
9175
9175
  class: p(["r-dropdown-options__option", {
9176
9176
  "r-dropdown-options__option--active": R(c),
9177
9177
  "r-dropdown-options__option--disabled": c.disabled
9178
9178
  }]),
9179
- onClick: A1((_) => w(_, c, y, T), ["prevent"])
9179
+ onClick: A1((_) => w(_, c, P, T), ["prevent"])
9180
9180
  }, [
9181
9181
  f(a.$slots, "option", {
9182
9182
  disabled: c.disabled,
@@ -9215,9 +9215,9 @@ const N5 = ["aria-disabled"], I5 = ["innerHTML"], Q5 = ["id"], G5 = /* @__PURE__
9215
9215
  ])
9216
9216
  ])
9217
9217
  ], 10, C3))), 128)),
9218
- P.value.length === 0 ? (m(), Z("li", V3, [
9218
+ y.value.length === 0 ? (m(), Z("li", V3, [
9219
9219
  f(a.$slots, "not-options", {}, () => [
9220
- S1(v(C.multiple ? "No options hit to enter for create" : C.noOptionsText), 1)
9220
+ S1(v(C.noOptionsText), 1)
9221
9221
  ])
9222
9222
  ])) : O("", !0)
9223
9223
  ], 2)
@@ -9780,7 +9780,7 @@ const k3 = ["aria-disabled", "aria-selected", "disabled"], B3 = { key: 0 }, b3 =
9780
9780
  function R(h) {
9781
9781
  L.value = h.target.value, M("input", h);
9782
9782
  }
9783
- function P() {
9783
+ function y() {
9784
9784
  var h;
9785
9785
  if (o.value) {
9786
9786
  L.value = "", (h = i.value) == null || h.focus(), M("click:clear", {
@@ -9866,7 +9866,7 @@ const k3 = ["aria-disabled", "aria-selected", "disabled"], B3 = { key: 0 }, b3 =
9866
9866
  class: p(k.value),
9867
9867
  name: `${B.value}`,
9868
9868
  size: 20,
9869
- onClick: P
9869
+ onClick: y
9870
9870
  }, null, 8, ["class", "name"])) : O("", !0)
9871
9871
  ])
9872
9872
  ], 2),