yuyeon 0.3.0-rc.4 → 0.3.0-rc.5

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.
package/dist/yuyeon.js CHANGED
@@ -1,7 +1,7 @@
1
1
  var lr = Object.defineProperty;
2
2
  var or = (e, t, n) => t in e ? lr(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
3
  var he = (e, t, n) => or(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { getCurrentInstance as te, capitalize as ur, inject as ue, computed as C, shallowRef as re, watchEffect as Be, ref as E, provide as ce, h as se, watch as F, onScopeDispose as Ce, effectScope as Tt, toRaw as _a, toRef as oe, onBeforeUnmount as Ot, reactive as Te, onMounted as bn, nextTick as ye, resolveDynamicComponent as cr, createVNode as d, withDirectives as ze, mergeProps as z, resolveDirective as Et, unref as ve, readonly as tn, onBeforeMount as Da, Fragment as X, createTextVNode as Mt, withKeys as sr, Transition as It, toRefs as dr, withModifiers as pn, Teleport as fr, vShow as wn, watchPostEffect as vr, defineComponent as xn, resolveComponent as yr, onBeforeUpdate as mr, isVNode as Yt } from "vue";
4
+ import { getCurrentInstance as te, capitalize as ur, inject as ue, computed as C, shallowRef as re, watchEffect as Be, ref as E, provide as ce, h as se, watch as F, onScopeDispose as be, effectScope as Tt, toRaw as _a, toRef as oe, onBeforeUnmount as Ot, reactive as Te, onMounted as bn, nextTick as ye, resolveDynamicComponent as cr, createVNode as d, withDirectives as ze, mergeProps as z, resolveDirective as Et, unref as ve, readonly as tn, onBeforeMount as Da, Fragment as X, createTextVNode as Mt, withKeys as sr, Transition as It, toRefs as dr, withModifiers as pn, Teleport as fr, vShow as wn, watchPostEffect as vr, defineComponent as xn, resolveComponent as yr, onBeforeUpdate as mr, isVNode as Yt } from "vue";
5
5
  function Je(e, t) {
6
6
  return e ? Object.prototype.hasOwnProperty.call(e, t) : !1;
7
7
  }
@@ -16,12 +16,12 @@ function Aa(e, t, n) {
16
16
  }
17
17
  return i == null || i[t[a]] === void 0 ? n : i[t[a]];
18
18
  }
19
- function pe(e = {}, t = {}, n) {
19
+ function we(e = {}, t = {}, n) {
20
20
  const a = { ...e };
21
21
  for (const i in t) {
22
22
  const r = a[i], l = t[i];
23
23
  if (typeof r == "object" && typeof l == "object") {
24
- a[i] = pe(r, l);
24
+ a[i] = we(r, l);
25
25
  continue;
26
26
  }
27
27
  a[i] = l;
@@ -52,12 +52,12 @@ function Le(e, t = 0, n = 1) {
52
52
  function ke(e, t = 0) {
53
53
  return Array.from({ length: e }, (n, a) => t + a);
54
54
  }
55
- function xe(e, t) {
55
+ function Se(e, t) {
56
56
  if (e === t) return !0;
57
57
  if (e instanceof Date && t instanceof Date && e.getTime() !== t.getTime() || e !== Object(e) || t !== Object(t))
58
58
  return !1;
59
59
  const n = Object.keys(e);
60
- return n.length !== Object.keys(t).length ? !1 : n.every((a) => xe(e[a], t[a]));
60
+ return n.length !== Object.keys(t).length ? !1 : n.every((a) => Se(e[a], t[a]));
61
61
  }
62
62
  function hr(e) {
63
63
  const t = typeof e;
@@ -175,7 +175,7 @@ function Sr(e = {}, t, n = Oa()) {
175
175
  const u = gr(bt, a);
176
176
  ce(
177
177
  bt,
178
- C(() => r.value ? pe((u == null ? void 0 : u.value) ?? {}, r.value) : u == null ? void 0 : u.value)
178
+ C(() => r.value ? we((u == null ? void 0 : u.value) ?? {}, r.value) : u == null ? void 0 : u.value)
179
179
  );
180
180
  }
181
181
  return { props: l, provideSubDefaults: o };
@@ -258,7 +258,7 @@ function Sn(e, t) {
258
258
  i && !n ? a() : i || (n == null || n.stop(), n = void 0);
259
259
  },
260
260
  { immediate: !0 }
261
- ), Ce(() => {
261
+ ), be(() => {
262
262
  n == null || n.stop();
263
263
  });
264
264
  }
@@ -451,7 +451,7 @@ function Tr(e, t) {
451
451
  function Ea(e, t) {
452
452
  const n = [];
453
453
  return t.forEach((a) => {
454
- const i = e.find((l) => xe(a, l.value)), r = e[a];
454
+ const i = e.find((l) => Se(a, l.value)), r = e[a];
455
455
  (i == null ? void 0 : i.value) != null ? n.push(i.id) : r != null && n.push(r.id);
456
456
  }), n;
457
457
  }
@@ -983,14 +983,14 @@ function Hr(e) {
983
983
  return e ? {
984
984
  scheme: Zn.light,
985
985
  theme: ["light", "dark"],
986
- themes: { ...pe(Qn, e.themes) },
987
- palette: { ...pe(Jn, e.palette) },
986
+ themes: { ...we(Qn, e.themes) },
987
+ palette: { ...we(Jn, e.palette) },
988
988
  separation: e == null ? void 0 : e.separation
989
989
  } : {
990
990
  scheme: Zn.light,
991
991
  theme: ["light", "dark"],
992
- themes: { ...pe(Qn) },
993
- palette: { ...pe(Jn) }
992
+ themes: { ...we(Qn) },
993
+ palette: { ...we(Jn) }
994
994
  };
995
995
  }
996
996
  const pt = Symbol.for("yuyeon.theme"), qe = K(
@@ -2587,7 +2587,7 @@ class dl {
2587
2587
  }
2588
2588
  }
2589
2589
  function fl(e) {
2590
- return pe(
2590
+ return we(
2591
2591
  {
2592
2592
  adapter: dl,
2593
2593
  locale: rl
@@ -3431,7 +3431,7 @@ function Yl(e, t, n, a) {
3431
3431
  h && !Array.isArray(h) && h.nodeType === 1 && x.unobserve(h), g && !Array.isArray(g) && g.nodeType === 1 && x.observe(g), p && x.unobserve(p), b && x.observe(b);
3432
3432
  },
3433
3433
  { immediate: !0 }
3434
- ), Ce(() => {
3434
+ ), be(() => {
3435
3435
  x.disconnect();
3436
3436
  });
3437
3437
  function v(g) {
@@ -3636,7 +3636,7 @@ function Bl(e, t) {
3636
3636
  () => !!(t.active.value && e.coordinateStrategy),
3637
3637
  (l) => {
3638
3638
  var o, c;
3639
- if (F(() => e.coordinateStrategy, l), Ce(() => {
3639
+ if (F(() => e.coordinateStrategy, l), be(() => {
3640
3640
  n.value = void 0;
3641
3641
  }), typeof e.coordinateStrategy == "function")
3642
3642
  n.value = (o = e.coordinateStrategy(
@@ -3655,7 +3655,7 @@ function Bl(e, t) {
3655
3655
  )) == null ? void 0 : c.updateCoordinate;
3656
3656
  }
3657
3657
  }
3658
- ), window.addEventListener("resize", r, { passive: !0 }), Ce(() => {
3658
+ ), window.addEventListener("resize", r, { passive: !0 }), be(() => {
3659
3659
  window.removeEventListener("resize", r), n.value = void 0;
3660
3660
  });
3661
3661
  function r(l) {
@@ -3691,7 +3691,7 @@ function Vl(e) {
3691
3691
  }))
3692
3692
  };
3693
3693
  }
3694
- const sa = "y-layer-group", be = /* @__PURE__ */ new WeakMap();
3694
+ const sa = "y-layer-group", pe = /* @__PURE__ */ new WeakMap();
3695
3695
  function Ll(e) {
3696
3696
  const t = te();
3697
3697
  qu();
@@ -3715,12 +3715,12 @@ function Ll(e) {
3715
3715
  n,
3716
3716
  (r, l) => {
3717
3717
  var o, c;
3718
- l && be.has(l) && ((o = be.get(l)) == null || o.delete(t)), be.has(r) && be.get(r) || be.set(r, /* @__PURE__ */ new Set()), (c = be.get(r)) == null || c.add(t);
3718
+ l && pe.has(l) && ((o = pe.get(l)) == null || o.delete(t)), pe.has(r) && pe.get(r) || pe.set(r, /* @__PURE__ */ new Set()), (c = pe.get(r)) == null || c.add(t);
3719
3719
  },
3720
3720
  { immediate: !0 }
3721
3721
  );
3722
3722
  function a() {
3723
- const r = [], l = be.get(n.value);
3723
+ const r = [], l = pe.get(n.value);
3724
3724
  return l == null || l.forEach((o) => {
3725
3725
  var c;
3726
3726
  (c = o == null ? void 0 : o.ctx) != null && c.active && !(o != null && o.isUnmounted) && r.push(o);
@@ -3728,11 +3728,11 @@ function Ll(e) {
3728
3728
  }
3729
3729
  function i() {
3730
3730
  var r;
3731
- (r = be.get(n.value)) == null || r.delete(t);
3731
+ (r = pe.get(n.value)) == null || r.delete(t);
3732
3732
  }
3733
3733
  return Ot(() => {
3734
3734
  i();
3735
- }), { layerGroup: n, layerGroupState: be, getActiveLayers: a };
3735
+ }), { layerGroup: n, layerGroupState: pe, getActiveLayers: a };
3736
3736
  }
3737
3737
  function Rl() {
3738
3738
  return !0;
@@ -3886,7 +3886,7 @@ function Xl(e, t) {
3886
3886
  var a;
3887
3887
  typeof e.scrollStrategy == "function" ? e.scrollStrategy(t, e, n) : (a = ht[e.scrollStrategy]) == null || a.call(ht, t, e, n);
3888
3888
  }));
3889
- }), Ce(() => {
3889
+ }), be(() => {
3890
3890
  n == null || n.stop();
3891
3891
  });
3892
3892
  }
@@ -3924,7 +3924,7 @@ function Jl(e, t) {
3924
3924
  va,
3925
3925
  U(i) ?? null
3926
3926
  ), o.classList.add(qt);
3927
- }), Ce(() => {
3927
+ }), be(() => {
3928
3928
  a.forEach((o, c) => {
3929
3929
  const s = parseFloat(o.style.getPropertyValue(Gt)), u = parseFloat(o.style.getPropertyValue(Xt));
3930
3930
  o.style.removeProperty(Gt), o.style.removeProperty(Xt), o.style.removeProperty(va), o.classList.remove(fa), o.scrollLeft = -s, o.scrollTop = -u;
@@ -3950,7 +3950,7 @@ function Ql(e, t, n) {
3950
3950
  })) : l(o);
3951
3951
  });
3952
3952
  });
3953
- }), Ce(() => {
3953
+ }), be(() => {
3954
3954
  typeof cancelIdleCallback < "u" && cancelIdleCallback(r), cancelAnimationFrame(i);
3955
3955
  });
3956
3956
  }
@@ -3958,7 +3958,7 @@ function Ja(e, t) {
3958
3958
  const n = [document, ...xt(e)];
3959
3959
  n.forEach((a) => {
3960
3960
  a.addEventListener("scroll", t, { passive: !0 });
3961
- }), Ce(() => {
3961
+ }), be(() => {
3962
3962
  n.forEach((a) => {
3963
3963
  a.removeEventListener("scroll", t);
3964
3964
  });
@@ -4386,6 +4386,8 @@ const ei = K({
4386
4386
  f ? f.addEventListener("click", v) : g && g.removeEventListener("click", v);
4387
4387
  }), r.value && (m(), x(!0)), F(r, (f) => {
4388
4388
  f ? m() : y(), x(f);
4389
+ }), be(() => {
4390
+ y(), x(!1);
4389
4391
  }), H(() => d(X, null, [d(me, z({
4390
4392
  modelValue: r.value,
4391
4393
  "onUpdate:modelValue": (f) => r.value = f,
@@ -5310,7 +5312,7 @@ const hi = mi(!1), Uo = mi(!0), qo = /* @__PURE__ */ xn({
5310
5312
  }
5311
5313
  },
5312
5314
  "abstract.items"
5313
- ), Se = /* @__PURE__ */ V({
5315
+ ), Ce = /* @__PURE__ */ V({
5314
5316
  name: "YIconCheckbox",
5315
5317
  props: {
5316
5318
  checked: Boolean,
@@ -5370,7 +5372,7 @@ const hi = mi(!1), Uo = mi(!0), qo = /* @__PURE__ */ xn({
5370
5372
  prev: "m19.82 23.585-7.6399-7.5489 7.4693-7.622",
5371
5373
  last: "m10.488 23.812 7.4981-7.7457-7.3307-7.8207m0 0zm10.856-0.075007v15.659",
5372
5374
  first: "m21.512 23.812-7.4981-7.7457 7.3307-7.8207m0 0zm-10.856-0.075007v15.659"
5373
- }, we = /* @__PURE__ */ V({
5375
+ }, xe = /* @__PURE__ */ V({
5374
5376
  name: "YIconPageControl",
5375
5377
  props: {
5376
5378
  type: {
@@ -5436,16 +5438,16 @@ const hi = mi(!1), Uo = mi(!0), qo = /* @__PURE__ */ xn({
5436
5438
  expand: rt,
5437
5439
  dropdown: Go,
5438
5440
  clear: _n,
5439
- checkbox: Se,
5440
- pageControl: we,
5441
+ checkbox: Ce,
5442
+ pageControl: xe,
5441
5443
  next: {
5442
- component: we,
5444
+ component: xe,
5443
5445
  props: {
5444
5446
  type: "next"
5445
5447
  }
5446
5448
  },
5447
5449
  prev: {
5448
- component: we,
5450
+ component: xe,
5449
5451
  props: {
5450
5452
  type: "prev"
5451
5453
  }
@@ -5544,7 +5546,7 @@ const hi = mi(!1), Uo = mi(!0), qo = /* @__PURE__ */ xn({
5544
5546
  YButton: ee,
5545
5547
  YIconExpand: rt,
5546
5548
  YPlate: We,
5547
- YIconCheckbox: Se
5549
+ YIconCheckbox: Ce
5548
5550
  },
5549
5551
  props: {
5550
5552
  item: {
@@ -5639,7 +5641,7 @@ const hi = mi(!1), Uo = mi(!0), qo = /* @__PURE__ */ xn({
5639
5641
  }, null), e.enableSelect && d("div", {
5640
5642
  class: "y-tree-view-node__select",
5641
5643
  onClick: p
5642
- }, [d(Se, {
5644
+ }, [d(Ce, {
5643
5645
  checked: s.value
5644
5646
  }, null)]), d("div", {
5645
5647
  class: "y-tree-view-node__content"
@@ -5888,7 +5890,7 @@ const xa = Bn(), Jo = /* @__PURE__ */ xn({
5888
5890
  }
5889
5891
  function Y(T, M, N, I) {
5890
5892
  const j = e.returnItem ? T.map((J) => Z(J, e.itemKey)) : T, W = [...M.value];
5891
- xe(W, j) || (W.forEach((J) => N(J, !1)), j.forEach((J) => N(J, !0)), I());
5893
+ Se(W, j) || (W.forEach((J) => N(J, !1)), j.forEach((J) => N(J, !0)), I());
5892
5894
  }
5893
5895
  F(r, (T) => {
5894
5896
  Y(T, c, b, A);
@@ -5902,7 +5904,7 @@ const xa = Bn(), Jo = /* @__PURE__ */ xn({
5902
5904
  return;
5903
5905
  I.forEach((J) => delete i.value[J]);
5904
5906
  const j = [...s.value], W = [...u.value];
5905
- s.value.clear(), c.value.clear(), u.value.clear(), g(T), xe(j, [...s.value]) || R(), xe(W, [...u.value]) || P();
5907
+ s.value.clear(), c.value.clear(), u.value.clear(), g(T), Se(j, [...s.value]) || R(), Se(W, [...u.value]) || P();
5906
5908
  }, {
5907
5909
  deep: !0,
5908
5910
  flush: "sync"
@@ -6313,7 +6315,7 @@ const tu = K(
6313
6315
  },
6314
6316
  itemComparator: {
6315
6317
  type: [Function, String],
6316
- default: () => xe
6318
+ default: () => Se
6317
6319
  }
6318
6320
  },
6319
6321
  "YDataTable--selection"
@@ -6533,7 +6535,7 @@ const Ai = K({
6533
6535
  P.stopPropagation(), v.selectable && r(v);
6534
6536
  }
6535
6537
  }, {
6536
- default: () => [d(Se, {
6538
+ default: () => [d(Ce, {
6537
6539
  checked: i(v),
6538
6540
  disabled: !v.selectable
6539
6541
  }, null)]
@@ -6855,14 +6857,14 @@ const Oi = K({
6855
6857
  key: "first",
6856
6858
  class: "y-pagination__first"
6857
6859
  }, [t.first ? t.first(u.value.first) : d(ee, u.value.first, {
6858
- default: () => [t["first-icon"] ? t["first-icon"]() : d(we, {
6860
+ default: () => [t["first-icon"] ? t["first-icon"]() : d(xe, {
6859
6861
  type: "first"
6860
6862
  }, null)]
6861
6863
  })]), d("li", {
6862
6864
  key: "prev",
6863
6865
  class: "y-pagination__prev"
6864
6866
  }, [t.prev ? t.prev(u.value.prev) : d(ee, u.value.prev, {
6865
- default: () => [t["prev-icon"] ? t["prev-icon"]() : d(we, {
6867
+ default: () => [t["prev-icon"] ? t["prev-icon"]() : d(xe, {
6866
6868
  type: "prev"
6867
6869
  }, null)]
6868
6870
  })]), x.value.map((f, g) => d("li", {
@@ -6876,14 +6878,14 @@ const Oi = K({
6876
6878
  key: "next",
6877
6879
  class: "y-pagination__next"
6878
6880
  }, [t.next ? t.next(u.value.next) : d(ee, u.value.next, {
6879
- default: () => [t["next-icon"] ? t["next-icon"]() : d(we, {
6881
+ default: () => [t["next-icon"] ? t["next-icon"]() : d(xe, {
6880
6882
  type: "next"
6881
6883
  }, null)]
6882
6884
  })]), e.showEndButton && d("li", {
6883
6885
  key: "last",
6884
6886
  class: "y-pagination__last"
6885
6887
  }, [t.last ? t.last(u.value.last) : d(ee, u.value.last, {
6886
- default: () => [t["last-icon"] ? t["last-icon"]() : d(we, {
6888
+ default: () => [t["last-icon"] ? t["last-icon"]() : d(xe, {
6887
6889
  type: "last"
6888
6890
  }, null)]
6889
6891
  })])])])), {
@@ -6965,7 +6967,7 @@ const Yi = K({
6965
6967
  YButton: ee,
6966
6968
  YIconExpand: rt,
6967
6969
  YFieldInput: wt,
6968
- YIconPageControl: we
6970
+ YIconPageControl: xe
6969
6971
  },
6970
6972
  props: Yi(),
6971
6973
  setup(e, {
@@ -7122,7 +7124,7 @@ const $i = K({
7122
7124
  P.stopPropagation(), o(!l.value);
7123
7125
  }
7124
7126
  }, {
7125
- default: () => [d(Se, {
7127
+ default: () => [d(Ce, {
7126
7128
  checked: l.value,
7127
7129
  indeterminate: !l.value && r.value,
7128
7130
  disabled: s.value.length < 1
@@ -7233,7 +7235,7 @@ function Vi({ page: e, pageSize: t, sortBy: n, search: a }, i) {
7233
7235
  F(
7234
7236
  r,
7235
7237
  () => {
7236
- xe(l, r.value) || (i("update:options", r.value), l = r.value);
7238
+ Se(l, r.value) || (i("update:options", r.value), l = r.value);
7237
7239
  },
7238
7240
  { deep: !0, immediate: !0 }
7239
7241
  );
@@ -7715,7 +7717,7 @@ const Hn = {
7715
7717
  }), hn = /* @__PURE__ */ V({
7716
7718
  name: "YInputCheckbox",
7717
7719
  components: {
7718
- YIconCheckbox: Se
7720
+ YIconCheckbox: Ce
7719
7721
  },
7720
7722
  props: {
7721
7723
  id: String,
@@ -7755,7 +7757,7 @@ const Hn = {
7755
7757
  return this.id && (e = this.id), `input-${e}`;
7756
7758
  },
7757
7759
  iconComponent() {
7758
- return this.icon ? null : Se;
7760
+ return this.icon ? null : Ce;
7759
7761
  }
7760
7762
  },
7761
7763
  methods: {
@@ -7804,7 +7806,7 @@ const Hn = {
7804
7806
  readonly: o
7805
7807
  }, null), this.$slots.icon ? this.$slots.icon({
7806
7808
  checked: a
7807
- }) : c ? se(c) : d(Se, null, null)])]);
7809
+ }) : c ? se(c) : d(Ce, null, null)])]);
7808
7810
  }
7809
7811
  }), mu = /* @__PURE__ */ V({
7810
7812
  name: "YCheckbox",
@@ -7966,7 +7968,7 @@ const Hn = {
7966
7968
  }
7967
7969
  }), Ki = Symbol.for("yuyeon.icon");
7968
7970
  function hu(e) {
7969
- return pe({
7971
+ return we({
7970
7972
  defaultSet: "built",
7971
7973
  sets: {
7972
7974
  svg: {
@@ -7999,7 +8001,7 @@ function gu(e) {
7999
8001
  const s = ve(e);
8000
8002
  return s && typeof s == "object" && "iconProps" in s && (i = {
8001
8003
  component: "component" in i ? i.component : i,
8002
- props: "props" in i ? pe(i.props, (s == null ? void 0 : s.iconProps) ?? {}) : s.iconProps
8004
+ props: "props" in i ? we(i.props, (s == null ? void 0 : s.iconProps) ?? {}) : s.iconProps
8003
8005
  }), {
8004
8006
  component: en,
8005
8007
  icon: i
@@ -8219,7 +8221,7 @@ function Cu(e) {
8219
8221
  function n(i) {
8220
8222
  return i.filter(
8221
8223
  (r) => r !== null || t.value.some((l) => l.value === null)
8222
- ).map((r) => t.value.find((o) => xe(r, o.value)) ?? Ui(e, r));
8224
+ ).map((r) => t.value.find((o) => Se(r, o.value)) ?? Ui(e, r));
8223
8225
  }
8224
8226
  function a(i) {
8225
8227
  return e.returnItem ? i.map(({ raw: r }) => r) : i.map(({ value: r }) => r);
@@ -8239,7 +8241,7 @@ const qi = K({
8239
8241
  multiple: Boolean,
8240
8242
  itemComparator: {
8241
8243
  type: Function,
8242
- default: xe
8244
+ default: Se
8243
8245
  },
8244
8246
  defaultSelect: Boolean,
8245
8247
  menuProps: {
@@ -9443,7 +9445,7 @@ function Fu(e, t) {
9443
9445
  i && !n ? a() : i || (n == null || n.stop(), n = void 0);
9444
9446
  }, {
9445
9447
  immediate: !0
9446
- }), Ce(() => {
9448
+ }), be(() => {
9447
9449
  n == null || n.stop();
9448
9450
  });
9449
9451
  }
@@ -9587,10 +9589,10 @@ const rr = K({
9587
9589
  YForm: tl,
9588
9590
  YHover: Ku,
9589
9591
  YIcon: Me,
9590
- YIconCheckbox: Se,
9592
+ YIconCheckbox: Ce,
9591
9593
  YIconClear: _n,
9592
9594
  YIconExpand: rt,
9593
- YIconPageControl: we,
9595
+ YIconPageControl: xe,
9594
9596
  YIconSort: Pn,
9595
9597
  YInput: Ye,
9596
9598
  YInputCheckbox: hn,