@ninebone/table 0.0.626 β 0.0.628
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/nine-table.js +59 -59
- package/dist/nine-table.js.map +1 -1
- package/dist/nine-table.umd.js +4 -4
- package/dist/nine-table.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/nine-table.js
CHANGED
|
@@ -22,29 +22,29 @@ const He = class He extends Ke.constructor {
|
|
|
22
22
|
};
|
|
23
23
|
c(He, "Trace");
|
|
24
24
|
let oe = He;
|
|
25
|
-
const
|
|
26
|
-
var
|
|
25
|
+
const H = new oe();
|
|
26
|
+
var z, j, w, X, K, Z, It, G, _t;
|
|
27
27
|
const Me = class Me extends HTMLElement {
|
|
28
28
|
constructor() {
|
|
29
29
|
super();
|
|
30
|
-
d(this,
|
|
30
|
+
d(this, z);
|
|
31
31
|
d(this, j, !1);
|
|
32
32
|
d(this, w);
|
|
33
33
|
d(this, X);
|
|
34
34
|
d(this, K);
|
|
35
35
|
d(this, Z);
|
|
36
36
|
d(this, It, /* @__PURE__ */ c(() => {
|
|
37
|
-
if (!t(this,
|
|
38
|
-
const e = t(this,
|
|
37
|
+
if (!t(this, z)) return;
|
|
38
|
+
const e = t(this, z).querySelector(".ng-container-body .ng-part-body");
|
|
39
39
|
e && (y(this, Z, new ResizeObserver(() => {
|
|
40
40
|
this.refresh();
|
|
41
41
|
})), t(this, Z).observe(e));
|
|
42
42
|
}, "#observeResize"));
|
|
43
43
|
A(this, "refresh", /* @__PURE__ */ c(() => {
|
|
44
|
-
if (!t(this,
|
|
44
|
+
if (!t(this, z) || !t(this, w) || t(this, j)) return;
|
|
45
45
|
const e = t(this, w).container, s = e.querySelector("table");
|
|
46
46
|
if (!s) return;
|
|
47
|
-
const r = t(this, w).track, n = t(this, w).thumb, o = t(this,
|
|
47
|
+
const r = t(this, w).track, n = t(this, w).thumb, o = t(this, z).querySelector(".ng-container-bottom"), a = e.clientWidth, h = s.scrollWidth;
|
|
48
48
|
if (a !== 0 && h > a)
|
|
49
49
|
o && (o.style.display = "flex");
|
|
50
50
|
else {
|
|
@@ -112,7 +112,7 @@ const Me = class Me extends HTMLElement {
|
|
|
112
112
|
}, "#init"));
|
|
113
113
|
}
|
|
114
114
|
connectedCallback() {
|
|
115
|
-
if (y(this,
|
|
115
|
+
if (y(this, z, this.closest("nine-table-sheet") || this.getRootNode().host), !t(this, z)) return;
|
|
116
116
|
this.innerHTML = `
|
|
117
117
|
<style>
|
|
118
118
|
nine-table-hscrollbar {
|
|
@@ -177,7 +177,7 @@ const Me = class Me extends HTMLElement {
|
|
|
177
177
|
<button class='ng-scroll-right' disabled><div class='ng-scroll-icon'></div></button>
|
|
178
178
|
`;
|
|
179
179
|
const e = /* @__PURE__ */ c(() => {
|
|
180
|
-
const s = t(this,
|
|
180
|
+
const s = t(this, z).querySelector(".ng-container-body .ng-part-body");
|
|
181
181
|
if (!s) {
|
|
182
182
|
setTimeout(e, 10);
|
|
183
183
|
return;
|
|
@@ -198,7 +198,7 @@ const Me = class Me extends HTMLElement {
|
|
|
198
198
|
t(this, Z) && t(this, Z).disconnect();
|
|
199
199
|
}
|
|
200
200
|
};
|
|
201
|
-
|
|
201
|
+
z = new WeakMap(), j = new WeakMap(), w = new WeakMap(), X = new WeakMap(), K = new WeakMap(), Z = new WeakMap(), It = new WeakMap(), G = new WeakMap(), _t = new WeakMap(), c(Me, "NineTableHScrollBar");
|
|
202
202
|
let ae = Me;
|
|
203
203
|
customElements.get("nine-table-hscrollbar") || customElements.define("nine-table-hscrollbar", ae);
|
|
204
204
|
var F, at, J, T, vt, xt, Nt;
|
|
@@ -230,7 +230,7 @@ const $e = class $e extends HTMLElement {
|
|
|
230
230
|
m < 0 && (m = 0), m > x && (m = x), r.style.top = `${m}px`, t(this, T).top.disabled = g <= 0, t(this, T).bottom.disabled = g >= b - 1;
|
|
231
231
|
}, "refresh"));
|
|
232
232
|
d(this, Nt, /* @__PURE__ */ c(() => {
|
|
233
|
-
|
|
233
|
+
H.log("nine-table-vscrollbar.#init");
|
|
234
234
|
const e = t(this, T).container, s = /* @__PURE__ */ c(() => {
|
|
235
235
|
const n = (t(this, F).data.get() || []).length, o = t(this, at).getRowHeight();
|
|
236
236
|
return n * o;
|
|
@@ -354,7 +354,7 @@ const $e = class $e extends HTMLElement {
|
|
|
354
354
|
F = new WeakMap(), at = new WeakMap(), J = new WeakMap(), T = new WeakMap(), vt = new WeakMap(), xt = new WeakMap(), Nt = new WeakMap(), c($e, "NineTableVScrollBar");
|
|
355
355
|
let le = $e;
|
|
356
356
|
customElements.get("nine-table-vscrollbar") || customElements.define("nine-table-vscrollbar", le);
|
|
357
|
-
var P, S, Q, D, _, V, tt, wt, Se, Ee, Wt, Ot,
|
|
357
|
+
var P, S, Q, D, _, V, tt, wt, Se, Ee, Wt, Ot, Bt, St, Et, zt, Dt, At, Ae, lt, qt, Pt;
|
|
358
358
|
const Ie = class Ie {
|
|
359
359
|
constructor(i) {
|
|
360
360
|
d(this, P);
|
|
@@ -371,12 +371,12 @@ const Ie = class Ie {
|
|
|
371
371
|
d(this, Wt, 3);
|
|
372
372
|
A(this, "refresh", /* @__PURE__ */ c(() => {
|
|
373
373
|
var e;
|
|
374
|
-
|
|
374
|
+
H.log("rowManager.refresh");
|
|
375
375
|
const i = t(this, S).querySelector(".ng-container-body .ng-part-body");
|
|
376
376
|
i && (t(this, St).call(this), t(this, lt).call(this, i.scrollTop), (e = t(this, S).querySelector("nine-table-vscrollbar")) == null || e.refresh());
|
|
377
377
|
}, "refresh"));
|
|
378
378
|
A(this, "initialize", /* @__PURE__ */ c(() => {
|
|
379
|
-
|
|
379
|
+
H.log("rowManager.initialize"), y(this, Q, {
|
|
380
380
|
scrollTables: t(this, S).querySelectorAll(".ng-part-body table"),
|
|
381
381
|
firstTr: t(this, S).querySelector(".ng-container-body .ng-part-body tbody.bindable-tbody tr:not(.nodata)")
|
|
382
382
|
}), y(this, _, null), t(this, D).clear(), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((o) => {
|
|
@@ -391,7 +391,7 @@ const Ie = class Ie {
|
|
|
391
391
|
});
|
|
392
392
|
const i = t(this, S).querySelector(".ng-container-body .ng-part-body"), e = t(this, S).querySelector(".ng-container-left .ng-part-body"), s = t(this, S).querySelector(".ng-container-right .ng-part-body"), r = t(this, S).querySelector(".ng-container-body .ng-part-header"), n = t(this, S).querySelector(".ng-container-body .ng-part-footer");
|
|
393
393
|
if (i) {
|
|
394
|
-
t(this,
|
|
394
|
+
t(this, Bt).call(this, i), t(this, At).call(this), t(this, St).call(this), t(this, lt).call(this, i.scrollTop);
|
|
395
395
|
let o = !1;
|
|
396
396
|
const a = /* @__PURE__ */ c((h) => {
|
|
397
397
|
if (o) return;
|
|
@@ -407,7 +407,7 @@ const Ie = class Ie {
|
|
|
407
407
|
}
|
|
408
408
|
}, "initialize"));
|
|
409
409
|
d(this, Ot, /* @__PURE__ */ c((i, e) => {
|
|
410
|
-
|
|
410
|
+
H.log("rowManager.#renderRows");
|
|
411
411
|
const s = t(this, D).get(e);
|
|
412
412
|
if (!s || s.length === 0) return;
|
|
413
413
|
const r = i.querySelector(".ng-part-body tbody.bindable-tbody");
|
|
@@ -420,14 +420,14 @@ const Ie = class Ie {
|
|
|
420
420
|
});
|
|
421
421
|
n ? n.before(o) : r.appendChild(o), e === ".ng-container-body" && (t(this, Q).firstTr = r.querySelector("tr:not(.nodata)"));
|
|
422
422
|
}, "#renderRows"));
|
|
423
|
-
d(this,
|
|
424
|
-
if (
|
|
423
|
+
d(this, Bt, /* @__PURE__ */ c((i) => {
|
|
424
|
+
if (H.log("rowManager.#measureAndCacheHeight"), t(this, _) !== null && t(this, _) > 0)
|
|
425
425
|
return t(this, _);
|
|
426
|
-
|
|
426
|
+
H.log("#measureAndCacheHeight");
|
|
427
427
|
const e = t(this, D).get(".ng-container-body");
|
|
428
428
|
if (!e || e.length === 0) throw new Error("invalid dom");
|
|
429
429
|
const s = i.querySelector("tbody.bindable-tbody");
|
|
430
|
-
if (
|
|
430
|
+
if (H.log(s), !s) throw new Error("invalid dom");
|
|
431
431
|
s.querySelectorAll("tr:not(.nodata)").forEach((g) => g.remove());
|
|
432
432
|
const r = s.querySelector("tr.nodata"), n = document.createDocumentFragment();
|
|
433
433
|
e.forEach((g) => {
|
|
@@ -436,15 +436,15 @@ const Ie = class Ie {
|
|
|
436
436
|
const o = t(this, S), a = o.style.display, h = o.style.visibility, l = o.style.position;
|
|
437
437
|
(a === "none" || window.getComputedStyle(o).display === "none") && (o.style.display = "block", o.style.visibility = "hidden", o.style.position = "absolute");
|
|
438
438
|
let f = 0;
|
|
439
|
-
const u = s.querySelectorAll("tr
|
|
439
|
+
const u = s.querySelectorAll("tr");
|
|
440
440
|
return u.forEach((g) => {
|
|
441
|
-
f += g.offsetHeight || g.getBoundingClientRect().height;
|
|
442
|
-
}), u.forEach((g) => g.remove()), o.style.display = a, o.style.visibility = h, o.style.position = l, y(this, _, f > 0 ? f : 24), t(this, Et).call(this), t(this, _);
|
|
441
|
+
H.log(g.offsetHeight, g.getBoundingClientRect().height), f += g.offsetHeight || g.getBoundingClientRect().height;
|
|
442
|
+
}), u.forEach((g) => g.remove()), o.style.display = a, o.style.visibility = h, o.style.position = l, H.log("totalHeight", f), y(this, _, f > 0 ? f : 24), t(this, Et).call(this), t(this, _);
|
|
443
443
|
}, "#measureAndCacheHeight"));
|
|
444
444
|
d(this, St, /* @__PURE__ */ c(() => {
|
|
445
|
-
|
|
445
|
+
H.log("rowManager.#updateVirtualScrollHeight");
|
|
446
446
|
const e = (t(this, P).data.get() || []).length, s = t(this, _), r = e * s;
|
|
447
|
-
|
|
447
|
+
H.log("π [VirtualHeight]", { totalCount: e, rowHeight: s, totalVirtualHeight: r }), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((n) => {
|
|
448
448
|
const o = t(this, S).querySelector(n);
|
|
449
449
|
if (!o) return;
|
|
450
450
|
const a = o.querySelector(".ng-part-body .ng-virtual-spacer");
|
|
@@ -457,7 +457,7 @@ const Ie = class Ie {
|
|
|
457
457
|
y(this, wt, i + t(this, Wt));
|
|
458
458
|
}
|
|
459
459
|
}, "#updateRowCount"));
|
|
460
|
-
d(this,
|
|
460
|
+
d(this, zt, /* @__PURE__ */ c(() => {
|
|
461
461
|
var a, h, l, f, u, g;
|
|
462
462
|
const i = t(this, S).querySelector(".ng-container-left .ng-part-body table"), e = t(this, S).querySelector(".ng-container-body .ng-part-body table"), s = t(this, S).querySelector(".ng-container-right .ng-part-body table");
|
|
463
463
|
if (e) {
|
|
@@ -501,10 +501,10 @@ const Ie = class Ie {
|
|
|
501
501
|
})), t(this, V).observe(t(this, S)));
|
|
502
502
|
}, "#initResizeObserver"));
|
|
503
503
|
d(this, At, /* @__PURE__ */ c(() => {
|
|
504
|
-
|
|
504
|
+
H.log("rowManager.#renderAllContainers"), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((i) => {
|
|
505
505
|
const e = t(this, S).querySelector(i);
|
|
506
506
|
e && e.querySelector(".ng-part-body tbody.bindable-tbody") && t(this, Ot).call(this, e, i);
|
|
507
|
-
}), t(this, Pt).call(this), t(this,
|
|
507
|
+
}), t(this, Pt).call(this), t(this, zt).call(this);
|
|
508
508
|
}, "#renderAllContainers"));
|
|
509
509
|
d(this, Ae, /* @__PURE__ */ c((i) => {
|
|
510
510
|
[".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((e) => {
|
|
@@ -573,7 +573,7 @@ const Ie = class Ie {
|
|
|
573
573
|
}, "#bindRowData"));
|
|
574
574
|
d(this, Pt, /* @__PURE__ */ c(() => {
|
|
575
575
|
var h, l, f;
|
|
576
|
-
|
|
576
|
+
H.log("rowManager.#syncHeaderHeights");
|
|
577
577
|
const i = t(this, S).querySelector(".ng-container-left .ng-part-header table"), e = t(this, S).querySelector(".ng-container-body .ng-part-header table"), s = t(this, S).querySelector(".ng-container-right .ng-part-header table");
|
|
578
578
|
if (!e) return;
|
|
579
579
|
const r = i ? Array.from(i.querySelectorAll("tr")) : [], n = Array.from(e.querySelectorAll("tr")), o = s ? Array.from(s.querySelectorAll("tr")) : [], a = Math.max(r.length, n.length, o.length);
|
|
@@ -599,7 +599,7 @@ const Ie = class Ie {
|
|
|
599
599
|
return ((e = t(this, D).get(i)) == null ? void 0 : e.length) || 1;
|
|
600
600
|
}
|
|
601
601
|
};
|
|
602
|
-
P = new WeakMap(), S = new WeakMap(), Q = new WeakMap(), D = new WeakMap(), _ = new WeakMap(), V = new WeakMap(), tt = new WeakMap(), wt = new WeakMap(), Se = new WeakMap(), Ee = new WeakMap(), Wt = new WeakMap(), Ot = new WeakMap(),
|
|
602
|
+
P = new WeakMap(), S = new WeakMap(), Q = new WeakMap(), D = new WeakMap(), _ = new WeakMap(), V = new WeakMap(), tt = new WeakMap(), wt = new WeakMap(), Se = new WeakMap(), Ee = new WeakMap(), Wt = new WeakMap(), Ot = new WeakMap(), Bt = new WeakMap(), St = new WeakMap(), Et = new WeakMap(), zt = new WeakMap(), Dt = new WeakMap(), At = new WeakMap(), Ae = new WeakMap(), lt = new WeakMap(), qt = new WeakMap(), Pt = new WeakMap(), c(Ie, "RowManager");
|
|
603
603
|
let ce = Ie;
|
|
604
604
|
const jt = class jt {
|
|
605
605
|
/**
|
|
@@ -648,15 +648,15 @@ const jt = class jt {
|
|
|
648
648
|
const x = m.sectionRowIndex;
|
|
649
649
|
let E = 0;
|
|
650
650
|
Array.from(m.querySelectorAll("th,td")).forEach((v) => {
|
|
651
|
-
for (let
|
|
652
|
-
if (b[x][
|
|
653
|
-
E =
|
|
651
|
+
for (let B = 0; B < b[x].length; B++)
|
|
652
|
+
if (b[x][B] === null) {
|
|
653
|
+
E = B;
|
|
654
654
|
break;
|
|
655
655
|
}
|
|
656
656
|
const I = v.rowSpan || 1, R = v.colSpan || 1;
|
|
657
|
-
for (let
|
|
657
|
+
for (let B = 0; B < I; B++)
|
|
658
658
|
for (let yt = 0; yt < R; yt++)
|
|
659
|
-
x +
|
|
659
|
+
x + B < u && E + yt < g && (b[x + B][E + yt] = B === 0 && yt === 0 ? "1" : "0");
|
|
660
660
|
});
|
|
661
661
|
}), l.forEach((m) => {
|
|
662
662
|
const x = m.sectionRowIndex;
|
|
@@ -943,7 +943,7 @@ const pt = class pt extends HTMLElement {
|
|
|
943
943
|
t(this, Ut).call(this);
|
|
944
944
|
}
|
|
945
945
|
disconnectedCallback() {
|
|
946
|
-
this.innerHTML = "",
|
|
946
|
+
this.innerHTML = "", H.log("NineTableSheet destroyed.");
|
|
947
947
|
}
|
|
948
948
|
};
|
|
949
949
|
Ft = new WeakMap(), et = new WeakMap(), st = new WeakMap(), Vt = new WeakMap(), Yt = new WeakMap(), ct = new WeakMap(), Ut = new WeakMap(), Xt = new WeakMap(), c(pt, "NineTableSheet"), A(pt, "SCROLLBAR_SIZE", 16);
|
|
@@ -1000,29 +1000,29 @@ const _e = class _e extends HTMLElement {
|
|
|
1000
1000
|
Kt = new WeakMap(), Rt = new WeakMap(), c(_e, "NineTableSheets");
|
|
1001
1001
|
let de = _e;
|
|
1002
1002
|
customElements.get("nine-table-sheets") || customElements.define("nine-table-sheets", de);
|
|
1003
|
-
var
|
|
1003
|
+
var M, Zt, Tt, Gt;
|
|
1004
1004
|
const Ne = class Ne {
|
|
1005
1005
|
constructor(i) {
|
|
1006
|
-
d(this,
|
|
1006
|
+
d(this, M);
|
|
1007
1007
|
d(this, Zt, /* @__PURE__ */ c(() => {
|
|
1008
1008
|
t(this, Gt).call(this), new ResizeObserver((i) => {
|
|
1009
1009
|
for (let e of i)
|
|
1010
|
-
t(this,
|
|
1011
|
-
}).observe(t(this,
|
|
1010
|
+
t(this, M).getAttribute("auto-height") === "true" && t(this, Tt).call(this);
|
|
1011
|
+
}).observe(t(this, M));
|
|
1012
1012
|
}, "#init"));
|
|
1013
1013
|
d(this, Tt, /* @__PURE__ */ c(() => {
|
|
1014
1014
|
var h, l;
|
|
1015
|
-
const i = Array.from(t(this,
|
|
1015
|
+
const i = Array.from(t(this, M).shadowRoot.querySelectorAll("nine-table-sheet.active"));
|
|
1016
1016
|
if (i.length === 0) return;
|
|
1017
|
-
const e = parseInt(t(this,
|
|
1018
|
-
t(this,
|
|
1017
|
+
const e = parseInt(t(this, M).getAttribute("max-display-row"), 10) || 10, s = Math.max(...i.map((f) => f.getRowHeight())), r = (h = t(this, M).shadowRoot.querySelector("nine-table-header")) == null ? void 0 : h.getBoundingClientRect().height, n = (l = t(this, M).shadowRoot.querySelector("nine-table-sheets-footer")) == null ? void 0 : l.getBoundingClientRect().height, o = $t.SCROLLBAR_SIZE, a = e * s + r + n + o;
|
|
1018
|
+
t(this, M).style.height = `${a}px`;
|
|
1019
1019
|
}, "#applyAutoHeight"));
|
|
1020
1020
|
d(this, Gt, /* @__PURE__ */ c(() => {
|
|
1021
|
-
const e = Array.from(t(this,
|
|
1021
|
+
const e = Array.from(t(this, M).children).filter((h) => h.tagName === "TABLE"), s = t(this, M).getAttribute("auto-height") === "true", r = e.length, n = e.map((h, l) => {
|
|
1022
1022
|
const u = `<nine-table-sheet class="${l === 0 ? "active" : ""}" data-index="${l}"></nine-table-sheet>`, g = l < r - 1 ? `<nine-splitter class="h" data-split-index="${l}"></nine-splitter>` : "";
|
|
1023
1023
|
return u + g;
|
|
1024
1024
|
}).join(""), o = e.map((h, l) => `<div class="nine-tab-item ${l === 0 ? "active" : ""}" data-index="${l}">Sheet ${l + 1}</div>`).join("");
|
|
1025
|
-
t(this,
|
|
1025
|
+
t(this, M).shadowRoot.innerHTML = `
|
|
1026
1026
|
<style>
|
|
1027
1027
|
:host {
|
|
1028
1028
|
display: flex;
|
|
@@ -1142,18 +1142,18 @@ const Ne = class Ne {
|
|
|
1142
1142
|
<nine-table-analysis></nine-table-analysis>
|
|
1143
1143
|
</nine-table-body>
|
|
1144
1144
|
<nine-table-footer></nine-table-footer>
|
|
1145
|
-
`, t(this,
|
|
1146
|
-
const a = t(this,
|
|
1145
|
+
`, t(this, M).shadowRoot.querySelector("nine-table-sheets").classList.add("nodata");
|
|
1146
|
+
const a = t(this, M).shadowRoot.querySelectorAll("nine-table-sheet");
|
|
1147
1147
|
a == null || a.forEach((h, l) => {
|
|
1148
1148
|
e[l] && setTimeout(() => {
|
|
1149
1149
|
h.generate(e[l]), s && t(this, Tt).call(this);
|
|
1150
1150
|
});
|
|
1151
1151
|
});
|
|
1152
1152
|
}, "#render"));
|
|
1153
|
-
y(this,
|
|
1153
|
+
y(this, M, i), t(this, Zt).call(this);
|
|
1154
1154
|
}
|
|
1155
1155
|
};
|
|
1156
|
-
|
|
1156
|
+
M = new WeakMap(), Zt = new WeakMap(), Tt = new WeakMap(), Gt = new WeakMap(), c(Ne, "LayoutManager");
|
|
1157
1157
|
let fe = Ne;
|
|
1158
1158
|
var kt, ht;
|
|
1159
1159
|
const We = class We {
|
|
@@ -1349,7 +1349,7 @@ const Oe = class Oe {
|
|
|
1349
1349
|
rt = new WeakMap(), c(Oe, "ngDataManager");
|
|
1350
1350
|
let be = Oe;
|
|
1351
1351
|
var ut, L, Lt, se;
|
|
1352
|
-
const
|
|
1352
|
+
const Be = class Be {
|
|
1353
1353
|
// π― μ΄μ { name: string, type: string } κ°μ²΄λ€μ λ°°μ΄λ‘ κ΄λ¦¬ν©λλ€.
|
|
1354
1354
|
constructor(i) {
|
|
1355
1355
|
d(this, ut);
|
|
@@ -1366,11 +1366,11 @@ const ze = class ze {
|
|
|
1366
1366
|
}), y(this, L, Array.from(i, ([e, s]) => ({ name: e, type: s }))), y(this, L, t(this, L).filter((e) => e.name !== "" && e.name !== "__ng")), t(this, L).sort((e, s) => e.name.length < s.name.length ? 1 : -1);
|
|
1367
1367
|
}, "#adjust"));
|
|
1368
1368
|
d(this, se, /* @__PURE__ */ c(() => {
|
|
1369
|
-
y(this, L, []),
|
|
1369
|
+
y(this, L, []), H.log(t(this, ut).querySelectorAll("table"));
|
|
1370
1370
|
const i = Array.from(t(this, ut).querySelectorAll("table"));
|
|
1371
1371
|
if (!(!i || i.length === 0)) {
|
|
1372
1372
|
for (const e of i)
|
|
1373
|
-
|
|
1373
|
+
H.log(e), $("[data-bind]", e).each((s, r) => {
|
|
1374
1374
|
const n = r.dataset.bind, o = r.getAttribute("data-type") || "string";
|
|
1375
1375
|
n && t(this, L).push({ name: n, type: o });
|
|
1376
1376
|
}), ["data-expr", "background-color", "color", "tooltip", "visible", "readonly", "enable-button", "enable-check", "class-expr", "icon-color", "icon-src"].forEach((s) => {
|
|
@@ -1419,17 +1419,17 @@ const ze = class ze {
|
|
|
1419
1419
|
return t(this, L).some((e) => e.name === i);
|
|
1420
1420
|
}
|
|
1421
1421
|
};
|
|
1422
|
-
ut = new WeakMap(), L = new WeakMap(), Lt = new WeakMap(), se = new WeakMap(), c(
|
|
1423
|
-
let ye =
|
|
1422
|
+
ut = new WeakMap(), L = new WeakMap(), Lt = new WeakMap(), se = new WeakMap(), c(Be, "ngFields");
|
|
1423
|
+
let ye = Be;
|
|
1424
1424
|
var nt, ie, re;
|
|
1425
|
-
const
|
|
1425
|
+
const ze = class ze extends HTMLElement {
|
|
1426
1426
|
constructor() {
|
|
1427
1427
|
super();
|
|
1428
1428
|
//#created = false;
|
|
1429
1429
|
d(this, nt);
|
|
1430
1430
|
d(this, ie);
|
|
1431
1431
|
d(this, re, /* @__PURE__ */ c(() => {
|
|
1432
|
-
this.fields = new ye(this), y(this, ie, new fe(this)),
|
|
1432
|
+
this.fields = new ye(this), y(this, ie, new fe(this)), H.log("NineTable connected."), this.dispatchEvent(new CustomEvent("load", { bubbles: !0, detail: { target: this } }));
|
|
1433
1433
|
}, "#init"));
|
|
1434
1434
|
this.attachShadow({ mode: "open" }), y(this, nt, new be(this));
|
|
1435
1435
|
}
|
|
@@ -1437,7 +1437,7 @@ const Be = class Be extends HTMLElement {
|
|
|
1437
1437
|
t(this, re).call(this);
|
|
1438
1438
|
}
|
|
1439
1439
|
disconnectedCallback() {
|
|
1440
|
-
|
|
1440
|
+
H.log("NineTable disconnected.");
|
|
1441
1441
|
}
|
|
1442
1442
|
// π― μΈλΆμμ grid.data.set(...) ννλ‘ μ κ·Όν μ μλλ‘ λ°μ΄ν° λ§€λμ μ€ν
|
|
1443
1443
|
get data() {
|
|
@@ -1452,8 +1452,8 @@ const Be = class Be extends HTMLElement {
|
|
|
1452
1452
|
return t(this, nt);
|
|
1453
1453
|
}
|
|
1454
1454
|
};
|
|
1455
|
-
nt = new WeakMap(), ie = new WeakMap(), re = new WeakMap(), c(
|
|
1456
|
-
let pe =
|
|
1455
|
+
nt = new WeakMap(), ie = new WeakMap(), re = new WeakMap(), c(ze, "NineTable");
|
|
1456
|
+
let pe = ze;
|
|
1457
1457
|
customElements.get("nine-table") || customElements.define("nine-table", pe);
|
|
1458
1458
|
const mt = class mt extends HTMLElement {
|
|
1459
1459
|
// π 컀μ€ν
μ€νμΌμ© μΊμ μΆκ°
|