@czxingyu/xycomponents 0.1.1 → 0.1.3

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/index.esm.js CHANGED
@@ -12,7 +12,7 @@ var qe = Object.create, Je = Object.defineProperty, Ye = Object.getOwnPropertyDe
12
12
  }, tt = (e, t, n) => (n = e == null ? {} : qe(Ze(e)), et(t || !e || !e.__esModule ? Je(n, "default", {
13
13
  value: e,
14
14
  enumerable: !0
15
- }) : n, e)), nt = "0.1.1";
15
+ }) : n, e)), nt = "0.1.3";
16
16
  //#endregion
17
17
  //#region components/shared/install.ts
18
18
  function X(e) {
@@ -6300,13 +6300,10 @@ var Wr = [
6300
6300
  t.className,
6301
6301
  v.value.item
6302
6302
  ]]),
6303
- style: T([
6304
- t.style,
6305
- e.direction === "vertical" ? { paddingInlineStart: `${r * 16}px` } : void 0,
6306
- y.value.item
6307
- ])
6303
+ style: T([t.style, y.value.item])
6308
6304
  }, [d("a", {
6309
6305
  class: C(["xy-anchor__link", { "xy-anchor__link--disabled": t.disabled }]),
6306
+ style: T(e.direction === "vertical" && r > 0 ? { paddingInlineStart: `calc(var(--xy-anchor-link-padding-inline) + ${r * 16}px)` } : void 0),
6310
6307
  href: t.href,
6311
6308
  target: t.target,
6312
6309
  rel: t.target === "_blank" ? "noreferrer" : void 0,
@@ -6325,11 +6322,11 @@ var Wr = [
6325
6322
  depth: r,
6326
6323
  index: i,
6327
6324
  item: t
6328
- }, () => [p(V(D(t)), 1)])], 6)], 10, Xr)], 6))), 128))], 6)) : l("", !0),
6325
+ }, () => [p(V(D(t)), 1)])], 6)], 14, Xr)], 6))), 128))], 6)) : l("", !0),
6329
6326
  I(n.$slots, "default")
6330
6327
  ], 14, Yr));
6331
6328
  }
6332
- }), [["__scopeId", "data-v-93931713"]])), Qr = X($), $r = ["aria-busy", "role"], ei = ["aria-label"], ti = /*#__PURE__*/ Z(/* @__PURE__ */ g({
6329
+ }), [["__scopeId", "data-v-5b2bf520"]])), Qr = X($), $r = ["aria-busy", "role"], ei = ["aria-label"], ti = /*#__PURE__*/ Z(/* @__PURE__ */ g({
6333
6330
  name: "XyMessage",
6334
6331
  __name: "message",
6335
6332
  props: {
@@ -15211,7 +15208,7 @@ var fs = ["aria-label"], ps = ["aria-label", "disabled"], ms = ["aria-label", "d
15211
15208
  }
15212
15209
  },
15213
15210
  setup(e) {
15214
- let n = e, r = ne(), i = N(), { width: a } = dr(i), o = B([]), f = {
15211
+ let n = e, r = ne(), i = N(Object.keys(r)), a = N(), { width: o } = dr(a), f = B([]), p = {
15215
15212
  xs: 0,
15216
15213
  sm: 576,
15217
15214
  md: 768,
@@ -15219,28 +15216,28 @@ var fs = ["aria-label"], ps = ["aria-label", "disabled"], ms = ["aria-label", "d
15219
15216
  xl: 1200,
15220
15217
  xxl: 1600,
15221
15218
  xxxl: 1920
15222
- }, p = Object.keys(f);
15223
- function h(e) {
15219
+ }, h = Object.keys(p);
15220
+ function g(e) {
15224
15221
  let t = Number(e);
15225
15222
  return Number.isFinite(t) ? Math.max(1, Math.floor(t)) : 1;
15226
15223
  }
15227
- function g(e, t) {
15228
- return e === "filled" ? t : Math.min(h(e), t);
15229
- }
15230
15224
  function _(e, t) {
15231
- if (typeof e == "number") return h(e);
15232
- let n = p.filter((t) => e[t] !== void 0);
15225
+ return e === "filled" ? t : Math.min(g(e), t);
15226
+ }
15227
+ function v(e, t) {
15228
+ if (typeof e == "number") return g(e);
15229
+ let n = h.filter((t) => e[t] !== void 0);
15233
15230
  if (n.length === 0) return 1;
15234
15231
  let r = e[n[0]];
15235
- for (let i of n) t >= f[i] && (r = e[i]);
15236
- return h(r);
15232
+ for (let i of n) t >= p[i] && (r = e[i]);
15233
+ return g(r);
15237
15234
  }
15238
- let v = s(() => n.bordered), y = s(() => n.colon), b = s(() => _(n.column, a.value)), x = s(() => n.layout), S = s(() => n.size), w = s(() => n.title !== void 0 || !!r.title), E = s(() => n.extra !== void 0 || !!r.extra), D = s(() => w.value || E.value), O = s(() => n.items !== void 0), k = s(() => {
15235
+ let y = s(() => n.bordered), b = s(() => n.colon), x = s(() => v(n.column, o.value)), S = s(() => n.layout), w = s(() => n.size), E = s(() => n.title !== void 0 || i.value.includes("title")), O = s(() => n.extra !== void 0 || i.value.includes("extra")), k = s(() => E.value || O.value), M = s(() => n.items !== void 0), P = s(() => {
15239
15236
  let e = /* @__PURE__ */ new Map(), t = 0, n = 0;
15240
- for (let r of o.value) {
15241
- let i = r.span.value, a = g(i, b.value);
15242
- i === "filled" ? a = Math.max(b.value - t, 1) : t + a > b.value && (t = 0, n += 1);
15243
- let o = t + a >= b.value;
15237
+ for (let r of f.value) {
15238
+ let i = r.span.value, a = _(i, x.value);
15239
+ i === "filled" ? a = Math.max(x.value - t, 1) : t + a > x.value && (t = 0, n += 1);
15240
+ let o = t + a >= x.value;
15244
15241
  e.set(r.id, {
15245
15242
  isLastColumn: o,
15246
15243
  isLastRow: !1,
@@ -15251,78 +15248,82 @@ var fs = ["aria-label"], ps = ["aria-label", "disabled"], ms = ["aria-label", "d
15251
15248
  let r = Math.max(...[...e.values()].map((e) => e.row), 0);
15252
15249
  for (let t of e.values()) t.isLastRow = t.row === r;
15253
15250
  return e;
15254
- }), M = s(() => ({ "--xy-descriptions-column": String(b.value) })), P = s(() => ({
15251
+ }), L = s(() => ({ "--xy-descriptions-column": String(x.value) })), R = s(() => ({
15255
15252
  bordered: n.bordered,
15256
15253
  colon: n.colon,
15257
- column: b.value,
15258
- hasExtra: E.value,
15259
- hasTitle: w.value,
15254
+ column: x.value,
15255
+ hasExtra: O.value,
15256
+ hasTitle: E.value,
15260
15257
  layout: n.layout,
15261
15258
  size: n.size
15262
- })), L = s(() => ut(n.classNames, P.value)), R = s(() => Q(n.styles, P.value)), z = s(() => [
15259
+ })), z = s(() => ut(n.classNames, R.value)), V = s(() => Q(n.styles, R.value)), H = s(() => [
15263
15260
  "xy-descriptions",
15264
15261
  `xy-descriptions--${n.layout}`,
15265
15262
  `xy-descriptions--${n.size}`,
15266
15263
  { "xy-descriptions--bordered": n.bordered },
15267
- L.value.root
15268
- ]), V = s(() => L.value.item), H = s(() => R.value.item), U = s(() => L.value.label), W = s(() => ({
15264
+ z.value.root
15265
+ ]), U = s(() => z.value.item), W = s(() => V.value.item), ee = s(() => z.value.label), te = s(() => ({
15269
15266
  ...n.labelStyle,
15270
- ...R.value.label
15271
- })), ee = s(() => L.value.content), te = s(() => ({
15267
+ ...V.value.label
15268
+ })), re = s(() => z.value.content), ie = s(() => ({
15272
15269
  ...n.contentStyle,
15273
- ...R.value.content
15270
+ ...V.value.content
15274
15271
  }));
15275
- function re(e) {
15276
- return o.value = [...o.value, e], () => {
15277
- o.value = o.value.filter((t) => t.id !== e.id);
15272
+ D(() => {
15273
+ let e = Object.keys(r);
15274
+ e.length === i.value.length && e.every((e, t) => e === i.value[t]) || (i.value = e);
15275
+ });
15276
+ function ae(e) {
15277
+ return f.value = [...f.value, e], () => {
15278
+ f.value = f.value.filter((t) => t.id !== e.id);
15278
15279
  };
15279
15280
  }
15280
- function ie(e, t) {
15281
- return ae(e, t).span;
15281
+ function K(e, t) {
15282
+ return oe(e, t).span;
15282
15283
  }
15283
- function ae(e, t) {
15284
- return k.value.get(e) ?? {
15284
+ function oe(e, t) {
15285
+ return P.value.get(e) ?? {
15285
15286
  isLastColumn: !0,
15286
15287
  isLastRow: !0,
15287
- span: g(t, b.value)
15288
+ span: _(t, x.value)
15288
15289
  };
15289
15290
  }
15290
15291
  return j(cc, {
15291
- bordered: v,
15292
- colon: y,
15293
- column: b,
15294
- contentClassName: ee,
15295
- contentStyle: te,
15296
- itemClassName: V,
15297
- itemStyle: H,
15298
- labelClassName: U,
15299
- labelStyle: W,
15300
- layout: x,
15301
- registerItem: re,
15302
- resolveItemLayout: ae,
15303
- resolveItemSpan: ie,
15304
- size: S
15292
+ bordered: y,
15293
+ colon: b,
15294
+ column: x,
15295
+ contentClassName: re,
15296
+ contentStyle: ie,
15297
+ itemClassName: U,
15298
+ itemStyle: W,
15299
+ labelClassName: ee,
15300
+ labelStyle: te,
15301
+ layout: S,
15302
+ registerItem: ae,
15303
+ resolveItemLayout: oe,
15304
+ resolveItemSpan: K,
15305
+ size: w
15305
15306
  }), (n, r) => (A(), u("section", {
15306
15307
  ref_key: "rootRef",
15307
- ref: i,
15308
- class: C(z.value),
15309
- style: T(R.value.root)
15310
- }, [D.value ? (A(), u("header", {
15308
+ ref: a,
15309
+ class: C(H.value),
15310
+ style: T(V.value.root)
15311
+ }, [k.value ? (A(), u("header", {
15311
15312
  key: 0,
15312
- class: C(["xy-descriptions__header", L.value.header]),
15313
- style: T(R.value.header)
15314
- }, [w.value ? (A(), u("div", {
15313
+ class: C(["xy-descriptions__header", z.value.header]),
15314
+ style: T(V.value.header)
15315
+ }, [E.value ? (A(), u("div", {
15315
15316
  key: 0,
15316
- class: C(["xy-descriptions__title", L.value.title]),
15317
- style: T(R.value.title)
15318
- }, [I(n.$slots, "title", {}, () => [m(G(lc), { value: e.title }, null, 8, ["value"])], !0)], 6)) : l("", !0), E.value ? (A(), u("div", {
15317
+ class: C(["xy-descriptions__title", z.value.title]),
15318
+ style: T(V.value.title)
15319
+ }, [I(n.$slots, "title", {}, () => [m(G(lc), { value: e.title }, null, 8, ["value"])], !0)], 6)) : l("", !0), O.value ? (A(), u("div", {
15319
15320
  key: 1,
15320
- class: C(["xy-descriptions__extra", L.value.extra]),
15321
- style: T(R.value.extra)
15321
+ class: C(["xy-descriptions__extra", z.value.extra]),
15322
+ style: T(V.value.extra)
15322
15323
  }, [I(n.$slots, "extra", {}, () => [m(G(lc), { value: e.extra }, null, 8, ["value"])], !0)], 6)) : l("", !0)], 6)) : l("", !0), d("dl", {
15323
- class: C(["xy-descriptions__view", L.value.view]),
15324
- style: T([M.value, R.value.view])
15325
- }, [O.value ? (A(!0), u(t, { key: 0 }, F(e.items, (e, t) => (A(), c(dc, {
15324
+ class: C(["xy-descriptions__view", z.value.view]),
15325
+ style: T([L.value, V.value.view])
15326
+ }, [M.value ? (A(!0), u(t, { key: 0 }, F(e.items, (e, t) => (A(), c(dc, {
15326
15327
  key: e.key ?? t,
15327
15328
  "class-names": e.classNames,
15328
15329
  "content-style": e.contentStyle,
@@ -15342,7 +15343,7 @@ var fs = ["aria-label"], ps = ["aria-label", "disabled"], ms = ["aria-label", "d
15342
15343
  "styles"
15343
15344
  ]))), 128)) : I(n.$slots, "default", { key: 1 }, void 0, !0)], 6)], 6));
15344
15345
  }
15345
- }), [["__scopeId", "data-v-604e62a9"]]), pc = X(dc), mc = Object.assign(X(fc), { Item: pc }), hc = ["aria-orientation"], gc = X(/* @__PURE__ */ Z(/* @__PURE__ */ g({
15346
+ }), [["__scopeId", "data-v-103d68c3"]]), pc = X(dc), mc = Object.assign(X(fc), { Item: pc }), hc = ["aria-orientation"], gc = X(/* @__PURE__ */ Z(/* @__PURE__ */ g({
15346
15347
  name: "XyDivider",
15347
15348
  __name: "divider",
15348
15349
  props: {
@@ -23988,11 +23989,7 @@ var af = ["aria-busy", "aria-label"], of = X(/* @__PURE__ */ Z(/* @__PURE__ */ g
23988
23989
  style: T([O.value.item, t.style]),
23989
23990
  "data-status": M(t, r),
23990
23991
  "data-step-key": t.key
23991
- }, [d("span", {
23992
- class: C(["xy-steps__tail", D.value.tail]),
23993
- style: T(O.value.tail),
23994
- "aria-hidden": "true"
23995
- }, null, 6), (A(), c(R(y.value ? "button" : "div"), {
23992
+ }, [(A(), c(R(y.value ? "button" : "div"), {
23996
23993
  class: "xy-steps__main",
23997
23994
  "aria-current": r === v.value ? "step" : void 0,
23998
23995
  "aria-disabled": e.disabled || t.disabled || void 0,
@@ -24025,19 +24022,27 @@ var af = ["aria-busy", "aria-label"], of = X(/* @__PURE__ */ Z(/* @__PURE__ */ g
24025
24022
  })) : (A(), u("span", uf, V(r + 1), 1)), L(t, r, M(t, r)) ? (A(), u("span", df, V(S.value) + "% ", 1)) : l("", !0)], !0)], 6), d("span", {
24026
24023
  class: C(["xy-steps__content", D.value.content]),
24027
24024
  style: T(O.value.content)
24028
- }, [d("span", ff, [d("span", {
24029
- class: C(["xy-steps__title", D.value.title]),
24030
- style: T(O.value.title)
24031
- }, [I(n.$slots, "title", {
24032
- current: r === v.value,
24033
- index: r,
24034
- item: t,
24035
- status: M(t, r)
24036
- }, () => [m(G(i), { content: t.title }, null, 8, ["content"])], !0)], 6), t.subTitle ? (A(), u("span", {
24037
- key: 0,
24038
- class: C(["xy-steps__subtitle", D.value.subTitle]),
24039
- style: T(O.value.subTitle)
24040
- }, [m(G(i), { content: t.subTitle }, null, 8, ["content"])], 6)) : l("", !0)]), t.description || G(f).description ? (A(), u("span", {
24025
+ }, [d("span", ff, [
24026
+ d("span", {
24027
+ class: C(["xy-steps__title", D.value.title]),
24028
+ style: T(O.value.title)
24029
+ }, [I(n.$slots, "title", {
24030
+ current: r === v.value,
24031
+ index: r,
24032
+ item: t,
24033
+ status: M(t, r)
24034
+ }, () => [m(G(i), { content: t.title }, null, 8, ["content"])], !0)], 6),
24035
+ t.subTitle ? (A(), u("span", {
24036
+ key: 0,
24037
+ class: C(["xy-steps__subtitle", D.value.subTitle]),
24038
+ style: T(O.value.subTitle)
24039
+ }, [m(G(i), { content: t.subTitle }, null, 8, ["content"])], 6)) : l("", !0),
24040
+ d("span", {
24041
+ class: C(["xy-steps__tail", D.value.tail]),
24042
+ style: T(O.value.tail),
24043
+ "aria-hidden": "true"
24044
+ }, null, 6)
24045
+ ]), t.description || G(f).description ? (A(), u("span", {
24041
24046
  key: 0,
24042
24047
  class: C(["xy-steps__description", D.value.description]),
24043
24048
  style: T(O.value.description)
@@ -24058,7 +24063,7 @@ var af = ["aria-busy", "aria-label"], of = X(/* @__PURE__ */ Z(/* @__PURE__ */ g
24058
24063
  "onClick"
24059
24064
  ]))], 14, cf))), 128))], 46, sf)], 6));
24060
24065
  }
24061
- }), [["__scopeId", "data-v-740b4545"]])), mf = [
24066
+ }), [["__scopeId", "data-v-0975956e"]])), mf = [
24062
24067
  "id",
24063
24068
  "aria-checked",
24064
24069
  "aria-describedby",
@@ -25759,7 +25764,7 @@ var ip = ["aria-busy"], ap = { key: 0 }, op = { key: 0 }, sp = ["colspan"], cp =
25759
25764
  title: h.value
25760
25765
  }, null, 8, ["title"]))], 14, sp)])) : (A(!0), u(t, { key: 1 }, F(S.value, (e, i) => (A(), u("tr", {
25761
25766
  key: e.key,
25762
- class: C(["xy-table__row", Me.value.row]),
25767
+ class: C(["xy-table__row", [Me.value.row, { "xy-table__row--resize-active": tt(e.key) }]]),
25763
25768
  "data-row-key": e.key,
25764
25769
  style: T(Ue(e))
25765
25770
  }, [d("th", {
@@ -25959,7 +25964,10 @@ var ip = ["aria-busy"], ap = { key: 0 }, op = { key: 0 }, sp = ["colspan"], cp =
25959
25964
  })
25960
25965
  }, [(A(!0), u(t, null, F(Fe.value, (e) => (A(), u("div", {
25961
25966
  key: String(e.key),
25962
- class: C(["xy-table__virtual-row xy-table__row", [Me.value.row, { "xy-table__row--selected": xt(e) && be.value.has(xt(e).key) }]]),
25967
+ class: C(["xy-table__virtual-row xy-table__row", [Me.value.row, {
25968
+ "xy-table__row--selected": xt(e) && be.value.has(xt(e).key),
25969
+ "xy-table__row--resize-active": xt(e) && tt(xt(e))
25970
+ }]]),
25963
25971
  "data-row-key": xt(e)?.key,
25964
25972
  style: T([xt(e) ? He(xt(e)) : {}, {
25965
25973
  gridTemplateColumns: De.value,
@@ -26177,7 +26185,10 @@ var ip = ["aria-busy"], ap = { key: 0 }, op = { key: 0 }, sp = ["colspan"], cp =
26177
26185
  style: T(Ne.value.body)
26178
26186
  }, [(A(!0), u(t, null, F(ve.value, (e) => (A(), u("tr", {
26179
26187
  key: e.key,
26180
- class: C(["xy-table__row", [Me.value.row, { "xy-table__row--selected": be.value.has(e.key) }]]),
26188
+ class: C(["xy-table__row", [Me.value.row, {
26189
+ "xy-table__row--selected": be.value.has(e.key),
26190
+ "xy-table__row--resize-active": tt(e)
26191
+ }]]),
26181
26192
  "data-row-key": e.key,
26182
26193
  style: T(He(e)),
26183
26194
  onClick: (t) => pt(e, t)
@@ -26336,7 +26347,7 @@ var ip = ["aria-busy"], ap = { key: 0 }, op = { key: 0 }, sp = ["colspan"], cp =
26336
26347
  "total"
26337
26348
  ])) : l("", !0)], 14, ip));
26338
26349
  }
26339
- }), [["__scopeId", "data-v-ea4be9b9"]])), Jp = ["aria-label", "aria-orientation"], Yp = [
26350
+ }), [["__scopeId", "data-v-90886cf3"]])), Jp = ["aria-label", "aria-orientation"], Yp = [
26340
26351
  "data-tab-key",
26341
26352
  "id",
26342
26353
  "aria-controls",
@@ -9,7 +9,7 @@ import qe from "dayjs/plugin/quarterOfYear.js";
9
9
  import Je from "dayjs/plugin/weekOfYear.js";
10
10
  import Ye from "dayjs/plugin/weekYear.js";
11
11
  //#region package.json
12
- var Xe = "0.1.1";
12
+ var Xe = "0.1.3";
13
13
  //#endregion
14
14
  //#region components/shared/install.ts
15
15
  function Z(e) {
@@ -6297,13 +6297,10 @@ var zr = [
6297
6297
  t.className,
6298
6298
  v.value.item
6299
6299
  ]]),
6300
- style: T([
6301
- t.style,
6302
- e.direction === "vertical" ? { paddingInlineStart: `${r * 16}px` } : void 0,
6303
- y.value.item
6304
- ])
6300
+ style: T([t.style, y.value.item])
6305
6301
  }, [d("a", {
6306
6302
  class: C(["xy-anchor__link", { "xy-anchor__link--disabled": t.disabled }]),
6303
+ style: T(e.direction === "vertical" && r > 0 ? { paddingInlineStart: `calc(var(--xy-anchor-link-padding-inline) + ${r * 16}px)` } : void 0),
6307
6304
  href: t.href,
6308
6305
  target: t.target,
6309
6306
  rel: t.target === "_blank" ? "noreferrer" : void 0,
@@ -6322,11 +6319,11 @@ var zr = [
6322
6319
  depth: r,
6323
6320
  index: i,
6324
6321
  item: t
6325
- }, () => [p(B(D(t)), 1)])], 6)], 10, Gr)], 6))), 128))], 6)) : l("", !0),
6322
+ }, () => [p(B(D(t)), 1)])], 6)], 14, Gr)], 6))), 128))], 6)) : l("", !0),
6326
6323
  F(n.$slots, "default")
6327
6324
  ], 14, Wr));
6328
6325
  }
6329
- }), [["__scopeId", "data-v-93931713"]])), qr = Z($), Jr = ["aria-busy", "role"], Yr = ["aria-label"], Xr = /*#__PURE__*/ Q(/* @__PURE__ */ g({
6326
+ }), [["__scopeId", "data-v-5b2bf520"]])), qr = Z($), Jr = ["aria-busy", "role"], Yr = ["aria-label"], Xr = /*#__PURE__*/ Q(/* @__PURE__ */ g({
6330
6327
  name: "XyMessage",
6331
6328
  __name: "message",
6332
6329
  props: {
@@ -14863,7 +14860,7 @@ var Jo = ["aria-label"], Yo = ["aria-label", "disabled"], Xo = ["aria-label", "d
14863
14860
  }
14864
14861
  },
14865
14862
  setup(e) {
14866
- let n = e, r = G(), i = M(), { width: a } = or(i), o = z([]), f = {
14863
+ let n = e, r = G(), i = M(Object.keys(r)), a = M(), { width: o } = or(a), f = z([]), p = {
14867
14864
  xs: 0,
14868
14865
  sm: 576,
14869
14866
  md: 768,
@@ -14871,28 +14868,28 @@ var Jo = ["aria-label"], Yo = ["aria-label", "disabled"], Xo = ["aria-label", "d
14871
14868
  xl: 1200,
14872
14869
  xxl: 1600,
14873
14870
  xxxl: 1920
14874
- }, p = Object.keys(f);
14875
- function h(e) {
14871
+ }, h = Object.keys(p);
14872
+ function g(e) {
14876
14873
  let t = Number(e);
14877
14874
  return Number.isFinite(t) ? Math.max(1, Math.floor(t)) : 1;
14878
14875
  }
14879
- function g(e, t) {
14880
- return e === "filled" ? t : Math.min(h(e), t);
14881
- }
14882
14876
  function _(e, t) {
14883
- if (typeof e == "number") return h(e);
14884
- let n = p.filter((t) => e[t] !== void 0);
14877
+ return e === "filled" ? t : Math.min(g(e), t);
14878
+ }
14879
+ function v(e, t) {
14880
+ if (typeof e == "number") return g(e);
14881
+ let n = h.filter((t) => e[t] !== void 0);
14885
14882
  if (n.length === 0) return 1;
14886
14883
  let r = e[n[0]];
14887
- for (let i of n) t >= f[i] && (r = e[i]);
14888
- return h(r);
14884
+ for (let i of n) t >= p[i] && (r = e[i]);
14885
+ return g(r);
14889
14886
  }
14890
- let v = s(() => n.bordered), y = s(() => n.colon), b = s(() => _(n.column, a.value)), x = s(() => n.layout), S = s(() => n.size), w = s(() => n.title !== void 0 || !!r.title), E = s(() => n.extra !== void 0 || !!r.extra), D = s(() => w.value || E.value), O = s(() => n.items !== void 0), j = s(() => {
14887
+ let y = s(() => n.bordered), b = s(() => n.colon), x = s(() => v(n.column, o.value)), S = s(() => n.layout), w = s(() => n.size), E = s(() => n.title !== void 0 || i.value.includes("title")), O = s(() => n.extra !== void 0 || i.value.includes("extra")), j = s(() => E.value || O.value), N = s(() => n.items !== void 0), I = s(() => {
14891
14888
  let e = /* @__PURE__ */ new Map(), t = 0, n = 0;
14892
- for (let r of o.value) {
14893
- let i = r.span.value, a = g(i, b.value);
14894
- i === "filled" ? a = Math.max(b.value - t, 1) : t + a > b.value && (t = 0, n += 1);
14895
- let o = t + a >= b.value;
14889
+ for (let r of f.value) {
14890
+ let i = r.span.value, a = _(i, x.value);
14891
+ i === "filled" ? a = Math.max(x.value - t, 1) : t + a > x.value && (t = 0, n += 1);
14892
+ let o = t + a >= x.value;
14896
14893
  e.set(r.id, {
14897
14894
  isLastColumn: o,
14898
14895
  isLastRow: !1,
@@ -14903,78 +14900,82 @@ var Jo = ["aria-label"], Yo = ["aria-label", "disabled"], Xo = ["aria-label", "d
14903
14900
  let r = Math.max(...[...e.values()].map((e) => e.row), 0);
14904
14901
  for (let t of e.values()) t.isLastRow = t.row === r;
14905
14902
  return e;
14906
- }), N = s(() => ({ "--xy-descriptions-column": String(b.value) })), I = s(() => ({
14903
+ }), L = s(() => ({ "--xy-descriptions-column": String(x.value) })), R = s(() => ({
14907
14904
  bordered: n.bordered,
14908
14905
  colon: n.colon,
14909
- column: b.value,
14910
- hasExtra: E.value,
14911
- hasTitle: w.value,
14906
+ column: x.value,
14907
+ hasExtra: O.value,
14908
+ hasTitle: E.value,
14912
14909
  layout: n.layout,
14913
14910
  size: n.size
14914
- })), L = s(() => it(n.classNames, I.value)), R = s(() => at(n.styles, I.value)), B = s(() => [
14911
+ })), B = s(() => it(n.classNames, R.value)), V = s(() => at(n.styles, R.value)), H = s(() => [
14915
14912
  "xy-descriptions",
14916
14913
  `xy-descriptions--${n.layout}`,
14917
14914
  `xy-descriptions--${n.size}`,
14918
14915
  { "xy-descriptions--bordered": n.bordered },
14919
- L.value.root
14920
- ]), V = s(() => L.value.item), H = s(() => R.value.item), W = s(() => L.value.label), ee = s(() => ({
14916
+ B.value.root
14917
+ ]), W = s(() => B.value.item), ee = s(() => V.value.item), K = s(() => B.value.label), te = s(() => ({
14921
14918
  ...n.labelStyle,
14922
- ...R.value.label
14923
- })), K = s(() => L.value.content), te = s(() => ({
14919
+ ...V.value.label
14920
+ })), ne = s(() => B.value.content), re = s(() => ({
14924
14921
  ...n.contentStyle,
14925
- ...R.value.content
14922
+ ...V.value.content
14926
14923
  }));
14927
- function ne(e) {
14928
- return o.value = [...o.value, e], () => {
14929
- o.value = o.value.filter((t) => t.id !== e.id);
14924
+ D(() => {
14925
+ let e = Object.keys(r);
14926
+ e.length === i.value.length && e.every((e, t) => e === i.value[t]) || (i.value = e);
14927
+ });
14928
+ function ie(e) {
14929
+ return f.value = [...f.value, e], () => {
14930
+ f.value = f.value.filter((t) => t.id !== e.id);
14930
14931
  };
14931
14932
  }
14932
- function re(e, t) {
14933
- return ie(e, t).span;
14933
+ function J(e, t) {
14934
+ return ae(e, t).span;
14934
14935
  }
14935
- function ie(e, t) {
14936
- return j.value.get(e) ?? {
14936
+ function ae(e, t) {
14937
+ return I.value.get(e) ?? {
14937
14938
  isLastColumn: !0,
14938
14939
  isLastRow: !0,
14939
- span: g(t, b.value)
14940
+ span: _(t, x.value)
14940
14941
  };
14941
14942
  }
14942
14943
  return A(Ws, {
14943
- bordered: v,
14944
- colon: y,
14945
- column: b,
14946
- contentClassName: K,
14947
- contentStyle: te,
14948
- itemClassName: V,
14949
- itemStyle: H,
14950
- labelClassName: W,
14951
- labelStyle: ee,
14952
- layout: x,
14953
- registerItem: ne,
14954
- resolveItemLayout: ie,
14955
- resolveItemSpan: re,
14956
- size: S
14944
+ bordered: y,
14945
+ colon: b,
14946
+ column: x,
14947
+ contentClassName: ne,
14948
+ contentStyle: re,
14949
+ itemClassName: W,
14950
+ itemStyle: ee,
14951
+ labelClassName: K,
14952
+ labelStyle: te,
14953
+ layout: S,
14954
+ registerItem: ie,
14955
+ resolveItemLayout: ae,
14956
+ resolveItemSpan: J,
14957
+ size: w
14957
14958
  }), (n, r) => (k(), u("section", {
14958
14959
  ref_key: "rootRef",
14959
- ref: i,
14960
- class: C(B.value),
14961
- style: T(R.value.root)
14962
- }, [D.value ? (k(), u("header", {
14960
+ ref: a,
14961
+ class: C(H.value),
14962
+ style: T(V.value.root)
14963
+ }, [j.value ? (k(), u("header", {
14963
14964
  key: 0,
14964
- class: C(["xy-descriptions__header", L.value.header]),
14965
- style: T(R.value.header)
14966
- }, [w.value ? (k(), u("div", {
14965
+ class: C(["xy-descriptions__header", B.value.header]),
14966
+ style: T(V.value.header)
14967
+ }, [E.value ? (k(), u("div", {
14967
14968
  key: 0,
14968
- class: C(["xy-descriptions__title", L.value.title]),
14969
- style: T(R.value.title)
14970
- }, [F(n.$slots, "title", {}, () => [m(U(Gs), { value: e.title }, null, 8, ["value"])], !0)], 6)) : l("", !0), E.value ? (k(), u("div", {
14969
+ class: C(["xy-descriptions__title", B.value.title]),
14970
+ style: T(V.value.title)
14971
+ }, [F(n.$slots, "title", {}, () => [m(U(Gs), { value: e.title }, null, 8, ["value"])], !0)], 6)) : l("", !0), O.value ? (k(), u("div", {
14971
14972
  key: 1,
14972
- class: C(["xy-descriptions__extra", L.value.extra]),
14973
- style: T(R.value.extra)
14973
+ class: C(["xy-descriptions__extra", B.value.extra]),
14974
+ style: T(V.value.extra)
14974
14975
  }, [F(n.$slots, "extra", {}, () => [m(U(Gs), { value: e.extra }, null, 8, ["value"])], !0)], 6)) : l("", !0)], 6)) : l("", !0), d("dl", {
14975
- class: C(["xy-descriptions__view", L.value.view]),
14976
- style: T([N.value, R.value.view])
14977
- }, [O.value ? (k(!0), u(t, { key: 0 }, P(e.items, (e, t) => (k(), c(qs, {
14976
+ class: C(["xy-descriptions__view", B.value.view]),
14977
+ style: T([L.value, V.value.view])
14978
+ }, [N.value ? (k(!0), u(t, { key: 0 }, P(e.items, (e, t) => (k(), c(qs, {
14978
14979
  key: e.key ?? t,
14979
14980
  "class-names": e.classNames,
14980
14981
  "content-style": e.contentStyle,
@@ -14994,7 +14995,7 @@ var Jo = ["aria-label"], Yo = ["aria-label", "disabled"], Xo = ["aria-label", "d
14994
14995
  "styles"
14995
14996
  ]))), 128)) : F(n.$slots, "default", { key: 1 }, void 0, !0)], 6)], 6));
14996
14997
  }
14997
- }), [["__scopeId", "data-v-604e62a9"]]), Ys = Z(qs), Xs = Object.assign(Z(Js), { Item: Ys }), Zs = ["aria-orientation"], Qs = Z(/* @__PURE__ */ Q(/* @__PURE__ */ g({
14998
+ }), [["__scopeId", "data-v-103d68c3"]]), Ys = Z(qs), Xs = Object.assign(Z(Js), { Item: Ys }), Zs = ["aria-orientation"], Qs = Z(/* @__PURE__ */ Q(/* @__PURE__ */ g({
14998
14999
  name: "XyDivider",
14999
15000
  __name: "divider",
15000
15001
  props: {
@@ -22859,11 +22860,7 @@ var od = ["aria-busy", "aria-label"], sd = Z(/* @__PURE__ */ Q(/* @__PURE__ */ g
22859
22860
  style: T([O.value.item, t.style]),
22860
22861
  "data-status": N(t, r),
22861
22862
  "data-step-key": t.key
22862
- }, [d("span", {
22863
- class: C(["xy-steps__tail", D.value.tail]),
22864
- style: T(O.value.tail),
22865
- "aria-hidden": "true"
22866
- }, null, 6), (k(), c(L(y.value ? "button" : "div"), {
22863
+ }, [(k(), c(L(y.value ? "button" : "div"), {
22867
22864
  class: "xy-steps__main",
22868
22865
  "aria-current": r === v.value ? "step" : void 0,
22869
22866
  "aria-disabled": e.disabled || t.disabled || void 0,
@@ -22896,19 +22893,27 @@ var od = ["aria-busy", "aria-label"], sd = Z(/* @__PURE__ */ Q(/* @__PURE__ */ g
22896
22893
  })) : (k(), u("span", dd, B(r + 1), 1)), R(t, r, N(t, r)) ? (k(), u("span", fd, B(S.value) + "% ", 1)) : l("", !0)], !0)], 6), d("span", {
22897
22894
  class: C(["xy-steps__content", D.value.content]),
22898
22895
  style: T(O.value.content)
22899
- }, [d("span", pd, [d("span", {
22900
- class: C(["xy-steps__title", D.value.title]),
22901
- style: T(O.value.title)
22902
- }, [F(n.$slots, "title", {
22903
- current: r === v.value,
22904
- index: r,
22905
- item: t,
22906
- status: N(t, r)
22907
- }, () => [m(U(i), { content: t.title }, null, 8, ["content"])], !0)], 6), t.subTitle ? (k(), u("span", {
22908
- key: 0,
22909
- class: C(["xy-steps__subtitle", D.value.subTitle]),
22910
- style: T(O.value.subTitle)
22911
- }, [m(U(i), { content: t.subTitle }, null, 8, ["content"])], 6)) : l("", !0)]), t.description || U(f).description ? (k(), u("span", {
22896
+ }, [d("span", pd, [
22897
+ d("span", {
22898
+ class: C(["xy-steps__title", D.value.title]),
22899
+ style: T(O.value.title)
22900
+ }, [F(n.$slots, "title", {
22901
+ current: r === v.value,
22902
+ index: r,
22903
+ item: t,
22904
+ status: N(t, r)
22905
+ }, () => [m(U(i), { content: t.title }, null, 8, ["content"])], !0)], 6),
22906
+ t.subTitle ? (k(), u("span", {
22907
+ key: 0,
22908
+ class: C(["xy-steps__subtitle", D.value.subTitle]),
22909
+ style: T(O.value.subTitle)
22910
+ }, [m(U(i), { content: t.subTitle }, null, 8, ["content"])], 6)) : l("", !0),
22911
+ d("span", {
22912
+ class: C(["xy-steps__tail", D.value.tail]),
22913
+ style: T(O.value.tail),
22914
+ "aria-hidden": "true"
22915
+ }, null, 6)
22916
+ ]), t.description || U(f).description ? (k(), u("span", {
22912
22917
  key: 0,
22913
22918
  class: C(["xy-steps__description", D.value.description]),
22914
22919
  style: T(O.value.description)
@@ -22929,7 +22934,7 @@ var od = ["aria-busy", "aria-label"], sd = Z(/* @__PURE__ */ Q(/* @__PURE__ */ g
22929
22934
  "onClick"
22930
22935
  ]))], 14, ld))), 128))], 46, cd)], 6));
22931
22936
  }
22932
- }), [["__scopeId", "data-v-740b4545"]])), hd = [
22937
+ }), [["__scopeId", "data-v-0975956e"]])), hd = [
22933
22938
  "id",
22934
22939
  "aria-checked",
22935
22940
  "aria-describedby",