@pantograph/vue 0.10.7 → 0.10.8

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 (77) hide show
  1. package/dist/DataTable/{index.js.js → index.js} +185 -188
  2. package/dist/DataTable/index.umd.cjs +1 -0
  3. package/dist/{index.js.js → index.js} +1 -1
  4. package/dist/index.umd.cjs +1 -0
  5. package/package.json +1 -1
  6. package/dist/DataTable/index.umd.cjs.js +0 -1
  7. package/dist/index.umd.cjs.js +0 -1
  8. /package/dist/ActionButton/{index.js.js → index.js} +0 -0
  9. /package/dist/ActionButton/{index.umd.cjs.js → index.umd.cjs} +0 -0
  10. /package/dist/Avatar/{index.js.js → index.js} +0 -0
  11. /package/dist/Avatar/{index.umd.cjs.js → index.umd.cjs} +0 -0
  12. /package/dist/AvatarGroup/{index.js.js → index.js} +0 -0
  13. /package/dist/AvatarGroup/{index.umd.cjs.js → index.umd.cjs} +0 -0
  14. /package/dist/Badge/{index.js.js → index.js} +0 -0
  15. /package/dist/Badge/{index.umd.cjs.js → index.umd.cjs} +0 -0
  16. /package/dist/Button/{index.js.js → index.js} +0 -0
  17. /package/dist/Button/{index.umd.cjs.js → index.umd.cjs} +0 -0
  18. /package/dist/ButtonGroup/{index.js.js → index.js} +0 -0
  19. /package/dist/ButtonGroup/{index.umd.cjs.js → index.umd.cjs} +0 -0
  20. /package/dist/Checkbox/{index.js.js → index.js} +0 -0
  21. /package/dist/Checkbox/{index.umd.cjs.js → index.umd.cjs} +0 -0
  22. /package/dist/CheckboxGroup/{index.js.js → index.js} +0 -0
  23. /package/dist/CheckboxGroup/{index.umd.cjs.js → index.umd.cjs} +0 -0
  24. /package/dist/ColorPicker/{index.js.js → index.js} +0 -0
  25. /package/dist/ColorPicker/{index.umd.cjs.js → index.umd.cjs} +0 -0
  26. /package/dist/ColorSwatch/{index.js.js → index.js} +0 -0
  27. /package/dist/ColorSwatch/{index.umd.cjs.js → index.umd.cjs} +0 -0
  28. /package/dist/ColorSwatchGroup/{index.js.js → index.js} +0 -0
  29. /package/dist/ColorSwatchGroup/{index.umd.cjs.js → index.umd.cjs} +0 -0
  30. /package/dist/ColorTrigger/{index.js.js → index.js} +0 -0
  31. /package/dist/ColorTrigger/{index.umd.cjs.js → index.umd.cjs} +0 -0
  32. /package/dist/ConfigProvider/{index.js.js → index.js} +0 -0
  33. /package/dist/ConfigProvider/{index.umd.cjs.js → index.umd.cjs} +0 -0
  34. /package/dist/Divider/{index.js.js → index.js} +0 -0
  35. /package/dist/Divider/{index.umd.cjs.js → index.umd.cjs} +0 -0
  36. /package/dist/Empty/{index.js.js → index.js} +0 -0
  37. /package/dist/Empty/{index.umd.cjs.js → index.umd.cjs} +0 -0
  38. /package/dist/FloatButton/{index.js.js → index.js} +0 -0
  39. /package/dist/FloatButton/{index.umd.cjs.js → index.umd.cjs} +0 -0
  40. /package/dist/GraphicalObject/{index.js.js → index.js} +0 -0
  41. /package/dist/GraphicalObject/{index.umd.cjs.js → index.umd.cjs} +0 -0
  42. /package/dist/Icon/{index.js.js → index.js} +0 -0
  43. /package/dist/Icon/{index.umd.cjs.js → index.umd.cjs} +0 -0
  44. /package/dist/IconButton/{index.js.js → index.js} +0 -0
  45. /package/dist/IconButton/{index.umd.cjs.js → index.umd.cjs} +0 -0
  46. /package/dist/Image/{index.js.js → index.js} +0 -0
  47. /package/dist/Image/{index.umd.cjs.js → index.umd.cjs} +0 -0
  48. /package/dist/IndentLevel/{index.js.js → index.js} +0 -0
  49. /package/dist/IndentLevel/{index.umd.cjs.js → index.umd.cjs} +0 -0
  50. /package/dist/Indicator/{index.js.js → index.js} +0 -0
  51. /package/dist/Indicator/{index.umd.cjs.js → index.umd.cjs} +0 -0
  52. /package/dist/Input/{index.js.js → index.js} +0 -0
  53. /package/dist/Input/{index.umd.cjs.js → index.umd.cjs} +0 -0
  54. /package/dist/Kbd/{index.js.js → index.js} +0 -0
  55. /package/dist/Kbd/{index.umd.cjs.js → index.umd.cjs} +0 -0
  56. /package/dist/Menu/{index.js.js → index.js} +0 -0
  57. /package/dist/Menu/{index.umd.cjs.js → index.umd.cjs} +0 -0
  58. /package/dist/MenuItem/{index.js.js → index.js} +0 -0
  59. /package/dist/MenuItem/{index.umd.cjs.js → index.umd.cjs} +0 -0
  60. /package/dist/Popover/{index.js.js → index.js} +0 -0
  61. /package/dist/Popover/{index.umd.cjs.js → index.umd.cjs} +0 -0
  62. /package/dist/RadioGroup/{index.js.js → index.js} +0 -0
  63. /package/dist/RadioGroup/{index.umd.cjs.js → index.umd.cjs} +0 -0
  64. /package/dist/Shortcut/{index.js.js → index.js} +0 -0
  65. /package/dist/Shortcut/{index.umd.cjs.js → index.umd.cjs} +0 -0
  66. /package/dist/Skeleton/{index.js.js → index.js} +0 -0
  67. /package/dist/Skeleton/{index.umd.cjs.js → index.umd.cjs} +0 -0
  68. /package/dist/Spinner/{index.js.js → index.js} +0 -0
  69. /package/dist/Spinner/{index.umd.cjs.js → index.umd.cjs} +0 -0
  70. /package/dist/Switch/{index.js.js → index.js} +0 -0
  71. /package/dist/Switch/{index.umd.cjs.js → index.umd.cjs} +0 -0
  72. /package/dist/Table/{index.js.js → index.js} +0 -0
  73. /package/dist/Table/{index.umd.cjs.js → index.umd.cjs} +0 -0
  74. /package/dist/Tree/{index.js.js → index.js} +0 -0
  75. /package/dist/Tree/{index.umd.cjs.js → index.umd.cjs} +0 -0
  76. /package/dist/utils/{index.js.js → index.js} +0 -0
  77. /package/dist/utils/{index.umd.cjs.js → index.umd.cjs} +0 -0
@@ -1,19 +1,19 @@
1
- import { defineComponent as _e, useSlots as $e, computed as P, createElementBlock as p, openBlock as a, normalizeClass as g, unref as t, createElementVNode as v, createCommentVNode as R, renderSlot as H, createBlock as T, createTextVNode as le, toDisplayString as J, h as Ze, ref as Q, watch as X, useTemplateRef as Ne, onBeforeUnmount as Oe, shallowRef as qe, createVNode as f, withCtx as d, normalizeStyle as Fe, Fragment as A, renderList as Z, mergeProps as I, createSlots as Ce, normalizeProps as Ge, guardReactiveProps as Ue, nextTick as se } from "vue";
1
+ import { defineComponent as _e, useSlots as $e, computed as P, createElementBlock as p, openBlock as a, normalizeClass as g, unref as t, createElementVNode as v, createCommentVNode as R, renderSlot as H, createBlock as T, createTextVNode as ne, toDisplayString as J, h as Ze, ref as Q, watch as ae, useTemplateRef as Ne, onBeforeUnmount as Oe, shallowRef as qe, createVNode as f, withCtx as d, normalizeStyle as Fe, Fragment as A, renderList as Z, mergeProps as I, createSlots as Ce, normalizeProps as Ge, guardReactiveProps as Ue, nextTick as le } from "vue";
2
2
  import { createColumnHelper as Je, flattenBy as Qe, useVueTable as Xe, getSortedRowModel as Ye, getCoreRowModel as xe } from "@tanstack/vue-table";
3
3
  import { b as et } from "../_baseIsEqual-BknLKouD.js";
4
- import { i as tt, b as ot, a as re } from "../isArray-CdbPONHA.js";
4
+ import { i as tt, b as ot, a as se } from "../isArray-CdbPONHA.js";
5
5
  import { u as nt } from "../useId-DvOSMFGX.js";
6
6
  import { _ as ye } from "../Checkbox.vue_vue_type_style_index_0_lang-BD4g7E0x.js";
7
- import { c as he, _ as lt, a as ie } from "../Menu.vue_vue_type_style_index_0_lang-Ck9CxDR-.js";
7
+ import { c as he, _ as lt, a as re } from "../Menu.vue_vue_type_style_index_0_lang-Ck9CxDR-.js";
8
8
  import { _ as st } from "../ActionButton.vue_vue_type_script_setup_true_lang-BG7u9LIG.js";
9
- import { g as Re, a as He, b as k, w as rt } from "../class-BCq3bHT0.js";
9
+ import { g as Re, a as He, b as w, w as rt } from "../class-BCq3bHT0.js";
10
10
  import { cva as ze } from "class-variance-authority";
11
11
  import { g as it } from "../options-JBqnVZUl.js";
12
- import { _ as Y } from "../Icon.vue_vue_type_style_index_0_lang-BpIpKu8I.js";
12
+ import { _ as X } from "../Icon.vue_vue_type_style_index_0_lang-BpIpKu8I.js";
13
13
  import { getCssVar as N, getBreakpoints as at } from "@pantograph/tokens";
14
14
  import { o as Be } from "../omit-CD3OjwFx.js";
15
15
  import { u as ct } from "../uniq-DSVd52ma.js";
16
- import { i as ae, a as V } from "../_flatRest-Dx0ZZgOx.js";
16
+ import { i as ie, a as V } from "../_flatRest-Dx0ZZgOx.js";
17
17
  import { useBreakpoints as ut, useIntersectionObserver as dt } from "@vueuse/core";
18
18
  import { _ as mt } from "../Skeleton.vue_vue_type_style_index_0_lang-Cjdn_7-J.js";
19
19
  import { _ as ve } from "../Popover.vue_vue_type_style_index_0_lang-DWUbX1hj.js";
@@ -47,26 +47,26 @@ const vt = ["simple", "advance"], wt = {
47
47
  description: {}
48
48
  },
49
49
  setup(B) {
50
- const _ = B, l = $e(), z = Re("empty"), b = ze(z, {
50
+ const _ = B, s = $e(), z = Re("empty"), b = ze(z, {
51
51
  variants: {
52
52
  type: He(vt, z)
53
53
  }
54
- }), u = P(() => _.title || !!l.title), $ = P(() => _.description || !!l.description);
55
- return (s, C) => (a(), p("div", {
54
+ }), u = P(() => _.title || !!s.title), $ = P(() => _.description || !!s.description);
55
+ return (l, C) => (a(), p("div", {
56
56
  class: g([
57
57
  t(b)({
58
- type: s.type
58
+ type: l.type
59
59
  }),
60
60
  _.class
61
61
  ])
62
62
  }, [
63
63
  v("div", {
64
- class: g([t(k)(t(z), "image"), s.imageCls])
64
+ class: g([t(w)(t(z), "image"), l.imageCls])
65
65
  }, [
66
- H(s.$slots, "image", {}, () => [
67
- s.type === "simple" ? (a(), T(Y, {
66
+ H(l.$slots, "image", {}, () => [
67
+ l.type === "simple" ? (a(), T(X, {
68
68
  key: 0,
69
- icon: s.icon,
69
+ icon: l.icon,
70
70
  size: "sm"
71
71
  }, null, 8, ["icon"])) : (a(), p("svg", wt, [
72
72
  v("path", {
@@ -117,48 +117,48 @@ const vt = ["simple", "advance"], wt = {
117
117
  ]))
118
118
  ])
119
119
  ], 2),
120
- s.type === "simple" && u.value ? (a(), p("div", {
120
+ l.type === "simple" && u.value ? (a(), p("div", {
121
121
  key: 0,
122
- class: g([t(k)(t(z), "title"), s.titleCls])
122
+ class: g([t(w)(t(z), "title"), l.titleCls])
123
123
  }, [
124
- H(s.$slots, "title", {}, () => [
125
- le(J(s.title), 1)
124
+ H(l.$slots, "title", {}, () => [
125
+ ne(J(l.title), 1)
126
126
  ])
127
- ], 2)) : u.value || $.value || l.actions ? (a(), p("div", {
127
+ ], 2)) : u.value || $.value || s.actions ? (a(), p("div", {
128
128
  key: 1,
129
- class: g([t(k)(t(z), "content"), s.contentCls])
129
+ class: g([t(w)(t(z), "content"), l.contentCls])
130
130
  }, [
131
131
  u.value || $.value ? (a(), p("div", {
132
132
  key: 0,
133
- class: g([t(k)(t(z), "text"), s.textCls])
133
+ class: g([t(w)(t(z), "text"), l.textCls])
134
134
  }, [
135
135
  u.value ? (a(), p("div", {
136
136
  key: 0,
137
- class: g([t(k)(t(z), "title"), s.titleCls])
137
+ class: g([t(w)(t(z), "title"), l.titleCls])
138
138
  }, [
139
- H(s.$slots, "title", {}, () => [
140
- le(J(s.title), 1)
139
+ H(l.$slots, "title", {}, () => [
140
+ ne(J(l.title), 1)
141
141
  ])
142
142
  ], 2)) : R("", !0),
143
143
  $.value ? (a(), p("div", {
144
144
  key: 1,
145
- class: g([t(k)(t(z), "description"), s.descriptionCls])
145
+ class: g([t(w)(t(z), "description"), l.descriptionCls])
146
146
  }, [
147
- H(s.$slots, "description", {}, () => [
148
- le(J(s.description), 1)
147
+ H(l.$slots, "description", {}, () => [
148
+ ne(J(l.description), 1)
149
149
  ])
150
150
  ], 2)) : R("", !0)
151
151
  ], 2)) : R("", !0),
152
- l.actions ? (a(), p("div", {
152
+ s.actions ? (a(), p("div", {
153
153
  key: 1,
154
- class: g([t(k)(t(z), "actions"), s.actionsCls])
154
+ class: g([t(w)(t(z), "actions"), l.actionsCls])
155
155
  }, [
156
- H(s.$slots, "actions")
156
+ H(l.$slots, "actions")
157
157
  ], 2)) : R("", !0)
158
158
  ], 2)) : R("", !0)
159
159
  ], 2));
160
160
  }
161
- }), Bt = (B, { isColumnWrapped: _, selectionId: l }) => {
161
+ }), Bt = (B, { isColumnWrapped: _, selectionId: s }) => {
162
162
  const z = (o) => {
163
163
  var m;
164
164
  const c = (y) => y === "list" ? "md" : "sm";
@@ -187,22 +187,22 @@ const vt = ["simple", "advance"], wt = {
187
187
  });
188
188
  }
189
189
  return c;
190
- }, $ = {}, s = (o, c = !0) => {
190
+ }, $ = {}, l = (o, c = !0) => {
191
191
  var y;
192
192
  let m = 1;
193
- return ((y = o == null ? void 0 : o.subHeaders) == null ? void 0 : y.length) === 1 && o.column.id === o.subHeaders[0].column.id && (m += s(o.subHeaders[0], !1)), c && (!$[o.column.id] || $[o.column.id] < m) && ($[o.column.id] = m), m;
193
+ return ((y = o == null ? void 0 : o.subHeaders) == null ? void 0 : y.length) === 1 && o.column.id === o.subHeaders[0].column.id && (m += l(o.subHeaders[0], !1)), c && (!$[o.column.id] || $[o.column.id] < m) && ($[o.column.id] = m), m;
194
194
  }, C = (o, c = {}) => {
195
195
  var m;
196
196
  if (o != null && o.column) {
197
197
  const y = (m = o == null ? void 0 : o.column) == null ? void 0 : m.columnDef, M = [], L = {};
198
- if (ae(y)) {
198
+ if (ie(y)) {
199
199
  let D = _(o.column.id);
200
200
  const { customCell: K, class: F } = y;
201
- if (he(F) || M.push(F), K && (ae(K) || V(K))) {
202
- const q = (w) => {
203
- if (ae(w)) {
204
- const { wrap: E, colSpan: ee, rowSpan: te } = w;
205
- D = D || (E ?? !1), L.colSpan = ee, L.rowSpan = te;
201
+ if (he(F) || M.push(F), K && (ie(K) || V(K))) {
202
+ const q = (k) => {
203
+ if (ie(k)) {
204
+ const { wrap: E, colSpan: x, rowSpan: ee } = k;
205
+ D = D || (E ?? !1), L.colSpan = x, L.rowSpan = ee;
206
206
  }
207
207
  };
208
208
  V(K) && o.row ? q(
@@ -213,7 +213,7 @@ const vt = ["simple", "advance"], wt = {
213
213
  })
214
214
  ) : q(K);
215
215
  }
216
- o.header ? L.rowSpan = s(o.header) : D && (L.wrap = !0);
216
+ o.header ? L.rowSpan = l(o.header) : D && (L.wrap = !0);
217
217
  }
218
218
  return {
219
219
  class: he(M) ? void 0 : M,
@@ -236,7 +236,7 @@ const vt = ["simple", "advance"], wt = {
236
236
  getTdProps: (o) => C(o),
237
237
  getColProps: (o) => {
238
238
  const c = u(o.columnDef);
239
- return o.id === l && (c.width = "var(--pt-dimension-2800)"), {
239
+ return o.id === s && (c.width = "var(--pt-dimension-2800)"), {
240
240
  style: c
241
241
  };
242
242
  },
@@ -248,26 +248,26 @@ function It(B) {
248
248
  return B === !0 || B === !1 || tt(B) && ot(B) == At;
249
249
  }
250
250
  const Tt = (B) => {
251
- const _ = Q([]), l = (s) => s ? _.value.findIndex((C) => C.id === s) : -1, z = (s) => {
252
- if (s) return _.value.find((C) => C.id === s);
253
- }, b = (s) => {
251
+ const _ = Q([]), s = (l) => l ? _.value.findIndex((C) => C.id === l) : -1, z = (l) => {
252
+ if (l) return _.value.find((C) => C.id === l);
253
+ }, b = (l) => {
254
254
  var C;
255
- return !!((C = z(s)) != null && C.wrap);
256
- }, u = (s) => {
257
- const { id: C } = s;
255
+ return !!((C = z(l)) != null && C.wrap);
256
+ }, u = (l) => {
257
+ const { id: C } = l;
258
258
  if (!C) return !1;
259
- const W = s.wrap ?? !b(C), O = l(C);
259
+ const W = l.wrap ?? !b(C), O = s(C);
260
260
  return O >= 0 ? _.value[O] = { id: C, wrap: W } : _.value.push({ id: C, wrap: W }), !0;
261
261
  }, $ = P(
262
- () => (B.columns ?? []).filter((s) => It(s.wrap)).map((s) => ({
263
- id: s.id,
264
- wrap: !!s.wrap
262
+ () => (B.columns ?? []).filter((l) => It(l.wrap)).map((l) => ({
263
+ id: l.id,
264
+ wrap: !!l.wrap
265
265
  }))
266
266
  );
267
- return X(
267
+ return ae(
268
268
  $,
269
- (s) => {
270
- _.value = [..._.value, ...s];
269
+ (l) => {
270
+ _.value = [..._.value, ...l];
271
271
  },
272
272
  {
273
273
  immediate: !0,
@@ -309,84 +309,84 @@ const Tt = (B) => {
309
309
  },
310
310
  emits: ["fetch"],
311
311
  setup(B, { emit: _ }) {
312
- const l = B, z = _, b = $e(), u = Re("data_table", rt), $ = Je(), s = `$${u}_selection$`, C = P(() => {
312
+ const s = B, z = _, b = $e(), u = Re("data_table", rt), $ = Je(), l = `$${u}_selection$`, C = P(() => {
313
313
  var e;
314
- return ((e = l.actionCol) == null ? void 0 : e.id) ?? `$${u}_action$`;
314
+ return ((e = s.actionCol) == null ? void 0 : e.id) ?? `$${u}_action$`;
315
315
  }), W = (e) => Be(e ?? {}, "title", "sorter", "columns", "id", "dataIndex"), O = P(() => {
316
316
  var h;
317
317
  const e = (n) => {
318
318
  var j;
319
319
  const S = n.id ?? nt(`${u}--col`);
320
- return re(be(n, l.childrenColumnName)) ? $.group({
320
+ return se(be(n, s.childrenColumnName)) ? $.group({
321
321
  header: n.title,
322
322
  id: S,
323
- columns: (j = be(n, l.childrenColumnName) ?? []) == null ? void 0 : j.map(e),
323
+ columns: (j = be(n, s.childrenColumnName) ?? []) == null ? void 0 : j.map(e),
324
324
  enableSorting: !1,
325
325
  ...W(n)
326
326
  }) : $.accessor(n.dataIndex ?? n.id, {
327
327
  header: n.title,
328
328
  id: S,
329
- sortingFn: typeof n.sorter == "function" ? (ne, We) => n.sorter(ne.original, We.original) : n.sorter,
329
+ sortingFn: typeof n.sorter == "function" ? (oe, We) => n.sorter(oe.original, We.original) : n.sorter,
330
330
  enableSorting: !!n.sorter,
331
331
  ...W(n)
332
332
  });
333
333
  };
334
- if (!re(l.columns)) throw "no columns";
335
- const i = l.columns.map(({ id: n }) => n);
336
- if (ct(i).length !== i.length) throw "no uniq column ids";
337
- const r = [];
338
- return l.rowSelection && l.rowKey && r.push(
339
- $.accessor(s, {
340
- id: s,
334
+ if (!se(s.columns)) throw "no columns";
335
+ const r = s.columns.map(({ id: n }) => n);
336
+ if (ct(r).length !== r.length) throw "no uniq column ids";
337
+ const i = [];
338
+ return s.rowSelection && s.rowKey && i.push(
339
+ $.accessor(l, {
340
+ id: l,
341
341
  enableSorting: !1
342
342
  })
343
- ), l.columns.forEach((n) => {
344
- r.push(e(n));
345
- }), (b.action || b.hoverAction) && r.push(
343
+ ), s.columns.forEach((n) => {
344
+ i.push(e(n));
345
+ }), (b.action || b.hoverAction) && i.push(
346
346
  $.accessor(C.value, {
347
347
  id: C.value,
348
- header: (h = l.actionCol) == null ? void 0 : h.title,
348
+ header: (h = s.actionCol) == null ? void 0 : h.title,
349
349
  enableSorting: !1,
350
- ...W(l.actionCol)
350
+ ...W(s.actionCol)
351
351
  })
352
- ), r;
353
- }), { toggleWrap: ce, isColumnWrapped: x } = Tt(l), o = Q({}), c = P(() => Object.keys(o.value)), m = P(
354
- () => l.rowKey ? Qe(l.data, (e) => e.children).map(
355
- (e) => e[l.rowKey]
352
+ ), i;
353
+ }), { toggleWrap: ce, isColumnWrapped: Y } = Tt(s), o = Q({}), c = P(() => Object.keys(o.value)), m = P(
354
+ () => s.rowKey ? Qe(s.data, (e) => e.children).map(
355
+ (e) => e[s.rowKey]
356
356
  ) : []
357
357
  ), y = () => {
358
358
  const e = Object.fromEntries(
359
- c.value.filter((i) => {
360
- var r;
361
- return !((r = l.rowSelection) != null && r.preserveSelectedRowKeys) && l.rowKey ? m.value.includes(i) : !0;
362
- }).map((i) => [i, !0])
359
+ c.value.filter((r) => {
360
+ var i;
361
+ return !((i = s.rowSelection) != null && i.preserveSelectedRowKeys) && s.rowKey ? m.value.includes(r) : !0;
362
+ }).map((r) => [r, !0])
363
363
  );
364
- Object.keys(e).length !== c.value.length && (o.value = e, se(() => {
365
- var i;
366
- V((i = l.rowSelection) == null ? void 0 : i.onChange) && l.rowSelection.onChange(E.value);
364
+ Object.keys(e).length !== c.value.length && (o.value = e, le(() => {
365
+ var r;
366
+ V((r = s.rowSelection) == null ? void 0 : r.onChange) && s.rowSelection.onChange(E.value);
367
367
  }));
368
- }, M = P(() => (y(), [...l.data])), L = at(), K = ut(
368
+ }, M = P(() => (y(), [...s.data])), L = at(), K = ut(
369
369
  Object.fromEntries(
370
370
  Object.keys(L).map((e) => [e, L[e].minWidth])
371
371
  ),
372
372
  { strategy: "min-width" }
373
373
  ).active(), F = Q({});
374
- X(
374
+ ae(
375
375
  K,
376
376
  (e) => {
377
377
  F.value = Object.fromEntries(
378
- O.value.map((i) => {
379
- var r;
378
+ O.value.map((r) => {
379
+ var i;
380
380
  return [
381
- i.id,
382
- re(i == null ? void 0 : i.responsive) ? (r = i.responsive) == null ? void 0 : r.includes(e) : !0
381
+ r.id,
382
+ se(r == null ? void 0 : r.responsive) ? (i = r.responsive) == null ? void 0 : i.includes(e) : !0
383
383
  ];
384
384
  })
385
385
  );
386
386
  },
387
387
  { immediate: !0 }
388
388
  );
389
- const q = Q([]), w = Xe({
389
+ const q = Q([]), k = Xe({
390
390
  // debugTable: true,
391
391
  getSubRows: (e) => e.children,
392
392
  enableSorting: !0,
@@ -412,6 +412,9 @@ const Tt = (B) => {
412
412
  get columns() {
413
413
  return O.value;
414
414
  },
415
+ getRowId(e, r) {
416
+ return s.rowKey ? e[s.rowKey] : r;
417
+ },
415
418
  getRowCanExpand: () => !0,
416
419
  getCoreRowModel: xe(),
417
420
  getSortedRowModel: Ye(),
@@ -420,24 +423,18 @@ const Tt = (B) => {
420
423
  }
421
424
  }), E = P(() => ({
422
425
  selectedRowKeys: c.value,
423
- selectedRows: w.getFilteredSelectedRowModel().flatRows.map((e) => e.original)
426
+ selectedRows: k.getFilteredSelectedRowModel().flatRows.map((e) => e.original)
424
427
  }));
425
- X(
426
- () => l.rowKey,
427
- () => {
428
- w._getRowId = l.rowKey ? (e) => e[l.rowKey] : void 0;
429
- },
430
- { immediate: !0 }
431
- ), X(
428
+ ae(
432
429
  () => {
433
430
  var e;
434
- return (e = l.rowSelection) == null ? void 0 : e.selectedRowKeys;
431
+ return (e = s.rowSelection) == null ? void 0 : e.selectedRowKeys;
435
432
  },
436
- (e, i) => {
437
- var r, h;
438
- if ((h = (r = l.rowSelection) == null ? void 0 : r.selectedRowKeys) != null && h.length && !Se(e, i)) {
433
+ (e, r) => {
434
+ var i, h;
435
+ if ((h = (i = s.rowSelection) == null ? void 0 : i.selectedRowKeys) != null && h.length && !Se(e, r)) {
439
436
  const n = Object.fromEntries(
440
- t(l.rowSelection.selectedRowKeys ?? Object.keys(o.value)).map(
437
+ t(s.rowSelection.selectedRowKeys ?? Object.keys(o.value)).map(
441
438
  (S) => [S, !0]
442
439
  )
443
440
  );
@@ -446,65 +443,65 @@ const Tt = (B) => {
446
443
  },
447
444
  { immediate: !0 }
448
445
  );
449
- const ee = P(() => w.getIsAllRowsSelected() ? !0 : w.getIsSomeRowsSelected() ? "indeterminate" : !1), te = (e) => {
450
- w.getIsSomeRowsSelected() || w.getIsAllRowsSelected() ? w.toggleAllRowsSelected(!1) : w.toggleAllRowsSelected(!0), se(() => {
451
- var i, r;
452
- V((i = l.rowSelection) == null ? void 0 : i.onSelectAll) && l.rowSelection.onSelectAll({ ...E.value, selected: e }), V((r = l.rowSelection) == null ? void 0 : r.onChange) && l.rowSelection.onChange(E.value);
446
+ const x = P(() => k.getIsAllRowsSelected() ? !0 : k.getIsSomeRowsSelected() ? "indeterminate" : !1), ee = (e) => {
447
+ k.getIsSomeRowsSelected() || k.getIsAllRowsSelected() ? k.toggleAllRowsSelected(!1) : k.toggleAllRowsSelected(!0), le(() => {
448
+ var r, i;
449
+ V((r = s.rowSelection) == null ? void 0 : r.onSelectAll) && s.rowSelection.onSelectAll({ ...E.value, selected: e }), V((i = s.rowSelection) == null ? void 0 : i.onChange) && s.rowSelection.onChange(E.value);
453
450
  });
454
- }, Ae = (e, i) => {
455
- var r;
456
- i.toggleSelected(e, {
457
- selectChildren: !((r = l.rowSelection) != null && r.checkStrictly)
458
- }), se(() => {
451
+ }, Ae = (e, r) => {
452
+ var i;
453
+ r.toggleSelected(e, {
454
+ selectChildren: !((i = s.rowSelection) != null && i.checkStrictly)
455
+ }), le(() => {
459
456
  var h, n;
460
- V((h = l.rowSelection) == null ? void 0 : h.onSelect) && l.rowSelection.onSelect({
457
+ V((h = s.rowSelection) == null ? void 0 : h.onSelect) && s.rowSelection.onSelect({
461
458
  ...E.value,
462
459
  selected: e,
463
- record: i.original
464
- }), V((n = l.rowSelection) == null ? void 0 : n.onChange) && l.rowSelection.onChange(E.value);
460
+ record: r.original
461
+ }), V((n = s.rowSelection) == null ? void 0 : n.onChange) && s.rowSelection.onChange(E.value);
465
462
  });
466
463
  }, Ie = (e) => {
467
- var i, r;
468
- return V((i = l.rowSelection) == null ? void 0 : i.getCheckboxProps) && ((r = l.rowSelection) == null || r.getCheckboxProps(e)), {};
464
+ var r, i;
465
+ return V((r = s.rowSelection) == null ? void 0 : r.getCheckboxProps) && ((i = s.rowSelection) == null || i.getCheckboxProps(e)), {};
469
466
  }, ue = (e) => {
470
- var i;
467
+ var r;
471
468
  if (e.getIsSelected()) return !0;
472
- if ((i = e.subRows) != null && i.length) {
469
+ if ((r = e.subRows) != null && r.length) {
473
470
  if (e.getIsAllSubRowsSelected()) return !0;
474
471
  if (e.getIsSomeSelected()) return "indeterminate";
475
472
  }
476
473
  return !1;
477
474
  }, de = Ne("target"), { stop: Te } = dt(de, ([e]) => {
478
- l.lazyLoading && !l.loading && (e != null && e.isIntersecting) && z("fetch");
475
+ s.lazyLoading && !s.loading && (e != null && e.isIntersecting) && z("fetch");
479
476
  });
480
477
  Oe(Te);
481
- const { getSkeletonProps: Pe, getThProps: Le, RenderCell: me, getTdProps: oe, getColProps: Me, isThVisible: Ve } = Bt(l, {
482
- selectionId: s,
483
- isColumnWrapped: x
478
+ const { getSkeletonProps: Pe, getThProps: Le, RenderCell: me, getTdProps: te, getColProps: Me, isThVisible: Ve } = Bt(s, {
479
+ selectionId: l,
480
+ isColumnWrapped: Y
484
481
  }), pe = P(() => Object.keys(o.value).length), De = () => {
485
482
  o.value = {};
486
483
  }, Ke = ze(u, {
487
484
  variants: {
488
485
  empty: He("empty", u)
489
486
  }
490
- }), fe = qe(0), Ee = ({ item: e }, i) => {
491
- e.key === "a-z" && i.toggleSorting(!1, !1), e.key === "z-a" && i.toggleSorting(!0, !1), e.key === "wrap" && ce({ id: i.id }), fe.value++;
487
+ }), fe = qe(0), Ee = ({ item: e }, r) => {
488
+ e.key === "a-z" && r.toggleSorting(!1, !1), e.key === "z-a" && r.toggleSorting(!0, !1), e.key === "wrap" && ce({ id: r.id }), fe.value++;
492
489
  }, je = (e) => {
493
- const i = e.getIsSorted();
494
- if (!i) return "tabler:arrows-up-down";
495
- if (i === "desc") return "tabler:arrow-down";
496
- if (i === "asc") return "tabler:arrow-up";
490
+ const r = e.getIsSorted();
491
+ if (!r) return "tabler:arrows-up-down";
492
+ if (r === "desc") return "tabler:arrow-down";
493
+ if (r === "asc") return "tabler:arrow-up";
497
494
  }, ge = P(
498
- () => w.getHeaderGroups().map((e) => ({
495
+ () => k.getHeaderGroups().map((e) => ({
499
496
  ...e,
500
- headers: e.headers.map((i) => ({
501
- ...i,
502
- bindings: Le(i.getContext())
497
+ headers: e.headers.map((r) => ({
498
+ ...r,
499
+ bindings: Le(r.getContext())
503
500
  }))
504
501
  }))
505
502
  );
506
- return (e, i) => (a(), p("div", {
507
- class: g([t(k)(t(u), "root"), e.rootCls])
503
+ return (e, r) => (a(), p("div", {
504
+ class: g([t(w)(t(u), "root"), e.rootCls])
508
505
  }, [
509
506
  f(ve, {
510
507
  "z-index": "1",
@@ -537,10 +534,10 @@ const Tt = (B) => {
537
534
  ]),
538
535
  default: d(() => [
539
536
  v("div", {
540
- class: g([t(k)(t(u), "scroll_area"), e.scrollAreaCls])
537
+ class: g([t(w)(t(u), "scroll_area"), e.scrollAreaCls])
541
538
  }, [
542
539
  v("div", {
543
- class: g([t(k)(t(u), "scroll_viewport"), e.scrollViewportCls])
540
+ class: g([t(w)(t(u), "scroll_viewport"), e.scrollViewportCls])
544
541
  }, [
545
542
  f(t(gt), {
546
543
  size: e.size,
@@ -549,17 +546,17 @@ const Tt = (B) => {
549
546
  }),
550
547
  class: g([
551
548
  t(Ke)({
552
- empty: !t(w).getRowModel().rows.length
549
+ empty: !t(k).getRowModel().rows.length
553
550
  }),
554
- l.class
551
+ s.class
555
552
  ])
556
553
  }, {
557
554
  default: d(() => [
558
555
  v("colgroup", null, [
559
- (a(!0), p(A, null, Z(t(w).getVisibleLeafColumns(), (r, h) => (a(), p("col", I({
560
- key: r.id,
556
+ (a(!0), p(A, null, Z(t(k).getVisibleLeafColumns(), (i, h) => (a(), p("col", I({
557
+ key: i.id,
561
558
  ref_for: !0
562
- }, t(Me)(r)), null, 16))), 128))
559
+ }, t(Me)(i)), null, 16))), 128))
563
560
  ]),
564
561
  e.noHeader ? R("", !0) : (a(), T(t(Ct), {
565
562
  key: 0,
@@ -567,29 +564,29 @@ const Tt = (B) => {
567
564
  sticky: e.stickyHeader
568
565
  }, {
569
566
  default: d(() => [
570
- (a(!0), p(A, null, Z(ge.value, (r, h) => (a(), T(t(G), {
571
- key: r.id
567
+ (a(!0), p(A, null, Z(ge.value, (i, h) => (a(), T(t(G), {
568
+ key: i.id
572
569
  }, {
573
570
  default: d(() => [
574
- (a(!0), p(A, null, Z(r.headers, (n) => (a(), p(A, {
571
+ (a(!0), p(A, null, Z(i.headers, (n) => (a(), p(A, {
575
572
  key: n.id
576
573
  }, [
577
574
  t(Ve)(h, ge.value.length, n.column.id) ? (a(), T(t(yt), I({
578
575
  key: 0,
579
576
  ref_for: !0
580
577
  }, n.bindings, {
581
- "data-selection": n.column.id === s
578
+ "data-selection": n.column.id === l
582
579
  }), {
583
580
  default: d(() => [
584
581
  v("div", {
585
- class: g(t(k)(t(u), "header"))
582
+ class: g(t(w)(t(u), "header"))
586
583
  }, [
587
584
  v("div", {
588
- class: g(t(k)(t(u), "header__content"))
585
+ class: g(t(w)(t(u), "header__content"))
589
586
  }, [
590
- n.column.id !== s ? (a(), p(A, { key: 0 }, [
587
+ n.column.id !== l ? (a(), p(A, { key: 0 }, [
591
588
  v("div", {
592
- class: g(t(k)(t(u), "header__content__title"))
589
+ class: g(t(w)(t(u), "header__content__title"))
593
590
  }, [
594
591
  H(e.$slots, "headerCell", I({ ref_for: !0 }, {
595
592
  column: n.column.columnDef
@@ -615,18 +612,18 @@ const Tt = (B) => {
615
612
  }, null, 8, ["class", "icon", "active", "onClick"])) : R("", !0)
616
613
  ], 64)) : (a(), p(A, { key: 1 }, [
617
614
  v("div", {
618
- class: g(t(k)(t(u), "selection_space"))
615
+ class: g(t(w)(t(u), "selection_space"))
619
616
  }, null, 2),
620
617
  f(ye, {
621
618
  rootCls: "w-fit",
622
- checked: ee.value,
623
- onChange: te
619
+ checked: x.value,
620
+ onChange: ee
624
621
  }, null, 8, ["checked"])
625
622
  ], 64))
626
623
  ], 2),
627
- ![C.value, s].includes(n.column.id) && !n.column.columns.length ? (a(), p("div", {
624
+ ![C.value, l].includes(n.column.id) && !n.column.columns.length ? (a(), p("div", {
628
625
  key: 0,
629
- class: g(t(k)(t(u), "header__action"))
626
+ class: g(t(w)(t(u), "header__action"))
630
627
  }, [
631
628
  (a(), T(ve, {
632
629
  "z-index": "1",
@@ -639,24 +636,24 @@ const Tt = (B) => {
639
636
  }, {
640
637
  default: d(() => [
641
638
  n.column.getCanSort() ? (a(), p(A, { key: 0 }, [
642
- f(ie, {
639
+ f(re, {
643
640
  title: "Sort A → Z",
644
641
  key: "a-z"
645
642
  }, {
646
643
  leading: d(({ iconSize: S }) => [
647
- f(Y, {
644
+ f(X, {
648
645
  icon: "tabler:arrow-up",
649
646
  size: S
650
647
  }, null, 8, ["size"])
651
648
  ]),
652
649
  _: 1
653
650
  }),
654
- f(ie, {
651
+ f(re, {
655
652
  title: "Sort Z → A",
656
653
  key: "z-a"
657
654
  }, {
658
655
  leading: d(({ iconSize: S }) => [
659
- f(Y, {
656
+ f(X, {
660
657
  icon: "tabler:arrow-down",
661
658
  size: S
662
659
  }, null, 8, ["size"])
@@ -665,19 +662,19 @@ const Tt = (B) => {
665
662
  }),
666
663
  f(we)
667
664
  ], 64)) : R("", !0),
668
- f(ie, {
665
+ f(re, {
669
666
  title: "Wrap Column",
670
667
  key: "wrap"
671
668
  }, {
672
669
  leading: d(({ iconSize: S }) => [
673
- f(Y, {
670
+ f(X, {
674
671
  icon: "tabler:text-wrap",
675
672
  size: S
676
673
  }, null, 8, ["size"])
677
674
  ]),
678
675
  trailing: d(() => [
679
676
  f(ft, {
680
- checked: t(x)(n.column.id)
677
+ checked: t(Y)(n.column.id)
681
678
  }, null, 8, ["checked"])
682
679
  ]),
683
680
  _: 2
@@ -692,7 +689,7 @@ const Tt = (B) => {
692
689
  size: "sm",
693
690
  color: "gray",
694
691
  type: "ghost",
695
- class: g(t(k)(t(u), "header__action__hover"))
692
+ class: g(t(w)(t(u), "header__action__hover"))
696
693
  }, null, 8, ["class"])
697
694
  ]),
698
695
  _: 2
@@ -713,34 +710,34 @@ const Tt = (B) => {
713
710
  class: g(e.tbodyCls)
714
711
  }, {
715
712
  default: d(() => [
716
- (a(!0), p(A, null, Z(t(w).getRowModel().rows, (r, h) => (a(), T(t(G), {
717
- key: r.id,
713
+ (a(!0), p(A, null, Z(t(k).getRowModel().rows, (i, h) => (a(), T(t(G), {
714
+ key: i.id,
718
715
  zebra: e.zebra,
719
- checked: !!ue(r)
716
+ checked: !!ue(i)
720
717
  }, {
721
718
  default: d(() => [
722
- (a(!0), p(A, null, Z(r.getVisibleCells(), (n) => {
719
+ (a(!0), p(A, null, Z(i.getVisibleCells(), (n) => {
723
720
  var S, j;
724
721
  return a(), p(A, {
725
722
  key: n.id
726
723
  }, [
727
- ((S = t(oe)(n.getContext())) == null ? void 0 : S.colSpan) !== 0 && ((j = t(oe)(n.getContext())) == null ? void 0 : j.rowSpan) !== 0 ? (a(), T(t(U), I({
724
+ ((S = t(te)(n.getContext())) == null ? void 0 : S.colSpan) !== 0 && ((j = t(te)(n.getContext())) == null ? void 0 : j.rowSpan) !== 0 ? (a(), T(t(U), I({
728
725
  key: 0,
729
726
  ref_for: !0
730
- }, t(oe)(n.getContext())), Ce({
727
+ }, t(te)(n.getContext())), Ce({
731
728
  default: d(() => [
732
729
  n.column.id === C.value && (b.hoverAction || b.action) ? (a(), p("div", {
733
730
  key: 0,
734
- class: g(t(k)(t(u), "action_cell"))
731
+ class: g(t(w)(t(u), "action_cell"))
735
732
  }, [
736
733
  v("div", {
737
- class: g([t(k)(t(u), "action_cell__hover"), e.actionHoverCls])
734
+ class: g([t(w)(t(u), "action_cell__hover"), e.actionHoverCls])
738
735
  }, [
739
736
  H(e.$slots, "hoverAction", I(
740
737
  { ref_for: !0 },
741
738
  {
742
739
  column: n.column.columnDef,
743
- record: r.original,
740
+ record: i.original,
744
741
  index: h
745
742
  }
746
743
  ))
@@ -749,18 +746,18 @@ const Tt = (B) => {
749
746
  { ref_for: !0 },
750
747
  {
751
748
  column: n.column.columnDef,
752
- record: r.original,
749
+ record: i.original,
753
750
  index: h
754
751
  }
755
752
  ))
756
- ], 2)) : n.column.id !== s ? H(e.$slots, "bodyCell", I(
753
+ ], 2)) : n.column.id !== l ? H(e.$slots, "bodyCell", I(
757
754
  {
758
755
  key: 1,
759
756
  ref_for: !0
760
757
  },
761
758
  {
762
759
  column: n.column.columnDef,
763
- record: r.original,
760
+ record: i.original,
764
761
  index: h
765
762
  }
766
763
  ), () => [
@@ -768,29 +765,29 @@ const Tt = (B) => {
768
765
  render: n.column.columnDef.cell,
769
766
  props: n.getContext()
770
767
  }, null, 8, ["render", "props"])
771
- ]) : e.rowKey && r.original[e.rowKey] ? (a(), p("div", Pt, [
768
+ ]) : e.rowKey && i.original[e.rowKey] ? (a(), p("div", Pt, [
772
769
  v("div", {
773
- class: g(t(k)(t(u), "selection_space"))
770
+ class: g(t(w)(t(u), "selection_space"))
774
771
  }, null, 2),
775
772
  f(ye, I({
776
773
  rootCls: "w-fit",
777
- disabled: !r.getCanSelect(),
778
- checked: ue(r),
779
- onChange: (ne) => Ae(ne, r),
774
+ disabled: !i.getCanSelect(),
775
+ checked: ue(i),
776
+ onChange: (oe) => Ae(oe, i),
780
777
  ref_for: !0
781
- }, Ie(r.original)), null, 16, ["disabled", "checked", "onChange"])
778
+ }, Ie(i.original)), null, 16, ["disabled", "checked", "onChange"])
782
779
  ])) : R("", !0)
783
780
  ]),
784
781
  _: 2
785
782
  }, [
786
- b.cellAction && ![C.value, s].includes(n.column.id) ? {
783
+ b.cellAction && ![C.value, l].includes(n.column.id) ? {
787
784
  name: "absoluteAction",
788
785
  fn: d(() => [
789
786
  H(e.$slots, "cellAction", I(
790
787
  { ref_for: !0 },
791
788
  {
792
789
  column: n.column.columnDef,
793
- record: r.original,
790
+ record: i.original,
794
791
  index: h
795
792
  }
796
793
  ))
@@ -803,14 +800,14 @@ const Tt = (B) => {
803
800
  ]),
804
801
  _: 2
805
802
  }, 1032, ["zebra", "checked"]))), 128)),
806
- l.loading ? (a(!0), p(A, { key: 0 }, Z(t(w).getRowModel().rows.length ? 2 : e.loadingRowCount, (r) => (a(), T(t(G), {
807
- key: r,
803
+ s.loading ? (a(!0), p(A, { key: 0 }, Z(t(k).getRowModel().rows.length ? 2 : e.loadingRowCount, (i) => (a(), T(t(G), {
804
+ key: i,
808
805
  zebra: e.zebra
809
806
  }, {
810
807
  default: d(() => [
811
- (a(!0), p(A, null, Z(t(w).getVisibleLeafColumns(), (h, n) => (a(), T(t(U), { key: n }, {
808
+ (a(!0), p(A, null, Z(t(k).getVisibleLeafColumns(), (h, n) => (a(), T(t(U), { key: n }, {
812
809
  default: d(() => [
813
- h.id !== s ? H(e.$slots, "skeleton", I({
810
+ h.id !== l ? H(e.$slots, "skeleton", I({
814
811
  key: 0,
815
812
  ref_for: !0
816
813
  }, { index: n, column: h.columnDef }), () => [
@@ -822,13 +819,13 @@ const Tt = (B) => {
822
819
  ]),
823
820
  _: 2
824
821
  }, 1032, ["zebra"]))), 128)) : R("", !0),
825
- t(w).getRowModel().rows.length ? R("", !0) : (a(), T(t(G), {
822
+ t(k).getRowModel().rows.length ? R("", !0) : (a(), T(t(G), {
826
823
  key: 1,
827
824
  empty: ""
828
825
  }, {
829
826
  default: d(() => [
830
827
  f(t(U), {
831
- colspan: t(w).getVisibleLeafColumns().length,
828
+ colspan: t(k).getVisibleLeafColumns().length,
832
829
  empty: ""
833
830
  }, {
834
831
  default: d(() => [