@ninebone/table 0.0.542 β†’ 0.0.543

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.
@@ -2,16 +2,16 @@ var Fe = Object.defineProperty;
2
2
  var Ve = (R) => {
3
3
  throw TypeError(R);
4
4
  };
5
- var Xe = (R, r, e) => r in R ? Fe(R, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : R[r] = e;
6
- var h = (R, r) => Fe(R, "name", { value: r, configurable: !0 });
7
- var E = (R, r, e) => Xe(R, typeof r != "symbol" ? r + "" : r, e), Ye = (R, r, e) => r.has(R) || Ve("Cannot " + e);
8
- var t = (R, r, e) => (Ye(R, r, "read from private field"), e ? e.call(R) : r.get(R)), d = (R, r, e) => r.has(R) ? Ve("Cannot add the same private member more than once") : r instanceof WeakSet ? r.add(R) : r.set(R, e), y = (R, r, e, s) => (Ye(R, r, "write to private field"), s ? s.call(R, e) : r.set(R, e), e);
9
- var Ue = (R, r, e, s) => ({
10
- set _(i) {
11
- y(R, r, i, e);
5
+ var Xe = (R, i, e) => i in R ? Fe(R, i, { enumerable: !0, configurable: !0, writable: !0, value: e }) : R[i] = e;
6
+ var h = (R, i) => Fe(R, "name", { value: i, configurable: !0 });
7
+ var E = (R, i, e) => Xe(R, typeof i != "symbol" ? i + "" : i, e), Ye = (R, i, e) => i.has(R) || Ve("Cannot " + e);
8
+ var t = (R, i, e) => (Ye(R, i, "read from private field"), e ? e.call(R) : i.get(R)), d = (R, i, e) => i.has(R) ? Ve("Cannot add the same private member more than once") : i instanceof WeakSet ? i.add(R) : i.set(R, e), y = (R, i, e, s) => (Ye(R, i, "write to private field"), s ? s.call(R, e) : i.set(R, e), e);
9
+ var Ue = (R, i, e, s) => ({
10
+ set _(r) {
11
+ y(R, i, r, e);
12
12
  },
13
13
  get _() {
14
- return t(R, r, s);
14
+ return t(R, i, s);
15
15
  }
16
16
  });
17
17
  import { trace as Ke } from "@ninebone/util";
@@ -22,7 +22,7 @@ const He = class He extends Ke.constructor {
22
22
  };
23
23
  h(He, "Trace");
24
24
  let ae = He;
25
- const H = new ae();
25
+ const I = new ae();
26
26
  var z, j, w, X, K, Z, _t, G, Nt;
27
27
  const Me = class Me extends HTMLElement {
28
28
  constructor() {
@@ -44,14 +44,14 @@ const Me = class Me extends HTMLElement {
44
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 i = t(this, w).track, n = t(this, w).thumb, a = t(this, z).querySelector(".ng-container-bottom"), o = e.clientWidth, c = s.scrollWidth;
47
+ const r = t(this, w).track, n = t(this, w).thumb, a = t(this, z).querySelector(".ng-container-bottom"), o = e.clientWidth, c = s.scrollWidth;
48
48
  if (o !== 0 && c > o)
49
49
  a && (a.style.display = "flex");
50
50
  else {
51
51
  a && (a.style.display = "none");
52
52
  return;
53
53
  }
54
- const l = i.clientWidth;
54
+ const l = r.clientWidth;
55
55
  if (l <= 0) return;
56
56
  const f = Math.max(Math.min(l * (o / c), l), 20);
57
57
  n.style.width = `${f}px`;
@@ -63,43 +63,43 @@ const Me = class Me extends HTMLElement {
63
63
  }, "refresh"));
64
64
  d(this, G, /* @__PURE__ */ h((e) => {
65
65
  if (!t(this, w)) return !1;
66
- const s = t(this, w).container, i = s.querySelector("table");
67
- if (!i) return !1;
66
+ const s = t(this, w).container, r = s.querySelector("table");
67
+ if (!r) return !1;
68
68
  const n = t(this, w).track.getBoundingClientRect(), a = t(this, w).thumb.clientWidth;
69
69
  let o = e;
70
70
  o < 0 && (o = 0);
71
71
  const c = n.width - a;
72
72
  o > c && (o = c), o = parseInt(o, 10), t(this, w).thumb.style.left = `${o}px`, t(this, w).left.disabled = o === 0, t(this, w).right.disabled = o >= c - 1;
73
- const l = s.clientWidth, u = i.scrollWidth - l;
73
+ const l = s.clientWidth, u = r.scrollWidth - l;
74
74
  return c > 0 && u > 0 && (s.scrollLeft = o / c * u), o > 0 && o < c - 1;
75
75
  }, "#thumbMoveTo"));
76
76
  d(this, Nt, /* @__PURE__ */ h(() => {
77
- const e = /* @__PURE__ */ h((i) => {
77
+ const e = /* @__PURE__ */ h((r) => {
78
78
  clearInterval(t(this, X)), clearInterval(t(this, K));
79
79
  const n = parseInt(t(this, w).thumb.style.left || 0, 10);
80
- t(this, G).call(this, n + i), y(this, X, setInterval(() => {
80
+ t(this, G).call(this, n + r), y(this, X, setInterval(() => {
81
81
  clearInterval(t(this, X)), y(this, K, setInterval(() => {
82
82
  const a = parseInt(t(this, w).thumb.style.left || 0, 10);
83
- t(this, G).call(this, a + i) || clearInterval(t(this, K));
83
+ t(this, G).call(this, a + r) || clearInterval(t(this, K));
84
84
  }, 50));
85
85
  }, 500));
86
86
  }, "delayScroll"), s = /* @__PURE__ */ h(() => {
87
87
  clearInterval(t(this, X)), clearInterval(t(this, K));
88
88
  }, "clearTimer");
89
- ["mouseup", "mouseleave", "touchend"].forEach((i) => {
90
- t(this, w).left.addEventListener(i, s), t(this, w).right.addEventListener(i, s), t(this, w).track.addEventListener(i, s);
91
- }), t(this, w).left.addEventListener("mousedown", (i) => {
92
- i.button === 0 && e(-20);
93
- }), t(this, w).right.addEventListener("mousedown", (i) => {
94
- i.button === 0 && e(20);
95
- }), t(this, w).left.addEventListener("touchstart", () => e(-20)), t(this, w).right.addEventListener("touchstart", () => e(20)), t(this, w).track.addEventListener("mousedown", (i) => {
96
- if (i.button !== 0) return;
97
- i.preventDefault();
89
+ ["mouseup", "mouseleave", "touchend"].forEach((r) => {
90
+ t(this, w).left.addEventListener(r, s), t(this, w).right.addEventListener(r, s), t(this, w).track.addEventListener(r, s);
91
+ }), t(this, w).left.addEventListener("mousedown", (r) => {
92
+ r.button === 0 && e(-20);
93
+ }), t(this, w).right.addEventListener("mousedown", (r) => {
94
+ r.button === 0 && e(20);
95
+ }), t(this, w).left.addEventListener("touchstart", () => e(-20)), t(this, w).right.addEventListener("touchstart", () => e(20)), t(this, w).track.addEventListener("mousedown", (r) => {
96
+ if (r.button !== 0) return;
97
+ r.preventDefault();
98
98
  const n = t(this, w).track.getBoundingClientRect(), a = t(this, w).thumb.clientWidth;
99
- t(this, G).call(this, i.clientX - n.left - a / 2);
100
- }), t(this, w).thumb.addEventListener("mousedown", (i) => {
101
- if (i.button !== 0) return;
102
- i.stopPropagation(), i.preventDefault(), y(this, j, !0), this.shiftX = i.clientX - t(this, w).thumb.getBoundingClientRect().left;
99
+ t(this, G).call(this, r.clientX - n.left - a / 2);
100
+ }), t(this, w).thumb.addEventListener("mousedown", (r) => {
101
+ if (r.button !== 0) return;
102
+ r.stopPropagation(), r.preventDefault(), y(this, j, !0), this.shiftX = r.clientX - t(this, w).thumb.getBoundingClientRect().left;
103
103
  const n = /* @__PURE__ */ h((o) => {
104
104
  if (!t(this, j)) return;
105
105
  const c = t(this, w).track.getBoundingClientRect();
@@ -213,34 +213,33 @@ const $e = class $e extends HTMLElement {
213
213
  d(this, wt, 0);
214
214
  E(this, "refresh", /* @__PURE__ */ h(() => {
215
215
  if (!t(this, F) || !t(this, q)) return;
216
- H.log("nine-table-vscrollbar.refresh");
217
- const e = t(this, q).container, s = t(this, q).track, i = t(this, q).thumb, n = e.clientHeight, o = (t(this, F).data.get() || []).length, c = t(this, at).getRowHeight(), l = o * c;
216
+ const e = t(this, q).container, s = t(this, q).track, r = t(this, q).thumb, n = e.clientHeight, o = (t(this, F).data.get() || []).length, c = t(this, at).getRowHeight(), l = o * c;
218
217
  if (l <= n) {
219
- i.style.display = "none", t(this, q).top.disabled = !0, t(this, q).bottom.disabled = !0;
218
+ r.style.display = "none", t(this, q).top.disabled = !0, t(this, q).bottom.disabled = !0;
220
219
  return;
221
220
  } else
222
- i.style.display = "block";
221
+ r.style.display = "block";
223
222
  const f = s.clientHeight;
224
223
  if (f <= 0) return;
225
224
  const u = Math.max(Math.min(f * (n / l), f), 20);
226
- i.style.height = `${u}px`;
225
+ r.style.height = `${u}px`;
227
226
  const g = e.scrollTop, b = Math.max(l - n, 1);
228
227
  let x = 0;
229
228
  b > 0 && (x = g / b * (f - u));
230
229
  const v = f - u;
231
- x < 0 && (x = 0), x > v && (x = v), i.style.top = `${x}px`, t(this, q).top.disabled = g <= 0, t(this, q).bottom.disabled = g >= b - 1;
230
+ x < 0 && (x = 0), x > v && (x = v), r.style.top = `${x}px`, t(this, q).top.disabled = g <= 0, t(this, q).bottom.disabled = g >= b - 1;
232
231
  }, "refresh"));
233
232
  d(this, Wt, /* @__PURE__ */ h(() => {
234
- H.log("nine-table-vscrollbar.#init");
233
+ I.log("nine-table-vscrollbar.#init");
235
234
  const e = t(this, q).container, s = /* @__PURE__ */ h(() => {
236
235
  const n = (t(this, F).data.get() || []).length, a = t(this, at).getRowHeight();
237
236
  return n * a;
238
237
  }, "getContentHeight");
239
238
  e.addEventListener("scroll", () => {
240
239
  t(this, J) || this.refresh();
241
- }), t(this, q).thumb.addEventListener("mousedown", (i) => {
242
- if (i.button !== 0) return;
243
- i.stopPropagation(), i.preventDefault(), y(this, J, !0), y(this, vt, i.clientY), y(this, wt, e.scrollTop);
240
+ }), t(this, q).thumb.addEventListener("mousedown", (r) => {
241
+ if (r.button !== 0) return;
242
+ r.stopPropagation(), r.preventDefault(), y(this, J, !0), y(this, vt, r.clientY), y(this, wt, e.scrollTop);
244
243
  const n = /* @__PURE__ */ h((o) => {
245
244
  if (!t(this, J)) return;
246
245
  const c = t(this, q).track.getBoundingClientRect(), l = t(this, q).thumb.clientHeight, u = c.height - l, g = o.clientY - t(this, vt), b = e.clientHeight, x = s(), v = Math.max(x - b, 1);
@@ -255,9 +254,9 @@ const $e = class $e extends HTMLElement {
255
254
  y(this, J, !1), document.removeEventListener("mousemove", n), document.removeEventListener("mouseup", a), this.refresh();
256
255
  }, "onMouseUp");
257
256
  document.addEventListener("mousemove", n), document.addEventListener("mouseup", a);
258
- }), t(this, q).track.addEventListener("mousedown", (i) => {
259
- if (i.button !== 0 || i.target === t(this, q).thumb) return;
260
- const n = t(this, q).track.getBoundingClientRect(), a = t(this, q).thumb.clientHeight, o = i.clientY - n.top - a / 2, l = n.height - a, f = e.clientHeight, u = s(), g = Math.max(u - f, 1);
257
+ }), t(this, q).track.addEventListener("mousedown", (r) => {
258
+ if (r.button !== 0 || r.target === t(this, q).thumb) return;
259
+ const n = t(this, q).track.getBoundingClientRect(), a = t(this, q).thumb.clientHeight, o = r.clientY - n.top - a / 2, l = n.height - a, f = e.clientHeight, u = s(), g = Math.max(u - f, 1);
261
260
  if (l > 0 && g > 0) {
262
261
  const b = Math.max(0, Math.min(1, o / l));
263
262
  e.scrollTop = b * g;
@@ -355,14 +354,14 @@ const $e = class $e extends HTMLElement {
355
354
  F = new WeakMap(), at = new WeakMap(), J = new WeakMap(), q = new WeakMap(), vt = new WeakMap(), wt = new WeakMap(), Wt = new WeakMap(), h($e, "NineTableVScrollBar");
356
355
  let ce = $e;
357
356
  customElements.get("nine-table-vscrollbar") || customElements.define("nine-table-vscrollbar", ce);
358
- var D, S, Q, P, M, V, tt, St, Ee, lt, Ot, Bt, zt, Et, At, Pt, Dt, Rt, Ae, ct, qt, jt;
357
+ var D, S, Q, P, H, V, tt, St, Ee, lt, Ot, Bt, zt, Et, At, Pt, Dt, Rt, Ae, ct, qt, jt;
359
358
  const Ie = class Ie {
360
- constructor(r) {
359
+ constructor(i) {
361
360
  d(this, D);
362
361
  d(this, S);
363
362
  d(this, Q);
364
363
  d(this, P, /* @__PURE__ */ new Map());
365
- d(this, M, null);
364
+ d(this, H, null);
366
365
  d(this, V, null);
367
366
  d(this, tt, 0);
368
367
  d(this, St, 40);
@@ -371,15 +370,15 @@ const Ie = class Ie {
371
370
  d(this, Ot, 3);
372
371
  E(this, "refresh", /* @__PURE__ */ h(() => {
373
372
  var e;
374
- H.log("rowManager.refresh");
375
- const r = t(this, S).querySelector(".ng-container-body .ng-part-body");
376
- r && (t(this, Et).call(this), t(this, ct).call(this, r.scrollTop), (e = t(this, S).querySelector("nine-table-vscrollbar")) == null || e.refresh());
373
+ I.log("rowManager.refresh");
374
+ const i = t(this, S).querySelector(".ng-container-body .ng-part-body");
375
+ i && (t(this, Et).call(this), t(this, ct).call(this, i.scrollTop), (e = t(this, S).querySelector("nine-table-vscrollbar")) == null || e.refresh());
377
376
  }, "refresh"));
378
377
  E(this, "initialize", /* @__PURE__ */ h(() => {
379
- H.log("rowManager.initialize"), y(this, Q, {
378
+ I.log("rowManager.initialize"), y(this, Q, {
380
379
  scrollTables: t(this, S).querySelectorAll(".ng-part-body table"),
381
380
  firstTr: t(this, S).querySelector(".ng-container-body .ng-part-body tbody.bindable-tbody tr:not(.nodata)")
382
- }), y(this, M, null), t(this, P).clear(), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((a) => {
381
+ }), y(this, H, null), t(this, P).clear(), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((a) => {
383
382
  const o = t(this, S).querySelector(a);
384
383
  if (!o) return;
385
384
  const c = o.querySelector(".ng-part-body table");
@@ -389,15 +388,15 @@ const Ie = class Ie {
389
388
  const u = Array.from(l.querySelectorAll("tr")).map((g) => g.cloneNode(!0));
390
389
  t(this, P).set(a, u);
391
390
  });
392
- const r = 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"), i = t(this, S).querySelector(".ng-container-body .ng-part-header"), n = t(this, S).querySelector(".ng-container-body .ng-part-footer");
393
- if (r) {
394
- t(this, zt).call(this, r), t(this, Rt).call(this), t(this, Et).call(this), t(this, ct).call(this, r.scrollTop);
391
+ 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");
392
+ if (i) {
393
+ t(this, zt).call(this, i), t(this, Rt).call(this), t(this, Et).call(this), t(this, ct).call(this, i.scrollTop);
395
394
  let a = !1;
396
395
  const o = /* @__PURE__ */ h((c, l, f) => {
397
396
  var u;
398
- a || (a = !0, r && r.scrollTop !== c && (r.scrollTop = c), e && e.scrollTop !== c && (e.scrollTop = c), s && s.scrollTop !== c && (s.scrollTop = c), i && i.scrollLeft !== l && (i.scrollLeft = l), n && n.scrollLeft !== l && (n.scrollLeft = l), t(this, ct).call(this, c), (u = t(this, S).querySelector("nine-table-vscrollbar")) == null || u.refresh(), a = !1);
397
+ a || (a = !0, i && i.scrollTop !== c && (i.scrollTop = c), e && e.scrollTop !== c && (e.scrollTop = c), s && s.scrollTop !== c && (s.scrollTop = c), r && r.scrollLeft !== l && (r.scrollLeft = l), n && n.scrollLeft !== l && (n.scrollLeft = l), t(this, ct).call(this, c), (u = t(this, S).querySelector("nine-table-vscrollbar")) == null || u.refresh(), a = !1);
399
398
  }, "syncScroll");
400
- [r, e, s].forEach((c) => {
399
+ [i, e, s].forEach((c) => {
401
400
  c && c.addEventListener("scroll", () => {
402
401
  t(this, lt) || (y(this, lt, !0), requestAnimationFrame(() => {
403
402
  o(c.scrollTop, c.scrollLeft), y(this, lt, !1);
@@ -406,62 +405,62 @@ const Ie = class Ie {
406
405
  });
407
406
  }
408
407
  }, "initialize"));
409
- d(this, Bt, /* @__PURE__ */ h((r, e) => {
410
- H.log("rowManager.#renderRows");
408
+ d(this, Bt, /* @__PURE__ */ h((i, e) => {
409
+ I.log("rowManager.#renderRows");
411
410
  const s = t(this, P).get(e);
412
411
  if (!s || s.length === 0) return;
413
- const i = r.querySelector(".ng-part-body tbody.bindable-tbody");
414
- if (!i) return;
415
- i.querySelectorAll("tr:not(.nodata)").forEach((o) => o.remove());
416
- const n = i.querySelector("tr.nodata"), a = document.createDocumentFragment();
412
+ const r = i.querySelector(".ng-part-body tbody.bindable-tbody");
413
+ if (!r) return;
414
+ r.querySelectorAll("tr:not(.nodata)").forEach((o) => o.remove());
415
+ const n = r.querySelector("tr.nodata"), a = document.createDocumentFragment();
417
416
  for (let o = 0; o < t(this, St); o++)
418
417
  s.forEach((c) => {
419
418
  a.appendChild(c.cloneNode(!0));
420
419
  });
421
- n ? n.before(a) : i.appendChild(a), e === ".ng-container-body" && (t(this, Q).firstTr = i.querySelector("tr:not(.nodata)"));
420
+ n ? n.before(a) : r.appendChild(a), e === ".ng-container-body" && (t(this, Q).firstTr = r.querySelector("tr:not(.nodata)"));
422
421
  }, "#renderRows"));
423
- d(this, zt, /* @__PURE__ */ h((r) => {
424
- if (H.log("rowManager.#measureAndCacheHeight"), t(this, M) !== null && t(this, M) > 0)
425
- return t(this, M);
426
- H.log("#measureAndCacheHeight");
422
+ d(this, zt, /* @__PURE__ */ h((i) => {
423
+ if (I.log("rowManager.#measureAndCacheHeight"), t(this, H) !== null && t(this, H) > 0)
424
+ return t(this, H);
425
+ I.log("#measureAndCacheHeight");
427
426
  const e = t(this, P).get(".ng-container-body");
428
427
  if (!e || e.length === 0) return 24;
429
- const s = r.querySelector("tbody.bindable-tbody");
428
+ const s = i.querySelector("tbody.bindable-tbody");
430
429
  if (!s) return 24;
431
430
  s.querySelectorAll("tr:not(.nodata)").forEach((g) => g.remove());
432
- const i = s.querySelector("tr.nodata"), n = document.createDocumentFragment();
431
+ const r = s.querySelector("tr.nodata"), n = document.createDocumentFragment();
433
432
  e.forEach((g) => {
434
433
  n.appendChild(g.cloneNode(!0));
435
- }), i ? i.before(n) : s.appendChild(n);
434
+ }), r ? r.before(n) : s.appendChild(n);
436
435
  const a = t(this, S), o = a.style.display, c = a.style.visibility, l = a.style.position;
437
436
  (o === "none" || window.getComputedStyle(a).display === "none") && (a.style.display = "block", a.style.visibility = "hidden", a.style.position = "absolute");
438
437
  let f = 0;
439
438
  const u = s.querySelectorAll("tr:not(.nodata)");
440
439
  return u.forEach((g) => {
441
440
  f += g.offsetHeight || g.getBoundingClientRect().height;
442
- }), u.forEach((g) => g.remove()), a.style.display = o, a.style.visibility = c, a.style.position = l, y(this, M, f > 0 ? f : 24), t(this, At).call(this), t(this, M);
441
+ }), u.forEach((g) => g.remove()), a.style.display = o, a.style.visibility = c, a.style.position = l, y(this, H, f > 0 ? f : 24), t(this, At).call(this), t(this, H);
443
442
  }, "#measureAndCacheHeight"));
444
443
  d(this, Et, /* @__PURE__ */ h(() => {
445
- H.log("rowManager.#updateVirtualScrollHeight");
446
- const e = (t(this, D).data.get() || []).length, s = t(this, M), i = e * s;
444
+ I.log("rowManager.#updateVirtualScrollHeight");
445
+ const e = (t(this, D).data.get() || []).length, s = t(this, H), r = e * s;
447
446
  [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((n) => {
448
447
  const a = t(this, S).querySelector(n);
449
448
  if (!a) return;
450
449
  const o = a.querySelector(".ng-part-body .ng-virtual-spacer");
451
- o && (o.style.height = `${i}px`);
450
+ o && (o.style.height = `${r}px`);
452
451
  });
453
452
  }, "#updateVirtualScrollHeight"));
454
453
  d(this, At, /* @__PURE__ */ h(() => {
455
- if (t(this, tt) > 0 && t(this, M) > 0) {
456
- const r = Math.ceil(t(this, tt) / t(this, M));
457
- y(this, St, r + t(this, Ot));
454
+ if (t(this, tt) > 0 && t(this, H) > 0) {
455
+ const i = Math.ceil(t(this, tt) / t(this, H));
456
+ y(this, St, i + t(this, Ot));
458
457
  }
459
458
  }, "#updateRowCount"));
460
459
  d(this, Pt, /* @__PURE__ */ h(() => {
461
460
  var o, c, l, f, u, g;
462
- const r = 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");
461
+ 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
462
  if (e) {
464
- const b = r ? Array.from(r.querySelectorAll("tbody tr")) : [], x = Array.from(e.querySelectorAll("tbody tr")), v = s ? Array.from(s.querySelectorAll("tbody tr")) : [], A = Math.max(b.length, x.length, v.length);
463
+ const b = i ? Array.from(i.querySelectorAll("tbody tr")) : [], x = Array.from(e.querySelectorAll("tbody tr")), v = s ? Array.from(s.querySelectorAll("tbody tr")) : [], A = Math.max(b.length, x.length, v.length);
465
464
  for (let m = 0; m < A; m++) {
466
465
  const W = [
467
466
  ((o = b[m]) == null ? void 0 : o.getBoundingClientRect().height) || 0,
@@ -471,9 +470,9 @@ const Ie = class Ie {
471
470
  C > 0 && (b[m] && (b[m].style.height = `${C}px`), x[m] && (x[m].style.height = `${C}px`), v[m] && (v[m].style.height = `${C}px`));
472
471
  }
473
472
  }
474
- const i = t(this, S).querySelector(".ng-container-left .ng-part-footer table"), n = t(this, S).querySelector(".ng-container-body .ng-part-footer table"), a = t(this, S).querySelector(".ng-container-right .ng-part-footer table");
473
+ const r = t(this, S).querySelector(".ng-container-left .ng-part-footer table"), n = t(this, S).querySelector(".ng-container-body .ng-part-footer table"), a = t(this, S).querySelector(".ng-container-right .ng-part-footer table");
475
474
  if (n) {
476
- const b = i ? Array.from(i.querySelectorAll("tfoot tr")) : [], x = Array.from(n.querySelectorAll("tfoot tr")), v = a ? Array.from(a.querySelectorAll("tfoot tr")) : [], A = Math.max(b.length, x.length, v.length);
475
+ const b = r ? Array.from(r.querySelectorAll("tfoot tr")) : [], x = Array.from(n.querySelectorAll("tfoot tr")), v = a ? Array.from(a.querySelectorAll("tfoot tr")) : [], A = Math.max(b.length, x.length, v.length);
477
476
  for (let m = 0; m < A; m++) {
478
477
  const W = [
479
478
  ((f = b[m]) == null ? void 0 : f.getBoundingClientRect().height) || 0,
@@ -485,37 +484,37 @@ const Ie = class Ie {
485
484
  }
486
485
  }, "#syncRowHeights"));
487
486
  d(this, Dt, /* @__PURE__ */ h(() => {
488
- !t(this, S) || !(t(this, S) instanceof HTMLElement) || (y(this, V, new ResizeObserver((r) => {
489
- for (const e of r) {
487
+ !t(this, S) || !(t(this, S) instanceof HTMLElement) || (y(this, V, new ResizeObserver((i) => {
488
+ for (const e of i) {
490
489
  const s = e.target;
491
490
  if (!s.classList.contains("active")) continue;
492
- const i = e.contentRect.height;
493
- if (i > 0) {
491
+ const r = e.contentRect.height;
492
+ if (r > 0) {
494
493
  let n = 0;
495
494
  const a = s.querySelector(".ng-part-header"), o = s.querySelector(".ng-part-footer");
496
495
  a && (n += a.offsetHeight), o && (n += o.offsetHeight);
497
- const c = Math.max(i - n, 100);
498
- t(this, tt) !== c && (y(this, tt, c), t(this, At).call(this), t(this, M) !== null && (t(this, Rt).call(this), this.refresh()));
496
+ const c = Math.max(r - n, 100);
497
+ t(this, tt) !== c && (y(this, tt, c), t(this, At).call(this), t(this, H) !== null && (t(this, Rt).call(this), this.refresh()));
499
498
  }
500
499
  }
501
500
  })), t(this, V).observe(t(this, S)));
502
501
  }, "#initResizeObserver"));
503
502
  d(this, Rt, /* @__PURE__ */ h(() => {
504
- H.log("rowManager.#renderAllContainers"), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((r) => {
505
- const e = t(this, S).querySelector(r);
506
- e && e.querySelector(".ng-part-body tbody.bindable-tbody") && t(this, Bt).call(this, e, r);
503
+ I.log("rowManager.#renderAllContainers"), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((i) => {
504
+ const e = t(this, S).querySelector(i);
505
+ e && e.querySelector(".ng-part-body tbody.bindable-tbody") && t(this, Bt).call(this, e, i);
507
506
  }), t(this, jt).call(this), t(this, Pt).call(this);
508
507
  }, "#renderAllContainers"));
509
- d(this, Ae, /* @__PURE__ */ h((r) => {
508
+ d(this, Ae, /* @__PURE__ */ h((i) => {
510
509
  [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((e) => {
511
510
  var l;
512
511
  const s = t(this, S).querySelector(e);
513
512
  if (!s) return;
514
- const i = s.querySelector(".ng-part-body tbody.bindable-tbody");
515
- if (!i) return;
516
- const n = Array.from(i.querySelectorAll("tr:not(.nodata)")), a = ((l = t(this, P).get(e)) == null ? void 0 : l.length) || 1, c = (t(this, D).data.get() || []).length;
513
+ const r = s.querySelector(".ng-part-body tbody.bindable-tbody");
514
+ if (!r) return;
515
+ const n = Array.from(r.querySelectorAll("tr:not(.nodata)")), a = ((l = t(this, P).get(e)) == null ? void 0 : l.length) || 1, c = (t(this, D).data.get() || []).length;
517
516
  n.forEach((f, u) => {
518
- const g = r + Math.floor(u / a);
517
+ const g = i + Math.floor(u / a);
519
518
  if (g >= c) {
520
519
  f.style.display = "none";
521
520
  return;
@@ -525,20 +524,20 @@ const Ie = class Ie {
525
524
  });
526
525
  });
527
526
  }, "#adjustBufferRows"));
528
- d(this, ct, /* @__PURE__ */ h((r) => {
527
+ d(this, ct, /* @__PURE__ */ h((i) => {
529
528
  var l, f;
530
- const e = t(this, M);
529
+ const e = t(this, H);
531
530
  if (!e || e <= 0) return;
532
- const s = t(this, D).data.length, i = Math.max(0, Math.floor(r / e)), n = i * e, a = ((l = t(this, P).get(".ng-container-body")) == null ? void 0 : l.length) || 1, o = t(this, Q).firstTr, c = o && o.dataset.row !== void 0 ? parseInt(o.dataset.row, 10) : -1;
531
+ const s = t(this, D).data.length, r = Math.max(0, Math.floor(i / e)), n = r * e, a = ((l = t(this, P).get(".ng-container-body")) == null ? void 0 : l.length) || 1, o = t(this, Q).firstTr, c = o && o.dataset.row !== void 0 ? parseInt(o.dataset.row, 10) : -1;
533
532
  (f = t(this, Q)) == null || f.scrollTables.forEach((u) => {
534
533
  u.style.transform = `translate3d(0, ${n}px, 0)`;
535
- }), c !== i && [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((u) => {
534
+ }), c !== r && [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((u) => {
536
535
  const g = t(this, S).querySelector(u);
537
536
  if (!g) return;
538
537
  const b = g.querySelector(".ng-part-body tbody.bindable-tbody");
539
538
  if (!b) return;
540
539
  Array.from(b.querySelectorAll("tr:not(.nodata)")).forEach((v, A) => {
541
- const m = i + Math.floor(A / a);
540
+ const m = r + Math.floor(A / a);
542
541
  if (m >= s) {
543
542
  v.style.display = "none";
544
543
  return;
@@ -562,55 +561,55 @@ const Ie = class Ie {
562
561
  cell.dataset.row = dataIndex;
563
562
  });
564
563
  }; */
565
- d(this, qt, /* @__PURE__ */ h((r, e, s) => {
566
- r.dataset.row = s, r.data = e, Array.from(r.cells).forEach((i, n) => {
567
- i.dataset.row = s;
568
- const a = Array.from(i.children).find((o) => o.tagName.toLowerCase().startsWith("cell-") || typeof o.refresh == "function");
564
+ d(this, qt, /* @__PURE__ */ h((i, e, s) => {
565
+ i.dataset.row = s, i.data = e, Array.from(i.cells).forEach((r, n) => {
566
+ r.dataset.row = s;
567
+ const a = Array.from(r.children).find((o) => o.tagName.toLowerCase().startsWith("cell-") || typeof o.refresh == "function");
569
568
  a && typeof a.refresh == "function" && a.refresh();
570
569
  });
571
570
  }, "#bindRowData"));
572
571
  d(this, jt, /* @__PURE__ */ h(() => {
573
572
  var c, l, f;
574
- H.log("rowManager.#syncHeaderHeights");
575
- const r = 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");
573
+ I.log("rowManager.#syncHeaderHeights");
574
+ 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");
576
575
  if (!e) return;
577
- const i = r ? Array.from(r.querySelectorAll("tr")) : [], n = Array.from(e.querySelectorAll("tr")), a = s ? Array.from(s.querySelectorAll("tr")) : [], o = Math.max(i.length, n.length, a.length);
576
+ const r = i ? Array.from(i.querySelectorAll("tr")) : [], n = Array.from(e.querySelectorAll("tr")), a = s ? Array.from(s.querySelectorAll("tr")) : [], o = Math.max(r.length, n.length, a.length);
578
577
  for (let u = 0; u < o; u++) {
579
578
  const g = [
580
- ((c = i[u]) == null ? void 0 : c.getBoundingClientRect().height) || 0,
579
+ ((c = r[u]) == null ? void 0 : c.getBoundingClientRect().height) || 0,
581
580
  ((l = n[u]) == null ? void 0 : l.getBoundingClientRect().height) || 0,
582
581
  ((f = a[u]) == null ? void 0 : f.getBoundingClientRect().height) || 0
583
582
  ], b = Math.max(...g);
584
- b > 0 && (i[u] && (i[u].style.height = `${b}px`), n[u] && (n[u].style.height = `${b}px`), a[u] && (a[u].style.height = `${b}px`));
583
+ b > 0 && (r[u] && (r[u].style.height = `${b}px`), n[u] && (n[u].style.height = `${b}px`), a[u] && (a[u].style.height = `${b}px`));
585
584
  }
586
585
  }, "#syncHeaderHeights"));
587
586
  E(this, "destroy", /* @__PURE__ */ h(() => {
588
587
  t(this, V) && (t(this, V).disconnect(), y(this, V, null));
589
588
  }, "destroy"));
590
- y(this, D, r.getRootNode().host), y(this, S, r), t(this, Dt).call(this);
589
+ y(this, D, i.getRootNode().host), y(this, S, i), t(this, Dt).call(this);
591
590
  }
592
591
  getRowHeight() {
593
- return t(this, M);
592
+ return t(this, H);
594
593
  }
595
- templateLength(r = ".ng-container-body") {
594
+ templateLength(i = ".ng-container-body") {
596
595
  var e;
597
- return ((e = t(this, P).get(r)) == null ? void 0 : e.length) || 1;
596
+ return ((e = t(this, P).get(i)) == null ? void 0 : e.length) || 1;
598
597
  }
599
598
  };
600
- D = new WeakMap(), S = new WeakMap(), Q = new WeakMap(), P = new WeakMap(), M = new WeakMap(), V = new WeakMap(), tt = new WeakMap(), St = new WeakMap(), Ee = new WeakMap(), lt = new WeakMap(), Ot = new WeakMap(), Bt = new WeakMap(), zt = new WeakMap(), Et = new WeakMap(), At = new WeakMap(), Pt = new WeakMap(), Dt = new WeakMap(), Rt = new WeakMap(), Ae = new WeakMap(), ct = new WeakMap(), qt = new WeakMap(), jt = new WeakMap(), h(Ie, "RowManager");
599
+ D = new WeakMap(), S = new WeakMap(), Q = new WeakMap(), P = new WeakMap(), H = new WeakMap(), V = new WeakMap(), tt = new WeakMap(), St = new WeakMap(), Ee = new WeakMap(), lt = new WeakMap(), Ot = new WeakMap(), Bt = new WeakMap(), zt = new WeakMap(), Et = new WeakMap(), At = new WeakMap(), Pt = new WeakMap(), Dt = new WeakMap(), Rt = new WeakMap(), Ae = new WeakMap(), ct = new WeakMap(), qt = new WeakMap(), jt = new WeakMap(), h(Ie, "RowManager");
601
600
  let he = Ie;
602
601
  const Ft = class Ft {
603
602
  /**
604
603
  * 🎯 λ ˆμ΄μ•„μ›ƒ λ‚΄μ˜ μ—¬λŸ¬ rawTables 배열을 μΌκ΄„λ‘œ λ°›μ•„ 단일 λ§ˆμŠ€ν„° ν…œν”Œλ¦ΏμœΌλ‘œ 사전 μ»΄νŒŒμΌν•©λ‹ˆλ‹€.
605
604
  */
606
- static compileAll(r) {
607
- return Array.isArray(r) ? r.map((e) => Ft.compile(e)) : [];
605
+ static compileAll(i) {
606
+ return Array.isArray(i) ? i.map((e) => Ft.compile(e)) : [];
608
607
  }
609
608
  /**
610
609
  * 🎯 단일 원본 ν…Œμ΄λΈ”μ„ λ°›μ•„ κΈ°λ³Έ ꡬ쑰 보정 및 2차원 격자 인덱슀 사전 λΆ€μ—¬ μ™„λ£Œλœ λ§ˆμŠ€ν„° ν…Œμ΄λΈ” λ°˜ν™˜
611
610
  */
612
- static compile(r) {
613
- if (!r) return null;
611
+ static compile(i) {
612
+ if (!i) return null;
614
613
  const e = /* @__PURE__ */ h((o) => {
615
614
  o.querySelectorAll("tbody td, tbody th, tfoot td, tfoot th").forEach((l) => {
616
615
  const f = l.getAttribute("cell-type") || "renderer";
@@ -634,7 +633,7 @@ const Ft = class Ft {
634
633
  l ? l.after(c) : o.prepend(c);
635
634
  }
636
635
  o.classList.add("nine-table-element"), o.style.display = "table";
637
- }, "ensureTableStructure"), i = /* @__PURE__ */ h((o, c) => {
636
+ }, "ensureTableStructure"), r = /* @__PURE__ */ h((o, c) => {
638
637
  const l = Array.from(o.querySelectorAll(c + " tr")), f = Array.from(o.querySelectorAll(c + " th," + c + " td")), u = l.length;
639
638
  if (u === 0 || f.length === 0) return;
640
639
  let g = 0;
@@ -666,8 +665,8 @@ const Ft = class Ft {
666
665
  }
667
666
  });
668
667
  });
669
- }, "resetColIndex"), n = r.cloneNode(!0);
670
- return s(n), e(n), i(n, "thead"), i(n, "tbody"), i(n, "tfoot"), Array.from(n.querySelectorAll("colgroup col")).forEach((o, c) => {
668
+ }, "resetColIndex"), n = i.cloneNode(!0);
669
+ return s(n), e(n), r(n, "thead"), r(n, "tbody"), r(n, "tfoot"), Array.from(n.querySelectorAll("colgroup col")).forEach((o, c) => {
671
670
  const l = o.getAttribute("fixed");
672
671
  l && n.querySelectorAll(`thead [data-col="${c}"], tbody [data-col="${c}"], tfoot [data-col="${c}"]`).forEach((f) => {
673
672
  f.setAttribute("fixed", l);
@@ -693,28 +692,28 @@ const mt = class mt extends HTMLElement {
693
692
  { selector: ".ng-container-body", type: null },
694
693
  { selector: ".ng-container-left", type: "left" },
695
694
  { selector: ".ng-container-right", type: "right" }
696
- ].forEach(({ selector: s, type: i }) => {
695
+ ].forEach(({ selector: s, type: r }) => {
697
696
  const n = this.querySelector(s);
698
697
  if (!n) return;
699
698
  n.innerHTML = "";
700
699
  const a = document.createElement("div");
701
- a.className = "ng-part-header", a.appendChild(t(this, ht).call(this, t(this, et), i, "header"));
700
+ a.className = "ng-part-header", a.appendChild(t(this, ht).call(this, t(this, et), r, "header"));
702
701
  const o = document.createElement("div");
703
702
  o.className = "ng-part-body";
704
703
  const c = document.createElement("div");
705
- c.className = "ng-scroll-content", c.style.position = "relative", c.style.width = "100%", c.appendChild(t(this, ht).call(this, t(this, et), i, "body"));
704
+ c.className = "ng-scroll-content", c.style.position = "relative", c.style.width = "100%", c.appendChild(t(this, ht).call(this, t(this, et), r, "body"));
706
705
  const l = document.createElement("div");
707
706
  l.className = "ng-virtual-spacer", l.style.width = "100%", l.style.pointerEvents = "none", c.appendChild(l), o.appendChild(c);
708
707
  const f = document.createElement("div");
709
- f.className = "ng-part-footer", f.appendChild(t(this, ht).call(this, t(this, et), i, "footer")), n.appendChild(a), n.appendChild(o), n.appendChild(f);
708
+ f.className = "ng-part-footer", f.appendChild(t(this, ht).call(this, t(this, et), r, "footer")), n.appendChild(a), n.appendChild(o), n.appendChild(f);
710
709
  });
711
710
  }, "#renderSplitContainers"));
712
711
  d(this, Ut, /* @__PURE__ */ h(() => {
713
712
  ["left", "right", "body"].forEach((e) => {
714
- const s = this.querySelector(`.ng-container-${e}`), i = s == null ? void 0 : s.querySelectorAll("table");
715
- if (!s || !i || i.length === 0) return;
713
+ const s = this.querySelector(`.ng-container-${e}`), r = s == null ? void 0 : s.querySelectorAll("table");
714
+ if (!s || !r || r.length === 0) return;
716
715
  let n = 0;
717
- i[0].querySelectorAll("col").forEach((a) => {
716
+ r[0].querySelectorAll("col").forEach((a) => {
718
717
  const o = parseInt(a.getAttribute("width"), 10);
719
718
  isNaN(n) || (n += o);
720
719
  }), e === "body" ? s.style.flex = "1" : (s.style.flex = `0 0 ${n}px`, s.style.width = `${n}px`);
@@ -726,14 +725,14 @@ const mt = class mt extends HTMLElement {
726
725
  (s = this.querySelector("nine-table-hscrollbar")) == null || s.refresh();
727
726
  }, 0));
728
727
  }, "generate"));
729
- d(this, ht, /* @__PURE__ */ h((e, s, i) => {
728
+ d(this, ht, /* @__PURE__ */ h((e, s, r) => {
730
729
  const n = e.cloneNode(!0), a = n.querySelector("thead"), o = n.querySelector("tbody"), c = n.querySelector("tfoot");
731
- if (i === "header") {
730
+ if (r === "header") {
732
731
  if (o && o.remove(), c && c.remove(), e.querySelector("tbody")) {
733
732
  const f = document.createElement("tbody");
734
733
  f.className = "fixed-tbody", n.appendChild(f);
735
734
  }
736
- } else i === "body" ? (a && a.remove(), c && c.remove(), o && (o.className = "bindable-tbody")) : i === "footer" && (a && a.remove(), o && o.remove());
735
+ } else r === "body" ? (a && a.remove(), c && c.remove(), o && (o.className = "bindable-tbody")) : r === "footer" && (a && a.remove(), o && o.remove());
737
736
  return s === "left" ? n.querySelectorAll("col, th, td, tfoot td, tfoot th").forEach((l) => {
738
737
  l.getAttribute("fixed") !== "left" && l.remove();
739
738
  }) : s === "right" ? n.querySelectorAll("col, th, td, tfoot td, tfoot th").forEach((l) => {
@@ -909,7 +908,7 @@ const mt = class mt extends HTMLElement {
909
908
  t(this, Xt).call(this);
910
909
  }
911
910
  disconnectedCallback() {
912
- this.innerHTML = "", H.log("NineTableSheet destroyed.");
911
+ this.innerHTML = "", I.log("NineTableSheet destroyed.");
913
912
  }
914
913
  };
915
914
  Vt = new WeakMap(), et = new WeakMap(), st = new WeakMap(), Yt = new WeakMap(), Ut = new WeakMap(), ht = new WeakMap(), Xt = new WeakMap(), Kt = new WeakMap(), h(mt, "NineTableSheet"), E(mt, "SCROLLBAR_SIZE", 16);
@@ -923,12 +922,12 @@ const _e = class _e extends HTMLElement {
923
922
  var e;
924
923
  (e = this.querySelector(".nine-tab-bar")) == null || e.addEventListener("click", (s) => {
925
924
  var a;
926
- const i = s.ctrlKey || s.metaKey || s.shiftKey, n = parseInt((a = s.target.closest(".nine-tab-item")) == null ? void 0 : a.dataset.index, 10);
927
- t(this, kt).call(this, n, i);
925
+ const r = s.ctrlKey || s.metaKey || s.shiftKey, n = parseInt((a = s.target.closest(".nine-tab-item")) == null ? void 0 : a.dataset.index, 10);
926
+ t(this, kt).call(this, n, r);
928
927
  }), t(this, kt).call(this, 0, !1);
929
928
  }, "#init"));
930
929
  d(this, kt, /* @__PURE__ */ h((e, s = !1) => {
931
- const i = /* @__PURE__ */ h(() => {
930
+ const r = /* @__PURE__ */ h(() => {
932
931
  const f = Array.from(this.querySelectorAll("nine-table-sheet"));
933
932
  Array.from(this.querySelectorAll("nine-splitter")).forEach((b) => b.style.setProperty("display", "none"));
934
933
  const g = f.filter((b) => b.classList.contains("active"));
@@ -956,7 +955,7 @@ const _e = class _e extends HTMLElement {
956
955
  const l = a.querySelectorAll("nine-table-sheet.active");
957
956
  l == null || l.forEach((f) => {
958
957
  f.style.flex = l.length > 1 ? "1 1 0%" : "1 1 100%";
959
- }), i();
958
+ }), r();
960
959
  }, "#switchSheet"));
961
960
  }
962
961
  connectedCallback() {
@@ -966,29 +965,29 @@ const _e = class _e extends HTMLElement {
966
965
  Zt = new WeakMap(), kt = new WeakMap(), h(_e, "NineTableSheets");
967
966
  let fe = _e;
968
967
  customElements.get("nine-table-sheets") || customElements.define("nine-table-sheets", fe);
969
- var I, Gt, Tt, Jt;
968
+ var M, Gt, Tt, Jt;
970
969
  const Ne = class Ne {
971
- constructor(r) {
972
- d(this, I);
970
+ constructor(i) {
971
+ d(this, M);
973
972
  d(this, Gt, /* @__PURE__ */ h(() => {
974
- t(this, Jt).call(this), new ResizeObserver((r) => {
975
- for (let e of r)
976
- t(this, I).getAttribute("auto-height") === "true" && t(this, Tt).call(this);
977
- }).observe(t(this, I));
973
+ t(this, Jt).call(this), new ResizeObserver((i) => {
974
+ for (let e of i)
975
+ t(this, M).getAttribute("auto-height") === "true" && t(this, Tt).call(this);
976
+ }).observe(t(this, M));
978
977
  }, "#init"));
979
978
  d(this, Tt, /* @__PURE__ */ h(() => {
980
979
  var c, l;
981
- const r = Array.from(t(this, I).shadowRoot.querySelectorAll("nine-table-sheet.active"));
982
- if (r.length === 0) return;
983
- const e = parseInt(t(this, I).getAttribute("max-display-row"), 10) || 10, s = Math.max(...r.map((f) => f.getRowHeight())), i = (c = t(this, I).shadowRoot.querySelector("nine-table-header")) == null ? void 0 : c.getBoundingClientRect().height, n = (l = t(this, I).shadowRoot.querySelector("nine-table-sheets-footer")) == null ? void 0 : l.getBoundingClientRect().height, a = It.SCROLLBAR_SIZE, o = e * s + i + n + a;
984
- t(this, I).style.height = `${o}px`;
980
+ const i = Array.from(t(this, M).shadowRoot.querySelectorAll("nine-table-sheet.active"));
981
+ if (i.length === 0) return;
982
+ const e = parseInt(t(this, M).getAttribute("max-display-row"), 10) || 10, s = Math.max(...i.map((f) => f.getRowHeight())), r = (c = t(this, M).shadowRoot.querySelector("nine-table-header")) == null ? void 0 : c.getBoundingClientRect().height, n = (l = t(this, M).shadowRoot.querySelector("nine-table-sheets-footer")) == null ? void 0 : l.getBoundingClientRect().height, a = It.SCROLLBAR_SIZE, o = e * s + r + n + a;
983
+ t(this, M).style.height = `${o}px`;
985
984
  }, "#applyAutoHeight"));
986
985
  d(this, Jt, /* @__PURE__ */ h(() => {
987
- const e = Array.from(t(this, I).children).filter((c) => c.tagName === "TABLE"), s = t(this, I).getAttribute("auto-height") === "true", i = e.length, n = e.map((c, l) => {
988
- const u = `<nine-table-sheet class="${l === 0 ? "active" : ""}" data-index="${l}"></nine-table-sheet>`, g = l < i - 1 ? `<nine-splitter class="h" data-split-index="${l}"></nine-splitter>` : "";
986
+ const e = Array.from(t(this, M).children).filter((c) => c.tagName === "TABLE"), s = t(this, M).getAttribute("auto-height") === "true", r = e.length, n = e.map((c, l) => {
987
+ 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>` : "";
989
988
  return u + g;
990
989
  }).join(""), a = e.map((c, l) => `<div class="nine-tab-item ${l === 0 ? "active" : ""}" data-index="${l}">Sheet ${l + 1}</div>`).join("");
991
- t(this, I).shadowRoot.innerHTML = `
990
+ t(this, M).shadowRoot.innerHTML = `
992
991
  <style>
993
992
  :host {
994
993
  display: flex;
@@ -1079,39 +1078,39 @@ const Ne = class Ne {
1079
1078
  </nine-table-body>
1080
1079
  <nine-table-footer></nine-table-footer>
1081
1080
  `;
1082
- const o = t(this, I).shadowRoot.querySelectorAll("nine-table-sheet");
1081
+ const o = t(this, M).shadowRoot.querySelectorAll("nine-table-sheet");
1083
1082
  o == null || o.forEach((c, l) => {
1084
1083
  e[l] && setTimeout(() => {
1085
1084
  c.generate(e[l]), s && t(this, Tt).call(this);
1086
1085
  });
1087
1086
  });
1088
1087
  }, "#render"));
1089
- y(this, I, r), t(this, Gt).call(this);
1088
+ y(this, M, i), t(this, Gt).call(this);
1090
1089
  }
1091
1090
  };
1092
- I = new WeakMap(), Gt = new WeakMap(), Tt = new WeakMap(), Jt = new WeakMap(), h(Ne, "LayoutManager");
1091
+ M = new WeakMap(), Gt = new WeakMap(), Tt = new WeakMap(), Jt = new WeakMap(), h(Ne, "LayoutManager");
1093
1092
  let ue = Ne;
1094
1093
  var Ct, dt;
1095
1094
  const We = class We {
1096
- constructor(r) {
1095
+ constructor(i) {
1097
1096
  d(this, Ct);
1098
1097
  d(this, dt, -1);
1099
1098
  E(this, "count", /* @__PURE__ */ h(() => t(this, Ct).rawRecords.length, "count"));
1100
- y(this, Ct, r);
1099
+ y(this, Ct, i);
1101
1100
  }
1102
1101
  get at() {
1103
1102
  return t(this, dt);
1104
1103
  }
1105
- set at(r) {
1106
- y(this, dt, parseInt(r, 10)), body && !body.querySelector(`tbody.bindable tr[data-row="${t(this, dt)}"]`) && setTimeout(() => {
1104
+ set at(i) {
1105
+ y(this, dt, parseInt(i, 10)), body && !body.querySelector(`tbody.bindable tr[data-row="${t(this, dt)}"]`) && setTimeout(() => {
1107
1106
  });
1108
1107
  }
1109
1108
  };
1110
1109
  Ct = new WeakMap(), dt = new WeakMap(), h(We, "ngRow");
1111
1110
  let ge = We;
1112
- var _, k, N, ft, Qt, Y, te, rt, Lt, ee, se, ut;
1111
+ var _, k, N, ft, Qt, Y, te, it, Lt, ee, se, ut;
1113
1112
  const O = class O {
1114
- constructor(r, e) {
1113
+ constructor(i, e) {
1115
1114
  d(this, _);
1116
1115
  d(this, k);
1117
1116
  d(this, N, []);
@@ -1120,34 +1119,34 @@ const O = class O {
1120
1119
  d(this, Y, []);
1121
1120
  d(this, te, /* @__PURE__ */ h(() => {
1122
1121
  y(this, Y, []);
1123
- const r = t(this, _).template || [];
1124
- Array.from(r).forEach((e) => {
1122
+ const i = t(this, _).template || [];
1123
+ Array.from(i).forEach((e) => {
1125
1124
  var s;
1126
1125
  t(this, Y).push(((s = e.getBoundingClientRect) == null ? void 0 : s.call(e).height) || 24);
1127
1126
  }), (t(this, k).rawRecords || []).forEach((e) => {
1128
1127
  e.__ng || (e.__ng = t(this, Lt).call(this)), e.__ng.height = t(this, Y).slice();
1129
1128
  });
1130
1129
  }, "#initialize"));
1131
- d(this, rt, /* @__PURE__ */ h(() => {
1132
- t(this, _).shadowRoot.querySelectorAll("nine-table-sheet").forEach((r) => {
1133
- r.invalidate();
1130
+ d(this, it, /* @__PURE__ */ h(() => {
1131
+ t(this, _).shadowRoot.querySelectorAll("nine-table-sheet").forEach((i) => {
1132
+ i.invalidate();
1134
1133
  });
1135
1134
  }, "#invalidate"));
1136
- E(this, "get", /* @__PURE__ */ h((r, e) => {
1135
+ E(this, "get", /* @__PURE__ */ h((i, e) => {
1137
1136
  var n;
1138
1137
  const s = this.getValidData();
1139
1138
  if (!s || s.length <= 0) return;
1140
- if (r == null) return t(this, ut).call(this, s);
1141
- if (r < 0 || r >= s.length) return null;
1142
- const i = typeof ((n = t(this, _).fields) == null ? void 0 : n.get) == "function" ? t(this, _).fields.get() : [];
1139
+ if (i == null) return t(this, ut).call(this, s);
1140
+ if (i < 0 || i >= s.length) return null;
1141
+ const r = typeof ((n = t(this, _).fields) == null ? void 0 : n.get) == "function" ? t(this, _).fields.get() : [];
1143
1142
  if (e != null) {
1144
- const a = i.indexOf(e);
1145
- return a >= 0 ? s[r].v[a] : null;
1143
+ const a = r.indexOf(e);
1144
+ return a >= 0 ? s[i].v[a] : null;
1146
1145
  }
1147
- return t(this, ut).call(this, s[r]);
1146
+ return t(this, ut).call(this, s[i]);
1148
1147
  }, "get"));
1149
- E(this, "set", /* @__PURE__ */ h((r) => {
1150
- this.clear(), this.add(r, !1), t(this, rt).call(this);
1148
+ E(this, "set", /* @__PURE__ */ h((i) => {
1149
+ this.clear(), this.add(i, !1), t(this, it).call(this);
1151
1150
  }, "set"));
1152
1151
  d(this, Lt, /* @__PURE__ */ h(() => ({
1153
1152
  rowState: O.ROW_STATE.EMPTY,
@@ -1159,84 +1158,84 @@ const O = class O {
1159
1158
  _: [0, 0, 0, 0, O.ROW_STATE.EMPTY, !1, !1, !0, !1, !0, !0, !1, t(this, Y).slice(), -1, {}, {}]
1160
1159
  }), "#getDefaultMeta"));
1161
1160
  E(this, "reset", /* @__PURE__ */ h(() => {
1162
- y(this, N, []), y(this, ft, []), t(this, rt).call(this);
1161
+ y(this, N, []), y(this, ft, []), t(this, it).call(this);
1163
1162
  }, "reset"));
1164
1163
  E(this, "clear", /* @__PURE__ */ h(() => {
1165
- var r;
1166
- t(this, k).rawRecords = [], y(this, N, []), y(this, ft, []), (r = t(this, k).viewRecords) != null && r.reset && t(this, k).viewRecords.reset();
1167
- }, "clear"));
1168
- d(this, ee, /* @__PURE__ */ h((r) => {
1169
1164
  var i;
1170
- Array.isArray(r) || (r = [r]);
1171
- const e = typeof ((i = t(this, _).fields) == null ? void 0 : i.get) == "function" ? t(this, _).fields.get() : Object.keys(r[0] || {}), s = [];
1172
- return r.forEach((n) => {
1165
+ t(this, k).rawRecords = [], y(this, N, []), y(this, ft, []), (i = t(this, k).viewRecords) != null && i.reset && t(this, k).viewRecords.reset();
1166
+ }, "clear"));
1167
+ d(this, ee, /* @__PURE__ */ h((i) => {
1168
+ var r;
1169
+ Array.isArray(i) || (i = [i]);
1170
+ const e = typeof ((r = t(this, _).fields) == null ? void 0 : r.get) == "function" ? t(this, _).fields.get() : Object.keys(i[0] || {}), s = [];
1171
+ return i.forEach((n) => {
1173
1172
  const a = { v: [] };
1174
1173
  e.forEach((o) => {
1175
1174
  a.v.push(n[o] !== void 0 && n[o] !== null ? n[o] : "");
1176
1175
  }), s.push(a);
1177
1176
  }), s;
1178
1177
  }, "#json2Array"));
1179
- d(this, se, /* @__PURE__ */ h((r) => (Array.isArray(r) || (r = [r]), r.forEach((e) => {
1178
+ d(this, se, /* @__PURE__ */ h((i) => (Array.isArray(i) || (i = [i]), i.forEach((e) => {
1180
1179
  e.__ng = t(this, Lt).call(this), e.__ng.rowid = this.nextId, e.__ng.rowState = O.ROW_STATE.INSERT, e.__ng._[0] = e.__ng.rowid;
1181
- }), r), "#defaultInsert"));
1182
- E(this, "add", /* @__PURE__ */ h((r, e = !0) => {
1183
- r === void 0 && (r = {});
1184
- const s = t(this, ee).call(this, r);
1180
+ }), i), "#defaultInsert"));
1181
+ E(this, "add", /* @__PURE__ */ h((i, e = !0) => {
1182
+ i === void 0 && (i = {});
1183
+ const s = t(this, ee).call(this, i);
1185
1184
  t(this, k).rawRecords = t(this, k).rawRecords.concat(t(this, se).call(this, s)), this.resetRecords();
1186
- const i = this.count() - 1;
1185
+ const r = this.count() - 1;
1187
1186
  return e || s.forEach((n, a) => {
1188
- const o = t(this, k).rawRecords[i - a];
1187
+ const o = t(this, k).rawRecords[r - a];
1189
1188
  o && (o.__ng.rowState = O.ROW_STATE.EMPTY);
1190
- }), t(this, rt).call(this), i;
1189
+ }), t(this, it).call(this), r;
1191
1190
  }, "add"));
1192
- E(this, "delete", /* @__PURE__ */ h((r) => {
1191
+ E(this, "delete", /* @__PURE__ */ h((i) => {
1193
1192
  let e = [];
1194
- Array.isArray(r) ? e = r : typeof r > "u" ? e = [t(this, k).host.row.at] : e = [parseInt(r, 10)], e.sort((s, i) => i - s).forEach((s) => {
1193
+ Array.isArray(i) ? e = i : typeof i > "u" ? e = [t(this, k).host.row.at] : e = [parseInt(i, 10)], e.sort((s, r) => r - s).forEach((s) => {
1195
1194
  if (t(this, N)[s]) {
1196
- const i = t(this, N)[s].__ng.rowid;
1197
- t(this, N)[s].__ng.rowState === O.ROW_STATE.INSERT ? t(this, k).rawRecords = t(this, k).rawRecords.filter((n) => n.__ng.rowid !== i) : t(this, k).rawRecords.forEach((n) => {
1198
- n.__ng.rowid === i && (n.__ng.deleted = !0, n.__ng.rowState = O.ROW_STATE.DELETE);
1195
+ const r = t(this, N)[s].__ng.rowid;
1196
+ t(this, N)[s].__ng.rowState === O.ROW_STATE.INSERT ? t(this, k).rawRecords = t(this, k).rawRecords.filter((n) => n.__ng.rowid !== r) : t(this, k).rawRecords.forEach((n) => {
1197
+ n.__ng.rowid === r && (n.__ng.deleted = !0, n.__ng.rowState = O.ROW_STATE.DELETE);
1199
1198
  });
1200
1199
  }
1201
- }), this.resetRecords(), t(this, rt).call(this);
1200
+ }), this.resetRecords(), t(this, it).call(this);
1202
1201
  }, "delete"));
1203
- E(this, "setValue", /* @__PURE__ */ h((r, e, s) => {
1202
+ E(this, "setValue", /* @__PURE__ */ h((i, e, s) => {
1204
1203
  var c;
1205
- r = parseInt(r, 10);
1204
+ i = parseInt(i, 10);
1206
1205
  const n = (typeof ((c = t(this, _).fields) == null ? void 0 : c.get) == "function" ? t(this, _).fields.get() : []).indexOf(e);
1207
1206
  if (n < 0) return;
1208
- const a = this.getValidData()[r];
1207
+ const a = this.getValidData()[i];
1209
1208
  if (!a) return;
1210
1209
  const o = a.v[n];
1211
1210
  o !== s && a.__ng.rowState !== O.ROW_STATE.INSERT && (a.__ng.o.hasOwnProperty(e) || (a.__ng.o[e] = o), a.__ng.rowState = O.ROW_STATE.UPDATE), a.v[n] = s;
1212
1211
  }, "setValue"));
1213
1212
  E(this, "resetRecords", /* @__PURE__ */ h(() => {
1214
- y(this, ft, t(this, k).rawRecords.filter((r) => !r.__ng.deleted)), y(this, N, t(this, k).rawRecords.filter((r) => !r.__ng.deleted && !r.__ng.filtered)), t(this, k).rawRecords.forEach((r, e) => {
1215
- r.__ng.rowidx = e;
1216
- }), t(this, N).forEach((r, e) => {
1217
- r.__ng.i = e;
1213
+ y(this, ft, t(this, k).rawRecords.filter((i) => !i.__ng.deleted)), y(this, N, t(this, k).rawRecords.filter((i) => !i.__ng.deleted && !i.__ng.filtered)), t(this, k).rawRecords.forEach((i, e) => {
1214
+ i.__ng.rowidx = e;
1215
+ }), t(this, N).forEach((i, e) => {
1216
+ i.__ng.i = e;
1218
1217
  });
1219
1218
  }, "resetRecords"));
1220
1219
  E(this, "getValidData", /* @__PURE__ */ h(() => (t(this, N).length === 0 && t(this, k).rawRecords.length > 0 && this.resetRecords(), t(this, N)), "getValidData"));
1221
- d(this, ut, /* @__PURE__ */ h((r) => {
1220
+ d(this, ut, /* @__PURE__ */ h((i) => {
1222
1221
  var a;
1223
- if (!r) return r;
1224
- const e = !Array.isArray(r), s = e ? [r] : r, i = typeof ((a = t(this, _).fields) == null ? void 0 : a.get) == "function" ? t(this, _).fields.get() : [], n = s.filter((o) => !o.__ng.deleted).map((o) => {
1222
+ if (!i) return i;
1223
+ const e = !Array.isArray(i), s = e ? [i] : i, r = typeof ((a = t(this, _).fields) == null ? void 0 : a.get) == "function" ? t(this, _).fields.get() : [], n = s.filter((o) => !o.__ng.deleted).map((o) => {
1225
1224
  const c = {};
1226
- return i.forEach((l, f) => {
1225
+ return r.forEach((l, f) => {
1227
1226
  c[l] = o.v ? o.v[f] : o[l];
1228
1227
  }), c.__ng = o.__ng, c;
1229
1228
  });
1230
1229
  return e ? n[0] : n;
1231
1230
  }, "#conv"));
1232
1231
  E(this, "count", /* @__PURE__ */ h(() => this.getValidData().length, "count"));
1233
- y(this, _, r), y(this, k, e), t(this, te).call(this);
1232
+ y(this, _, i), y(this, k, e), t(this, te).call(this);
1234
1233
  }
1235
1234
  get source() {
1236
1235
  return t(this, ut).call(this, t(this, k).rawRecords);
1237
1236
  }
1238
- set source(r) {
1239
- this.clear(), this.add(r, !1);
1237
+ set source(i) {
1238
+ this.clear(), this.add(i, !1);
1240
1239
  }
1241
1240
  get nextId() {
1242
1241
  return ++Ue(this, Qt)._;
@@ -1251,7 +1250,7 @@ const O = class O {
1251
1250
  return this.length;
1252
1251
  }
1253
1252
  };
1254
- _ = new WeakMap(), k = new WeakMap(), N = new WeakMap(), ft = new WeakMap(), Qt = new WeakMap(), Y = new WeakMap(), te = new WeakMap(), rt = new WeakMap(), Lt = new WeakMap(), ee = new WeakMap(), se = new WeakMap(), ut = new WeakMap(), h(O, "ngData"), // 🎯 ν–‰ μƒνƒœ μ •μ˜ μƒμˆ˜λ₯Ό 클래슀 λ‚΄λΆ€λ‘œ λ‚΄μž¬ν™”
1253
+ _ = new WeakMap(), k = new WeakMap(), N = new WeakMap(), ft = new WeakMap(), Qt = new WeakMap(), Y = new WeakMap(), te = new WeakMap(), it = new WeakMap(), Lt = new WeakMap(), ee = new WeakMap(), se = new WeakMap(), ut = new WeakMap(), h(O, "ngData"), // 🎯 ν–‰ μƒνƒœ μ •μ˜ μƒμˆ˜λ₯Ό 클래슀 λ‚΄λΆ€λ‘œ λ‚΄μž¬ν™”
1255
1254
  E(O, "ROW_STATE", {
1256
1255
  EMPTY: "EMPTY",
1257
1256
  NORMAL: "NORMAL",
@@ -1260,56 +1259,56 @@ E(O, "ROW_STATE", {
1260
1259
  DELETE: "DELETE"
1261
1260
  });
1262
1261
  let be = O;
1263
- var it;
1262
+ var rt;
1264
1263
  const Oe = class Oe {
1265
- constructor(r) {
1266
- d(this, it);
1267
- y(this, it, r), this.row = new ge(this), this.data = new be(t(this, it), this), this.rawRecords = [], this.viewRecords = [], this.delRecords = [], this.pageCnt = 25, this.viewRecords.reset = () => {
1264
+ constructor(i) {
1265
+ d(this, rt);
1266
+ y(this, rt, i), this.row = new ge(this), this.data = new be(t(this, rt), this), this.rawRecords = [], this.viewRecords = [], this.delRecords = [], this.pageCnt = 25, this.viewRecords.reset = () => {
1268
1267
  var e;
1269
- (e = t(this, it).view) != null && e.redraw && t(this, it).view.redraw();
1268
+ (e = t(this, rt).view) != null && e.redraw && t(this, rt).view.redraw();
1270
1269
  }, this.setDataSource = (e) => {
1271
1270
  this.data && this.data.reset(), this.rawRecords = [], this.viewRecords = [], this.delRecords = [], this.data.set(e || []);
1272
1271
  }, this.getRowState = (e) => {
1273
- var i, n;
1272
+ var r, n;
1274
1273
  const s = parseInt(e, 10);
1275
1274
  if (!(s >= this.data.count()))
1276
- return (n = (i = this.data.getValidData()[s]) == null ? void 0 : i.__ng) == null ? void 0 : n.rowState;
1275
+ return (n = (r = this.data.getValidData()[s]) == null ? void 0 : r.__ng) == null ? void 0 : n.rowState;
1277
1276
  }, this.getRowPosition = () => this.row.at, this.setRowPosition = (e) => {
1278
1277
  this.row.at = e;
1279
- }, this.scrollTo_V1 = (e) => (e < 0 && (e = 0), e >= this.rawRecords.length && (e = this.rawRecords.length - 1), this.viewRecords.rawIndex = e, this.viewRecords.reset && this.viewRecords.reset(), !(e <= 0 || e >= this.rawRecords.length - 1)), this.getColumn = (e, s) => this.data.get(e, s), this.setColumn = (e, s, i) => {
1280
- e = parseInt(e, 10), this.data.setValue(e, s, i);
1278
+ }, this.scrollTo_V1 = (e) => (e < 0 && (e = 0), e >= this.rawRecords.length && (e = this.rawRecords.length - 1), this.viewRecords.rawIndex = e, this.viewRecords.reset && this.viewRecords.reset(), !(e <= 0 || e >= this.rawRecords.length - 1)), this.getColumn = (e, s) => this.data.get(e, s), this.setColumn = (e, s, r) => {
1279
+ e = parseInt(e, 10), this.data.setValue(e, s, r);
1281
1280
  }, this.setDataSource([]);
1282
1281
  }
1283
1282
  };
1284
- it = new WeakMap(), h(Oe, "ngDataManager");
1283
+ rt = new WeakMap(), h(Oe, "ngDataManager");
1285
1284
  let ye = Oe;
1286
- var gt, L, Ht, re;
1285
+ var gt, L, Ht, ie;
1287
1286
  const Be = class Be {
1288
1287
  // 🎯 이제 { name: string, type: string } κ°μ²΄λ“€μ˜ λ°°μ—΄λ‘œ κ΄€λ¦¬ν•©λ‹ˆλ‹€.
1289
- constructor(r) {
1288
+ constructor(i) {
1290
1289
  d(this, gt);
1291
1290
  d(this, L, []);
1292
- E(this, "add", /* @__PURE__ */ h((r, e = "string") => {
1293
- r.forEach((s) => {
1294
- t(this, L).some((i) => i.name === s) || t(this, L).push({ name: s, type: e });
1291
+ E(this, "add", /* @__PURE__ */ h((i, e = "string") => {
1292
+ i.forEach((s) => {
1293
+ t(this, L).some((r) => r.name === s) || t(this, L).push({ name: s, type: e });
1295
1294
  }), t(this, Ht).call(this);
1296
1295
  }, "add"));
1297
1296
  d(this, Ht, /* @__PURE__ */ h(() => {
1298
- const r = /* @__PURE__ */ new Map();
1297
+ const i = /* @__PURE__ */ new Map();
1299
1298
  t(this, L).forEach((e) => {
1300
- r.set(e.name, e.type);
1301
- }), y(this, L, Array.from(r, ([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);
1299
+ i.set(e.name, e.type);
1300
+ }), 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);
1302
1301
  }, "#adjust"));
1303
- d(this, re, /* @__PURE__ */ h(() => {
1304
- y(this, L, []), H.log(t(this, gt).querySelectorAll("table"));
1305
- const r = Array.from(t(this, gt).querySelectorAll("table"));
1306
- if (!(!r || r.length === 0)) {
1307
- for (const e of r)
1308
- H.log(e), $("[data-bind]", e).each((s, i) => {
1309
- const n = i.dataset.bind, a = i.getAttribute("data-type") || "string";
1302
+ d(this, ie, /* @__PURE__ */ h(() => {
1303
+ y(this, L, []), I.log(t(this, gt).querySelectorAll("table"));
1304
+ const i = Array.from(t(this, gt).querySelectorAll("table"));
1305
+ if (!(!i || i.length === 0)) {
1306
+ for (const e of i)
1307
+ I.log(e), $("[data-bind]", e).each((s, r) => {
1308
+ const n = r.dataset.bind, a = r.getAttribute("data-type") || "string";
1310
1309
  n && t(this, L).push({ name: n, type: a });
1311
1310
  }), ["data-expr", "background-color", "color", "tooltip", "visible", "readonly", "enable-button", "enable-check", "class-expr", "icon-color", "icon-src"].forEach((s) => {
1312
- $(`[${s}]`, e).each((i, n) => {
1311
+ $(`[${s}]`, e).each((r, n) => {
1313
1312
  var a = n.getAttribute(s);
1314
1313
  if (a.indexOf("data.") < 0) {
1315
1314
  const o = a.search(/[(]/g);
@@ -1332,39 +1331,39 @@ const Be = class Be {
1332
1331
  t(this, Ht).call(this);
1333
1332
  }
1334
1333
  }, "#init"));
1335
- y(this, gt, r), t(this, re).call(this);
1334
+ y(this, gt, i), t(this, ie).call(this);
1336
1335
  }
1337
1336
  // 🎯 기쑴에 ν•„λ“œ μ΄λ¦„λ§Œ μ“°λ˜ κ³³λ“€κ³Όμ˜ ν˜Έν™˜μ„ μœ„ν•΄ 이름 λ°°μ—΄λ§Œ λ¦¬ν„΄ν•˜λŠ” λ©”μ„œλ“œ μœ μ§€
1338
1337
  get() {
1339
- return t(this, L).map((r) => r.name);
1338
+ return t(this, L).map((i) => i.name);
1340
1339
  }
1341
1340
  // 🎯 λ‚΄λΆ€ 객체 ν†΅μ§Έλ‘œ μ–»κΈ°
1342
1341
  getFields() {
1343
1342
  return t(this, L);
1344
1343
  }
1345
1344
  // 🎯 νŠΉμ • ν•„λ“œμ˜ 데이터 νƒ€μž… 쑰회
1346
- getType(r) {
1347
- const e = t(this, L).find((s) => s.name === r);
1345
+ getType(i) {
1346
+ const e = t(this, L).find((s) => s.name === i);
1348
1347
  return e ? e.type : "string";
1349
1348
  }
1350
- indexOf(r) {
1351
- return t(this, L).findIndex((e) => e.name === r);
1349
+ indexOf(i) {
1350
+ return t(this, L).findIndex((e) => e.name === i);
1352
1351
  }
1353
- includes(r) {
1354
- return t(this, L).some((e) => e.name === r);
1352
+ includes(i) {
1353
+ return t(this, L).some((e) => e.name === i);
1355
1354
  }
1356
1355
  };
1357
- gt = new WeakMap(), L = new WeakMap(), Ht = new WeakMap(), re = new WeakMap(), h(Be, "ngFields");
1356
+ gt = new WeakMap(), L = new WeakMap(), Ht = new WeakMap(), ie = new WeakMap(), h(Be, "ngFields");
1358
1357
  let pe = Be;
1359
- var nt, ie, ne;
1358
+ var nt, re, ne;
1360
1359
  const ze = class ze extends HTMLElement {
1361
1360
  constructor() {
1362
1361
  super();
1363
1362
  //#created = false;
1364
1363
  d(this, nt);
1365
- d(this, ie);
1364
+ d(this, re);
1366
1365
  d(this, ne, /* @__PURE__ */ h(() => {
1367
- this.fields = new pe(this), y(this, ie, new ue(this)), H.log("NineTable connected."), this.dispatchEvent(new CustomEvent("load", { bubbles: !0, detail: { target: this } }));
1366
+ this.fields = new pe(this), y(this, re, new ue(this)), I.log("NineTable connected."), this.dispatchEvent(new CustomEvent("load", { bubbles: !0, detail: { target: this } }));
1368
1367
  }, "#init"));
1369
1368
  this.attachShadow({ mode: "open" }), y(this, nt, new ye(this));
1370
1369
  }
@@ -1372,7 +1371,7 @@ const ze = class ze extends HTMLElement {
1372
1371
  t(this, ne).call(this);
1373
1372
  }
1374
1373
  disconnectedCallback() {
1375
- H.log("NineTable disconnected.");
1374
+ I.log("NineTable disconnected.");
1376
1375
  }
1377
1376
  // 🎯 μ™ΈλΆ€μ—μ„œ grid.data.set(...) ν˜•νƒœλ‘œ μ ‘κ·Όν•  수 μžˆλ„λ‘ 데이터 λ§€λ‹ˆμ € μ˜€ν”ˆ
1378
1377
  get data() {
@@ -1387,7 +1386,7 @@ const ze = class ze extends HTMLElement {
1387
1386
  return t(this, nt);
1388
1387
  }
1389
1388
  };
1390
- nt = new WeakMap(), ie = new WeakMap(), ne = new WeakMap(), h(ze, "NineTable");
1389
+ nt = new WeakMap(), re = new WeakMap(), ne = new WeakMap(), h(ze, "NineTable");
1391
1390
  let me = ze;
1392
1391
  customElements.get("nine-table") || customElements.define("nine-table", me);
1393
1392
  const xt = class xt extends HTMLElement {
@@ -1417,13 +1416,13 @@ const Pe = class Pe extends xe {
1417
1416
  E(this, "getDisplayText", /* @__PURE__ */ h((e) => {
1418
1417
  if (t(this, p))
1419
1418
  if (t(this, p).closest("tbody")) {
1420
- const s = t(this, p).closest("tr").data, i = parseInt(t(this, p).dataset.row);
1419
+ const s = t(this, p).closest("tr").data, r = parseInt(t(this, p).dataset.row);
1421
1420
  if (!s) return "";
1422
1421
  if (ninegrid.isNull(t(this, p).dataset.expr)) {
1423
1422
  if (!ninegrid.isNull(t(this, p).dataset.bind))
1424
1423
  return s[t(this, p).dataset.bind] || ninegrid.nvl(e, "");
1425
1424
  } else try {
1426
- return this.getExprValue(t(this, p).dataset.expr, s, i, t(this, p));
1425
+ return this.getExprValue(t(this, p).dataset.expr, s, r, t(this, p));
1427
1426
  } catch {
1428
1427
  console.error(t(this, p).dataset.expr, s, t(this, p).dataset.row);
1429
1428
  }
@@ -1438,14 +1437,14 @@ const Pe = class Pe extends xe {
1438
1437
  if (!(!t(this, T) || !t(this, T).template || !t(this, p).closest("tbody.bindable"))) {
1439
1438
  var e = ninegrid.j.querySelectorAll(t(this, p)).attr("suppress");
1440
1439
  if (e && (e = parseInt(e)), e && !isNaN(e)) {
1441
- var s = t(this, p).closest("tr"), i = [];
1440
+ var s = t(this, p).closest("tr"), r = [];
1442
1441
  $("th,td", s).each((m, W) => {
1443
1442
  var C = ninegrid.j.querySelectorAll(W).attr("suppress");
1444
- C && W.dataset.row && (C = parseInt(C), !isNaN(C) && C <= e && i.push(C));
1445
- }), i.sort();
1443
+ C && W.dataset.row && (C = parseInt(C), !isNaN(C) && C <= e && r.push(C));
1444
+ }), r.sort();
1446
1445
  var n = !1;
1447
1446
  if (parseInt(s.sectionRowIndex / t(this, T).template.length) > 0)
1448
- for (var a of i) {
1447
+ for (var a of r) {
1449
1448
  if (a > e) break;
1450
1449
  var o = parseInt(t(this, p).dataset.row), c = o - 1, l = t(this, p).closest("tr").data, f = t(this, T).data.get(c);
1451
1450
  t(this, p).dataset.matrixRow;
@@ -1463,12 +1462,12 @@ const Pe = class Pe extends xe {
1463
1462
  }
1464
1463
  }
1465
1464
  }, "#resetSuppress"));
1466
- E(this, "getExprValue", /* @__PURE__ */ h((e, s, i, n) => {
1465
+ E(this, "getExprValue", /* @__PURE__ */ h((e, s, r, n) => {
1467
1466
  if (typeof e < "u")
1468
1467
  try {
1469
- i = parseInt(i);
1468
+ r = parseInt(r);
1470
1469
  const a = e.replace("()", "");
1471
- return t(this, T)[a] ? t(this, T)[a].call(this, s, i, t(this, p)) : t(this, T).exprFunction(e).call(this, s, i, t(this, T).data);
1470
+ return t(this, T)[a] ? t(this, T)[a].call(this, s, r, t(this, p)) : t(this, T).exprFunction(e).call(this, s, r, t(this, T).data);
1472
1471
  } catch {
1473
1472
  return ["NG-COMBO"].includes(this.tagName) ? "" : e;
1474
1473
  }
@@ -1485,8 +1484,8 @@ const Pe = class Pe extends xe {
1485
1484
  }
1486
1485
  set value(e) {
1487
1486
  var s = parseInt(t(this, p).dataset.row);
1488
- const i = this.getAttribute("update-row-state") != "false";
1489
- s < 0 ? t(this, T).data.setValueNF(parseInt(t(this, p).dataset.index), t(this, p).dataset.bind, e, i) : t(this, T).data.setValue(s, t(this, p).dataset.bind, e, i);
1487
+ const r = this.getAttribute("update-row-state") != "false";
1488
+ s < 0 ? t(this, T).data.setValueNF(parseInt(t(this, p).dataset.index), t(this, p).dataset.bind, e, r) : t(this, T).data.setValue(s, t(this, p).dataset.bind, e, r);
1490
1489
  }
1491
1490
  get row() {
1492
1491
  return parseInt(t(this, p).dataset.row);
@@ -1526,7 +1525,7 @@ const je = class je extends we {
1526
1525
  d(this, U);
1527
1526
  E(this, "refresh", /* @__PURE__ */ h(() => {
1528
1527
  const e = super.refresh();
1529
- H.log("::", e), t(this, $t).value = e;
1528
+ I.log("::", e), t(this, $t).value = e;
1530
1529
  }, "refresh"));
1531
1530
  /**
1532
1531
  dataRefresh = (v) => {
@@ -1563,9 +1562,9 @@ const je = class je extends we {
1563
1562
  if (t(this, ot) == "number") {
1564
1563
  let n = [];
1565
1564
  if (t(this, U) && Number(t(this, U)) > 0 && n.push("."), t(this, yt) && Number(t(this, yt)) >= 0 && n.push("-"), !(e.keyCode >= 48 && e.keyCode <= 57 || e.keyCode >= 96 && e.keyCode <= 105) && !n.includes(e.key) && e.preventDefault(), t(this, U) && (e.keyCode >= 48 && e.keyCode <= 57 || e.keyCode >= 96 && e.keyCode <= 105) && e.target.selectionStart == e.target.selectionEnd) {
1566
- var s = e.target.value, i = s.indexOf(".");
1567
- if (i >= 0) {
1568
- var s = s.substr(i + 1, s.length);
1565
+ var s = e.target.value, r = s.indexOf(".");
1566
+ if (r >= 0) {
1567
+ var s = s.substr(r + 1, s.length);
1569
1568
  s.length >= Number(t(this, U)) && e.preventDefault();
1570
1569
  }
1571
1570
  }