@ninebone/table 0.0.687 β†’ 0.0.689

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.
@@ -55,11 +55,11 @@ const $e = class $e extends HTMLElement {
55
55
  if (l <= 0) return;
56
56
  const f = Math.max(Math.min(l * (a / c), l), 20);
57
57
  n.style.width = `${f}px`;
58
- const u = e.scrollLeft, b = c - a;
59
- let g = 0;
60
- b > 0 && (g = parseInt(u / b * (l - f), 10)), g < 0 && (g = 0);
58
+ const g = e.scrollLeft, b = c - a;
59
+ let u = 0;
60
+ b > 0 && (u = parseInt(g / b * (l - f), 10)), u < 0 && (u = 0);
61
61
  const v = l - f;
62
- g > v && (g = v), n.style.left = `${g}px`, t(this, S).left.disabled = g === 0, t(this, S).right.disabled = g >= v - 1;
62
+ u > v && (u = v), n.style.left = `${u}px`, t(this, S).left.disabled = u === 0, t(this, S).right.disabled = u >= v - 1;
63
63
  }, "refresh"));
64
64
  d(this, G, /* @__PURE__ */ h((e) => {
65
65
  if (!t(this, S)) return !1;
@@ -70,8 +70,8 @@ const $e = class $e extends HTMLElement {
70
70
  a < 0 && (a = 0);
71
71
  const c = n.width - o;
72
72
  a > c && (a = c), a = parseInt(a, 10), t(this, S).thumb.style.left = `${a}px`, t(this, S).left.disabled = a === 0, t(this, S).right.disabled = a >= c - 1;
73
- const l = s.clientWidth, u = i.scrollWidth - l;
74
- return c > 0 && u > 0 && (s.scrollLeft = a / c * u), a > 0 && a < c - 1;
73
+ const l = s.clientWidth, g = i.scrollWidth - l;
74
+ return c > 0 && g > 0 && (s.scrollLeft = a / c * g), a > 0 && a < c - 1;
75
75
  }, "#thumbMoveTo"));
76
76
  d(this, Nt, /* @__PURE__ */ h(() => {
77
77
  const e = /* @__PURE__ */ h((i) => {
@@ -201,19 +201,21 @@ const $e = class $e extends HTMLElement {
201
201
  z = new WeakMap(), j = new WeakMap(), S = new WeakMap(), X = new WeakMap(), K = new WeakMap(), Z = new WeakMap(), _t = new WeakMap(), G = new WeakMap(), Nt = new WeakMap(), h($e, "NineTableHScrollBar");
202
202
  let ae = $e;
203
203
  customElements.get("nine-table-hscrollbar") || customElements.define("nine-table-hscrollbar", ae);
204
- var F, at, J, k, vt, xt, Wt;
204
+ var F, ot, at, k, vt, xt, Wt;
205
205
  const Me = class Me extends HTMLElement {
206
206
  constructor() {
207
207
  super();
208
208
  d(this, F);
209
- d(this, at);
210
- d(this, J, !1);
209
+ d(this, ot);
210
+ d(this, at, !1);
211
211
  d(this, k);
212
212
  d(this, vt, 0);
213
213
  d(this, xt, 0);
214
214
  E(this, "refresh", /* @__PURE__ */ h(() => {
215
- if (R.log("vscrollbar.refresh"), R.log(t(this, k)), !t(this, F) || !t(this, k)) return;
216
- const e = t(this, k).container, s = t(this, k).track, i = t(this, k).thumb, n = e.clientHeight, o = t(this, F).data.length, a = t(this, at).getRowHeight(), c = o * a;
215
+ if (R.log("vscrollbar.refresh"), !t(this, F) || !t(this, k)) return;
216
+ const e = t(this, k).container, s = t(this, k).track, i = t(this, k).thumb, n = e.clientHeight, o = t(this, F).data.length, a = t(this, ot).getRowHeight();
217
+ R.log(t(this, k));
218
+ const c = o * a;
217
219
  if (c <= n || o === 0) {
218
220
  this.style.display = "none";
219
221
  return;
@@ -223,43 +225,41 @@ const Me = class Me extends HTMLElement {
223
225
  if (l <= 0) return;
224
226
  const f = Math.max(Math.min(l * (n / c), l), 20);
225
227
  i.style.height = `${f}px`;
226
- const u = e.scrollTop, b = Math.max(c - n, 1);
227
- let g = 0;
228
- b > 0 && (g = u / b * (l - f));
228
+ const g = e.scrollTop, b = Math.max(c - n, 1);
229
+ let u = 0;
230
+ b > 0 && (u = g / b * (l - f));
229
231
  const v = l - f;
230
- g < 0 && (g = 0), g > v && (g = v), i.style.top = `${g}px`, t(this, k).top.disabled = u <= 0, t(this, k).bottom.disabled = u >= b - 1;
232
+ u < 0 && (u = 0), u > v && (u = v), i.style.top = `${u}px`, t(this, k).top.disabled = g <= 0, t(this, k).bottom.disabled = g >= b - 1;
231
233
  }, "refresh"));
232
234
  d(this, Wt, /* @__PURE__ */ h(() => {
233
235
  R.log("nine-table-vscrollbar.#init");
234
236
  const e = t(this, k).container, s = /* @__PURE__ */ h(() => {
235
- const n = (t(this, F).data.get() || []).length, o = t(this, at).getRowHeight();
237
+ const n = (t(this, F).data.get() || []).length, o = t(this, ot).getRowHeight();
236
238
  return n * o;
237
239
  }, "getContentHeight");
238
- e.addEventListener("scroll", () => {
239
- t(this, J) || this.refresh();
240
- }), t(this, k).thumb.addEventListener("mousedown", (i) => {
240
+ t(this, k).thumb.addEventListener("mousedown", (i) => {
241
241
  if (i.button !== 0) return;
242
- i.stopPropagation(), i.preventDefault(), y(this, J, !0), y(this, vt, i.clientY), y(this, xt, e.scrollTop);
242
+ i.stopPropagation(), i.preventDefault(), y(this, at, !0), y(this, vt, i.clientY), y(this, xt, e.scrollTop);
243
243
  const n = /* @__PURE__ */ h((a) => {
244
- if (!t(this, J)) return;
245
- const c = t(this, k).track.getBoundingClientRect(), l = t(this, k).thumb.clientHeight, u = c.height - l, b = a.clientY - t(this, vt), g = e.clientHeight, v = s(), w = Math.max(v - g, 1);
246
- if (u > 0 && w > 0) {
247
- const A = b / u * w;
244
+ if (!t(this, at)) return;
245
+ const c = t(this, k).track.getBoundingClientRect(), l = t(this, k).thumb.clientHeight, g = c.height - l, b = a.clientY - t(this, vt), u = e.clientHeight, v = s(), w = Math.max(v - u, 1);
246
+ if (g > 0 && w > 0) {
247
+ const A = b / g * w;
248
248
  let m = t(this, xt) + A;
249
- const W = Math.max(0, v - g);
249
+ const W = Math.max(0, v - u);
250
250
  m < 0 && (m = 0), m > W && (m = W), e.scrollTop = m;
251
251
  }
252
252
  this.refresh();
253
253
  }, "onMouseMove"), o = /* @__PURE__ */ h(() => {
254
- y(this, J, !1), document.removeEventListener("mousemove", n), document.removeEventListener("mouseup", o), this.refresh();
254
+ y(this, at, !1), document.removeEventListener("mousemove", n), document.removeEventListener("mouseup", o), this.refresh();
255
255
  }, "onMouseUp");
256
256
  document.addEventListener("mousemove", n), document.addEventListener("mouseup", o);
257
257
  }), t(this, k).track.addEventListener("mousedown", (i) => {
258
258
  if (i.button !== 0 || i.target === t(this, k).thumb) return;
259
- const n = t(this, k).track.getBoundingClientRect(), o = t(this, k).thumb.clientHeight, a = i.clientY - n.top - o / 2, l = n.height - o, f = e.clientHeight, u = s(), b = Math.max(u - f, 1);
259
+ const n = t(this, k).track.getBoundingClientRect(), o = t(this, k).thumb.clientHeight, a = i.clientY - n.top - o / 2, l = n.height - o, f = e.clientHeight, g = s(), b = Math.max(g - f, 1);
260
260
  if (l > 0 && b > 0) {
261
- const g = Math.max(0, Math.min(1, a / l));
262
- e.scrollTop = g * b;
261
+ const u = Math.max(0, Math.min(1, a / l));
262
+ e.scrollTop = u * b;
263
263
  }
264
264
  this.refresh();
265
265
  }), t(this, k).top.addEventListener("click", () => {
@@ -270,7 +270,7 @@ const Me = class Me extends HTMLElement {
270
270
  }, "#init"));
271
271
  }
272
272
  connectedCallback() {
273
- y(this, F, this.getRootNode().host), y(this, at, this.closest("nine-table-sheet")), this.innerHTML = `
273
+ y(this, F, this.getRootNode().host), y(this, ot, this.closest("nine-table-sheet")), this.innerHTML = `
274
274
  <style>
275
275
  nine-table-vscrollbar {
276
276
  display: flex;
@@ -351,19 +351,19 @@ const Me = class Me extends HTMLElement {
351
351
  e();
352
352
  }
353
353
  };
354
- F = new WeakMap(), at = new WeakMap(), J = new WeakMap(), k = new WeakMap(), vt = new WeakMap(), xt = new WeakMap(), Wt = new WeakMap(), h(Me, "NineTableVScrollBar");
354
+ F = new WeakMap(), ot = new WeakMap(), at = new WeakMap(), k = new WeakMap(), vt = new WeakMap(), xt = new WeakMap(), Wt = new WeakMap(), h(Me, "NineTableVScrollBar");
355
355
  let le = Me;
356
356
  customElements.get("nine-table-vscrollbar") || customElements.define("nine-table-vscrollbar", le);
357
- var P, x, Q, D, M, V, tt, wt, Se, Ee, Ot, Bt, St, Et, At, zt, Dt, qt, Ae, lt, Rt, Pt;
357
+ var P, x, J, D, I, V, Q, wt, Se, Ee, Ot, Bt, St, Et, At, zt, Dt, qt, Ae, lt, Rt, Pt;
358
358
  const Ie = class Ie {
359
359
  constructor(r) {
360
360
  d(this, P);
361
361
  d(this, x);
362
- d(this, Q);
362
+ d(this, J);
363
363
  d(this, D, /* @__PURE__ */ new Map());
364
- d(this, M, null);
364
+ d(this, I, null);
365
365
  d(this, V, null);
366
- d(this, tt, 0);
366
+ d(this, Q, 0);
367
367
  d(this, wt, 40);
368
368
  d(this, Se, !1);
369
369
  d(this, Ee, !1);
@@ -376,31 +376,32 @@ const Ie = class Ie {
376
376
  r && (t(this, St).call(this), t(this, Et).call(this), t(this, lt).call(this, r.scrollTop), (e = t(this, x).querySelector("nine-table-vscrollbar")) == null || e.refresh());
377
377
  }, "refresh"));
378
378
  E(this, "initialize", /* @__PURE__ */ h(() => {
379
- R.log("rowManager.initialize"), y(this, Q, {
379
+ R.log("rowManager.initialize"), y(this, J, {
380
380
  scrollTables: t(this, x).querySelectorAll(".ng-part-body table"),
381
381
  firstTr: t(this, x).querySelector(".ng-container-body .ng-part-body tbody.bindable-tbody tr:not(.nodata)")
382
- }), y(this, M, null), t(this, D).clear(), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((o) => {
382
+ }), y(this, I, null), t(this, D).clear(), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((o) => {
383
383
  const a = t(this, x).querySelector(o);
384
384
  if (!a) return;
385
385
  const c = a.querySelector(".ng-part-body table");
386
386
  if (!c) return;
387
387
  const l = c.querySelector("tbody.bindable-tbody");
388
388
  if (!l) return;
389
- const u = Array.from(l.querySelectorAll("tr")).map((b) => b.cloneNode(!0));
390
- t(this, D).set(o, u);
389
+ const g = Array.from(l.querySelectorAll("tr")).map((b) => b.cloneNode(!0));
390
+ t(this, D).set(o, g);
391
391
  });
392
392
  const r = t(this, x).querySelector(".ng-container-body .ng-part-body"), e = t(this, x).querySelector(".ng-container-left .ng-part-body"), s = t(this, x).querySelector(".ng-container-right .ng-part-body"), i = t(this, x).querySelector(".ng-container-body .ng-part-header"), n = t(this, x).querySelector(".ng-container-body .ng-part-footer");
393
393
  if (r) {
394
394
  t(this, St).call(this), t(this, qt).call(this), t(this, Et).call(this), t(this, lt).call(this, r.scrollTop);
395
395
  let o = !1;
396
396
  const a = /* @__PURE__ */ h((c) => {
397
+ var g;
397
398
  if (o) return;
398
399
  o = !0;
399
400
  const l = c.scrollTop, f = c.scrollLeft;
400
- r && r.scrollTop !== l && (r.scrollTop = l), e && e.scrollTop !== l && (e.scrollTop = l), s && s.scrollTop !== l && (s.scrollTop = l), i && i.scrollLeft !== f && (i.scrollLeft = f), n && n.scrollLeft !== f && (n.scrollLeft = f), t(this, lt).call(this, l), o = !1;
401
+ r && r.scrollTop !== l && (r.scrollTop = l), e && e.scrollTop !== l && (e.scrollTop = l), s && s.scrollTop !== l && (s.scrollTop = l), i && i.scrollLeft !== f && (i.scrollLeft = f), n && n.scrollLeft !== f && (n.scrollLeft = f), t(this, lt).call(this, l), (g = t(this, x).querySelector("nine-table-vscrollbar")) == null || g.refresh(), o = !1;
401
402
  }, "handleContainerScroll");
402
403
  [r, e, s].forEach((c) => {
403
- R.log(c), c && c.addEventListener("scroll", () => {
404
+ c == null || c.addEventListener("scroll", () => {
404
405
  a(c);
405
406
  });
406
407
  });
@@ -418,11 +419,11 @@ const Ie = class Ie {
418
419
  s.forEach((c) => {
419
420
  o.appendChild(c.cloneNode(!0));
420
421
  });
421
- n ? n.before(o) : i.appendChild(o), e === ".ng-container-body" && (t(this, Q).firstTr = i.querySelector("tr:not(.nodata)"));
422
+ n ? n.before(o) : i.appendChild(o), e === ".ng-container-body" && (t(this, J).firstTr = i.querySelector("tr:not(.nodata)"));
422
423
  }, "#renderRows"));
423
424
  d(this, St, /* @__PURE__ */ h(() => {
424
- if (t(this, M) !== null && t(this, M) > 0)
425
- return t(this, M);
425
+ if (t(this, I) !== null && t(this, I) > 0)
426
+ return t(this, I);
426
427
  const r = t(this, x).querySelector(".ng-container-body .ng-part-body");
427
428
  R.log("rowManager.#measureAndCacheHeight");
428
429
  const e = t(this, D).get(".ng-container-body");
@@ -437,19 +438,19 @@ const Ie = class Ie {
437
438
  const o = t(this, x), a = o.style.display, c = o.style.visibility, l = o.style.position;
438
439
  (a === "none" || window.getComputedStyle(o).display === "none") && (o.style.display = "block", o.style.visibility = "hidden", o.style.position = "absolute");
439
440
  let f = 0;
440
- const u = s.querySelectorAll("tr");
441
- return u.forEach((b) => {
442
- let g = b.offsetHeight || b.getBoundingClientRect().height;
443
- if (g === 0) {
441
+ const g = s.querySelectorAll("tr");
442
+ return g.forEach((b) => {
443
+ let u = b.offsetHeight || b.getBoundingClientRect().height;
444
+ if (u === 0) {
444
445
  const v = window.getComputedStyle(b);
445
- g = parseFloat(v.height) || parseFloat(v.minHeight) || 0;
446
+ u = parseFloat(v.height) || parseFloat(v.minHeight) || 0;
446
447
  }
447
- f += g;
448
- }), u.forEach((b) => b.remove()), o.style.display = a, o.style.visibility = c, o.style.position = l, f <= 0 ? -1 : (y(this, M, f), t(this, At).call(this), t(this, M));
448
+ f += u;
449
+ }), g.forEach((b) => b.remove()), o.style.display = a, o.style.visibility = c, o.style.position = l, f <= 0 ? -1 : (y(this, I, f), t(this, At).call(this), t(this, I));
449
450
  }, "#measureAndCacheHeight"));
450
451
  d(this, Et, /* @__PURE__ */ h(() => {
451
452
  R.log("rowManager.#updateVirtualScrollHeight");
452
- const e = (t(this, P).data.get() || []).length, s = t(this, M), i = e * s;
453
+ const e = (t(this, P).data.get() || []).length, s = t(this, I), i = e * s;
453
454
  R.log("πŸ” [VirtualHeight]", { totalCount: e, rowHeight: s, totalVirtualHeight: i }), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((n) => {
454
455
  const o = t(this, x).querySelector(n);
455
456
  if (!o) return;
@@ -458,35 +459,35 @@ const Ie = class Ie {
458
459
  });
459
460
  }, "#updateVirtualScrollHeight"));
460
461
  d(this, At, /* @__PURE__ */ h(() => {
461
- if (t(this, tt) > 0 && t(this, M) > 0) {
462
- const r = Math.ceil(t(this, tt) / t(this, M));
462
+ if (t(this, Q) > 0 && t(this, I) > 0) {
463
+ const r = Math.ceil(t(this, Q) / t(this, I));
463
464
  y(this, wt, r + t(this, Ot));
464
465
  }
465
466
  }, "#updateRowCount"));
466
467
  d(this, zt, /* @__PURE__ */ h(() => {
467
- var a, c, l, f, u, b;
468
+ var a, c, l, f, g, b;
468
469
  const r = t(this, x).querySelector(".ng-container-left .ng-part-body table"), e = t(this, x).querySelector(".ng-container-body .ng-part-body table"), s = t(this, x).querySelector(".ng-container-right .ng-part-body table");
469
470
  if (e) {
470
- const g = r ? Array.from(r.querySelectorAll("tbody tr")) : [], v = Array.from(e.querySelectorAll("tbody tr")), w = s ? Array.from(s.querySelectorAll("tbody tr")) : [], A = Math.max(g.length, v.length, w.length);
471
+ const u = r ? Array.from(r.querySelectorAll("tbody tr")) : [], v = Array.from(e.querySelectorAll("tbody tr")), w = s ? Array.from(s.querySelectorAll("tbody tr")) : [], A = Math.max(u.length, v.length, w.length);
471
472
  for (let m = 0; m < A; m++) {
472
473
  const W = [
473
- ((a = g[m]) == null ? void 0 : a.getBoundingClientRect().height) || 0,
474
+ ((a = u[m]) == null ? void 0 : a.getBoundingClientRect().height) || 0,
474
475
  ((c = v[m]) == null ? void 0 : c.getBoundingClientRect().height) || 0,
475
476
  ((l = w[m]) == null ? void 0 : l.getBoundingClientRect().height) || 0
476
477
  ], T = Math.max(...W);
477
- T > 0 && (g[m] && (g[m].style.height = `${T}px`), v[m] && (v[m].style.height = `${T}px`), w[m] && (w[m].style.height = `${T}px`));
478
+ T > 0 && (u[m] && (u[m].style.height = `${T}px`), v[m] && (v[m].style.height = `${T}px`), w[m] && (w[m].style.height = `${T}px`));
478
479
  }
479
480
  }
480
481
  const i = t(this, x).querySelector(".ng-container-left .ng-part-footer table"), n = t(this, x).querySelector(".ng-container-body .ng-part-footer table"), o = t(this, x).querySelector(".ng-container-right .ng-part-footer table");
481
482
  if (n) {
482
- const g = i ? Array.from(i.querySelectorAll("tfoot tr")) : [], v = Array.from(n.querySelectorAll("tfoot tr")), w = o ? Array.from(o.querySelectorAll("tfoot tr")) : [], A = Math.max(g.length, v.length, w.length);
483
+ const u = i ? Array.from(i.querySelectorAll("tfoot tr")) : [], v = Array.from(n.querySelectorAll("tfoot tr")), w = o ? Array.from(o.querySelectorAll("tfoot tr")) : [], A = Math.max(u.length, v.length, w.length);
483
484
  for (let m = 0; m < A; m++) {
484
485
  const W = [
485
- ((f = g[m]) == null ? void 0 : f.getBoundingClientRect().height) || 0,
486
- ((u = v[m]) == null ? void 0 : u.getBoundingClientRect().height) || 0,
486
+ ((f = u[m]) == null ? void 0 : f.getBoundingClientRect().height) || 0,
487
+ ((g = v[m]) == null ? void 0 : g.getBoundingClientRect().height) || 0,
487
488
  ((b = w[m]) == null ? void 0 : b.getBoundingClientRect().height) || 0
488
489
  ], T = Math.max(...W);
489
- T > 0 && (g[m] && (g[m].style.height = `${T}px`), v[m] && (v[m].style.height = `${T}px`), w[m] && (w[m].style.height = `${T}px`));
490
+ T > 0 && (u[m] && (u[m].style.height = `${T}px`), v[m] && (v[m].style.height = `${T}px`), w[m] && (w[m].style.height = `${T}px`));
490
491
  }
491
492
  }
492
493
  }, "#syncRowHeights"));
@@ -501,7 +502,7 @@ const Ie = class Ie {
501
502
  const o = s.querySelector(".ng-part-header"), a = s.querySelector(".ng-part-footer");
502
503
  o && (n += o.offsetHeight), a && (n += a.offsetHeight);
503
504
  const c = Math.max(i - n, 100);
504
- t(this, tt) !== c && (y(this, tt, c), t(this, At).call(this), t(this, M) !== null && (t(this, qt).call(this), this.refresh()));
505
+ t(this, Q) !== c && (y(this, Q, c), t(this, At).call(this), t(this, I) !== null && (t(this, qt).call(this), this.refresh()));
505
506
  }
506
507
  }
507
508
  })), t(this, V).observe(t(this, x)));
@@ -520,34 +521,33 @@ const Ie = class Ie {
520
521
  const i = s.querySelector(".ng-part-body tbody.bindable-tbody");
521
522
  if (!i) return;
522
523
  const n = Array.from(i.querySelectorAll("tr:not(.nodata)")), o = ((l = t(this, D).get(e)) == null ? void 0 : l.length) || 1, c = (t(this, P).data.get() || []).length;
523
- n.forEach((f, u) => {
524
- const b = r + Math.floor(u / o);
524
+ n.forEach((f, g) => {
525
+ const b = r + Math.floor(g / o);
525
526
  if (b >= c) {
526
527
  f.style.visibility = "hidden";
527
528
  return;
528
529
  }
529
- const g = t(this, P).data.get(b);
530
- f.style.display = "", t(this, Rt).call(this, f, g, b);
530
+ const u = t(this, P).data.get(b);
531
+ f.style.display = "", t(this, Rt).call(this, f, u, b);
531
532
  });
532
533
  });
533
534
  }, "#adjustBufferRows"));
534
535
  d(this, lt, /* @__PURE__ */ h((r) => {
535
- var u, b;
536
- R.log("rowManager.#handleScroll()", t(this, M));
537
- const e = t(this, M);
536
+ var g, b;
537
+ const e = t(this, I);
538
538
  if (!e || e <= 0) return;
539
539
  const s = t(this, P).data.length;
540
540
  if (s === 0) return;
541
- const i = ((u = t(this, D).get(".ng-container-body")) == null ? void 0 : u.length) || 1, n = t(this, x).querySelector(".ng-container-body .ng-part-body");
541
+ const i = ((g = t(this, D).get(".ng-container-body")) == null ? void 0 : g.length) || 1, n = t(this, x).querySelector(".ng-container-body .ng-part-body");
542
542
  R.log("bodyContainer.clientHeight", n.clientHeight);
543
543
  const o = Math.max(0, s - Math.floor(n.clientHeight / e)), a = Math.min(o, Math.max(0, Math.floor(r / e)));
544
544
  let c = Math.floor(a * e);
545
545
  R.log(`πŸ“œ [Scroll Calc] maxStartIndex: ${o}, startIndex: ${a}, offsetY: ${c}`), a === o && R.log(`πŸ“œ [Scroll Inspect] scrollTop: ${r}, rowHeight: ${e}, maxStartIndex: ${o}, startIndex: ${a}, offsetY: ${c}`);
546
- const l = t(this, Q).firstTr, f = l && l.dataset.row !== void 0 ? parseInt(l.dataset.row, 10) : -1;
547
- (b = t(this, Q)) == null || b.scrollTables.forEach((g) => {
548
- g.style.transform = `translate3d(0, ${c}px, 0)`;
549
- }), f !== a && (R.log(`πŸ”„ [Row Bind Trigger] currentStartIndex(${f}) !== startIndex(${a})`), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((g) => {
550
- const v = t(this, x).querySelector(g);
546
+ const l = t(this, J).firstTr, f = l && l.dataset.row !== void 0 ? parseInt(l.dataset.row, 10) : -1;
547
+ (b = t(this, J)) == null || b.scrollTables.forEach((u) => {
548
+ u.style.transform = `translate3d(0, ${c}px, 0)`;
549
+ }), f !== a && (R.log(`πŸ”„ [Row Bind Trigger] currentStartIndex(${f}) !== startIndex(${a})`), [".ng-container-body", ".ng-container-left", ".ng-container-right"].forEach((u) => {
550
+ const v = t(this, x).querySelector(u);
551
551
  if (!v) return;
552
552
  const w = v.querySelector(".ng-part-body tbody.bindable-tbody");
553
553
  if (!w) return;
@@ -589,13 +589,13 @@ const Ie = class Ie {
589
589
  const r = t(this, x).querySelector(".ng-container-left .ng-part-header table"), e = t(this, x).querySelector(".ng-container-body .ng-part-header table"), s = t(this, x).querySelector(".ng-container-right .ng-part-header table");
590
590
  if (!e) return;
591
591
  const i = r ? Array.from(r.querySelectorAll("tr")) : [], n = Array.from(e.querySelectorAll("tr")), o = s ? Array.from(s.querySelectorAll("tr")) : [], a = Math.max(i.length, n.length, o.length);
592
- for (let u = 0; u < a; u++) {
592
+ for (let g = 0; g < a; g++) {
593
593
  const b = [
594
- ((c = i[u]) == null ? void 0 : c.getBoundingClientRect().height) || 0,
595
- ((l = n[u]) == null ? void 0 : l.getBoundingClientRect().height) || 0,
596
- ((f = o[u]) == null ? void 0 : f.getBoundingClientRect().height) || 0
597
- ], g = Math.max(...b);
598
- g > 0 && (i[u] && (i[u].style.height = `${g}px`), n[u] && (n[u].style.height = `${g}px`), o[u] && (o[u].style.height = `${g}px`));
594
+ ((c = i[g]) == null ? void 0 : c.getBoundingClientRect().height) || 0,
595
+ ((l = n[g]) == null ? void 0 : l.getBoundingClientRect().height) || 0,
596
+ ((f = o[g]) == null ? void 0 : f.getBoundingClientRect().height) || 0
597
+ ], u = Math.max(...b);
598
+ u > 0 && (i[g] && (i[g].style.height = `${u}px`), n[g] && (n[g].style.height = `${u}px`), o[g] && (o[g].style.height = `${u}px`));
599
599
  }
600
600
  }, "#syncHeaderHeights"));
601
601
  E(this, "destroy", /* @__PURE__ */ h(() => {
@@ -604,14 +604,14 @@ const Ie = class Ie {
604
604
  y(this, P, r.getRootNode().host), y(this, x, r), t(this, Dt).call(this);
605
605
  }
606
606
  getRowHeight() {
607
- return t(this, M);
607
+ return t(this, I);
608
608
  }
609
609
  templateLength(r = ".ng-container-body") {
610
610
  var e;
611
611
  return ((e = t(this, D).get(r)) == null ? void 0 : e.length) || 1;
612
612
  }
613
613
  };
614
- P = new WeakMap(), x = new WeakMap(), Q = new WeakMap(), D = new WeakMap(), M = new WeakMap(), V = new WeakMap(), tt = new WeakMap(), wt = new WeakMap(), Se = new WeakMap(), Ee = new WeakMap(), Ot = new WeakMap(), Bt = new WeakMap(), St = new WeakMap(), Et = new WeakMap(), At = new WeakMap(), zt = new WeakMap(), Dt = new WeakMap(), qt = new WeakMap(), Ae = new WeakMap(), lt = new WeakMap(), Rt = new WeakMap(), Pt = new WeakMap(), h(Ie, "RowManager");
614
+ P = new WeakMap(), x = new WeakMap(), J = new WeakMap(), D = new WeakMap(), I = new WeakMap(), V = new WeakMap(), Q = new WeakMap(), wt = new WeakMap(), Se = new WeakMap(), Ee = new WeakMap(), Ot = new WeakMap(), Bt = new WeakMap(), St = new WeakMap(), Et = new WeakMap(), At = new WeakMap(), zt = new WeakMap(), Dt = new WeakMap(), qt = new WeakMap(), Ae = new WeakMap(), lt = new WeakMap(), Rt = new WeakMap(), Pt = new WeakMap(), h(Ie, "RowManager");
615
615
  let ce = Ie;
616
616
  const jt = class jt {
617
617
  /**
@@ -629,17 +629,17 @@ const jt = class jt {
629
629
  a.querySelectorAll("tbody td, tbody th, tfoot td, tfoot th").forEach((l) => {
630
630
  const f = l.getAttribute("cell-type") || "renderer";
631
631
  if (l.children.length > 0 && l.firstElementChild.tagName.includes("-")) return;
632
- let u = `cell-${f}`;
633
- const b = l.getAttribute("data-bind"), g = l.getAttribute("data-expr"), v = l.getAttribute("maxbyte"), w = l.getAttribute("type");
632
+ let g = `cell-${f}`;
633
+ const b = l.getAttribute("data-bind"), u = l.getAttribute("data-expr"), v = l.getAttribute("maxbyte"), w = l.getAttribute("type");
634
634
  let A = [];
635
- b && A.push(`data-bind="${b}"`), g && A.push(`data-expr="${g}"`), v && A.push(`maxbyte="${v}"`), w && A.push(`type="${w}"`), l.innerHTML = `<${u} ${A.join(" ")}></${u}>`;
635
+ b && A.push(`data-bind="${b}"`), u && A.push(`data-expr="${u}"`), v && A.push(`maxbyte="${v}"`), w && A.push(`type="${w}"`), l.innerHTML = `<${g} ${A.join(" ")}></${g}>`;
636
636
  });
637
637
  }, "processCellTypes"), s = /* @__PURE__ */ h((a) => {
638
638
  if (!a.querySelector("colgroup")) {
639
- const c = a.querySelector("tbody tr") || a.querySelector("tr"), l = c ? c.querySelectorAll("th, td").length : 1, f = document.createElement("colgroup"), u = Math.max(Math.floor(a.clientWidth / l), 100);
639
+ const c = a.querySelector("tbody tr") || a.querySelector("tr"), l = c ? c.querySelectorAll("th, td").length : 1, f = document.createElement("colgroup"), g = Math.max(Math.floor(a.clientWidth / l), 100);
640
640
  for (let b = 0; b < l; b++) {
641
- const g = document.createElement("col");
642
- g.setAttribute("width", u), f.appendChild(g);
641
+ const u = document.createElement("col");
642
+ u.setAttribute("width", g), f.appendChild(u);
643
643
  }
644
644
  a.prepend(f);
645
645
  }
@@ -649,33 +649,33 @@ const jt = class jt {
649
649
  }
650
650
  a.classList.add("nine-table-element");
651
651
  }, "ensureTableStructure"), i = /* @__PURE__ */ h((a, c) => {
652
- const l = Array.from(a.querySelectorAll(c + " tr")), f = Array.from(a.querySelectorAll(c + " th," + c + " td")), u = l.length;
653
- if (u === 0 || f.length === 0) return;
652
+ const l = Array.from(a.querySelectorAll(c + " tr")), f = Array.from(a.querySelectorAll(c + " th," + c + " td")), g = l.length;
653
+ if (g === 0 || f.length === 0) return;
654
654
  let b = 0;
655
655
  f.forEach((v) => {
656
656
  b += v.colSpan || 1;
657
657
  });
658
- const g = Array.from(Array(u), () => Array(b).fill(null));
658
+ const u = Array.from(Array(g), () => Array(b).fill(null));
659
659
  l.forEach((v) => {
660
660
  const w = v.sectionRowIndex;
661
661
  let A = 0;
662
662
  Array.from(v.querySelectorAll("th,td")).forEach((m) => {
663
- for (let O = 0; O < g[w].length; O++)
664
- if (g[w][O] === null) {
663
+ for (let O = 0; O < u[w].length; O++)
664
+ if (u[w][O] === null) {
665
665
  A = O;
666
666
  break;
667
667
  }
668
668
  const W = m.rowSpan || 1, T = m.colSpan || 1;
669
669
  for (let O = 0; O < W; O++)
670
670
  for (let yt = 0; yt < T; yt++)
671
- w + O < u && A + yt < b && (g[w + O][A + yt] = O === 0 && yt === 0 ? "1" : "0");
671
+ w + O < g && A + yt < b && (u[w + O][A + yt] = O === 0 && yt === 0 ? "1" : "0");
672
672
  });
673
673
  }), l.forEach((v) => {
674
674
  const w = v.sectionRowIndex;
675
675
  Array.from(v.querySelectorAll("th,td")).forEach((A) => {
676
- for (let m = 0; m < g[w].length; m++)
677
- if (g[w][m] === "1") {
678
- A.dataset.col = m, g[w][m] = "0";
676
+ for (let m = 0; m < u[w].length; m++)
677
+ if (u[w][m] === "1") {
678
+ A.dataset.col = m, u[w][m] = "0";
679
679
  break;
680
680
  }
681
681
  });
@@ -692,21 +692,21 @@ const jt = class jt {
692
692
  };
693
693
  h(jt, "TableCompiler");
694
694
  let he = jt;
695
- var Ft, et, st, Vt, Yt, ct, Ut, Xt;
695
+ var Ft, tt, et, Vt, Yt, ct, Ut, Xt;
696
696
  const pt = class pt extends HTMLElement {
697
697
  constructor() {
698
698
  super();
699
699
  d(this, Ft);
700
- d(this, et, null);
701
- d(this, st);
700
+ d(this, tt, null);
701
+ d(this, et);
702
702
  E(this, "invalidate", /* @__PURE__ */ h(() => {
703
- R.log("sheet.invalidate()"), t(this, st).refresh();
703
+ R.log("sheet.invalidate()"), t(this, et).refresh();
704
704
  }, "invalidate"));
705
705
  E(this, "generate", /* @__PURE__ */ h((e) => {
706
706
  if (R.log("sheet.generate()"), !e) return;
707
- y(this, et, he.compile(e)), t(this, Vt).call(this), t(this, Yt).call(this);
707
+ y(this, tt, he.compile(e)), t(this, Vt).call(this), t(this, Yt).call(this);
708
708
  const s = this.querySelector(".ng-container-body .ng-part-header"), i = this.querySelector(".ng-container-body .ng-part-footer"), n = this.querySelector(".ng-nodata-overlay");
709
- s && n && (n.style.top = `${s.offsetHeight}px`), i && n && (n.style.bottom = `${i.offsetHeight}px`), t(this, st).initialize(), setTimeout(() => {
709
+ s && n && (n.style.top = `${s.offsetHeight}px`), i && n && (n.style.bottom = `${i.offsetHeight}px`), t(this, et).initialize(), setTimeout(() => {
710
710
  var o;
711
711
  (o = this.querySelector("nine-table-hscrollbar")) == null || o.refresh();
712
712
  }, 0);
@@ -718,7 +718,7 @@ const pt = class pt extends HTMLElement {
718
718
  { selector: ".ng-container-right", type: "right" }
719
719
  ].forEach(({ selector: s, type: i }) => {
720
720
  var n, o, a;
721
- (n = this.querySelector(`${s} .ng-part-header`)) == null || n.appendChild(t(this, ct).call(this, t(this, et), i, "header")), (o = this.querySelector(`${s} .ng-virtual-spacer`)) == null || o.before(t(this, ct).call(this, t(this, et), i, "body")), (a = this.querySelector(`${s} .ng-part-footer`)) == null || a.appendChild(t(this, ct).call(this, t(this, et), i, "footer"));
721
+ (n = this.querySelector(`${s} .ng-part-header`)) == null || n.appendChild(t(this, ct).call(this, t(this, tt), i, "header")), (o = this.querySelector(`${s} .ng-virtual-spacer`)) == null || o.before(t(this, ct).call(this, t(this, tt), i, "body")), (a = this.querySelector(`${s} .ng-part-footer`)) == null || a.appendChild(t(this, ct).call(this, t(this, tt), i, "footer"));
722
722
  });
723
723
  }, "#renderSplitContainers"));
724
724
  d(this, Yt, /* @__PURE__ */ h(() => {
@@ -748,7 +748,7 @@ const pt = class pt extends HTMLElement {
748
748
  l.remove();
749
749
  }), n;
750
750
  }, "#createSplitTable"));
751
- E(this, "getRowHeight", /* @__PURE__ */ h(() => t(this, st).getRowHeight(), "getRowHeight"));
751
+ E(this, "getRowHeight", /* @__PURE__ */ h(() => t(this, et).getRowHeight(), "getRowHeight"));
752
752
  E(this, "scrollToX", /* @__PURE__ */ h((e) => {
753
753
  const s = this.querySelector(".ng-container-body .ng-part-body");
754
754
  s && (s.scrollLeft = e);
@@ -951,7 +951,7 @@ const pt = class pt extends HTMLElement {
951
951
  </div>
952
952
  `;
953
953
  }, "#render"));
954
- y(this, st, new ce(this)), y(this, Ft, this.getRootNode().host);
954
+ y(this, et, new ce(this)), y(this, Ft, this.getRootNode().host);
955
955
  }
956
956
  connectedCallback() {
957
957
  t(this, Ut).call(this);
@@ -960,7 +960,7 @@ const pt = class pt extends HTMLElement {
960
960
  this.innerHTML = "", R.log("NineTableSheet destroyed.");
961
961
  }
962
962
  };
963
- Ft = new WeakMap(), et = new WeakMap(), st = new WeakMap(), Vt = new WeakMap(), Yt = new WeakMap(), ct = new WeakMap(), Ut = new WeakMap(), Xt = new WeakMap(), h(pt, "NineTableSheet"), E(pt, "SCROLLBAR_SIZE", 16);
963
+ Ft = new WeakMap(), tt = new WeakMap(), et = new WeakMap(), Vt = new WeakMap(), Yt = new WeakMap(), ct = new WeakMap(), Ut = new WeakMap(), Xt = new WeakMap(), h(pt, "NineTableSheet"), E(pt, "SCROLLBAR_SIZE", 16);
964
964
  let It = pt;
965
965
  customElements.get("nine-table-sheet") || customElements.define("nine-table-sheet", It);
966
966
  var Kt, Tt;
@@ -978,24 +978,24 @@ const _e = class _e extends HTMLElement {
978
978
  d(this, Tt, /* @__PURE__ */ h((e, s = !1) => {
979
979
  const i = /* @__PURE__ */ h(() => {
980
980
  const f = Array.from(this.querySelectorAll("nine-table-sheet"));
981
- Array.from(this.querySelectorAll("nine-splitter")).forEach((g) => g.style.setProperty("display", "none"));
982
- const b = f.filter((g) => g.classList.contains("active"));
983
- b.length < 2 || b.forEach((g) => {
984
- const v = parseInt(g.getAttribute("data-index"), 10), w = this.querySelector(`nine-splitter[data-split-index="${v}"]`), A = f[v + 1];
981
+ Array.from(this.querySelectorAll("nine-splitter")).forEach((u) => u.style.setProperty("display", "none"));
982
+ const b = f.filter((u) => u.classList.contains("active"));
983
+ b.length < 2 || b.forEach((u) => {
984
+ const v = parseInt(u.getAttribute("data-index"), 10), w = this.querySelector(`nine-splitter[data-split-index="${v}"]`), A = f[v + 1];
985
985
  w && A && A.classList.contains("active") && w.style.setProperty("display", "flex");
986
986
  });
987
987
  }, "updateSplitters"), n = this.querySelector(".nine-tab-bar"), o = this.querySelector("nine-table-sheets-body"), a = n.querySelectorAll(".nine-tab-item"), c = o.querySelectorAll("nine-table-sheet");
988
988
  if (!a[e]) return;
989
989
  if (!s)
990
- a.forEach((f, u) => {
991
- f.classList.toggle("active", u === e);
992
- }), c.forEach((f, u) => {
993
- const b = u === e;
990
+ a.forEach((f, g) => {
991
+ f.classList.toggle("active", g === e);
992
+ }), c.forEach((f, g) => {
993
+ const b = g === e;
994
994
  f.classList.toggle("active", b), f.style.flex = b ? "1 1 100%" : "";
995
995
  });
996
996
  else {
997
- const f = a[e], u = n.querySelectorAll(".nine-tab-item.active");
998
- if (f.classList.contains("active") && u.length <= 1)
997
+ const f = a[e], g = n.querySelectorAll(".nine-tab-item.active");
998
+ if (f.classList.contains("active") && g.length <= 1)
999
999
  return;
1000
1000
  f.classList.toggle("active");
1001
1001
  const b = o.querySelector(`nine-table-sheet[data-index="${e}"]`);
@@ -1014,29 +1014,29 @@ const _e = class _e extends HTMLElement {
1014
1014
  Kt = new WeakMap(), Tt = new WeakMap(), h(_e, "NineTableSheets");
1015
1015
  let de = _e;
1016
1016
  customElements.get("nine-table-sheets") || customElements.define("nine-table-sheets", de);
1017
- var I, Zt, kt, Gt;
1017
+ var M, Zt, kt, Gt;
1018
1018
  const Ne = class Ne {
1019
1019
  constructor(r) {
1020
- d(this, I);
1020
+ d(this, M);
1021
1021
  d(this, Zt, /* @__PURE__ */ h(() => {
1022
1022
  t(this, Gt).call(this), new ResizeObserver((r) => {
1023
1023
  for (let e of r)
1024
- t(this, I).getAttribute("auto-height") === "true" && t(this, kt).call(this);
1025
- }).observe(t(this, I));
1024
+ t(this, M).getAttribute("auto-height") === "true" && t(this, kt).call(this);
1025
+ }).observe(t(this, M));
1026
1026
  }, "#init"));
1027
1027
  d(this, kt, /* @__PURE__ */ h(() => {
1028
1028
  var c, l;
1029
- const r = Array.from(t(this, I).shadowRoot.querySelectorAll("nine-table-sheet.active"));
1029
+ const r = Array.from(t(this, M).shadowRoot.querySelectorAll("nine-table-sheet.active"));
1030
1030
  if (r.length === 0) return;
1031
- 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, o = It.SCROLLBAR_SIZE, a = e * s + i + n + o;
1032
- t(this, I).style.height = `${a}px`;
1031
+ const e = parseInt(t(this, M).getAttribute("max-display-row"), 10) || 10, s = Math.max(...r.map((f) => f.getRowHeight())), i = (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, o = It.SCROLLBAR_SIZE, a = e * s + i + n + o;
1032
+ t(this, M).style.height = `${a}px`;
1033
1033
  }, "#applyAutoHeight"));
1034
1034
  d(this, Gt, /* @__PURE__ */ h(() => {
1035
- 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) => {
1036
- const u = `<nine-table-sheet class="${l === 0 ? "active" : ""}" data-index="${l}"></nine-table-sheet>`, b = l < i - 1 ? `<nine-splitter class="h" data-split-index="${l}"></nine-splitter>` : "";
1037
- return u + b;
1035
+ const e = Array.from(t(this, M).children).filter((c) => c.tagName === "TABLE"), s = t(this, M).getAttribute("auto-height") === "true", i = e.length, n = e.map((c, l) => {
1036
+ const g = `<nine-table-sheet class="${l === 0 ? "active" : ""}" data-index="${l}"></nine-table-sheet>`, b = l < i - 1 ? `<nine-splitter class="h" data-split-index="${l}"></nine-splitter>` : "";
1037
+ return g + b;
1038
1038
  }).join(""), o = e.map((c, l) => `<div class="nine-tab-item ${l === 0 ? "active" : ""}" data-index="${l}">Sheet ${l + 1}</div>`).join("");
1039
- t(this, I).shadowRoot.innerHTML = `
1039
+ t(this, M).shadowRoot.innerHTML = `
1040
1040
  <style>
1041
1041
  :host {
1042
1042
  display: flex;
@@ -1156,18 +1156,18 @@ const Ne = class Ne {
1156
1156
  <nine-table-analysis></nine-table-analysis>
1157
1157
  </nine-table-body>
1158
1158
  <nine-table-footer></nine-table-footer>
1159
- `, t(this, I).shadowRoot.querySelector("nine-table-sheets").classList.add("nodata");
1160
- const a = t(this, I).shadowRoot.querySelectorAll("nine-table-sheet");
1159
+ `, t(this, M).shadowRoot.querySelector("nine-table-sheets").classList.add("nodata");
1160
+ const a = t(this, M).shadowRoot.querySelectorAll("nine-table-sheet");
1161
1161
  a == null || a.forEach((c, l) => {
1162
1162
  e[l] && setTimeout(() => {
1163
1163
  c.generate(e[l]), s && t(this, kt).call(this);
1164
1164
  });
1165
1165
  });
1166
1166
  }, "#render"));
1167
- y(this, I, r), t(this, Zt).call(this);
1167
+ y(this, M, r), t(this, Zt).call(this);
1168
1168
  }
1169
1169
  };
1170
- I = new WeakMap(), Zt = new WeakMap(), kt = new WeakMap(), Gt = new WeakMap(), h(Ne, "LayoutManager");
1170
+ M = new WeakMap(), Zt = new WeakMap(), kt = new WeakMap(), Gt = new WeakMap(), h(Ne, "LayoutManager");
1171
1171
  let fe = Ne;
1172
1172
  var Ct, ht;
1173
1173
  const We = class We {
@@ -1187,7 +1187,7 @@ const We = class We {
1187
1187
  };
1188
1188
  Ct = new WeakMap(), ht = new WeakMap(), h(We, "ngRow");
1189
1189
  let ge = We;
1190
- var _, C, N, dt, Jt, Y, Qt, rt, Lt, te, ee, ft;
1190
+ var _, C, N, dt, Jt, Y, Qt, st, Lt, te, ee, ft;
1191
1191
  const B = class B {
1192
1192
  constructor(r, e) {
1193
1193
  d(this, _);
@@ -1206,7 +1206,7 @@ const B = class B {
1206
1206
  e.__ng || (e.__ng = t(this, Lt).call(this)), e.__ng.height = t(this, Y).slice();
1207
1207
  });
1208
1208
  }, "#initialize"));
1209
- d(this, rt, /* @__PURE__ */ h(() => {
1209
+ d(this, st, /* @__PURE__ */ h(() => {
1210
1210
  const r = t(this, _).shadowRoot.querySelector("nine-table-sheets");
1211
1211
  r == null || r.classList.toggle("nodata", this.length === 0), t(this, _).shadowRoot.querySelectorAll("nine-table-sheet").forEach((e) => {
1212
1212
  e.invalidate();
@@ -1226,7 +1226,7 @@ const B = class B {
1226
1226
  return t(this, ft).call(this, s[r]);
1227
1227
  }, "get"));
1228
1228
  E(this, "set", /* @__PURE__ */ h((r) => {
1229
- this.clear(), this.add(r, !1), t(this, rt).call(this);
1229
+ this.clear(), this.add(r, !1), t(this, st).call(this);
1230
1230
  }, "set"));
1231
1231
  d(this, Lt, /* @__PURE__ */ h(() => ({
1232
1232
  rowState: B.ROW_STATE.EMPTY,
@@ -1238,7 +1238,7 @@ const B = class B {
1238
1238
  _: [0, 0, 0, 0, B.ROW_STATE.EMPTY, !1, !1, !0, !1, !0, !0, !1, t(this, Y).slice(), -1, {}, {}]
1239
1239
  }), "#getDefaultMeta"));
1240
1240
  E(this, "reset", /* @__PURE__ */ h(() => {
1241
- y(this, N, []), y(this, dt, []), t(this, rt).call(this);
1241
+ y(this, N, []), y(this, dt, []), t(this, st).call(this);
1242
1242
  }, "reset"));
1243
1243
  E(this, "clear", /* @__PURE__ */ h(() => {
1244
1244
  var r;
@@ -1266,7 +1266,7 @@ const B = class B {
1266
1266
  return e || s.forEach((n, o) => {
1267
1267
  const a = t(this, C).rawRecords[i - o];
1268
1268
  a && (a.__ng.rowState = B.ROW_STATE.EMPTY);
1269
- }), t(this, rt).call(this), i;
1269
+ }), t(this, st).call(this), i;
1270
1270
  }, "add"));
1271
1271
  E(this, "delete", /* @__PURE__ */ h((r) => {
1272
1272
  let e = [];
@@ -1277,7 +1277,7 @@ const B = class B {
1277
1277
  n.__ng.rowid === i && (n.__ng.deleted = !0, n.__ng.rowState = B.ROW_STATE.DELETE);
1278
1278
  });
1279
1279
  }
1280
- }), this.resetRecords(), t(this, rt).call(this);
1280
+ }), this.resetRecords(), t(this, st).call(this);
1281
1281
  }, "delete"));
1282
1282
  E(this, "setValue", /* @__PURE__ */ h((r, e, s) => {
1283
1283
  var c;
@@ -1330,7 +1330,7 @@ const B = class B {
1330
1330
  return this.length;
1331
1331
  }
1332
1332
  };
1333
- _ = new WeakMap(), C = new WeakMap(), N = new WeakMap(), dt = new WeakMap(), Jt = new WeakMap(), Y = new WeakMap(), Qt = new WeakMap(), rt = new WeakMap(), Lt = new WeakMap(), te = new WeakMap(), ee = new WeakMap(), ft = new WeakMap(), h(B, "ngData"), // 🎯 ν–‰ μƒνƒœ μ •μ˜ μƒμˆ˜λ₯Ό 클래슀 λ‚΄λΆ€λ‘œ λ‚΄μž¬ν™”
1333
+ _ = new WeakMap(), C = new WeakMap(), N = new WeakMap(), dt = new WeakMap(), Jt = new WeakMap(), Y = new WeakMap(), Qt = new WeakMap(), st = new WeakMap(), Lt = new WeakMap(), te = new WeakMap(), ee = new WeakMap(), ft = new WeakMap(), h(B, "ngData"), // 🎯 ν–‰ μƒνƒœ μ •μ˜ μƒμˆ˜λ₯Ό 클래슀 λ‚΄λΆ€λ‘œ λ‚΄μž¬ν™”
1334
1334
  E(B, "ROW_STATE", {
1335
1335
  EMPTY: "EMPTY",
1336
1336
  NORMAL: "NORMAL",
@@ -1339,13 +1339,13 @@ E(B, "ROW_STATE", {
1339
1339
  DELETE: "DELETE"
1340
1340
  });
1341
1341
  let ue = B;
1342
- var it;
1342
+ var rt;
1343
1343
  const Oe = class Oe {
1344
1344
  constructor(r) {
1345
- d(this, it);
1346
- y(this, it, r), this.row = new ge(this), this.data = new ue(t(this, it), this), this.rawRecords = [], this.viewRecords = [], this.delRecords = [], this.pageCnt = 25, this.viewRecords.reset = () => {
1345
+ d(this, rt);
1346
+ y(this, rt, r), this.row = new ge(this), this.data = new ue(t(this, rt), this), this.rawRecords = [], this.viewRecords = [], this.delRecords = [], this.pageCnt = 25, this.viewRecords.reset = () => {
1347
1347
  var e;
1348
- (e = t(this, it).view) != null && e.redraw && t(this, it).view.redraw();
1348
+ (e = t(this, rt).view) != null && e.redraw && t(this, rt).view.redraw();
1349
1349
  }, this.setDataSource = (e) => {
1350
1350
  this.data && this.data.reset(), this.rawRecords = [], this.viewRecords = [], this.delRecords = [], this.data.set(e || []);
1351
1351
  }, this.getRowState = (e) => {
@@ -1360,7 +1360,7 @@ const Oe = class Oe {
1360
1360
  }, this.setDataSource([]);
1361
1361
  }
1362
1362
  };
1363
- it = new WeakMap(), h(Oe, "ngDataManager");
1363
+ rt = new WeakMap(), h(Oe, "ngDataManager");
1364
1364
  let be = Oe;
1365
1365
  var gt, H, Ht, se;
1366
1366
  const Be = class Be {
@@ -1435,17 +1435,17 @@ const Be = class Be {
1435
1435
  };
1436
1436
  gt = new WeakMap(), H = new WeakMap(), Ht = new WeakMap(), se = new WeakMap(), h(Be, "ngFields");
1437
1437
  let ye = Be;
1438
- var nt, re, ie;
1438
+ var it, re, ie;
1439
1439
  const ze = class ze extends HTMLElement {
1440
1440
  constructor() {
1441
1441
  super();
1442
1442
  //#created = false;
1443
- d(this, nt);
1443
+ d(this, it);
1444
1444
  d(this, re);
1445
1445
  d(this, ie, /* @__PURE__ */ h(() => {
1446
1446
  this.fields = new ye(this), y(this, re, new fe(this)), R.log("NineTable connected."), this.dispatchEvent(new CustomEvent("load", { bubbles: !0, detail: { target: this } }));
1447
1447
  }, "#init"));
1448
- this.attachShadow({ mode: "open" }), y(this, nt, new be(this));
1448
+ this.attachShadow({ mode: "open" }), y(this, it, new be(this));
1449
1449
  }
1450
1450
  connectedCallback() {
1451
1451
  t(this, ie).call(this);
@@ -1455,18 +1455,18 @@ const ze = class ze extends HTMLElement {
1455
1455
  }
1456
1456
  // 🎯 μ™ΈλΆ€μ—μ„œ grid.data.set(...) ν˜•νƒœλ‘œ μ ‘κ·Όν•  수 μžˆλ„λ‘ 데이터 λ§€λ‹ˆμ € μ˜€ν”ˆ
1457
1457
  get data() {
1458
- return t(this, nt).data;
1458
+ return t(this, it).data;
1459
1459
  }
1460
1460
  // 🎯 ν–‰(row) κ΄€λ ¨ μ œμ–΄ μ ‘κ·Όμž μ˜€ν”ˆ
1461
1461
  get row() {
1462
- return t(this, nt).row;
1462
+ return t(this, it).row;
1463
1463
  }
1464
1464
  // 🎯 전체 데이터 λ§€λ‹ˆμ € μ ‘κ·Ό ν•„μš”ν•  경우
1465
1465
  get dataManager() {
1466
- return t(this, nt);
1466
+ return t(this, it);
1467
1467
  }
1468
1468
  };
1469
- nt = new WeakMap(), re = new WeakMap(), ie = new WeakMap(), h(ze, "NineTable");
1469
+ it = new WeakMap(), re = new WeakMap(), ie = new WeakMap(), h(ze, "NineTable");
1470
1470
  let pe = ze;
1471
1471
  customElements.get("nine-table") || customElements.define("nine-table", pe);
1472
1472
  const mt = class mt extends HTMLElement {
@@ -1528,8 +1528,8 @@ const De = class De extends me {
1528
1528
  if (o > e) break;
1529
1529
  var a = parseInt(t(this, p).dataset.row), c = a - 1, l = t(this, p).closest("tr").data, f = t(this, L).data.get(c);
1530
1530
  t(this, p).dataset.matrixRow;
1531
- var u = t(this, L).body.querySelector(`tbody.bindable [suppress="${o}"][data-matrix-row="${t(this, p).dataset.matrixRow}"]`), b = u.dataset.expr ? this.getExprValue(u.dataset.expr, l, a) : l[u.dataset.bind], g = u.dataset.expr ? this.getExprValue(u.dataset.expr, f, c) : f[u.dataset.bind];
1532
- if (b != g) {
1531
+ var g = t(this, L).body.querySelector(`tbody.bindable [suppress="${o}"][data-matrix-row="${t(this, p).dataset.matrixRow}"]`), b = g.dataset.expr ? this.getExprValue(g.dataset.expr, l, a) : l[g.dataset.bind], u = g.dataset.expr ? this.getExprValue(g.dataset.expr, f, c) : f[g.dataset.bind];
1532
+ if (b != u) {
1533
1533
  n = !0;
1534
1534
  break;
1535
1535
  }
@@ -1593,12 +1593,12 @@ const Pe = class Pe extends ve {
1593
1593
  };
1594
1594
  h(Pe, "EditableCellElement");
1595
1595
  let xe = Pe;
1596
- var Mt, ot, ut, bt, ne, U, Le;
1596
+ var Mt, nt, ut, bt, ne, U, Le;
1597
1597
  const je = class je extends xe {
1598
1598
  constructor() {
1599
1599
  super();
1600
1600
  d(this, Mt);
1601
- d(this, ot);
1601
+ d(this, nt);
1602
1602
  d(this, ut);
1603
1603
  d(this, bt);
1604
1604
  d(this, ne);
@@ -1639,7 +1639,7 @@ const je = class je extends xe {
1639
1639
  */
1640
1640
  d(this, Le, /* @__PURE__ */ h((e) => {
1641
1641
  if (!["Escape", "Enter", "Tab", "Home", "End", "ArrowLeft", "ArrowRight", "PageUp", "PageDown", "Backspace", "Delete"].includes(e.code)) {
1642
- if (t(this, ot) == "number") {
1642
+ if (t(this, nt) == "number") {
1643
1643
  let n = [];
1644
1644
  if (t(this, U) && Number(t(this, U)) > 0 && n.push("."), t(this, bt) && Number(t(this, bt)) >= 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) {
1645
1645
  var s = e.target.value, i = s.indexOf(".");
@@ -1652,7 +1652,7 @@ const je = class je extends xe {
1652
1652
  t(this, ut) && ninegrid.getByteLength(e.target.value) >= Number(t(this, ut)) && e.target.selectionStart == e.target.selectionEnd && e.preventDefault();
1653
1653
  }
1654
1654
  }, "#onKeyDown"));
1655
- if (this.applyBaseStyle(), y(this, ot, this.getAttribute("type") || "text"), y(this, ut, this.getAttribute("maxbyte")), y(this, bt, this.getAttribute("min")), y(this, ne, this.getAttribute("max")), y(this, U, this.getAttribute("scale")), !["text", "number"].includes(t(this, ot))) throw `invalid type : ${t(this, ot)}`;
1655
+ if (this.applyBaseStyle(), y(this, nt, this.getAttribute("type") || "text"), y(this, ut, this.getAttribute("maxbyte")), y(this, bt, this.getAttribute("min")), y(this, ne, this.getAttribute("max")), y(this, U, this.getAttribute("scale")), !["text", "number"].includes(t(this, nt))) throw `invalid type : ${t(this, nt)}`;
1656
1656
  }
1657
1657
  connectedCallback() {
1658
1658
  for (var e = [], s = 0; s < this.attributes.length; s++)
@@ -1665,7 +1665,7 @@ const je = class je extends xe {
1665
1665
  `, super.connectedCallback(), y(this, Mt, this.querySelector("input"));
1666
1666
  }
1667
1667
  };
1668
- Mt = new WeakMap(), ot = new WeakMap(), ut = new WeakMap(), bt = new WeakMap(), ne = new WeakMap(), U = new WeakMap(), Le = new WeakMap(), h(je, "CellInputText");
1668
+ Mt = new WeakMap(), nt = new WeakMap(), ut = new WeakMap(), bt = new WeakMap(), ne = new WeakMap(), U = new WeakMap(), Le = new WeakMap(), h(je, "CellInputText");
1669
1669
  let we = je;
1670
1670
  customElements.get("cell-input-text");
1671
1671
  customElements.get("cell-input") || customElements.define("cell-input", we);