@ninebone/table 0.0.418 β†’ 0.0.420

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.
@@ -22,23 +22,23 @@ const re = class re extends Se.constructor {
22
22
  };
23
23
  a(re, "Trace");
24
24
  let jt = re;
25
- const T = new jt();
26
- var _, O, p, V, Y, X, Et, U, Rt;
25
+ const k = new jt();
26
+ var _, O, p, P, V, Y, St, X, Et;
27
27
  const le = class le extends HTMLElement {
28
28
  constructor() {
29
29
  super();
30
30
  c(this, _);
31
31
  c(this, O, !1);
32
32
  c(this, p);
33
+ c(this, P);
33
34
  c(this, V);
34
35
  c(this, Y);
35
- c(this, X);
36
- c(this, Et, /* @__PURE__ */ a(() => {
36
+ c(this, St, /* @__PURE__ */ a(() => {
37
37
  if (!t(this, _)) return;
38
38
  const e = t(this, _).querySelector(".ng-container-body");
39
- e && (g(this, X, new ResizeObserver(() => {
39
+ e && (g(this, Y, new ResizeObserver(() => {
40
40
  this.refresh();
41
- })), t(this, X).observe(e));
41
+ })), t(this, Y).observe(e));
42
42
  }, "#observeResize"));
43
43
  v(this, "refresh", /* @__PURE__ */ a(() => {
44
44
  if (!t(this, _) || !t(this, p) || t(this, O)) return;
@@ -59,9 +59,9 @@ const le = class le extends HTMLElement {
59
59
  let y = 0;
60
60
  b > 0 && (y = parseInt(u / b * (h - f), 10)), y < 0 && (y = 0);
61
61
  const m = h - f;
62
- y > m && (y = m), r.style.left = `${y}px`, T.log(y), t(this, p).left.disabled = y === 0, t(this, p).right.disabled = y >= m - 1;
62
+ y > m && (y = m), r.style.left = `${y}px`, k.log(y), t(this, p).left.disabled = y === 0, t(this, p).right.disabled = y >= m - 1;
63
63
  }, "refresh"));
64
- c(this, U, /* @__PURE__ */ a((e) => {
64
+ c(this, X, /* @__PURE__ */ a((e) => {
65
65
  if (!t(this, p)) return !1;
66
66
  const s = t(this, p).container, n = s.querySelector("table");
67
67
  if (!n) return !1;
@@ -73,18 +73,18 @@ const le = class le extends HTMLElement {
73
73
  const h = s.clientWidth, u = n.scrollWidth - h;
74
74
  return d > 0 && u > 0 && (s.scrollLeft = l / d * u), l > 0 && l < d - 1;
75
75
  }, "#thumbMoveTo"));
76
- c(this, Rt, /* @__PURE__ */ a(() => {
76
+ c(this, Et, /* @__PURE__ */ a(() => {
77
77
  const e = /* @__PURE__ */ a((n) => {
78
- clearInterval(t(this, V)), clearInterval(t(this, Y));
78
+ clearInterval(t(this, P)), clearInterval(t(this, V));
79
79
  const r = parseInt(t(this, p).thumb.style.left || 0, 10);
80
- t(this, U).call(this, r + n), g(this, V, setInterval(() => {
81
- clearInterval(t(this, V)), g(this, Y, setInterval(() => {
80
+ t(this, X).call(this, r + n), g(this, P, setInterval(() => {
81
+ clearInterval(t(this, P)), g(this, V, setInterval(() => {
82
82
  const o = parseInt(t(this, p).thumb.style.left || 0, 10);
83
- t(this, U).call(this, o + n) || clearInterval(t(this, Y));
83
+ t(this, X).call(this, o + n) || clearInterval(t(this, V));
84
84
  }, 50));
85
85
  }, 500));
86
86
  }, "delayScroll"), s = /* @__PURE__ */ a(() => {
87
- clearInterval(t(this, V)), clearInterval(t(this, Y));
87
+ clearInterval(t(this, P)), clearInterval(t(this, V));
88
88
  }, "clearTimer");
89
89
  ["mouseup", "mouseleave", "touchend"].forEach((n) => {
90
90
  t(this, p).left.addEventListener(n, s), t(this, p).right.addEventListener(n, s), t(this, p).track.addEventListener(n, s);
@@ -96,14 +96,14 @@ const le = class le extends HTMLElement {
96
96
  if (n.button !== 0) return;
97
97
  n.preventDefault();
98
98
  const r = t(this, p).track.getBoundingClientRect(), o = t(this, p).thumb.clientWidth;
99
- t(this, U).call(this, n.clientX - r.left - o / 2);
99
+ t(this, X).call(this, n.clientX - r.left - o / 2);
100
100
  }), t(this, p).thumb.addEventListener("mousedown", (n) => {
101
101
  if (n.button !== 0) return;
102
102
  n.stopPropagation(), n.preventDefault(), g(this, O, !0), this.shiftX = n.clientX - t(this, p).thumb.getBoundingClientRect().left;
103
103
  const r = /* @__PURE__ */ a((l) => {
104
104
  if (!t(this, O)) return;
105
105
  const d = t(this, p).track.getBoundingClientRect();
106
- t(this, U).call(this, l.clientX - d.left - this.shiftX);
106
+ t(this, X).call(this, l.clientX - d.left - this.shiftX);
107
107
  }, "onMouseMove"), o = /* @__PURE__ */ a(() => {
108
108
  g(this, O, !1), s(), document.removeEventListener("mousemove", r), document.removeEventListener("mouseup", o), this.refresh();
109
109
  }, "onMouseUp");
@@ -190,22 +190,22 @@ const le = class le extends HTMLElement {
190
190
  right: this.querySelector(".ng-scroll-right")
191
191
  }), s.addEventListener("scroll", () => {
192
192
  t(this, O) || this.refresh();
193
- }), t(this, Rt).call(this), t(this, Et).call(this), this.refresh();
193
+ }), t(this, Et).call(this), t(this, St).call(this), this.refresh();
194
194
  }, "initWhenReady");
195
195
  e();
196
196
  }
197
197
  disconnectedCallback() {
198
- t(this, X) && t(this, X).disconnect();
198
+ t(this, Y) && t(this, Y).disconnect();
199
199
  }
200
200
  };
201
- _ = new WeakMap(), O = new WeakMap(), p = new WeakMap(), V = new WeakMap(), Y = new WeakMap(), X = new WeakMap(), Et = new WeakMap(), U = new WeakMap(), Rt = new WeakMap(), a(le, "NineTableHScrollBar");
201
+ _ = new WeakMap(), O = new WeakMap(), p = new WeakMap(), P = new WeakMap(), V = new WeakMap(), Y = new WeakMap(), St = new WeakMap(), X = new WeakMap(), Et = new WeakMap(), a(le, "NineTableHScrollBar");
202
202
  let Kt = le;
203
203
  customElements.get("nine-table-hscrollbar") || customElements.define("nine-table-hscrollbar", Kt);
204
- var F, Q, z, S, ht, dt, At;
204
+ var U, Q, z, S, ht, dt, Rt;
205
205
  const ae = class ae extends HTMLElement {
206
206
  constructor() {
207
207
  super();
208
- c(this, F);
208
+ c(this, U);
209
209
  c(this, Q);
210
210
  c(this, z, !1);
211
211
  c(this, S);
@@ -215,8 +215,8 @@ const ae = class ae extends HTMLElement {
215
215
  * 🎯 μŠ€ν¬λ‘€λ°” μœ„μΉ˜ 및 썸브 크기 κ°±μ‹ 
216
216
  */
217
217
  v(this, "refresh", /* @__PURE__ */ a(() => {
218
- T.log("refresh", t(this, z)), T.log("refresh2");
219
- const e = t(this, S).container, s = t(this, S).track, n = t(this, S).thumb, r = e.clientHeight, l = (t(this, F).data.get() || []).length, d = t(this, Q).getRowHeight(), h = l * d;
218
+ k.log("refresh", t(this, z)), k.log("refresh2");
219
+ const e = t(this, S).container, s = t(this, S).track, n = t(this, S).thumb, r = e.clientHeight, l = (t(this, U).data.get() || []).length, d = t(this, Q).getRowHeight(), h = l * d;
220
220
  if (h <= r) {
221
221
  n.style.display = "none", t(this, S).top.disabled = !0, t(this, S).bottom.disabled = !0;
222
222
  return;
@@ -230,11 +230,11 @@ const ae = class ae extends HTMLElement {
230
230
  let m = 0;
231
231
  y > 0 && (m = b / y * (f - u));
232
232
  const R = f - u;
233
- m < 0 && (m = 0), m > R && (m = R), n.style.top = `${m}px`, T.log("currentScrollTop", b), T.log("maxScrollTop", y), T.log("trackHeight", f), T.log("thumbHeight", u), t(this, S).top.disabled = b <= 0, t(this, S).bottom.disabled = b >= y - 1;
233
+ m < 0 && (m = 0), m > R && (m = R), n.style.top = `${m}px`, k.log("currentScrollTop", b), k.log("maxScrollTop", y), k.log("trackHeight", f), k.log("thumbHeight", u), t(this, S).top.disabled = b <= 0, t(this, S).bottom.disabled = b >= y - 1;
234
234
  }, "refresh"));
235
- c(this, At, /* @__PURE__ */ a(() => {
235
+ c(this, Rt, /* @__PURE__ */ a(() => {
236
236
  const e = t(this, S).container, s = /* @__PURE__ */ a(() => {
237
- const r = (t(this, F).data.get() || []).length, o = t(this, Q).getRowHeight();
237
+ const r = (t(this, U).data.get() || []).length, o = t(this, Q).getRowHeight();
238
238
  return r * o;
239
239
  }, "getContentHeight");
240
240
  e.addEventListener("scroll", () => {
@@ -272,7 +272,7 @@ const ae = class ae extends HTMLElement {
272
272
  }, "#init"));
273
273
  }
274
274
  connectedCallback() {
275
- g(this, F, this.getRootNode().host), g(this, Q, this.closest("nine-table-sheet")), this.innerHTML = `
275
+ g(this, U, this.getRootNode().host), g(this, Q, this.closest("nine-table-sheet")), this.innerHTML = `
276
276
  <style>
277
277
  nine-table-vscrollbar {
278
278
  display: flex;
@@ -338,7 +338,7 @@ const ae = class ae extends HTMLElement {
338
338
  <button class='ng-scroll-bottom' disabled><div class='ng-scroll-icon'></div></button>
339
339
  `;
340
340
  const e = /* @__PURE__ */ a(() => {
341
- const s = t(this, F).shadowRoot.querySelector(".ng-container-body");
341
+ const s = t(this, U).shadowRoot.querySelector(".ng-container-body");
342
342
  if (!s) {
343
343
  setTimeout(e, 10);
344
344
  return;
@@ -349,15 +349,15 @@ const ae = class ae extends HTMLElement {
349
349
  thumb: this.querySelector(".ng-scroll-thumb"),
350
350
  top: this.querySelector(".ng-scroll-top"),
351
351
  bottom: this.querySelector(".ng-scroll-bottom")
352
- }), t(this, At).call(this), this.refresh();
352
+ }), t(this, Rt).call(this), this.refresh();
353
353
  }, "initWhenReady");
354
354
  e();
355
355
  }
356
356
  };
357
- F = new WeakMap(), Q = new WeakMap(), z = new WeakMap(), S = new WeakMap(), ht = new WeakMap(), dt = new WeakMap(), At = new WeakMap(), a(ae, "NineTableVScrollBar");
357
+ U = new WeakMap(), Q = new WeakMap(), z = new WeakMap(), S = new WeakMap(), ht = new WeakMap(), dt = new WeakMap(), Rt = new WeakMap(), a(ae, "NineTableVScrollBar");
358
358
  let Zt = ae;
359
359
  customElements.get("nine-table-vscrollbar") || customElements.define("nine-table-vscrollbar", Zt);
360
- var Tt, tt;
360
+ var At, tt;
361
361
  const M = class M {
362
362
  /**
363
363
  * 🎯 λ ˆμ΄μ•„μ›ƒ λ‚΄μ˜ μ—¬λŸ¬ rawTables 배열을 μΌκ΄„λ‘œ λ°›μ•„ 단일 λ§ˆμŠ€ν„° ν…œν”Œλ¦ΏμœΌλ‘œ 사전 μ»΄νŒŒμΌν•©λ‹ˆλ‹€.
@@ -372,7 +372,7 @@ const M = class M {
372
372
  var n, r, o, l;
373
373
  if (!i) return null;
374
374
  const e = i.cloneNode(!0);
375
- return t(n = M, Tt).call(n, e), t(r = M, tt).call(r, e, "thead"), t(o = M, tt).call(o, e, "tbody"), t(l = M, tt).call(l, e, "tfoot"), Array.from(e.querySelectorAll("colgroup col")).forEach((d, h) => {
375
+ return t(n = M, At).call(n, e), t(r = M, tt).call(r, e, "thead"), t(o = M, tt).call(o, e, "tbody"), t(l = M, tt).call(l, e, "tfoot"), Array.from(e.querySelectorAll("colgroup col")).forEach((d, h) => {
376
376
  const f = d.getAttribute("fixed");
377
377
  f && e.querySelectorAll(`thead [data-col="${h}"], tbody [data-col="${h}"], tfoot [data-col="${h}"]`).forEach((u) => {
378
378
  u.setAttribute("fixed", f);
@@ -380,7 +380,7 @@ const M = class M {
380
380
  }), e;
381
381
  }
382
382
  };
383
- Tt = new WeakMap(), tt = new WeakMap(), a(M, "TableCompiler"), c(M, Tt, /* @__PURE__ */ a((i) => {
383
+ At = new WeakMap(), tt = new WeakMap(), a(M, "TableCompiler"), c(M, At, /* @__PURE__ */ a((i) => {
384
384
  if (!i.querySelector("colgroup")) {
385
385
  const e = i.querySelector("tbody tr") || i.querySelector("tr"), s = e ? e.querySelectorAll("th, td").length : 1, n = document.createElement("colgroup"), r = Math.max(Math.floor(i.clientWidth / s), 100);
386
386
  for (let o = 0; o < s; o++) {
@@ -428,25 +428,25 @@ Tt = new WeakMap(), tt = new WeakMap(), a(M, "TableCompiler"), c(M, Tt, /* @__PU
428
428
  });
429
429
  }, "#resetColIndex"));
430
430
  let Gt = M;
431
- var I, w, W, q, D, j, B, et, qt, kt, Lt, ft, ut, Ht, Ct, gt, $t, it, bt;
431
+ var I, w, W, T, D, F, B, et, Tt, qt, kt, ft, ut, Lt, Ht, gt, Ct, it, bt;
432
432
  const ce = class ce {
433
433
  constructor(i) {
434
434
  c(this, I);
435
435
  c(this, w);
436
436
  c(this, W, /* @__PURE__ */ new Map());
437
- c(this, q, null);
437
+ c(this, T, null);
438
438
  c(this, D, null);
439
- c(this, j, 0);
439
+ c(this, F, 0);
440
440
  c(this, B, 40);
441
441
  c(this, et, !1);
442
- c(this, qt, 3);
442
+ c(this, Tt, 3);
443
443
  v(this, "refresh", /* @__PURE__ */ a(() => {
444
444
  var e;
445
445
  const i = t(this, w).querySelector(".ng-container-body");
446
446
  i && (t(this, ft).call(this), t(this, it).call(this, i.scrollTop), (e = t(this, w).querySelector("nine-table-vscrollbar")) == null || e.refresh());
447
447
  }, "refresh"));
448
448
  v(this, "initialize", /* @__PURE__ */ a(() => {
449
- g(this, q, null), t(this, W).clear(), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((n) => {
449
+ g(this, T, null), t(this, W).clear(), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((n) => {
450
450
  const r = t(this, w).querySelector(n);
451
451
  if (!r) return;
452
452
  const o = r.querySelector("table");
@@ -458,7 +458,7 @@ const ce = class ce {
458
458
  });
459
459
  const i = t(this, w).querySelector(".ng-container-body"), e = t(this, w).querySelector(".ng-container-left"), s = t(this, w).querySelector(".ng-container-right");
460
460
  if (i) {
461
- t(this, Lt).call(this, i), t(this, gt).call(this), t(this, ft).call(this), t(this, it).call(this, i.scrollTop);
461
+ t(this, kt).call(this, i), t(this, gt).call(this), t(this, ft).call(this), t(this, it).call(this, i.scrollTop);
462
462
  let n = i.scrollTop;
463
463
  const r = /* @__PURE__ */ a((o) => {
464
464
  var l;
@@ -470,7 +470,7 @@ const ce = class ce {
470
470
  });
471
471
  }
472
472
  }, "initialize"));
473
- c(this, kt, /* @__PURE__ */ a((i, e) => {
473
+ c(this, qt, /* @__PURE__ */ a((i, e) => {
474
474
  const s = t(this, W).get(e);
475
475
  if (!s || s.length === 0) return;
476
476
  const n = i.querySelector("tbody.bindable-tbody");
@@ -483,9 +483,9 @@ const ce = class ce {
483
483
  });
484
484
  r ? r.before(o) : n.appendChild(o);
485
485
  }, "#renderRows"));
486
- c(this, Lt, /* @__PURE__ */ a((i) => {
487
- if (t(this, q) !== null && t(this, q) > 0)
488
- return t(this, q);
486
+ c(this, kt, /* @__PURE__ */ a((i) => {
487
+ if (t(this, T) !== null && t(this, T) > 0)
488
+ return t(this, T);
489
489
  const e = t(this, W).get(".ng-container-body");
490
490
  if (!e || e.length === 0) return 24;
491
491
  const s = i.querySelector("tbody.bindable-tbody") || i.querySelector("tbody.bindable-tbody:last-of-type");
@@ -501,23 +501,23 @@ const ce = class ce {
501
501
  const u = s.querySelectorAll("tr:not(.nodata)");
502
502
  return u.forEach((b) => {
503
503
  f += b.offsetHeight || b.getBoundingClientRect().height;
504
- }), u.forEach((b) => b.remove()), o.style.display = l, o.style.visibility = d, o.style.position = h, g(this, q, f > 0 ? f : 24), t(this, ut).call(this), t(this, q);
504
+ }), u.forEach((b) => b.remove()), o.style.display = l, o.style.visibility = d, o.style.position = h, g(this, T, f > 0 ? f : 24), t(this, ut).call(this), t(this, T);
505
505
  }, "#measureAndCacheHeight"));
506
506
  c(this, ft, /* @__PURE__ */ a(() => {
507
507
  if (!t(this, w).querySelector(".ng-container-body")) return;
508
- const s = (t(this, I).data.get() || []).length, n = t(this, q) || 24, r = s * n;
509
- T.log(`[VirtualHeight] totalCount: ${s}, rowHeight: ${n}, totalVirtualHeight: ${r}`), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((o) => {
508
+ const s = (t(this, I).data.get() || []).length, n = t(this, T) || 24, r = s * n;
509
+ k.log(`[VirtualHeight] totalCount: ${s}, rowHeight: ${n}, totalVirtualHeight: ${r}`), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((o) => {
510
510
  const l = t(this, w).querySelector(o), d = l == null ? void 0 : l.querySelector("table");
511
511
  d && (d.style.height = `${r}px`);
512
512
  });
513
513
  }, "#updateVirtualScrollHeight"));
514
514
  c(this, ut, /* @__PURE__ */ a(() => {
515
- if ((t(this, I).data.get() || []).length, t(this, j) > 0 && t(this, q) > 0) {
516
- const e = Math.ceil(t(this, j) / t(this, q));
517
- g(this, B, e + t(this, qt)), T.log("visibleRows:", e, "cachedRowCount:", t(this, B));
515
+ if ((t(this, I).data.get() || []).length, t(this, F) > 0 && t(this, T) > 0) {
516
+ const e = Math.ceil(t(this, F) / t(this, T));
517
+ g(this, B, e + t(this, Tt)), k.log("visibleRows:", e, "cachedRowCount:", t(this, B));
518
518
  }
519
519
  }, "#updateRowCount"));
520
- c(this, Ht, /* @__PURE__ */ a(() => {
520
+ c(this, Lt, /* @__PURE__ */ a(() => {
521
521
  var d, h, f;
522
522
  const i = t(this, w).querySelector(".ng-container-left table"), e = t(this, w).querySelector(".ng-container-body table"), s = t(this, w).querySelector(".ng-container-right table");
523
523
  if (!e) return;
@@ -531,7 +531,7 @@ const ce = class ce {
531
531
  y > 0 && (n[u] && (n[u].style.height = `${y}px`), r[u] && (r[u].style.height = `${y}px`), o[u] && (o[u].style.height = `${y}px`));
532
532
  }
533
533
  }, "#syncRowHeights"));
534
- c(this, Ct, /* @__PURE__ */ a(() => {
534
+ c(this, Ht, /* @__PURE__ */ a(() => {
535
535
  !t(this, w) || !(t(this, w) instanceof HTMLElement) || (g(this, D, new ResizeObserver((i) => {
536
536
  for (const e of i) {
537
537
  const s = e.target;
@@ -542,7 +542,7 @@ const ce = class ce {
542
542
  const o = s.querySelector("thead");
543
543
  o && (r += o.offsetHeight || o.getBoundingClientRect().height);
544
544
  const l = Math.max(n - r, 100);
545
- t(this, j) !== l && (g(this, j, l), t(this, ut).call(this), t(this, q) !== null && t(this, gt).call(this));
545
+ t(this, F) !== l && (g(this, F, l), t(this, ut).call(this), t(this, T) !== null && t(this, gt).call(this));
546
546
  }
547
547
  }
548
548
  })), t(this, D).observe(t(this, w)));
@@ -550,10 +550,10 @@ const ce = class ce {
550
550
  c(this, gt, /* @__PURE__ */ a(() => {
551
551
  [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((i) => {
552
552
  const e = t(this, w).querySelector(i);
553
- e && e.querySelector("tbody.bindable-tbody") && t(this, kt).call(this, e, i);
554
- }), t(this, Ht).call(this);
553
+ e && e.querySelector("tbody.bindable-tbody") && t(this, qt).call(this, e, i);
554
+ }), t(this, Lt).call(this);
555
555
  }, "#renderAllContainers"));
556
- c(this, $t, /* @__PURE__ */ a((i) => {
556
+ c(this, Ct, /* @__PURE__ */ a((i) => {
557
557
  [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((e) => {
558
558
  var h;
559
559
  const s = t(this, w).querySelector(e);
@@ -574,10 +574,10 @@ const ce = class ce {
574
574
  }, "#adjustBufferRows"));
575
575
  c(this, it, /* @__PURE__ */ a((i) => {
576
576
  var d;
577
- const e = t(this, q);
577
+ const e = t(this, T);
578
578
  if (!e || e <= 0) return;
579
579
  const n = (t(this, I).data.get() || []).length, r = Math.max(0, Math.floor(i / e)), o = ((d = t(this, W).get(".ng-container-body")) == null ? void 0 : d.length) || 1, l = r + t(this, B);
580
- T.log(`[Scroll] scrollTop: ${i}, startIndex: ${r}, cachedRowCount: ${t(this, B)}, targetDataIndex range: ${r} ~ ${l} (Total: ${n})`), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((h) => {
580
+ k.log(`[Scroll] scrollTop: ${i}, startIndex: ${r}, cachedRowCount: ${t(this, B)}, targetDataIndex range: ${r} ~ ${l} (Total: ${n})`), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((h) => {
581
581
  const f = t(this, w).querySelector(h);
582
582
  if (!f) return;
583
583
  const u = f.querySelector("tbody.bindable-tbody");
@@ -592,7 +592,7 @@ const ce = class ce {
592
592
  y.style.display = "", t(this, bt).call(this, y, J, R);
593
593
  });
594
594
  }), t(this, et) || (g(this, et, !0), setTimeout(() => {
595
- t(this, $t).call(this, r), g(this, et, !1);
595
+ t(this, Ct).call(this, r), g(this, et, !1);
596
596
  }, 0));
597
597
  }, "#handleScroll"));
598
598
  c(this, bt, /* @__PURE__ */ a((i, e, s) => {
@@ -604,38 +604,34 @@ const ce = class ce {
604
604
  v(this, "destroy", /* @__PURE__ */ a(() => {
605
605
  t(this, D) && (t(this, D).disconnect(), g(this, D, null));
606
606
  }, "destroy"));
607
- g(this, I, i.getRootNode().host), g(this, w, i), t(this, Ct).call(this);
607
+ g(this, I, i.getRootNode().host), g(this, w, i), t(this, Ht).call(this);
608
608
  }
609
609
  getRowHeight() {
610
- return t(this, q);
610
+ return t(this, T);
611
611
  }
612
612
  templateLength(i = ".ng-container-body") {
613
613
  var e;
614
614
  return ((e = t(this, W).get(i)) == null ? void 0 : e.length) || 1;
615
615
  }
616
616
  };
617
- I = new WeakMap(), w = new WeakMap(), W = new WeakMap(), q = new WeakMap(), D = new WeakMap(), j = new WeakMap(), B = new WeakMap(), et = new WeakMap(), qt = new WeakMap(), kt = new WeakMap(), Lt = new WeakMap(), ft = new WeakMap(), ut = new WeakMap(), Ht = new WeakMap(), Ct = new WeakMap(), gt = new WeakMap(), $t = new WeakMap(), it = new WeakMap(), bt = new WeakMap(), a(ce, "RowManager");
617
+ I = new WeakMap(), w = new WeakMap(), W = new WeakMap(), T = new WeakMap(), D = new WeakMap(), F = new WeakMap(), B = new WeakMap(), et = new WeakMap(), Tt = new WeakMap(), qt = new WeakMap(), kt = new WeakMap(), ft = new WeakMap(), ut = new WeakMap(), Lt = new WeakMap(), Ht = new WeakMap(), gt = new WeakMap(), Ct = new WeakMap(), it = new WeakMap(), bt = new WeakMap(), a(ce, "RowManager");
618
618
  let Jt = ce;
619
- var yt, st, N, Mt, _t, It, Wt, Ot;
619
+ var Mt, st, j, _t, $t, It, Wt, Ot;
620
620
  const ct = class ct extends HTMLElement {
621
621
  constructor() {
622
622
  super();
623
- c(this, yt);
623
+ c(this, Mt);
624
624
  c(this, st, null);
625
- c(this, N);
625
+ c(this, j);
626
626
  /**
627
627
  * data.set, add, delete
628
628
  * filter, sorting : κ³ λ €λŒ€μƒ
629
629
  */
630
630
  v(this, "invalidate", /* @__PURE__ */ a(() => {
631
- var o, l;
632
- const s = (((l = (o = t(this, yt)) == null ? void 0 : o.data) == null ? void 0 : l.get()) || []).length, n = t(this, N).getRowHeight() || 24, r = s * n;
633
- [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((d) => {
634
- const h = this.querySelector(d), f = h == null ? void 0 : h.querySelector("table");
635
- T.log("==============="), T.log(f, r), f && (f.style.height = `${r}px`, f.style.minHeight = `${r}px`);
636
- }), t(this, N).refresh();
631
+ var e, s;
632
+ t(this, j).refresh(), (e = this.querySelector("nine-table-hscrollbar")) == null || e.refresh(), (s = this.querySelector("nine-table-vscrollbar")) == null || s.refresh();
637
633
  }, "invalidate"));
638
- c(this, Mt, /* @__PURE__ */ a(() => {
634
+ c(this, _t, /* @__PURE__ */ a(() => {
639
635
  [
640
636
  { selector: ".ng-container-body", type: null },
641
637
  { selector: ".ng-container-left", type: "left" },
@@ -647,7 +643,7 @@ const ct = class ct extends HTMLElement {
647
643
  r.innerHTML = "", r.appendChild(o);
648
644
  });
649
645
  }, "#renderSplitContainers"));
650
- c(this, _t, /* @__PURE__ */ a(() => {
646
+ c(this, $t, /* @__PURE__ */ a(() => {
651
647
  ["left", "right"].forEach((e) => {
652
648
  const s = this.querySelector(`.ng-container-${e}`), n = s == null ? void 0 : s.querySelector("table");
653
649
  if (!s || !n) return;
@@ -659,13 +655,13 @@ const ct = class ct extends HTMLElement {
659
655
  });
660
656
  }, "#updateContainerWidths"));
661
657
  v(this, "generate", /* @__PURE__ */ a((e) => {
662
- e && (g(this, st, Gt.compile(e)), t(this, st).style.display = "table", t(this, Mt).call(this), t(this, _t).call(this), requestAnimationFrame(() => {
658
+ e && (g(this, st, Gt.compile(e)), t(this, st).style.display = "table", t(this, _t).call(this), t(this, $t).call(this), requestAnimationFrame(() => {
663
659
  var n;
664
660
  const s = (n = this.querySelector("thead")) == null ? void 0 : n.getBoundingClientRect().height;
665
661
  this.querySelectorAll("tbody.fixed-tbody").forEach((r) => {
666
662
  r.style.top = `${s}px`;
667
663
  });
668
- }), t(this, N).initialize(), setTimeout(() => {
664
+ }), t(this, j).initialize(), setTimeout(() => {
669
665
  var s;
670
666
  (s = this.querySelector("nine-table-hscrollbar")) == null || s.refresh();
671
667
  }, 0));
@@ -687,7 +683,7 @@ const ct = class ct extends HTMLElement {
687
683
  o.remove();
688
684
  }), n;
689
685
  }, "#createSplitTable"));
690
- v(this, "getRowHeight", /* @__PURE__ */ a(() => t(this, N).getRowHeight(), "getRowHeight"));
686
+ v(this, "getRowHeight", /* @__PURE__ */ a(() => t(this, j).getRowHeight(), "getRowHeight"));
691
687
  v(this, "scrollToX", /* @__PURE__ */ a((e) => {
692
688
  const s = this.querySelector(".ng-container-body");
693
689
  s && (s.scrollLeft = e);
@@ -846,19 +842,19 @@ const ct = class ct extends HTMLElement {
846
842
  </div>
847
843
  `;
848
844
  }, "#render"));
849
- g(this, N, new Jt(this)), g(this, yt, this.getRootNode().host);
845
+ g(this, j, new Jt(this)), g(this, Mt, this.getRootNode().host);
850
846
  }
851
847
  connectedCallback() {
852
848
  t(this, Wt).call(this);
853
849
  }
854
850
  disconnectedCallback() {
855
- this.innerHTML = "", T.log("NineTableSheet destroyed.");
851
+ this.innerHTML = "", k.log("NineTableSheet destroyed.");
856
852
  }
857
853
  };
858
- yt = new WeakMap(), st = new WeakMap(), N = new WeakMap(), Mt = new WeakMap(), _t = new WeakMap(), It = new WeakMap(), Wt = new WeakMap(), Ot = new WeakMap(), a(ct, "NineTableSheet"), v(ct, "SCROLLBAR_SIZE", 16);
859
- let St = ct;
860
- customElements.get("nine-table-sheet") || customElements.define("nine-table-sheet", St);
861
- var zt, pt;
854
+ Mt = new WeakMap(), st = new WeakMap(), j = new WeakMap(), _t = new WeakMap(), $t = new WeakMap(), It = new WeakMap(), Wt = new WeakMap(), Ot = new WeakMap(), a(ct, "NineTableSheet"), v(ct, "SCROLLBAR_SIZE", 16);
855
+ let wt = ct;
856
+ customElements.get("nine-table-sheet") || customElements.define("nine-table-sheet", wt);
857
+ var zt, yt;
862
858
  const he = class he extends HTMLElement {
863
859
  constructor() {
864
860
  super();
@@ -867,10 +863,10 @@ const he = class he extends HTMLElement {
867
863
  (e = this.querySelector(".nine-tab-bar")) == null || e.addEventListener("click", (s) => {
868
864
  var o;
869
865
  const n = s.ctrlKey || s.metaKey || s.shiftKey, r = parseInt((o = s.target.closest(".nine-tab-item")) == null ? void 0 : o.dataset.index, 10);
870
- t(this, pt).call(this, r, n);
871
- }), t(this, pt).call(this, 0, !1);
866
+ t(this, yt).call(this, r, n);
867
+ }), t(this, yt).call(this, 0, !1);
872
868
  }, "#init"));
873
- c(this, pt, /* @__PURE__ */ a((e, s = !1) => {
869
+ c(this, yt, /* @__PURE__ */ a((e, s = !1) => {
874
870
  const n = /* @__PURE__ */ a(() => {
875
871
  const f = Array.from(this.querySelectorAll("nine-table-sheet"));
876
872
  Array.from(this.querySelectorAll("nine-splitter")).forEach((y) => y.style.setProperty("display", "none"));
@@ -906,32 +902,32 @@ const he = class he extends HTMLElement {
906
902
  t(this, zt).call(this);
907
903
  }
908
904
  };
909
- zt = new WeakMap(), pt = new WeakMap(), a(he, "NineTableSheets");
905
+ zt = new WeakMap(), yt = new WeakMap(), a(he, "NineTableSheets");
910
906
  let Qt = he;
911
907
  customElements.get("nine-table-sheets") || customElements.define("nine-table-sheets", Qt);
912
- var k, Dt, mt, Bt;
908
+ var q, Dt, pt, Bt;
913
909
  const de = class de {
914
910
  constructor(i) {
915
- c(this, k);
911
+ c(this, q);
916
912
  c(this, Dt, /* @__PURE__ */ a(() => {
917
913
  t(this, Bt).call(this), new ResizeObserver((i) => {
918
914
  for (let e of i)
919
- t(this, k).getAttribute("auto-height") === "true" && t(this, mt).call(this);
920
- }).observe(t(this, k));
915
+ t(this, q).getAttribute("auto-height") === "true" && t(this, pt).call(this);
916
+ }).observe(t(this, q));
921
917
  }, "#init"));
922
- c(this, mt, /* @__PURE__ */ a(() => {
918
+ c(this, pt, /* @__PURE__ */ a(() => {
923
919
  var d, h;
924
- const i = Array.from(t(this, k).shadowRoot.querySelectorAll("nine-table-sheet.active"));
920
+ const i = Array.from(t(this, q).shadowRoot.querySelectorAll("nine-table-sheet.active"));
925
921
  if (i.length === 0) return;
926
- const e = parseInt(t(this, k).getAttribute("max-display-row"), 10) || 10, s = Math.max(...i.map((f) => f.getRowHeight())), n = (d = t(this, k).shadowRoot.querySelector("nine-table-header")) == null ? void 0 : d.getBoundingClientRect().height, r = (h = t(this, k).shadowRoot.querySelector("nine-table-sheets-footer")) == null ? void 0 : h.getBoundingClientRect().height, o = St.SCROLLBAR_SIZE, l = e * s + n + r + o;
927
- t(this, k).style.height = `${l}px`;
922
+ const e = parseInt(t(this, q).getAttribute("max-display-row"), 10) || 10, s = Math.max(...i.map((f) => f.getRowHeight())), n = (d = t(this, q).shadowRoot.querySelector("nine-table-header")) == null ? void 0 : d.getBoundingClientRect().height, r = (h = t(this, q).shadowRoot.querySelector("nine-table-sheets-footer")) == null ? void 0 : h.getBoundingClientRect().height, o = wt.SCROLLBAR_SIZE, l = e * s + n + r + o;
923
+ t(this, q).style.height = `${l}px`;
928
924
  }, "#applyAutoHeight"));
929
925
  c(this, Bt, /* @__PURE__ */ a(() => {
930
- const e = Array.from(t(this, k).children).filter((d) => d.tagName === "TABLE"), s = t(this, k).getAttribute("auto-height") === "true", n = e.length, r = e.map((d, h) => {
926
+ const e = Array.from(t(this, q).children).filter((d) => d.tagName === "TABLE"), s = t(this, q).getAttribute("auto-height") === "true", n = e.length, r = e.map((d, h) => {
931
927
  const u = `<nine-table-sheet class="${h === 0 ? "active" : ""}" data-index="${h}"></nine-table-sheet>`, b = h < n - 1 ? `<nine-splitter class="h" data-split-index="${h}"></nine-splitter>` : "";
932
928
  return u + b;
933
929
  }).join(""), o = e.map((d, h) => `<div class="nine-tab-item ${h === 0 ? "active" : ""}" data-index="${h}">Sheet ${h + 1}</div>`).join("");
934
- t(this, k).shadowRoot.innerHTML = `
930
+ t(this, q).shadowRoot.innerHTML = `
935
931
  <style>
936
932
  :host {
937
933
  display: flex;
@@ -1022,25 +1018,25 @@ const de = class de {
1022
1018
  </nine-table-body>
1023
1019
  <nine-table-footer></nine-table-footer>
1024
1020
  `;
1025
- const l = t(this, k).shadowRoot.querySelectorAll("nine-table-sheet");
1021
+ const l = t(this, q).shadowRoot.querySelectorAll("nine-table-sheet");
1026
1022
  l == null || l.forEach((d, h) => {
1027
1023
  e[h] && setTimeout(() => {
1028
- d.generate(e[h]), s && t(this, mt).call(this);
1024
+ d.generate(e[h]), s && t(this, pt).call(this);
1029
1025
  });
1030
1026
  });
1031
1027
  }, "#render"));
1032
- g(this, k, i), t(this, Dt).call(this);
1028
+ g(this, q, i), t(this, Dt).call(this);
1033
1029
  }
1034
1030
  };
1035
- k = new WeakMap(), Dt = new WeakMap(), mt = new WeakMap(), Bt = new WeakMap(), a(de, "LayoutManager");
1031
+ q = new WeakMap(), Dt = new WeakMap(), pt = new WeakMap(), Bt = new WeakMap(), a(de, "LayoutManager");
1036
1032
  let te = de;
1037
- var xt, nt;
1033
+ var mt, nt;
1038
1034
  const fe = class fe {
1039
1035
  constructor(i) {
1040
- c(this, xt);
1036
+ c(this, mt);
1041
1037
  c(this, nt, -1);
1042
- v(this, "count", /* @__PURE__ */ a(() => t(this, xt).rawRecords.length, "count"));
1043
- g(this, xt, i);
1038
+ v(this, "count", /* @__PURE__ */ a(() => t(this, mt).rawRecords.length, "count"));
1039
+ g(this, mt, i);
1044
1040
  }
1045
1041
  get at() {
1046
1042
  return t(this, nt);
@@ -1050,9 +1046,9 @@ const fe = class fe {
1050
1046
  });
1051
1047
  }
1052
1048
  };
1053
- xt = new WeakMap(), nt = new WeakMap(), a(fe, "ngRow");
1049
+ mt = new WeakMap(), nt = new WeakMap(), a(fe, "ngRow");
1054
1050
  let ee = fe;
1055
- var L, E, H, ot, Nt, P, Pt, K, vt, Vt, Yt, rt;
1051
+ var L, E, H, ot, Nt, N, Pt, K, xt, Vt, Yt, rt;
1056
1052
  const C = class C {
1057
1053
  constructor(i, e) {
1058
1054
  c(this, L);
@@ -1060,15 +1056,15 @@ const C = class C {
1060
1056
  c(this, H, []);
1061
1057
  c(this, ot, []);
1062
1058
  c(this, Nt, 0);
1063
- c(this, P, []);
1059
+ c(this, N, []);
1064
1060
  c(this, Pt, /* @__PURE__ */ a(() => {
1065
- g(this, P, []);
1061
+ g(this, N, []);
1066
1062
  const i = t(this, L).template || [];
1067
1063
  Array.from(i).forEach((e) => {
1068
1064
  var s;
1069
- t(this, P).push(((s = e.getBoundingClientRect) == null ? void 0 : s.call(e).height) || 24);
1065
+ t(this, N).push(((s = e.getBoundingClientRect) == null ? void 0 : s.call(e).height) || 24);
1070
1066
  }), (t(this, E).rawRecords || []).forEach((e) => {
1071
- e.__ng || (e.__ng = t(this, vt).call(this)), e.__ng.height = t(this, P).slice();
1067
+ e.__ng || (e.__ng = t(this, xt).call(this)), e.__ng.height = t(this, N).slice();
1072
1068
  });
1073
1069
  }, "#initialize"));
1074
1070
  c(this, K, /* @__PURE__ */ a(() => {
@@ -1092,14 +1088,14 @@ const C = class C {
1092
1088
  v(this, "set", /* @__PURE__ */ a((i) => {
1093
1089
  this.clear(), this.add(i, !1), t(this, K).call(this);
1094
1090
  }, "set"));
1095
- c(this, vt, /* @__PURE__ */ a(() => ({
1091
+ c(this, xt, /* @__PURE__ */ a(() => ({
1096
1092
  rowState: C.ROW_STATE.EMPTY,
1097
1093
  deleted: !1,
1098
1094
  filtered: !1,
1099
- height: t(this, P).slice(),
1095
+ height: t(this, N).slice(),
1100
1096
  o: {},
1101
1097
  c: {},
1102
- _: [0, 0, 0, 0, C.ROW_STATE.EMPTY, !1, !1, !0, !1, !0, !0, !1, t(this, P).slice(), -1, {}, {}]
1098
+ _: [0, 0, 0, 0, C.ROW_STATE.EMPTY, !1, !1, !0, !1, !0, !0, !1, t(this, N).slice(), -1, {}, {}]
1103
1099
  }), "#getDefaultMeta"));
1104
1100
  v(this, "reset", /* @__PURE__ */ a(() => {
1105
1101
  g(this, H, []), g(this, ot, []), t(this, K).call(this);
@@ -1120,7 +1116,7 @@ const C = class C {
1120
1116
  }), s;
1121
1117
  }, "#json2Array"));
1122
1118
  c(this, Yt, /* @__PURE__ */ a((i) => (Array.isArray(i) || (i = [i]), i.forEach((e) => {
1123
- e.__ng = t(this, vt).call(this), e.__ng.rowid = this.nextId, e.__ng.rowState = C.ROW_STATE.INSERT, e.__ng._[0] = e.__ng.rowid;
1119
+ e.__ng = t(this, xt).call(this), e.__ng.rowid = this.nextId, e.__ng.rowState = C.ROW_STATE.INSERT, e.__ng._[0] = e.__ng.rowid;
1124
1120
  }), i), "#defaultInsert"));
1125
1121
  v(this, "add", /* @__PURE__ */ a((i, e = !0) => {
1126
1122
  i === void 0 && (i = {});
@@ -1191,7 +1187,7 @@ const C = class C {
1191
1187
  return this.length;
1192
1188
  }
1193
1189
  };
1194
- L = new WeakMap(), E = new WeakMap(), H = new WeakMap(), ot = new WeakMap(), Nt = new WeakMap(), P = new WeakMap(), Pt = new WeakMap(), K = new WeakMap(), vt = new WeakMap(), Vt = new WeakMap(), Yt = new WeakMap(), rt = new WeakMap(), a(C, "ngData"), // 🎯 ν–‰ μƒνƒœ μ •μ˜ μƒμˆ˜λ₯Ό 클래슀 λ‚΄λΆ€λ‘œ λ‚΄μž¬ν™”
1190
+ L = new WeakMap(), E = new WeakMap(), H = new WeakMap(), ot = new WeakMap(), Nt = new WeakMap(), N = new WeakMap(), Pt = new WeakMap(), K = new WeakMap(), xt = new WeakMap(), Vt = new WeakMap(), Yt = new WeakMap(), rt = new WeakMap(), a(C, "ngData"), // 🎯 ν–‰ μƒνƒœ μ •μ˜ μƒμˆ˜λ₯Ό 클래슀 λ‚΄λΆ€λ‘œ λ‚΄μž¬ν™”
1195
1191
  v(C, "ROW_STATE", {
1196
1192
  EMPTY: "EMPTY",
1197
1193
  NORMAL: "NORMAL",
@@ -1223,7 +1219,7 @@ const ue = class ue {
1223
1219
  };
1224
1220
  Z = new WeakMap(), a(ue, "ngDataManager");
1225
1221
  let se = ue;
1226
- var lt, A, wt, Xt;
1222
+ var lt, A, vt, Xt;
1227
1223
  const ge = class ge {
1228
1224
  // 🎯 이제 { name: string, type: string } κ°μ²΄λ“€μ˜ λ°°μ—΄λ‘œ κ΄€λ¦¬ν•©λ‹ˆλ‹€.
1229
1225
  constructor(i) {
@@ -1232,20 +1228,20 @@ const ge = class ge {
1232
1228
  v(this, "add", /* @__PURE__ */ a((i, e = "string") => {
1233
1229
  i.forEach((s) => {
1234
1230
  t(this, A).some((n) => n.name === s) || t(this, A).push({ name: s, type: e });
1235
- }), t(this, wt).call(this);
1231
+ }), t(this, vt).call(this);
1236
1232
  }, "add"));
1237
- c(this, wt, /* @__PURE__ */ a(() => {
1233
+ c(this, vt, /* @__PURE__ */ a(() => {
1238
1234
  const i = /* @__PURE__ */ new Map();
1239
1235
  t(this, A).forEach((e) => {
1240
1236
  i.set(e.name, e.type);
1241
1237
  }), g(this, A, Array.from(i, ([e, s]) => ({ name: e, type: s }))), g(this, A, t(this, A).filter((e) => e.name !== "" && e.name !== "__ng")), t(this, A).sort((e, s) => e.name.length < s.name.length ? 1 : -1);
1242
1238
  }, "#adjust"));
1243
1239
  c(this, Xt, /* @__PURE__ */ a(() => {
1244
- g(this, A, []), T.log(t(this, lt).querySelectorAll("table"));
1240
+ g(this, A, []), k.log(t(this, lt).querySelectorAll("table"));
1245
1241
  const i = Array.from(t(this, lt).querySelectorAll("table"));
1246
1242
  if (!(!i || i.length === 0)) {
1247
1243
  for (const e of i)
1248
- T.log(e), $("[data-bind]", e).each((s, n) => {
1244
+ k.log(e), $("[data-bind]", e).each((s, n) => {
1249
1245
  const r = n.dataset.bind, o = n.getAttribute("data-type") || "string";
1250
1246
  r && t(this, A).push({ name: r, type: o });
1251
1247
  }), ["data-expr", "background-color", "color", "tooltip", "visible", "readonly", "enable-button", "enable-check", "class-expr", "icon-color", "icon-src"].forEach((s) => {
@@ -1269,7 +1265,7 @@ const ge = class ge {
1269
1265
  });
1270
1266
  });
1271
1267
  });
1272
- t(this, wt).call(this);
1268
+ t(this, vt).call(this);
1273
1269
  }
1274
1270
  }, "#init"));
1275
1271
  g(this, lt, i), t(this, Xt).call(this);
@@ -1294,7 +1290,7 @@ const ge = class ge {
1294
1290
  return t(this, A).some((e) => e.name === i);
1295
1291
  }
1296
1292
  };
1297
- lt = new WeakMap(), A = new WeakMap(), wt = new WeakMap(), Xt = new WeakMap(), a(ge, "ngFields");
1293
+ lt = new WeakMap(), A = new WeakMap(), vt = new WeakMap(), Xt = new WeakMap(), a(ge, "ngFields");
1298
1294
  let ne = ge;
1299
1295
  var G, Ut, Ft;
1300
1296
  const be = class be extends HTMLElement {
@@ -1304,7 +1300,7 @@ const be = class be extends HTMLElement {
1304
1300
  c(this, G);
1305
1301
  c(this, Ut);
1306
1302
  c(this, Ft, /* @__PURE__ */ a(() => {
1307
- this.fields = new ne(this), g(this, Ut, new te(this)), T.log("NineTable connected."), this.dispatchEvent(new CustomEvent("load", { bubbles: !0, detail: { target: this } }));
1303
+ this.fields = new ne(this), g(this, Ut, new te(this)), k.log("NineTable connected."), this.dispatchEvent(new CustomEvent("load", { bubbles: !0, detail: { target: this } }));
1308
1304
  }, "#init"));
1309
1305
  this.attachShadow({ mode: "open" }), g(this, G, new se(this));
1310
1306
  }
@@ -1312,7 +1308,7 @@ const be = class be extends HTMLElement {
1312
1308
  t(this, Ft).call(this);
1313
1309
  }
1314
1310
  disconnectedCallback() {
1315
- T.log("NineTable disconnected.");
1311
+ k.log("NineTable disconnected.");
1316
1312
  }
1317
1313
  // 🎯 μ™ΈλΆ€μ—μ„œ grid.data.set(...) ν˜•νƒœλ‘œ μ ‘κ·Όν•  수 μžˆλ„λ‘ 데이터 λ§€λ‹ˆμ € μ˜€ν”ˆ
1318
1314
  get data() {