@ninebone/table 0.0.105 β 0.0.106
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 +247 -246
- package/dist/nine-table.js.map +1 -1
- package/dist/nine-table.umd.js +5 -5
- package/dist/nine-table.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/nine-table.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
var xe = Object.defineProperty;
|
|
2
|
-
var
|
|
2
|
+
var Ee = (y) => {
|
|
3
3
|
throw TypeError(y);
|
|
4
4
|
};
|
|
5
|
-
var
|
|
5
|
+
var Te = (y, s, t) => s in y ? xe(y, s, { enumerable: !0, configurable: !0, writable: !0, value: t }) : y[s] = t;
|
|
6
6
|
var a = (y, s) => xe(y, "name", { value: s, configurable: !0 });
|
|
7
|
-
var
|
|
8
|
-
var e = (y, s, t) => (
|
|
7
|
+
var v = (y, s, t) => Te(y, typeof s != "symbol" ? s + "" : s, t), Se = (y, s, t) => s.has(y) || Ee("Cannot " + t);
|
|
8
|
+
var e = (y, s, t) => (Se(y, s, "read from private field"), t ? t.call(y) : s.get(y)), g = (y, s, t) => s.has(y) ? Ee("Cannot add the same private member more than once") : s instanceof WeakSet ? s.add(y) : s.set(y, t), m = (y, s, t, i) => (Se(y, s, "write to private field"), i ? i.call(y, t) : s.set(y, t), t);
|
|
9
9
|
var Re = (y, s, t, i) => ({
|
|
10
10
|
set _(n) {
|
|
11
11
|
m(y, s, n, t);
|
|
@@ -15,83 +15,83 @@ var Re = (y, s, t, i) => ({
|
|
|
15
15
|
}
|
|
16
16
|
});
|
|
17
17
|
import { trace as ke } from "@ninebone/util";
|
|
18
|
-
const
|
|
18
|
+
const be = class be extends ke.constructor {
|
|
19
19
|
constructor() {
|
|
20
20
|
super(), this.init("nine-table", "green");
|
|
21
21
|
}
|
|
22
22
|
};
|
|
23
|
-
a(
|
|
24
|
-
let
|
|
25
|
-
const
|
|
26
|
-
var q,
|
|
27
|
-
const
|
|
23
|
+
a(be, "Trace");
|
|
24
|
+
let re = be;
|
|
25
|
+
const F = new re();
|
|
26
|
+
var q, M, p, $, W, H, U, O, K;
|
|
27
|
+
const ge = class ge extends HTMLElement {
|
|
28
28
|
constructor() {
|
|
29
29
|
super();
|
|
30
30
|
g(this, q);
|
|
31
|
-
g(this,
|
|
31
|
+
g(this, M, !1);
|
|
32
32
|
g(this, p);
|
|
33
33
|
g(this, $);
|
|
34
|
-
g(this, M);
|
|
35
34
|
g(this, W);
|
|
36
|
-
g(this,
|
|
35
|
+
g(this, H);
|
|
36
|
+
g(this, U, /* @__PURE__ */ a(() => {
|
|
37
37
|
if (!e(this, q)) return;
|
|
38
38
|
const t = e(this, q).querySelector(".ng-container-body");
|
|
39
|
-
t && (m(this,
|
|
39
|
+
t && (m(this, H, new ResizeObserver(() => {
|
|
40
40
|
this.refresh();
|
|
41
|
-
})), e(this,
|
|
41
|
+
})), e(this, H).observe(t));
|
|
42
42
|
}, "#observeResize"));
|
|
43
|
-
|
|
44
|
-
if (!e(this, q) || !e(this, p) || e(this,
|
|
43
|
+
v(this, "refresh", /* @__PURE__ */ a(() => {
|
|
44
|
+
if (!e(this, q) || !e(this, p) || e(this, M)) return;
|
|
45
45
|
const t = e(this, p).container, i = t.querySelector("table");
|
|
46
46
|
if (!i) return;
|
|
47
|
-
const n = e(this, p).track,
|
|
47
|
+
const n = e(this, p).track, o = e(this, p).thumb, r = e(this, q).querySelector(".ng-container-bottom"), c = t.clientWidth, u = i.scrollWidth;
|
|
48
48
|
if (c !== 0 && u > c)
|
|
49
49
|
r && (r.style.display = "flex");
|
|
50
50
|
else {
|
|
51
51
|
r && (r.style.display = "none");
|
|
52
52
|
return;
|
|
53
53
|
}
|
|
54
|
-
const
|
|
55
|
-
if (
|
|
56
|
-
const b = Math.max(Math.min(
|
|
57
|
-
|
|
54
|
+
const l = n.clientWidth;
|
|
55
|
+
if (l <= 0) return;
|
|
56
|
+
const b = Math.max(Math.min(l * (c / u), l), 20);
|
|
57
|
+
o.style.width = `${b}px`;
|
|
58
58
|
let h = 0;
|
|
59
59
|
const f = i.style.transform;
|
|
60
60
|
if (f && f.includes("translateX")) {
|
|
61
|
-
const
|
|
62
|
-
|
|
61
|
+
const x = f.match(/translateX\(([-\d.]+)px\)/);
|
|
62
|
+
x && x[1] && (h = parseFloat(x[1]));
|
|
63
63
|
} else
|
|
64
64
|
h = parseInt(i.style.left || 0, 10);
|
|
65
|
-
let d = parseInt(Math.abs(h) *
|
|
65
|
+
let d = parseInt(Math.abs(h) * l / u, 10);
|
|
66
66
|
d < 0 && (d = 0);
|
|
67
|
-
const
|
|
68
|
-
d >
|
|
67
|
+
const E = l - b;
|
|
68
|
+
d > E && (d = E), o.style.left = `${d}px`, e(this, p).left.disabled = d === 0, e(this, p).right.disabled = d >= E - 1;
|
|
69
69
|
}, "refresh"));
|
|
70
|
-
g(this,
|
|
70
|
+
g(this, O, /* @__PURE__ */ a((t) => {
|
|
71
71
|
if (!e(this, p)) return !1;
|
|
72
72
|
const i = e(this, p).container, n = i.querySelector("table");
|
|
73
73
|
if (!n) return !1;
|
|
74
|
-
const
|
|
74
|
+
const o = e(this, p).track.getBoundingClientRect(), r = e(this, p).thumb.clientWidth;
|
|
75
75
|
let c = t;
|
|
76
76
|
c < 0 && (c = 0);
|
|
77
|
-
const u =
|
|
77
|
+
const u = o.width - r;
|
|
78
78
|
c > u && (c = u), c = parseInt(c, 10), e(this, p).thumb.style.left = `${c}px`, e(this, p).left.disabled = c === 0, e(this, p).right.disabled = c >= u - 1;
|
|
79
|
-
const
|
|
80
|
-
let h = u > 0 ? -c * (b -
|
|
81
|
-
return -h > b -
|
|
79
|
+
const l = i.clientWidth, b = n.scrollWidth;
|
|
80
|
+
let h = u > 0 ? -c * (b - l) / u : 0;
|
|
81
|
+
return -h > b - l && (h = -(b - l)), -h + 5 > b - l && (h = -(b - l)), l >= b && (h = 0), n.style.transform = `translateX(${h}px)`, c > 0 && c < u - 1;
|
|
82
82
|
}, "#thumbMoveTo"));
|
|
83
83
|
g(this, K, /* @__PURE__ */ a(() => {
|
|
84
84
|
const t = /* @__PURE__ */ a((n) => {
|
|
85
|
-
clearInterval(e(this, $)), clearInterval(e(this,
|
|
86
|
-
const
|
|
87
|
-
e(this,
|
|
88
|
-
clearInterval(e(this, $)), m(this,
|
|
85
|
+
clearInterval(e(this, $)), clearInterval(e(this, W));
|
|
86
|
+
const o = parseInt(e(this, p).thumb.style.left || 0, 10);
|
|
87
|
+
e(this, O).call(this, o + n), m(this, $, setInterval(() => {
|
|
88
|
+
clearInterval(e(this, $)), m(this, W, setInterval(() => {
|
|
89
89
|
const r = parseInt(e(this, p).thumb.style.left || 0, 10);
|
|
90
|
-
e(this,
|
|
90
|
+
e(this, O).call(this, r + n) || clearInterval(e(this, W));
|
|
91
91
|
}, 50));
|
|
92
92
|
}, 500));
|
|
93
93
|
}, "delayScroll"), i = /* @__PURE__ */ a(() => {
|
|
94
|
-
clearInterval(e(this, $)), clearInterval(e(this,
|
|
94
|
+
clearInterval(e(this, $)), clearInterval(e(this, W));
|
|
95
95
|
}, "clearTimer");
|
|
96
96
|
["mouseup", "mouseleave", "touchend"].forEach((n) => {
|
|
97
97
|
e(this, p).left.addEventListener(n, i), e(this, p).right.addEventListener(n, i), e(this, p).track.addEventListener(n, i);
|
|
@@ -102,19 +102,19 @@ const be = class be extends HTMLElement {
|
|
|
102
102
|
}), e(this, p).left.addEventListener("touchstart", () => t(-20)), e(this, p).right.addEventListener("touchstart", () => t(20)), e(this, p).track.addEventListener("mousedown", (n) => {
|
|
103
103
|
if (n.button !== 0) return;
|
|
104
104
|
n.preventDefault();
|
|
105
|
-
const
|
|
106
|
-
e(this,
|
|
105
|
+
const o = e(this, p).track.getBoundingClientRect(), r = e(this, p).thumb.clientWidth;
|
|
106
|
+
e(this, O).call(this, n.clientX - o.left - r / 2);
|
|
107
107
|
}), e(this, p).thumb.addEventListener("mousedown", (n) => {
|
|
108
108
|
if (n.button !== 0) return;
|
|
109
|
-
n.stopPropagation(), n.preventDefault(), m(this,
|
|
110
|
-
const
|
|
111
|
-
if (!e(this,
|
|
109
|
+
n.stopPropagation(), n.preventDefault(), m(this, M, !0), this.shiftX = n.clientX - e(this, p).thumb.getBoundingClientRect().left;
|
|
110
|
+
const o = /* @__PURE__ */ a((c) => {
|
|
111
|
+
if (!e(this, M)) return;
|
|
112
112
|
const u = e(this, p).track.getBoundingClientRect();
|
|
113
|
-
e(this,
|
|
113
|
+
e(this, O).call(this, c.clientX - u.left - this.shiftX);
|
|
114
114
|
}, "onMouseMove"), r = /* @__PURE__ */ a(() => {
|
|
115
|
-
m(this,
|
|
115
|
+
m(this, M, !1), i(), document.removeEventListener("mousemove", o), document.removeEventListener("mouseup", r), this.refresh();
|
|
116
116
|
}, "onMouseUp");
|
|
117
|
-
document.addEventListener("mousemove",
|
|
117
|
+
document.addEventListener("mousemove", o), document.addEventListener("mouseup", r);
|
|
118
118
|
});
|
|
119
119
|
}, "#init"));
|
|
120
120
|
}
|
|
@@ -195,99 +195,99 @@ const be = class be extends HTMLElement {
|
|
|
195
195
|
thumb: this.querySelector(".ng-scroll-thumb"),
|
|
196
196
|
left: this.querySelector(".ng-scroll-left"),
|
|
197
197
|
right: this.querySelector(".ng-scroll-right")
|
|
198
|
-
}), e(this, K).call(this), e(this,
|
|
198
|
+
}), e(this, K).call(this), e(this, U).call(this), this.refresh();
|
|
199
199
|
}, "initWhenReady");
|
|
200
200
|
t();
|
|
201
201
|
}
|
|
202
202
|
disconnectedCallback() {
|
|
203
|
-
e(this,
|
|
203
|
+
e(this, H) && e(this, H).disconnect();
|
|
204
204
|
}
|
|
205
205
|
};
|
|
206
|
-
q = new WeakMap(),
|
|
207
|
-
let
|
|
208
|
-
customElements.get("nine-table-hscrollbar") || customElements.define("nine-table-hscrollbar",
|
|
209
|
-
var
|
|
206
|
+
q = new WeakMap(), M = new WeakMap(), p = new WeakMap(), $ = new WeakMap(), W = new WeakMap(), H = new WeakMap(), U = new WeakMap(), O = new WeakMap(), K = new WeakMap(), a(ge, "NineTableHScrollBar");
|
|
207
|
+
let oe = ge;
|
|
208
|
+
customElements.get("nine-table-hscrollbar") || customElements.define("nine-table-hscrollbar", oe);
|
|
209
|
+
var A, Z;
|
|
210
210
|
const P = class P extends HTMLElement {
|
|
211
211
|
constructor() {
|
|
212
212
|
super();
|
|
213
|
-
g(this,
|
|
214
|
-
|
|
213
|
+
g(this, A, null);
|
|
214
|
+
v(this, "init", /* @__PURE__ */ a((t) => {
|
|
215
215
|
if (!t) return;
|
|
216
|
-
const i = /* @__PURE__ */ a((
|
|
216
|
+
const i = /* @__PURE__ */ a((l) => {
|
|
217
217
|
const b = /* @__PURE__ */ a((f) => {
|
|
218
218
|
if (f.querySelector("colgroup")) return;
|
|
219
|
-
const d = f.querySelector("tbody tr") || f.querySelector("tr"),
|
|
220
|
-
for (let R = 0; R <
|
|
221
|
-
const
|
|
222
|
-
|
|
219
|
+
const d = f.querySelector("tbody tr") || f.querySelector("tr"), E = d ? d.querySelectorAll("th, td").length : 1, x = document.createElement("colgroup"), _ = Math.max(Math.floor((f.clientWidth || 600) / E), 100);
|
|
220
|
+
for (let R = 0; R < E; R++) {
|
|
221
|
+
const ne = document.createElement("col");
|
|
222
|
+
ne.setAttribute("width", _), x.appendChild(ne);
|
|
223
223
|
}
|
|
224
|
-
f.prepend(
|
|
224
|
+
f.prepend(x);
|
|
225
225
|
}, "ensureColgroup"), h = /* @__PURE__ */ a((f) => {
|
|
226
226
|
if (f.querySelector("thead")) return;
|
|
227
|
-
const d = document.createElement("thead"),
|
|
228
|
-
|
|
227
|
+
const d = document.createElement("thead"), E = f.querySelector("colgroup");
|
|
228
|
+
E ? E.after(d) : f.prepend(d);
|
|
229
229
|
}, "ensureThead");
|
|
230
|
-
return b(
|
|
230
|
+
return b(l), h(l), l.classList.add("nine-table-element"), l;
|
|
231
231
|
}, "initializeTable"), n = t.cloneNode(!0);
|
|
232
|
-
m(this,
|
|
233
|
-
const
|
|
234
|
-
const f =
|
|
235
|
-
return d.forEach((
|
|
236
|
-
const R =
|
|
237
|
-
(h ? !R || R === "" : R === b) ||
|
|
238
|
-
}),
|
|
239
|
-
d[
|
|
240
|
-
const R =
|
|
241
|
-
R[
|
|
232
|
+
m(this, A, i(n)), e(this, A).style.display = "table";
|
|
233
|
+
const o = this.querySelector(".ng-container-left"), r = this.querySelector(".ng-container-body"), c = this.querySelector(".ng-container-right"), u = /* @__PURE__ */ a((l, b, h = !1) => {
|
|
234
|
+
const f = l.cloneNode(!0), d = Array.from(f.querySelectorAll("colgroup col")), E = [];
|
|
235
|
+
return d.forEach((x, _) => {
|
|
236
|
+
const R = x.getAttribute("fixed");
|
|
237
|
+
(h ? !R || R === "" : R === b) || E.push(_);
|
|
238
|
+
}), E.reverse().forEach((x) => {
|
|
239
|
+
d[x] && d[x].remove(), f.querySelectorAll("tr").forEach((_) => {
|
|
240
|
+
const R = _.querySelectorAll("th, td");
|
|
241
|
+
R[x] && R[x].remove();
|
|
242
242
|
});
|
|
243
243
|
}), f;
|
|
244
244
|
}, "filterTableByFixed");
|
|
245
245
|
if (r) {
|
|
246
|
-
const
|
|
247
|
-
r.innerHTML = "", r.appendChild(
|
|
246
|
+
const l = u(e(this, A), null, !0);
|
|
247
|
+
r.innerHTML = "", r.appendChild(l);
|
|
248
248
|
}
|
|
249
|
-
if (
|
|
250
|
-
const
|
|
249
|
+
if (o) {
|
|
250
|
+
const l = u(e(this, A), "left", !1);
|
|
251
251
|
let b = 0;
|
|
252
|
-
|
|
252
|
+
l.querySelectorAll("col").forEach((f) => {
|
|
253
253
|
const d = parseInt(f.getAttribute("width"), 10);
|
|
254
254
|
isNaN(d) || (b += d);
|
|
255
|
-
}),
|
|
255
|
+
}), o.innerHTML = "", o.appendChild(l);
|
|
256
256
|
const h = b > 0 ? b : 0;
|
|
257
|
-
|
|
257
|
+
o.style.flex = `0 0 ${h}px`, o.style.width = `${h}px`;
|
|
258
258
|
}
|
|
259
259
|
if (c) {
|
|
260
|
-
const
|
|
260
|
+
const l = u(e(this, A), "right", !1);
|
|
261
261
|
let b = 0;
|
|
262
|
-
|
|
262
|
+
l.querySelectorAll("col").forEach((f) => {
|
|
263
263
|
const d = parseInt(f.getAttribute("width"), 10);
|
|
264
264
|
isNaN(d) || (b += d);
|
|
265
|
-
}), c.innerHTML = "", c.appendChild(
|
|
265
|
+
}), c.innerHTML = "", c.appendChild(l);
|
|
266
266
|
const h = b > 0 ? b : 0;
|
|
267
267
|
c.style.flex = `0 0 ${h}px`, c.style.width = `${h}px`;
|
|
268
268
|
}
|
|
269
269
|
if (r) {
|
|
270
|
-
const
|
|
271
|
-
r.style.overflowY =
|
|
270
|
+
const l = this.getRowCount();
|
|
271
|
+
r.style.overflowY = l > 10 ? "auto" : "hidden", r.addEventListener("scroll", () => {
|
|
272
272
|
const b = this.querySelector("nine-table-hscrollbar");
|
|
273
273
|
b && typeof b.refresh == "function" && b.refresh();
|
|
274
274
|
});
|
|
275
275
|
}
|
|
276
276
|
setTimeout(() => {
|
|
277
|
-
const
|
|
278
|
-
|
|
279
|
-
}, 0),
|
|
277
|
+
const l = this.querySelector("nine-table-hscrollbar");
|
|
278
|
+
l && typeof l.refresh == "function" && l.refresh();
|
|
279
|
+
}, 0), F.log(`NineTableSheet 3-split initialized with rows: ${this.getRowCount()}`);
|
|
280
280
|
}, "init"));
|
|
281
|
-
|
|
282
|
-
|
|
281
|
+
v(this, "getRowCount", /* @__PURE__ */ a(() => e(this, A) ? e(this, A).querySelectorAll("tbody tr").length : 0, "getRowCount"));
|
|
282
|
+
v(this, "scrollToX", /* @__PURE__ */ a((t) => {
|
|
283
283
|
const i = this.querySelector(".ng-container-body");
|
|
284
284
|
i && (i.scrollLeft = t);
|
|
285
285
|
}, "scrollToX"));
|
|
286
|
-
|
|
286
|
+
v(this, "scrollToY", /* @__PURE__ */ a((t) => {
|
|
287
287
|
const i = this.querySelector(".ng-container-body");
|
|
288
288
|
i && (i.scrollTop = t);
|
|
289
289
|
}, "scrollToY"));
|
|
290
|
-
g(this,
|
|
290
|
+
g(this, Z, /* @__PURE__ */ a(() => {
|
|
291
291
|
const t = P.SCROLLBAR_SIZE;
|
|
292
292
|
this.innerHTML = `
|
|
293
293
|
<style>
|
|
@@ -406,36 +406,36 @@ const P = class P extends HTMLElement {
|
|
|
406
406
|
}, "#render"));
|
|
407
407
|
}
|
|
408
408
|
connectedCallback() {
|
|
409
|
-
e(this,
|
|
409
|
+
e(this, Z).call(this);
|
|
410
410
|
}
|
|
411
411
|
disconnectedCallback() {
|
|
412
|
-
this.innerHTML = "",
|
|
412
|
+
this.innerHTML = "", F.log("NineTableSheet destroyed.");
|
|
413
413
|
}
|
|
414
414
|
};
|
|
415
|
-
|
|
416
|
-
let
|
|
417
|
-
customElements.get("nine-table-sheet") || customElements.define("nine-table-sheet",
|
|
418
|
-
var
|
|
419
|
-
const
|
|
415
|
+
A = new WeakMap(), Z = new WeakMap(), a(P, "NineTableSheet"), v(P, "SCROLLBAR_SIZE", 16);
|
|
416
|
+
let le = P;
|
|
417
|
+
customElements.get("nine-table-sheet") || customElements.define("nine-table-sheet", le);
|
|
418
|
+
var j;
|
|
419
|
+
const pe = class pe extends HTMLElement {
|
|
420
420
|
constructor() {
|
|
421
421
|
super();
|
|
422
|
-
g(this,
|
|
422
|
+
g(this, j, /* @__PURE__ */ a(() => {
|
|
423
423
|
const t = this.querySelector(".nine-tab-bar");
|
|
424
424
|
t && (t.addEventListener("click", (i) => {
|
|
425
425
|
const n = i.target.closest(".nine-tab-item");
|
|
426
426
|
if (!n) return;
|
|
427
|
-
const
|
|
428
|
-
this.switchSheet(r,
|
|
427
|
+
const o = i.ctrlKey || i.metaKey || i.shiftKey, r = parseInt(n.dataset.index, 10);
|
|
428
|
+
this.switchSheet(r, o);
|
|
429
429
|
}), this.switchSheet(0, !1));
|
|
430
430
|
}, "#init"));
|
|
431
|
-
|
|
431
|
+
v(this, "switchSheet", /* @__PURE__ */ a((t, i = !1) => {
|
|
432
432
|
const n = /* @__PURE__ */ a(() => {
|
|
433
433
|
const h = this.querySelector("nine-table-sheets-body");
|
|
434
434
|
h.querySelectorAll("nine-splitter").forEach((d) => {
|
|
435
|
-
const
|
|
436
|
-
|
|
435
|
+
const E = parseInt(d.dataset.splitIndex, 10), x = h.querySelector(`nine-table-sheet[data-index="${E - 1}"]`), _ = h.querySelector(`nine-table-sheet[data-index="${E}"]`);
|
|
436
|
+
x && _ && x.classList.contains("active") && _.classList.contains("active") ? d.classList.add("active") : d.classList.remove("active");
|
|
437
437
|
});
|
|
438
|
-
}, "updateSplitters"),
|
|
438
|
+
}, "updateSplitters"), o = this.querySelector(".nine-tab-bar"), r = this.querySelector("nine-table-sheets-body"), c = o.querySelectorAll(".nine-tab-item"), u = r.querySelectorAll("nine-table-sheet");
|
|
439
439
|
if (!c[t]) return;
|
|
440
440
|
if (!i)
|
|
441
441
|
c.forEach((h, f) => {
|
|
@@ -446,21 +446,21 @@ const ge = class ge extends HTMLElement {
|
|
|
446
446
|
h.classList.toggle("active", f === t);
|
|
447
447
|
});
|
|
448
448
|
else {
|
|
449
|
-
const h = c[t], f =
|
|
449
|
+
const h = c[t], f = o.querySelectorAll(".nine-tab-item.active");
|
|
450
450
|
if (h.classList.contains("active") && f.length <= 1)
|
|
451
451
|
return;
|
|
452
452
|
h.classList.toggle("active");
|
|
453
453
|
const d = r.querySelector(`nine-table-sheet[data-index="${t}"]`);
|
|
454
454
|
d && (d.classList.toggle("active"), d.classList.contains("active") || (d.style.flex = ""));
|
|
455
455
|
}
|
|
456
|
-
const
|
|
457
|
-
if (
|
|
458
|
-
const h = 1 /
|
|
459
|
-
|
|
456
|
+
const l = Array.from(r.querySelectorAll("nine-table-sheet.active"));
|
|
457
|
+
if (l.length > 1) {
|
|
458
|
+
const h = 1 / l.length;
|
|
459
|
+
l.forEach((f) => {
|
|
460
460
|
(!f.style.flex || f.style.flex === "1 1 100%") && (f.style.flex = `${h} ${h} 0px`);
|
|
461
461
|
});
|
|
462
462
|
} else
|
|
463
|
-
|
|
463
|
+
l.forEach((h) => {
|
|
464
464
|
h.style.flex = "1 1 100%";
|
|
465
465
|
});
|
|
466
466
|
n();
|
|
@@ -472,36 +472,36 @@ const ge = class ge extends HTMLElement {
|
|
|
472
472
|
}, "switchSheet"));
|
|
473
473
|
}
|
|
474
474
|
connectedCallback() {
|
|
475
|
-
e(this,
|
|
475
|
+
e(this, j).call(this);
|
|
476
476
|
}
|
|
477
477
|
};
|
|
478
|
-
|
|
479
|
-
let
|
|
480
|
-
customElements.get("nine-table-sheets") || customElements.define("nine-table-sheets",
|
|
481
|
-
var
|
|
482
|
-
const
|
|
478
|
+
j = new WeakMap(), a(pe, "NineTableSheets");
|
|
479
|
+
let ae = pe;
|
|
480
|
+
customElements.get("nine-table-sheets") || customElements.define("nine-table-sheets", ae);
|
|
481
|
+
var L, X, G, V, J;
|
|
482
|
+
const ye = class ye {
|
|
483
483
|
constructor(s) {
|
|
484
|
-
g(this,
|
|
485
|
-
g(this,
|
|
486
|
-
g(this,
|
|
487
|
-
const s = e(this,
|
|
488
|
-
s && (m(this,
|
|
484
|
+
g(this, L);
|
|
485
|
+
g(this, X, null);
|
|
486
|
+
g(this, G, /* @__PURE__ */ a(() => {
|
|
487
|
+
const s = e(this, L).host;
|
|
488
|
+
s && (m(this, X, new ResizeObserver((t) => {
|
|
489
489
|
for (let i of t)
|
|
490
|
-
s.getAttribute("auto-height") === "true" && e(this,
|
|
491
|
-
})), e(this,
|
|
490
|
+
s.getAttribute("auto-height") === "true" && e(this, V).call(this, s);
|
|
491
|
+
})), e(this, X).observe(s));
|
|
492
492
|
}, "#observeResize"));
|
|
493
|
-
g(this,
|
|
494
|
-
var
|
|
495
|
-
const t = (
|
|
493
|
+
g(this, V, /* @__PURE__ */ a((s) => {
|
|
494
|
+
var _, R;
|
|
495
|
+
const t = (_ = s.shadowRoot) == null ? void 0 : _.querySelector("nine-table-sheet.active");
|
|
496
496
|
if (!t) return;
|
|
497
|
-
const i = ((R = t.getRowCount) == null ? void 0 : R.call(t)) || 0, n = parseInt(s.getAttribute("max-display-row"), 10) || 10,
|
|
498
|
-
s.style.height = `${
|
|
499
|
-
const
|
|
500
|
-
|
|
497
|
+
const i = ((R = t.getRowCount) == null ? void 0 : R.call(t)) || 0, n = parseInt(s.getAttribute("max-display-row"), 10) || 10, o = Math.min(i, n), r = t.querySelector("tbody tr") || t.querySelector("tr"), c = r ? r.getBoundingClientRect().height : 32, u = e(this, L).querySelector("nine-table-header"), l = e(this, L).querySelector("nine-table-sheets-footer"), b = u ? u.getBoundingClientRect().height : 40, h = l ? l.getBoundingClientRect().height : 32, d = b + h + 16, E = o * c + d;
|
|
498
|
+
s.style.height = `${E}px`, s.style.maxHeight = `${n * c + d}px`;
|
|
499
|
+
const x = e(this, L).querySelector("nine-table-sheets-body");
|
|
500
|
+
x && (x.style.overflowY = i > n ? "auto" : "hidden");
|
|
501
501
|
}, "#applyAutoHeight"));
|
|
502
|
-
g(this,
|
|
503
|
-
const s = e(this,
|
|
504
|
-
e(this,
|
|
502
|
+
g(this, J, /* @__PURE__ */ a(() => {
|
|
503
|
+
const s = e(this, L).host, i = Array.from(s.children).filter((u) => u.tagName === "TABLE"), n = s.getAttribute("auto-height") === "true", o = i.map((u, l) => `<nine-table-sheet class="${l === 0 ? "active" : ""}" data-index="${l}"></nine-table-sheet>`).join(""), r = i.map((u, l) => `<div class="nine-tab-item ${l === 0 ? "active" : ""}" data-index="${l}">Sheet ${l + 1}</div>`).join("");
|
|
504
|
+
e(this, L).innerHTML = `
|
|
505
505
|
<style>
|
|
506
506
|
:host {
|
|
507
507
|
display: flex;
|
|
@@ -589,7 +589,7 @@ const pe = class pe {
|
|
|
589
589
|
<nine-table-body>
|
|
590
590
|
<nine-table-summary></nine-table-summary>
|
|
591
591
|
<nine-table-sheets>
|
|
592
|
-
<nine-table-sheets-body>${
|
|
592
|
+
<nine-table-sheets-body>${o}</nine-table-sheets-body>
|
|
593
593
|
<nine-table-sheets-footer>
|
|
594
594
|
<div class="nine-tab-bar">${r}</div>
|
|
595
595
|
<div class="sheets-counter">Total : <span id="row-count">0</span></div>
|
|
@@ -599,25 +599,25 @@ const pe = class pe {
|
|
|
599
599
|
</nine-table-body>
|
|
600
600
|
<nine-table-footer></nine-table-footer>
|
|
601
601
|
`;
|
|
602
|
-
const c = e(this,
|
|
603
|
-
c == null || c.forEach((u,
|
|
604
|
-
i[
|
|
605
|
-
u.init(i[
|
|
602
|
+
const c = e(this, L).querySelectorAll("nine-table-sheet");
|
|
603
|
+
c == null || c.forEach((u, l) => {
|
|
604
|
+
i[l] && setTimeout(() => {
|
|
605
|
+
u.init(i[l]), n && e(this, V).call(this, s);
|
|
606
606
|
});
|
|
607
607
|
});
|
|
608
608
|
}, "#render"));
|
|
609
|
-
m(this,
|
|
609
|
+
m(this, L, s), e(this, J).call(this), e(this, G).call(this);
|
|
610
610
|
}
|
|
611
611
|
};
|
|
612
|
-
|
|
613
|
-
let
|
|
614
|
-
var
|
|
615
|
-
const
|
|
612
|
+
L = new WeakMap(), X = new WeakMap(), G = new WeakMap(), V = new WeakMap(), J = new WeakMap(), a(ye, "LayoutManager");
|
|
613
|
+
let ce = ye;
|
|
614
|
+
var C, z;
|
|
615
|
+
const we = class we {
|
|
616
616
|
constructor(s) {
|
|
617
|
-
g(this,
|
|
617
|
+
g(this, C);
|
|
618
618
|
g(this, z, -1);
|
|
619
|
-
|
|
620
|
-
m(this,
|
|
619
|
+
v(this, "count", /* @__PURE__ */ a(() => e(this, C).rawRecords.length, "count"));
|
|
620
|
+
m(this, C, s);
|
|
621
621
|
}
|
|
622
622
|
get at() {
|
|
623
623
|
return e(this, z);
|
|
@@ -625,165 +625,166 @@ const ye = class ye {
|
|
|
625
625
|
set at(s) {
|
|
626
626
|
var i, n;
|
|
627
627
|
m(this, z, parseInt(s, 10));
|
|
628
|
-
const t = ((n = (i = e(this,
|
|
628
|
+
const t = ((n = (i = e(this, C).owner).querySelector) == null ? void 0 : n.call(i, ".ng-container-body")) || e(this, C).owner.body;
|
|
629
629
|
t && !t.querySelector(`tbody.bindable tr[data-row="${e(this, z)}"]`) && setTimeout(() => {
|
|
630
|
-
var
|
|
631
|
-
(r = (
|
|
630
|
+
var o, r;
|
|
631
|
+
(r = (o = e(this, C).owner).scrollTo_V1) == null || r.call(o, e(this, z));
|
|
632
632
|
});
|
|
633
633
|
}
|
|
634
634
|
};
|
|
635
|
-
|
|
636
|
-
let
|
|
637
|
-
var
|
|
638
|
-
const
|
|
635
|
+
C = new WeakMap(), z = new WeakMap(), a(we, "ngRow");
|
|
636
|
+
let he = we;
|
|
637
|
+
var S, w, k, D, Q, I, ee, Y, te, se, N;
|
|
638
|
+
const T = class T {
|
|
639
639
|
constructor(s, t) {
|
|
640
|
-
g(this,
|
|
640
|
+
g(this, S);
|
|
641
641
|
g(this, w);
|
|
642
|
-
g(this,
|
|
643
|
-
g(this,
|
|
644
|
-
g(this,
|
|
645
|
-
g(this,
|
|
646
|
-
g(this,
|
|
647
|
-
m(this,
|
|
648
|
-
const s = e(this,
|
|
642
|
+
g(this, k, []);
|
|
643
|
+
g(this, D, []);
|
|
644
|
+
g(this, Q, 0);
|
|
645
|
+
g(this, I, []);
|
|
646
|
+
g(this, ee, /* @__PURE__ */ a(() => {
|
|
647
|
+
m(this, I, []);
|
|
648
|
+
const s = e(this, S).template || [];
|
|
649
649
|
Array.from(s).forEach((t) => {
|
|
650
650
|
var i;
|
|
651
|
-
e(this,
|
|
651
|
+
e(this, I).push(((i = t.getBoundingClientRect) == null ? void 0 : i.call(t).height) || 24);
|
|
652
652
|
}), (e(this, w).rawRecords || []).forEach((t) => {
|
|
653
|
-
t.__ng || (t.__ng = e(this,
|
|
653
|
+
t.__ng || (t.__ng = e(this, Y).call(this)), t.__ng.height = e(this, I).slice();
|
|
654
654
|
});
|
|
655
655
|
}, "#initialize"));
|
|
656
|
-
|
|
656
|
+
v(this, "set", /* @__PURE__ */ a((s) => {
|
|
657
657
|
this.clear(), this.add(s, !1);
|
|
658
658
|
}, "set"));
|
|
659
|
-
g(this,
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
}, "#getDefaultMeta"));
|
|
671
|
-
x(this, "reset", /* @__PURE__ */ a(() => {
|
|
672
|
-
m(this, _, []), m(this, B, []);
|
|
659
|
+
g(this, Y, /* @__PURE__ */ a(() => ({
|
|
660
|
+
rowState: T.ROW_STATE.EMPTY,
|
|
661
|
+
deleted: !1,
|
|
662
|
+
filtered: !1,
|
|
663
|
+
height: e(this, I).slice(),
|
|
664
|
+
o: {},
|
|
665
|
+
c: {},
|
|
666
|
+
_: [0, 0, 0, 0, T.ROW_STATE.EMPTY, !1, !1, !0, !1, !0, !0, !1, e(this, I).slice(), -1, {}, {}]
|
|
667
|
+
}), "#getDefaultMeta"));
|
|
668
|
+
v(this, "reset", /* @__PURE__ */ a(() => {
|
|
669
|
+
m(this, k, []), m(this, D, []);
|
|
673
670
|
}, "reset"));
|
|
674
|
-
|
|
671
|
+
v(this, "clear", /* @__PURE__ */ a(() => {
|
|
675
672
|
var s;
|
|
676
|
-
e(this, w).rawRecords = [], m(this,
|
|
673
|
+
e(this, w).rawRecords = [], m(this, k, []), m(this, D, []), (s = e(this, w).viewRecords) != null && s.reset && e(this, w).viewRecords.reset();
|
|
677
674
|
}, "clear"));
|
|
678
|
-
g(this,
|
|
675
|
+
g(this, te, /* @__PURE__ */ a((s) => {
|
|
679
676
|
var n;
|
|
680
677
|
Array.isArray(s) || (s = [s]);
|
|
681
|
-
const t = typeof ((n = e(this,
|
|
682
|
-
return s.forEach((
|
|
678
|
+
const t = typeof ((n = e(this, S).fields) == null ? void 0 : n.get) == "function" ? e(this, S).fields.get() : Object.keys(s[0] || {}), i = [];
|
|
679
|
+
return s.forEach((o) => {
|
|
683
680
|
const r = { v: [] };
|
|
684
681
|
t.forEach((c) => {
|
|
685
|
-
r.v.push(
|
|
682
|
+
r.v.push(o[c] !== void 0 && o[c] !== null ? o[c] : "");
|
|
686
683
|
}), i.push(r);
|
|
687
684
|
}), i;
|
|
688
685
|
}, "#json2Array"));
|
|
689
|
-
g(this,
|
|
690
|
-
|
|
691
|
-
t.__ng = e(this, V).call(this), t.__ng.rowid = this.nextId, t.__ng.rowState = ((i = ninegrid.ROW_STATE) == null ? void 0 : i.INSERT) || "INSERT", t.__ng._[0] = t.__ng.rowid;
|
|
686
|
+
g(this, se, /* @__PURE__ */ a((s) => (Array.isArray(s) || (s = [s]), s.forEach((t) => {
|
|
687
|
+
t.__ng = e(this, Y).call(this), t.__ng.rowid = this.nextId, t.__ng.rowState = T.ROW_STATE.INSERT, t.__ng._[0] = t.__ng.rowid;
|
|
692
688
|
}), s), "#defaultInsert"));
|
|
693
|
-
|
|
694
|
-
var
|
|
689
|
+
v(this, "add", /* @__PURE__ */ a((s, t = !0) => {
|
|
690
|
+
var o;
|
|
695
691
|
s === void 0 && (s = {});
|
|
696
|
-
const i = e(this,
|
|
697
|
-
e(this, w).rawRecords = e(this, w).rawRecords.concat(e(this,
|
|
692
|
+
const i = e(this, te).call(this, s);
|
|
693
|
+
e(this, w).rawRecords = e(this, w).rawRecords.concat(e(this, se).call(this, i)), this.resetRecords();
|
|
698
694
|
const n = this.count() - 1;
|
|
699
695
|
return t || i.forEach((r, c) => {
|
|
700
|
-
var o;
|
|
701
696
|
const u = e(this, w).rawRecords[n - c];
|
|
702
|
-
u && (u.__ng.rowState =
|
|
703
|
-
}), (
|
|
697
|
+
u && (u.__ng.rowState = T.ROW_STATE.EMPTY);
|
|
698
|
+
}), (o = e(this, w).viewRecords) != null && o.reset && e(this, w).viewRecords.reset(), n;
|
|
704
699
|
}, "add"));
|
|
705
|
-
|
|
700
|
+
v(this, "delete", /* @__PURE__ */ a((s) => {
|
|
706
701
|
var i;
|
|
707
702
|
let t = [];
|
|
708
|
-
Array.isArray(s) ? t = s : typeof s > "u" ? t = [e(this, w).owner.row.at] : t = [parseInt(s, 10)], t.sort((n,
|
|
709
|
-
if (e(this,
|
|
710
|
-
const
|
|
711
|
-
e(this,
|
|
712
|
-
|
|
713
|
-
r.__ng.rowid === l && (r.__ng.deleted = !0, r.__ng.rowState = ((c = ninegrid.ROW_STATE) == null ? void 0 : c.DELETE) || "DELETE");
|
|
703
|
+
Array.isArray(s) ? t = s : typeof s > "u" ? t = [e(this, w).owner.row.at] : t = [parseInt(s, 10)], t.sort((n, o) => o - n).forEach((n) => {
|
|
704
|
+
if (e(this, k)[n]) {
|
|
705
|
+
const o = e(this, k)[n].__ng.rowid;
|
|
706
|
+
e(this, k)[n].__ng.rowState === T.ROW_STATE.INSERT ? e(this, w).rawRecords = e(this, w).rawRecords.filter((r) => r.__ng.rowid !== o) : e(this, w).rawRecords.forEach((r) => {
|
|
707
|
+
r.__ng.rowid === o && (r.__ng.deleted = !0, r.__ng.rowState = T.ROW_STATE.DELETE);
|
|
714
708
|
});
|
|
715
709
|
}
|
|
716
710
|
}), this.resetRecords(), (i = e(this, w).viewRecords) != null && i.reset && e(this, w).viewRecords.reset();
|
|
717
711
|
}, "delete"));
|
|
718
|
-
|
|
719
|
-
var u
|
|
712
|
+
v(this, "setValue", /* @__PURE__ */ a((s, t, i) => {
|
|
713
|
+
var u;
|
|
720
714
|
s = parseInt(s, 10);
|
|
721
|
-
const
|
|
722
|
-
if (
|
|
715
|
+
const o = (typeof ((u = e(this, S).fields) == null ? void 0 : u.get) == "function" ? e(this, S).fields.get() : []).indexOf(t);
|
|
716
|
+
if (o < 0) return;
|
|
723
717
|
const r = this.getValidData()[s];
|
|
724
718
|
if (!r) return;
|
|
725
|
-
const c = r.v[
|
|
726
|
-
c !== i && r.__ng.rowState !==
|
|
719
|
+
const c = r.v[o];
|
|
720
|
+
c !== i && r.__ng.rowState !== T.ROW_STATE.INSERT && (r.__ng.o.hasOwnProperty(t) || (r.__ng.o[t] = c), r.__ng.rowState = T.ROW_STATE.UPDATE), r.v[o] = i, e(this, w).owner.refreshData && e(this, w).owner.refreshData(s);
|
|
727
721
|
}, "setValue"));
|
|
728
|
-
|
|
729
|
-
m(this,
|
|
722
|
+
v(this, "resetRecords", /* @__PURE__ */ a(() => {
|
|
723
|
+
m(this, D, e(this, w).rawRecords.filter((s) => !s.__ng.deleted)), m(this, k, e(this, w).rawRecords.filter((s) => !s.__ng.deleted && !s.__ng.filtered)), e(this, w).rawRecords.forEach((s, t) => {
|
|
730
724
|
s.__ng.rowidx = t;
|
|
731
|
-
}), e(this,
|
|
725
|
+
}), e(this, k).forEach((s, t) => {
|
|
732
726
|
s.__ng.i = t;
|
|
733
727
|
});
|
|
734
728
|
}, "resetRecords"));
|
|
735
|
-
|
|
736
|
-
g(this,
|
|
729
|
+
v(this, "getValidData", /* @__PURE__ */ a(() => (e(this, k).length === 0 && e(this, w).rawRecords.length > 0 && this.resetRecords(), e(this, k)), "getValidData"));
|
|
730
|
+
g(this, N, /* @__PURE__ */ a((s) => {
|
|
737
731
|
var i;
|
|
738
732
|
if (!s) return s;
|
|
739
|
-
const t = typeof ((i = e(this,
|
|
733
|
+
const t = typeof ((i = e(this, S).fields) == null ? void 0 : i.get) == "function" ? e(this, S).fields.get() : [];
|
|
740
734
|
return Array.isArray(s) ? s.filter((n) => !n.__ng.deleted).map((n) => {
|
|
741
|
-
const
|
|
735
|
+
const o = {};
|
|
742
736
|
return t.forEach((r, c) => {
|
|
743
|
-
|
|
744
|
-
}),
|
|
737
|
+
o[r] = n.v ? n.v[c] : n[r];
|
|
738
|
+
}), o.__ng = n.__ng, o;
|
|
745
739
|
}) : s;
|
|
746
740
|
}, "#conv2"));
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
var
|
|
741
|
+
v(this, "count", /* @__PURE__ */ a(() => this.getValidData().length, "count"));
|
|
742
|
+
v(this, "get", /* @__PURE__ */ a((s, t) => {
|
|
743
|
+
var o;
|
|
750
744
|
const i = this.getValidData();
|
|
751
745
|
if (!i || i.length <= 0) return;
|
|
752
|
-
if (s == null) return e(this,
|
|
746
|
+
if (s == null) return e(this, N).call(this, i);
|
|
753
747
|
if (s < 0 || s >= i.length) return null;
|
|
754
|
-
const n = typeof ((
|
|
748
|
+
const n = typeof ((o = e(this, S).fields) == null ? void 0 : o.get) == "function" ? e(this, S).fields.get() : [];
|
|
755
749
|
if (t != null) {
|
|
756
750
|
const r = n.indexOf(t);
|
|
757
751
|
return r >= 0 ? i[s].v[r] : null;
|
|
758
752
|
}
|
|
759
|
-
return e(this,
|
|
753
|
+
return e(this, N).call(this, i[s]);
|
|
760
754
|
}, "get"));
|
|
761
|
-
m(this,
|
|
755
|
+
m(this, S, s), m(this, w, t), e(this, ee).call(this);
|
|
762
756
|
}
|
|
763
757
|
get source() {
|
|
764
|
-
return e(this,
|
|
758
|
+
return e(this, N).call(this, e(this, w).rawRecords);
|
|
765
759
|
}
|
|
766
760
|
set source(s) {
|
|
767
761
|
this.clear(), this.add(s, !1);
|
|
768
762
|
}
|
|
769
763
|
get nextId() {
|
|
770
|
-
return ++Re(this,
|
|
764
|
+
return ++Re(this, Q)._;
|
|
771
765
|
}
|
|
772
766
|
};
|
|
773
|
-
|
|
774
|
-
|
|
767
|
+
S = new WeakMap(), w = new WeakMap(), k = new WeakMap(), D = new WeakMap(), Q = new WeakMap(), I = new WeakMap(), ee = new WeakMap(), Y = new WeakMap(), te = new WeakMap(), se = new WeakMap(), N = new WeakMap(), a(T, "ngData"), // π― ν μν μ μ μμλ₯Ό ν΄λμ€ λ΄λΆλ‘ λ΄μ¬ν
|
|
768
|
+
v(T, "ROW_STATE", {
|
|
769
|
+
EMPTY: "EMPTY",
|
|
770
|
+
NORMAL: "NORMAL",
|
|
771
|
+
INSERT: "INSERT",
|
|
772
|
+
UPDATE: "UPDATE",
|
|
773
|
+
DELETE: "DELETE"
|
|
774
|
+
});
|
|
775
|
+
let de = T;
|
|
775
776
|
const me = class me {
|
|
776
777
|
constructor(s) {
|
|
777
|
-
this.owner = s, this.row = new
|
|
778
|
+
this.owner = s, this.row = new he(this), this.data = new de(s, this), this.rawRecords = [], this.viewRecords = [], this.delRecords = [], this.pageCnt = 25, this.viewRecords.reset = () => {
|
|
778
779
|
var t;
|
|
779
780
|
(t = this.owner.view) != null && t.redraw && this.owner.view.redraw();
|
|
780
781
|
}, this.setDataSource = (t) => {
|
|
781
782
|
this.data && this.data.reset(), this.rawRecords = [], this.viewRecords = [], this.delRecords = [], this.data.set(t || []);
|
|
782
783
|
}, this.getRowState = (t) => {
|
|
783
|
-
var n,
|
|
784
|
+
var n, o;
|
|
784
785
|
const i = parseInt(t, 10);
|
|
785
786
|
if (!(i >= this.data.count()))
|
|
786
|
-
return (
|
|
787
|
+
return (o = (n = this.data.getValidData()[i]) == null ? void 0 : n.__ng) == null ? void 0 : o.rowState;
|
|
787
788
|
}, this.getRowPosition = () => this.row.at, this.setRowPosition = (t) => {
|
|
788
789
|
this.row.at = t;
|
|
789
790
|
}, this.scrollTo_V1 = (t) => (t < 0 && (t = 0), t >= this.rawRecords.length && (t = this.rawRecords.length - 1), this.viewRecords.rawIndex = t, this.viewRecords.reset && this.viewRecords.reset(), !(t <= 0 || t >= this.rawRecords.length - 1)), this.getColumn = (t, i) => this.data.get(t, i), this.setColumn = (t, i, n) => {
|
|
@@ -792,36 +793,36 @@ const me = class me {
|
|
|
792
793
|
}
|
|
793
794
|
};
|
|
794
795
|
a(me, "ngDataManager");
|
|
795
|
-
let
|
|
796
|
-
var
|
|
796
|
+
let fe = me;
|
|
797
|
+
var B, ie;
|
|
797
798
|
const ve = class ve extends HTMLElement {
|
|
798
799
|
constructor() {
|
|
799
800
|
super();
|
|
800
801
|
//#created = false;
|
|
801
|
-
g(this,
|
|
802
|
-
g(this,
|
|
803
|
-
this.attachShadow({ mode: "open" }), m(this,
|
|
802
|
+
g(this, B);
|
|
803
|
+
g(this, ie);
|
|
804
|
+
this.attachShadow({ mode: "open" }), m(this, B, new fe(this));
|
|
804
805
|
}
|
|
805
806
|
connectedCallback() {
|
|
806
|
-
m(this,
|
|
807
|
+
m(this, ie, new ce(this.shadowRoot)), F.log("NineTable connected."), this.dispatchEvent(new CustomEvent("load", { bubbles: !0, detail: { target: this } }));
|
|
807
808
|
}
|
|
808
809
|
disconnectedCallback() {
|
|
809
|
-
|
|
810
|
+
F.log("NineTable disconnected.");
|
|
810
811
|
}
|
|
811
812
|
// π― μΈλΆμμ grid.data.set(...) ννλ‘ μ κ·Όν μ μλλ‘ λ°μ΄ν° λ§€λμ μ€ν
|
|
812
813
|
get data() {
|
|
813
|
-
return e(this,
|
|
814
|
+
return e(this, B).data;
|
|
814
815
|
}
|
|
815
816
|
// π― ν(row) κ΄λ ¨ μ μ΄ μ κ·Όμ μ€ν
|
|
816
817
|
get row() {
|
|
817
|
-
return e(this,
|
|
818
|
+
return e(this, B).row;
|
|
818
819
|
}
|
|
819
820
|
// π― μ 체 λ°μ΄ν° λ§€λμ μ κ·Ό νμν κ²½μ°
|
|
820
821
|
get dataManager() {
|
|
821
|
-
return e(this,
|
|
822
|
+
return e(this, B);
|
|
822
823
|
}
|
|
823
824
|
};
|
|
824
|
-
|
|
825
|
-
let
|
|
826
|
-
customElements.get("nine-table") || customElements.define("nine-table",
|
|
825
|
+
B = new WeakMap(), ie = new WeakMap(), a(ve, "NineTable");
|
|
826
|
+
let ue = ve;
|
|
827
|
+
customElements.get("nine-table") || customElements.define("nine-table", ue);
|
|
827
828
|
//# sourceMappingURL=nine-table.js.map
|