@sken-ds/primitives 0.4.3 → 0.5.0
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.js +9 -9
- package/dist/rolldown-runtime-BRfZIaNm.js +17 -0
- package/dist/sken-button.js +2 -2
- package/dist/sken-button.js.map +1 -1
- package/dist/sken-combobox.js +56 -65
- package/dist/sken-combobox.js.map +1 -1
- package/dist/{sken-datatable-ChDjB_T_.js → sken-datatable-jx_jh1Fu.js} +157 -217
- package/dist/sken-datatable-jx_jh1Fu.js.map +1 -0
- package/dist/sken-datatable.js +1 -1
- package/dist/sken-dialog.js +241 -2
- package/dist/sken-dialog.js.map +1 -0
- package/dist/sken-input.js +3 -3
- package/dist/sken-input.js.map +1 -1
- package/dist/sken-layout.js +4 -10
- package/dist/sken-layout.js.map +1 -1
- package/dist/sken-number-input.js +6 -3
- package/dist/sken-number-input.js.map +1 -1
- package/dist/sken-textarea.js +2 -2
- package/dist/sken-textarea.js.map +1 -1
- package/package.json +7 -5
- package/dist/directive-BcLtPdVO.js +0 -263
- package/dist/directive-BcLtPdVO.js.map +0 -1
- package/dist/sken-datatable-ChDjB_T_.js.map +0 -1
- package/dist/sken-dialog-BvRZxwSk.js +0 -258
- package/dist/sken-dialog-BvRZxwSk.js.map +0 -1
|
@@ -1,46 +1,30 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { LitElement as
|
|
4
|
-
import { customElement as
|
|
5
|
-
import { constructTable as
|
|
6
|
-
import * as
|
|
7
|
-
import { table_publishExternalState as
|
|
8
|
-
//#region \0rolldown/runtime.js
|
|
9
|
-
var p = Object.defineProperty, ie = Object.getOwnPropertyDescriptor, ae = Object.getOwnPropertyNames, m = Object.prototype.hasOwnProperty, h = (e, t) => {
|
|
10
|
-
let n = {};
|
|
11
|
-
for (var r in e) p(n, r, {
|
|
12
|
-
get: e[r],
|
|
13
|
-
enumerable: !0
|
|
14
|
-
});
|
|
15
|
-
return t || p(n, Symbol.toStringTag, { value: "Module" }), n;
|
|
16
|
-
}, g = (e, t, n, r) => {
|
|
17
|
-
if (t && typeof t == "object" || typeof t == "function") for (var i = ae(t), a = 0, o = i.length, s; a < o; a++) s = i[a], !m.call(e, s) && s !== n && p(e, s, {
|
|
18
|
-
get: ((e) => t[e]).bind(null, s),
|
|
19
|
-
enumerable: !(r = ie(t, s)) || r.enumerable
|
|
20
|
-
});
|
|
21
|
-
return e;
|
|
22
|
-
}, oe = (e, t, n) => (g(e, t, "default"), n && g(n, t, "default"));
|
|
23
|
-
//#endregion
|
|
1
|
+
import { n as e, t } from "./rolldown-runtime-BRfZIaNm.js";
|
|
2
|
+
import { t as n } from "./decorate-D4FKzyDw.js";
|
|
3
|
+
import { LitElement as r, css as i, html as a, noChange as o, nothing as s } from "lit";
|
|
4
|
+
import { customElement as c, property as l } from "lit/decorators.js";
|
|
5
|
+
import { constructTable as u, createColumnHelper as d } from "@tanstack/table-core";
|
|
6
|
+
import * as f from "@tanstack/table-core/static-functions";
|
|
7
|
+
import { table_publishExternalState as ee, table_setOptions as te } from "@tanstack/table-core/static-functions";
|
|
24
8
|
//#region ../../node_modules/.pnpm/@tanstack+lit-table@9.0.0_@lit+context@1.1.6_lit@3.3.3/node_modules/@tanstack/lit-table/dist/flexRender.js
|
|
25
|
-
function
|
|
9
|
+
function p(e, t) {
|
|
26
10
|
return e == null ? null : typeof e == "function" ? e(t) : e;
|
|
27
11
|
}
|
|
28
|
-
function
|
|
12
|
+
function m(e) {
|
|
29
13
|
if ("cell" in e && e.cell) {
|
|
30
14
|
let t = e.cell, n = t.column.columnDef, r = t, i = n;
|
|
31
|
-
return r.getIsAggregated?.() ?
|
|
15
|
+
return r.getIsAggregated?.() ? p(i.aggregatedCell ?? n.cell, t.getContext()) : r.getIsPlaceholder?.() ? null : p(n.cell, t.getContext());
|
|
32
16
|
}
|
|
33
|
-
return "header" in e && e.header ?
|
|
17
|
+
return "header" in e && e.header ? p(e.header.column.columnDef.header, e.header.getContext()) : "footer" in e && e.footer ? p(e.footer.column.columnDef.footer, e.footer.getContext()) : null;
|
|
34
18
|
}
|
|
35
19
|
//#endregion
|
|
36
20
|
//#region ../../node_modules/.pnpm/@tanstack+lit-store@0.14.0_lit@3.3.3/node_modules/@tanstack/lit-store/dist/tan-stack-store-selector.js
|
|
37
|
-
function
|
|
21
|
+
function ne(e, t) {
|
|
38
22
|
return e === t;
|
|
39
23
|
}
|
|
40
|
-
function
|
|
24
|
+
function h(e) {
|
|
41
25
|
return e;
|
|
42
26
|
}
|
|
43
|
-
var
|
|
27
|
+
var g = class {
|
|
44
28
|
#e;
|
|
45
29
|
#t;
|
|
46
30
|
#n;
|
|
@@ -49,8 +33,8 @@ var le = class {
|
|
|
49
33
|
#a;
|
|
50
34
|
#o = !1;
|
|
51
35
|
#s;
|
|
52
|
-
constructor(e, t, n =
|
|
53
|
-
this.#e = e, this.#t = t, this.#n = n, this.#r = r?.compare ??
|
|
36
|
+
constructor(e, t, n = h, r) {
|
|
37
|
+
this.#e = e, this.#t = t, this.#n = n, this.#r = r?.compare ?? ne, e.addController(this);
|
|
54
38
|
}
|
|
55
39
|
get value() {
|
|
56
40
|
return this.#s;
|
|
@@ -71,11 +55,11 @@ var le = class {
|
|
|
71
55
|
hostDisconnected() {
|
|
72
56
|
this.#i?.(), this.#i = void 0, this.#a = void 0, this.#o = !1, this.#s = void 0;
|
|
73
57
|
}
|
|
74
|
-
},
|
|
58
|
+
}, _ = /* @__PURE__ */ function(e) {
|
|
75
59
|
return e[e.None = 0] = "None", e[e.Mutable = 1] = "Mutable", e[e.Watching = 2] = "Watching", e[e.RecursedCheck = 4] = "RecursedCheck", e[e.Recursed = 8] = "Recursed", e[e.Dirty = 16] = "Dirty", e[e.Pending = 32] = "Pending", e;
|
|
76
60
|
}({});
|
|
77
61
|
/* @__NO_SIDE_EFFECTS__ */
|
|
78
|
-
function
|
|
62
|
+
function re({ update: e, notify: t, unwatched: n }) {
|
|
79
63
|
return {
|
|
80
64
|
link: r,
|
|
81
65
|
unlink: i,
|
|
@@ -112,7 +96,7 @@ function ue({ update: e, notify: t, unwatched: n }) {
|
|
|
112
96
|
let n = e.nextSub, r;
|
|
113
97
|
top: do {
|
|
114
98
|
let i = e.sub, a = i.flags;
|
|
115
|
-
if (a & (
|
|
99
|
+
if (a & (_.RecursedCheck | _.Recursed | _.Dirty | _.Pending) ? a & (_.RecursedCheck | _.Recursed) ? a & _.RecursedCheck ? !(a & (_.Dirty | _.Pending)) && c(e, i) ? (i.flags = a | (_.Recursed | _.Pending), a &= _.Mutable) : a = _.None : i.flags = a & ~_.Recursed | _.Pending : a = _.None : i.flags = a | _.Pending, a & _.Watching && t(i), a & _.Mutable) {
|
|
116
100
|
let t = i.subs;
|
|
117
101
|
if (t !== void 0) {
|
|
118
102
|
let i = (e = t).nextSub;
|
|
@@ -138,13 +122,13 @@ function ue({ update: e, notify: t, unwatched: n }) {
|
|
|
138
122
|
let r, i = 0, a = !1;
|
|
139
123
|
top: do {
|
|
140
124
|
let o = t.dep, c = o.flags;
|
|
141
|
-
if (n.flags &
|
|
142
|
-
else if ((c & (
|
|
125
|
+
if (n.flags & _.Dirty) a = !0;
|
|
126
|
+
else if ((c & (_.Mutable | _.Dirty)) === (_.Mutable | _.Dirty)) {
|
|
143
127
|
if (e(o)) {
|
|
144
128
|
let e = o.subs;
|
|
145
129
|
e.nextSub !== void 0 && s(e), a = !0;
|
|
146
130
|
}
|
|
147
|
-
} else if ((c & (
|
|
131
|
+
} else if ((c & (_.Mutable | _.Pending)) === (_.Mutable | _.Pending)) {
|
|
148
132
|
(t.nextSub !== void 0 || t.prevSub !== void 0) && (r = {
|
|
149
133
|
value: t,
|
|
150
134
|
prev: r
|
|
@@ -166,7 +150,7 @@ function ue({ update: e, notify: t, unwatched: n }) {
|
|
|
166
150
|
continue;
|
|
167
151
|
}
|
|
168
152
|
a = !1;
|
|
169
|
-
} else n.flags &= ~
|
|
153
|
+
} else n.flags &= ~_.Pending;
|
|
170
154
|
n = t.sub;
|
|
171
155
|
let c = t.nextDep;
|
|
172
156
|
if (c !== void 0) {
|
|
@@ -180,7 +164,7 @@ function ue({ update: e, notify: t, unwatched: n }) {
|
|
|
180
164
|
function s(e) {
|
|
181
165
|
do {
|
|
182
166
|
let n = e.sub, r = n.flags;
|
|
183
|
-
(r & (
|
|
167
|
+
(r & (_.Pending | _.Dirty)) === _.Pending && (n.flags = r | _.Dirty, (r & (_.Watching | _.RecursedCheck)) === _.Watching && t(n));
|
|
184
168
|
} while ((e = e.nextSub) !== void 0);
|
|
185
169
|
}
|
|
186
170
|
function c(e, t) {
|
|
@@ -194,7 +178,7 @@ function ue({ update: e, notify: t, unwatched: n }) {
|
|
|
194
178
|
}
|
|
195
179
|
//#endregion
|
|
196
180
|
//#region ../../node_modules/.pnpm/@tanstack+store@0.11.0/node_modules/@tanstack/store/dist/atom.js
|
|
197
|
-
function
|
|
181
|
+
function v(e, t, n) {
|
|
198
182
|
let r = typeof e == "object", i = r ? e : void 0;
|
|
199
183
|
return {
|
|
200
184
|
next: (r ? e.next : e)?.bind(i),
|
|
@@ -202,50 +186,50 @@ function de(e, t, n) {
|
|
|
202
186
|
complete: (r ? e.complete : n)?.bind(i)
|
|
203
187
|
};
|
|
204
188
|
}
|
|
205
|
-
var
|
|
189
|
+
var y = [], b = 0, { link: x, unlink: S, propagate: C, checkDirty: w, shallowPropagate: T } = /* @__PURE__ */ re({
|
|
206
190
|
update(e) {
|
|
207
191
|
return e._update();
|
|
208
192
|
},
|
|
209
193
|
notify(e) {
|
|
210
|
-
|
|
194
|
+
y[D++] = e, e.flags &= ~_.Watching;
|
|
211
195
|
},
|
|
212
196
|
unwatched(e) {
|
|
213
|
-
e.depsTail !== void 0 && (e.depsTail = void 0, e.flags =
|
|
197
|
+
e.depsTail !== void 0 && (e.depsTail = void 0, e.flags = _.Mutable | _.Dirty, A(e));
|
|
214
198
|
}
|
|
215
|
-
}),
|
|
216
|
-
function
|
|
199
|
+
}), E = 0, D = 0, O, k = 0;
|
|
200
|
+
function ie(e) {
|
|
217
201
|
try {
|
|
218
|
-
++
|
|
202
|
+
++k, e();
|
|
219
203
|
} finally {
|
|
220
|
-
--
|
|
204
|
+
--k || j();
|
|
221
205
|
}
|
|
222
206
|
}
|
|
223
|
-
function
|
|
207
|
+
function A(e) {
|
|
224
208
|
let t = e.depsTail, n = t === void 0 ? e.deps : t.nextDep;
|
|
225
|
-
for (; n !== void 0;) n =
|
|
209
|
+
for (; n !== void 0;) n = S(n, e);
|
|
226
210
|
}
|
|
227
|
-
function
|
|
228
|
-
if (!(
|
|
229
|
-
for (;
|
|
230
|
-
let e =
|
|
231
|
-
|
|
211
|
+
function j() {
|
|
212
|
+
if (!(k > 0)) {
|
|
213
|
+
for (; E < D;) {
|
|
214
|
+
let e = y[E];
|
|
215
|
+
y[E++] = void 0, e.notify();
|
|
232
216
|
}
|
|
233
|
-
|
|
217
|
+
E = 0, D = 0;
|
|
234
218
|
}
|
|
235
219
|
}
|
|
236
|
-
function
|
|
220
|
+
function M(e, t) {
|
|
237
221
|
let n = typeof e == "function", r = e, i = {
|
|
238
222
|
_snapshot: n ? void 0 : e,
|
|
239
223
|
subs: void 0,
|
|
240
224
|
subsTail: void 0,
|
|
241
225
|
deps: void 0,
|
|
242
226
|
depsTail: void 0,
|
|
243
|
-
flags: n ?
|
|
227
|
+
flags: n ? _.None : _.Mutable,
|
|
244
228
|
get() {
|
|
245
|
-
return
|
|
229
|
+
return O !== void 0 && x(i, O, b), i._snapshot;
|
|
246
230
|
},
|
|
247
231
|
subscribe(e) {
|
|
248
|
-
let t =
|
|
232
|
+
let t = v(e), n = { current: !1 }, r = N(() => {
|
|
249
233
|
i.get(), n.current ? t.next?.(i._snapshot) : n.current = !0;
|
|
250
234
|
});
|
|
251
235
|
return { unsubscribe: () => {
|
|
@@ -253,62 +237,62 @@ function pe(e, t) {
|
|
|
253
237
|
} };
|
|
254
238
|
},
|
|
255
239
|
_update(e) {
|
|
256
|
-
let a =
|
|
257
|
-
if (n)
|
|
240
|
+
let a = O, o = t?.compare ?? Object.is;
|
|
241
|
+
if (n) O = i, ++b, i.depsTail = void 0;
|
|
258
242
|
else if (e === void 0) return !1;
|
|
259
|
-
n && (i.flags =
|
|
243
|
+
n && (i.flags = _.Mutable | _.RecursedCheck);
|
|
260
244
|
try {
|
|
261
245
|
let t = i._snapshot, a = typeof e == "function" ? e(t) : e === void 0 && n ? r(t) : e;
|
|
262
246
|
return t === void 0 || !o(t, a) ? (i._snapshot = a, !0) : !1;
|
|
263
247
|
} finally {
|
|
264
|
-
|
|
248
|
+
O = a, n && (i.flags &= ~_.RecursedCheck), A(i);
|
|
265
249
|
}
|
|
266
250
|
}
|
|
267
251
|
};
|
|
268
|
-
return n ? (i.flags =
|
|
252
|
+
return n ? (i.flags = _.Mutable | _.Dirty, i.get = function() {
|
|
269
253
|
let e = i.flags;
|
|
270
|
-
if (e &
|
|
254
|
+
if (e & _.Dirty || e & _.Pending && w(i.deps, i)) {
|
|
271
255
|
if (i._update()) {
|
|
272
256
|
let e = i.subs;
|
|
273
|
-
e !== void 0 &&
|
|
257
|
+
e !== void 0 && T(e);
|
|
274
258
|
}
|
|
275
|
-
} else e &
|
|
276
|
-
return
|
|
259
|
+
} else e & _.Pending && (i.flags = e & ~_.Pending);
|
|
260
|
+
return O !== void 0 && x(i, O, b), i._snapshot;
|
|
277
261
|
}) : i.set = function(e) {
|
|
278
262
|
if (i._update(e)) {
|
|
279
263
|
let e = i.subs;
|
|
280
|
-
e !== void 0 && (
|
|
264
|
+
e !== void 0 && (C(e), T(e), j());
|
|
281
265
|
}
|
|
282
266
|
}, i;
|
|
283
267
|
}
|
|
284
|
-
function
|
|
268
|
+
function N(e) {
|
|
285
269
|
let t = () => {
|
|
286
|
-
let t =
|
|
287
|
-
|
|
270
|
+
let t = O;
|
|
271
|
+
O = n, ++b, n.depsTail = void 0, n.flags = _.Watching | _.RecursedCheck;
|
|
288
272
|
try {
|
|
289
273
|
return e();
|
|
290
274
|
} finally {
|
|
291
|
-
|
|
275
|
+
O = t, n.flags &= ~_.RecursedCheck, A(n);
|
|
292
276
|
}
|
|
293
277
|
}, n = {
|
|
294
278
|
deps: void 0,
|
|
295
279
|
depsTail: void 0,
|
|
296
280
|
subs: void 0,
|
|
297
281
|
subsTail: void 0,
|
|
298
|
-
flags:
|
|
282
|
+
flags: _.Watching | _.RecursedCheck,
|
|
299
283
|
notify() {
|
|
300
284
|
let e = this.flags;
|
|
301
|
-
e &
|
|
285
|
+
e & _.Dirty || e & _.Pending && w(this.deps, this) ? t() : this.flags = _.Watching;
|
|
302
286
|
},
|
|
303
287
|
stop() {
|
|
304
|
-
this.flags =
|
|
288
|
+
this.flags = _.None, this.depsTail = void 0, A(this);
|
|
305
289
|
}
|
|
306
290
|
};
|
|
307
291
|
return t(), n;
|
|
308
292
|
}
|
|
309
293
|
//#endregion
|
|
310
294
|
//#region ../../node_modules/.pnpm/@tanstack+store@0.11.0/node_modules/@tanstack/store/dist/shallow.js
|
|
311
|
-
function
|
|
295
|
+
function P(e, t) {
|
|
312
296
|
if (Object.is(e, t)) return !0;
|
|
313
297
|
if (typeof e != "object" || !e || typeof t != "object" || !t) return !1;
|
|
314
298
|
if (e instanceof Map && t instanceof Map) {
|
|
@@ -322,77 +306,33 @@ function N(e, t) {
|
|
|
322
306
|
return !0;
|
|
323
307
|
}
|
|
324
308
|
if (e instanceof Date && t instanceof Date) return e.getTime() === t.getTime();
|
|
325
|
-
let n =
|
|
326
|
-
if (n.length !==
|
|
309
|
+
let n = F(e);
|
|
310
|
+
if (n.length !== F(t).length) return !1;
|
|
327
311
|
for (let r = 0; r < n.length; r++) if (!Object.prototype.hasOwnProperty.call(t, n[r]) || !Object.is(e[n[r]], t[n[r]])) return !1;
|
|
328
312
|
return !0;
|
|
329
313
|
}
|
|
330
|
-
function
|
|
314
|
+
function F(e) {
|
|
331
315
|
return Object.keys(e).concat(Object.getOwnPropertySymbols(e));
|
|
332
316
|
}
|
|
333
317
|
//#endregion
|
|
334
|
-
//#region ../../node_modules/.pnpm/lit
|
|
335
|
-
var
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
let t, n;
|
|
342
|
-
do {
|
|
343
|
-
if ((t = e._$AM) === void 0) break;
|
|
344
|
-
n = t._$AN, n.delete(e), e = t;
|
|
345
|
-
} while (n?.size === 0);
|
|
346
|
-
}, R = (e) => {
|
|
347
|
-
for (let t; t = e._$AM; e = t) {
|
|
348
|
-
let n = t._$AN;
|
|
349
|
-
if (n === void 0) t._$AN = n = /* @__PURE__ */ new Set();
|
|
350
|
-
else if (n.has(e)) break;
|
|
351
|
-
n.add(e), _e(t);
|
|
352
|
-
}
|
|
353
|
-
};
|
|
354
|
-
function z(e) {
|
|
355
|
-
this._$AN === void 0 ? this._$AM = e : (L(this), this._$AM = e, R(this));
|
|
356
|
-
}
|
|
357
|
-
function ge(e, t = !1, n = 0) {
|
|
358
|
-
let r = this._$AH, i = this._$AN;
|
|
359
|
-
if (i !== void 0 && i.size !== 0) if (t) if (Array.isArray(r)) for (let e = n; e < r.length; e++) I(r[e], !1), L(r[e]);
|
|
360
|
-
else r != null && (I(r, !1), L(r));
|
|
361
|
-
else I(this, e);
|
|
362
|
-
}
|
|
363
|
-
var _e = (e) => {
|
|
364
|
-
e.type == r.CHILD && (e._$AP ??= ge, e._$AQ ??= z);
|
|
365
|
-
}, ve = class extends n {
|
|
366
|
-
constructor() {
|
|
367
|
-
super(...arguments), this._$AN = void 0;
|
|
368
|
-
}
|
|
369
|
-
_$AT(e, t, n) {
|
|
370
|
-
super._$AT(e, t, n), R(this), this.isConnected = e._$AU;
|
|
371
|
-
}
|
|
372
|
-
_$AO(e, t = !0) {
|
|
373
|
-
e !== this.isConnected && (this.isConnected = e, e ? this.reconnected?.() : this.disconnected?.()), t && (I(this, e), L(this));
|
|
374
|
-
}
|
|
375
|
-
setValue(e) {
|
|
376
|
-
if (F(this._$Ct)) this._$Ct._$AI(e, this);
|
|
377
|
-
else {
|
|
378
|
-
let t = [...this._$Ct._$AH];
|
|
379
|
-
t[this._$Ci] = e, this._$Ct._$AI(t, this, 0);
|
|
380
|
-
}
|
|
381
|
-
}
|
|
382
|
-
disconnected() {}
|
|
383
|
-
reconnected() {}
|
|
384
|
-
}, ye = (e) => e, B = class extends ve {
|
|
318
|
+
//#region ../../node_modules/.pnpm/lit@3.3.3/node_modules/lit/async-directive.js
|
|
319
|
+
var I = /* @__PURE__ */ t({});
|
|
320
|
+
import * as ae from "lit-html/async-directive.js";
|
|
321
|
+
e(I, ae);
|
|
322
|
+
//#endregion
|
|
323
|
+
//#region ../../node_modules/.pnpm/@tanstack+lit-table@9.0.0_@lit+context@1.1.6_lit@3.3.3/node_modules/@tanstack/lit-table/dist/subscribe-directive.js
|
|
324
|
+
var oe = (e) => e, L = class extends I.AsyncDirective {
|
|
385
325
|
controller;
|
|
386
326
|
latestSource;
|
|
387
327
|
latestSelector;
|
|
388
328
|
resolvedTemplate;
|
|
389
329
|
initialized = !1;
|
|
390
330
|
render(e, t, n) {
|
|
391
|
-
return
|
|
331
|
+
return o;
|
|
392
332
|
}
|
|
393
333
|
update(e, t) {
|
|
394
|
-
let [n, r, i] = t, a = i === void 0, o = a ?
|
|
395
|
-
return this.resolvedTemplate = s, u && (this.initialized && (this.controller?.hostDisconnected(), this.controller = void 0), this.latestSource = n, this.latestSelector = o, this.controller ||= new
|
|
334
|
+
let [n, r, i] = t, a = i === void 0, o = a ? oe : r, s = a ? r : i, c = this.latestSource !== n, l = this.latestSelector !== o, u = !this.initialized || c || l;
|
|
335
|
+
return this.resolvedTemplate = s, u && (this.initialized && (this.controller?.hostDisconnected(), this.controller = void 0), this.latestSource = n, this.latestSelector = o, this.controller ||= new g(this.createFakeHost(), () => this.latestSource, (e) => this.latestSelector?.(e)), this.controller.hostUpdate(), this.initialized = !0), this.resolvedTemplate?.(this.latestSelector(this.latestSource.get()));
|
|
396
336
|
}
|
|
397
337
|
disconnected() {
|
|
398
338
|
this.controller?.hostDisconnected();
|
|
@@ -412,10 +352,10 @@ var _e = (e) => {
|
|
|
412
352
|
}
|
|
413
353
|
};
|
|
414
354
|
}
|
|
415
|
-
},
|
|
355
|
+
}, R = (0, I.directive)(L);
|
|
416
356
|
//#endregion
|
|
417
357
|
//#region ../../node_modules/.pnpm/@tanstack+table-core@9.0.0/node_modules/@tanstack/table-core/dist/core/reactivity/renderPhaseReactivity.js
|
|
418
|
-
function
|
|
358
|
+
function z(e) {
|
|
419
359
|
let { createAtom: t, batch: n } = e, r = t(0);
|
|
420
360
|
return {
|
|
421
361
|
createOptionsStore: !1,
|
|
@@ -445,7 +385,7 @@ function be(e) {
|
|
|
445
385
|
}
|
|
446
386
|
};
|
|
447
387
|
}
|
|
448
|
-
function
|
|
388
|
+
function B(e, t = Object.is) {
|
|
449
389
|
let n = !1, r;
|
|
450
390
|
return {
|
|
451
391
|
get: e.get,
|
|
@@ -459,15 +399,15 @@ function xe(e, t = Object.is) {
|
|
|
459
399
|
}
|
|
460
400
|
//#endregion
|
|
461
401
|
//#region ../../node_modules/.pnpm/@tanstack+lit-table@9.0.0_@lit+context@1.1.6_lit@3.3.3/node_modules/@tanstack/lit-table/dist/reactivity.js
|
|
462
|
-
function
|
|
463
|
-
return
|
|
464
|
-
createAtom:
|
|
465
|
-
batch:
|
|
402
|
+
function V() {
|
|
403
|
+
return z({
|
|
404
|
+
createAtom: M,
|
|
405
|
+
batch: ie
|
|
466
406
|
});
|
|
467
407
|
}
|
|
468
408
|
//#endregion
|
|
469
409
|
//#region ../../node_modules/.pnpm/@tanstack+lit-table@9.0.0_@lit+context@1.1.6_lit@3.3.3/node_modules/@tanstack/lit-table/dist/TableController.js
|
|
470
|
-
var
|
|
410
|
+
var H = class {
|
|
471
411
|
host;
|
|
472
412
|
_table = null;
|
|
473
413
|
_rootSource;
|
|
@@ -485,7 +425,7 @@ var U = class {
|
|
|
485
425
|
let t = {
|
|
486
426
|
...e,
|
|
487
427
|
features: {
|
|
488
|
-
coreReactivityFeature:
|
|
428
|
+
coreReactivityFeature: V(),
|
|
489
429
|
...e.features
|
|
490
430
|
},
|
|
491
431
|
mergeOptions: (e, t) => ({
|
|
@@ -493,17 +433,17 @@ var U = class {
|
|
|
493
433
|
...t
|
|
494
434
|
})
|
|
495
435
|
};
|
|
496
|
-
this._table =
|
|
436
|
+
this._table = u(t), this._rootSource = B(this._table.store, P), this._setupSubscriptions();
|
|
497
437
|
}
|
|
498
|
-
|
|
438
|
+
te(this._table, (t) => ({
|
|
499
439
|
...t,
|
|
500
440
|
...e
|
|
501
441
|
}), { syncExternalState: !1 }), this._capturedState = this._table.options.state;
|
|
502
442
|
let n = this._rootSource.get();
|
|
503
443
|
return this._capturedSnapshot = n, this._hasSelector = t !== void 0, this._latestSelector = t, this._lastSelected = t ? t(n) : n, {
|
|
504
444
|
...this._table,
|
|
505
|
-
subscribe:
|
|
506
|
-
FlexRender:
|
|
445
|
+
subscribe: R,
|
|
446
|
+
FlexRender: m,
|
|
507
447
|
get state() {
|
|
508
448
|
return t?.(n) ?? n;
|
|
509
449
|
}
|
|
@@ -513,7 +453,7 @@ var U = class {
|
|
|
513
453
|
this._table && !this._storeSubscription && (this._storeSubscription = this._rootSource.subscribe((e) => {
|
|
514
454
|
if (this._hasSelector) {
|
|
515
455
|
let t = this._latestSelector(e);
|
|
516
|
-
if (
|
|
456
|
+
if (P(this._lastSelected, t)) return;
|
|
517
457
|
this._lastSelected = t;
|
|
518
458
|
}
|
|
519
459
|
this.host.requestUpdate();
|
|
@@ -523,12 +463,12 @@ var U = class {
|
|
|
523
463
|
this._setupSubscriptions(), this._table && this.host.requestUpdate();
|
|
524
464
|
}
|
|
525
465
|
hostUpdated() {
|
|
526
|
-
this._table && (this._rootSource.markCommitted(this._capturedSnapshot),
|
|
466
|
+
this._table && (this._rootSource.markCommitted(this._capturedSnapshot), ee(this._table, this._capturedState ?? null, P));
|
|
527
467
|
}
|
|
528
468
|
hostDisconnected() {
|
|
529
469
|
this._storeSubscription?.unsubscribe(), this._storeSubscription = void 0;
|
|
530
470
|
}
|
|
531
|
-
},
|
|
471
|
+
}, U = class extends Event {
|
|
532
472
|
constructor(e, t, n, r) {
|
|
533
473
|
super("context-request", {
|
|
534
474
|
bubbles: !0,
|
|
@@ -538,12 +478,12 @@ var U = class {
|
|
|
538
478
|
};
|
|
539
479
|
//#endregion
|
|
540
480
|
//#region ../../node_modules/.pnpm/@lit+context@1.1.6/node_modules/@lit/context/lib/create-context.js
|
|
541
|
-
function
|
|
481
|
+
function W(e) {
|
|
542
482
|
return e;
|
|
543
483
|
}
|
|
544
484
|
//#endregion
|
|
545
485
|
//#region ../../node_modules/.pnpm/@lit+context@1.1.6/node_modules/@lit/context/lib/controllers/context-consumer.js
|
|
546
|
-
var
|
|
486
|
+
var G = class {
|
|
547
487
|
constructor(e, t, n, r) {
|
|
548
488
|
if (this.subscribe = !1, this.provided = !1, this.value = void 0, this.t = (e, t) => {
|
|
549
489
|
this.unsubscribe && (this.unsubscribe !== t && (this.provided = !1, this.unsubscribe()), this.subscribe || this.unsubscribe()), this.value = e, this.host.requestUpdate(), this.provided && !this.subscribe || (this.provided = !0, this.callback && this.callback(e, t)), this.unsubscribe = t;
|
|
@@ -560,9 +500,9 @@ var K = class {
|
|
|
560
500
|
this.unsubscribe &&= (this.unsubscribe(), void 0);
|
|
561
501
|
}
|
|
562
502
|
dispatchRequest() {
|
|
563
|
-
this.host.dispatchEvent(new
|
|
503
|
+
this.host.dispatchEvent(new U(this.context, this.host, this.t, this.subscribe));
|
|
564
504
|
}
|
|
565
|
-
},
|
|
505
|
+
}, K = class {
|
|
566
506
|
get value() {
|
|
567
507
|
return this.o;
|
|
568
508
|
}
|
|
@@ -592,14 +532,14 @@ var K = class {
|
|
|
592
532
|
clearCallbacks() {
|
|
593
533
|
this.subscriptions.clear();
|
|
594
534
|
}
|
|
595
|
-
},
|
|
535
|
+
}, se = class extends Event {
|
|
596
536
|
constructor(e, t) {
|
|
597
537
|
super("context-provider", {
|
|
598
538
|
bubbles: !0,
|
|
599
539
|
composed: !0
|
|
600
540
|
}), this.context = e, this.contextTarget = t;
|
|
601
541
|
}
|
|
602
|
-
},
|
|
542
|
+
}, ce = class extends K {
|
|
603
543
|
constructor(e, t, n) {
|
|
604
544
|
super(t.context === void 0 ? n : t.initialValue), this.onContextRequest = (e) => {
|
|
605
545
|
if (e.context !== this.context) return;
|
|
@@ -608,7 +548,7 @@ var K = class {
|
|
|
608
548
|
}, this.onProviderRequest = (e) => {
|
|
609
549
|
if (e.context !== this.context || (e.contextTarget ?? e.composedPath()[0]) === this.host) return;
|
|
610
550
|
let t = /* @__PURE__ */ new Set();
|
|
611
|
-
for (let [e, { consumerHost: n }] of this.subscriptions) t.has(e) || (t.add(e), n.dispatchEvent(new
|
|
551
|
+
for (let [e, { consumerHost: n }] of this.subscriptions) t.has(e) || (t.add(e), n.dispatchEvent(new U(this.context, n, e, !0)));
|
|
612
552
|
e.stopPropagation();
|
|
613
553
|
}, this.host = e, this.context = t.context === void 0 ? t : t.context, this.attachListeners(), this.host.addController?.(this);
|
|
614
554
|
}
|
|
@@ -616,36 +556,36 @@ var K = class {
|
|
|
616
556
|
this.host.addEventListener("context-request", this.onContextRequest), this.host.addEventListener("context-provider", this.onProviderRequest);
|
|
617
557
|
}
|
|
618
558
|
hostConnected() {
|
|
619
|
-
this.host.dispatchEvent(new
|
|
559
|
+
this.host.dispatchEvent(new se(this.context, this.host));
|
|
620
560
|
}
|
|
621
561
|
};
|
|
622
562
|
//#endregion
|
|
623
563
|
//#region ../../node_modules/.pnpm/@tanstack+lit-table@9.0.0_@lit+context@1.1.6_lit@3.3.3/node_modules/@tanstack/lit-table/dist/createTableHook.js
|
|
624
|
-
function
|
|
625
|
-
let i =
|
|
564
|
+
function le({ tableComponents: e, cellComponents: t, headerComponents: n, ...r }) {
|
|
565
|
+
let i = W(Symbol("tanstack-table")), a = W(Symbol("tanstack-cell")), o = W(Symbol("tanstack-header"));
|
|
626
566
|
function s() {
|
|
627
|
-
return
|
|
567
|
+
return d();
|
|
628
568
|
}
|
|
629
569
|
function c(e) {
|
|
630
|
-
return new
|
|
570
|
+
return new G(e, {
|
|
631
571
|
context: i,
|
|
632
572
|
subscribe: !0
|
|
633
573
|
});
|
|
634
574
|
}
|
|
635
575
|
function l(e) {
|
|
636
|
-
return new
|
|
576
|
+
return new G(e, {
|
|
637
577
|
context: a,
|
|
638
578
|
subscribe: !0
|
|
639
579
|
});
|
|
640
580
|
}
|
|
641
581
|
function u(e) {
|
|
642
|
-
return new
|
|
582
|
+
return new G(e, {
|
|
643
583
|
context: o,
|
|
644
584
|
subscribe: !0
|
|
645
585
|
});
|
|
646
586
|
}
|
|
647
|
-
function
|
|
648
|
-
let c = new
|
|
587
|
+
function f(a, o, s) {
|
|
588
|
+
let c = new H(a), l = new ce(a, { context: i });
|
|
649
589
|
return { table() {
|
|
650
590
|
let i = {
|
|
651
591
|
...r,
|
|
@@ -653,7 +593,7 @@ function Te({ tableComponents: e, cellComponents: t, headerComponents: n, ...r }
|
|
|
653
593
|
}, a = c.table(i, s);
|
|
654
594
|
l.setValue(a);
|
|
655
595
|
function u(e, n) {
|
|
656
|
-
let r = () =>
|
|
596
|
+
let r = () => m({ cell: e }), i = {};
|
|
657
597
|
for (let [n, r] of Object.entries(t ?? {})) i[n] = () => r(e);
|
|
658
598
|
return n(Object.assign(e, {
|
|
659
599
|
FlexRender: r,
|
|
@@ -661,7 +601,7 @@ function Te({ tableComponents: e, cellComponents: t, headerComponents: n, ...r }
|
|
|
661
601
|
}));
|
|
662
602
|
}
|
|
663
603
|
function d(e, t) {
|
|
664
|
-
let r = () =>
|
|
604
|
+
let r = () => p(e.column.columnDef.header, e.getContext()), i = {};
|
|
665
605
|
for (let [t, r] of Object.entries(n ?? {})) i[t] = () => r(e);
|
|
666
606
|
return t(Object.assign(e, {
|
|
667
607
|
FlexRender: r,
|
|
@@ -669,7 +609,7 @@ function Te({ tableComponents: e, cellComponents: t, headerComponents: n, ...r }
|
|
|
669
609
|
}));
|
|
670
610
|
}
|
|
671
611
|
function f(e, t) {
|
|
672
|
-
let r = () =>
|
|
612
|
+
let r = () => p(e.column.columnDef.footer, e.getContext()), i = {};
|
|
673
613
|
for (let [t, r] of Object.entries(n ?? {})) i[t] = () => r(e);
|
|
674
614
|
return t(Object.assign(e, {
|
|
675
615
|
FlexRender: r,
|
|
@@ -680,7 +620,7 @@ function Te({ tableComponents: e, cellComponents: t, headerComponents: n, ...r }
|
|
|
680
620
|
AppCell: u,
|
|
681
621
|
AppHeader: d,
|
|
682
622
|
AppFooter: f,
|
|
683
|
-
FlexRender:
|
|
623
|
+
FlexRender: m,
|
|
684
624
|
...e ?? {}
|
|
685
625
|
});
|
|
686
626
|
} };
|
|
@@ -688,7 +628,7 @@ function Te({ tableComponents: e, cellComponents: t, headerComponents: n, ...r }
|
|
|
688
628
|
return {
|
|
689
629
|
appFeatures: r.features,
|
|
690
630
|
createAppColumnHelper: s,
|
|
691
|
-
useAppTable:
|
|
631
|
+
useAppTable: f,
|
|
692
632
|
useTableContext: c,
|
|
693
633
|
useCellContext: l,
|
|
694
634
|
useHeaderContext: u
|
|
@@ -696,16 +636,16 @@ function Te({ tableComponents: e, cellComponents: t, headerComponents: n, ...r }
|
|
|
696
636
|
}
|
|
697
637
|
//#endregion
|
|
698
638
|
//#region ../../node_modules/.pnpm/@tanstack+lit-table@9.0.0_@lit+context@1.1.6_lit@3.3.3/node_modules/@tanstack/lit-table/dist/index.js
|
|
699
|
-
var q = /* @__PURE__ */
|
|
700
|
-
FlexRender: () =>
|
|
701
|
-
SubscribeDirective: () =>
|
|
702
|
-
TableController: () =>
|
|
703
|
-
createTableHook: () =>
|
|
704
|
-
flexRender: () =>
|
|
705
|
-
subscribe: () =>
|
|
639
|
+
var q = /* @__PURE__ */ t({
|
|
640
|
+
FlexRender: () => m,
|
|
641
|
+
SubscribeDirective: () => L,
|
|
642
|
+
TableController: () => H,
|
|
643
|
+
createTableHook: () => le,
|
|
644
|
+
flexRender: () => p,
|
|
645
|
+
subscribe: () => R
|
|
706
646
|
});
|
|
707
|
-
import * as
|
|
708
|
-
|
|
647
|
+
import * as ue from "@tanstack/table-core";
|
|
648
|
+
e(q, ue);
|
|
709
649
|
//#endregion
|
|
710
650
|
//#region ../../node_modules/.pnpm/@tanstack+match-sorter-utils@9.0.0/node_modules/@tanstack/match-sorter-utils/dist/remove-accents.js
|
|
711
651
|
var J = {
|
|
@@ -1108,9 +1048,9 @@ var J = {
|
|
|
1108
1048
|
x̧: "x",
|
|
1109
1049
|
Z̧: "Z",
|
|
1110
1050
|
z̧: "z"
|
|
1111
|
-
},
|
|
1112
|
-
function
|
|
1113
|
-
return e.replace(
|
|
1051
|
+
}, de = Object.keys(J).join("|"), fe = new RegExp(de, "g");
|
|
1052
|
+
function pe(e) {
|
|
1053
|
+
return e.replace(fe, (e) => J[e]);
|
|
1114
1054
|
}
|
|
1115
1055
|
//#endregion
|
|
1116
1056
|
//#region ../../node_modules/.pnpm/@tanstack+match-sorter-utils@9.0.0/node_modules/@tanstack/match-sorter-utils/dist/index.js
|
|
@@ -1124,7 +1064,7 @@ var Y = {
|
|
|
1124
1064
|
MATCHES: 1,
|
|
1125
1065
|
NO_MATCH: 0
|
|
1126
1066
|
};
|
|
1127
|
-
function
|
|
1067
|
+
function me(e, t, n) {
|
|
1128
1068
|
if (n ||= {}, n.threshold = n.threshold ?? Y.MATCHES, !n.accessors) {
|
|
1129
1069
|
let r = X(e, t, n);
|
|
1130
1070
|
return {
|
|
@@ -1135,7 +1075,7 @@ function Ae(e, t, n) {
|
|
|
1135
1075
|
passed: r >= n.threshold
|
|
1136
1076
|
};
|
|
1137
1077
|
}
|
|
1138
|
-
let r =
|
|
1078
|
+
let r = ve(e, n.accessors), i = {
|
|
1139
1079
|
rankedValue: e,
|
|
1140
1080
|
rank: Y.NO_MATCH,
|
|
1141
1081
|
accessorIndex: -1,
|
|
@@ -1149,9 +1089,9 @@ function Ae(e, t, n) {
|
|
|
1149
1089
|
return i;
|
|
1150
1090
|
}
|
|
1151
1091
|
function X(e, t, n) {
|
|
1152
|
-
return e = Z(e, n), t = Z(t, n), t.length > e.length ? Y.NO_MATCH : e === t ? Y.CASE_SENSITIVE_EQUAL : (e = e.toLowerCase(), t = t.toLowerCase(), e === t ? Y.EQUAL : e.startsWith(t) ? Y.STARTS_WITH : e.includes(` ${t}`) ? Y.WORD_STARTS_WITH : e.includes(t) ? Y.CONTAINS : t.length === 1 ? Y.NO_MATCH :
|
|
1092
|
+
return e = Z(e, n), t = Z(t, n), t.length > e.length ? Y.NO_MATCH : e === t ? Y.CASE_SENSITIVE_EQUAL : (e = e.toLowerCase(), t = t.toLowerCase(), e === t ? Y.EQUAL : e.startsWith(t) ? Y.STARTS_WITH : e.includes(` ${t}`) ? Y.WORD_STARTS_WITH : e.includes(t) ? Y.CONTAINS : t.length === 1 ? Y.NO_MATCH : he(e).includes(t) ? Y.ACRONYM : ge(e, t));
|
|
1153
1093
|
}
|
|
1154
|
-
function
|
|
1094
|
+
function he(e) {
|
|
1155
1095
|
let t = "";
|
|
1156
1096
|
return e.split(" ").forEach((e) => {
|
|
1157
1097
|
e.split("-").forEach((e) => {
|
|
@@ -1159,7 +1099,7 @@ function je(e) {
|
|
|
1159
1099
|
});
|
|
1160
1100
|
}), t;
|
|
1161
1101
|
}
|
|
1162
|
-
function
|
|
1102
|
+
function ge(e, t) {
|
|
1163
1103
|
let n = 0, r = 0;
|
|
1164
1104
|
function i(e, t, r) {
|
|
1165
1105
|
for (let i = r, a = t.length; i < a; i++) if (t[i] === e) return n += 1, i + 1;
|
|
@@ -1179,18 +1119,18 @@ function Me(e, t) {
|
|
|
1179
1119
|
return a(r - o);
|
|
1180
1120
|
}
|
|
1181
1121
|
function Z(e, { keepDiacritics: t }) {
|
|
1182
|
-
return e = `${e}`, t || (e =
|
|
1122
|
+
return e = `${e}`, t || (e = pe(e)), e;
|
|
1183
1123
|
}
|
|
1184
|
-
function
|
|
1124
|
+
function _e(e, t) {
|
|
1185
1125
|
let n = t;
|
|
1186
1126
|
typeof t == "object" && (n = t.accessor);
|
|
1187
1127
|
let r = n(e);
|
|
1188
1128
|
return r == null ? [] : Array.isArray(r) ? r : [String(r)];
|
|
1189
1129
|
}
|
|
1190
|
-
function
|
|
1130
|
+
function ve(e, t) {
|
|
1191
1131
|
let n = [];
|
|
1192
1132
|
for (let r = 0, i = t.length; r < i; r++) {
|
|
1193
|
-
let i = t[r], a =
|
|
1133
|
+
let i = t[r], a = ye(i), o = _e(e, i);
|
|
1194
1134
|
for (let e = 0, t = o.length; e < t; e++) n.push({
|
|
1195
1135
|
itemValue: o[e],
|
|
1196
1136
|
attributes: a
|
|
@@ -1202,7 +1142,7 @@ var Q = {
|
|
|
1202
1142
|
maxRanking: Infinity,
|
|
1203
1143
|
minRanking: -Infinity
|
|
1204
1144
|
};
|
|
1205
|
-
function
|
|
1145
|
+
function ye(e) {
|
|
1206
1146
|
return typeof e == "function" ? Q : {
|
|
1207
1147
|
...Q,
|
|
1208
1148
|
...e
|
|
@@ -1210,7 +1150,7 @@ function Fe(e) {
|
|
|
1210
1150
|
}
|
|
1211
1151
|
//#endregion
|
|
1212
1152
|
//#region src/components/sken-datatable.ts
|
|
1213
|
-
var $ = class extends
|
|
1153
|
+
var $ = class extends r {
|
|
1214
1154
|
constructor(...e) {
|
|
1215
1155
|
super(...e), this.rows = [], this.columns = [], this.getRowId = void 0, this.loading = !1, this.empty = void 0, this.sorting = void 0, this.globalFilter = void 0, this.filterPlaceholder = "Filter…", this.pagination = void 0, this.defaultPageSize = 10, this.#e = [], this.#t = "", this.#n = {
|
|
1216
1156
|
pageIndex: 0,
|
|
@@ -1223,7 +1163,7 @@ var $ = class extends a {
|
|
|
1223
1163
|
globalFilteringFeature: q.globalFilteringFeature,
|
|
1224
1164
|
rowPaginationFeature: q.rowPaginationFeature,
|
|
1225
1165
|
paginatedRowModel: (0, q.createPaginatedRowModel)()
|
|
1226
|
-
}), this.#i = void 0, this.#o = (e, t, n) =>
|
|
1166
|
+
}), this.#i = void 0, this.#o = (e, t, n) => me(Object.values(e.original ?? {}).map((e) => e == null ? "" : String(e)).join(" "), String(n ?? "")).passed;
|
|
1227
1167
|
}
|
|
1228
1168
|
#e;
|
|
1229
1169
|
#t;
|
|
@@ -1231,7 +1171,7 @@ var $ = class extends a {
|
|
|
1231
1171
|
#r;
|
|
1232
1172
|
#i;
|
|
1233
1173
|
#a() {
|
|
1234
|
-
return this.#i === void 0 && (this.#i = new
|
|
1174
|
+
return this.#i === void 0 && (this.#i = new H(this)), this.#i;
|
|
1235
1175
|
}
|
|
1236
1176
|
#o;
|
|
1237
1177
|
#s() {
|
|
@@ -1244,14 +1184,14 @@ var $ = class extends a {
|
|
|
1244
1184
|
});
|
|
1245
1185
|
}
|
|
1246
1186
|
render() {
|
|
1247
|
-
if (this.loading) return
|
|
1187
|
+
if (this.loading) return a`
|
|
1248
1188
|
<div class="loading" role="status" aria-busy="true">
|
|
1249
1189
|
<slot name="loading"></slot>
|
|
1250
1190
|
</div>
|
|
1251
1191
|
`;
|
|
1252
1192
|
if (this.rows.length === 0) return this.#c();
|
|
1253
1193
|
let e = {}, t = {};
|
|
1254
|
-
this.sorting !== void 0 && this.sorting.length > 0 && (e.sorting = this.sorting, t.sorting = this.sorting), this.globalFilter !== void 0 &&
|
|
1194
|
+
this.sorting !== void 0 && this.sorting.length > 0 && (e.sorting = this.sorting, t.sorting = this.sorting), this.globalFilter !== void 0 && (e.globalFilter = this.globalFilter, t.globalFilter = this.globalFilter), this.pagination === void 0 ? t.pagination = this.#n : (e.pagination = this.pagination, t.pagination = this.pagination);
|
|
1255
1195
|
let n = this.#a().table({
|
|
1256
1196
|
data: this.rows,
|
|
1257
1197
|
columns: this.columns,
|
|
@@ -1285,7 +1225,7 @@ var $ = class extends a {
|
|
|
1285
1225
|
}));
|
|
1286
1226
|
}
|
|
1287
1227
|
});
|
|
1288
|
-
return
|
|
1228
|
+
return f.table_publishExternalState(n, e, (e, t) => e === t), a`
|
|
1289
1229
|
<div class="filter-bar">
|
|
1290
1230
|
<slot name="filter">
|
|
1291
1231
|
<input
|
|
@@ -1307,26 +1247,26 @@ var $ = class extends a {
|
|
|
1307
1247
|
</div>
|
|
1308
1248
|
<table>
|
|
1309
1249
|
<thead>
|
|
1310
|
-
${n.getHeaderGroups().map((e) =>
|
|
1250
|
+
${n.getHeaderGroups().map((e) => a`
|
|
1311
1251
|
<tr>
|
|
1312
1252
|
${e.headers.map((e) => {
|
|
1313
|
-
let t = e.column.columnDef.header, n = typeof t == "string" ? t : e.column.id, r = e.column.getCanSort(), i = e.column.getIsSorted(),
|
|
1314
|
-
return
|
|
1253
|
+
let t = e.column.columnDef.header, n = typeof t == "string" ? t : e.column.id, r = e.column.getCanSort(), i = e.column.getIsSorted(), o = i === "asc" ? "▲" : i === "desc" ? "▼" : "", c = e.column.getToggleSortingHandler();
|
|
1254
|
+
return a`
|
|
1315
1255
|
<th
|
|
1316
1256
|
scope="col"
|
|
1317
1257
|
part="header-cell"
|
|
1318
1258
|
data-column-id=${e.column.id}
|
|
1319
1259
|
class=${r ? "sortable" : ""}
|
|
1320
1260
|
aria-sort=${i === "asc" ? "ascending" : i === "desc" ? "descending" : "none"}
|
|
1321
|
-
@click=${r &&
|
|
1261
|
+
@click=${r && c ? c : null}
|
|
1322
1262
|
>
|
|
1323
1263
|
<span class="header-text">${n}</span>
|
|
1324
|
-
${r ?
|
|
1264
|
+
${r ? a`<span
|
|
1325
1265
|
class="sort-indicator"
|
|
1326
1266
|
data-state=${i || "none"}
|
|
1327
1267
|
aria-hidden="true"
|
|
1328
|
-
>${
|
|
1329
|
-
>` :
|
|
1268
|
+
>${o}</span
|
|
1269
|
+
>` : s}
|
|
1330
1270
|
</th>
|
|
1331
1271
|
`;
|
|
1332
1272
|
})}
|
|
@@ -1336,13 +1276,13 @@ var $ = class extends a {
|
|
|
1336
1276
|
<tbody>
|
|
1337
1277
|
${n.getRowModel().rows.map((e) => {
|
|
1338
1278
|
let t = e;
|
|
1339
|
-
return
|
|
1279
|
+
return a`
|
|
1340
1280
|
<tr part="row" data-row-id=${t.id}>
|
|
1341
1281
|
${t.getAllCells().map((e) => {
|
|
1342
1282
|
let t = e.getValue();
|
|
1343
|
-
return
|
|
1283
|
+
return a`
|
|
1344
1284
|
<td part="cell" data-column-id=${e.column.id}>
|
|
1345
|
-
${t == null ?
|
|
1285
|
+
${t == null ? s : String(t)}
|
|
1346
1286
|
</td>
|
|
1347
1287
|
`;
|
|
1348
1288
|
})}
|
|
@@ -1356,7 +1296,7 @@ var $ = class extends a {
|
|
|
1356
1296
|
<slot name="pagination">
|
|
1357
1297
|
${(() => {
|
|
1358
1298
|
let e = n, { pageIndex: t, pageSize: r } = e.state.pagination, i = e.getPageCount();
|
|
1359
|
-
return
|
|
1299
|
+
return a`
|
|
1360
1300
|
<button
|
|
1361
1301
|
type="button"
|
|
1362
1302
|
class="page-btn"
|
|
@@ -1384,14 +1324,14 @@ var $ = class extends a {
|
|
|
1384
1324
|
`;
|
|
1385
1325
|
}
|
|
1386
1326
|
#c() {
|
|
1387
|
-
return
|
|
1327
|
+
return a`
|
|
1388
1328
|
<div class="empty" role="status">
|
|
1389
1329
|
<slot name="empty">${this.empty ?? "No rows"}</slot>
|
|
1390
1330
|
</div>
|
|
1391
1331
|
`;
|
|
1392
1332
|
}
|
|
1393
1333
|
static {
|
|
1394
|
-
this.styles =
|
|
1334
|
+
this.styles = i`
|
|
1395
1335
|
:host {
|
|
1396
1336
|
display: block;
|
|
1397
1337
|
inline-size: 100%;
|
|
@@ -1548,14 +1488,14 @@ var $ = class extends a {
|
|
|
1548
1488
|
`;
|
|
1549
1489
|
}
|
|
1550
1490
|
};
|
|
1551
|
-
|
|
1491
|
+
n([l({ attribute: !1 })], $.prototype, "rows", void 0), n([l({ attribute: !1 })], $.prototype, "columns", void 0), n([l({ attribute: !1 })], $.prototype, "getRowId", void 0), n([l({
|
|
1552
1492
|
reflect: !0,
|
|
1553
1493
|
type: Boolean
|
|
1554
|
-
})], $.prototype, "loading", void 0),
|
|
1494
|
+
})], $.prototype, "loading", void 0), n([l()], $.prototype, "empty", void 0), n([l({ attribute: !1 })], $.prototype, "sorting", void 0), n([l({ attribute: !1 })], $.prototype, "globalFilter", void 0), n([l()], $.prototype, "filterPlaceholder", void 0), n([l({ attribute: !1 })], $.prototype, "pagination", void 0), n([l({
|
|
1555
1495
|
attribute: "default-page-size",
|
|
1556
1496
|
type: Number
|
|
1557
|
-
})], $.prototype, "defaultPageSize", void 0), $ =
|
|
1497
|
+
})], $.prototype, "defaultPageSize", void 0), $ = n([c("sken-datatable")], $);
|
|
1558
1498
|
//#endregion
|
|
1559
1499
|
export { $ as t };
|
|
1560
1500
|
|
|
1561
|
-
//# sourceMappingURL=sken-datatable-
|
|
1501
|
+
//# sourceMappingURL=sken-datatable-jx_jh1Fu.js.map
|