open-grid 1.0.7 → 1.0.8

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.
@@ -1,4 +1,4 @@
1
- class oe {
1
+ class re {
2
2
  constructor() {
3
3
  this.listeners = /* @__PURE__ */ new Map();
4
4
  }
@@ -15,18 +15,18 @@ class oe {
15
15
  return this.listeners.delete(t), this;
16
16
  const s = this.listeners.get(t);
17
17
  if (s) {
18
- const i = s.filter((o) => o.handler !== e);
19
- i.length === 0 ? this.listeners.delete(t) : this.listeners.set(t, i);
18
+ const o = s.filter((i) => i.handler !== e);
19
+ o.length === 0 ? this.listeners.delete(t) : this.listeners.set(t, o);
20
20
  }
21
21
  return this;
22
22
  }
23
23
  emit(t, ...e) {
24
24
  const s = this.listeners.get(t);
25
25
  if (!s || s.length === 0) return !1;
26
- const i = [];
27
- for (const o of s)
28
- o.handler(...e), o.once || i.push(o);
29
- return i.length !== s.length && (i.length === 0 ? this.listeners.delete(t) : this.listeners.set(t, i)), !0;
26
+ const o = [];
27
+ for (const i of s)
28
+ i.handler(...e), i.once || o.push(i);
29
+ return o.length !== s.length && (o.length === 0 ? this.listeners.delete(t) : this.listeners.set(t, o)), !0;
30
30
  }
31
31
  removeAllListeners(t) {
32
32
  return t ? this.listeners.delete(t) : this.listeners.clear(), this;
@@ -36,11 +36,11 @@ class oe {
36
36
  return ((e = this.listeners.get(t)) == null ? void 0 : e.length) ?? 0;
37
37
  }
38
38
  }
39
- let ne = 0;
40
- function St() {
41
- return `og-r-${++ne}`;
39
+ let le = 0;
40
+ function Tt() {
41
+ return `og-r-${++le}`;
42
42
  }
43
- class re {
43
+ class ae {
44
44
  constructor(t = "_ogRowId") {
45
45
  this._data = [], this._original = [], this._meta = /* @__PURE__ */ new Map(), this._displayIndexes = [], this._idMap = /* @__PURE__ */ new Map(), this._findQuery = "", this._findFields = [], this._getStrategy = (e, s) => s, this._idField = t;
46
46
  }
@@ -51,8 +51,8 @@ class re {
51
51
  // ─── 데이터 설정 ──────────────────────────────────────
52
52
  setData(t) {
53
53
  this._data = t.map((e) => {
54
- const s = St(), i = { ...e, [this._idField]: s };
55
- return this._meta.set(s, { state: "none", rowId: s }), i;
54
+ const s = Tt(), o = { ...e, [this._idField]: s };
55
+ return this._meta.set(s, { state: "none", rowId: s }), o;
56
56
  }), this._original = this._data.map((e) => ({ ...e })), this._rebuildIdMap(), this._displayIndexes = this._data.map((e, s) => s);
57
57
  }
58
58
  getData() {
@@ -75,44 +75,44 @@ class re {
75
75
  }
76
76
  // ─── 행 CRUD ──────────────────────────────────────────
77
77
  addRow(t, e = "last") {
78
- const s = St(), i = { ...t, [this._idField]: s };
78
+ const s = Tt(), o = { ...t, [this._idField]: s };
79
79
  if (this._meta.set(s, { state: "added", rowId: s }), e === "last") {
80
- const o = this._data.push(i) - 1;
81
- this._idMap.set(s, o), this._displayIndexes.push(o);
80
+ const i = this._data.push(o) - 1;
81
+ this._idMap.set(s, i), this._displayIndexes.push(i);
82
82
  } else if (e === "first")
83
- this._data.unshift(i), this._rebuildIdMap(), this._displayIndexes.unshift(0);
83
+ this._data.unshift(o), this._rebuildIdMap(), this._displayIndexes.unshift(0);
84
84
  else {
85
- const o = Math.min(e, this._displayIndexes.length), n = o < this._displayIndexes.length ? this._displayIndexes[o] : this._data.length;
86
- this._data.splice(n, 0, i), this._rebuildIdMap(), this._displayIndexes = this._data.map((r, l) => l);
85
+ const i = Math.min(e, this._displayIndexes.length), n = i < this._displayIndexes.length ? this._displayIndexes[i] : this._data.length;
86
+ this._data.splice(n, 0, o), this._rebuildIdMap(), this._displayIndexes = this._data.map((r, l) => l);
87
87
  }
88
88
  }
89
89
  removeRow(t) {
90
90
  const e = this._displayIndexes[t];
91
91
  if (e === void 0) return;
92
- const s = this._data[e], i = s[this._idField], o = this._meta.get(i);
93
- return (o == null ? void 0 : o.state) === "added" ? (this._data.splice(e, 1), this._meta.delete(i)) : this._meta.set(i, { ...o, state: "removed" }), this._rebuildIdMap(), this._displayIndexes = this._data.map((n, r) => ({ r: n, i: r })).filter(({ r: n }) => {
92
+ const s = this._data[e], o = s[this._idField], i = this._meta.get(o);
93
+ return (i == null ? void 0 : i.state) === "added" ? (this._data.splice(e, 1), this._meta.delete(o)) : this._meta.set(o, { ...i, state: "removed" }), this._rebuildIdMap(), this._displayIndexes = this._data.map((n, r) => ({ r: n, i: r })).filter(({ r: n }) => {
94
94
  var r;
95
95
  return ((r = this._meta.get(n[this._idField])) == null ? void 0 : r.state) !== "removed";
96
96
  }).map(({ i: n }) => n), s;
97
97
  }
98
98
  moveRow(t, e) {
99
- const s = this._displayIndexes[t], i = this._displayIndexes[e];
100
- if (s === void 0 || i === void 0) return;
101
- const [o] = this._data.splice(s, 1), n = s < i ? i - 1 : i;
102
- this._data.splice(n, 0, o), this._rebuildIdMap(), this._displayIndexes = this._data.map((r, l) => ({ r, i: l })).filter(({ r }) => {
99
+ const s = this._displayIndexes[t], o = this._displayIndexes[e];
100
+ if (s === void 0 || o === void 0) return;
101
+ const [i] = this._data.splice(s, 1), n = s < o ? o - 1 : o;
102
+ this._data.splice(n, 0, i), this._rebuildIdMap(), this._displayIndexes = this._data.map((r, l) => ({ r, i: l })).filter(({ r }) => {
103
103
  var l;
104
104
  return ((l = this._meta.get(r[this._idField])) == null ? void 0 : l.state) !== "removed";
105
105
  }).map(({ i: r }) => r);
106
106
  }
107
107
  updateCell(t, e, s) {
108
- const i = this._displayIndexes[t];
109
- if (i === void 0) return !1;
110
- const n = this._data[i][this._idField], r = this._meta.get(n);
108
+ const o = this._displayIndexes[t];
109
+ if (o === void 0) return !1;
110
+ const n = this._data[o][this._idField], r = this._meta.get(n);
111
111
  return (r == null ? void 0 : r.state) === "none" && this._meta.set(n, {
112
112
  ...r,
113
113
  state: "edited",
114
- original: { ...this._original[i] }
115
- }), this._data[i][e] = s, !0;
114
+ original: { ...this._original[o] }
115
+ }), this._data[o][e] = s, !0;
116
116
  }
117
117
  getRowByIndex(t) {
118
118
  const e = this._displayIndexes[t];
@@ -158,17 +158,17 @@ class re {
158
158
  */
159
159
  getChanges() {
160
160
  const t = [], e = [], s = [];
161
- for (const i of this._data) {
162
- const o = i[this._idField], n = this._meta.get(o), r = (n == null ? void 0 : n.state) ?? "none";
161
+ for (const o of this._data) {
162
+ const i = o[this._idField], n = this._meta.get(i), r = (n == null ? void 0 : n.state) ?? "none";
163
163
  if (r === "added")
164
- t.push({ ...i });
164
+ t.push({ ...o });
165
165
  else if (r === "removed")
166
- s.push({ ...i });
166
+ s.push({ ...o });
167
167
  else if (r === "edited") {
168
- const l = n.original ?? {}, a = Object.keys(i).filter(
169
- (c) => c !== this._idField && i[c] !== l[c]
168
+ const l = n.original ?? {}, a = Object.keys(o).filter(
169
+ (c) => c !== this._idField && o[c] !== l[c]
170
170
  );
171
- e.push({ ...i, _changedFields: a });
171
+ e.push({ ...o, _changedFields: a });
172
172
  }
173
173
  }
174
174
  return { added: t, edited: e, removed: s };
@@ -182,25 +182,25 @@ class re {
182
182
  var e;
183
183
  return ((e = this._meta.get(t[this._idField])) == null ? void 0 : e.state) === "edited";
184
184
  }).map((t) => {
185
- var i;
186
- const e = ((i = this._meta.get(t[this._idField])) == null ? void 0 : i.original) ?? {}, s = [];
187
- for (const o of Object.keys(t))
188
- o !== this._idField && t[o] !== e[o] && s.push({ field: o, oldValue: e[o], newValue: t[o] });
189
- return { row: { ...t }, fields: s.map((o) => o.field), diff: s };
185
+ var o;
186
+ const e = ((o = this._meta.get(t[this._idField])) == null ? void 0 : o.original) ?? {}, s = [];
187
+ for (const i of Object.keys(t))
188
+ i !== this._idField && t[i] !== e[i] && s.push({ field: i, oldValue: e[i], newValue: t[i] });
189
+ return { row: { ...t }, fields: s.map((i) => i.field), diff: s };
190
190
  });
191
191
  }
192
192
  /** rowIndex 행의 원본(수정 전) 데이터 반환. 추가된 행은 undefined. */
193
193
  getOriginalRow(t) {
194
194
  const e = this._displayIndexes[t];
195
195
  if (e === void 0) return;
196
- const s = this._data[e], i = this._meta.get(s[this._idField]);
197
- if (!(!i || i.state === "added"))
198
- return i.state === "edited" && i.original ? { ...i.original } : { ...this._original[e] };
196
+ const s = this._data[e], o = this._meta.get(s[this._idField]);
197
+ if (!(!o || o.state === "added"))
198
+ return o.state === "edited" && o.original ? { ...o.original } : { ...this._original[e] };
199
199
  }
200
200
  getRowsWithState(t) {
201
201
  return this._data.map((e) => {
202
- var i;
203
- const s = ((i = this._meta.get(e[this._idField])) == null ? void 0 : i.state) ?? "none";
202
+ var o;
203
+ const s = ((o = this._meta.get(e[this._idField])) == null ? void 0 : o.state) ?? "none";
204
204
  return { ...e, [t]: s };
205
205
  });
206
206
  }
@@ -211,61 +211,61 @@ class re {
211
211
  }
212
212
  // ─── 정렬 ─────────────────────────────────────────────
213
213
  applySort(t) {
214
- const e = (o) => {
214
+ const e = (i) => {
215
215
  var n, r;
216
- return ((r = this._meta.get((n = this._data[o]) == null ? void 0 : n[this._idField])) == null ? void 0 : r.state) !== "removed";
216
+ return ((r = this._meta.get((n = this._data[i]) == null ? void 0 : n[this._idField])) == null ? void 0 : r.state) !== "removed";
217
217
  };
218
218
  if (t.length === 0) {
219
- this._displayIndexes = this._data.map((o, n) => n).filter(e);
219
+ this._displayIndexes = this._data.map((i, n) => n).filter(e);
220
220
  return;
221
221
  }
222
- const s = this._displayIndexes.filter(e).map((o) => {
223
- const n = this._data[o];
222
+ const s = this._displayIndexes.filter(e).map((i) => {
223
+ const n = this._data[i];
224
224
  return {
225
- idx: o,
225
+ idx: i,
226
226
  keys: t.map((r) => n[r.field])
227
227
  };
228
- }), i = this._getStrategy(
228
+ }), o = this._getStrategy(
229
229
  "sortComparator",
230
- (o, n, r, l) => {
231
- if (o == null && n == null) return 0;
232
- if (o == null) return -1;
230
+ (i, n, r, l) => {
231
+ if (i == null && n == null) return 0;
232
+ if (i == null) return -1;
233
233
  if (n == null) return 1;
234
- if (typeof o == "number" && typeof n == "number") return o - n;
235
- const a = String(o), c = String(n);
234
+ if (typeof i == "number" && typeof n == "number") return i - n;
235
+ const a = String(i), c = String(n);
236
236
  return a < c ? -1 : a > c ? 1 : 0;
237
237
  }
238
238
  );
239
- s.sort((o, n) => {
239
+ s.sort((i, n) => {
240
240
  for (let r = 0; r < t.length; r++) {
241
- const l = t[r].dir, a = t[r].field, c = o.keys[r], u = n.keys[r], h = i(c, u, a, l);
241
+ const l = t[r].dir, a = t[r].field, c = i.keys[r], u = n.keys[r], h = o(c, u, a, l);
242
242
  if (h !== 0) return l === "asc" ? h : -h;
243
243
  }
244
244
  return 0;
245
- }), this._displayIndexes = s.map((o) => o.idx);
245
+ }), this._displayIndexes = s.map((i) => i.idx);
246
246
  }
247
247
  // ─── 필터 ─────────────────────────────────────────────
248
248
  applyFilter(t) {
249
249
  const e = Object.keys(t), s = this._getStrategy(
250
250
  "filterPredicate",
251
- (i, o, n) => le(i, o)
251
+ (o, i, n) => de(o, i)
252
252
  );
253
- this._displayIndexes = this._data.map((i, o) => ({ r: i, i: o })).filter(({ r: i }) => {
254
- var o;
255
- if (((o = this._meta.get(i[this._idField])) == null ? void 0 : o.state) === "removed" || e.length > 0 && !e.every((n) => {
256
- const r = i[n];
253
+ this._displayIndexes = this._data.map((o, i) => ({ r: o, i })).filter(({ r: o }) => {
254
+ var i;
255
+ if (((i = this._meta.get(o[this._idField])) == null ? void 0 : i.state) === "removed" || e.length > 0 && !e.every((n) => {
256
+ const r = o[n];
257
257
  return t[n].every((l) => s(r, l, n));
258
258
  }))
259
259
  return !1;
260
260
  if (this._findQuery && this._findFields.length > 0) {
261
261
  const n = this._findQuery;
262
262
  if (!this._findFields.some((l) => {
263
- const a = i[l];
263
+ const a = o[l];
264
264
  return a != null && String(a).toLowerCase().includes(n);
265
265
  })) return !1;
266
266
  }
267
267
  return !0;
268
- }).map(({ i }) => i);
268
+ }).map(({ i: o }) => o);
269
269
  }
270
270
  /** F3: 찾기 바 전체 컬럼 OR 검색 설정 */
271
271
  setFindFilter(t, e) {
@@ -278,7 +278,7 @@ class re {
278
278
  });
279
279
  }
280
280
  }
281
- function le(d, t) {
281
+ function de(d, t) {
282
282
  const e = d, s = t.value;
283
283
  switch (t.operator) {
284
284
  case "=":
@@ -303,7 +303,7 @@ function le(d, t) {
303
303
  return !0;
304
304
  }
305
305
  }
306
- class ae {
306
+ class ce {
307
307
  constructor(t, e) {
308
308
  this._totalRows = 0, this._scrollTop = 0, this._viewportHeight = 0, this._rafId = null, this._onScroll = () => {
309
309
  this._scrollTop = this.container.scrollTop, this._scheduleRender();
@@ -320,8 +320,8 @@ class ae {
320
320
  const t = Math.ceil(this._viewportHeight / this.rowHeight), e = Math.max(0, Math.floor(this._scrollTop / this.rowHeight) - this.overscan), s = Math.min(
321
321
  this._totalRows - 1,
322
322
  e + t + this.overscan * 2
323
- ), i = e * this.rowHeight;
324
- return { startIndex: e, endIndex: s, offsetY: i };
323
+ ), o = e * this.rowHeight;
324
+ return { startIndex: e, endIndex: s, offsetY: o };
325
325
  }
326
326
  setTotalRows(t) {
327
327
  this._totalRows = t, this._updateSpacerHeight(), this._scheduleRender();
@@ -333,12 +333,12 @@ class ae {
333
333
  this.rowHeight = t, this._updateSpacerHeight(), this._scheduleRender();
334
334
  }
335
335
  scrollToRow(t) {
336
- const e = t * this.rowHeight, s = e + this.rowHeight, i = this._scrollTop + this._viewportHeight;
336
+ const e = t * this.rowHeight, s = e + this.rowHeight, o = this._scrollTop + this._viewportHeight;
337
337
  if (e < this._scrollTop)
338
338
  this._scrollTop = e, this.container.scrollTop = e;
339
- else if (s > i) {
340
- const o = s - this._viewportHeight;
341
- this._scrollTop = o, this.container.scrollTop = o;
339
+ else if (s > o) {
340
+ const i = s - this._viewportHeight;
341
+ this._scrollTop = i, this.container.scrollTop = i;
342
342
  }
343
343
  }
344
344
  getTotalHeight() {
@@ -352,16 +352,16 @@ class ae {
352
352
  this.container.removeEventListener("scroll", this._onScroll), this._rafId !== null && cancelAnimationFrame(this._rafId);
353
353
  }
354
354
  }
355
- class Lt {
355
+ class Ft {
356
356
  constructor(t, e = 0) {
357
357
  this._flatLeaves = [], this._maxDepth = 1, this._frozenCount = 0, this._columns = t, this._frozenCount = e, this._process();
358
358
  }
359
359
  _process() {
360
360
  const t = [];
361
361
  let e = 0;
362
- const s = (i, o) => {
363
- for (const n of i)
364
- n.children && n.children.length > 0 ? (s(n.children, o + 1), this._maxDepth = Math.max(this._maxDepth, o + 1)) : t.push({ ...n, _colIndex: e++, _depth: o, _leaf: !0 });
362
+ const s = (o, i) => {
363
+ for (const n of o)
364
+ n.children && n.children.length > 0 ? (s(n.children, i + 1), this._maxDepth = Math.max(this._maxDepth, i + 1)) : t.push({ ...n, _colIndex: e++, _depth: i, _leaf: !0 });
365
365
  };
366
366
  this._maxDepth = 1, s(this._columns, 1), this._flatLeaves = t;
367
367
  }
@@ -399,7 +399,7 @@ class Lt {
399
399
  e === "last" ? this._columns.push(t) : e === "first" ? this._columns.unshift(t) : this._columns.splice(e, 0, t), this._process();
400
400
  }
401
401
  removeColumn(t) {
402
- const e = (s) => s.filter((i) => i.field === t ? !1 : (i.children && (i.children = e(i.children)), !0));
402
+ const e = (s) => s.filter((o) => o.field === t ? !1 : (o.children && (o.children = e(o.children)), !0));
403
403
  this._columns = e(this._columns), this._process();
404
404
  }
405
405
  getColumnByField(t) {
@@ -415,26 +415,26 @@ class Lt {
415
415
  buildHeaderCells() {
416
416
  const t = Array.from({ length: this._maxDepth }, () => []);
417
417
  let e = 0;
418
- const s = (i, o) => {
418
+ const s = (o, i) => {
419
419
  let n = 0;
420
- for (const r of i)
420
+ for (const r of o)
421
421
  if (!r.hidden)
422
422
  if (r.children && r.children.length > 0) {
423
- const l = s(r.children, o + 1);
424
- l > 0 && (t[o - 1].push({
423
+ const l = s(r.children, i + 1);
424
+ l > 0 && (t[i - 1].push({
425
425
  column: r,
426
426
  colIndex: e,
427
- depth: o,
427
+ depth: i,
428
428
  colSpan: l,
429
429
  rowSpan: 1
430
430
  }), n += l);
431
431
  } else
432
- t[o - 1].push({
432
+ t[i - 1].push({
433
433
  column: r,
434
434
  colIndex: e++,
435
- depth: o,
435
+ depth: i,
436
436
  colSpan: 1,
437
- rowSpan: this._maxDepth - o + 1
437
+ rowSpan: this._maxDepth - i + 1
438
438
  }), n++;
439
439
  return n;
440
440
  };
@@ -442,11 +442,11 @@ class Lt {
442
442
  }
443
443
  /** 각 리프 컬럼의 계산된 너비 배열 반환 */
444
444
  computeWidths(t, e = 100) {
445
- const s = this.visibleLeaves, i = s.filter((l) => l.flex), o = s.filter((l) => !l.flex && l.width).reduce((l, a) => l + a.width, 0), n = i.reduce((l, a) => l + (a.flex ?? 1), 0), r = Math.max(0, t - o);
445
+ const s = this.visibleLeaves, o = s.filter((l) => l.flex), i = s.filter((l) => !l.flex && l.width).reduce((l, a) => l + a.width, 0), n = o.reduce((l, a) => l + (a.flex ?? 1), 0), r = Math.max(0, t - i);
446
446
  return s.map((l) => l.flex ? Math.round(l.flex / n * r) : l.width ?? e);
447
447
  }
448
448
  }
449
- class de {
449
+ class he {
450
450
  constructor(t, e, s) {
451
451
  this._field = "", this._outsideHandler = null, this._onApply = e, this._onClear = s, this._el = document.createElement("div"), this._el.className = "og-filter-panel", this._el.style.cssText = `
452
452
  position:absolute;z-index:1000;min-width:200px;max-width:280px;
@@ -458,10 +458,10 @@ class de {
458
458
  open(t, e, s) {
459
459
  var k;
460
460
  this._field = t, this._el.innerHTML = "";
461
- const i = document.createElement("div");
462
- i.textContent = "필터", i.style.cssText = "font-weight:600;margin-bottom:8px;color:var(--og-text-color,#333);", this._el.appendChild(i);
463
461
  const o = document.createElement("div");
464
- o.style.cssText = "display:flex;gap:4px;margin-bottom:6px;";
462
+ o.textContent = "필터", o.style.cssText = "font-weight:600;margin-bottom:8px;color:var(--og-text-color,#333);", this._el.appendChild(o);
463
+ const i = document.createElement("div");
464
+ i.style.cssText = "display:flex;gap:4px;margin-bottom:6px;";
465
465
  const n = document.createElement("select");
466
466
  n.style.cssText = "flex:1;padding:3px 4px;border:1px solid var(--og-border-color,#e0e0e0);border-radius:3px;font-size:12px;";
467
467
  const r = [
@@ -475,18 +475,18 @@ class de {
475
475
  { label: "이상", value: ">=" },
476
476
  { label: "이하", value: "<=" }
477
477
  ];
478
- for (const m of r) {
479
- const w = document.createElement("option");
480
- w.value = m.value, w.textContent = m.label, n.appendChild(w);
478
+ for (const y of r) {
479
+ const b = document.createElement("option");
480
+ b.value = y.value, b.textContent = y.label, n.appendChild(b);
481
481
  }
482
- s[0] && (n.value = s[0].operator), o.appendChild(n), this._el.appendChild(o);
482
+ s[0] && (n.value = s[0].operator), i.appendChild(n), this._el.appendChild(i);
483
483
  const l = document.createElement("input");
484
484
  l.type = "text", l.placeholder = "필터 값 입력...", l.value = ((k = s[0]) == null ? void 0 : k.value) ?? "", l.style.cssText = `
485
485
  width:100%;padding:4px 6px;border:1px solid var(--og-border-color,#e0e0e0);
486
486
  border-radius:3px;font-size:12px;box-sizing:border-box;margin-bottom:8px;
487
487
  outline:none;
488
- `, l.addEventListener("keydown", (m) => {
489
- m.key === "Enter" ? u.click() : m.key === "Escape" && this.close();
488
+ `, l.addEventListener("keydown", (y) => {
489
+ y.key === "Enter" ? u.click() : y.key === "Escape" && this.close();
490
490
  }), this._el.appendChild(l);
491
491
  const a = document.createElement("div");
492
492
  a.style.cssText = "display:flex;gap:6px;justify-content:flex-end;";
@@ -503,12 +503,12 @@ class de {
503
503
  border-radius:3px;background:var(--og-primary,#1976d2);
504
504
  color:#fff;cursor:pointer;font-size:12px;
505
505
  `, u.addEventListener("click", () => {
506
- const m = l.value.trim();
507
- m ? this._onApply(this._field, [{ operator: n.value, value: m }]) : this._onClear(this._field), this.close();
506
+ const y = l.value.trim();
507
+ y ? this._onApply(this._field, [{ operator: n.value, value: y }]) : this._onClear(this._field), this.close();
508
508
  }), a.appendChild(c), a.appendChild(u), this._el.appendChild(a);
509
509
  const h = e.getBoundingClientRect(), g = this._el.parentElement.getBoundingClientRect();
510
- this._el.style.top = `${h.bottom - g.top + 2}px`, this._el.style.left = `${Math.min(h.left - g.left, g.width - 220)}px`, this._el.style.display = "block", requestAnimationFrame(() => l.focus()), this._outsideHandler && document.removeEventListener("mousedown", this._outsideHandler), this._outsideHandler = (m) => {
511
- !this._el.contains(m.target) && m.target !== e && this.close();
510
+ this._el.style.top = `${h.bottom - g.top + 2}px`, this._el.style.left = `${Math.min(h.left - g.left, g.width - 220)}px`, this._el.style.display = "block", requestAnimationFrame(() => l.focus()), this._outsideHandler && document.removeEventListener("mousedown", this._outsideHandler), this._outsideHandler = (y) => {
511
+ !this._el.contains(y.target) && y.target !== e && this.close();
512
512
  }, setTimeout(() => document.addEventListener("mousedown", this._outsideHandler), 0);
513
513
  }
514
514
  close() {
@@ -521,38 +521,38 @@ class de {
521
521
  this.close(), this._el.remove();
522
522
  }
523
523
  }
524
- const ce = 10;
525
- function he(d, t = ce) {
524
+ const ue = 10;
525
+ function ge(d, t = ue) {
526
526
  const e = Math.pow(10, t);
527
527
  return Math.round(d * e) / e;
528
528
  }
529
- class M {
529
+ class C {
530
530
  // scale = 소수점 아래 자릿수
531
531
  constructor(t, e) {
532
532
  this._c = t, this._s = e < 0 ? 0 : e;
533
533
  }
534
534
  // ── 생성 ─────────────────────────────────────────────────
535
535
  static from(t) {
536
- if (t instanceof M) return t;
537
- if (typeof t == "bigint") return new M(t, 0);
536
+ if (t instanceof C) return t;
537
+ if (typeof t == "bigint") return new C(t, 0);
538
538
  const e = String(t).trim();
539
539
  if (!e || e === "null" || e === "undefined" || e === "NaN")
540
- return new M(0n, 0);
541
- const s = e.startsWith("-"), i = s ? e.slice(1) : e, o = i.indexOf(".");
540
+ return new C(0n, 0);
541
+ const s = e.startsWith("-"), o = s ? e.slice(1) : e, i = o.indexOf(".");
542
542
  let n, r;
543
- if (o === -1)
544
- n = BigInt(i), r = 0;
543
+ if (i === -1)
544
+ n = BigInt(o), r = 0;
545
545
  else {
546
- const l = i.slice(o + 1);
547
- n = BigInt(i.slice(0, o) + l), r = l.length;
546
+ const l = o.slice(i + 1);
547
+ n = BigInt(o.slice(0, i) + l), r = l.length;
548
548
  }
549
- return new M(s ? -n : n, r);
549
+ return new C(s ? -n : n, r);
550
550
  }
551
551
  static zero() {
552
- return new M(0n, 0);
552
+ return new C(0n, 0);
553
553
  }
554
554
  static one() {
555
- return new M(1n, 0);
555
+ return new C(1n, 0);
556
556
  }
557
557
  // ── 내부: 두 값의 스케일 정렬 ────────────────────────────
558
558
  static _align(t, e) {
@@ -560,51 +560,51 @@ class M {
560
560
  }
561
561
  // ── 사칙연산 ─────────────────────────────────────────────
562
562
  add(t) {
563
- const [e, s, i] = M._align(this, M.from(t));
564
- return new M(e + s, i);
563
+ const [e, s, o] = C._align(this, C.from(t));
564
+ return new C(e + s, o);
565
565
  }
566
566
  sub(t) {
567
- const [e, s, i] = M._align(this, M.from(t));
568
- return new M(e - s, i);
567
+ const [e, s, o] = C._align(this, C.from(t));
568
+ return new C(e - s, o);
569
569
  }
570
570
  mul(t) {
571
- const e = M.from(t);
572
- return new M(this._c * e._c, this._s + e._s);
571
+ const e = C.from(t);
572
+ return new C(this._c * e._c, this._s + e._s);
573
573
  }
574
574
  /**
575
575
  * 나눗셈. precision = 결과 소수점 자리수 (기본 20).
576
576
  * 수익 배분처럼 소수 수백 자리가 필요하면 precision을 높인다.
577
577
  */
578
578
  div(t, e = 20) {
579
- const s = M.from(t);
579
+ const s = C.from(t);
580
580
  if (s._c === 0n) throw new Error("OGDecimal: division by zero");
581
- const o = this._c * 10n ** BigInt(e + s._s) / s._c;
582
- return new M(o, e + this._s);
581
+ const i = this._c * 10n ** BigInt(e + s._s) / s._c;
582
+ return new C(i, e + this._s);
583
583
  }
584
584
  /** 나머지 (정수 나머지와 동일한 개념을 소수에 적용) */
585
585
  mod(t) {
586
- const e = M.from(t), [s, i, o] = M._align(this, e);
587
- return new M(s % i, o);
586
+ const e = C.from(t), [s, o, i] = C._align(this, e);
587
+ return new C(s % o, i);
588
588
  }
589
589
  /** 부호 반전 */
590
590
  neg() {
591
- return new M(-this._c, this._s);
591
+ return new C(-this._c, this._s);
592
592
  }
593
593
  /** 절댓값 */
594
594
  abs() {
595
- return new M(this._c < 0n ? -this._c : this._c, this._s);
595
+ return new C(this._c < 0n ? -this._c : this._c, this._s);
596
596
  }
597
597
  // ── 비교 ─────────────────────────────────────────────────
598
598
  eq(t) {
599
- const [e, s] = M._align(this, M.from(t));
599
+ const [e, s] = C._align(this, C.from(t));
600
600
  return e === s;
601
601
  }
602
602
  gt(t) {
603
- const [e, s] = M._align(this, M.from(t));
603
+ const [e, s] = C._align(this, C.from(t));
604
604
  return e > s;
605
605
  }
606
606
  lt(t) {
607
- const [e, s] = M._align(this, M.from(t));
607
+ const [e, s] = C._align(this, C.from(t));
608
608
  return e < s;
609
609
  }
610
610
  gte(t) {
@@ -633,12 +633,12 @@ class M {
633
633
  e = e * 10n ** BigInt(t - s);
634
634
  else if (s > t) {
635
635
  const c = 10n ** BigInt(s - t), u = c / 2n, h = e < 0n, g = h ? -e : e, k = g % c;
636
- let m = g / c;
637
- k >= u && (m += 1n), e = h ? -m : m;
636
+ let y = g / c;
637
+ k >= u && (y += 1n), e = h ? -y : y;
638
638
  }
639
639
  s = t;
640
- const i = e < 0n, n = (i ? -e : e).toString().padStart(t + 1, "0"), r = n.slice(0, n.length - t) || "0", l = t > 0 ? "." + n.slice(n.length - t) : "";
641
- return (i ? "-" : "") + r + l;
640
+ const o = e < 0n, n = (o ? -e : e).toString().padStart(t + 1, "0"), r = n.slice(0, n.length - t) || "0", l = t > 0 ? "." + n.slice(n.length - t) : "";
641
+ return (o ? "-" : "") + r + l;
642
642
  }
643
643
  /** 정규화(후행 0 제거) 후 최소 표현 문자열 반환 */
644
644
  toString() {
@@ -646,7 +646,7 @@ class M {
646
646
  let t = this._c, e = this._s;
647
647
  for (; e > 0 && t !== 0n && t % 10n === 0n; )
648
648
  t /= 10n, e--;
649
- return new M(t, e).toFixed(e);
649
+ return new C(t, e).toFixed(e);
650
650
  }
651
651
  /** number로 변환 (정밀도 손실 주의 — 표시 전용) */
652
652
  toNumber() {
@@ -655,27 +655,27 @@ class M {
655
655
  // ── 집계 정적 메서드 ─────────────────────────────────────
656
656
  /** 정확한 합산 (내부적으로 BigInt 정수 연산) */
657
657
  static sum(t) {
658
- return t.reduce((e, s) => e.add(s), M.zero());
658
+ return t.reduce((e, s) => e.add(s), C.zero());
659
659
  }
660
660
  /** 정확한 평균. precision = 나눗셈 소수점 자리수 */
661
661
  static avg(t, e = 20) {
662
- return t.length ? M.sum(t).div(t.length, e) : M.zero();
662
+ return t.length ? C.sum(t).div(t.length, e) : C.zero();
663
663
  }
664
664
  /** 배열 최솟값 */
665
665
  static min(t) {
666
666
  if (!t.length) throw new Error("OGDecimal.min: empty array");
667
- return t.map(M.from).reduce((e, s) => e.lt(s) ? e : s);
667
+ return t.map(C.from).reduce((e, s) => e.lt(s) ? e : s);
668
668
  }
669
669
  /** 배열 최댓값 */
670
670
  static max(t) {
671
671
  if (!t.length) throw new Error("OGDecimal.max: empty array");
672
- return t.map(M.from).reduce((e, s) => e.gt(s) ? e : s);
672
+ return t.map(C.from).reduce((e, s) => e.gt(s) ? e : s);
673
673
  }
674
674
  }
675
- function Gt(d, t, e = 30) {
676
- return new ue(d, t, e).parse();
675
+ function Xt(d, t, e = 30) {
676
+ return new pe(d, t, e).parse();
677
677
  }
678
- class ue {
678
+ class pe {
679
679
  constructor(t, e, s) {
680
680
  this._ctx = e, this._prec = s, this._pos = 0, this._src = t.trim();
681
681
  }
@@ -739,7 +739,7 @@ class ue {
739
739
  const s = this._ctx[e];
740
740
  if (s == null)
741
741
  throw new ReferenceError(`FormulaEngine: 필드 '[${e}]'가 행 데이터에 없습니다`);
742
- return M.from(s);
742
+ return C.from(s);
743
743
  }
744
744
  /** 숫자 리터럴 파싱 (정수 / 소수 모두) */
745
745
  _literal() {
@@ -751,7 +751,7 @@ class ue {
751
751
  throw new SyntaxError(
752
752
  `FormulaEngine: 숫자 또는 [필드]를 기대했지만 '${this._src[this._pos] ?? "EOF"}' 발견 (위치 ${t})`
753
753
  );
754
- return M.from(e);
754
+ return C.from(e);
755
755
  }
756
756
  /** 공백 스킵 */
757
757
  _skip() {
@@ -759,108 +759,108 @@ class ue {
759
759
  this._pos++;
760
760
  }
761
761
  }
762
- function kt(d, t) {
762
+ function Rt(d, t) {
763
763
  if (d == null || d === "") return d ?? "";
764
764
  const e = typeof t == "string" ? { type: t } : t, s = e.char ?? "*";
765
765
  switch (e.type) {
766
766
  case "ssn":
767
- return ge(d, s);
767
+ return _e(d, s);
768
768
  case "phone":
769
769
  case "mobile":
770
- return pe(d, s);
770
+ return fe(d, s);
771
771
  case "email":
772
- return _e(d, s);
772
+ return me(d, s);
773
773
  case "credit":
774
- return fe(d, s);
774
+ return ye(d, s);
775
775
  case "account":
776
- return me(d, s, e.visiblePrefix ?? 3, e.visibleSuffix ?? 4);
776
+ return we(d, s, e.visiblePrefix ?? 3, e.visibleSuffix ?? 4);
777
777
  case "password":
778
778
  return s.repeat(Math.max(d.length, 6));
779
779
  case "name":
780
- return ye(d, s);
780
+ return be(d, s);
781
781
  case "ip":
782
- return we(d, s);
782
+ return ve(d, s);
783
783
  case "partial":
784
- return rt(d, s, e.visiblePrefix ?? 0, e.visibleSuffix ?? 4);
784
+ return lt(d, s, e.visiblePrefix ?? 0, e.visibleSuffix ?? 4);
785
785
  default:
786
786
  return d;
787
787
  }
788
788
  }
789
- function ge(d, t) {
789
+ function _e(d, t) {
790
790
  const e = d.replace(/[^0-9]/g, "");
791
791
  if (e.length < 7) {
792
792
  const n = d.includes("-") ? "-" : "", r = d.indexOf("-") >= 0 ? d.indexOf("-") : 6;
793
793
  return d.slice(0, r) + n + t.repeat(Math.max(1, d.length - r - n.length));
794
794
  }
795
- const s = e.slice(0, 6), i = e[6], o = e.length - 7;
796
- return `${s}-${i}${t.repeat(o)}`;
795
+ const s = e.slice(0, 6), o = e[6], i = e.length - 7;
796
+ return `${s}-${o}${t.repeat(i)}`;
797
797
  }
798
- function pe(d, t) {
798
+ function fe(d, t) {
799
799
  const e = d.replace(/[^0-9]/g, "");
800
- return e.length === 11 ? `${e.slice(0, 3)}-${t.repeat(4)}-${e.slice(7)}` : e.length === 10 ? e.startsWith("02") ? `${e.slice(0, 2)}-${t.repeat(4)}-${e.slice(6)}` : `${e.slice(0, 3)}-${t.repeat(3)}-${e.slice(6)}` : e.length === 9 ? `${e.slice(0, 2)}-${t.repeat(3)}-${e.slice(5)}` : rt(d, t, 3, 4);
800
+ return e.length === 11 ? `${e.slice(0, 3)}-${t.repeat(4)}-${e.slice(7)}` : e.length === 10 ? e.startsWith("02") ? `${e.slice(0, 2)}-${t.repeat(4)}-${e.slice(6)}` : `${e.slice(0, 3)}-${t.repeat(3)}-${e.slice(6)}` : e.length === 9 ? `${e.slice(0, 2)}-${t.repeat(3)}-${e.slice(5)}` : lt(d, t, 3, 4);
801
801
  }
802
- function _e(d, t) {
802
+ function me(d, t) {
803
803
  const e = d.indexOf("@");
804
- if (e < 0) return rt(d, t, 2, 0);
805
- const s = d.slice(0, e), i = d.slice(e), o = Math.min(2, s.length), n = s.slice(0, o), r = Math.max(s.length - o, 3);
806
- return `${n}${t.repeat(r)}${i}`;
804
+ if (e < 0) return lt(d, t, 2, 0);
805
+ const s = d.slice(0, e), o = d.slice(e), i = Math.min(2, s.length), n = s.slice(0, i), r = Math.max(s.length - i, 3);
806
+ return `${n}${t.repeat(r)}${o}`;
807
807
  }
808
- function fe(d, t) {
808
+ function ye(d, t) {
809
809
  const e = d.replace(/[^0-9]/g, "");
810
810
  if (e.length < 8) return d;
811
- const s = e.slice(0, 4), i = e.slice(-4), o = e.length - 8, n = t.repeat(Math.max(o, 8)), r = [s];
811
+ const s = e.slice(0, 4), o = e.slice(-4), i = e.length - 8, n = t.repeat(Math.max(i, 8)), r = [s];
812
812
  for (let l = 0; l < n.length; l += 4) {
813
813
  const a = n.slice(l, l + 4);
814
814
  a && r.push(a);
815
815
  }
816
- return r.push(i), r.join("-");
816
+ return r.push(o), r.join("-");
817
817
  }
818
- function me(d, t, e, s) {
819
- const i = d.replace(/[^0-9]/g, "");
820
- if (i.length <= e + s)
821
- return rt(i, t, e, s);
822
- const o = i.slice(0, e), n = i.slice(-s), r = i.length - e - s;
823
- return `${o}-${t.repeat(r)}-${n}`;
818
+ function we(d, t, e, s) {
819
+ const o = d.replace(/[^0-9]/g, "");
820
+ if (o.length <= e + s)
821
+ return lt(o, t, e, s);
822
+ const i = o.slice(0, e), n = o.slice(-s), r = o.length - e - s;
823
+ return `${i}-${t.repeat(r)}-${n}`;
824
824
  }
825
- function ye(d, t) {
825
+ function be(d, t) {
826
826
  const e = d.trim();
827
827
  return e.length === 0 ? d : e.length === 1 ? t : e.length === 2 ? `${e[0]}${t}` : `${e[0]}${t.repeat(e.length - 2)}${e[e.length - 1]}`;
828
828
  }
829
- function we(d, t) {
829
+ function ve(d, t) {
830
830
  const e = d.split(".");
831
- if (e.length !== 4) return rt(d, t, 3, 0);
832
- const s = (i) => t.repeat(Math.max(i.length, 3));
831
+ if (e.length !== 4) return lt(d, t, 3, 0);
832
+ const s = (o) => t.repeat(Math.max(o.length, 3));
833
833
  return `${e[0]}.${e[1]}.${s(e[2])}.${s(e[3])}`;
834
834
  }
835
- function rt(d, t, e, s) {
835
+ function lt(d, t, e, s) {
836
836
  if (d.length <= e + s) return d;
837
- const i = d.slice(0, e), o = s > 0 ? d.slice(-s) : "", n = d.length - e - s;
838
- return `${i}${t.repeat(n)}${o}`;
837
+ const o = d.slice(0, e), i = s > 0 ? d.slice(-s) : "", n = d.length - e - s;
838
+ return `${o}${t.repeat(n)}${i}`;
839
839
  }
840
- let ot = null;
841
- function be(d) {
842
- ot = d;
840
+ let nt = null;
841
+ function xe(d) {
842
+ nt = d;
843
843
  }
844
- function qt(d) {
844
+ function Yt(d) {
845
845
  const t = d.column;
846
846
  if (!t.formula) return null;
847
847
  const e = t.formulaPrecision ?? 30;
848
848
  try {
849
849
  let s;
850
- return typeof t.formula == "function" ? s = t.formula(d.row, M) : s = Gt(t.formula, d.row, e), s instanceof M ? t.precision != null ? s.toFixed(t.precision) : s.toString() : typeof s == "string" ? s : t.precision != null ? M.from(s).toFixed(t.precision) : String(s);
850
+ return typeof t.formula == "function" ? s = t.formula(d.row, C) : s = Xt(t.formula, d.row, e), s instanceof C ? t.precision != null ? s.toFixed(t.precision) : s.toString() : typeof s == "string" ? s : t.precision != null ? C.from(s).toFixed(t.precision) : String(s);
851
851
  } catch (s) {
852
852
  return console.warn("[OpenGrid] Formula error:", s), "#ERR";
853
853
  }
854
854
  }
855
- function ve(d, t, e, s, i, o) {
856
- if (ot) {
857
- const _ = ot(d, i ?? "", o);
858
- if (_ != null) return _;
855
+ function Ce(d, t, e, s, o, i) {
856
+ if (nt) {
857
+ const p = nt(d, o ?? "", i);
858
+ if (p != null) return p;
859
859
  }
860
860
  if (d == null || d === "") return "";
861
861
  let n = Number(d);
862
862
  if (isNaN(n)) return String(d);
863
- if (e != null && (n = he(n, e)), s)
863
+ if (e != null && (n = ge(n, e)), s)
864
864
  try {
865
865
  return new Intl.NumberFormat(void 0, {
866
866
  style: "currency",
@@ -873,57 +873,59 @@ function ve(d, t, e, s, i, o) {
873
873
  return e != null ? n.toFixed(e) : String(n);
874
874
  const r = t.indexOf(";"), l = r >= 0 ? t.slice(r + 1) : null, a = n < 0 && l != null ? l : r >= 0 ? t.slice(0, r) : t, c = n < 0 && l != null ? Math.abs(n) : n, u = a.match(/[#0][#0,]*(?:\.[#0]+)?/);
875
875
  if (!u) return String(n);
876
- const h = u[0], g = a.slice(0, u.index), k = a.slice(u.index + h.length), m = h.includes(","), w = h.includes(".") ? h.split(".")[1].length : e ?? 0, x = c.toLocaleString("ko-KR", {
877
- minimumFractionDigits: w,
878
- maximumFractionDigits: w,
879
- useGrouping: m
876
+ const h = u[0], g = a.slice(0, u.index), k = a.slice(u.index + h.length), y = h.includes(","), b = h.includes(".") ? h.split(".")[1].length : e ?? 0, x = c.toLocaleString("ko-KR", {
877
+ minimumFractionDigits: b,
878
+ maximumFractionDigits: b,
879
+ useGrouping: y
880
880
  });
881
881
  return g + x + k;
882
882
  }
883
- function Xt(d, t = "yyyy-MM-dd", e, s) {
884
- if (ot) {
885
- const l = ot(d, e ?? "", s);
883
+ function Jt(d, t = "yyyy-MM-dd", e, s) {
884
+ if (nt) {
885
+ const l = nt(d, e ?? "", s);
886
886
  if (l != null) return l;
887
887
  }
888
888
  if (!d) return "";
889
- const i = d instanceof Date ? d : new Date(d);
890
- if (isNaN(i.getTime())) return String(d);
891
- const o = i.getFullYear(), n = String(i.getMonth() + 1).padStart(2, "0"), r = String(i.getDate()).padStart(2, "0");
892
- return t.replace("yyyy", String(o)).replace("MM", n).replace("dd", r);
889
+ const o = d instanceof Date ? d : new Date(d);
890
+ if (isNaN(o.getTime())) return String(d);
891
+ const i = o.getFullYear(), n = String(o.getMonth() + 1).padStart(2, "0"), r = String(o.getDate()).padStart(2, "0");
892
+ return t.replace("yyyy", String(i)).replace("MM", n).replace("dd", r);
893
893
  }
894
- function xe(d, t, e) {
895
- const s = kt(d, t.mask), i = document.createElement("span");
896
- i.style.cssText = "display:flex;align-items:center;gap:3px;overflow:hidden;width:100%;box-sizing:border-box;";
897
- const o = document.createElement("span");
898
- o.style.cssText = "flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:monospace;letter-spacing:0.4px;color:var(--og-mask-text,#888);", o.textContent = s;
894
+ function Me(d, t, e) {
895
+ const s = Rt(d, t.mask), o = document.createElement("span");
896
+ o.style.cssText = "display:flex;align-items:center;gap:3px;overflow:hidden;width:100%;box-sizing:border-box;";
897
+ const i = document.createElement("span");
898
+ i.style.cssText = "flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:monospace;letter-spacing:0.4px;color:var(--og-mask-text,#888);", i.textContent = s;
899
899
  const n = document.createElement("button");
900
900
  return n.title = "클릭하면 원문 표시", n.setAttribute("aria-label", "마스킹 해제"), n.innerHTML = '<svg width="13" height="13" viewBox="0 0 16 16" fill="currentColor"><path d="M16 8s-3-5.5-8-5.5S0 8 0 8s3 5.5 8 5.5S16 8 16 8z"/><path d="M8 5.5A2.5 2.5 0 1 0 8 10.5 2.5 2.5 0 0 0 8 5.5zm0 4A1.5 1.5 0 1 1 8 6.5a1.5 1.5 0 0 1 0 3z" fill="#fff"/></svg>', n.style.cssText = "flex-shrink:0;background:none;border:none;cursor:pointer;color:#c0c0c0;padding:1px 2px;line-height:0;border-radius:3px;display:flex;align-items:center;", n.addEventListener("mouseover", () => {
901
901
  n.style.color = "var(--og-primary,#1976d2)", n.style.background = "rgba(25,118,210,0.08)";
902
902
  }), n.addEventListener("mouseout", () => {
903
903
  n.style.color = "#c0c0c0", n.style.background = "none";
904
904
  }), n.addEventListener("click", (r) => {
905
- r.stopPropagation(), o.textContent = d, o.style.fontFamily = "", o.style.letterSpacing = "", o.style.color = "", n.remove(), (t._maskRevealedRows ?? (t._maskRevealedRows = /* @__PURE__ */ new Set())).add(e);
906
- }), i.appendChild(o), i.appendChild(n), i;
905
+ r.stopPropagation(), i.textContent = d, i.style.fontFamily = "", i.style.letterSpacing = "", i.style.color = "", n.remove(), (t._maskRevealedRows ?? (t._maskRevealedRows = /* @__PURE__ */ new Set())).add(e);
906
+ }), o.appendChild(i), o.appendChild(n), o;
907
907
  }
908
- class ut {
908
+ class gt {
909
909
  render(t) {
910
910
  var l;
911
911
  const e = document.createElement("span");
912
912
  e.className = "og-cell-text";
913
- const s = qt(t);
913
+ const s = Yt(t);
914
914
  if (s !== null)
915
915
  return e.textContent = s, e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;", e;
916
- const { value: i, column: o, rowIndex: n } = t;
916
+ const { value: o, column: i, rowIndex: n } = t;
917
+ if (t.displayValue != null)
918
+ return e.textContent = t.displayValue, e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;", e;
917
919
  let r;
918
- if (o.valueMap && i != null && o.valueMap[i] ? r = o.valueMap[i] : r = i == null ? "" : String(i), o.mask) {
919
- const a = o._maskRevealed === !0, c = ((l = o._maskRevealedRows) == null ? void 0 : l.has(n)) === !0;
920
+ if (i.valueMap && o != null && i.valueMap[o] ? r = i.valueMap[o] : r = o == null ? "" : String(o), i.mask) {
921
+ const a = i._maskRevealed === !0, c = ((l = i._maskRevealedRows) == null ? void 0 : l.has(n)) === !0;
920
922
  if (!a && !c)
921
- return xe(r, o, n);
923
+ return Me(r, i, n);
922
924
  }
923
925
  return e.textContent = r, e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;", e;
924
926
  }
925
927
  }
926
- class Ce {
928
+ class ke {
927
929
  constructor(t = [], e) {
928
930
  this._opts = t.map(
929
931
  (s) => typeof s == "string" ? { label: s, value: s } : { label: s.label ?? s.text ?? String(s.value ?? ""), value: s.value }
@@ -934,25 +936,25 @@ class Ce {
934
936
  e.className = "og-cell-text", e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;";
935
937
  const s = t.value;
936
938
  if (s == null || s === "") return e;
937
- const i = String(s), n = (this._fn ? this._fn(t.row, t.rowIndex).map((r) => typeof r == "string" ? { label: r, value: r } : { label: r.label ?? r.text ?? String(r.value ?? ""), value: r.value }) : this._opts).find((r) => String(r.value) === i);
938
- return e.textContent = n ? n.label : i, e;
939
+ const o = String(s), n = (this._fn ? this._fn(t.row, t.rowIndex).map((r) => typeof r == "string" ? { label: r, value: r } : { label: r.label ?? r.text ?? String(r.value ?? ""), value: r.value }) : this._opts).find((r) => String(r.value) === o);
940
+ return e.textContent = n ? n.label : o, e;
939
941
  }
940
942
  }
941
- class gt {
943
+ class pt {
942
944
  render(t) {
943
945
  const e = document.createElement("span");
944
946
  e.className = "og-cell-number";
945
- const s = qt(t);
946
- return s !== null ? (e.textContent = s, e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;width:100%;text-align:right;", e) : (e.textContent = ve(t.value, t.column.format ?? "#,##0", t.column.precision, t.column.currency, t.column.field, t.row), e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;width:100%;text-align:right;", e);
947
+ const s = Yt(t);
948
+ return s !== null ? (e.textContent = s, e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;width:100%;text-align:right;", e) : (e.textContent = Ce(t.value, t.column.format ?? "#,##0", t.column.precision, t.column.currency, t.column.field, t.row), e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;width:100%;text-align:right;", e);
947
949
  }
948
950
  }
949
- class pt {
951
+ class _t {
950
952
  render(t) {
951
953
  const e = document.createElement("span");
952
- return e.className = "og-cell-date", e.textContent = Xt(t.value, t.column.format, t.column.field, t.row), e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;", e;
954
+ return e.className = "og-cell-date", e.textContent = Jt(t.value, t.column.format, t.column.field, t.row), e.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;", e;
953
955
  }
954
956
  }
955
- class _t {
957
+ class ft {
956
958
  render(t) {
957
959
  const e = document.createElement("span");
958
960
  e.className = "og-cell-checkbox", e.style.cssText = "display:flex;align-items:center;justify-content:center;height:100%;";
@@ -960,18 +962,18 @@ class _t {
960
962
  return s.type = "checkbox", s.checked = !!t.value, s.disabled = !0, s.style.cssText += "cursor:pointer;pointer-events:none;", e.appendChild(s), e;
961
963
  }
962
964
  }
963
- class Ft {
965
+ class Dt {
964
966
  constructor(t) {
965
967
  this.def = t;
966
968
  }
967
969
  render(t) {
968
- var o, n, r;
970
+ var i, n, r;
969
971
  const e = document.createElement("span");
970
972
  e.style.cssText = "display:flex;align-items:center;justify-content:center;height:100%;";
971
973
  const s = document.createElement("button");
972
- s.className = `og-cell-btn${(o = this.def) != null && o.buttonClass ? " " + this.def.buttonClass : ""}`;
973
- const i = (n = this.def) == null ? void 0 : n.label;
974
- return typeof i == "function" ? s.textContent = i(t.value, t.row) : s.textContent = i ?? String(t.value ?? "btn"), s.style.cssText = `
974
+ s.className = `og-cell-btn${(i = this.def) != null && i.buttonClass ? " " + this.def.buttonClass : ""}`;
975
+ const o = (n = this.def) == null ? void 0 : n.label;
976
+ return typeof o == "function" ? s.textContent = o(t.value, t.row) : s.textContent = o ?? String(t.value ?? "btn"), s.style.cssText = `
975
977
  padding:2px 10px;border:1px solid var(--og-primary,#1976d2);
976
978
  border-radius:4px;background:var(--og-row-bg,#fff);color:var(--og-primary,#1976d2);
977
979
  cursor:pointer;font-size:12px;white-space:nowrap;transition:background 0.12s;
@@ -979,7 +981,7 @@ class Ft {
979
981
  `, s.addEventListener("mouseover", () => s.style.background = "var(--og-primary-light,#e3f2fd)"), s.addEventListener("mouseout", () => s.style.background = "var(--og-row-bg,#fff)"), e.appendChild(s), e;
980
982
  }
981
983
  }
982
- class Tt {
984
+ class $t {
983
985
  constructor(t, e) {
984
986
  this.colorMap = t, this.labelMap = e;
985
987
  }
@@ -987,9 +989,9 @@ class Tt {
987
989
  var r, l, a;
988
990
  const e = document.createElement("span");
989
991
  e.style.cssText = "display:flex;align-items:center;height:100%;";
990
- const s = document.createElement("span"), i = t.value == null ? "" : String(t.value), o = ((r = this.labelMap) == null ? void 0 : r[i]) ?? ((l = t.column.valueMap) == null ? void 0 : l[i]) ?? i;
991
- s.textContent = o;
992
- const n = ((a = this.colorMap) == null ? void 0 : a[i]) ?? "#666";
992
+ const s = document.createElement("span"), o = t.value == null ? "" : String(t.value), i = ((r = this.labelMap) == null ? void 0 : r[o]) ?? ((l = t.column.valueMap) == null ? void 0 : l[o]) ?? o;
993
+ s.textContent = i;
994
+ const n = ((a = this.colorMap) == null ? void 0 : a[o]) ?? "#666";
993
995
  return s.style.cssText = `
994
996
  display:inline-block;padding:2px 8px;border-radius:12px;font-size:11px;
995
997
  background:${n}22;color:${n};border:1px solid ${n}66;
@@ -997,7 +999,7 @@ class Tt {
997
999
  `, e.appendChild(s), e;
998
1000
  }
999
1001
  }
1000
- class Dt {
1002
+ class At {
1001
1003
  constructor(t, e) {
1002
1004
  this.hrefFn = t, this.target = e;
1003
1005
  }
@@ -1006,7 +1008,7 @@ class Dt {
1006
1008
  return e.className = "og-cell-link", e.textContent = t.value == null ? "" : String(t.value), e.href = this.hrefFn ? this.hrefFn(t.value, t.row) : "#", this.target && (e.target = this.target), e.style.cssText = "color:var(--og-primary,#1976d2);text-decoration:underline;cursor:pointer;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;", this.hrefFn || e.addEventListener("click", (s) => s.preventDefault()), e;
1007
1009
  }
1008
1010
  }
1009
- class Me {
1011
+ class Re {
1010
1012
  constructor(t) {
1011
1013
  this.templateFn = t;
1012
1014
  }
@@ -1015,7 +1017,7 @@ class Me {
1015
1017
  return e.className = "og-cell-template", e.style.cssText = "display:flex;align-items:center;height:100%;overflow:hidden;", e.innerHTML = this.templateFn(t.value, t.row, t.rowIndex), e;
1016
1018
  }
1017
1019
  }
1018
- class ke {
1020
+ class Ee {
1019
1021
  constructor(t) {
1020
1022
  this.def = t;
1021
1023
  }
@@ -1023,17 +1025,17 @@ class ke {
1023
1025
  var a, c, u, h, g;
1024
1026
  const e = document.createElement("span");
1025
1027
  e.style.cssText = "display:flex;align-items:center;justify-content:center;height:100%;";
1026
- const s = document.createElement("img"), i = (a = this.def) != null && a.srcFn ? this.def.srcFn(t.value, t.row) : String(t.value ?? "");
1027
- s.src = i;
1028
- const o = ((c = this.def) == null ? void 0 : c.width) ?? 28, n = ((u = this.def) == null ? void 0 : u.height) ?? 28, r = ((h = this.def) == null ? void 0 : h.radius) ?? 4;
1029
- s.style.cssText = `width:${o}px;height:${n}px;object-fit:cover;border-radius:${r}px;display:block;`;
1028
+ const s = document.createElement("img"), o = (a = this.def) != null && a.srcFn ? this.def.srcFn(t.value, t.row) : String(t.value ?? "");
1029
+ s.src = o;
1030
+ const i = ((c = this.def) == null ? void 0 : c.width) ?? 28, n = ((u = this.def) == null ? void 0 : u.height) ?? 28, r = ((h = this.def) == null ? void 0 : h.radius) ?? 4;
1031
+ s.style.cssText = `width:${i}px;height:${n}px;object-fit:cover;border-radius:${r}px;display:block;`;
1030
1032
  const l = (g = this.def) == null ? void 0 : g.alt;
1031
1033
  return s.alt = typeof l == "function" ? l(t.value, t.row) : l ?? "", s.onerror = () => {
1032
1034
  s.style.display = "none";
1033
1035
  }, e.appendChild(s), e;
1034
1036
  }
1035
1037
  }
1036
- class Re {
1038
+ class Se {
1037
1039
  constructor(t) {
1038
1040
  this.def = t;
1039
1041
  }
@@ -1041,17 +1043,17 @@ class Re {
1041
1043
  var a, c, u, h;
1042
1044
  const e = document.createElement("span");
1043
1045
  e.style.cssText = "display:flex;align-items:center;gap:5px;width:100%;padding:0 4px;box-sizing:border-box;";
1044
- const s = ((a = this.def) == null ? void 0 : a.max) ?? 100, i = Number(t.value) || 0, o = Math.min(100, Math.max(0, i / s * 100)), n = (c = this.def) != null && c.colorFn ? this.def.colorFn(i) : ((u = this.def) == null ? void 0 : u.color) ?? "var(--og-primary,#1976d2)", r = document.createElement("div");
1046
+ const s = ((a = this.def) == null ? void 0 : a.max) ?? 100, o = Number(t.value) || 0, i = Math.min(100, Math.max(0, o / s * 100)), n = (c = this.def) != null && c.colorFn ? this.def.colorFn(o) : ((u = this.def) == null ? void 0 : u.color) ?? "var(--og-primary,#1976d2)", r = document.createElement("div");
1045
1047
  r.className = "og-progress-track", r.style.cssText = "flex:1;height:10px;background:#e0e0e0;border-radius:5px;overflow:hidden;";
1046
1048
  const l = document.createElement("div");
1047
- if (l.className = "og-progress-fill", l.style.cssText = `width:${o}%;height:100%;background:${n};border-radius:5px;`, r.appendChild(l), e.appendChild(r), ((h = this.def) == null ? void 0 : h.showLabel) !== !1) {
1049
+ if (l.className = "og-progress-fill", l.style.cssText = `width:${i}%;height:100%;background:${n};border-radius:5px;`, r.appendChild(l), e.appendChild(r), ((h = this.def) == null ? void 0 : h.showLabel) !== !1) {
1048
1050
  const g = document.createElement("span");
1049
- g.style.cssText = "font-size:11px;color:#666;white-space:nowrap;min-width:28px;text-align:right;", g.textContent = `${Math.round(o)}%`, e.appendChild(g);
1051
+ g.style.cssText = "font-size:11px;color:#666;white-space:nowrap;min-width:28px;text-align:right;", g.textContent = `${Math.round(i)}%`, e.appendChild(g);
1050
1052
  }
1051
1053
  return e;
1052
1054
  }
1053
1055
  }
1054
- class Ee {
1056
+ class Le {
1055
1057
  constructor(t) {
1056
1058
  this.def = t;
1057
1059
  }
@@ -1062,43 +1064,43 @@ class Ee {
1062
1064
  const s = Array.isArray(t.value) ? t.value.map(Number) : [];
1063
1065
  if (!s.length)
1064
1066
  return e.textContent = "-", e;
1065
- const i = ((c = this.def) == null ? void 0 : c.width) ?? 80, o = ((u = this.def) == null ? void 0 : u.height) ?? 22, n = ((h = this.def) == null ? void 0 : h.color) ?? "#1976d2", r = ((g = this.def) == null ? void 0 : g.chartType) ?? "bar", l = document.createElement("canvas");
1066
- l.width = i, l.height = o, l.style.cssText = "display:block;";
1067
+ const o = ((c = this.def) == null ? void 0 : c.width) ?? 80, i = ((u = this.def) == null ? void 0 : u.height) ?? 22, n = ((h = this.def) == null ? void 0 : h.color) ?? "#1976d2", r = ((g = this.def) == null ? void 0 : g.chartType) ?? "bar", l = document.createElement("canvas");
1068
+ l.width = o, l.height = i, l.style.cssText = "display:block;";
1067
1069
  const a = l.getContext("2d");
1068
1070
  if (a) {
1069
- const k = Math.max(...s, 1), m = Math.min(...s, 0), w = k - m || 1, x = s.length;
1071
+ const k = Math.max(...s, 1), y = Math.min(...s, 0), b = k - y || 1, x = s.length;
1070
1072
  if (r === "bar") {
1071
- const _ = i / x;
1072
- s.forEach((b, L) => {
1073
- const v = (b - m) / w * (o - 2);
1074
- a.fillStyle = n, a.fillRect(L * _ + 1, o - v - 1, _ - 2, v);
1073
+ const p = o / x;
1074
+ s.forEach((v, T) => {
1075
+ const A = (v - y) / b * (i - 2);
1076
+ a.fillStyle = n, a.fillRect(T * p + 1, i - A - 1, p - 2, A);
1075
1077
  });
1076
1078
  } else {
1077
- const _ = s.map((b, L) => ({
1078
- x: L / (x - 1 || 1) * i,
1079
- y: o - (b - m) / w * (o - 4) - 2
1079
+ const p = s.map((v, T) => ({
1080
+ x: T / (x - 1 || 1) * o,
1081
+ y: i - (v - y) / b * (i - 4) - 2
1080
1082
  }));
1081
- r === "area" && (a.fillStyle = n + "33", a.beginPath(), a.moveTo(_[0].x, o), _.forEach((b) => a.lineTo(b.x, b.y)), a.lineTo(_[_.length - 1].x, o), a.closePath(), a.fill()), a.strokeStyle = n, a.lineWidth = 1.5, a.beginPath(), _.forEach((b, L) => L === 0 ? a.moveTo(b.x, b.y) : a.lineTo(b.x, b.y)), a.stroke();
1083
+ r === "area" && (a.fillStyle = n + "33", a.beginPath(), a.moveTo(p[0].x, i), p.forEach((v) => a.lineTo(v.x, v.y)), a.lineTo(p[p.length - 1].x, i), a.closePath(), a.fill()), a.strokeStyle = n, a.lineWidth = 1.5, a.beginPath(), p.forEach((v, T) => T === 0 ? a.moveTo(v.x, v.y) : a.lineTo(v.x, v.y)), a.stroke();
1082
1084
  }
1083
1085
  }
1084
1086
  return e.appendChild(l), e;
1085
1087
  }
1086
1088
  }
1087
- class $t {
1089
+ class Ht {
1088
1090
  render(t) {
1089
1091
  const e = document.createElement("span");
1090
1092
  e.style.cssText = "display:flex;align-items:center;justify-content:center;height:100%;";
1091
- const s = !!t.value, i = document.createElement("span");
1092
- i.className = "og-switch" + (s ? " og-switch--on" : ""), i.style.cssText = `display:inline-block;width:34px;height:18px;border-radius:9px;
1093
+ const s = !!t.value, o = document.createElement("span");
1094
+ o.className = "og-switch" + (s ? " og-switch--on" : ""), o.style.cssText = `display:inline-block;width:34px;height:18px;border-radius:9px;
1093
1095
  background:${s ? "var(--og-primary,#1976d2)" : "#bdbdbd"};
1094
1096
  position:relative;transition:background 0.2s;cursor:pointer;flex-shrink:0;pointer-events:none;`;
1095
- const o = document.createElement("span");
1096
- return o.style.cssText = `position:absolute;top:2px;left:${s ? "16px" : "2px"};
1097
+ const i = document.createElement("span");
1098
+ return i.style.cssText = `position:absolute;top:2px;left:${s ? "16px" : "2px"};
1097
1099
  width:14px;height:14px;border-radius:50%;background:#fff;
1098
- transition:left 0.2s;box-shadow:0 1px 3px rgba(0,0,0,0.3);`, i.appendChild(o), e.appendChild(i), e;
1100
+ transition:left 0.2s;box-shadow:0 1px 3px rgba(0,0,0,0.3);`, o.appendChild(i), e.appendChild(o), e;
1099
1101
  }
1100
1102
  }
1101
- class Se {
1103
+ class Te {
1102
1104
  constructor(t) {
1103
1105
  this.def = t;
1104
1106
  }
@@ -1106,15 +1108,15 @@ class Se {
1106
1108
  var n, r;
1107
1109
  const e = document.createElement("span");
1108
1110
  e.style.cssText = "display:flex;align-items:center;gap:1px;height:100%;";
1109
- const s = ((n = this.def) == null ? void 0 : n.max) ?? 5, i = Math.round(Number(t.value) || 0), o = ((r = this.def) == null ? void 0 : r.color) ?? "#ffa000";
1111
+ const s = ((n = this.def) == null ? void 0 : n.max) ?? 5, o = Math.round(Number(t.value) || 0), i = ((r = this.def) == null ? void 0 : r.color) ?? "#ffa000";
1110
1112
  for (let l = 1; l <= s; l++) {
1111
1113
  const a = document.createElement("span");
1112
- a.textContent = "★", a.style.cssText = `font-size:14px;color:${l <= i ? o : "#e0e0e0"};line-height:1;`, e.appendChild(a);
1114
+ a.textContent = "★", a.style.cssText = `font-size:14px;color:${l <= o ? i : "#e0e0e0"};line-height:1;`, e.appendChild(a);
1113
1115
  }
1114
1116
  return e;
1115
1117
  }
1116
1118
  }
1117
- class ft {
1119
+ class mt {
1118
1120
  render(t) {
1119
1121
  const e = document.createElement("span");
1120
1122
  e.style.cssText = "display:flex;align-items:center;justify-content:center;height:100%;pointer-events:none;";
@@ -1122,7 +1124,7 @@ class ft {
1122
1124
  return s.type = "radio", s.checked = !!t.value, s.setAttribute("aria-checked", t.value ? "true" : "false"), s.setAttribute("aria-label", t.column.header ?? "선택"), t.column.group && (s.name = `og-radio-${t.rowIndex}-${t.column.group}`), s.style.cssText = "width:14px;height:14px;cursor:pointer;accent-color:var(--og-primary,#1976d2);", e.appendChild(s), e;
1123
1125
  }
1124
1126
  }
1125
- class mt {
1127
+ class yt {
1126
1128
  render(t) {
1127
1129
  const e = document.createElement("span");
1128
1130
  if (e.style.cssText = "display:flex;align-items:center;justify-content:center;height:100%;overflow:hidden;", !t.value) return e;
@@ -1130,7 +1132,7 @@ class mt {
1130
1132
  return s.src = String(t.value), s.alt = t.column.alt ?? t.column.field, s.style.cssText = "max-width:100%;max-height:100%;object-fit:contain;display:block;", s.setAttribute("role", "img"), e.appendChild(s), e;
1131
1133
  }
1132
1134
  }
1133
- function Le(d) {
1135
+ function Fe(d) {
1134
1136
  const t = document.createElement("div");
1135
1137
  return t.innerHTML = d, t.querySelectorAll("script,iframe,object,embed").forEach((e) => e.remove()), t.querySelectorAll("*").forEach((e) => {
1136
1138
  for (const s of [...e.attributes])
@@ -1141,15 +1143,15 @@ function Le(d) {
1141
1143
  }
1142
1144
  }), t.innerHTML;
1143
1145
  }
1144
- class yt {
1146
+ class wt {
1145
1147
  render(t) {
1146
1148
  const e = document.createElement("span");
1147
1149
  e.style.cssText = "display:block;overflow:hidden;width:100%;";
1148
- const s = t.column.sanitize !== !1, i = String(t.value ?? "");
1149
- return e.innerHTML = s ? Le(i) : i, e;
1150
+ const s = t.column.sanitize !== !1, o = String(t.value ?? "");
1151
+ return e.innerHTML = s ? Fe(o) : o, e;
1150
1152
  }
1151
1153
  }
1152
- const Fe = [
1154
+ const De = [
1153
1155
  "212222",
1154
1156
  "222122",
1155
1157
  "222221",
@@ -1270,35 +1272,35 @@ const Fe = [
1270
1272
  "211214",
1271
1273
  "211232"
1272
1274
  // 104 (Start B), 105 (Start C)
1273
- ], Te = "2331112";
1274
- function At(d) {
1275
+ ], $e = "2331112";
1276
+ function zt(d) {
1275
1277
  let t = "", e = !0;
1276
1278
  for (const s of d)
1277
1279
  t += (e ? "1" : "0").repeat(+s), e = !e;
1278
1280
  return t;
1279
1281
  }
1280
- function De(d) {
1282
+ function Ae(d) {
1281
1283
  const t = [104];
1282
1284
  for (const s of d) {
1283
- const i = s.charCodeAt(0) - 32;
1284
- i >= 0 && i <= 94 && t.push(i);
1285
+ const o = s.charCodeAt(0) - 32;
1286
+ o >= 0 && o <= 94 && t.push(o);
1285
1287
  }
1286
1288
  let e = 104;
1287
1289
  for (let s = 1; s < t.length; s++) e += t[s] * s;
1288
- return t.push(e % 103), t.map((s) => At(Fe[s])).join("") + At(Te) + "11";
1290
+ return t.push(e % 103), t.map((s) => zt(De[s])).join("") + zt($e) + "11";
1289
1291
  }
1290
- class wt {
1292
+ class bt {
1291
1293
  render(t) {
1292
- const e = String(t.value ?? ""), s = t.column.barcodeHeight ?? 28, i = document.createElement("div");
1293
- i.style.cssText = "display:flex;flex-direction:column;align-items:center;justify-content:center;height:100%;overflow:hidden;gap:1px;", i.setAttribute("role", "img"), i.setAttribute("aria-label", `바코드: ${e}`), i.innerHTML = $e(e, s);
1294
- const o = document.createElement("span");
1295
- return o.textContent = e, o.style.cssText = "font-size:9px;font-family:monospace;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100%;", i.appendChild(o), i;
1294
+ const e = String(t.value ?? ""), s = t.column.barcodeHeight ?? 28, o = document.createElement("div");
1295
+ o.style.cssText = "display:flex;flex-direction:column;align-items:center;justify-content:center;height:100%;overflow:hidden;gap:1px;", o.setAttribute("role", "img"), o.setAttribute("aria-label", `바코드: ${e}`), o.innerHTML = He(e, s);
1296
+ const i = document.createElement("span");
1297
+ return i.textContent = e, i.style.cssText = "font-size:9px;font-family:monospace;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100%;", o.appendChild(i), o;
1296
1298
  }
1297
1299
  }
1298
- function $e(d, t) {
1300
+ function He(d, t) {
1299
1301
  if (!d) return "";
1300
- const e = De(d), s = 1.4, i = 6, o = e.length * s + i * 2, n = [];
1301
- let r = 0, l = i;
1302
+ const e = Ae(d), s = 1.4, o = 6, i = e.length * s + o * 2, n = [];
1303
+ let r = 0, l = o;
1302
1304
  for (; r < e.length; )
1303
1305
  if (e[r] === "1") {
1304
1306
  let a = 0;
@@ -1306,96 +1308,96 @@ function $e(d, t) {
1306
1308
  n.push(`<rect x="${l.toFixed(2)}" y="0" width="${(a * s).toFixed(2)}" height="${t}"/>`), l += a * s, r += a;
1307
1309
  } else
1308
1310
  l += s, r++;
1309
- return `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${o.toFixed(2)} ${t}" width="${o.toFixed(2)}" height="${t}" style="display:block" aria-hidden="true"><g fill="currentColor">${n.join("")}</g></svg>`;
1311
+ return `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${i.toFixed(2)} ${t}" width="${i.toFixed(2)}" height="${t}" style="display:block" aria-hidden="true"><g fill="currentColor">${n.join("")}</g></svg>`;
1310
1312
  }
1311
- function Ae(d) {
1313
+ function ze(d) {
1312
1314
  const t = d.renderer;
1313
1315
  if (!t)
1314
1316
  switch (d.type) {
1315
1317
  case "number":
1316
- return new gt();
1317
- case "date":
1318
1318
  return new pt();
1319
- case "boolean":
1319
+ case "date":
1320
1320
  return new _t();
1321
- case "radio":
1321
+ case "boolean":
1322
1322
  return new ft();
1323
- case "img":
1323
+ case "radio":
1324
1324
  return new mt();
1325
- case "html":
1325
+ case "img":
1326
1326
  return new yt();
1327
- case "barcode":
1327
+ case "html":
1328
1328
  return new wt();
1329
+ case "barcode":
1330
+ return new bt();
1329
1331
  case "select":
1330
- return new Ce(d.options ?? [], d.optionsFn);
1332
+ return new ke(d.options ?? [], d.optionsFn);
1331
1333
  default:
1332
- return new ut();
1334
+ return new gt();
1333
1335
  }
1334
1336
  if (typeof t == "string")
1335
1337
  switch (t) {
1336
1338
  case "number":
1337
- return new gt();
1338
- case "date":
1339
1339
  return new pt();
1340
- case "checkbox":
1340
+ case "date":
1341
1341
  return new _t();
1342
+ case "checkbox":
1343
+ return new ft();
1342
1344
  case "button":
1343
- return new Ft();
1344
- case "link":
1345
1345
  return new Dt();
1346
+ case "link":
1347
+ return new At();
1346
1348
  case "badge":
1347
- return new Tt();
1348
- case "switch":
1349
1349
  return new $t();
1350
+ case "switch":
1351
+ return new Ht();
1350
1352
  case "radio":
1351
- return new ft();
1352
- case "img":
1353
1353
  return new mt();
1354
- case "html":
1354
+ case "img":
1355
1355
  return new yt();
1356
- case "barcode":
1356
+ case "html":
1357
1357
  return new wt();
1358
+ case "barcode":
1359
+ return new bt();
1358
1360
  default:
1359
- return new ut();
1361
+ return new gt();
1360
1362
  }
1361
1363
  switch (t.type) {
1362
1364
  case "button":
1363
- return new Ft(t);
1365
+ return new Dt(t);
1364
1366
  case "checkbox":
1365
- return new _t();
1367
+ return new ft();
1366
1368
  case "link":
1367
- return new Dt(t.hrefFn, t.target);
1369
+ return new At(t.hrefFn, t.target);
1368
1370
  case "template":
1369
- return new Me(t.templateFn);
1371
+ return new Re(t.templateFn);
1370
1372
  case "badge":
1371
- return new Tt(t.colorMap, t.labelMap ?? t.valueMap);
1373
+ return new $t(t.colorMap, t.labelMap ?? t.valueMap);
1372
1374
  case "image":
1373
- return new ke(t);
1375
+ return new Ee(t);
1374
1376
  case "progress":
1375
- return new Re(t);
1377
+ return new Se(t);
1376
1378
  case "sparkline":
1377
- return new Ee(t);
1379
+ return new Le(t);
1378
1380
  case "switch":
1379
- return new $t();
1381
+ return new Ht();
1380
1382
  case "rating":
1381
- return new Se(t);
1383
+ return new Te(t);
1382
1384
  case "number":
1383
- return new gt();
1384
- case "date":
1385
1385
  return new pt();
1386
+ case "date":
1387
+ return new _t();
1386
1388
  case "radio":
1387
- return new ft();
1388
- case "img":
1389
1389
  return new mt();
1390
- case "html":
1390
+ case "img":
1391
1391
  return new yt();
1392
- case "barcode":
1392
+ case "html":
1393
1393
  return new wt();
1394
+ case "barcode":
1395
+ return new bt();
1394
1396
  default:
1395
- return new ut();
1397
+ return new gt();
1396
1398
  }
1397
1399
  }
1398
- class He {
1400
+ class Ie {
1399
1401
  constructor(t, e, s) {
1400
1402
  this._cellMap = /* @__PURE__ */ new Map(), this._root = t, this._opts = e, this._cbs = s, this._header = D("div", "og-header"), this._header.style.cssText = "flex-shrink:0;overflow-x:auto;overflow-y:hidden;border:0;border-bottom:1px solid var(--og-border-color,#e0e0e0);scrollbar-width:none;", this._bodyWrap = D("div", "og-body-wrapper"), this._bodyWrap.style.cssText = "flex:1;overflow:auto;position:relative;", this._bodyWrap.style.setProperty("--scrollbar-size", "8px"), this._body = D("div", "og-body"), this._body.style.cssText = "position:relative;", this._bodyWrap.appendChild(this._body), t.appendChild(this._header), t.appendChild(this._bodyWrap), this._bodyWrap.addEventListener("scroll", () => {
1401
1403
  this._header.scrollLeft = this._bodyWrap.scrollLeft;
@@ -1411,23 +1413,23 @@ class He {
1411
1413
  getHeaderHeight() {
1412
1414
  return this._header.offsetHeight;
1413
1415
  }
1414
- renderHeader(t, e, s, i, o) {
1416
+ renderHeader(t, e, s, o, i) {
1415
1417
  var g, k;
1416
1418
  this._header.innerHTML = "";
1417
- const n = o._frozenCount ?? 0;
1419
+ const n = i._frozenCount ?? 0;
1418
1420
  let r = 0;
1419
- o.stateColumn && (r += 24), o.draggable && (r += 18), o.rowNumber && (r += 44), o.checkColumn && (r += 36);
1420
- const l = r + e.reduce((m, w, x) => m + (s[x] ?? o.defaultColumnWidth), 0);
1421
+ i.stateColumn && (r += 24), i.draggable && (r += 18), i.rowNumber && (r += 44), i.checkColumn && (r += 36);
1422
+ const l = r + e.reduce((y, b, x) => y + (s[x] ?? i.defaultColumnWidth), 0);
1421
1423
  this._header.style.background = "var(--og-header-bg,#f5f5f5)";
1422
1424
  const a = D("table", "og-header-table");
1423
1425
  a.setAttribute("role", "presentation"), a.style.cssText = `table-layout:fixed;border-collapse:collapse;border-spacing:0;margin:0;width:${l}px;background:var(--og-header-bg,#f5f5f5);`;
1424
1426
  const c = t.length;
1425
1427
  let u = 0;
1426
- const h = (m, w, x, _ = "") => {
1427
- const b = D("th", `og-header-cell og-extra-col ${_}`);
1428
- b.setAttribute("rowspan", String(c)), b.textContent = x, zt(b, {
1429
- width: `${w}px`,
1430
- minWidth: `${w}px`,
1428
+ const h = (y, b, x, p = "") => {
1429
+ const v = D("th", `og-header-cell og-extra-col ${p}`);
1430
+ v.setAttribute("rowspan", String(c)), v.textContent = x, Bt(v, {
1431
+ width: `${b}px`,
1432
+ minWidth: `${b}px`,
1431
1433
  textAlign: "center",
1432
1434
  borderRight: "1px solid var(--og-border-color,#e0e0e0)",
1433
1435
  borderBottom: "1px solid var(--og-border-color,#e0e0e0)",
@@ -1442,46 +1444,46 @@ class He {
1442
1444
  userSelect: "none",
1443
1445
  boxSizing: "border-box",
1444
1446
  background: "var(--og-header-bg,#f5f5f5)"
1445
- }), n > 0 && (b.style.position = "sticky", b.style.left = `${u}px`, b.style.zIndex = "4"), u += w, m.appendChild(b);
1447
+ }), n > 0 && (v.style.position = "sticky", v.style.left = `${u}px`, v.style.zIndex = "4"), u += b, y.appendChild(v);
1446
1448
  };
1447
- for (let m = 0; m < t.length; m++) {
1448
- const w = D("tr", "og-header-row");
1449
- if (w.style.height = `${o.headerHeight}px`, m === 0 && (o.stateColumn && h(w, 24, ""), o.draggable && h(w, 18, ""), o.rowNumber && h(w, 44, "No"), o.checkColumn)) {
1449
+ for (let y = 0; y < t.length; y++) {
1450
+ const b = D("tr", "og-header-row");
1451
+ if (b.style.height = `${i.headerHeight}px`, y === 0 && (i.stateColumn && h(b, 24, ""), i.draggable && h(b, 18, ""), i.rowNumber && h(b, 44, "No"), i.checkColumn)) {
1450
1452
  const x = D("th", "og-header-cell og-extra-col");
1451
1453
  x.setAttribute("rowspan", String(c)), x.style.cssText = "width:36px;min-width:36px;text-align:center;border-right:1px solid var(--og-border-color,#e0e0e0);border-bottom:1px solid var(--og-border-color,#e0e0e0);border-top:0;border-left:0;line-height:normal;vertical-align:middle;background:var(--og-header-bg,#f5f5f5);box-sizing:border-box;", n > 0 && (x.style.position = "sticky", x.style.left = `${u}px`, x.style.zIndex = "4"), u += 36;
1452
- const _ = document.createElement("input");
1453
- _.type = "checkbox", _.setAttribute("aria-label", "전체 행 선택"), _.style.cssText = "width:16px;height:16px;", _.addEventListener("change", () => this._cbs.onAllCheck(_.checked)), x.appendChild(_), w.appendChild(x);
1454
+ const p = document.createElement("input");
1455
+ p.type = "checkbox", p.setAttribute("aria-label", "전체 행 선택"), p.style.cssText = "width:16px;height:16px;", p.addEventListener("change", () => this._cbs.onAllCheck(p.checked)), x.appendChild(p), b.appendChild(x);
1454
1456
  }
1455
- for (const x of t[m] ?? []) {
1456
- const _ = D("th", "og-header-cell"), b = x.column;
1457
- x.colSpan > 1 && (_.colSpan = x.colSpan), x.rowSpan > 1 && (_.rowSpan = x.rowSpan);
1458
- const L = x.colSpan === 1 ? e.findIndex((p) => p.field === b.field) : -1;
1457
+ for (const x of t[y] ?? []) {
1458
+ const p = D("th", "og-header-cell"), v = x.column;
1459
+ x.colSpan > 1 && (p.colSpan = x.colSpan), x.rowSpan > 1 && (p.rowSpan = x.rowSpan);
1460
+ const T = x.colSpan === 1 ? e.findIndex((_) => _.field === v.field) : -1;
1459
1461
  if (x.colSpan === 1) {
1460
- const p = L >= 0 ? s[L] ?? o.defaultColumnWidth : b.width ?? o.defaultColumnWidth;
1461
- _.style.width = `${p}px`, _.style.minWidth = `${p}px`;
1462
+ const _ = T >= 0 ? s[T] ?? i.defaultColumnWidth : v.width ?? i.defaultColumnWidth;
1463
+ p.style.width = `${_}px`, p.style.minWidth = `${_}px`;
1462
1464
  }
1463
- const v = i.find((p) => p.field === b.field), R = b.sortable !== !1 && o.sortable && x.colSpan === 1;
1464
- if (_.setAttribute("role", "columnheader"), _.setAttribute("scope", "col"), R && (_.setAttribute("aria-sort", v ? v.dir === "asc" ? "ascending" : "descending" : "none"), _.tabIndex = L === 0 ? 0 : -1, _.addEventListener("keydown", (p) => {
1465
- if (p.key === "Enter" || p.key === " ")
1466
- p.preventDefault(), this._cbs.onHeaderClick(b.field, p.shiftKey);
1467
- else if (p.key === "ArrowRight") {
1468
- p.preventDefault();
1469
- const C = _.nextElementSibling;
1470
- (C == null ? void 0 : C.tagName) === "TH" && C.focus();
1471
- } else if (p.key === "ArrowLeft") {
1472
- p.preventDefault();
1473
- const C = _.previousElementSibling;
1474
- (C == null ? void 0 : C.tagName) === "TH" && C.focus();
1465
+ const A = o.find((_) => _.field === v.field), E = v.sortable !== !1 && i.sortable && x.colSpan === 1;
1466
+ if (p.setAttribute("role", "columnheader"), p.setAttribute("scope", "col"), E && (p.setAttribute("aria-sort", A ? A.dir === "asc" ? "ascending" : "descending" : "none"), p.tabIndex = T === 0 ? 0 : -1, p.addEventListener("keydown", (_) => {
1467
+ if (_.key === "Enter" || _.key === " ")
1468
+ _.preventDefault(), this._cbs.onHeaderClick(v.field, _.shiftKey);
1469
+ else if (_.key === "ArrowRight") {
1470
+ _.preventDefault();
1471
+ const M = p.nextElementSibling;
1472
+ (M == null ? void 0 : M.tagName) === "TH" && M.focus();
1473
+ } else if (_.key === "ArrowLeft") {
1474
+ _.preventDefault();
1475
+ const M = p.previousElementSibling;
1476
+ (M == null ? void 0 : M.tagName) === "TH" && M.focus();
1475
1477
  }
1476
- })), L >= 0 && L < n) {
1477
- let p = 0;
1478
- o.stateColumn && (p += 24), o.draggable && (p += 18), o.rowNumber && (p += 44), o.checkColumn && (p += 36);
1479
- for (let C = 0; C < L; C++) p += s[C] ?? o.defaultColumnWidth;
1480
- _.classList.add("og-frozen"), L === n - 1 && _.classList.add("og-frozen-last"), _.style.left = `${p}px`;
1478
+ })), T >= 0 && T < n) {
1479
+ let _ = 0;
1480
+ i.stateColumn && (_ += 24), i.draggable && (_ += 18), i.rowNumber && (_ += 44), i.checkColumn && (_ += 36);
1481
+ for (let M = 0; M < T; M++) _ += s[M] ?? i.defaultColumnWidth;
1482
+ p.classList.add("og-frozen"), T === n - 1 && p.classList.add("og-frozen-last"), p.style.left = `${_}px`;
1481
1483
  }
1482
- const F = b.header ?? b.field, I = typeof F == "string" && F.indexOf(`
1483
- `) >= 0, T = b.headerWrap === !0 || I;
1484
- zt(_, {
1484
+ const f = v.header ?? v.field, $ = typeof f == "string" && f.indexOf(`
1485
+ `) >= 0, B = v.headerWrap === !0 || $;
1486
+ Bt(p, {
1485
1487
  padding: "4px 8px",
1486
1488
  boxSizing: "border-box",
1487
1489
  // host isolation: 헤더 <th> 의 모든 시각 속성을 인라인으로 고정한다.
@@ -1490,283 +1492,284 @@ class He {
1490
1492
  // (var 참조라 setTheme 시 자동 반영. text-align/padding 은 그리드 의도값 유지)
1491
1493
  background: "var(--og-header-bg)",
1492
1494
  color: "var(--og-header-color)",
1493
- lineHeight: T ? "1.3" : "normal",
1495
+ lineHeight: B ? "1.3" : "normal",
1494
1496
  verticalAlign: "middle",
1495
1497
  fontSize: "var(--og-font-size)",
1496
- textAlign: b.headerAlign ?? "center",
1498
+ textAlign: v.headerAlign ?? "center",
1497
1499
  borderTop: "0",
1498
1500
  borderLeft: "0",
1499
1501
  borderRight: "1px solid var(--og-border-color,#e0e0e0)",
1500
1502
  borderBottom: "1px solid var(--og-border-color,#e0e0e0)",
1501
1503
  userSelect: "none",
1502
- cursor: R ? "pointer" : "default",
1504
+ cursor: E ? "pointer" : "default",
1503
1505
  // 줄바꿈 컬럼: nowrap+ellipsis 대신 여러 줄 허용(word-break). 미설정 컬럼은 기존 동작 유지.
1504
- whiteSpace: T ? "normal" : "nowrap",
1505
- overflow: T ? "visible" : "hidden",
1506
- textOverflow: T ? "clip" : "ellipsis",
1507
- wordBreak: T ? "break-word" : "normal",
1506
+ whiteSpace: B ? "normal" : "nowrap",
1507
+ overflow: B ? "visible" : "hidden",
1508
+ textOverflow: B ? "clip" : "ellipsis",
1509
+ wordBreak: B ? "break-word" : "normal",
1508
1510
  position: "relative"
1509
- }), _.title = (typeof b.tooltip == "string" ? b.tooltip : F) ?? "";
1510
- const A = D("span");
1511
- if (T ? (A.style.cssText = "overflow:visible;text-overflow:clip;white-space:normal;word-break:break-word;", String(F).split(`
1512
- `).forEach((C, O) => {
1513
- O > 0 && A.appendChild(document.createElement("br")), A.appendChild(document.createTextNode(C));
1514
- })) : (A.textContent = F, A.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;"), _.appendChild(A), v) {
1515
- _.classList.add("og-sorted");
1516
- const p = D("span", "og-sort-icon");
1517
- p.textContent = v.dir === "asc" ? " ↑" : " ↓", _.appendChild(p);
1511
+ }), p.title = (typeof v.tooltip == "string" ? v.tooltip : f) ?? "";
1512
+ const z = D("span");
1513
+ if (B ? (z.style.cssText = "overflow:visible;text-overflow:clip;white-space:normal;word-break:break-word;", String(f).split(`
1514
+ `).forEach((M, F) => {
1515
+ F > 0 && z.appendChild(document.createElement("br")), z.appendChild(document.createTextNode(M));
1516
+ })) : (z.textContent = f, z.style.cssText = "overflow:hidden;text-overflow:ellipsis;white-space:nowrap;"), p.appendChild(z), A) {
1517
+ p.classList.add("og-sorted");
1518
+ const _ = D("span", "og-sort-icon");
1519
+ _.textContent = A.dir === "asc" ? " ↑" : " ↓", p.appendChild(_);
1518
1520
  }
1519
- if (b.filterable !== !1 && o.filterable && x.colSpan === 1) {
1520
- const p = D("span", "og-filter-icon"), C = ((k = (g = o._activeFilters) == null ? void 0 : g[b.field]) == null ? void 0 : k.length) > 0;
1521
- p.textContent = C ? "⊿" : "▿", p.title = "필터", p.style.cssText = "margin-left:3px;cursor:pointer;font-size:10px;opacity:0.6;", C && p.classList.add("og-filter-icon--active"), p.addEventListener("click", (O) => {
1522
- O.stopPropagation(), this._cbs.onFilterIconClick(b.field, p);
1523
- }), _.appendChild(p);
1521
+ if (v.filterable !== !1 && i.filterable && x.colSpan === 1) {
1522
+ const _ = D("span", "og-filter-icon"), M = ((k = (g = i._activeFilters) == null ? void 0 : g[v.field]) == null ? void 0 : k.length) > 0;
1523
+ _.textContent = M ? "⊿" : "▿", _.title = "필터", _.style.cssText = "margin-left:3px;cursor:pointer;font-size:10px;opacity:0.6;", M && _.classList.add("og-filter-icon--active"), _.addEventListener("click", (F) => {
1524
+ F.stopPropagation(), this._cbs.onFilterIconClick(v.field, _);
1525
+ }), p.appendChild(_);
1524
1526
  }
1525
- if (b.resizable !== !1) {
1526
- const p = D("div", "og-resize-handle");
1527
- p.style.cssText = "position:absolute;right:0;top:0;bottom:0;width:4px;cursor:col-resize;z-index:1;", _.appendChild(p);
1528
- const C = L;
1529
- ze(p, _, (O) => {
1530
- C >= 0 && this._cbs.onColResize(C, O);
1527
+ if (v.resizable !== !1) {
1528
+ const _ = D("div", "og-resize-handle");
1529
+ _.style.cssText = "position:absolute;right:0;top:0;bottom:0;width:4px;cursor:col-resize;z-index:1;", p.appendChild(_);
1530
+ const M = T;
1531
+ Be(_, p, (F) => {
1532
+ M >= 0 && this._cbs.onColResize(M, F);
1531
1533
  });
1532
1534
  }
1533
- o.columnReorder && L >= 0 && x.colSpan === 1 && (_.draggable = !0, _.addEventListener("dragstart", (p) => {
1534
- var C;
1535
- this._cbs.onColDragStart(L), _.classList.add("og-col-dragging"), (C = p.dataTransfer) == null || C.setData("text/plain", String(L));
1536
- }), _.addEventListener("dragend", () => {
1537
- _.classList.remove("og-col-dragging"), this._header.querySelectorAll(".og-col-drop-over").forEach((p) => p.classList.remove("og-col-drop-over"));
1538
- }), _.addEventListener("dragover", (p) => {
1539
- p.preventDefault();
1540
- const C = this._cbs.getColDragIdx();
1541
- C !== null && C !== L && (this._header.querySelectorAll(".og-col-drop-over").forEach((O) => O.classList.remove("og-col-drop-over")), _.classList.add("og-col-drop-over"));
1542
- }), _.addEventListener("dragleave", () => {
1543
- _.classList.remove("og-col-drop-over");
1544
- }), _.addEventListener("drop", (p) => {
1545
- p.preventDefault(), _.classList.remove("og-col-drop-over"), this._cbs.onColDrop(L);
1546
- })), R && _.addEventListener("click", (p) => {
1547
- p.target.classList.contains("og-resize-handle") || this._cbs.onHeaderClick(b.field, p.shiftKey);
1548
- }), w.appendChild(_);
1535
+ i.columnReorder && T >= 0 && x.colSpan === 1 && (p.draggable = !0, p.addEventListener("dragstart", (_) => {
1536
+ var M;
1537
+ this._cbs.onColDragStart(T), p.classList.add("og-col-dragging"), (M = _.dataTransfer) == null || M.setData("text/plain", String(T));
1538
+ }), p.addEventListener("dragend", () => {
1539
+ p.classList.remove("og-col-dragging"), this._header.querySelectorAll(".og-col-drop-over").forEach((_) => _.classList.remove("og-col-drop-over"));
1540
+ }), p.addEventListener("dragover", (_) => {
1541
+ _.preventDefault();
1542
+ const M = this._cbs.getColDragIdx();
1543
+ M !== null && M !== T && (this._header.querySelectorAll(".og-col-drop-over").forEach((F) => F.classList.remove("og-col-drop-over")), p.classList.add("og-col-drop-over"));
1544
+ }), p.addEventListener("dragleave", () => {
1545
+ p.classList.remove("og-col-drop-over");
1546
+ }), p.addEventListener("drop", (_) => {
1547
+ _.preventDefault(), p.classList.remove("og-col-drop-over"), this._cbs.onColDrop(T);
1548
+ })), E && p.addEventListener("click", (_) => {
1549
+ _.target.classList.contains("og-resize-handle") || this._cbs.onHeaderClick(v.field, _.shiftKey);
1550
+ }), b.appendChild(p);
1549
1551
  }
1550
- a.appendChild(w);
1552
+ a.appendChild(b);
1551
1553
  }
1552
1554
  this._header.appendChild(a);
1553
1555
  }
1554
- renderBody(t, e, s, i, o, n, r, l, a, c, u = null, h, g, k = {}, m) {
1555
- var b, L;
1556
+ renderBody(t, e, s, o, i, n, r, l, a, c, u = null, h, g, k = {}, y) {
1557
+ var v, T, A, E;
1556
1558
  Object.keys(k).length && (n = { ...n, ...k }), this._body.innerHTML = "", this._cellMap.clear();
1557
- const w = n.autoHeight === !0;
1558
- this._body.classList.toggle("og-autoheight", w), this._body.style.height = w ? "" : `${l}px`;
1559
+ const b = n.autoHeight === !0;
1560
+ this._body.classList.toggle("og-autoheight", b), this._body.style.height = b ? "" : `${l}px`;
1559
1561
  const x = n._frozenCount ?? 0;
1560
1562
  {
1561
- let v = 0;
1562
- n.stateColumn && (v += 24), n.draggable && (v += 18), n.rowNumber && (v += 44), n.checkColumn && (v += 36);
1563
- const R = v + i.reduce((F, I, T) => F + (o[T] ?? n.defaultColumnWidth), 0);
1564
- this._body.style.minWidth = `${R}px`;
1563
+ let f = 0;
1564
+ n.stateColumn && (f += 24), n.draggable && (f += 18), n.rowNumber && (f += 44), n.checkColumn && (f += 36);
1565
+ const $ = f + o.reduce((B, z, S) => B + (i[S] ?? n.defaultColumnWidth), 0);
1566
+ this._body.style.minWidth = `${$}px`;
1565
1567
  }
1566
1568
  if (e < t) return;
1567
- const _ = document.createDocumentFragment();
1568
- for (let v = t; v <= e; v++) {
1569
- const R = u ? u[v] : null, F = R && R._isGroup === !0, I = R && R._isTree === !0;
1570
- if (F) {
1571
- const f = R, S = `__${f._groupField}:${f._groupValue}`, H = D("div", "og-group-row"), tt = r + (v - t) * n.rowHeight;
1569
+ const p = document.createDocumentFragment();
1570
+ for (let f = t; f <= e; f++) {
1571
+ const $ = u ? u[f] : null, B = $ && $._isGroup === !0, z = $ && $._isTree === !0;
1572
+ if (B) {
1573
+ const m = $, L = `__${m._groupField}:${m._groupValue}`, H = D("div", "og-group-row"), at = r + (f - t) * n.rowHeight;
1572
1574
  H.style.cssText = [
1573
- w ? "" : `top:${tt}px;height:${n.rowHeight}px;`,
1575
+ b ? "" : `top:${at}px;height:${n.rowHeight}px;`,
1574
1576
  "display:flex;align-items:stretch;cursor:pointer;",
1575
- `padding-left:${4 + f._depth * 12}px;`,
1577
+ `padding-left:${4 + m._depth * 12}px;`,
1576
1578
  "background:var(--og-header-bg,#f5f5f5);",
1577
1579
  // host isolation: border:0 선행 (WP :where([style*=border-color]) 의 3px 강제 차단)
1578
1580
  "border:0;border-bottom:1px solid var(--og-border-color,#e0e0e0);"
1579
- ].join(""), H.setAttribute("role", "row"), H.setAttribute("aria-expanded", f._expanded ? "true" : "false"), H.setAttribute("aria-rowindex", String(v + 1)), H.setAttribute("aria-level", String(f._depth + 1));
1580
- let j = 0;
1581
- if (n.stateColumn && (j += 24), n.draggable && (j += 18), n.rowNumber && (j += 44), n.checkColumn && (j += 36), j > 0) {
1582
- const y = D("div", "og-group-state-cell");
1583
- y.style.cssText = [
1584
- `width:${j}px;min-width:${j}px;flex-shrink:0;`,
1581
+ ].join(""), H.setAttribute("role", "row"), H.setAttribute("aria-expanded", m._expanded ? "true" : "false"), H.setAttribute("aria-rowindex", String(f + 1)), H.setAttribute("aria-level", String(m._depth + 1));
1582
+ let G = 0;
1583
+ if (n.stateColumn && (G += 24), n.draggable && (G += 18), n.rowNumber && (G += 44), n.checkColumn && (G += 36), G > 0) {
1584
+ const w = D("div", "og-group-state-cell");
1585
+ w.style.cssText = [
1586
+ `width:${G}px;min-width:${G}px;flex-shrink:0;`,
1585
1587
  "display:flex;align-items:center;justify-content:center;",
1586
1588
  "font-size:10px;font-weight:700;gap:2px;",
1587
1589
  "border-right:1px solid var(--og-border-color,#e0e0e0);"
1588
1590
  ].join("");
1589
- const B = f._states ?? { added: 0, edited: 0, removed: 0 };
1590
- if (B.added > 0) {
1591
- const z = D("span");
1592
- z.textContent = `+${B.added}`, z.style.cssText = "color:var(--og-row-added-bg,#2e7d32);background:#e8f5e9;padding:1px 3px;border-radius:3px;", y.appendChild(z);
1591
+ const O = m._states ?? { added: 0, edited: 0, removed: 0 };
1592
+ if (O.added > 0) {
1593
+ const I = D("span");
1594
+ I.textContent = `+${O.added}`, I.style.cssText = "color:var(--og-row-added-bg,#2e7d32);background:#e8f5e9;padding:1px 3px;border-radius:3px;", w.appendChild(I);
1593
1595
  }
1594
- if (B.edited > 0) {
1595
- const z = D("span");
1596
- z.textContent = `M${B.edited}`, z.style.cssText = "color:#e65100;background:#fff8e1;padding:1px 3px;border-radius:3px;", y.appendChild(z);
1596
+ if (O.edited > 0) {
1597
+ const I = D("span");
1598
+ I.textContent = `M${O.edited}`, I.style.cssText = "color:#e65100;background:#fff8e1;padding:1px 3px;border-radius:3px;", w.appendChild(I);
1597
1599
  }
1598
- if (B.removed > 0) {
1599
- const z = D("span");
1600
- z.textContent = `D${B.removed}`, z.style.cssText = "color:var(--og-row-removed-bg,#c62828);background:#ffebee;padding:1px 3px;border-radius:3px;", y.appendChild(z);
1600
+ if (O.removed > 0) {
1601
+ const I = D("span");
1602
+ I.textContent = `D${O.removed}`, I.style.cssText = "color:var(--og-row-removed-bg,#c62828);background:#ffebee;padding:1px 3px;border-radius:3px;", w.appendChild(I);
1601
1603
  }
1602
- H.appendChild(y);
1604
+ H.appendChild(w);
1603
1605
  }
1604
- let P = !1;
1605
- for (let y = 0; y < i.length; y++) {
1606
- const B = i[y], z = o[y] ?? n.defaultColumnWidth, at = f._summaryFmt !== void 0 && B.field in (f._summaryFmt ?? {}), W = D("div", "og-group-cell");
1607
- if (W.style.cssText = [
1608
- `width:${z}px;min-width:${z}px;flex-shrink:0;`,
1606
+ let j = !1;
1607
+ for (let w = 0; w < o.length; w++) {
1608
+ const O = o[w], I = i[w] ?? n.defaultColumnWidth, dt = m._summaryFmt !== void 0 && O.field in (m._summaryFmt ?? {}), N = D("div", "og-group-cell");
1609
+ if (N.style.cssText = [
1610
+ `width:${I}px;min-width:${I}px;flex-shrink:0;`,
1609
1611
  "padding:2px 8px;box-sizing:border-box;overflow:hidden;",
1610
1612
  "border-right:1px solid var(--og-border-color,#e0e0e0);",
1611
1613
  "display:flex;align-items:center;",
1612
1614
  "white-space:nowrap;text-overflow:ellipsis;"
1613
- ].join(""), at) {
1614
- const U = f._summaryFmt[B.field];
1615
- W.textContent = U !== "" ? U : "-", W.style.justifyContent = "flex-end", W.style.color = "var(--og-primary,#1976d2)", W.style.fontWeight = "600";
1616
- } else if (!P) {
1617
- P = !0;
1618
- const U = D("span", "og-group-arrow");
1619
- U.textContent = f._expanded ? "▾ " : "▸ ", U.style.cssText = "color:var(--og-primary,#1976d2);margin-right:4px;flex-shrink:0;", W.appendChild(U);
1620
- const G = D("span", "og-group-label");
1621
- G.textContent = `${f._groupLabel} (${f._childCount}건)`, G.style.cssText = "overflow:hidden;text-overflow:ellipsis;font-weight:600;", W.appendChild(G), W.style.gap = "0";
1615
+ ].join(""), dt) {
1616
+ const q = m._summaryFmt[O.field];
1617
+ N.textContent = q !== "" ? q : "-", N.style.justifyContent = "flex-end", N.style.color = "var(--og-primary,#1976d2)", N.style.fontWeight = "600";
1618
+ } else if (!j) {
1619
+ j = !0;
1620
+ const q = D("span", "og-group-arrow");
1621
+ q.textContent = m._expanded ? "▾ " : "▸ ", q.style.cssText = "color:var(--og-primary,#1976d2);margin-right:4px;flex-shrink:0;", N.appendChild(q);
1622
+ const X = D("span", "og-group-label");
1623
+ X.textContent = `${m._groupLabel} (${m._childCount}건)`, X.style.cssText = "overflow:hidden;text-overflow:ellipsis;font-weight:600;", N.appendChild(X), N.style.gap = "0";
1622
1624
  }
1623
- H.appendChild(W);
1625
+ H.appendChild(N);
1624
1626
  }
1625
- H.addEventListener("click", () => h == null ? void 0 : h(S)), _.appendChild(H);
1627
+ H.addEventListener("click", () => h == null ? void 0 : h(L)), p.appendChild(H);
1626
1628
  continue;
1627
1629
  }
1628
- const T = I ? R : null, A = T ? T.data : u ? R : s.getRowByIndex(v);
1629
- if (!A) continue;
1630
- const $ = I || F ? "none" : s.getRowState(v), p = D("div", "og-row");
1631
- if (p.setAttribute("role", "row"), p.setAttribute("aria-rowindex", String(v + 1)), !w) {
1632
- const f = r + (v - t) * n.rowHeight;
1633
- p.style.top = `${f}px`, p.style.height = `${n.rowHeight}px`;
1630
+ const S = z ? $ : null, _ = S ? S.data : u ? $ : s.getRowByIndex(f);
1631
+ if (!_) continue;
1632
+ const M = z || B ? "none" : s.getRowState(f), F = D("div", "og-row");
1633
+ if (F.setAttribute("role", "row"), F.setAttribute("aria-rowindex", String(f + 1)), !b) {
1634
+ const m = r + (f - t) * n.rowHeight;
1635
+ F.style.top = `${m}px`, F.style.height = `${n.rowHeight}px`;
1634
1636
  }
1635
- let C = v % 2 === 0 ? "var(--og-row-bg,#fff)" : "var(--og-row-alt-bg,#fafafa)";
1636
- p.style.background = C, $ === "added" && p.classList.add("og-state-added"), $ === "edited" && p.classList.add("og-state-edited"), $ === "removed" && p.classList.add("og-state-removed"), a.has(v) && p.classList.add("og-selected"), p.setAttribute("aria-selected", a.has(v) ? "true" : "false"), $ === "added" && (C = "var(--og-row-added-bg,#e8f5e9)"), $ === "edited" && (C = "var(--og-row-edited-bg,#fff8e1)"), $ === "removed" && (C = "var(--og-row-removed-bg,#ffebee)"), a.has(v) && (C = "var(--og-row-selected-bg,#bbdefb)");
1637
- const O = v;
1638
- p.addEventListener("click", (f) => {
1639
- this._cbs.onCellClick(O, -1, f);
1637
+ let W = f % 2 === 0 ? "var(--og-row-bg,#fff)" : "var(--og-row-alt-bg,#fafafa)";
1638
+ F.style.background = W, M === "added" && F.classList.add("og-state-added"), M === "edited" && F.classList.add("og-state-edited"), M === "removed" && F.classList.add("og-state-removed"), a.has(f) && F.classList.add("og-selected"), F.setAttribute("aria-selected", a.has(f) ? "true" : "false"), M === "added" && (W = "var(--og-row-added-bg,#e8f5e9)"), M === "edited" && (W = "var(--og-row-edited-bg,#fff8e1)"), M === "removed" && (W = "var(--og-row-removed-bg,#ffebee)"), a.has(f) && (W = "var(--og-row-selected-bg,#bbdefb)");
1639
+ const St = f;
1640
+ F.addEventListener("click", (m) => {
1641
+ this._cbs.onCellClick(St, -1, m);
1640
1642
  });
1641
- const lt = /* @__PURE__ */ new Map();
1642
- let X = 0;
1643
+ const it = /* @__PURE__ */ new Map();
1644
+ let V = 0;
1643
1645
  if (n.stateColumn) {
1644
- const f = D("div", "og-cell og-col-state"), S = { added: "✚", edited: "✎", removed: "✖", none: "" }, H = { added: "#2e7d32", edited: "#bf360c", removed: "#c62828", none: "" };
1645
- f.textContent = S[$] ?? "", f.style.color = H[$] ?? "", f.title = $, x > 0 && (f.style.position = "sticky", f.style.left = `${X}px`, f.style.zIndex = "2", f.style.background = C), X += 24, p.appendChild(f);
1646
+ const m = D("div", "og-cell og-col-state"), L = { added: "✚", edited: "✎", removed: "✖", none: "" }, H = { added: "#2e7d32", edited: "#bf360c", removed: "#c62828", none: "" };
1647
+ m.textContent = L[M] ?? "", m.style.color = H[M] ?? "", m.title = M, x > 0 && (m.style.position = "sticky", m.style.left = `${V}px`, m.style.zIndex = "2", m.style.background = W), V += 24, F.appendChild(m);
1646
1648
  }
1647
- const st = this._cbs.getDndManager();
1648
- if (n.draggable && st) {
1649
- const f = st.attachHandle(p, v, n._totalRows ?? e + 1);
1650
- x > 0 && (f.style.position = "sticky", f.style.left = `${X}px`, f.style.zIndex = "2", f.style.background = C), X += 18, p.appendChild(f);
1649
+ const et = this._cbs.getDndManager();
1650
+ if (n.draggable && et) {
1651
+ const m = et.attachHandle(F, f, n._totalRows ?? e + 1);
1652
+ x > 0 && (m.style.position = "sticky", m.style.left = `${V}px`, m.style.zIndex = "2", m.style.background = W), V += 18, F.appendChild(m);
1651
1653
  }
1652
1654
  if (n.rowNumber) {
1653
- const f = D("div", "og-cell og-col-rownum");
1654
- f.textContent = String(v + 1), x > 0 && (f.style.position = "sticky", f.style.left = `${X}px`, f.style.zIndex = "2", f.style.background = C), X += 44, p.appendChild(f);
1655
+ const m = D("div", "og-cell og-col-rownum");
1656
+ m.textContent = String(f + 1), x > 0 && (m.style.position = "sticky", m.style.left = `${V}px`, m.style.zIndex = "2", m.style.background = W), V += 44, F.appendChild(m);
1655
1657
  }
1656
1658
  if (n.checkColumn) {
1657
- const f = D("div", "og-cell og-col-check"), S = document.createElement("input");
1658
- S.type = "checkbox", S.checked = c.has(v), S.setAttribute("aria-label", `${v + 1}행 선택`), S.addEventListener("click", (H) => H.stopPropagation()), S.addEventListener("change", (H) => {
1659
- H.stopPropagation(), this._cbs.onRowCheck(v, S.checked);
1660
- }), f.appendChild(S), x > 0 && (f.style.position = "sticky", f.style.left = `${X}px`, f.style.zIndex = "2", f.style.background = C), X += 36, p.appendChild(f);
1659
+ const m = D("div", "og-cell og-col-check"), L = document.createElement("input");
1660
+ L.type = "checkbox", L.checked = c.has(f), L.setAttribute("aria-label", `${f + 1}행 선택`), L.addEventListener("click", (H) => H.stopPropagation()), L.addEventListener("change", (H) => {
1661
+ H.stopPropagation(), this._cbs.onRowCheck(f, L.checked);
1662
+ }), m.appendChild(L), x > 0 && (m.style.position = "sticky", m.style.left = `${V}px`, m.style.zIndex = "2", m.style.background = W), V += 36, F.appendChild(m);
1661
1663
  }
1662
- for (let f = 0; f < i.length; f++) {
1663
- const S = i[f], H = o[f] ?? n.defaultColumnWidth, tt = n.editable && S.editable !== !1, j = f === 0, P = m && !m.isEmpty ? m.getInfo(v, f) : null;
1664
- if (P != null && P.hidden) {
1665
- const E = D("div", "og-cell og-cell--merge-ph");
1666
- E.style.cssText = `width:${H}px;min-width:${H}px;flex-shrink:0;visibility:hidden;box-sizing:border-box;`, p.appendChild(E);
1664
+ for (let m = 0; m < o.length; m++) {
1665
+ const L = o[m], H = i[m] ?? n.defaultColumnWidth, at = n.editable && L.editable !== !1, G = m === 0, j = y && !y.isEmpty ? y.getInfo(f, m) : null;
1666
+ if (j != null && j.hidden) {
1667
+ const R = D("div", "og-cell og-cell--merge-ph");
1668
+ R.style.cssText = `width:${H}px;min-width:${H}px;flex-shrink:0;visibility:hidden;box-sizing:border-box;`, F.appendChild(R);
1667
1669
  continue;
1668
1670
  }
1669
- const y = D("div", "og-cell");
1670
- y.setAttribute("role", "gridcell"), y.setAttribute("aria-colindex", String(f + 1));
1671
- const B = (P == null ? void 0 : P.rowSpan) ?? 1, z = (P == null ? void 0 : P.colSpan) ?? 1, at = B > 1 ? B * n.rowHeight : n.rowHeight;
1672
- let W = H;
1673
- if (z > 1)
1674
- for (let E = 1; E < z; E++)
1675
- W += o[f + E] ?? n.defaultColumnWidth;
1676
- const U = f < x;
1677
- let G = 0;
1678
- if (U) {
1679
- n.stateColumn && (G += 24), n.draggable && (G += 18), n.rowNumber && (G += 44), n.checkColumn && (G += 36);
1680
- for (let E = 0; E < f; E++) G += o[E] ?? n.defaultColumnWidth;
1681
- y.classList.add("og-frozen-cell"), f === x - 1 && y.classList.add("og-frozen-last");
1671
+ const w = D("div", "og-cell");
1672
+ w.setAttribute("role", "gridcell"), w.setAttribute("aria-colindex", String(m + 1));
1673
+ const O = (j == null ? void 0 : j.rowSpan) ?? 1, I = (j == null ? void 0 : j.colSpan) ?? 1, dt = O > 1 ? O * n.rowHeight : n.rowHeight;
1674
+ let N = H;
1675
+ if (I > 1)
1676
+ for (let R = 1; R < I; R++)
1677
+ N += i[m + R] ?? n.defaultColumnWidth;
1678
+ const q = m < x;
1679
+ let X = 0;
1680
+ if (q) {
1681
+ n.stateColumn && (X += 24), n.draggable && (X += 18), n.rowNumber && (X += 44), n.checkColumn && (X += 36);
1682
+ for (let R = 0; R < m; R++) X += i[R] ?? n.defaultColumnWidth;
1683
+ w.classList.add("og-frozen-cell"), m === x - 1 && w.classList.add("og-frozen-last");
1682
1684
  }
1683
- y.style.width = `${W}px`, y.style.minWidth = `${W}px`, y.style.maxWidth = `${W}px`, B > 1 && (y.style.height = `${at}px`), U && (y.style.background = C), T && j && (y.style.padding = "0"), y.style.overflow = "hidden", B > 1 ? (y.style.height = `${at}px`, y.style.position = "absolute", y.style.zIndex = "3", y.style.background = C && C !== "inherit" ? C : "var(--og-row-bg, #fff)", y.style.borderTop = "0", y.style.borderLeft = "0", y.style.borderBottom = "1px solid var(--og-border-color, #e0e0e0)") : U && (y.style.position = "sticky", y.style.left = `${G}px`, y.style.zIndex = "1"), S.type === "number" || S.align === "right" ? y.classList.add("og-cell--right") : S.align === "center" && y.classList.add("og-cell--center"), tt && y.classList.add("og-cell--editable"), S.wrap && y.classList.add("og-cell--wrap"), tt || y.setAttribute("aria-readonly", "true"), z > 1 && y.setAttribute("aria-colspan", String(z)), B > 1 && y.setAttribute("aria-rowspan", String(B)), ((b = n._focusCell) == null ? void 0 : b.ri) === v && ((L = n._focusCell) == null ? void 0 : L.ci) === f && (y.classList.add("og-cell-focused"), y.tabIndex = -1);
1684
- const et = A ? A[S.field] : null;
1685
- y.setAttribute("aria-label", `${S.header}: ${et == null ? "" : String(et)}`), S.tooltip != null ? y.title = typeof S.tooltip == "function" ? String(S.tooltip(et, A) ?? "") : String(S.tooltip) : n.tooltips && et != null && et !== "" && (y.title = String(et));
1686
- let Et = y;
1687
- if (T && j) {
1688
- const E = D("div", "og-tree-cell"), q = T._ancestorHasMore ?? [];
1689
- for (let K = 0; K < T._depth; K++) {
1690
- const Y = D("span", "og-tree-guide");
1691
- q[K] && Y.classList.add("og-tree-guide--line"), E.appendChild(Y);
1685
+ w.style.width = `${N}px`, w.style.minWidth = `${N}px`, w.style.maxWidth = `${N}px`, O > 1 && (w.style.height = `${dt}px`), q && (w.style.background = W), S && G && (w.style.padding = "0"), w.style.overflow = "hidden", O > 1 ? (w.style.height = `${dt}px`, w.style.position = "absolute", w.style.zIndex = "3", w.style.background = W && W !== "inherit" ? W : "var(--og-row-bg, #fff)", w.style.borderTop = "0", w.style.borderLeft = "0", w.style.borderBottom = "1px solid var(--og-border-color, #e0e0e0)") : q && (w.style.position = "sticky", w.style.left = `${X}px`, w.style.zIndex = "1"), L.type === "number" || L.align === "right" ? w.classList.add("og-cell--right") : L.align === "center" && w.classList.add("og-cell--center"), at && w.classList.add("og-cell--editable"), L.wrap && w.classList.add("og-cell--wrap"), at || w.setAttribute("aria-readonly", "true"), I > 1 && w.setAttribute("aria-colspan", String(I)), O > 1 && w.setAttribute("aria-rowspan", String(O)), ((v = n._focusCell) == null ? void 0 : v.ri) === f && ((T = n._focusCell) == null ? void 0 : T.ci) === m && (w.classList.add("og-cell-focused"), w.tabIndex = -1);
1686
+ const st = _ ? _[L.field] : null;
1687
+ w.setAttribute("aria-label", `${L.header}: ${st == null ? "" : String(st)}`), L.tooltip != null ? w.title = typeof L.tooltip == "function" ? String(L.tooltip(st, _) ?? "") : String(L.tooltip) : n.tooltips && st != null && st !== "" && (w.title = String(st));
1688
+ let Lt = w;
1689
+ if (S && G) {
1690
+ const R = D("div", "og-tree-cell"), Y = S._ancestorHasMore ?? [];
1691
+ for (let P = 0; P < S._depth; P++) {
1692
+ const J = D("span", "og-tree-guide");
1693
+ Y[P] && J.classList.add("og-tree-guide--line"), R.appendChild(J);
1692
1694
  }
1693
- if (T._depth > 0) {
1694
- const K = D("span", "og-tree-connector");
1695
- K.classList.add(
1696
- T._isLastChild ? "og-tree-connector--last" : "og-tree-connector--mid"
1697
- ), E.appendChild(K);
1695
+ if (S._depth > 0) {
1696
+ const P = D("span", "og-tree-connector");
1697
+ P.classList.add(
1698
+ S._isLastChild ? "og-tree-connector--last" : "og-tree-connector--mid"
1699
+ ), R.appendChild(P);
1698
1700
  }
1699
- const dt = D("span", "og-tree-toggle-wrap");
1700
- if (!T._hasChildren) {
1701
- const K = D("span", "og-tree-leaf-dot");
1702
- dt.appendChild(K);
1701
+ const ct = D("span", "og-tree-toggle-wrap");
1702
+ if (!S._hasChildren) {
1703
+ const P = D("span", "og-tree-leaf-dot");
1704
+ ct.appendChild(P);
1703
1705
  }
1704
- E.appendChild(dt);
1705
- const N = document.createElement("i");
1706
- if (T._hasChildren) {
1707
- const K = Ht(S.treeNodeIcon, A, !0, T._expanded);
1708
- N.className = T._expanded ? `${K} og-tree-node-icon og-tree-node-icon--branch og-tree-node-icon--open og-tree-node-icon--toggle` : `${K} og-tree-node-icon og-tree-node-icon--branch og-tree-node-icon--toggle`, N.setAttribute("role", "button"), N.setAttribute("tabindex", "0"), N.setAttribute("aria-expanded", T._expanded ? "true" : "false"), N.setAttribute("aria-label", T._expanded ? "접기" : "펼치기"), N.addEventListener("click", (Y) => {
1709
- Y.stopPropagation(), g == null || g(T._treeId);
1710
- }), N.addEventListener("keydown", (Y) => {
1711
- (Y.key === "Enter" || Y.key === " ") && (Y.preventDefault(), Y.stopPropagation(), g == null || g(T._treeId));
1706
+ R.appendChild(ct);
1707
+ const K = document.createElement("i");
1708
+ if (S._hasChildren) {
1709
+ const P = It(L.treeNodeIcon, _, !0, S._expanded);
1710
+ K.className = S._expanded ? `${P} og-tree-node-icon og-tree-node-icon--branch og-tree-node-icon--open og-tree-node-icon--toggle` : `${P} og-tree-node-icon og-tree-node-icon--branch og-tree-node-icon--toggle`, K.setAttribute("role", "button"), K.setAttribute("tabindex", "0"), K.setAttribute("aria-expanded", S._expanded ? "true" : "false"), K.setAttribute("aria-label", S._expanded ? "접기" : "펼치기"), K.addEventListener("click", (J) => {
1711
+ J.stopPropagation(), g == null || g(S._treeId);
1712
+ }), K.addEventListener("keydown", (J) => {
1713
+ (J.key === "Enter" || J.key === " ") && (J.preventDefault(), J.stopPropagation(), g == null || g(S._treeId));
1712
1714
  });
1713
1715
  } else {
1714
- const K = Ht(S.treeNodeIcon, A, !1, !1);
1715
- N.setAttribute("aria-hidden", "true"), N.className = `${K} og-tree-node-icon og-tree-node-icon--leaf`;
1716
+ const P = It(L.treeNodeIcon, _, !1, !1);
1717
+ K.setAttribute("aria-hidden", "true"), K.className = `${P} og-tree-node-icon og-tree-node-icon--leaf`;
1716
1718
  }
1717
- E.appendChild(N), y.appendChild(E), Et = E;
1719
+ R.appendChild(K), w.appendChild(R), Lt = R;
1718
1720
  }
1719
- if (S.cellStyle) {
1720
- const E = A[S.field], q = typeof S.cellStyle == "function" ? S.cellStyle(E, A, v) : S.cellStyle;
1721
- Object.assign(y.style, q);
1721
+ if (L.cellStyle) {
1722
+ const R = _[L.field], Y = typeof L.cellStyle == "function" ? L.cellStyle(R, _, f) : L.cellStyle;
1723
+ Object.assign(w.style, Y);
1722
1724
  }
1723
- const ie = Ae(S).render({
1724
- value: A[S.field],
1725
- row: A,
1726
- rowIndex: v,
1727
- column: S,
1728
- colIndex: f,
1729
- isSelected: a.has(v),
1730
- rowState: $
1725
+ const ne = ze(L).render({
1726
+ value: _[L.field],
1727
+ row: _,
1728
+ rowIndex: f,
1729
+ column: L,
1730
+ colIndex: m,
1731
+ isSelected: a.has(f),
1732
+ rowState: M,
1733
+ displayValue: ((E = (A = this._cbs).getDisplayText) == null ? void 0 : E.call(A, f, L.field)) ?? null
1731
1734
  });
1732
- Et.appendChild(ie);
1733
- const J = v, Q = f;
1734
- if (y.addEventListener("click", (E) => {
1735
- E.stopPropagation(), this._cbs.onCellClick(J, Q, E);
1736
- }), y.addEventListener("dblclick", (E) => {
1737
- E.stopPropagation(), this._cbs.onCellDblClick(J, Q, E);
1738
- }), y.addEventListener("mouseover", (E) => {
1739
- E.stopPropagation(), this._cbs.onCellMouseOver(J, Q, E);
1740
- }), y.addEventListener("mouseout", (E) => {
1741
- E.stopPropagation(), this._cbs.onCellMouseOut(J, Q, E);
1742
- }), y.addEventListener("mousedown", (E) => {
1743
- E.stopPropagation(), this._cbs.onCellMouseDown(J, Q, E);
1744
- }), y.addEventListener("mouseup", (E) => {
1745
- E.stopPropagation(), this._cbs.onCellMouseUp(J, Q, E);
1746
- }), y.addEventListener("mousemove", (E) => {
1747
- E.stopPropagation(), this._cbs.onCellMouseMove(J, Q, E);
1748
- }), lt.set(f, y), B > 1) {
1749
- const E = document.createElement("div");
1750
- E.style.cssText = [
1735
+ Lt.appendChild(ne);
1736
+ const Q = f, Z = m;
1737
+ if (w.addEventListener("click", (R) => {
1738
+ R.stopPropagation(), this._cbs.onCellClick(Q, Z, R);
1739
+ }), w.addEventListener("dblclick", (R) => {
1740
+ R.stopPropagation(), this._cbs.onCellDblClick(Q, Z, R);
1741
+ }), w.addEventListener("mouseover", (R) => {
1742
+ R.stopPropagation(), this._cbs.onCellMouseOver(Q, Z, R);
1743
+ }), w.addEventListener("mouseout", (R) => {
1744
+ R.stopPropagation(), this._cbs.onCellMouseOut(Q, Z, R);
1745
+ }), w.addEventListener("mousedown", (R) => {
1746
+ R.stopPropagation(), this._cbs.onCellMouseDown(Q, Z, R);
1747
+ }), w.addEventListener("mouseup", (R) => {
1748
+ R.stopPropagation(), this._cbs.onCellMouseUp(Q, Z, R);
1749
+ }), w.addEventListener("mousemove", (R) => {
1750
+ R.stopPropagation(), this._cbs.onCellMouseMove(Q, Z, R);
1751
+ }), it.set(m, w), O > 1) {
1752
+ const R = document.createElement("div");
1753
+ R.style.cssText = [
1751
1754
  `width:${H}px;min-width:${H}px;height:${n.rowHeight}px;`,
1752
1755
  "flex-shrink:0;box-sizing:border-box;",
1753
1756
  "border-right:1px solid var(--og-border-color,#e0e0e0);"
1754
- ].join(""), p.appendChild(E);
1755
- let q = 0;
1756
- n.stateColumn && (q += 24), n.draggable && (q += 18), n.rowNumber && (q += 44), n.checkColumn && (q += 36);
1757
- for (let N = 0; N < f; N++) q += o[N] ?? n.defaultColumnWidth;
1758
- const dt = r + (v - t) * n.rowHeight;
1759
- y.style.left = `${q}px`, y.style.top = `${dt}px`, _.appendChild(y);
1757
+ ].join(""), F.appendChild(R);
1758
+ let Y = 0;
1759
+ n.stateColumn && (Y += 24), n.draggable && (Y += 18), n.rowNumber && (Y += 44), n.checkColumn && (Y += 36);
1760
+ for (let K = 0; K < m; K++) Y += i[K] ?? n.defaultColumnWidth;
1761
+ const ct = r + (f - t) * n.rowHeight;
1762
+ w.style.left = `${Y}px`, w.style.top = `${ct}px`, p.appendChild(w);
1760
1763
  } else
1761
- p.appendChild(y);
1764
+ F.appendChild(w);
1762
1765
  }
1763
- this._cellMap.set(v, lt), _.appendChild(p);
1766
+ this._cellMap.set(f, it), p.appendChild(F);
1764
1767
  }
1765
1768
  if (s.rowCount === 0) {
1766
- const v = D("div", "og-empty-message");
1767
- v.textContent = "데이터가 없습니다.", v.style.cssText = "width:100%;", _.appendChild(v);
1769
+ const f = D("div", "og-empty-message");
1770
+ f.textContent = "데이터가 없습니다.", f.style.cssText = "width:100%;", p.appendChild(f);
1768
1771
  }
1769
- this._body.appendChild(_);
1772
+ this._body.appendChild(p);
1770
1773
  }
1771
1774
  getCellEl(t, e) {
1772
1775
  var s;
@@ -1776,35 +1779,35 @@ class He {
1776
1779
  this._root.innerHTML = "";
1777
1780
  }
1778
1781
  }
1779
- function Ht(d, t, e, s) {
1780
- let i;
1781
- return d ? typeof d == "function" ? i = d(t, e, s) : e ? i = s ? d.branchOpen ?? "bi-folder2-open" : d.branch ?? "bi-folder2" : i = d.leaf ?? "bi-file-earmark" : i = e ? s ? "bi-folder2-open" : "bi-folder2" : "bi-file-earmark", i.startsWith("bi ") ? i : `bi ${i}`;
1782
+ function It(d, t, e, s) {
1783
+ let o;
1784
+ return d ? typeof d == "function" ? o = d(t, e, s) : e ? o = s ? d.branchOpen ?? "bi-folder2-open" : d.branch ?? "bi-folder2" : o = d.leaf ?? "bi-file-earmark" : o = e ? s ? "bi-folder2-open" : "bi-folder2" : "bi-file-earmark", o.startsWith("bi ") ? o : `bi ${o}`;
1782
1785
  }
1783
1786
  function D(d, t) {
1784
1787
  const e = document.createElement(d);
1785
1788
  return t && (e.className = t), e;
1786
1789
  }
1787
- function zt(d, t) {
1790
+ function Bt(d, t) {
1788
1791
  Object.assign(d.style, t);
1789
1792
  }
1790
- function It(d, t, e = "text/plain;charset=utf-8") {
1791
- const s = new Blob([d], { type: e }), i = URL.createObjectURL(s), o = document.createElement("a");
1792
- o.href = i, o.download = t, o.click(), URL.revokeObjectURL(i);
1793
+ function Ot(d, t, e = "text/plain;charset=utf-8") {
1794
+ const s = new Blob([d], { type: e }), o = URL.createObjectURL(s), i = document.createElement("a");
1795
+ i.href = o, i.download = t, i.click(), URL.revokeObjectURL(o);
1793
1796
  }
1794
- function ze(d, t, e) {
1795
- let s = 0, i = 0;
1796
- d.addEventListener("mousedown", (o) => {
1797
- o.stopPropagation(), o.preventDefault(), s = o.clientX, i = t.offsetWidth;
1797
+ function Be(d, t, e) {
1798
+ let s = 0, o = 0;
1799
+ d.addEventListener("mousedown", (i) => {
1800
+ i.stopPropagation(), i.preventDefault(), s = i.clientX, o = t.offsetWidth;
1798
1801
  const n = (l) => {
1799
- const a = Math.max(40, i + l.clientX - s);
1802
+ const a = Math.max(40, o + l.clientX - s);
1800
1803
  t.style.width = `${a}px`, t.style.minWidth = `${a}px`;
1801
1804
  }, r = (l) => {
1802
- document.removeEventListener("mousemove", n), document.removeEventListener("mouseup", r), e(Math.max(40, i + l.clientX - s));
1805
+ document.removeEventListener("mousemove", n), document.removeEventListener("mouseup", r), e(Math.max(40, o + l.clientX - s));
1803
1806
  };
1804
1807
  document.addEventListener("mousemove", n), document.addEventListener("mouseup", r);
1805
1808
  });
1806
1809
  }
1807
- class Ie {
1810
+ class Oe {
1808
1811
  constructor(t) {
1809
1812
  this._selectedRows = /* @__PURE__ */ new Set(), this._checkedRows = /* @__PURE__ */ new Set(), this._data = t;
1810
1813
  }
@@ -1875,7 +1878,7 @@ class Ie {
1875
1878
  this._selectedRows.clear(), this._checkedRows.clear();
1876
1879
  }
1877
1880
  }
1878
- class bt {
1881
+ class vt {
1879
1882
  constructor() {
1880
1883
  this._onKeyDown = (t) => {
1881
1884
  t.stopPropagation(), t.key === "Enter" ? (t.preventDefault(), this._onCommit(this.input.value)) : t.key === "Escape" && this._onCancel();
@@ -1883,12 +1886,12 @@ class bt {
1883
1886
  this._onCommit(this.input.value);
1884
1887
  };
1885
1888
  }
1886
- mount(t, e, s, i) {
1887
- this._container = t, this._onCommit = s, this._onCancel = i, t.setAttribute("aria-haspopup", "dialog"), t.setAttribute("aria-expanded", "true"), this.input = document.createElement("input"), this.input.type = "date", this.input.className = "og-cell-input", this.input.setAttribute("aria-label", e.column.header ?? "날짜 선택");
1888
- const o = e.value;
1889
- if (o) {
1890
- const n = o instanceof Date ? o : new Date(o);
1891
- isNaN(n.getTime()) || (this.input.value = Xt(n, "yyyy-MM-dd"));
1889
+ mount(t, e, s, o) {
1890
+ this._container = t, this._onCommit = s, this._onCancel = o, t.setAttribute("aria-haspopup", "dialog"), t.setAttribute("aria-expanded", "true"), this.input = document.createElement("input"), this.input.type = "date", this.input.className = "og-cell-input", this.input.setAttribute("aria-label", e.column.header ?? "날짜 선택");
1891
+ const i = e.value;
1892
+ if (i) {
1893
+ const n = i instanceof Date ? i : new Date(i);
1894
+ isNaN(n.getTime()) || (this.input.value = Jt(n, "yyyy-MM-dd"));
1892
1895
  }
1893
1896
  this.input.addEventListener("keydown", this._onKeyDown), this.input.addEventListener("blur", this._onBlur), t.appendChild(this.input);
1894
1897
  }
@@ -1905,23 +1908,23 @@ class bt {
1905
1908
  (t = this._container) == null || t.setAttribute("aria-expanded", "false"), (e = this.input) == null || e.removeEventListener("keydown", this._onKeyDown), (s = this.input) == null || s.removeEventListener("blur", this._onBlur);
1906
1909
  }
1907
1910
  }
1908
- function Bt(d) {
1911
+ function Wt(d) {
1909
1912
  return d.map((t) => typeof t == "string" ? { label: t, value: t } : { label: t.label ?? t.text ?? String(t.value ?? ""), value: t.value });
1910
1913
  }
1911
- class vt {
1914
+ class xt {
1912
1915
  constructor(t = [], e) {
1913
- this._options = Bt(t), this._optionsFn = e ?? null;
1916
+ this._options = Wt(t), this._optionsFn = e ?? null;
1914
1917
  }
1915
- mount(t, e, s, i) {
1916
- this._container = t, this._onCommit = s, this._onCancel = i, t.setAttribute("aria-haspopup", "listbox"), t.setAttribute("aria-expanded", "true"), this.select = document.createElement("select"), this.select.className = "og-cell-select", this.select.setAttribute("aria-label", e.column.header ?? "선택");
1917
- const o = this._optionsFn ? Bt(this._optionsFn(e.row, e.rowIndex)) : this._options;
1918
- for (const r of o) {
1918
+ mount(t, e, s, o) {
1919
+ this._container = t, this._onCommit = s, this._onCancel = o, t.setAttribute("aria-haspopup", "listbox"), t.setAttribute("aria-expanded", "true"), this.select = document.createElement("select"), this.select.className = "og-cell-select", this.select.setAttribute("aria-label", e.column.header ?? "선택");
1920
+ const i = this._optionsFn ? Wt(this._optionsFn(e.row, e.rowIndex)) : this._options;
1921
+ for (const r of i) {
1919
1922
  const l = document.createElement("option");
1920
1923
  l.value = String(r.value), l.textContent = r.label, this.select.appendChild(l);
1921
1924
  }
1922
1925
  const n = e.value == null ? "" : String(e.value);
1923
- o.some((r) => String(r.value) === n) && (this.select.value = n), this.select.addEventListener("change", () => s(this.select.value)), this.select.addEventListener("blur", () => s(this.select.value)), this.select.addEventListener("keydown", (r) => {
1924
- r.key === "Escape" && i();
1926
+ i.some((r) => String(r.value) === n) && (this.select.value = n), this.select.addEventListener("change", () => s(this.select.value)), this.select.addEventListener("blur", () => s(this.select.value)), this.select.addEventListener("keydown", (r) => {
1927
+ r.key === "Escape" && o();
1925
1928
  }), t.appendChild(this.select);
1926
1929
  }
1927
1930
  getValue() {
@@ -1937,7 +1940,7 @@ class vt {
1937
1940
  (t = this._container) == null || t.setAttribute("aria-expanded", "false");
1938
1941
  }
1939
1942
  }
1940
- class xt {
1943
+ class Ct {
1941
1944
  constructor() {
1942
1945
  this._onKeyDown = (t) => {
1943
1946
  t.stopPropagation(), t.key === "Enter" || t.key === "Tab" ? (t.preventDefault(), this._onCommit(this.input.value)) : t.key === "Escape" && this._onCancel();
@@ -1945,8 +1948,8 @@ class xt {
1945
1948
  this._onCommit(this.input.value);
1946
1949
  };
1947
1950
  }
1948
- mount(t, e, s, i) {
1949
- this._onCommit = s, this._onCancel = i, this.input = document.createElement("input"), this.input.type = "text", this.input.value = e.value == null ? "" : String(e.value), this.input.style.cssText = `
1951
+ mount(t, e, s, o) {
1952
+ this._onCommit = s, this._onCancel = o, this.input = document.createElement("input"), this.input.type = "text", this.input.value = e.value == null ? "" : String(e.value), this.input.style.cssText = `
1950
1953
  width:100%;height:100%;border:none;outline:none;padding:0 8px;
1951
1954
  font-size:var(--og-font-size,13px);font-family:var(--og-font-family,sans-serif);
1952
1955
  background:var(--og-row-bg,#fff);box-sizing:border-box;
@@ -1965,7 +1968,7 @@ class xt {
1965
1968
  (t = this.input) == null || t.removeEventListener("keydown", this._onKeyDown), (e = this.input) == null || e.removeEventListener("blur", this._onBlur);
1966
1969
  }
1967
1970
  }
1968
- class Ct {
1971
+ class Mt {
1969
1972
  constructor(t) {
1970
1973
  this._onKeyDown = (e) => {
1971
1974
  e.stopPropagation(), e.key === "Enter" || e.key === "Tab" ? (e.preventDefault(), this._commit()) : e.key === "Escape" && this._onCancel();
@@ -1973,8 +1976,8 @@ class Ct {
1973
1976
  this._commit();
1974
1977
  }, this.min = t == null ? void 0 : t.min, this.max = t == null ? void 0 : t.max, this.step = t == null ? void 0 : t.step;
1975
1978
  }
1976
- mount(t, e, s, i) {
1977
- this._onCommit = s, this._onCancel = i, this.input = document.createElement("input"), this.input.type = "number", this.input.value = e.value == null ? "" : String(e.value), this.min != null && (this.input.min = String(this.min)), this.max != null && (this.input.max = String(this.max)), this.step != null && (this.input.step = String(this.step)), this.input.style.cssText = `
1979
+ mount(t, e, s, o) {
1980
+ this._onCommit = s, this._onCancel = o, this.input = document.createElement("input"), this.input.type = "number", this.input.value = e.value == null ? "" : String(e.value), this.min != null && (this.input.min = String(this.min)), this.max != null && (this.input.max = String(this.max)), this.step != null && (this.input.step = String(this.step)), this.input.style.cssText = `
1978
1981
  width:100%;height:100%;border:none;outline:none;padding:0 8px;
1979
1982
  font-size:var(--og-font-size,13px);text-align:right;
1980
1983
  background:var(--og-row-bg,#fff);box-sizing:border-box;
@@ -1997,8 +2000,8 @@ class Ct {
1997
2000
  (t = this.input) == null || t.removeEventListener("keydown", this._onKeyDown), (e = this.input) == null || e.removeEventListener("blur", this._onBlur);
1998
2001
  }
1999
2002
  }
2000
- class Mt {
2001
- mount(t, e, s, i) {
2003
+ class kt {
2004
+ mount(t, e, s, o) {
2002
2005
  this._onCommit = s, t.style.cssText += "display:flex;align-items:center;justify-content:center;", this.chk = document.createElement("input"), this.chk.type = "checkbox", this.chk.checked = !!e.value, this.chk.style.cursor = "pointer", this.chk.addEventListener("change", () => s(this.chk.checked)), t.appendChild(this.chk);
2003
2006
  }
2004
2007
  getValue() {
@@ -2012,54 +2015,54 @@ class Mt {
2012
2015
  destroy() {
2013
2016
  }
2014
2017
  }
2015
- function Ot(d) {
2018
+ function Nt(d) {
2016
2019
  const t = d.editor;
2017
2020
  if (!t)
2018
2021
  switch (d.type) {
2019
2022
  case "number":
2020
- return new Ct();
2023
+ return new Mt();
2021
2024
  case "date":
2022
- return new bt();
2025
+ return new vt();
2023
2026
  case "boolean":
2024
- return new Mt();
2027
+ return new kt();
2025
2028
  case "select":
2026
- return new vt(d.options ?? [], d.optionsFn);
2029
+ return new xt(d.options ?? [], d.optionsFn);
2027
2030
  default:
2028
- return new xt();
2031
+ return new Ct();
2029
2032
  }
2030
2033
  if (typeof t == "string")
2031
2034
  switch (t) {
2032
2035
  case "number":
2033
- return new Ct();
2036
+ return new Mt();
2034
2037
  case "date":
2035
- return new bt();
2038
+ return new vt();
2036
2039
  case "select":
2037
- return new vt(d.options ?? [], d.optionsFn);
2040
+ return new xt(d.options ?? [], d.optionsFn);
2038
2041
  case "checkbox":
2039
- return new Mt();
2042
+ return new kt();
2040
2043
  default:
2041
- return new xt();
2044
+ return new Ct();
2042
2045
  }
2043
2046
  switch (t.type) {
2044
2047
  case "number": {
2045
2048
  const e = {};
2046
- return t.min != null && (e.min = t.min), t.max != null && (e.max = t.max), t.step != null && (e.step = t.step), new Ct(e);
2049
+ return t.min != null && (e.min = t.min), t.max != null && (e.max = t.max), t.step != null && (e.step = t.step), new Mt(e);
2047
2050
  }
2048
2051
  case "date":
2049
- return new bt();
2052
+ return new vt();
2050
2053
  case "select":
2051
- return new vt(t.options ?? [], d.optionsFn);
2054
+ return new xt(t.options ?? [], d.optionsFn);
2052
2055
  case "checkbox":
2053
- return new Mt();
2056
+ return new kt();
2054
2057
  default:
2055
- return new xt();
2058
+ return new Ct();
2056
2059
  }
2057
2060
  }
2058
- function nt(d) {
2061
+ function rt(d) {
2059
2062
  const t = typeof d.renderer == "string" ? d.renderer : d.renderer && typeof d.renderer == "object" ? d.renderer.type : "";
2060
2063
  return d.type === "boolean" || d.type === "checkbox" || t === "checkbox" || t === "switch";
2061
2064
  }
2062
- class Be {
2065
+ class We {
2063
2066
  constructor(t) {
2064
2067
  this._activeEditor = null, this._editCell = null, this._focusCell = null, this._dragColIdx = null, this._d = t;
2065
2068
  }
@@ -2082,11 +2085,11 @@ class Be {
2082
2085
  // ─── 포커스 셀 ───────────────────────────────────────────
2083
2086
  setFocusCell(t, e) {
2084
2087
  this._focusCell = { ri: t, ci: e }, this._d.scrollToRow(t), this._d.doRender();
2085
- const s = this._d.getVisibleLeaves()[e], i = this._d.data.getRowByIndex(t);
2086
- if (s && i) {
2087
- const o = i[s.field];
2088
+ const s = this._d.getVisibleLeaves()[e], o = this._d.data.getRowByIndex(t);
2089
+ if (s && o) {
2090
+ const i = o[s.field];
2088
2091
  this._d.announce(
2089
- `${t + 1}행 ${e + 1}열, ${s.header}: ${o == null ? "빈 값" : String(o)}`
2092
+ `${t + 1}행 ${e + 1}열, ${s.header}: ${i == null ? "빈 값" : String(i)}`
2090
2093
  );
2091
2094
  }
2092
2095
  }
@@ -2098,7 +2101,7 @@ class Be {
2098
2101
  var a, c, u;
2099
2102
  const s = this._d.getVisibleLeaves()[e];
2100
2103
  if (!s) return;
2101
- if (nt(s)) {
2104
+ if (rt(s)) {
2102
2105
  const h = this._d.getOptions();
2103
2106
  if (s.editable !== !1 && (s.editable !== void 0 || h.editable)) {
2104
2107
  const k = this._d.data.getRowByIndex(t);
@@ -2106,28 +2109,28 @@ class Be {
2106
2109
  }
2107
2110
  return;
2108
2111
  }
2109
- const i = this._d.data.getRowByIndex(t);
2110
- if (s.editable === !1 || typeof s.editable == "function" && !s.editable(i, t)) return;
2112
+ const o = this._d.data.getRowByIndex(t);
2113
+ if (s.editable === !1 || typeof s.editable == "function" && !s.editable(o, t)) return;
2111
2114
  this.commitEdit();
2112
- const o = (a = this._d.getRenderer()) == null ? void 0 : a.getCellEl(t, e);
2113
- if (!o) return;
2114
- o.innerHTML = "";
2115
- const n = Ot(s);
2115
+ const i = (a = this._d.getRenderer()) == null ? void 0 : a.getCellEl(t, e);
2116
+ if (!i) return;
2117
+ i.innerHTML = "";
2118
+ const n = Nt(s);
2116
2119
  this._activeEditor = n, this._editCell = { ri: t, ci: e };
2117
2120
  const r = {
2118
2121
  type: "editStart",
2119
2122
  rowIndex: t,
2120
2123
  columnIndex: e,
2121
2124
  field: s.field,
2122
- oldValue: i == null ? void 0 : i[s.field],
2123
- newValue: i == null ? void 0 : i[s.field],
2124
- row: i,
2125
+ oldValue: o == null ? void 0 : o[s.field],
2126
+ newValue: o == null ? void 0 : o[s.field],
2127
+ row: o,
2125
2128
  column: s
2126
2129
  };
2127
- this._d.emit("editStart", r), (u = (c = this._d.getOptions()).onEditStart) == null || u.call(c, r), o.classList.add("og-editing");
2130
+ this._d.emit("editStart", r), (u = (c = this._d.getOptions()).onEditStart) == null || u.call(c, r), i.classList.add("og-editing");
2128
2131
  const l = {
2129
- value: i == null ? void 0 : i[s.field],
2130
- row: i,
2132
+ value: o == null ? void 0 : o[s.field],
2133
+ row: o,
2131
2134
  rowIndex: t,
2132
2135
  column: s,
2133
2136
  colIndex: e,
@@ -2135,7 +2138,7 @@ class Be {
2135
2138
  rowState: "none"
2136
2139
  };
2137
2140
  n.mount(
2138
- o,
2141
+ i,
2139
2142
  l,
2140
2143
  (h) => this.commitEditWithValue(t, e, h),
2141
2144
  () => this.cancelEdit()
@@ -2144,34 +2147,34 @@ class Be {
2144
2147
  // ─── 편집 시작 (마우스) ──────────────────────────────────
2145
2148
  startEdit(t, e, s) {
2146
2149
  var u, h;
2147
- const i = this._d.getOptions();
2148
- if (!i.editable) return;
2149
- const o = this._d.getVisibleLeaves()[e];
2150
- if (!o || nt(o)) return;
2150
+ const o = this._d.getOptions();
2151
+ if (!o.editable) return;
2152
+ const i = this._d.getVisibleLeaves()[e];
2153
+ if (!i || rt(i)) return;
2151
2154
  const n = this._d.data.getRowByIndex(t);
2152
- if (o.editable === !1 || typeof o.editable == "function" && !o.editable(n, t) || !o.editable && !i.editable) return;
2155
+ if (i.editable === !1 || typeof i.editable == "function" && !i.editable(n, t) || !i.editable && !o.editable) return;
2153
2156
  this.commitEdit();
2154
2157
  const r = (u = this._d.getRenderer()) == null ? void 0 : u.getCellEl(t, e);
2155
2158
  if (!r) return;
2156
2159
  r.innerHTML = "";
2157
- const l = Ot(o);
2160
+ const l = Nt(i);
2158
2161
  this._activeEditor = l, this._editCell = { ri: t, ci: e };
2159
2162
  const a = {
2160
2163
  type: "editStart",
2161
2164
  rowIndex: t,
2162
2165
  columnIndex: e,
2163
- field: o.field,
2164
- oldValue: n == null ? void 0 : n[o.field],
2165
- newValue: n == null ? void 0 : n[o.field],
2166
+ field: i.field,
2167
+ oldValue: n == null ? void 0 : n[i.field],
2168
+ newValue: n == null ? void 0 : n[i.field],
2166
2169
  row: n,
2167
- column: o
2170
+ column: i
2168
2171
  };
2169
- this._d.emit("editStart", a), (h = i.onEditStart) == null || h.call(i, a), r.classList.add("og-editing");
2172
+ this._d.emit("editStart", a), (h = o.onEditStart) == null || h.call(o, a), r.classList.add("og-editing");
2170
2173
  const c = {
2171
- value: n == null ? void 0 : n[o.field],
2174
+ value: n == null ? void 0 : n[i.field],
2172
2175
  row: n,
2173
2176
  rowIndex: t,
2174
- column: o,
2177
+ column: i,
2175
2178
  colIndex: e,
2176
2179
  isSelected: !0,
2177
2180
  rowState: "none"
@@ -2197,23 +2200,23 @@ class Be {
2197
2200
  const { ri: t, ci: e } = this._editCell;
2198
2201
  this._finishEdit(t, e, void 0, !0);
2199
2202
  }
2200
- _finishEdit(t, e, s, i) {
2203
+ _finishEdit(t, e, s, o) {
2201
2204
  var r, l, a;
2202
2205
  if (!this._activeEditor) return;
2203
- const o = this._d.getVisibleLeaves()[e], n = (r = this._d.getRenderer()) == null ? void 0 : r.getCellEl(t, e);
2204
- if (n && (this._activeEditor.destroy(), n.classList.remove("og-editing")), this._activeEditor = null, this._editCell = null, !i && o) {
2205
- const c = this._d.data.getCellValue(t, o.field);
2206
+ const i = this._d.getVisibleLeaves()[e], n = (r = this._d.getRenderer()) == null ? void 0 : r.getCellEl(t, e);
2207
+ if (n && (this._activeEditor.destroy(), n.classList.remove("og-editing")), this._activeEditor = null, this._editCell = null, !o && i) {
2208
+ const c = this._d.data.getCellValue(t, i.field);
2206
2209
  if (s !== c) {
2207
- this._d.data.updateCell(t, o.field, s);
2210
+ this._d.data.updateCell(t, i.field, s);
2208
2211
  const u = this._d.data.getRowByIndex(t), h = this._d.getOptions(), g = {
2209
2212
  type: "editEnd",
2210
2213
  rowIndex: t,
2211
2214
  columnIndex: e,
2212
- field: o.field,
2215
+ field: i.field,
2213
2216
  oldValue: c,
2214
2217
  newValue: s,
2215
2218
  row: u,
2216
- column: o
2219
+ column: i
2217
2220
  };
2218
2221
  this._d.emit("editEnd", g), (l = h.onEditEnd) == null || l.call(h, g), this._d.emit("dataChange", this._d.data.getData()), (a = h.onDataChange) == null || a.call(h, this._d.data.getData());
2219
2222
  }
@@ -2221,9 +2224,9 @@ class Be {
2221
2224
  this._d.doRender(), requestAnimationFrame(() => this._d.getContainer().focus({ preventScroll: !0 }));
2222
2225
  }
2223
2226
  }
2224
- class Oe {
2225
- constructor(t, e, s, i, o) {
2226
- this._selects = /* @__PURE__ */ new Map(), this._selected = {}, this._config = e, this._onFilter = s, this._onReset = i, this._el = document.createElement("fieldset"), this._el.className = "og-filter-select";
2227
+ class Ne {
2228
+ constructor(t, e, s, o, i) {
2229
+ this._selects = /* @__PURE__ */ new Map(), this._selected = {}, this._config = e, this._onFilter = s, this._onReset = o, this._el = document.createElement("fieldset"), this._el.className = "og-filter-select";
2227
2230
  const n = document.createElement("legend");
2228
2231
  n.className = "og-filter-select-legend", n.textContent = e.legend ?? "필터", this._el.appendChild(n);
2229
2232
  const r = document.createElement("div");
@@ -2234,7 +2237,7 @@ class Oe {
2234
2237
  const h = document.createElement("label");
2235
2238
  h.htmlFor = c, h.textContent = a.label, h.className = "og-filter-select-label";
2236
2239
  const g = document.createElement("select");
2237
- g.id = c, g.className = "og-filter-select-sel", g.setAttribute("aria-label", a.label), o && g.setAttribute("aria-controls", o), a.dependsOn ? this._fill(g, [], !1) : this._fill(g, this._resolve(a, ""), !0), g.addEventListener("change", () => this._onChange(a.field, g.value)), u.appendChild(h), u.appendChild(g), r.appendChild(u), this._selects.set(a.field, g);
2240
+ g.id = c, g.className = "og-filter-select-sel", g.setAttribute("aria-label", a.label), i && g.setAttribute("aria-controls", i), a.dependsOn ? this._fill(g, [], !1) : this._fill(g, this._resolve(a, ""), !0), g.addEventListener("change", () => this._onChange(a.field, g.value)), u.appendChild(h), u.appendChild(g), r.appendChild(u), this._selects.set(a.field, g);
2238
2241
  }
2239
2242
  const l = document.createElement("button");
2240
2243
  l.type = "button", l.textContent = "초기화", l.className = "og-filter-select-reset", l.setAttribute("aria-label", "필터 초기화"), l.addEventListener("click", () => this._reset()), this._el.appendChild(r), this._el.appendChild(l), t.insertBefore(this._el, t.firstChild);
@@ -2252,27 +2255,27 @@ class Oe {
2252
2255
  t.dependsOn && t.dependsOnKey && e && (s = s.filter(
2253
2256
  (n) => String(n[t.dependsOnKey] ?? "") === e
2254
2257
  ));
2255
- const i = t.valueKey ?? "value", o = t.textKey ?? i;
2258
+ const o = t.valueKey ?? "value", i = t.textKey ?? o;
2256
2259
  return s.map((n) => ({
2257
- value: String(n[i] ?? ""),
2258
- text: String(n[o] ?? n[i] ?? "")
2260
+ value: String(n[o] ?? ""),
2261
+ text: String(n[i] ?? n[o] ?? "")
2259
2262
  }));
2260
2263
  }
2261
2264
  // ─── select DOM 채우기 ────────────────────────────────
2262
2265
  _fill(t, e, s) {
2263
2266
  t.innerHTML = "";
2264
- const i = document.createElement("option");
2265
- i.value = "", i.textContent = "전체", t.appendChild(i);
2266
- for (const o of e) {
2267
+ const o = document.createElement("option");
2268
+ o.value = "", o.textContent = "전체", t.appendChild(o);
2269
+ for (const i of e) {
2267
2270
  const n = document.createElement("option");
2268
- n.value = o.value, n.textContent = o.text, t.appendChild(n);
2271
+ n.value = i.value, n.textContent = i.text, t.appendChild(n);
2269
2272
  }
2270
2273
  t.disabled = !s;
2271
2274
  }
2272
2275
  // ─── 선택 변경 처리 ───────────────────────────────────
2273
2276
  _onChange(t, e) {
2274
- const s = this._config.columns.find((o) => o.field === t), i = s.filterKey ?? s.field;
2275
- e ? (this._selected[t] = e, this._onFilter(i, [{ operator: "=", value: e }])) : (delete this._selected[t], this._onReset(i)), this._cascade(t);
2277
+ const s = this._config.columns.find((i) => i.field === t), o = s.filterKey ?? s.field;
2278
+ e ? (this._selected[t] = e, this._onFilter(o, [{ operator: "=", value: e }])) : (delete this._selected[t], this._onReset(o)), this._cascade(t);
2276
2279
  }
2277
2280
  /**
2278
2281
  * 부모 컬럼 변경 후 자식 컬럼 옵션을 재계산한다 (재귀).
@@ -2281,10 +2284,10 @@ class Oe {
2281
2284
  const e = this._selected[t] ?? "";
2282
2285
  for (const s of this._config.columns) {
2283
2286
  if (s.dependsOn !== t) continue;
2284
- const i = this._selects.get(s.field);
2285
- if (!i) continue;
2286
- const o = s.filterKey ?? s.field;
2287
- e ? (this._fill(i, this._resolve(s, e), !0), i.value = "", delete this._selected[s.field], this._onReset(o)) : (this._fill(i, [], !1), delete this._selected[s.field], this._onReset(o), this._cascade(s.field));
2287
+ const o = this._selects.get(s.field);
2288
+ if (!o) continue;
2289
+ const i = s.filterKey ?? s.field;
2290
+ e ? (this._fill(o, this._resolve(s, e), !0), o.value = "", delete this._selected[s.field], this._onReset(i)) : (this._fill(o, [], !1), delete this._selected[s.field], this._onReset(i), this._cascade(s.field));
2288
2291
  }
2289
2292
  }
2290
2293
  // ─── 전체 초기화 ──────────────────────────────────────
@@ -2303,7 +2306,7 @@ class Oe {
2303
2306
  this._el.remove();
2304
2307
  }
2305
2308
  }
2306
- class We {
2309
+ class Ke {
2307
2310
  constructor(t, e, s) {
2308
2311
  this._page = 1, this._totalRows = 0, this._pageSize = e, this._onChange = s, this._el = document.createElement("div"), this._el.className = "og-pagination", this._el.style.cssText = `
2309
2312
  display:flex;align-items:center;justify-content:center;gap:4px;
@@ -2351,15 +2354,15 @@ class We {
2351
2354
  e.style.cssText = "display:flex;align-items:center;gap:3px;margin-right:8px;";
2352
2355
  const s = document.createElement("span");
2353
2356
  s.textContent = "행/페이지:", s.style.color = "#888";
2354
- const i = document.createElement("select");
2355
- i.style.cssText = "padding:2px 4px;border:1px solid var(--og-border-color,#e0e0e0);border-radius:3px;font-size:11px;cursor:pointer;";
2357
+ const o = document.createElement("select");
2358
+ o.style.cssText = "padding:2px 4px;border:1px solid var(--og-border-color,#e0e0e0);border-radius:3px;font-size:11px;cursor:pointer;";
2356
2359
  for (const c of [10, 20, 50, 100, 200]) {
2357
2360
  const u = document.createElement("option");
2358
- u.value = String(c), u.textContent = String(c), c === this._pageSize && (u.selected = !0), i.appendChild(u);
2361
+ u.value = String(c), u.textContent = String(c), c === this._pageSize && (u.selected = !0), o.appendChild(u);
2359
2362
  }
2360
- i.addEventListener("change", () => this.setPageSize(Number(i.value))), e.appendChild(s), e.appendChild(i), this._el.appendChild(e);
2361
- const o = document.createElement("span"), { start: n, end: r } = this.getRange();
2362
- o.textContent = this._totalRows > 0 ? `${n + 1}–${r + 1} / ${this._totalRows}건` : "0건", o.style.cssText = "margin-right:8px;color:#888;", this._el.appendChild(o);
2363
+ o.addEventListener("change", () => this.setPageSize(Number(o.value))), e.appendChild(s), e.appendChild(o), this._el.appendChild(e);
2364
+ const i = document.createElement("span"), { start: n, end: r } = this.getRange();
2365
+ i.textContent = this._totalRows > 0 ? `${n + 1}–${r + 1} / ${this._totalRows}건` : "0건", i.style.cssText = "margin-right:8px;color:#888;", this._el.appendChild(i);
2363
2366
  const l = (c, u, h) => {
2364
2367
  const g = document.createElement("button");
2365
2368
  return g.textContent = c, g.disabled = h, g.style.cssText = `
@@ -2371,7 +2374,7 @@ class We {
2371
2374
  `, h || g.addEventListener("click", () => this.goTo(u)), g;
2372
2375
  };
2373
2376
  this._el.appendChild(l("«", 1, this._page === 1)), this._el.appendChild(l("‹", this._page - 1, this._page === 1));
2374
- const a = Ne(this._page, t);
2377
+ const a = Pe(this._page, t);
2375
2378
  for (const c of a)
2376
2379
  if (c === -1) {
2377
2380
  const u = document.createElement("span");
@@ -2386,20 +2389,20 @@ class We {
2386
2389
  this._el.remove();
2387
2390
  }
2388
2391
  }
2389
- function Ne(d, t) {
2390
- if (t <= 7) return Array.from({ length: t }, (s, i) => i + 1);
2392
+ function Pe(d, t) {
2393
+ if (t <= 7) return Array.from({ length: t }, (s, o) => o + 1);
2391
2394
  const e = [1];
2392
2395
  d > 3 && e.push(-1);
2393
2396
  for (let s = Math.max(2, d - 1); s <= Math.min(t - 1, d + 1); s++)
2394
2397
  e.push(s);
2395
2398
  return d < t - 2 && e.push(-1), e.push(t), e;
2396
2399
  }
2397
- class Ke {
2400
+ class Ve {
2398
2401
  // grab 지점의 상단 오프셋
2399
- constructor(t, e, s, i) {
2402
+ constructor(t, e, s, o) {
2400
2403
  this._dx = e - t.left, this._dy = s - t.top;
2401
- const o = document.createElement("div");
2402
- o.className = "og-drag-ghost", o.style.cssText = `position:fixed;left:0;top:0;width:${t.width}px;height:${Math.min(t.height, 40)}px;transform:translate(${t.left}px,${t.top}px);background:rgba(25,118,210,0.12);border:2px dashed #1976d2;box-sizing:border-box;pointer-events:none;z-index:10000;border-radius:3px;opacity:0.92;display:flex;align-items:center;padding-left:10px;font-size:12px;color:#1565c0;font-weight:600;white-space:nowrap;overflow:hidden;`, i > 1 && (o.textContent = `${i}개 행 이동`), document.body.appendChild(o), this._el = o;
2404
+ const i = document.createElement("div");
2405
+ i.className = "og-drag-ghost", i.style.cssText = `position:fixed;left:0;top:0;width:${t.width}px;height:${Math.min(t.height, 40)}px;transform:translate(${t.left}px,${t.top}px);background:rgba(25,118,210,0.12);border:2px dashed #1976d2;box-sizing:border-box;pointer-events:none;z-index:10000;border-radius:3px;opacity:0.92;display:flex;align-items:center;padding-left:10px;font-size:12px;color:#1565c0;font-weight:600;white-space:nowrap;overflow:hidden;`, o > 1 && (i.textContent = `${o}개 행 이동`), document.body.appendChild(i), this._el = i;
2403
2406
  }
2404
2407
  /** 커서 위치로 이동 (grab 오프셋 유지) */
2405
2408
  move(t, e) {
@@ -2409,15 +2412,15 @@ class Ke {
2409
2412
  this._el.remove();
2410
2413
  }
2411
2414
  }
2412
- class Wt {
2415
+ class Kt {
2413
2416
  constructor(t = "#1976d2") {
2414
2417
  const e = document.createElement("div");
2415
2418
  e.className = "og-drop-indicator", e.style.cssText = "position:absolute;left:0;right:0;display:none;align-items:center;pointer-events:none;z-index:9998;transform:translateY(-50%);";
2416
- const s = (o) => {
2417
- const n = document.createElement("div"), r = o === "left" ? `border-left:7px solid ${t}` : `border-right:7px solid ${t}`;
2419
+ const s = (i) => {
2420
+ const n = document.createElement("div"), r = i === "left" ? `border-left:7px solid ${t}` : `border-right:7px solid ${t}`;
2418
2421
  return n.style.cssText = `width:0;height:0;flex-shrink:0;border-top:5px solid transparent;border-bottom:5px solid transparent;${r};`, n;
2419
- }, i = document.createElement("div");
2420
- i.style.cssText = `flex:1;height:3px;background:${t};border-radius:2px;box-shadow:0 0 0 1px rgba(255,255,255,0.7);`, e.append(s("left"), i, s("right")), this._el = e;
2422
+ }, o = document.createElement("div");
2423
+ o.style.cssText = `flex:1;height:3px;background:${t};border-radius:2px;box-shadow:0 0 0 1px rgba(255,255,255,0.7);`, e.append(s("left"), o, s("right")), this._el = e;
2421
2424
  }
2422
2425
  /** parent(그리드 바디) 안의 top(행 경계) 위치에 표시 */
2423
2426
  showIn(t, e) {
@@ -2430,32 +2433,32 @@ class Wt {
2430
2433
  this._el.remove();
2431
2434
  }
2432
2435
  }
2433
- const Nt = (d, t, e) => Math.max(t, Math.min(e, d));
2434
- class Pe {
2436
+ const Pt = (d, t, e) => Math.max(t, Math.min(e, d));
2437
+ class je {
2435
2438
  // 다른 그리드 드롭
2436
- constructor(t, e, s, i = null, o = () => 1) {
2437
- this._bodyEl = t, this._rowHeight = e, this._onDrop = s, this._cross = i, this._getDragCount = o, this._drag = null, this._selfIndicator = new Wt("#1976d2"), this._crossIndicator = new Wt("#2e7d32"), this._onMouseMove = this._onMouseMove.bind(this), this._onMouseUp = this._onMouseUp.bind(this);
2439
+ constructor(t, e, s, o = null, i = () => 1) {
2440
+ this._bodyEl = t, this._rowHeight = e, this._onDrop = s, this._cross = o, this._getDragCount = i, this._drag = null, this._selfIndicator = new Kt("#1976d2"), this._crossIndicator = new Kt("#2e7d32"), this._onMouseMove = this._onMouseMove.bind(this), this._onMouseUp = this._onMouseUp.bind(this);
2438
2441
  }
2439
2442
  /** 행 엘리먼트에 드래그 핸들 삽입 */
2440
2443
  attachHandle(t, e, s) {
2441
- const i = document.createElement("div");
2442
- return i.className = "og-drag-handle", i.innerHTML = "⠿", i.style.cssText = `
2444
+ const o = document.createElement("div");
2445
+ return o.className = "og-drag-handle", o.innerHTML = "⠿", o.style.cssText = `
2443
2446
  width:18px;min-width:18px;height:100%;
2444
2447
  display:flex;align-items:center;justify-content:center;
2445
2448
  cursor:grab;font-size:14px;color:#bbb;flex-shrink:0;
2446
2449
  user-select:none;border-right:1px solid var(--og-border-color,#e0e0e0);
2447
- `, i.addEventListener("mousedown", (o) => {
2448
- o.preventDefault(), o.stopPropagation(), this._startDrag(o, t, e, s);
2449
- }), i;
2450
+ `, o.addEventListener("mousedown", (i) => {
2451
+ i.preventDefault(), i.stopPropagation(), this._startDrag(i, t, e, s);
2452
+ }), o;
2450
2453
  }
2451
- _startDrag(t, e, s, i) {
2452
- const o = e.getBoundingClientRect(), n = this._getDragCount(s);
2454
+ _startDrag(t, e, s, o) {
2455
+ const i = e.getBoundingClientRect(), n = this._getDragCount(s);
2453
2456
  this._drag = {
2454
2457
  fromIndex: s,
2455
2458
  bodyEl: this._bodyEl,
2456
2459
  rowHeight: this._rowHeight,
2457
- totalRows: i,
2458
- ghost: new Ke(o, t.clientX, t.clientY, n),
2460
+ totalRows: o,
2461
+ ghost: new Ve(i, t.clientX, t.clientY, n),
2459
2462
  currentTarget: s,
2460
2463
  crossTarget: null
2461
2464
  }, document.addEventListener("mousemove", this._onMouseMove, !0), document.addEventListener("mouseup", this._onMouseUp, !0);
@@ -2464,28 +2467,28 @@ class Pe {
2464
2467
  if (!this._drag) return;
2465
2468
  const e = this._drag;
2466
2469
  if (e.ghost.move(t.clientX, t.clientY), this._cross) {
2467
- const o = this._cross.resolveTarget(t.clientX, t.clientY);
2468
- if (o && o.bodyEl !== e.bodyEl) {
2469
- const n = o.bodyEl.getBoundingClientRect(), r = t.clientY - n.top + o.bodyEl.scrollTop, l = Nt(Math.round(r / o.rowHeight), 0, o.totalRows);
2470
- e.crossTarget = { bodyEl: o.bodyEl, index: l }, this._selfIndicator.hide(), this._crossIndicator.showIn(o.bodyEl, l * o.rowHeight);
2470
+ const i = this._cross.resolveTarget(t.clientX, t.clientY);
2471
+ if (i && i.bodyEl !== e.bodyEl) {
2472
+ const n = i.bodyEl.getBoundingClientRect(), r = t.clientY - n.top + i.bodyEl.scrollTop, l = Pt(Math.round(r / i.rowHeight), 0, i.totalRows);
2473
+ e.crossTarget = { bodyEl: i.bodyEl, index: l }, this._selfIndicator.hide(), this._crossIndicator.showIn(i.bodyEl, l * i.rowHeight);
2471
2474
  return;
2472
2475
  }
2473
2476
  }
2474
2477
  e.crossTarget = null, this._crossIndicator.hide();
2475
- const s = e.bodyEl.getBoundingClientRect(), i = t.clientY - s.top + e.bodyEl.scrollTop;
2476
- e.currentTarget = Nt(Math.round(i / e.rowHeight), 0, e.totalRows - 1), this._selfIndicator.showIn(e.bodyEl, e.currentTarget * e.rowHeight);
2478
+ const s = e.bodyEl.getBoundingClientRect(), o = t.clientY - s.top + e.bodyEl.scrollTop;
2479
+ e.currentTarget = Pt(Math.round(o / e.rowHeight), 0, e.totalRows - 1), this._selfIndicator.showIn(e.bodyEl, e.currentTarget * e.rowHeight);
2477
2480
  }
2478
2481
  _onMouseUp(t) {
2479
2482
  if (document.removeEventListener("mousemove", this._onMouseMove, !0), document.removeEventListener("mouseup", this._onMouseUp, !0), !this._drag) return;
2480
- const { fromIndex: e, currentTarget: s, ghost: i, crossTarget: o } = this._drag;
2481
- this._drag = null, i.destroy(), this._selfIndicator.hide(), this._crossIndicator.hide(), o && this._cross ? this._cross.onCrossDrop(e, o.bodyEl, o.index) : e !== s && this._onDrop(e, s);
2483
+ const { fromIndex: e, currentTarget: s, ghost: o, crossTarget: i } = this._drag;
2484
+ this._drag = null, o.destroy(), this._selfIndicator.hide(), this._crossIndicator.hide(), i && this._cross ? this._cross.onCrossDrop(e, i.bodyEl, i.index) : e !== s && this._onDrop(e, s);
2482
2485
  }
2483
2486
  destroy() {
2484
2487
  var t;
2485
2488
  document.removeEventListener("mousemove", this._onMouseMove, !0), document.removeEventListener("mouseup", this._onMouseUp, !0), (t = this._drag) == null || t.ghost.destroy(), this._selfIndicator.destroy(), this._crossIndicator.destroy(), this._drag = null;
2486
2489
  }
2487
2490
  }
2488
- class Z {
2491
+ class tt {
2489
2492
  constructor() {
2490
2493
  this._map = /* @__PURE__ */ new Map();
2491
2494
  }
@@ -2496,15 +2499,15 @@ class Z {
2496
2499
  applyMergeCells(t) {
2497
2500
  this._map.clear();
2498
2501
  for (const e of t) {
2499
- const s = Math.max(1, e.rowSpan ?? 1), i = Math.max(1, e.colSpan ?? 1);
2500
- this._map.set(Z._key(e.row, e.col), {
2502
+ const s = Math.max(1, e.rowSpan ?? 1), o = Math.max(1, e.colSpan ?? 1);
2503
+ this._map.set(tt._key(e.row, e.col), {
2501
2504
  rowSpan: s,
2502
- colSpan: i,
2505
+ colSpan: o,
2503
2506
  hidden: !1
2504
2507
  });
2505
- for (let o = 0; o < s; o++)
2506
- for (let n = 0; n < i; n++)
2507
- o === 0 && n === 0 || this._map.set(Z._key(e.row + o, e.col + n), {
2508
+ for (let i = 0; i < s; i++)
2509
+ for (let n = 0; n < o; n++)
2510
+ i === 0 && n === 0 || this._map.set(tt._key(e.row + i, e.col + n), {
2508
2511
  rowSpan: 1,
2509
2512
  colSpan: 1,
2510
2513
  hidden: !0
@@ -2517,23 +2520,23 @@ class Z {
2517
2520
  * fields: colIndexes[i] 에 대응하는 field 이름
2518
2521
  */
2519
2522
  applyAutoMerge(t, e, s) {
2520
- var i, o;
2523
+ var o, i;
2521
2524
  this._map.clear();
2522
2525
  for (let n = 0; n < e.length; n++) {
2523
2526
  const r = e[n], l = s[n];
2524
2527
  let a = 0;
2525
2528
  for (let c = 1; c <= t.length; c++) {
2526
- const u = (i = t[c - 1]) == null ? void 0 : i[l], h = c < t.length ? (o = t[c]) == null ? void 0 : o[l] : void 0;
2529
+ const u = (o = t[c - 1]) == null ? void 0 : o[l], h = c < t.length ? (i = t[c]) == null ? void 0 : i[l] : void 0;
2527
2530
  if (c === t.length || h !== u) {
2528
2531
  const g = c - a;
2529
2532
  if (g > 1) {
2530
- this._map.set(Z._key(a, r), {
2533
+ this._map.set(tt._key(a, r), {
2531
2534
  rowSpan: g,
2532
2535
  colSpan: 1,
2533
2536
  hidden: !1
2534
2537
  });
2535
2538
  for (let k = a + 1; k < c; k++)
2536
- this._map.set(Z._key(k, r), {
2539
+ this._map.set(tt._key(k, r), {
2537
2540
  rowSpan: 1,
2538
2541
  colSpan: 1,
2539
2542
  hidden: !0
@@ -2546,7 +2549,7 @@ class Z {
2546
2549
  }
2547
2550
  /** 셀 병합 정보 조회. 없으면 null */
2548
2551
  getInfo(t, e) {
2549
- return this._map.get(Z._key(t, e)) ?? null;
2552
+ return this._map.get(tt._key(t, e)) ?? null;
2550
2553
  }
2551
2554
  /** 병합 맵 초기화 */
2552
2555
  clear() {
@@ -2556,7 +2559,7 @@ class Z {
2556
2559
  return this._map.size === 0;
2557
2560
  }
2558
2561
  }
2559
- const Ve = [
2562
+ const Ue = [
2560
2563
  { id: "sort-asc", label: "오름차순 정렬", icon: "↑", action: "sortAsc" },
2561
2564
  { id: "sort-desc", label: "내림차순 정렬", icon: "↓", action: "sortDesc" },
2562
2565
  { type: "divider" },
@@ -2566,7 +2569,7 @@ const Ve = [
2566
2569
  { id: "csv", label: "CSV로 저장", icon: "📄", action: "csv" },
2567
2570
  { id: "print", label: "인쇄", icon: "🖨", action: "print" }
2568
2571
  ];
2569
- class je {
2572
+ class Ge {
2570
2573
  /**
2571
2574
  * @param _anchor 그리드 컨테이너 엘리먼트 — CSS 변수 상속 기준점
2572
2575
  * @param _actions 기본 액션 핸들러 (OpenGrid에서 주입)
@@ -2576,12 +2579,12 @@ class je {
2576
2579
  }
2577
2580
  open(t, e) {
2578
2581
  this.close();
2579
- const s = e ?? Ve, i = document.createElement("div");
2580
- i.className = "og-context-menu", i.setAttribute("role", "menu");
2582
+ const s = e ?? Ue, o = document.createElement("div");
2583
+ o.className = "og-context-menu", o.setAttribute("role", "menu");
2581
2584
  for (const r of s) {
2582
2585
  if (r.type === "divider") {
2583
2586
  const c = document.createElement("div");
2584
- c.className = "og-cm-divider", c.setAttribute("role", "separator"), i.appendChild(c);
2587
+ c.className = "og-cm-divider", c.setAttribute("role", "separator"), o.appendChild(c);
2585
2588
  continue;
2586
2589
  }
2587
2590
  const l = document.createElement("button");
@@ -2597,17 +2600,17 @@ class je {
2597
2600
  const a = document.createElement("span");
2598
2601
  a.className = "og-cm-label", a.textContent = r.label ?? "", l.appendChild(a), l.addEventListener("click", (c) => {
2599
2602
  c.stopPropagation(), r.disabled || this._runAction(r), this.close();
2600
- }), i.appendChild(l);
2603
+ }), o.appendChild(l);
2601
2604
  }
2602
- const o = this._anchor.closest("[data-og-theme]"), n = o == null ? void 0 : o.getAttribute("data-og-theme");
2603
- n && i.setAttribute("data-og-theme", n), document.body.appendChild(i), this._el = i, this._docMouseMove = (r) => {
2605
+ const i = this._anchor.closest("[data-og-theme]"), n = i == null ? void 0 : i.getAttribute("data-og-theme");
2606
+ n && o.setAttribute("data-og-theme", n), document.body.appendChild(o), this._el = o, this._docMouseMove = (r) => {
2604
2607
  if (!this._el) return;
2605
2608
  const l = this._el.getBoundingClientRect();
2606
2609
  (r.clientX < l.left - 4 || r.clientX > l.right + 4 || r.clientY < l.top - 4 || r.clientY > l.bottom + 4) && this.close();
2607
- }, this._position(i, t.clientX, t.clientY, () => {
2608
- this._el === i && document.addEventListener("mousemove", this._docMouseMove, { capture: !0, passive: !0 });
2610
+ }, this._position(o, t.clientX, t.clientY, () => {
2611
+ this._el === o && document.addEventListener("mousemove", this._docMouseMove, { capture: !0, passive: !0 });
2609
2612
  }), this._docClick = (r) => {
2610
- i.contains(r.target) || this.close();
2613
+ o.contains(r.target) || this.close();
2611
2614
  }, this._docKey = (r) => {
2612
2615
  if (r.key === "Escape") {
2613
2616
  this.close();
@@ -2622,7 +2625,7 @@ class je {
2622
2625
  return;
2623
2626
  }
2624
2627
  if (r.key === "Enter") {
2625
- const l = i.querySelector(".og-cm-item:focus");
2628
+ const l = o.querySelector(".og-cm-item:focus");
2626
2629
  l == null || l.click();
2627
2630
  }
2628
2631
  }, this._docScroll = () => this.close(), setTimeout(() => {
@@ -2637,10 +2640,10 @@ class je {
2637
2640
  this.close();
2638
2641
  }
2639
2642
  // ── 위치 결정 ─────────────────────────────────────────────
2640
- _position(t, e, s, i) {
2643
+ _position(t, e, s, o) {
2641
2644
  t.style.cssText = "position:fixed;visibility:hidden;left:0;top:0;", requestAnimationFrame(() => {
2642
- const { width: o, height: n } = t.getBoundingClientRect(), r = window.innerWidth, l = window.innerHeight, a = e + o > r ? Math.max(0, e - o) : e, c = s + n > l ? Math.max(0, s - n) : s;
2643
- t.style.cssText = `position:fixed;left:${a}px;top:${c}px;z-index:9999;`, i == null || i();
2645
+ const { width: i, height: n } = t.getBoundingClientRect(), r = window.innerWidth, l = window.innerHeight, a = e + i > r ? Math.max(0, e - i) : e, c = s + n > l ? Math.max(0, s - n) : s;
2646
+ t.style.cssText = `position:fixed;left:${a}px;top:${c}px;z-index:9999;`, o == null || o();
2644
2647
  });
2645
2648
  }
2646
2649
  // ── 키보드 포커스 이동 ────────────────────────────────────
@@ -2680,7 +2683,7 @@ class je {
2680
2683
  }
2681
2684
  }
2682
2685
  }
2683
- class Kt {
2686
+ class Vt {
2684
2687
  constructor(t, e) {
2685
2688
  this._sheets = /* @__PURE__ */ new Map(), this._active = "", this._onSwitch = e, this._tabBar = this._buildTabBar(t);
2686
2689
  }
@@ -2703,7 +2706,7 @@ class Kt {
2703
2706
  throw new Error(`WorksheetManager: 시트 '${e}'이 이미 존재합니다`);
2704
2707
  this._sheets.get(t);
2705
2708
  const s = Array.from(this._sheets.entries()).map(
2706
- ([i, o]) => i === t ? [e, { ...o, name: e }] : [i, o]
2709
+ ([o, i]) => o === t ? [e, { ...i, name: e }] : [o, i]
2707
2710
  );
2708
2711
  this._sheets = new Map(s), this._active === t && (this._active = e), this._renderTabs();
2709
2712
  }
@@ -2752,20 +2755,20 @@ class Kt {
2752
2755
  _startRename(t, e) {
2753
2756
  const s = document.createElement("input");
2754
2757
  s.className = "og-sheet-tab-rename", s.value = e, t.replaceWith(s), s.focus(), s.select();
2755
- const i = () => {
2756
- const o = s.value.trim() || e;
2758
+ const o = () => {
2759
+ const i = s.value.trim() || e;
2757
2760
  try {
2758
- o !== e ? this.rename(e, o) : this._renderTabs();
2761
+ i !== e ? this.rename(e, i) : this._renderTabs();
2759
2762
  } catch {
2760
2763
  this._renderTabs();
2761
2764
  }
2762
2765
  };
2763
- s.addEventListener("blur", i), s.addEventListener("keydown", (o) => {
2764
- o.key === "Enter" && s.blur(), o.key === "Escape" && (s.value = e, s.blur());
2766
+ s.addEventListener("blur", o), s.addEventListener("keydown", (i) => {
2767
+ i.key === "Enter" && s.blur(), i.key === "Escape" && (s.value = e, s.blur());
2765
2768
  });
2766
2769
  }
2767
2770
  }
2768
- class Ue {
2771
+ class qe {
2769
2772
  constructor(t) {
2770
2773
  this._d = t;
2771
2774
  }
@@ -2775,15 +2778,15 @@ class Ue {
2775
2778
  _hexToXlsxRgb(t) {
2776
2779
  const e = t.trim(), s = e.match(/^rgba?\(\s*(\d+),\s*(\d+),\s*(\d+)/i);
2777
2780
  if (s)
2778
- return [s[1], s[2], s[3]].map((o) => parseInt(o).toString(16).padStart(2, "0")).join("").toUpperCase();
2779
- const i = e.replace("#", "").toUpperCase();
2780
- return i.length === 3 ? i[0] + i[0] + i[1] + i[1] + i[2] + i[2] : i.length === 6 ? i : "";
2781
+ return [s[1], s[2], s[3]].map((i) => parseInt(i).toString(16).padStart(2, "0")).join("").toUpperCase();
2782
+ const o = e.replace("#", "").toUpperCase();
2783
+ return o.length === 3 ? o[0] + o[0] + o[1] + o[1] + o[2] + o[2] : o.length === 6 ? o : "";
2781
2784
  }
2782
2785
  exportExcel(t) {
2783
2786
  const e = typeof t == "string" ? { filename: t } : t ?? {};
2784
2787
  let s = e.filename ?? "export";
2785
2788
  s.toLowerCase().endsWith(".xlsx") || (s += ".xlsx");
2786
- const i = e.sheetName ?? (this._d.getOptions().ariaLabel || "Sheet1"), o = this._d.getData(), n = this._d.getColLayout().visibleLeaves.filter((a) => {
2789
+ const o = e.sheetName ?? (this._d.getOptions().ariaLabel || "Sheet1"), i = this._d.getData(), n = this._d.getColLayout().visibleLeaves.filter((a) => {
2787
2790
  var c;
2788
2791
  return !((c = e.exceptFields) != null && c.includes(a.field));
2789
2792
  }), r = e.includeHeader !== !1, l = (this._d.getStrategy ?? ((a, c) => c))(
@@ -2791,89 +2794,89 @@ class Ue {
2791
2794
  (a, c, u) => c.type === "number" && typeof a == "number" ? a : typeof a == "boolean" ? a ? "✓" : "" : typeof a == "object" ? "" : String(a)
2792
2795
  );
2793
2796
  import("./xlsx.min-Wavxcamn.js").then((a) => a.x).then(({ utils: a, writeFile: c }) => {
2794
- var A;
2797
+ var z;
2795
2798
  const u = [];
2796
- r && u.push(n.map(($) => $.header));
2797
- for (const $ of o)
2798
- u.push(n.map((p) => {
2799
- const C = $[p.field];
2800
- if (e.maskOnExport && p.mask && this._d.getMaskEnabled(p.field))
2801
- return kt(C == null ? "" : String(C), p.mask);
2802
- const O = C;
2803
- return O == null || O === "" ? "" : l(O, p, $);
2799
+ r && u.push(n.map((S) => S.header));
2800
+ for (const S of i)
2801
+ u.push(n.map((_) => {
2802
+ const M = S[_.field];
2803
+ if (e.maskOnExport && _.mask && this._d.getMaskEnabled(_.field))
2804
+ return Rt(M == null ? "" : String(M), _.mask);
2805
+ const F = M;
2806
+ return F == null || F === "" ? "" : l(F, _, S);
2804
2807
  }));
2805
2808
  const h = a.aoa_to_sheet(u), g = this._d.getColWidths(), k = this._d.getColLayout();
2806
- h["!cols"] = n.map(($) => ({
2807
- wpx: g[k.getColumnIndex($.field)] ?? 100
2808
- })), h["!rows"] = u.map(($, p) => ({ hpx: p === 0 && r ? 22 : 19 }));
2809
- const m = e.styleMode ?? "theme";
2810
- let w = "1565C0", x = "FFFFFF", _ = "FFFFFF", b = "EEF2FF", L = "212121", v = "BDBDBD", R = 10;
2811
- if (m === "theme") {
2812
- const $ = (C) => this._hexToXlsxRgb(C);
2813
- w = $(this._readCssVar("--og-header-bg")) || w, x = $(this._readCssVar("--og-header-color")) || x, _ = $(this._readCssVar("--og-row-bg")) || _, b = $(this._readCssVar("--og-row-alt-bg")) || b, L = $(this._readCssVar("--og-row-color")) || L, v = $(this._readCssVar("--og-border-color")) || v;
2814
- const p = this._readCssVar("--og-font-size");
2815
- p && (R = Math.max(8, Math.round(parseFloat(p) * 0.75)));
2809
+ h["!cols"] = n.map((S) => ({
2810
+ wpx: g[k.getColumnIndex(S.field)] ?? 100
2811
+ })), h["!rows"] = u.map((S, _) => ({ hpx: _ === 0 && r ? 22 : 19 }));
2812
+ const y = e.styleMode ?? "theme";
2813
+ let b = "1565C0", x = "FFFFFF", p = "FFFFFF", v = "EEF2FF", T = "212121", A = "BDBDBD", E = 10;
2814
+ if (y === "theme") {
2815
+ const S = (M) => this._hexToXlsxRgb(M);
2816
+ b = S(this._readCssVar("--og-header-bg")) || b, x = S(this._readCssVar("--og-header-color")) || x, p = S(this._readCssVar("--og-row-bg")) || p, v = S(this._readCssVar("--og-row-alt-bg")) || v, T = S(this._readCssVar("--og-row-color")) || T, A = S(this._readCssVar("--og-border-color")) || A;
2817
+ const _ = this._readCssVar("--og-font-size");
2818
+ _ && (E = Math.max(8, Math.round(parseFloat(_) * 0.75)));
2816
2819
  }
2817
- const F = m === "none", I = {
2818
- hdrFont: F ? {} : { bold: !0, color: { rgb: x }, sz: R, name: "맑은 고딕" },
2819
- dataFont: F ? {} : { sz: R, color: { rgb: L }, name: "맑은 고딕" },
2820
- hdrFill: F ? {} : { patternType: "solid", fgColor: { rgb: w } },
2821
- evenFill: F ? {} : { patternType: "solid", fgColor: { rgb: _ } },
2822
- oddFill: F ? {} : { patternType: "solid", fgColor: { rgb: b } },
2823
- hdrBorder: F ? {} : {
2824
- top: { style: "medium", color: { rgb: w } },
2825
- bottom: { style: "medium", color: { rgb: w } },
2826
- left: { style: "thin", color: { rgb: w } },
2827
- right: { style: "thin", color: { rgb: w } }
2820
+ const f = y === "none", $ = {
2821
+ hdrFont: f ? {} : { bold: !0, color: { rgb: x }, sz: E, name: "맑은 고딕" },
2822
+ dataFont: f ? {} : { sz: E, color: { rgb: T }, name: "맑은 고딕" },
2823
+ hdrFill: f ? {} : { patternType: "solid", fgColor: { rgb: b } },
2824
+ evenFill: f ? {} : { patternType: "solid", fgColor: { rgb: p } },
2825
+ oddFill: f ? {} : { patternType: "solid", fgColor: { rgb: v } },
2826
+ hdrBorder: f ? {} : {
2827
+ top: { style: "medium", color: { rgb: b } },
2828
+ bottom: { style: "medium", color: { rgb: b } },
2829
+ left: { style: "thin", color: { rgb: b } },
2830
+ right: { style: "thin", color: { rgb: b } }
2828
2831
  },
2829
- dataBorder: F ? {} : {
2830
- top: { style: "thin", color: { rgb: v } },
2831
- bottom: { style: "thin", color: { rgb: v } },
2832
- left: { style: "thin", color: { rgb: v } },
2833
- right: { style: "thin", color: { rgb: v } }
2832
+ dataBorder: f ? {} : {
2833
+ top: { style: "thin", color: { rgb: A } },
2834
+ bottom: { style: "thin", color: { rgb: A } },
2835
+ left: { style: "thin", color: { rgb: A } },
2836
+ right: { style: "thin", color: { rgb: A } }
2834
2837
  }
2835
2838
  };
2836
- u.forEach(($, p) => {
2837
- const C = r && p === 0, lt = (r ? p - 1 : p) % 2 === 0;
2838
- $.forEach((X, st) => {
2839
- const f = a.encode_cell({ r: p, c: st });
2840
- h[f] || (h[f] = { t: "s", v: "" });
2841
- const S = n[st], H = S.type === "number" || S.align === "right", tt = C ? "center" : H ? "right" : S.align ?? "left";
2842
- h[f].s = {
2843
- font: C ? I.hdrFont : I.dataFont,
2844
- fill: C ? I.hdrFill : lt ? I.evenFill : I.oddFill,
2845
- border: C ? I.hdrBorder : I.dataBorder,
2846
- alignment: { horizontal: tt, vertical: "center", wrapText: !1 }
2839
+ u.forEach((S, _) => {
2840
+ const M = r && _ === 0, W = (r ? _ - 1 : _) % 2 === 0;
2841
+ S.forEach((St, it) => {
2842
+ const V = a.encode_cell({ r: _, c: it });
2843
+ h[V] || (h[V] = { t: "s", v: "" });
2844
+ const et = n[it], m = et.type === "number" || et.align === "right", L = M ? "center" : m ? "right" : et.align ?? "left";
2845
+ h[V].s = {
2846
+ font: M ? $.hdrFont : $.dataFont,
2847
+ fill: M ? $.hdrFill : W ? $.evenFill : $.oddFill,
2848
+ border: M ? $.hdrBorder : $.dataBorder,
2849
+ alignment: { horizontal: L, vertical: "center", wrapText: !1 }
2847
2850
  };
2848
2851
  });
2849
2852
  });
2850
- const T = a.book_new();
2851
- a.book_append_sheet(T, h, i), c(T, s, { cellStyles: !0 }), (A = e.onAfter) == null || A.call(e, new Blob([]));
2853
+ const B = a.book_new();
2854
+ a.book_append_sheet(B, h, o), c(B, s, { cellStyles: !0 }), (z = e.onAfter) == null || z.call(e, new Blob([]));
2852
2855
  }).catch(() => {
2853
2856
  console.error("Excel 내보내기 실패: xlsx 패키지를 확인하세요.");
2854
2857
  });
2855
2858
  }
2856
2859
  exportCsv(t) {
2857
- const e = typeof t == "string" ? { filename: t } : t ?? {}, s = this._d.getData(), i = this._d.getColLayout().visibleLeaves, o = i.map((l) => `"${l.header}"`).join(","), n = s.map((l) => i.map((a) => {
2860
+ const e = typeof t == "string" ? { filename: t } : t ?? {}, s = this._d.getData(), o = this._d.getColLayout().visibleLeaves, i = o.map((l) => `"${l.header}"`).join(","), n = s.map((l) => o.map((a) => {
2858
2861
  const c = l[a.field] ?? "";
2859
2862
  if (e.maskOnExport && a.mask && this._d.getMaskEnabled(a.field))
2860
- return kt(String(c), a.mask);
2863
+ return Rt(String(c), a.mask);
2861
2864
  const u = c;
2862
2865
  return typeof u == "string" && u.includes(",") ? `"${u}"` : u;
2863
2866
  }).join(",")), r = e.filename ?? "export.csv";
2864
- It("\uFEFF" + [o, ...n].join(`
2867
+ Ot("\uFEFF" + [i, ...n].join(`
2865
2868
  `), r);
2866
2869
  }
2867
2870
  exportJson(t) {
2868
2871
  const e = typeof t == "string" ? t : (t == null ? void 0 : t.filename) ?? "export.json";
2869
- It(JSON.stringify(this._d.getData(), null, 2), e, "application/json");
2872
+ Ot(JSON.stringify(this._d.getData(), null, 2), e, "application/json");
2870
2873
  }
2871
2874
  print(t) {
2872
- const e = (t == null ? void 0 : t.title) ?? "OPEN_GRID", s = (t == null ? void 0 : t.footerText) ?? "", i = this._d.getData(), o = this._d.getColLayout().visibleLeaves.filter((u) => {
2875
+ const e = (t == null ? void 0 : t.title) ?? "OPEN_GRID", s = (t == null ? void 0 : t.footerText) ?? "", o = this._d.getData(), i = this._d.getColLayout().visibleLeaves.filter((u) => {
2873
2876
  var h;
2874
2877
  return !((h = t == null ? void 0 : t.excludeFields) != null && h.includes(u.field));
2875
- }), n = o.map((u) => `<th>${u.header ?? u.field}</th>`).join(""), r = i.map(
2876
- (u) => `<tr>${o.map((h) => `<td>${String(u[h.field] ?? "")}</td>`).join("")}</tr>`
2878
+ }), n = i.map((u) => `<th>${u.header ?? u.field}</th>`).join(""), r = o.map(
2879
+ (u) => `<tr>${i.map((h) => `<td>${String(u[h.field] ?? "")}</td>`).join("")}</tr>`
2877
2880
  ).join(""), l = s ? `<div class="og-print-footer">${s}</div>` : "", a = `<!DOCTYPE html>
2878
2881
  <html lang="ko"><head>
2879
2882
  <meta charset="UTF-8"><title>${e}</title>
@@ -2890,7 +2893,7 @@ class Ue {
2890
2893
  </style>
2891
2894
  </head><body>
2892
2895
  <h2>${e}</h2>
2893
- <p>${i.length}행 × ${o.length}열 · ${(/* @__PURE__ */ new Date()).toLocaleString("ko-KR")}</p>
2896
+ <p>${o.length}행 × ${i.length}열 · ${(/* @__PURE__ */ new Date()).toLocaleString("ko-KR")}</p>
2894
2897
  <table>
2895
2898
  <thead><tr>${n}</tr></thead>
2896
2899
  <tbody>${r}</tbody>
@@ -2906,72 +2909,72 @@ ${l}
2906
2909
  this.exportExcel(t ?? "workbook");
2907
2910
  return;
2908
2911
  }
2909
- const s = t ?? "workbook.xlsx", i = (this._d.getStrategy ?? ((o, n) => n))(
2912
+ const s = t ?? "workbook.xlsx", o = (this._d.getStrategy ?? ((i, n) => n))(
2910
2913
  "cellSerializer",
2911
- (o, n, r) => typeof o == "boolean" ? o ? "✓" : "" : n.type === "number" && typeof o == "number" ? o : String(o)
2914
+ (i, n, r) => typeof i == "boolean" ? i ? "✓" : "" : n.type === "number" && typeof i == "number" ? i : String(i)
2912
2915
  );
2913
- import("./xlsx.min-Wavxcamn.js").then((o) => o.x).then(({ utils: o, writeFile: n }) => {
2914
- const r = o.book_new(), l = this._d.getOptions();
2916
+ import("./xlsx.min-Wavxcamn.js").then((i) => i.x).then(({ utils: i, writeFile: n }) => {
2917
+ const r = i.book_new(), l = this._d.getOptions();
2915
2918
  for (const a of e.getNames()) {
2916
2919
  const c = e.get(a), u = c.columns.length ? c.columns : l.columns, h = [u.map((k) => k.header)];
2917
2920
  for (const k of c.data)
2918
- h.push(u.map((m) => {
2919
- const w = k[m.field];
2920
- return w == null ? "" : i(w, m, k);
2921
+ h.push(u.map((y) => {
2922
+ const b = k[y.field];
2923
+ return b == null ? "" : o(b, y, k);
2921
2924
  }));
2922
- const g = o.aoa_to_sheet(h);
2923
- g["!cols"] = u.map(() => ({ wpx: 100 })), o.book_append_sheet(r, g, a);
2925
+ const g = i.aoa_to_sheet(h);
2926
+ g["!cols"] = u.map(() => ({ wpx: 100 })), i.book_append_sheet(r, g, a);
2924
2927
  }
2925
2928
  n(r, s.endsWith(".xlsx") ? s : s + ".xlsx", { cellStyles: !0 });
2926
2929
  }).catch(() => console.error("exportSheetsExcel: xlsx 패키지를 확인하세요."));
2927
2930
  }
2928
2931
  }
2929
- class Ge {
2932
+ class Xe {
2930
2933
  constructor(t) {
2931
2934
  this._d = t;
2932
2935
  }
2933
2936
  fmtNum(t, e) {
2934
2937
  if (!e)
2935
2938
  return Math.round(t).toLocaleString("ko-KR");
2936
- const s = e.match(/[#0][#0,]*(?:\.[#0]+)?|\d+/), i = s ? e.slice(0, s.index) : "", o = s ? e.slice(s.index + s[0].length) : "", n = s ? s[0] : e, r = n.includes("#") || n.includes(","), l = n.match(/\.(\d+)$/), a = l ? parseInt(l[1], 10) : /^\d+$/.test(n) ? parseInt(n, 10) : 0, c = Math.abs(t).toFixed(a), [u = "0", h] = c.split("."), g = r ? u.replace(/\B(?=(\d{3})+(?!\d))/g, ",") : u, k = h !== void 0 ? `${g}.${h}` : g, m = `${i}${k}${o}`;
2937
- return t < 0 ? `-${m}` : m;
2939
+ const s = e.match(/[#0][#0,]*(?:\.[#0]+)?|\d+/), o = s ? e.slice(0, s.index) : "", i = s ? e.slice(s.index + s[0].length) : "", n = s ? s[0] : e, r = n.includes("#") || n.includes(","), l = n.match(/\.(\d+)$/), a = l ? parseInt(l[1], 10) : /^\d+$/.test(n) ? parseInt(n, 10) : 0, c = Math.abs(t).toFixed(a), [u = "0", h] = c.split("."), g = r ? u.replace(/\B(?=(\d{3})+(?!\d))/g, ",") : u, k = h !== void 0 ? `${g}.${h}` : g, y = `${o}${k}${i}`;
2940
+ return t < 0 ? `-${y}` : y;
2938
2941
  }
2939
2942
  computeValues() {
2940
2943
  const t = this._d.getOptions().footer;
2941
2944
  if (!t || t.length === 0) return [];
2942
2945
  const e = this._d.getData();
2943
2946
  return t.filter((s) => s.field && s.op).map((s) => {
2944
- const i = s.field, o = s.op, n = e.map((h) => h[i]).filter((h) => h != null && h !== "");
2947
+ const o = s.field, i = s.op, n = e.map((h) => h[o]).filter((h) => h != null && h !== "");
2945
2948
  let r = null;
2946
- const l = o.toUpperCase(), a = (this._d.getStrategy ?? ((h, g) => g))(
2949
+ const l = i.toUpperCase(), a = (this._d.getStrategy ?? ((h, g) => g))(
2947
2950
  "summaryOp",
2948
2951
  null
2949
2952
  );
2950
2953
  if (a) {
2951
- const h = a(l, n, i);
2954
+ const h = a(l, n, o);
2952
2955
  if (h != null)
2953
- return { _field: i, _value: h, _formatted: this.fmtNum(h, s.format) };
2956
+ return { _field: o, _value: h, _formatted: this.fmtNum(h, s.format) };
2954
2957
  }
2955
2958
  if (l === "SUM")
2956
- r = n.length > 0 ? M.sum(n.map((h) => String(h))) : null;
2959
+ r = n.length > 0 ? C.sum(n.map((h) => String(h))) : null;
2957
2960
  else if (l === "AVG")
2958
- r = n.length > 0 ? M.sum(n.map((h) => String(h))).div(M.from(String(n.length))) : null;
2961
+ r = n.length > 0 ? C.sum(n.map((h) => String(h))).div(C.from(String(n.length))) : null;
2959
2962
  else if (l === "COUNT") {
2960
2963
  const h = n.length;
2961
- return { _field: i, _value: h, _formatted: h.toLocaleString("ko-KR") };
2962
- } else l === "MAX" ? r = n.length > 0 ? M.max(n.map((h) => String(h))) : null : l === "MIN" && (r = n.length > 0 ? M.min(n.map((h) => String(h))) : null);
2963
- if (!r) return { _field: i, _value: null, _formatted: "" };
2964
+ return { _field: o, _value: h, _formatted: h.toLocaleString("ko-KR") };
2965
+ } else l === "MAX" ? r = n.length > 0 ? C.max(n.map((h) => String(h))) : null : l === "MIN" && (r = n.length > 0 ? C.min(n.map((h) => String(h))) : null);
2966
+ if (!r) return { _field: o, _value: null, _formatted: "" };
2964
2967
  const c = r.toNumber(), u = this.fmtNum(c, s.format);
2965
- return { _field: i, _value: c, _formatted: u };
2968
+ return { _field: o, _value: c, _formatted: u };
2966
2969
  });
2967
2970
  }
2968
2971
  render() {
2969
2972
  var u;
2970
2973
  const t = this._d.getContainer(), e = t.querySelector(".og-footer-bar");
2971
2974
  e == null || e.remove();
2972
- const s = this._d.getOptions(), i = s.footer;
2973
- if (!i || i.length === 0) return;
2974
- const o = this._d.getColLayout().visibleLeaves, n = this._d.getColWidths() ?? o.map((h) => h.width ?? 100), r = new Map(
2975
+ const s = this._d.getOptions(), o = s.footer;
2976
+ if (!o || o.length === 0) return;
2977
+ const i = this._d.getColLayout().visibleLeaves, n = this._d.getColWidths() ?? i.map((h) => h.width ?? 100), r = new Map(
2975
2978
  this.computeValues().map((h) => [h._field, h])
2976
2979
  ), l = document.createElement("div");
2977
2980
  l.className = "og-footer-bar", l.style.cssText = [
@@ -2987,31 +2990,31 @@ class Ge {
2987
2990
  h.style.cssText = `width:${a}px;flex-shrink:0;border-right:1px solid var(--og-border-color,#e0e0e0);`, l.appendChild(h);
2988
2991
  }
2989
2992
  let c = 0;
2990
- for (const h of i) {
2993
+ for (const h of o) {
2991
2994
  const g = Math.max(1, h.colspan ?? 1);
2992
2995
  let k = 0;
2993
- for (let b = 0; b < g; b++)
2994
- k += n[c + b] ?? 100;
2995
- const m = o[c];
2996
+ for (let v = 0; v < g; v++)
2997
+ k += n[c + v] ?? 100;
2998
+ const y = i[c];
2996
2999
  c += g;
2997
- const w = document.createElement("div");
2998
- w.style.cssText = [
3000
+ const b = document.createElement("div");
3001
+ b.style.cssText = [
2999
3002
  `width:${k}px;min-width:${k}px;flex-shrink:0;`,
3000
3003
  "padding:4px 8px;box-sizing:border-box;overflow:hidden;",
3001
3004
  "border-right:1px solid var(--og-border-color,#e0e0e0);",
3002
3005
  "white-space:nowrap;text-overflow:ellipsis;"
3003
3006
  ].join("");
3004
- const x = h.field, _ = x ? r.get(x) : null;
3005
- if (_) {
3006
- const b = _._formatted ?? String(_._value ?? ""), L = h.label ? `${h.label}: ` : "";
3007
- w.textContent = L + b, w.title = `${((u = h.op) == null ? void 0 : u.toUpperCase()) ?? ""} = ${b}`, w.style.color = "var(--og-primary,#1976d2)", w.style.textAlign = h.align ?? ((m == null ? void 0 : m.type) === "number", "right");
3008
- } else h.label && (w.textContent = h.label, w.style.textAlign = h.align ?? "left", w.style.color = "var(--og-row-color,#212121)");
3009
- l.appendChild(w);
3007
+ const x = h.field, p = x ? r.get(x) : null;
3008
+ if (p) {
3009
+ const v = p._formatted ?? String(p._value ?? ""), T = h.label ? `${h.label}: ` : "";
3010
+ b.textContent = T + v, b.title = `${((u = h.op) == null ? void 0 : u.toUpperCase()) ?? ""} = ${v}`, b.style.color = "var(--og-primary,#1976d2)", b.style.textAlign = h.align ?? ((y == null ? void 0 : y.type) === "number", "right");
3011
+ } else h.label && (b.textContent = h.label, b.style.textAlign = h.align ?? "left", b.style.color = "var(--og-row-color,#212121)");
3012
+ l.appendChild(b);
3010
3013
  }
3011
3014
  s.footerPosition === "top" ? t.insertBefore(l, t.firstChild) : t.appendChild(l);
3012
3015
  }
3013
3016
  }
3014
- class qe {
3017
+ class Ye {
3015
3018
  constructor(t) {
3016
3019
  this._d = t;
3017
3020
  }
@@ -3019,8 +3022,8 @@ class qe {
3019
3022
  const e = this._d.getEditMgr();
3020
3023
  if (e.activeEditor) return;
3021
3024
  this._d.handleCellKeyEvt("cellKeyDown", t);
3022
- const s = this._d.getData(), i = this._d.getColLayout(), o = s.rowCount, n = i.visibleLeaves.length;
3023
- if (o === 0 || n === 0) return;
3025
+ const s = this._d.getData(), o = this._d.getColLayout(), i = s.rowCount, n = o.visibleLeaves.length;
3026
+ if (i === 0 || n === 0) return;
3024
3027
  if ((t.ctrlKey || t.metaKey) && t.key === "c") {
3025
3028
  t.preventDefault(), this._copyToClipboard();
3026
3029
  return;
@@ -3034,7 +3037,7 @@ class qe {
3034
3037
  if (t.key === "ArrowDown") {
3035
3038
  t.preventDefault();
3036
3039
  const l = e.focusCell.ci !== void 0 ? e.focusCell.ri : 0;
3037
- l < o - 1 && (this._d.handleRowDrop(l, l + 1), this._d.setFocusCell(l + 1, e.focusCell.ci), this._d.announce(`행 ${l + 1}을(를) ${l + 2}번째 위치로 이동`));
3040
+ l < i - 1 && (this._d.handleRowDrop(l, l + 1), this._d.setFocusCell(l + 1, e.focusCell.ci), this._d.announce(`행 ${l + 1}을(를) ${l + 2}번째 위치로 이동`));
3038
3041
  return;
3039
3042
  }
3040
3043
  if (t.key === "ArrowUp") {
@@ -3047,7 +3050,7 @@ class qe {
3047
3050
  switch (t.key) {
3048
3051
  case "ArrowDown": {
3049
3052
  t.preventDefault();
3050
- const l = e.focusCell, a = l ? Math.min(l.ri + 1, o - 1) : 0;
3053
+ const l = e.focusCell, a = l ? Math.min(l.ri + 1, i - 1) : 0;
3051
3054
  this._d.setFocusCell(a, (l == null ? void 0 : l.ci) ?? 0);
3052
3055
  break;
3053
3056
  }
@@ -3064,7 +3067,7 @@ class qe {
3064
3067
  this._d.setFocusCell(0, 0);
3065
3068
  break;
3066
3069
  }
3067
- l.ci < n - 1 ? this._d.setFocusCell(l.ri, l.ci + 1) : l.ri < o - 1 && this._d.setFocusCell(l.ri + 1, 0);
3070
+ l.ci < n - 1 ? this._d.setFocusCell(l.ri, l.ci + 1) : l.ri < i - 1 && this._d.setFocusCell(l.ri + 1, 0);
3068
3071
  break;
3069
3072
  }
3070
3073
  case "ArrowLeft": {
@@ -3084,7 +3087,7 @@ class qe {
3084
3087
  this._d.setFocusCell(0, 0);
3085
3088
  break;
3086
3089
  }
3087
- t.shiftKey ? l.ci > 0 ? this._d.setFocusCell(l.ri, l.ci - 1) : l.ri > 0 && this._d.setFocusCell(l.ri - 1, n - 1) : l.ci < n - 1 ? this._d.setFocusCell(l.ri, l.ci + 1) : l.ri < o - 1 && this._d.setFocusCell(l.ri + 1, 0);
3090
+ t.shiftKey ? l.ci > 0 ? this._d.setFocusCell(l.ri, l.ci - 1) : l.ri > 0 && this._d.setFocusCell(l.ri - 1, n - 1) : l.ci < n - 1 ? this._d.setFocusCell(l.ri, l.ci + 1) : l.ri < i - 1 && this._d.setFocusCell(l.ri + 1, 0);
3088
3091
  break;
3089
3092
  }
3090
3093
  case "Home": {
@@ -3098,7 +3101,7 @@ class qe {
3098
3101
  }
3099
3102
  case "End": {
3100
3103
  if (t.preventDefault(), t.ctrlKey || t.metaKey)
3101
- this._d.setFocusCell(o - 1, n - 1);
3104
+ this._d.setFocusCell(i - 1, n - 1);
3102
3105
  else {
3103
3106
  const l = e.focusCell;
3104
3107
  this._d.setFocusCell((l == null ? void 0 : l.ri) ?? 0, n - 1);
@@ -3107,7 +3110,7 @@ class qe {
3107
3110
  }
3108
3111
  case "PageDown": {
3109
3112
  t.preventDefault();
3110
- const l = e.focusCell, a = this._d.getOptions().pageSize ?? 10, c = Math.min(l ? l.ri + a : a - 1, o - 1);
3113
+ const l = e.focusCell, a = this._d.getOptions().pageSize ?? 10, c = Math.min(l ? l.ri + a : a - 1, i - 1);
3111
3114
  this._d.setFocusCell(c, (l == null ? void 0 : l.ci) ?? 0);
3112
3115
  break;
3113
3116
  }
@@ -3139,20 +3142,20 @@ class qe {
3139
3142
  _copyToClipboard() {
3140
3143
  var n;
3141
3144
  if (!this._d.getOptions().clipboard) return;
3142
- const e = this._d.getEditMgr(), s = this._d.getColLayout(), i = this._d.getData();
3143
- let o = "";
3145
+ const e = this._d.getEditMgr(), s = this._d.getColLayout(), o = this._d.getData();
3146
+ let i = "";
3144
3147
  if (e.focusCell) {
3145
3148
  const { ri: r, ci: l } = e.focusCell, a = s.visibleLeaves[l];
3146
- a && (o = String(i.getCellValue(r, a.field) ?? ""));
3149
+ a && (i = String(o.getCellValue(r, a.field) ?? ""));
3147
3150
  } else if (this._d.getRowMgr().selectedRows.size > 0) {
3148
3151
  const r = s.visibleLeaves;
3149
- o = [...this._d.getRowMgr().selectedRows].sort((a, c) => a - c).map((a) => {
3150
- const c = i.getRowByIndex(a);
3152
+ i = [...this._d.getRowMgr().selectedRows].sort((a, c) => a - c).map((a) => {
3153
+ const c = o.getRowByIndex(a);
3151
3154
  return r.map((u) => String((c == null ? void 0 : c[u.field]) ?? "")).join(" ");
3152
3155
  }).join(`
3153
3156
  `);
3154
3157
  }
3155
- o && ((n = navigator.clipboard) == null || n.writeText(o).catch(() => {
3158
+ i && ((n = navigator.clipboard) == null || n.writeText(i).catch(() => {
3156
3159
  }));
3157
3160
  }
3158
3161
  _pasteFromClipboard() {
@@ -3160,15 +3163,15 @@ class qe {
3160
3163
  const t = this._d.getOptions();
3161
3164
  if (!t.clipboard || !t.editable) return;
3162
3165
  const e = this._d.getEditMgr();
3163
- e.focusCell && ((s = navigator.clipboard) == null || s.readText().then((i) => {
3164
- if (!i) return;
3165
- const { ri: o, ci: n } = e.focusCell, r = i.split(`
3166
+ e.focusCell && ((s = navigator.clipboard) == null || s.readText().then((o) => {
3167
+ if (!o) return;
3168
+ const { ri: i, ci: n } = e.focusCell, r = o.split(`
3166
3169
  `), l = this._d.getColLayout().visibleLeaves, a = this._d.getData();
3167
3170
  for (let c = 0; c < r.length; c++) {
3168
3171
  const u = r[c].split(" ");
3169
3172
  for (let h = 0; h < u.length; h++) {
3170
- const g = o + c, k = n + h, m = l[k];
3171
- m && g < a.rowCount && a.updateCell(g, m.field, u[h]);
3173
+ const g = i + c, k = n + h, y = l[k];
3174
+ y && g < a.rowCount && a.updateCell(g, y.field, u[h]);
3172
3175
  }
3173
3176
  }
3174
3177
  this._d.emit("dataChange", a.getData()), this._d.doRender();
@@ -3176,7 +3179,7 @@ class qe {
3176
3179
  }));
3177
3180
  }
3178
3181
  }
3179
- class Xe {
3182
+ class Je {
3180
3183
  constructor(t) {
3181
3184
  this._bar = null, this._input = null, this._count = null, this._filter = "", this._d = t;
3182
3185
  }
@@ -3188,16 +3191,16 @@ class Xe {
3188
3191
  e.className = "og-find-bar", e.hidden = !0;
3189
3192
  const s = document.createElement("span");
3190
3193
  s.className = "og-find-label", s.textContent = "찾기";
3191
- const i = document.createElement("input");
3192
- i.type = "text", i.className = "og-find-input", i.placeholder = "검색어 입력...", i.setAttribute("aria-label", "그리드 내 검색");
3193
- const o = document.createElement("span");
3194
- o.className = "og-find-count";
3194
+ const o = document.createElement("input");
3195
+ o.type = "text", o.className = "og-find-input", o.placeholder = "검색어 입력...", o.setAttribute("aria-label", "그리드 내 검색");
3196
+ const i = document.createElement("span");
3197
+ i.className = "og-find-count";
3195
3198
  const n = document.createElement("button");
3196
- n.className = "og-find-close", n.textContent = "✕", n.setAttribute("aria-label", "찾기 닫기"), e.appendChild(s), e.appendChild(i), e.appendChild(o), e.appendChild(n), t.insertBefore(e, t.firstChild), i.addEventListener("input", () => {
3197
- this._filter = i.value.trim(), this._apply();
3198
- }), i.addEventListener("keydown", (r) => {
3199
+ n.className = "og-find-close", n.textContent = "✕", n.setAttribute("aria-label", "찾기 닫기"), e.appendChild(s), e.appendChild(o), e.appendChild(i), e.appendChild(n), t.insertBefore(e, t.firstChild), o.addEventListener("input", () => {
3200
+ this._filter = o.value.trim(), this._apply();
3201
+ }), o.addEventListener("keydown", (r) => {
3199
3202
  r.key === "Escape" && this.close();
3200
- }), n.addEventListener("click", () => this.close()), this._bar = e, this._input = i, this._count = o;
3203
+ }), n.addEventListener("click", () => this.close()), this._bar = e, this._input = o, this._count = i;
3201
3204
  }
3202
3205
  open() {
3203
3206
  this._bar && (this._bar.hidden = !1, this._input.focus(), this._input.select());
@@ -3206,20 +3209,20 @@ class Xe {
3206
3209
  this._bar && (this._bar.hidden = !0, this._filter = "", this._input.value = "", this._count && (this._count.textContent = ""), this._apply());
3207
3210
  }
3208
3211
  _apply() {
3209
- var i, o;
3212
+ var o, i;
3210
3213
  const t = this._d.getData(), e = this._d.getColLayout().visibleLeaves.map((n) => n.field);
3211
3214
  t.setFindFilter(this._filter, e), t.applyFilter(this._d.getFilters());
3212
3215
  const s = t.rowCount;
3213
- (i = this._d.getVs()) == null || i.setTotalRows(s), (o = this._d.getPagination()) == null || o.setTotalRows(s), this._count && (this._count.textContent = this._filter ? `${s}건` : ""), this._d.doRender();
3216
+ (o = this._d.getVs()) == null || o.setTotalRows(s), (i = this._d.getPagination()) == null || i.setTotalRows(s), this._count && (this._count.textContent = this._filter ? `${s}건` : ""), this._d.doRender();
3214
3217
  }
3215
3218
  }
3216
- function Yt(d) {
3219
+ function Qt(d) {
3217
3220
  return d && d._isGroup === !0;
3218
3221
  }
3219
- function Pt(d, t, e = [], s = /* @__PURE__ */ new Set(), i, o) {
3220
- return t.length ? Jt(d, t, 0, e, s, "", i, o) : [];
3222
+ function jt(d, t, e = [], s = /* @__PURE__ */ new Set(), o, i) {
3223
+ return t.length ? Zt(d, t, 0, e, s, "", o, i) : [];
3221
3224
  }
3222
- function Jt(d, t, e, s, i, o, n, r) {
3225
+ function Zt(d, t, e, s, o, i, n, r) {
3223
3226
  const l = t[e], a = /* @__PURE__ */ new Map();
3224
3227
  for (const u of d) {
3225
3228
  const h = r ? r(u, t.slice(e)) : u[l];
@@ -3227,10 +3230,10 @@ function Jt(d, t, e, s, i, o, n, r) {
3227
3230
  }
3228
3231
  const c = [];
3229
3232
  for (const [u, h] of a) {
3230
- const g = `${o}__${l}:${u}`, k = i.has(g);
3231
- let m;
3232
- e < t.length - 1 ? m = Jt(h, t, e + 1, s, i, g, n, r) : m = h;
3233
- const { summary: w, summaryFmt: x } = Ye(h, s), _ = Je(h, n);
3233
+ const g = `${i}__${l}:${u}`, k = o.has(g);
3234
+ let y;
3235
+ e < t.length - 1 ? y = Zt(h, t, e + 1, s, o, g, n, r) : y = h;
3236
+ const { summary: b, summaryFmt: x } = Qe(h, s), p = Ze(h, n);
3234
3237
  c.push({
3235
3238
  _isGroup: !0,
3236
3239
  _groupField: l,
@@ -3239,82 +3242,82 @@ function Jt(d, t, e, s, i, o, n, r) {
3239
3242
  _depth: e,
3240
3243
  _expanded: k,
3241
3244
  _childCount: h.length,
3242
- _summary: w,
3245
+ _summary: b,
3243
3246
  _summaryFmt: x,
3244
- _states: _,
3245
- children: m
3247
+ _states: p,
3248
+ children: y
3246
3249
  });
3247
3250
  }
3248
3251
  return c;
3249
3252
  }
3250
- function Ye(d, t) {
3253
+ function Qe(d, t) {
3251
3254
  const e = {}, s = {};
3252
- for (const i of t) {
3253
- const o = d.map((a) => a[i.field]).filter((a) => a != null && a !== "");
3255
+ for (const o of t) {
3256
+ const i = d.map((a) => a[o.field]).filter((a) => a != null && a !== "");
3254
3257
  let n = null;
3255
- const r = i.op.toUpperCase();
3258
+ const r = o.op.toUpperCase();
3256
3259
  if (r === "SUM")
3257
- n = o.length > 0 ? M.sum(o.map(String)) : null;
3260
+ n = i.length > 0 ? C.sum(i.map(String)) : null;
3258
3261
  else if (r === "AVG")
3259
- n = o.length > 0 ? M.sum(o.map(String)).div(M.from(String(o.length))) : null;
3262
+ n = i.length > 0 ? C.sum(i.map(String)).div(C.from(String(i.length))) : null;
3260
3263
  else if (r === "COUNT") {
3261
- e[i.field] = d.length, s[i.field] = d.length.toLocaleString("ko-KR");
3264
+ e[o.field] = d.length, s[o.field] = d.length.toLocaleString("ko-KR");
3262
3265
  continue;
3263
- } else r === "MAX" ? n = o.length > 0 ? M.max(o.map(String)) : null : r === "MIN" && (n = o.length > 0 ? M.min(o.map(String)) : null);
3266
+ } else r === "MAX" ? n = i.length > 0 ? C.max(i.map(String)) : null : r === "MIN" && (n = i.length > 0 ? C.min(i.map(String)) : null);
3264
3267
  if (!n) {
3265
- e[i.field] = null, s[i.field] = "";
3268
+ e[o.field] = null, s[o.field] = "";
3266
3269
  continue;
3267
3270
  }
3268
3271
  const l = n.toNumber();
3269
- e[i.field] = l, s[i.field] = Qe(l, i.format);
3272
+ e[o.field] = l, s[o.field] = ts(l, o.format);
3270
3273
  }
3271
3274
  return { summary: e, summaryFmt: s };
3272
3275
  }
3273
- function Je(d, t) {
3276
+ function Ze(d, t) {
3274
3277
  if (!t) return { added: 0, edited: 0, removed: 0 };
3275
- let e = 0, s = 0, i = 0;
3276
- for (const o of d) {
3277
- const n = t(o);
3278
- n === "added" ? e++ : n === "edited" ? s++ : n === "removed" && i++;
3278
+ let e = 0, s = 0, o = 0;
3279
+ for (const i of d) {
3280
+ const n = t(i);
3281
+ n === "added" ? e++ : n === "edited" ? s++ : n === "removed" && o++;
3279
3282
  }
3280
- return { added: e, edited: s, removed: i };
3283
+ return { added: e, edited: s, removed: o };
3281
3284
  }
3282
- function Qe(d, t) {
3285
+ function ts(d, t) {
3283
3286
  if (t == null)
3284
3287
  return d % 1 === 0 ? d.toLocaleString("ko-KR") : parseFloat(d.toFixed(6)).toLocaleString("ko-KR", {
3285
3288
  minimumFractionDigits: 2,
3286
3289
  maximumFractionDigits: 6
3287
3290
  });
3288
- const e = t.includes("#") || t.includes(","), s = t.match(/\.(\d+)$/), i = s ? parseInt(s[1], 10) : /^\d+$/.test(t) ? parseInt(t, 10) : 0, o = Math.abs(d).toFixed(i), [n = "0", r] = o.split("."), l = e ? n.replace(/\B(?=(\d{3})+(?!\d))/g, ",") : n, a = r !== void 0 ? `${l}.${r}` : l;
3291
+ const e = t.includes("#") || t.includes(","), s = t.match(/\.(\d+)$/), o = s ? parseInt(s[1], 10) : /^\d+$/.test(t) ? parseInt(t, 10) : 0, i = Math.abs(d).toFixed(o), [n = "0", r] = i.split("."), l = e ? n.replace(/\B(?=(\d{3})+(?!\d))/g, ",") : n, a = r !== void 0 ? `${l}.${r}` : l;
3289
3292
  return d < 0 ? `-${a}` : a;
3290
3293
  }
3291
- function Qt(d) {
3294
+ function te(d) {
3292
3295
  const t = [];
3293
3296
  for (const e of d)
3294
3297
  if (t.push(e), e._expanded)
3295
3298
  for (const s of e.children)
3296
- Yt(s) ? t.push(...Qt([s])) : t.push(s);
3299
+ Qt(s) ? t.push(...te([s])) : t.push(s);
3297
3300
  return t;
3298
3301
  }
3299
- function Zt(d, t = "") {
3302
+ function ee(d, t = "") {
3300
3303
  const e = [];
3301
3304
  for (const s of d) {
3302
- const i = `${t}__${s._groupField}:${s._groupValue}`;
3303
- e.push(i);
3304
- const o = s.children.filter((n) => Yt(n));
3305
- o.length && e.push(...Zt(o, i));
3305
+ const o = `${t}__${s._groupField}:${s._groupValue}`;
3306
+ e.push(o);
3307
+ const i = s.children.filter((n) => Qt(n));
3308
+ i.length && e.push(...ee(i, o));
3306
3309
  }
3307
3310
  return e;
3308
3311
  }
3309
- function Vt(d, t, e = /* @__PURE__ */ new Set()) {
3310
- const { idField: s, parentIdField: i, expandOnLoad: o = !1 } = t, n = /* @__PURE__ */ new Map(), r = [];
3312
+ function Ut(d, t, e = /* @__PURE__ */ new Set()) {
3313
+ const { idField: s, parentIdField: o, expandOnLoad: i = !1 } = t, n = /* @__PURE__ */ new Map(), r = [];
3311
3314
  for (const c of d) {
3312
3315
  const u = c[s], h = {
3313
3316
  _isTree: !0,
3314
3317
  _treeId: u,
3315
- _treeParentId: c[i],
3318
+ _treeParentId: c[o],
3316
3319
  _depth: 0,
3317
- _expanded: o || e.has(u),
3320
+ _expanded: i || e.has(u),
3318
3321
  _hasChildren: !1,
3319
3322
  _childCount: 0,
3320
3323
  _isLastChild: !1,
@@ -3335,7 +3338,7 @@ function Vt(d, t, e = /* @__PURE__ */ new Set()) {
3335
3338
  }
3336
3339
  function l(c, u) {
3337
3340
  for (const h of c)
3338
- h._depth = u, h._childCount = te(h), l(h.children, u + 1);
3341
+ h._depth = u, h._childCount = se(h), l(h.children, u + 1);
3339
3342
  }
3340
3343
  l(r, 0);
3341
3344
  function a(c, u) {
@@ -3346,27 +3349,27 @@ function Vt(d, t, e = /* @__PURE__ */ new Set()) {
3346
3349
  }
3347
3350
  return a(r, []), r;
3348
3351
  }
3349
- function te(d) {
3352
+ function se(d) {
3350
3353
  let t = d.children.length;
3351
- for (const e of d.children) t += te(e);
3354
+ for (const e of d.children) t += se(e);
3352
3355
  return t;
3353
3356
  }
3354
- function ee(d) {
3357
+ function ie(d) {
3355
3358
  const t = [];
3356
3359
  for (const e of d)
3357
- t.push(e), e._expanded && e.children.length > 0 && t.push(...ee(e.children));
3360
+ t.push(e), e._expanded && e.children.length > 0 && t.push(...ie(e.children));
3358
3361
  return t;
3359
3362
  }
3360
- function Ze(d, t) {
3363
+ function es(d, t) {
3361
3364
  d.has(t) ? d.delete(t) : d.add(t);
3362
3365
  }
3363
- function Rt(d) {
3366
+ function Et(d) {
3364
3367
  const t = [];
3365
3368
  for (const e of d)
3366
- t.push(e._treeId), e.children.length && t.push(...Rt(e.children));
3369
+ t.push(e._treeId), e.children.length && t.push(...Et(e.children));
3367
3370
  return t;
3368
3371
  }
3369
- class ts {
3372
+ class ss {
3370
3373
  constructor(t) {
3371
3374
  this._groupFields = [], this._groupExpandedKeys = /* @__PURE__ */ new Set(), this._groupFlatRows = [], this._isGroupMode = !1, this._treeRoots = [], this._treeFlatRows = [], this._treeExpandedKeys = /* @__PURE__ */ new Set(), this._isTreeMode = !1, this._d = t;
3372
3375
  }
@@ -3395,8 +3398,8 @@ class ts {
3395
3398
  }
3396
3399
  expandAll() {
3397
3400
  if (!this._isGroupMode) return;
3398
- const t = Pt(this._d.getData(), this._groupFields, this._getSummaryDefs(), void 0, void 0, this._groupKeyFn());
3399
- Zt(t).forEach((e) => this._groupExpandedKeys.add(e)), this.rebuildGroups();
3401
+ const t = jt(this._d.getData(), this._groupFields, this._getSummaryDefs(), void 0, void 0, this._groupKeyFn());
3402
+ ee(t).forEach((e) => this._groupExpandedKeys.add(e)), this.rebuildGroups();
3400
3403
  }
3401
3404
  /** Phase 2 슬롯 #5: groupKeyFn resolver. default = undefined(→ GroupEngine 가 row[field] 사용). */
3402
3405
  _groupKeyFn() {
@@ -3409,23 +3412,23 @@ class ts {
3409
3412
  this._groupExpandedKeys.has(t) ? this._groupExpandedKeys.delete(t) : this._groupExpandedKeys.add(t), this.rebuildGroups();
3410
3413
  }
3411
3414
  rebuildGroups() {
3412
- var o;
3415
+ var i;
3413
3416
  const t = this._d.getData(), e = this._d.getDataLayer(), s = (n) => {
3414
3417
  const r = t.indexOf(n);
3415
3418
  return r >= 0 ? e.getRowState(r) : "none";
3416
- }, i = Pt(t, this._groupFields, this._getSummaryDefs(), this._groupExpandedKeys, s, this._groupKeyFn());
3417
- this._groupFlatRows = Qt(i), (o = this._d.getVs()) == null || o.setTotalRows(this._groupFlatRows.length), this._d.doRenderFull(this._groupFlatRows.length);
3419
+ }, o = jt(t, this._groupFields, this._getSummaryDefs(), this._groupExpandedKeys, s, this._groupKeyFn());
3420
+ this._groupFlatRows = te(o), (i = this._d.getVs()) == null || i.setTotalRows(this._groupFlatRows.length), this._d.doRenderFull(this._groupFlatRows.length);
3418
3421
  }
3419
3422
  // ─── 트리 ─────────────────────────────────────────────────
3420
3423
  enableTree() {
3421
3424
  this._isTreeMode = !0, this._isGroupMode = !1;
3422
3425
  const t = this._d.getOptions();
3423
3426
  if (t.expandOnLoad) {
3424
- const e = Vt(this._d.getData(), {
3427
+ const e = Ut(this._d.getData(), {
3425
3428
  idField: t.treeId,
3426
3429
  parentIdField: t.treeParentId
3427
3430
  });
3428
- Rt(e).forEach((s) => this._treeExpandedKeys.add(s));
3431
+ Et(e).forEach((s) => this._treeExpandedKeys.add(s));
3429
3432
  }
3430
3433
  this.rebuildTree();
3431
3434
  }
@@ -3437,27 +3440,27 @@ class ts {
3437
3440
  }
3438
3441
  expandNodes(t, e = !0) {
3439
3442
  const s = Array.isArray(t) ? t : [t];
3440
- for (const i of s)
3441
- e ? this._treeExpandedKeys.add(i) : this._treeExpandedKeys.delete(i);
3443
+ for (const o of s)
3444
+ e ? this._treeExpandedKeys.add(o) : this._treeExpandedKeys.delete(o);
3442
3445
  this._isTreeMode && this.rebuildTree();
3443
3446
  }
3444
3447
  expandAllNodes() {
3445
- this._isTreeMode && (Rt(this._treeRoots).forEach((t) => this._treeExpandedKeys.add(t)), this.rebuildTree());
3448
+ this._isTreeMode && (Et(this._treeRoots).forEach((t) => this._treeExpandedKeys.add(t)), this.rebuildTree());
3446
3449
  }
3447
3450
  collapseAllNodes() {
3448
3451
  this._isTreeMode && (this._treeExpandedKeys.clear(), this.rebuildTree());
3449
3452
  }
3450
3453
  handleTreeToggle(t) {
3451
- Ze(this._treeExpandedKeys, t), this.rebuildTree();
3454
+ es(this._treeExpandedKeys, t), this.rebuildTree();
3452
3455
  }
3453
3456
  rebuildTree() {
3454
3457
  var e;
3455
3458
  const t = this._d.getOptions();
3456
- this._treeRoots = Vt(this._d.getData(), {
3459
+ this._treeRoots = Ut(this._d.getData(), {
3457
3460
  idField: t.treeId,
3458
3461
  parentIdField: t.treeParentId,
3459
3462
  expandOnLoad: t.expandOnLoad
3460
- }, this._treeExpandedKeys), this._treeFlatRows = ee(this._treeRoots), (e = this._d.getVs()) == null || e.setTotalRows(this._treeFlatRows.length), this._d.doRenderFull(this._treeFlatRows.length);
3463
+ }, this._treeExpandedKeys), this._treeFlatRows = ie(this._treeRoots), (e = this._d.getVs()) == null || e.setTotalRows(this._treeFlatRows.length), this._d.doRenderFull(this._treeFlatRows.length);
3461
3464
  }
3462
3465
  // ─── 내부 헬퍼 ───────────────────────────────────────────
3463
3466
  _getSummaryDefs() {
@@ -3465,13 +3468,13 @@ class ts {
3465
3468
  if (!t) return [];
3466
3469
  if (t.rows && t.rows.length > 0)
3467
3470
  return t.fields.flatMap(
3468
- (s) => t.rows.map((i) => ({ field: s, op: i.op, format: i.format }))
3471
+ (s) => t.rows.map((o) => ({ field: s, op: o.op, format: o.format }))
3469
3472
  );
3470
3473
  const e = Array.isArray(t.ops) ? t.ops : t.ops ? [t.ops] : ["SUM"];
3471
3474
  return t.fields.map((s) => ({ field: s, op: e[0] ?? "SUM", format: t.format }));
3472
3475
  }
3473
3476
  }
3474
- class es {
3477
+ class is {
3475
3478
  constructor(t) {
3476
3479
  this._sortList = [], this._filters = {}, this._d = t;
3477
3480
  }
@@ -3487,21 +3490,21 @@ class es {
3487
3490
  var r;
3488
3491
  const s = this._d.getOptions();
3489
3492
  if (!s.sortable) return;
3490
- const i = this._sortList.findIndex((l) => l.field === t);
3491
- if (i >= 0) {
3492
- const l = this._sortList[i];
3493
- l.dir === "asc" ? l.dir = "desc" : this._sortList.splice(i, 1);
3493
+ const o = this._sortList.findIndex((l) => l.field === t);
3494
+ if (o >= 0) {
3495
+ const l = this._sortList[o];
3496
+ l.dir === "asc" ? l.dir = "desc" : this._sortList.splice(o, 1);
3494
3497
  } else
3495
3498
  (!e || !s.multiSort) && (this._sortList = []), this._sortList.push({ field: t, dir: "asc" });
3496
3499
  this._d.getData().applySort(this._sortList), this._d.renderHeader(), this._d.doRender();
3497
- const o = this._sortList.find((l) => l.field === t), n = o ? o.dir === "asc" ? "오름차순" : "내림차순" : "정렬 해제";
3498
- this._d.announce(`${t} ${n} 정렬`), this._d.emit("sortChange", { sortList: this._sortList }), (r = s.onSortChange) == null || r.call(s, { field: t, dir: (o == null ? void 0 : o.dir) ?? "asc", sortList: this._sortList });
3500
+ const i = this._sortList.find((l) => l.field === t), n = i ? i.dir === "asc" ? "오름차순" : "내림차순" : "정렬 해제";
3501
+ this._d.announce(`${t} ${n} 정렬`), this._d.emit("sortChange", { sortList: this._sortList }), (r = s.onSortChange) == null || r.call(s, { field: t, dir: (i == null ? void 0 : i.dir) ?? "asc", sortList: this._sortList });
3499
3502
  }
3500
3503
  sort(t, e = "asc") {
3501
3504
  if (Array.isArray(t))
3502
3505
  this._sortList = t;
3503
3506
  else {
3504
- const s = this._sortList.findIndex((i) => i.field === t);
3507
+ const s = this._sortList.findIndex((o) => o.field === t);
3505
3508
  s >= 0 ? this._sortList[s].dir = e : this._sortList = [{ field: t, dir: e }], this._d.getOptions().multiSort || (this._sortList = this._sortList.slice(-1));
3506
3509
  }
3507
3510
  this._d.getData().applySort(this._sortList), this._d.renderHeader(), this._d.doRender(), this._d.emit("sortChange", { sortList: this._sortList });
@@ -3517,8 +3520,8 @@ class es {
3517
3520
  }
3518
3521
  // ─── 필터 ─────────────────────────────────────────────────
3519
3522
  setFilter(t, e) {
3520
- var s, i;
3521
- this._filters[t] = e, this.applyFilters(), this._d.renderHeader(), this._d.doRender(), this._d.emit("filterChange", { field: t, filterItems: e, allFilters: this._filters }), (i = (s = this._d.getOptions()).onFilterChange) == null || i.call(s, { field: t, filterItems: e, allFilters: this._filters });
3523
+ var s, o;
3524
+ this._filters[t] = e, this.applyFilters(), this._d.renderHeader(), this._d.doRender(), this._d.emit("filterChange", { field: t, filterItems: e, allFilters: this._filters }), (o = (s = this._d.getOptions()).onFilterChange) == null || o.call(s, { field: t, filterItems: e, allFilters: this._filters });
3522
3525
  }
3523
3526
  resetFilter(t) {
3524
3527
  t ? delete this._filters[t] : this._filters = {}, this.applyFilters(), this._d.renderHeader(), this._d.doRender();
@@ -3530,42 +3533,42 @@ class es {
3530
3533
  this._filters = { ...t }, this.applyFilters();
3531
3534
  }
3532
3535
  applyFilters() {
3533
- var s, i;
3536
+ var s, o;
3534
3537
  const t = this._d.getData();
3535
- t.setFindFilter(this._d.getFindFilter(), this._d.getColLayout().visibleLeaves.map((o) => o.field)), t.applyFilter(this._filters);
3538
+ t.setFindFilter(this._d.getFindFilter(), this._d.getColLayout().visibleLeaves.map((i) => i.field)), t.applyFilter(this._filters);
3536
3539
  const e = t.rowCount;
3537
- (s = this._d.getVs()) == null || s.setTotalRows(e), (i = this._d.getPagination()) == null || i.setTotalRows(e);
3540
+ (s = this._d.getVs()) == null || s.setTotalRows(e), (o = this._d.getPagination()) == null || o.setTotalRows(e);
3538
3541
  }
3539
3542
  }
3540
- class ss {
3543
+ class os {
3541
3544
  constructor(t) {
3542
3545
  this._d = t;
3543
3546
  }
3544
3547
  handleCellClick(t, e, s) {
3545
- var a, c, u, h, g, k, m;
3546
- const i = this._d.getOptions(), o = this._d.getRowMgr(), n = this._d.getEditMgr();
3547
- i.selection === "single" || i.selection === "row" ? o.selectSingle(t) : i.selection === "multiple" && (s.ctrlKey || s.metaKey ? o.selectToggle(t) : o.selectSingle(t));
3548
+ var a, c, u, h, g, k, y;
3549
+ const o = this._d.getOptions(), i = this._d.getRowMgr(), n = this._d.getEditMgr();
3550
+ o.selection === "single" || o.selection === "row" ? i.selectSingle(t) : o.selection === "multiple" && (s.ctrlKey || s.metaKey ? i.selectToggle(t) : i.selectSingle(t));
3548
3551
  const r = this._d.getData().getRowByIndex(t), l = this._d.getColLayout().visibleLeaves[e];
3549
3552
  if (r && l) {
3550
- const w = l.editable !== !1 && (l.editable !== void 0 || i.editable);
3551
- if (nt(l) && w) {
3552
- const R = r[l.field];
3553
- this._d.writeCell(t, l.field, !R);
3553
+ const b = l.editable !== !1 && (l.editable !== void 0 || o.editable);
3554
+ if (rt(l) && b) {
3555
+ const E = r[l.field];
3556
+ this._d.writeCell(t, l.field, !E);
3554
3557
  }
3555
3558
  if (l.type === "radio") {
3556
- const R = l.group;
3557
- for (const F of this._d.getColLayout().visibleLeaves)
3558
- F.type === "radio" && F.field !== l.field && (!R || F.group === R) && this._d.getData().updateCell(t, F.field, !1);
3559
+ const E = l.group;
3560
+ for (const f of this._d.getColLayout().visibleLeaves)
3561
+ f.type === "radio" && f.field !== l.field && (!E || f.group === E) && this._d.getData().updateCell(t, f.field, !1);
3559
3562
  this._d.writeCell(t, l.field, !0);
3560
3563
  }
3561
3564
  let x = r[l.field];
3562
3565
  if (x === void 0 && l.formula)
3563
3566
  try {
3564
- const R = l.formulaPrecision ?? 30, F = Gt(l.formula, r, R);
3565
- x = F instanceof M ? l.precision != null ? F.toFixed(l.precision) : F.toString() : String(F);
3567
+ const E = l.formulaPrecision ?? 30, f = Xt(l.formula, r, E);
3568
+ x = f instanceof C ? l.precision != null ? f.toFixed(l.precision) : f.toString() : String(f);
3566
3569
  } catch {
3567
3570
  }
3568
- const _ = {
3571
+ const p = {
3569
3572
  type: "cellClick",
3570
3573
  rowIndex: t,
3571
3574
  columnIndex: e,
@@ -3576,92 +3579,92 @@ class ss {
3576
3579
  target: s.target,
3577
3580
  originalEvent: s
3578
3581
  };
3579
- this._d.emit("cellClick", _), (a = i.onCellClick) == null || a.call(i, _);
3580
- const b = { type: "rowClick", rowIndex: t, row: r, target: s.target, originalEvent: s };
3581
- this._d.emit("rowClick", b), (c = i.onRowClick) == null || c.call(i, b);
3582
- const L = l.type === "select";
3583
- !(n.activeEditor != null && ((u = n.editCell) == null ? void 0 : u.ri) === t && ((h = n.editCell) == null ? void 0 : h.ci) === e) && (i.editMode === "click" || L) && !nt(l) && n.startEdit(t, e, s);
3582
+ this._d.emit("cellClick", p), (a = o.onCellClick) == null || a.call(o, p);
3583
+ const v = { type: "rowClick", rowIndex: t, row: r, target: s.target, originalEvent: s };
3584
+ this._d.emit("rowClick", v), (c = o.onRowClick) == null || c.call(o, v);
3585
+ const T = l.type === "select";
3586
+ !(n.activeEditor != null && ((u = n.editCell) == null ? void 0 : u.ri) === t && ((h = n.editCell) == null ? void 0 : h.ci) === e) && (o.editMode === "click" || T) && !rt(l) && n.startEdit(t, e, s);
3584
3587
  }
3585
3588
  n.activeEditor && ((g = n.editCell) == null ? void 0 : g.ri) === t && ((k = n.editCell) == null ? void 0 : k.ci) === e || (this._d.doRender(), this._d.emit("selectionChange", {
3586
- rows: o.getSelections(),
3587
- rowIndexes: [...o.selectedRows]
3588
- }), (m = i.onSelectionChange) == null || m.call(i, { rows: o.getSelections(), rowIndexes: [...o.selectedRows], cells: [] }));
3589
+ rows: i.getSelections(),
3590
+ rowIndexes: [...i.selectedRows]
3591
+ }), (y = o.onSelectionChange) == null || y.call(o, { rows: i.getSelections(), rowIndexes: [...i.selectedRows], cells: [] }));
3589
3592
  }
3590
3593
  handleCellDblClick(t, e, s) {
3591
3594
  var a, c;
3592
- const i = this._d.getData().getRowByIndex(t), o = this._d.getColLayout().visibleLeaves[e];
3593
- if (!i || !o) return;
3595
+ const o = this._d.getData().getRowByIndex(t), i = this._d.getColLayout().visibleLeaves[e];
3596
+ if (!o || !i) return;
3594
3597
  const n = this._d.getOptions(), r = {
3595
3598
  type: "cellDblClick",
3596
3599
  rowIndex: t,
3597
3600
  columnIndex: e,
3598
- field: o.field,
3599
- value: i[o.field],
3600
- row: i,
3601
- column: o,
3601
+ field: i.field,
3602
+ value: o[i.field],
3603
+ row: o,
3604
+ column: i,
3602
3605
  target: s.target,
3603
3606
  originalEvent: s
3604
3607
  };
3605
3608
  this._d.emit("cellDblClick", r), (a = n.onCellDblClick) == null || a.call(n, r);
3606
- const l = { type: "rowDblClick", rowIndex: t, row: i, target: s.target, originalEvent: s };
3609
+ const l = { type: "rowDblClick", rowIndex: t, row: o, target: s.target, originalEvent: s };
3607
3610
  this._d.emit("rowDblClick", l), (c = n.onRowDblClick) == null || c.call(n, l), n.editMode === "dblclick" && this._d.getEditMgr().startEdit(t, e, s);
3608
3611
  }
3609
3612
  handleCellMouseOver(t, e, s) {
3610
3613
  var a, c;
3611
- const i = this._d.getData().getRowByIndex(t), o = this._d.getColLayout().visibleLeaves[e];
3612
- if (!i || !o) return;
3613
- const n = this._d.getOptions(), r = { type: "cellMouseOver", rowIndex: t, columnIndex: e, field: o.field, value: i[o.field], row: i, column: o, target: s.target, originalEvent: s };
3614
+ const o = this._d.getData().getRowByIndex(t), i = this._d.getColLayout().visibleLeaves[e];
3615
+ if (!o || !i) return;
3616
+ const n = this._d.getOptions(), r = { type: "cellMouseOver", rowIndex: t, columnIndex: e, field: i.field, value: o[i.field], row: o, column: i, target: s.target, originalEvent: s };
3614
3617
  this._d.emit("cellMouseOver", r), (a = n.onCellMouseOver) == null || a.call(n, r);
3615
- const l = { type: "rowMouseOver", rowIndex: t, row: i, target: s.target, originalEvent: s };
3618
+ const l = { type: "rowMouseOver", rowIndex: t, row: o, target: s.target, originalEvent: s };
3616
3619
  this._d.emit("rowMouseOver", l), (c = n.onRowMouseOver) == null || c.call(n, l);
3617
3620
  }
3618
3621
  handleCellMouseOut(t, e, s) {
3619
3622
  var a, c;
3620
- const i = this._d.getData().getRowByIndex(t), o = this._d.getColLayout().visibleLeaves[e];
3621
- if (!i || !o) return;
3622
- const n = this._d.getOptions(), r = { type: "cellMouseOut", rowIndex: t, columnIndex: e, field: o.field, value: i[o.field], row: i, column: o, target: s.target, originalEvent: s };
3623
+ const o = this._d.getData().getRowByIndex(t), i = this._d.getColLayout().visibleLeaves[e];
3624
+ if (!o || !i) return;
3625
+ const n = this._d.getOptions(), r = { type: "cellMouseOut", rowIndex: t, columnIndex: e, field: i.field, value: o[i.field], row: o, column: i, target: s.target, originalEvent: s };
3623
3626
  this._d.emit("cellMouseOut", r), (a = n.onCellMouseOut) == null || a.call(n, r);
3624
- const l = { type: "rowMouseOut", rowIndex: t, row: i, target: s.target, originalEvent: s };
3627
+ const l = { type: "rowMouseOut", rowIndex: t, row: o, target: s.target, originalEvent: s };
3625
3628
  this._d.emit("rowMouseOut", l), (c = n.onRowMouseOut) == null || c.call(n, l);
3626
3629
  }
3627
3630
  handleCellMouseDown(t, e, s) {
3628
3631
  var a, c;
3629
- const i = this._d.getData().getRowByIndex(t), o = this._d.getColLayout().visibleLeaves[e];
3630
- if (!i || !o) return;
3631
- const n = this._d.getOptions(), r = { type: "cellMouseDown", rowIndex: t, columnIndex: e, field: o.field, value: i[o.field], row: i, column: o, target: s.target, originalEvent: s };
3632
+ const o = this._d.getData().getRowByIndex(t), i = this._d.getColLayout().visibleLeaves[e];
3633
+ if (!o || !i) return;
3634
+ const n = this._d.getOptions(), r = { type: "cellMouseDown", rowIndex: t, columnIndex: e, field: i.field, value: o[i.field], row: o, column: i, target: s.target, originalEvent: s };
3632
3635
  this._d.emit("cellMouseDown", r), (a = n.onCellMouseDown) == null || a.call(n, r);
3633
- const l = { type: "rowMouseDown", rowIndex: t, row: i, target: s.target, originalEvent: s };
3636
+ const l = { type: "rowMouseDown", rowIndex: t, row: o, target: s.target, originalEvent: s };
3634
3637
  this._d.emit("rowMouseDown", l), (c = n.onRowMouseDown) == null || c.call(n, l);
3635
3638
  }
3636
3639
  handleCellMouseUp(t, e, s) {
3637
3640
  var a, c;
3638
- const i = this._d.getData().getRowByIndex(t), o = this._d.getColLayout().visibleLeaves[e];
3639
- if (!i || !o) return;
3640
- const n = this._d.getOptions(), r = { type: "cellMouseUp", rowIndex: t, columnIndex: e, field: o.field, value: i[o.field], row: i, column: o, target: s.target, originalEvent: s };
3641
+ const o = this._d.getData().getRowByIndex(t), i = this._d.getColLayout().visibleLeaves[e];
3642
+ if (!o || !i) return;
3643
+ const n = this._d.getOptions(), r = { type: "cellMouseUp", rowIndex: t, columnIndex: e, field: i.field, value: o[i.field], row: o, column: i, target: s.target, originalEvent: s };
3641
3644
  this._d.emit("cellMouseUp", r), (a = n.onCellMouseUp) == null || a.call(n, r);
3642
- const l = { type: "rowMouseUp", rowIndex: t, row: i, target: s.target, originalEvent: s };
3645
+ const l = { type: "rowMouseUp", rowIndex: t, row: o, target: s.target, originalEvent: s };
3643
3646
  this._d.emit("rowMouseUp", l), (c = n.onRowMouseUp) == null || c.call(n, l);
3644
3647
  }
3645
3648
  handleCellMouseMove(t, e, s) {
3646
3649
  var a, c;
3647
- const i = this._d.getData().getRowByIndex(t), o = this._d.getColLayout().visibleLeaves[e];
3648
- if (!i || !o) return;
3649
- const n = this._d.getOptions(), r = { type: "cellMouseMove", rowIndex: t, columnIndex: e, field: o.field, value: i[o.field], row: i, column: o, target: s.target, originalEvent: s };
3650
+ const o = this._d.getData().getRowByIndex(t), i = this._d.getColLayout().visibleLeaves[e];
3651
+ if (!o || !i) return;
3652
+ const n = this._d.getOptions(), r = { type: "cellMouseMove", rowIndex: t, columnIndex: e, field: i.field, value: o[i.field], row: o, column: i, target: s.target, originalEvent: s };
3650
3653
  this._d.emit("cellMouseMove", r), (a = n.onCellMouseMove) == null || a.call(n, r);
3651
- const l = { type: "rowMouseMove", rowIndex: t, row: i, target: s.target, originalEvent: s };
3654
+ const l = { type: "rowMouseMove", rowIndex: t, row: o, target: s.target, originalEvent: s };
3652
3655
  this._d.emit("rowMouseMove", l), (c = n.onRowMouseMove) == null || c.call(n, l);
3653
3656
  }
3654
3657
  handleCellKeyEvt(t, e) {
3655
3658
  var c, u, h;
3656
3659
  const s = this._d.getEditMgr();
3657
3660
  if (!s.focusCell || s.activeEditor) return;
3658
- const { ri: i, ci: o } = s.focusCell, n = this._d.getData().getRowByIndex(i), r = this._d.getColLayout().visibleLeaves[o];
3661
+ const { ri: o, ci: i } = s.focusCell, n = this._d.getData().getRowByIndex(o), r = this._d.getColLayout().visibleLeaves[i];
3659
3662
  if (!n || !r) return;
3660
- const l = this._d.getOptions(), a = { type: t, rowIndex: i, columnIndex: o, field: r.field, value: n[r.field], row: n, column: r, key: e.key, target: this._d.getContainer(), originalEvent: e };
3663
+ const l = this._d.getOptions(), a = { type: t, rowIndex: o, columnIndex: i, field: r.field, value: n[r.field], row: n, column: r, key: e.key, target: this._d.getContainer(), originalEvent: e };
3661
3664
  this._d.emit(t, a), t === "cellKeyDown" ? (c = l.onCellKeyDown) == null || c.call(l, a) : t === "cellKeyUp" ? (u = l.onCellKeyUp) == null || u.call(l, a) : (h = l.onCellKeyPress) == null || h.call(l, a);
3662
3665
  }
3663
3666
  }
3664
- class is {
3667
+ class ns {
3665
3668
  constructor() {
3666
3669
  this._triggers = /* @__PURE__ */ new Map();
3667
3670
  }
@@ -3671,8 +3674,8 @@ class is {
3671
3674
  remove(t, e) {
3672
3675
  const s = this._triggers.get(t);
3673
3676
  if (s) {
3674
- const i = s.indexOf(e);
3675
- i >= 0 && s.splice(i, 1);
3677
+ const o = s.indexOf(e);
3678
+ o >= 0 && s.splice(o, 1);
3676
3679
  }
3677
3680
  }
3678
3681
  clear(t) {
@@ -3696,18 +3699,18 @@ class is {
3696
3699
  }
3697
3700
  exec(t, e) {
3698
3701
  const s = this._triggers.get(t) ?? [];
3699
- for (const i of s)
3700
- if (i(e), e.cancelled) return !1;
3702
+ for (const o of s)
3703
+ if (o(e), e.cancelled) return !1;
3701
3704
  if (t.startsWith("after:")) {
3702
- const i = this._triggers.get("complete") ?? [];
3703
- for (const o of i) o(e);
3705
+ const o = this._triggers.get("complete") ?? [];
3706
+ for (const i of o) i(e);
3704
3707
  }
3705
3708
  return !0;
3706
3709
  }
3707
3710
  }
3708
- const ht = "";
3709
- function se(d) {
3710
- const t = Object.entries(d).filter(([, e]) => e !== ht).map(([e, s]) => ` ${JSON.stringify(e)}: src[${JSON.stringify(s)}],`);
3711
+ const ut = "";
3712
+ function oe(d) {
3713
+ const t = Object.entries(d).filter(([, e]) => e !== ut).map(([e, s]) => ` ${JSON.stringify(e)}: src[${JSON.stringify(s)}],`);
3711
3714
  return `// crossGridMapping 옵션에 이 함수를 그대로 지정하세요.
3712
3715
  function mapRow(src) {
3713
3716
  return {
@@ -3716,45 +3719,45 @@ function mapRow(src) {
3716
3719
  ` : "") + ` };
3717
3720
  }`;
3718
3721
  }
3719
- function os(d) {
3722
+ function rs(d) {
3720
3723
  return (t) => {
3721
3724
  const e = {};
3722
- for (const [s, i] of Object.entries(d))
3723
- i !== ht && (e[s] = t[i]);
3725
+ for (const [s, o] of Object.entries(d))
3726
+ o !== ut && (e[s] = t[o]);
3724
3727
  return e;
3725
3728
  };
3726
3729
  }
3727
- function ns(d, t) {
3730
+ function ls(d, t) {
3728
3731
  if (d.length !== t.length) return !1;
3729
3732
  const e = new Set(t);
3730
3733
  return d.every((s) => e.has(s));
3731
3734
  }
3732
- function rs(d, t) {
3735
+ function as(d, t) {
3733
3736
  return new Promise((e) => {
3734
- const s = new Set(d.map((R) => R.field)), i = {};
3735
- for (const R of t) i[R.field] = s.has(R.field) ? R.field : ht;
3736
- const o = document.createElement("div");
3737
- o.className = "og-mapper-overlay", o.setAttribute("role", "dialog"), o.setAttribute("aria-modal", "true"), o.setAttribute("aria-label", "그리드 필드 매핑"), o.style.cssText = "position:fixed;inset:0;z-index:100000;background:rgba(0,0,0,0.45);display:flex;align-items:center;justify-content:center;font-family:var(--og-font-family,-apple-system,sans-serif);";
3737
+ const s = new Set(d.map((E) => E.field)), o = {};
3738
+ for (const E of t) o[E.field] = s.has(E.field) ? E.field : ut;
3739
+ const i = document.createElement("div");
3740
+ i.className = "og-mapper-overlay", i.setAttribute("role", "dialog"), i.setAttribute("aria-modal", "true"), i.setAttribute("aria-label", "그리드 필드 매핑"), i.style.cssText = "position:fixed;inset:0;z-index:100000;background:rgba(0,0,0,0.45);display:flex;align-items:center;justify-content:center;font-family:var(--og-font-family,-apple-system,sans-serif);";
3738
3741
  const n = document.createElement("div");
3739
- n.style.cssText = "background:#fff;border-radius:10px;box-shadow:0 12px 40px rgba(0,0,0,0.3);width:min(620px,92vw);max-height:88vh;overflow:auto;color:#222;", o.appendChild(n);
3742
+ n.style.cssText = "background:#fff;border-radius:10px;box-shadow:0 12px 40px rgba(0,0,0,0.3);width:min(620px,92vw);max-height:88vh;overflow:auto;color:#222;", i.appendChild(n);
3740
3743
  const r = document.createElement("div");
3741
3744
  r.style.cssText = "padding:18px 20px 8px;", r.innerHTML = '<div style="font-size:16px;font-weight:700;">필드 매핑</div><div style="font-size:12.5px;color:#666;margin-top:4px;line-height:1.5;">두 그리드의 필드 구조가 다릅니다. <b>타깃 필드</b>마다 어떤 <b>소스 필드</b>의 값을 가져올지 지정하세요. 아래 스크립트를 복사해 <code>crossGridMapping</code> 에 baking 하면 다음부터는 이 창 없이 자동 변환됩니다.</div>', n.appendChild(r);
3742
3745
  const l = document.createElement("div");
3743
3746
  l.style.cssText = "padding:6px 20px;";
3744
3747
  const a = '<option value="">(비움)</option>' + d.map(
3745
- (R) => `<option value="${it(R.field)}">${it(R.header)} &lt;${it(R.field)}&gt;</option>`
3748
+ (E) => `<option value="${ot(E.field)}">${ot(E.header)} &lt;${ot(E.field)}&gt;</option>`
3746
3749
  ).join("");
3747
- for (const R of t) {
3748
- const F = document.createElement("div");
3749
- F.style.cssText = "display:flex;align-items:center;gap:10px;padding:7px 0;border-bottom:1px solid #f0f0f0;";
3750
- const I = document.createElement("div");
3751
- I.style.cssText = "flex:1;font-size:13px;min-width:0;", I.innerHTML = `<span style="font-weight:600;">${it(R.header)}</span><span style="color:#999;font-size:11.5px;"> &lt;${it(R.field)}&gt;</span>`;
3752
- const T = document.createElement("span");
3753
- T.textContent = "←", T.style.cssText = "color:#888;flex-shrink:0;";
3754
- const A = document.createElement("select");
3755
- A.style.cssText = "flex:1;min-width:0;padding:6px 8px;border:1px solid #ccc;border-radius:6px;font-size:13px;background:#fff;", A.innerHTML = a, A.value = i[R.field] ?? ht, A.addEventListener("change", () => {
3756
- i[R.field] = A.value, m();
3757
- }), F.append(I, T, A), l.appendChild(F);
3750
+ for (const E of t) {
3751
+ const f = document.createElement("div");
3752
+ f.style.cssText = "display:flex;align-items:center;gap:10px;padding:7px 0;border-bottom:1px solid #f0f0f0;";
3753
+ const $ = document.createElement("div");
3754
+ $.style.cssText = "flex:1;font-size:13px;min-width:0;", $.innerHTML = `<span style="font-weight:600;">${ot(E.header)}</span><span style="color:#999;font-size:11.5px;"> &lt;${ot(E.field)}&gt;</span>`;
3755
+ const B = document.createElement("span");
3756
+ B.textContent = "←", B.style.cssText = "color:#888;flex-shrink:0;";
3757
+ const z = document.createElement("select");
3758
+ z.style.cssText = "flex:1;min-width:0;padding:6px 8px;border:1px solid #ccc;border-radius:6px;font-size:13px;background:#fff;", z.innerHTML = a, z.value = o[E.field] ?? ut, z.addEventListener("change", () => {
3759
+ o[E.field] = z.value, y();
3760
+ }), f.append($, B, z), l.appendChild(f);
3758
3761
  }
3759
3762
  n.appendChild(l);
3760
3763
  const c = document.createElement("div");
@@ -3766,15 +3769,15 @@ function rs(d, t) {
3766
3769
  const g = document.createElement("pre");
3767
3770
  g.style.cssText = "margin:0;background:#0d1117;color:#c9d1d9;padding:12px;border-radius:8px;font-family:ui-monospace,Consolas,monospace;font-size:12px;line-height:1.5;overflow:auto;max-height:180px;", c.append(u, g), n.appendChild(c);
3768
3771
  function k() {
3769
- return se(i);
3772
+ return oe(o);
3770
3773
  }
3771
- function m() {
3774
+ function y() {
3772
3775
  g.textContent = k();
3773
3776
  }
3774
- m(), h.addEventListener("click", () => {
3775
- var F;
3776
- const R = k();
3777
- (F = navigator.clipboard) == null || F.writeText(R).then(
3777
+ y(), h.addEventListener("click", () => {
3778
+ var f;
3779
+ const E = k();
3780
+ (f = navigator.clipboard) == null || f.writeText(E).then(
3778
3781
  () => {
3779
3782
  h.textContent = "복사됨!", setTimeout(() => h.textContent = "복사", 1200);
3780
3783
  },
@@ -3783,28 +3786,28 @@ function rs(d, t) {
3783
3786
  }
3784
3787
  );
3785
3788
  });
3786
- const w = document.createElement("div");
3787
- w.style.cssText = "display:flex;justify-content:flex-end;gap:8px;padding:14px 20px 18px;";
3789
+ const b = document.createElement("div");
3790
+ b.style.cssText = "display:flex;justify-content:flex-end;gap:8px;padding:14px 20px 18px;";
3788
3791
  const x = document.createElement("button");
3789
3792
  x.type = "button", x.textContent = "취소", x.style.cssText = "font-size:13px;padding:8px 16px;border:1px solid #ccc;border-radius:7px;background:#fff;cursor:pointer;";
3790
- const _ = document.createElement("button");
3791
- _.type = "button", _.textContent = "적용 후 이동", _.style.cssText = "font-size:13px;padding:8px 16px;border:0;border-radius:7px;background:#1976d2;color:#fff;cursor:pointer;font-weight:600;", w.append(x, _), n.appendChild(w);
3792
- let b = !1;
3793
- function L(R) {
3794
- b || (b = !0, document.removeEventListener("keydown", v), o.remove(), e(R));
3793
+ const p = document.createElement("button");
3794
+ p.type = "button", p.textContent = "적용 후 이동", p.style.cssText = "font-size:13px;padding:8px 16px;border:0;border-radius:7px;background:#1976d2;color:#fff;cursor:pointer;font-weight:600;", b.append(x, p), n.appendChild(b);
3795
+ let v = !1;
3796
+ function T(E) {
3797
+ v || (v = !0, document.removeEventListener("keydown", A), i.remove(), e(E));
3795
3798
  }
3796
- function v(R) {
3797
- R.key === "Escape" && L(null);
3799
+ function A(E) {
3800
+ E.key === "Escape" && T(null);
3798
3801
  }
3799
- x.addEventListener("click", () => L(null)), o.addEventListener("mousedown", (R) => {
3800
- R.target === o && L(null);
3801
- }), _.addEventListener("click", () => L({ mapping: { ...i }, script: k() })), document.addEventListener("keydown", v), document.body.appendChild(o), _.focus();
3802
+ x.addEventListener("click", () => T(null)), i.addEventListener("mousedown", (E) => {
3803
+ E.target === i && T(null);
3804
+ }), p.addEventListener("click", () => T({ mapping: { ...o }, script: k() })), document.addEventListener("keydown", A), document.body.appendChild(i), p.focus();
3802
3805
  });
3803
3806
  }
3804
- function it(d) {
3807
+ function ot(d) {
3805
3808
  return String(d).replace(/[&<>"]/g, (t) => ({ "&": "&amp;", "<": "&lt;", ">": "&gt;", '"': "&quot;" })[t]);
3806
3809
  }
3807
- class ls {
3810
+ class ds {
3808
3811
  constructor() {
3809
3812
  this._map = /* @__PURE__ */ new Map();
3810
3813
  }
@@ -3822,14 +3825,14 @@ class ls {
3822
3825
  }
3823
3826
  /** 커서 좌표 아래의 다른(crossGrid 허용) 그리드 반환. 없으면 null */
3824
3827
  resolveAt(t, e, s) {
3825
- const i = document.elementFromPoint(t, e), o = i == null ? void 0 : i.closest(".og-body-wrapper");
3826
- if (!o) return null;
3827
- const n = this._map.get(o);
3828
+ const o = document.elementFromPoint(t, e), i = o == null ? void 0 : o.closest(".og-body-wrapper");
3829
+ if (!i) return null;
3830
+ const n = this._map.get(i);
3828
3831
  return !n || n === s ? null : n;
3829
3832
  }
3830
3833
  }
3831
- const ct = new ls();
3832
- class as {
3834
+ const ht = new ds();
3835
+ class cs {
3833
3836
  constructor(t, e) {
3834
3837
  this._originals = /* @__PURE__ */ new Map(), this._hadOwn = /* @__PURE__ */ new Map(), this._stack = /* @__PURE__ */ new Map(), this._strategies = /* @__PURE__ */ new Map(), this._callPath = [], this._host = t, this._strict = (e == null ? void 0 : e.strict) ?? !0, this._maxDepth = (e == null ? void 0 : e.maxDepth) ?? 32;
3835
3838
  }
@@ -3844,21 +3847,21 @@ class as {
3844
3847
  if (typeof e != "function")
3845
3848
  throw new TypeError(`OverrideKernel.override: fn for "${t}" must be a function`);
3846
3849
  if (!this._originals.has(t)) {
3847
- const o = this._host[t];
3848
- if (typeof o != "function")
3850
+ const i = this._host[t];
3851
+ if (typeof i != "function")
3849
3852
  throw new TypeError(`OverrideKernel.override: host["${t}"] is not a function`);
3850
- this._hadOwn.set(t, Object.prototype.hasOwnProperty.call(this._host, t)), this._originals.set(t, o.bind(this._host));
3853
+ this._hadOwn.set(t, Object.prototype.hasOwnProperty.call(this._host, t)), this._originals.set(t, i.bind(this._host));
3851
3854
  }
3852
- const i = this._stack.get(t) ?? [];
3853
- return i.push({ fn: e, opts: s }), this._stack.set(t, i), this._host[t] = this._buildDispatcher(t), this._host;
3855
+ const o = this._stack.get(t) ?? [];
3856
+ return o.push({ fn: e, opts: s }), this._stack.set(t, o), this._host[t] = this._buildDispatcher(t), this._host;
3854
3857
  }
3855
3858
  /** 합성된 dispatcher 생성. override/restore 시점마다 재구성. */
3856
3859
  _buildDispatcher(t) {
3857
3860
  var a;
3858
- const e = this._originals.get(t), s = this._stack.get(t) ?? [], i = s.reduce(
3861
+ const e = this._originals.get(t), s = this._stack.get(t) ?? [], o = s.reduce(
3859
3862
  (c, u) => (...h) => u.fn(c, ...h),
3860
3863
  e
3861
- ), o = ((a = s[s.length - 1]) == null ? void 0 : a.opts) ?? {}, n = o.reentrant === !0, r = o.onError === "fallback", l = this;
3864
+ ), i = ((a = s[s.length - 1]) == null ? void 0 : a.opts) ?? {}, n = i.reentrant === !0, r = i.onError === "fallback", l = this;
3862
3865
  return function(...c) {
3863
3866
  if (!n && l._callPath.indexOf(t) !== -1)
3864
3867
  return e(...c);
@@ -3871,7 +3874,7 @@ class as {
3871
3874
  }
3872
3875
  l._callPath.push(t);
3873
3876
  try {
3874
- return i(...c);
3877
+ return o(...c);
3875
3878
  } catch (u) {
3876
3879
  if (r && !l._strict)
3877
3880
  return console.warn(`[og.override:${t}]`, u), e(...c);
@@ -3915,10 +3918,10 @@ class as {
3915
3918
  return [...this._originals.keys()];
3916
3919
  }
3917
3920
  }
3918
- const jt = "_ogRowId", V = class V extends oe {
3921
+ const Gt = "_ogRowId", U = class U extends re {
3919
3922
  constructor(t, e) {
3920
- var o;
3921
- super(), this._vs = null, this._ro = null, this._renderer = null, this._trigMgr = new is(), this._destroyed = !1, this._autoHeightWarned = !1, this._colWidths = [], this._userWidths = /* @__PURE__ */ new Map(), this._filterPanel = null, this._filterSelect = null, this._pagination = null, this._dnd = null, this._mergeEngine = new Z(), this._liveRegion = null, this._ctxMenu = null, this._cmHandler = null, this._cmKbdHandler = null, this._wsManager = null;
3923
+ var i;
3924
+ super(), this._vs = null, this._ro = null, this._renderer = null, this._trigMgr = new ns(), this._destroyed = !1, this._autoHeightWarned = !1, this._colWidths = [], this._userWidths = /* @__PURE__ */ new Map(), this._filterPanel = null, this._filterSelect = null, this._pagination = null, this._dnd = null, this._mergeEngine = new tt(), this._liveRegion = null, this._ctxMenu = null, this._cmHandler = null, this._cmKbdHandler = null, this._wsManager = null;
3922
3925
  const s = typeof t == "string" ? document.querySelector(t) : t;
3923
3926
  if (!s) throw new Error(`OpenGrid: container not found: ${t}`);
3924
3927
  this._container = s, this._options = {
@@ -3963,7 +3966,7 @@ const jt = "_ogRowId", V = class V extends oe {
3963
3966
  cssVars: {},
3964
3967
  ariaLabel: "OPEN_GRID 데이터 그리드",
3965
3968
  ...e
3966
- }, this._data = new re(jt), this._rowMgr = new Ie(this._data), this._colLayout = new Lt(this._options.columns, this._options.frozenColumns), this._editMgr = new Be({
3969
+ }, this._data = new ae(Gt), this._rowMgr = new Oe(this._data), this._colLayout = new Ft(this._options.columns, this._options.frozenColumns), this._editMgr = new We({
3967
3970
  data: this._data,
3968
3971
  colLayout: this._colLayout,
3969
3972
  getRenderer: () => this._renderer,
@@ -3978,7 +3981,7 @@ const jt = "_ogRowId", V = class V extends oe {
3978
3981
  return (r = this._vs) == null ? void 0 : r.scrollToRow(n);
3979
3982
  },
3980
3983
  getVisibleLeaves: () => this._colLayout.visibleLeaves
3981
- }), this._exportMgr = new Ue({
3984
+ }), this._exportMgr = new qe({
3982
3985
  getData: () => this._data.getData(),
3983
3986
  getColLayout: () => this._colLayout,
3984
3987
  getColWidths: () => this._colWidths,
@@ -3987,14 +3990,14 @@ const jt = "_ogRowId", V = class V extends oe {
3987
3990
  getMaskEnabled: (n) => this.getMaskEnabled(n),
3988
3991
  getWsManager: () => this._wsManager,
3989
3992
  getStrategy: (n, r) => this._ovk.getStrategy(n, r)
3990
- }), this._footerMgr = new Ge({
3993
+ }), this._footerMgr = new Xe({
3991
3994
  getData: () => this._data.getData(),
3992
3995
  getColLayout: () => this._colLayout,
3993
3996
  getColWidths: () => this._colWidths,
3994
3997
  getOptions: () => this._options,
3995
3998
  getContainer: () => this._container,
3996
3999
  getStrategy: (n, r) => this._ovk.getStrategy(n, r)
3997
- }), this._kbdMgr = new qe({
4000
+ }), this._kbdMgr = new Ye({
3998
4001
  getEditMgr: () => this._editMgr,
3999
4002
  getRowMgr: () => this._rowMgr,
4000
4003
  getData: () => this._data,
@@ -4007,7 +4010,7 @@ const jt = "_ogRowId", V = class V extends oe {
4007
4010
  emit: (n, ...r) => this.emit(n, ...r),
4008
4011
  visRange: () => this._visRange(),
4009
4012
  handleCellKeyEvt: (n, r) => this._handleCellKeyEvt(n, r)
4010
- }), this._sfMgr = new es({
4013
+ }), this._sfMgr = new is({
4011
4014
  getData: () => this._data,
4012
4015
  getColLayout: () => this._colLayout,
4013
4016
  getFindFilter: () => this._findMgr.findFilter,
@@ -4018,14 +4021,14 @@ const jt = "_ogRowId", V = class V extends oe {
4018
4021
  doRender: () => this._doRender(...this._visRange()),
4019
4022
  announce: (n) => this._announce(n),
4020
4023
  emit: (n, ...r) => this.emit(n, ...r)
4021
- }), this._findMgr = new Xe({
4024
+ }), this._findMgr = new Je({
4022
4025
  getColLayout: () => this._colLayout,
4023
4026
  getData: () => this._data,
4024
4027
  getFilters: () => this._sfMgr.filters,
4025
4028
  getVs: () => this._vs,
4026
4029
  getPagination: () => this._pagination,
4027
4030
  doRender: () => this._doRender(...this._visRange())
4028
- }), this._cellEvt = new ss({
4031
+ }), this._cellEvt = new os({
4029
4032
  getData: () => this._data,
4030
4033
  getColLayout: () => this._colLayout,
4031
4034
  getOptions: () => this._options,
@@ -4035,7 +4038,7 @@ const jt = "_ogRowId", V = class V extends oe {
4035
4038
  writeCell: (n, r, l) => this.writeCell(n, r, l),
4036
4039
  doRender: () => this._doRender(...this._visRange()),
4037
4040
  getContainer: () => this._container
4038
- }), this._grpMgr = new ts({
4041
+ }), this._grpMgr = new ss({
4039
4042
  getData: () => this._data.getData(),
4040
4043
  getDataLayer: () => this._data,
4041
4044
  getOptions: () => this._options,
@@ -4043,25 +4046,25 @@ const jt = "_ogRowId", V = class V extends oe {
4043
4046
  doRenderFull: (n) => this._doRender(0, n - 1),
4044
4047
  doRender: () => this._doRender(...this._visRange()),
4045
4048
  getStrategy: (n, r) => this._ovk.getStrategy(n, r)
4046
- }), this._ovk = new as(this, { strict: this._options.overrideStrict ?? !0 }), this._data.setStrategyResolver((n, r) => this._ovk.getStrategy(n, r)), be(
4049
+ }), this._ovk = new cs(this, { strict: this._options.overrideStrict ?? !0 }), this._data.setStrategyResolver((n, r) => this._ovk.getStrategy(n, r)), xe(
4047
4050
  (n, r, l) => {
4048
4051
  var a;
4049
4052
  return ((a = this._ovk.getStrategy("displayFormatter", null)) == null ? void 0 : a(n, r, l)) ?? null;
4050
4053
  }
4051
- ), this._mount(), this._bindOptionEvents(), (o = this._options.defaultSort) != null && o.length && this._sfMgr.initSort(this._options.defaultSort), this.override = Object.assign(
4054
+ ), this._mount(), this._bindOptionEvents(), (i = this._options.defaultSort) != null && i.length && this._sfMgr.initSort(this._options.defaultSort), this.override = Object.assign(
4052
4055
  (n, r, l) => this._ovk.override(n, r, l),
4053
4056
  { strategy: (n, r) => this._ovk.strategy(n, r) }
4054
4057
  );
4055
- const i = this.destroy.bind(this);
4058
+ const o = this.destroy.bind(this);
4056
4059
  this.destroy = () => {
4057
4060
  try {
4058
- i();
4061
+ o();
4059
4062
  } finally {
4060
4063
  this._ovk.restoreAll();
4061
4064
  }
4062
4065
  };
4063
- for (const [n, r] of V._defaultStrategies) this._ovk.strategy(n, r);
4064
- for (const [n, r, l] of V._defaultOverrides) this._ovk.override(n, r, l);
4066
+ for (const [n, r] of U._defaultStrategies) this._ovk.strategy(n, r);
4067
+ for (const [n, r, l] of U._defaultOverrides) this._ovk.override(n, r, l);
4065
4068
  requestAnimationFrame(() => {
4066
4069
  var n, r;
4067
4070
  this.emit("ready", this), (r = (n = this._options).onReady) == null || r.call(n, this);
@@ -4069,7 +4072,7 @@ const jt = "_ogRowId", V = class V extends oe {
4069
4072
  }
4070
4073
  /** 정적: 모든 신규 그리드에 적용될 override 레이어 등록. */
4071
4074
  static defaultOverride(t, e, s = {}) {
4072
- return V._defaultOverrides.push([t, e, s]), V;
4075
+ return U._defaultOverrides.push([t, e, s]), U;
4073
4076
  }
4074
4077
  // ── grid.override() 위임 메서드 ──────────────────────────
4075
4078
  restore(t) {
@@ -4088,63 +4091,64 @@ const jt = "_ogRowId", V = class V extends oe {
4088
4091
  return this._ovk.getStrategy(t, e);
4089
4092
  }
4090
4093
  _mount() {
4091
- var s, i;
4094
+ var s, o;
4092
4095
  this._container.classList.add("og-container");
4093
4096
  const t = this._options.height, e = this._options.width;
4094
4097
  this._container.style.height = typeof t == "number" ? `${t}px` : String(t), this._container.style.width = typeof e == "number" ? `${e}px` : String(e), this._container.style.display = "flex", this._container.style.flexDirection = "column", this._container.style.overflow = "hidden", this._container.style.boxSizing = "border-box", this._container.style.border = "1px solid var(--og-border-color, #e0e0e0)", this._container.style.fontFamily = "var(--og-font-family, -apple-system, sans-serif)", this._container.style.fontSize = "var(--og-font-size, 13px)", this._container.setAttribute("data-og-theme", this._options.theme);
4095
- for (const [o, n] of Object.entries(this._options.cssVars))
4096
- this._container.style.setProperty(o, n);
4097
- this._renderer = new He(this._container, this._options, {
4098
- onHeaderClick: (o, n) => this._handleSortClick(o, n),
4099
- onCellClick: (o, n, r) => this._handleCellClick(o, n, r),
4100
- onCellDblClick: (o, n, r) => this._handleCellDblClick(o, n, r),
4101
- onCellMouseOver: (o, n, r) => this._handleCellMouseOver(o, n, r),
4102
- onCellMouseOut: (o, n, r) => this._handleCellMouseOut(o, n, r),
4103
- onCellMouseDown: (o, n, r) => this._handleCellMouseDown(o, n, r),
4104
- onCellMouseUp: (o, n, r) => this._handleCellMouseUp(o, n, r),
4105
- onCellMouseMove: (o, n, r) => this._handleCellMouseMove(o, n, r),
4106
- onRowCheck: (o, n) => this._handleRowCheck(o, n),
4107
- onAllCheck: (o) => this._handleAllCheck(o),
4108
- onColResize: (o, n) => this._handleColResize(o, n),
4109
- onFilterIconClick: (o, n) => this._handleFilterIconClick(o, n),
4098
+ for (const [i, n] of Object.entries(this._options.cssVars))
4099
+ this._container.style.setProperty(i, n);
4100
+ this._renderer = new Ie(this._container, this._options, {
4101
+ onHeaderClick: (i, n) => this._handleSortClick(i, n),
4102
+ onCellClick: (i, n, r) => this._handleCellClick(i, n, r),
4103
+ onCellDblClick: (i, n, r) => this._handleCellDblClick(i, n, r),
4104
+ onCellMouseOver: (i, n, r) => this._handleCellMouseOver(i, n, r),
4105
+ onCellMouseOut: (i, n, r) => this._handleCellMouseOut(i, n, r),
4106
+ onCellMouseDown: (i, n, r) => this._handleCellMouseDown(i, n, r),
4107
+ onCellMouseUp: (i, n, r) => this._handleCellMouseUp(i, n, r),
4108
+ onCellMouseMove: (i, n, r) => this._handleCellMouseMove(i, n, r),
4109
+ onRowCheck: (i, n) => this._handleRowCheck(i, n),
4110
+ onAllCheck: (i) => this._handleAllCheck(i),
4111
+ onColResize: (i, n) => this._handleColResize(i, n),
4112
+ onFilterIconClick: (i, n) => this._handleFilterIconClick(i, n),
4110
4113
  getDndManager: () => this._dnd,
4111
- onColDragStart: (o) => {
4112
- this._editMgr.dragColIdx = o;
4114
+ onColDragStart: (i) => {
4115
+ this._editMgr.dragColIdx = i;
4113
4116
  },
4114
- onColDrop: (o) => {
4115
- this._editMgr.dragColIdx !== null && this._editMgr.dragColIdx !== o && this._reorderColumn(this._editMgr.dragColIdx, o), this._editMgr.dragColIdx = null;
4117
+ onColDrop: (i) => {
4118
+ this._editMgr.dragColIdx !== null && this._editMgr.dragColIdx !== i && this._reorderColumn(this._editMgr.dragColIdx, i), this._editMgr.dragColIdx = null;
4116
4119
  },
4117
- getColDragIdx: () => this._editMgr.dragColIdx
4118
- }), this._filterPanel = new de(
4120
+ getColDragIdx: () => this._editMgr.dragColIdx,
4121
+ getDisplayText: (i, n) => this.hasOverride("getDisplayValue") || this._ovk.hasStrategy("displayFormatter") ? this.getDisplayValue(i, n) : null
4122
+ }), this._filterPanel = new he(
4119
4123
  this._container,
4120
- (o, n) => this.setFilter(o, n),
4121
- (o) => this.resetFilter(o)
4122
- ), this._container.setAttribute("role", "grid"), this._container.setAttribute("aria-label", this._options.ariaLabel ?? ((s = this._options.cssVars) == null ? void 0 : s["aria-label"]) ?? "OPEN_GRID 데이터 그리드"), this._container.setAttribute("aria-rowcount", "0"), this._container.setAttribute("aria-colcount", String(this._options.columns.filter((o) => !o.hidden).length)), this._liveRegion = document.createElement("div"), this._liveRegion.setAttribute("aria-live", "polite"), this._liveRegion.setAttribute("aria-atomic", "true"), this._liveRegion.className = "og-live-region", this._container.insertAdjacentElement("beforebegin", this._liveRegion), this._container.tabIndex = 0, this._container.addEventListener("keydown", (o) => this._handleKeyDown(o)), this._container.addEventListener("keyup", (o) => this._handleCellKeyEvt("cellKeyUp", o)), this._container.addEventListener("keypress", (o) => this._handleCellKeyEvt("cellKeyPress", o)), this._vs = new ae(this._renderer.bodyWrapper, {
4124
+ (i, n) => this.setFilter(i, n),
4125
+ (i) => this.resetFilter(i)
4126
+ ), this._container.setAttribute("role", "grid"), this._container.setAttribute("aria-label", this._options.ariaLabel ?? ((s = this._options.cssVars) == null ? void 0 : s["aria-label"]) ?? "OPEN_GRID 데이터 그리드"), this._container.setAttribute("aria-rowcount", "0"), this._container.setAttribute("aria-colcount", String(this._options.columns.filter((i) => !i.hidden).length)), this._liveRegion = document.createElement("div"), this._liveRegion.setAttribute("aria-live", "polite"), this._liveRegion.setAttribute("aria-atomic", "true"), this._liveRegion.className = "og-live-region", this._container.insertAdjacentElement("beforebegin", this._liveRegion), this._container.tabIndex = 0, this._container.addEventListener("keydown", (i) => this._handleKeyDown(i)), this._container.addEventListener("keyup", (i) => this._handleCellKeyEvt("cellKeyUp", i)), this._container.addEventListener("keypress", (i) => this._handleCellKeyEvt("cellKeyPress", i)), this._vs = new ce(this._renderer.bodyWrapper, {
4123
4127
  rowHeight: this._options.rowHeight,
4124
- onRender: (o, n) => this._doRender(o, n)
4125
- }), ct.register(this._renderer.bodyWrapper, this), this._options.draggable && (this._dnd = new Pe(
4128
+ onRender: (i, n) => this._doRender(i, n)
4129
+ }), ht.register(this._renderer.bodyWrapper, this), this._options.draggable && (this._dnd = new je(
4126
4130
  this._renderer.bodyWrapper,
4127
4131
  this._options.rowHeight,
4128
- (o, n) => this._handleRowDrop(o, n),
4132
+ (i, n) => this._handleRowDrop(i, n),
4129
4133
  this._options.crossGrid ? {
4130
- resolveTarget: (o, n) => {
4131
- const r = ct.resolveAt(o, n, this);
4134
+ resolveTarget: (i, n) => {
4135
+ const r = ht.resolveAt(i, n, this);
4132
4136
  return !r || !r._options.crossGrid ? null : { bodyEl: r._crossBodyEl(), rowHeight: r._options.rowHeight, totalRows: r._data.rowCount };
4133
4137
  },
4134
- onCrossDrop: (o, n, r) => this._handleCrossGridDrop(o, n, r)
4138
+ onCrossDrop: (i, n, r) => this._handleCrossGridDrop(i, n, r)
4135
4139
  } : void 0,
4136
- (o) => this._dragRowSet(o).length
4137
- )), this._options.pagination && (this._pagination = new We(
4140
+ (i) => this._dragRowSet(i).length
4141
+ )), this._options.pagination && (this._pagination = new Ke(
4138
4142
  this._container,
4139
4143
  this._options.pageSize,
4140
- (o) => {
4141
- this.emit("pageChange", o), this._doRender(...this._visRange());
4144
+ (i) => {
4145
+ this.emit("pageChange", i), this._doRender(...this._visRange());
4142
4146
  }
4143
- )), this._findMgr.init(this._container), this._initContextMenu(), (i = this._options.worksheets) != null && i.length && this._initWorksheets(), this._ro = new ResizeObserver(() => this._onResize()), this._ro.observe(this._container), this._onResize();
4147
+ )), this._findMgr.init(this._container), this._initContextMenu(), (o = this._options.worksheets) != null && o.length && this._initWorksheets(), this._ro = new ResizeObserver(() => this._onResize()), this._ro.observe(this._container), this._onResize();
4144
4148
  }
4145
4149
  _initContextMenu() {
4146
4150
  const t = this._options.contextMenu;
4147
- t !== !1 && (this._cmHandler && this._container.removeEventListener("contextmenu", this._cmHandler), this._cmKbdHandler && this._container.removeEventListener("keydown", this._cmKbdHandler), this._cmHandler = this._cmKbdHandler = null, this._ctxMenu = new je(this._container, {
4151
+ t !== !1 && (this._cmHandler && this._container.removeEventListener("contextmenu", this._cmHandler), this._cmKbdHandler && this._container.removeEventListener("keydown", this._cmKbdHandler), this._cmHandler = this._cmKbdHandler = null, this._ctxMenu = new Ge(this._container, {
4148
4152
  onSortAsc: () => {
4149
4153
  const e = this._colLayout.visibleLeaves[0];
4150
4154
  e && this.orderBy(e.field, "asc");
@@ -4162,16 +4166,16 @@ const jt = "_ogRowId", V = class V extends oe {
4162
4166
  const s = e.target.closest(".og-cell");
4163
4167
  if (!s) return;
4164
4168
  e.preventDefault();
4165
- const i = Number(s.dataset.colIndex ?? -1), o = this._colLayout.visibleLeaves[i];
4166
- o && this._ctxMenu && (this._ctxMenu._actions.onSortAsc = () => this.orderBy(o.field, "asc"), this._ctxMenu._actions.onSortDesc = () => this.orderBy(o.field, "desc"));
4169
+ const o = Number(s.dataset.colIndex ?? -1), i = this._colLayout.visibleLeaves[o];
4170
+ i && this._ctxMenu && (this._ctxMenu._actions.onSortAsc = () => this.orderBy(i.field, "asc"), this._ctxMenu._actions.onSortDesc = () => this.orderBy(i.field, "desc"));
4167
4171
  const n = Array.isArray(t) ? t : void 0;
4168
4172
  (r = this._ctxMenu) == null || r.open(e, n);
4169
4173
  }, this._container.addEventListener("contextmenu", this._cmHandler), this._cmKbdHandler = (e) => {
4170
4174
  var s;
4171
4175
  if (e.shiftKey && e.key === "F10") {
4172
4176
  e.preventDefault();
4173
- const i = this._container.getBoundingClientRect(), o = { clientX: i.left + 80, clientY: i.top + 40 };
4174
- (s = this._ctxMenu) == null || s.open(o);
4177
+ const o = this._container.getBoundingClientRect(), i = { clientX: o.left + 80, clientY: o.top + 40 };
4178
+ (s = this._ctxMenu) == null || s.open(i);
4175
4179
  }
4176
4180
  }, this._container.addEventListener("keydown", this._cmKbdHandler));
4177
4181
  }
@@ -4186,10 +4190,10 @@ const jt = "_ogRowId", V = class V extends oe {
4186
4190
  }
4187
4191
  setFilterSelect(t) {
4188
4192
  var e;
4189
- (e = this._filterSelect) == null || e.destroy(), this._filterSelect = null, t && (this._container.id || (this._container.id = `og-${Math.random().toString(36).slice(2, 7)}`), this._filterSelect = new Oe(
4193
+ (e = this._filterSelect) == null || e.destroy(), this._filterSelect = null, t && (this._container.id || (this._container.id = `og-${Math.random().toString(36).slice(2, 7)}`), this._filterSelect = new Ne(
4190
4194
  this._container,
4191
4195
  t,
4192
- (s, i) => this.setFilter(s, i),
4196
+ (s, o) => this.setFilter(s, o),
4193
4197
  (s) => this.resetFilter(s),
4194
4198
  this._container.id
4195
4199
  ));
@@ -4210,9 +4214,9 @@ const jt = "_ogRowId", V = class V extends oe {
4210
4214
  * enabled=false → 컬럼 전체 마스킹 해제 (원문 표시)
4211
4215
  */
4212
4216
  setMaskEnabled(t, e) {
4213
- var i;
4217
+ var o;
4214
4218
  const s = this._colLayout.getColumnByField(t);
4215
- s && (e ? (s._maskRevealed = !1, (i = s._maskRevealedRows) == null || i.clear()) : s._maskRevealed = !0, this._doRender(...this._visRange()));
4219
+ s && (e ? (s._maskRevealed = !1, (o = s._maskRevealedRows) == null || o.clear()) : s._maskRevealed = !0, this._doRender(...this._visRange()));
4216
4220
  }
4217
4221
  /** 현재 컬럼 마스킹 활성 여부 반환. true=마스킹 중, false=해제됨 */
4218
4222
  getMaskEnabled(t) {
@@ -4221,7 +4225,7 @@ const jt = "_ogRowId", V = class V extends oe {
4221
4225
  }
4222
4226
  _initWorksheets() {
4223
4227
  const t = this._options.worksheets;
4224
- this._wsManager = new Kt(
4228
+ this._wsManager = new Vt(
4225
4229
  this._container,
4226
4230
  (e, s) => this._loadWorksheetState(s)
4227
4231
  );
@@ -4233,18 +4237,18 @@ const jt = "_ogRowId", V = class V extends oe {
4233
4237
  // _visRange 가 빈 범위를 돌려줘 행이 렌더되지 않는다(데이터 미표시 버그).
4234
4238
  // 공개 setData 와 동일하게 _vs.setTotalRows + aria + 컬럼폭 재계산까지 수행한다.
4235
4239
  _loadWorksheetState(t) {
4236
- var s, i;
4237
- this._rowMgr.reset(), this._data.setData(t.data), this._colLayout = new Lt(
4240
+ var s, o;
4241
+ this._rowMgr.reset(), this._data.setData(t.data), this._colLayout = new Ft(
4238
4242
  t.columns.length ? t.columns : this._options.columns,
4239
4243
  this._options.frozenColumns
4240
- ), (s = this._vs) == null || s.setTotalRows(this._data.rowCount), (i = this._pagination) == null || i.setTotalRows(this._data.rowCount), this._container.setAttribute("aria-rowcount", String(this._data.rowCount)), this._container.setAttribute("aria-colcount", String(this._colLayout.visibleLeaves.length));
4244
+ ), (s = this._vs) == null || s.setTotalRows(this._data.rowCount), (o = this._pagination) == null || o.setTotalRows(this._data.rowCount), this._container.setAttribute("aria-rowcount", String(this._data.rowCount)), this._container.setAttribute("aria-colcount", String(this._colLayout.visibleLeaves.length));
4241
4245
  const { width: e } = this._container.getBoundingClientRect();
4242
4246
  e && this._recalcWidths(e), this._renderHeader(), this._doRender(...this._visRange());
4243
4247
  }
4244
4248
  addWorksheet(t, e, s) {
4245
- this._wsManager || (this._wsManager = new Kt(
4249
+ this._wsManager || (this._wsManager = new Vt(
4246
4250
  this._container,
4247
- (i, o) => this._loadWorksheetState(o)
4251
+ (o, i) => this._loadWorksheetState(i)
4248
4252
  )), this._wsManager.add(t, e ?? this._options.columns, s ?? []);
4249
4253
  }
4250
4254
  removeWorksheet(t) {
@@ -4282,8 +4286,8 @@ const jt = "_ogRowId", V = class V extends oe {
4282
4286
  t - (this._options.stateColumn ? 24 : 0) - (this._options.draggable ? 18 : 0) - (this._options.rowNumber ? 44 : 0) - (this._options.checkColumn ? 36 : 0),
4283
4287
  this._options.defaultColumnWidth
4284
4288
  ), this._userWidths.size && this._colLayout.visibleLeaves.forEach((e, s) => {
4285
- const i = this._userWidths.get(e.field);
4286
- i != null && (this._colWidths[s] = i);
4289
+ const o = this._userWidths.get(e.field);
4290
+ o != null && (this._colWidths[s] = o);
4287
4291
  });
4288
4292
  }
4289
4293
  // 헤더(컬럼 제목 행)를 다시 그린다
@@ -4309,10 +4313,10 @@ const jt = "_ogRowId", V = class V extends oe {
4309
4313
  this._renderer.updateSize(t - this._paginationHeight(), s), this._vs.setViewportHeight(t - s - this._paginationHeight());
4310
4314
  }
4311
4315
  _doRender(t, e) {
4312
- var o;
4316
+ var i;
4313
4317
  if (!this._renderer || !this._vs) return;
4314
- const s = this._vs.getVisibleRange(), i = this._options.autoHeight === !0;
4315
- i && ([t, e] = this._visRange(), !this._autoHeightWarned && e - t + 1 > 2e3 && (this._autoHeightWarned = !0, console.warn(
4318
+ const s = this._vs.getVisibleRange(), o = this._options.autoHeight === !0;
4319
+ o && ([t, e] = this._visRange(), !this._autoHeightWarned && e - t + 1 > 2e3 && (this._autoHeightWarned = !0, console.warn(
4316
4320
  `[OpenGrid] autoHeight 는 가상 스크롤이 아니라 전 행(${e - t + 1}행)을 렌더합니다. 행이 많으면 고정 rowHeight(가상 스크롤) 사용을 권장합니다.`
4317
4321
  ))), this._renderer.renderBody(
4318
4322
  t,
@@ -4321,8 +4325,8 @@ const jt = "_ogRowId", V = class V extends oe {
4321
4325
  this._colLayout.visibleLeaves,
4322
4326
  this._colWidths,
4323
4327
  this._options,
4324
- i ? 0 : s.offsetY,
4325
- i ? 0 : this._vs.getTotalHeight(),
4328
+ o ? 0 : s.offsetY,
4329
+ o ? 0 : this._vs.getTotalHeight(),
4326
4330
  this._rowMgr.selectedRows,
4327
4331
  this._rowMgr.checkedRows,
4328
4332
  this._grpMgr.isGroupMode ? this._grpMgr.groupFlatRows : this._grpMgr.isTreeMode ? this._grpMgr.treeFlatRows : null,
@@ -4330,7 +4334,7 @@ const jt = "_ogRowId", V = class V extends oe {
4330
4334
  this._grpMgr.isTreeMode ? (n) => this._grpMgr.handleTreeToggle(n) : void 0,
4331
4335
  { _totalRows: this._data.rowCount, _frozenCount: this._colLayout.frozenCount, _focusCell: this._editMgr.focusCell },
4332
4336
  this._mergeEngine
4333
- ), (o = this._options.footer) != null && o.length && this._renderFooterEl();
4337
+ ), (i = this._options.footer) != null && i.length && this._renderFooterEl();
4334
4338
  }
4335
4339
  _handleGroupToggle(t) {
4336
4340
  this._grpMgr.handleGroupToggle(t);
@@ -4339,8 +4343,8 @@ const jt = "_ogRowId", V = class V extends oe {
4339
4343
  _visRange() {
4340
4344
  var e;
4341
4345
  if (this._options.pagination && this._pagination) {
4342
- const { start: s, end: i } = this._pagination.getRange();
4343
- return [s, i];
4346
+ const { start: s, end: o } = this._pagination.getRange();
4347
+ return [s, o];
4344
4348
  }
4345
4349
  if (this._options.autoHeight)
4346
4350
  return [0, (this._grpMgr.isGroupMode ? this._grpMgr.groupFlatRows.length : this._grpMgr.isTreeMode ? this._grpMgr.treeFlatRows.length : this._data.rowCount) - 1];
@@ -4355,7 +4359,7 @@ const jt = "_ogRowId", V = class V extends oe {
4355
4359
  this._sfMgr.handleSortClick(t, e);
4356
4360
  }
4357
4361
  _isToggleCol(t) {
4358
- return nt(t);
4362
+ return rt(t);
4359
4363
  }
4360
4364
  _handleCellClick(t, e, s) {
4361
4365
  this._cellEvt.handleCellClick(t, e, s);
@@ -4385,20 +4389,20 @@ const jt = "_ogRowId", V = class V extends oe {
4385
4389
  this._rowMgr.check(t, e), this._doRender(...this._visRange()), this.emit("rowCheck", { rowIndex: t, checked: e, row: this._data.getRowByIndex(t) });
4386
4390
  }
4387
4391
  _handleFilterIconClick(t, e) {
4388
- var i, o;
4389
- if ((i = this._filterPanel) != null && i.isOpen) {
4392
+ var o, i;
4393
+ if ((o = this._filterPanel) != null && o.isOpen) {
4390
4394
  this._filterPanel.close();
4391
4395
  return;
4392
4396
  }
4393
4397
  const s = this._sfMgr.filters[t] ?? [];
4394
- (o = this._filterPanel) == null || o.open(t, e, s);
4398
+ (i = this._filterPanel) == null || i.open(t, e, s);
4395
4399
  }
4396
4400
  _handleAllCheck(t) {
4397
4401
  this._rowMgr.checkAll(t, this._data.rowCount), this._doRender(...this._visRange()), this.emit("allCheck", { checked: t });
4398
4402
  }
4399
4403
  _handleRowDrop(t, e) {
4400
- var s, i;
4401
- this._data.moveRow(t, e), this._doRender(...this._visRange()), this.emit("rowDrop", { fromIndex: t, toIndex: e }), (i = (s = this._options).onRowDrop) == null || i.call(s, { fromIndex: t, toIndex: e });
4404
+ var s, o;
4405
+ this._data.moveRow(t, e), this._doRender(...this._visRange()), this.emit("rowDrop", { fromIndex: t, toIndex: e }), (o = (s = this._options).onRowDrop) == null || o.call(s, { fromIndex: t, toIndex: e });
4402
4406
  }
4403
4407
  // ── 크로스그리드 내부 헬퍼 ──
4404
4408
  /** 드래그/셔틀이 참조하는 바디 엘리먼트 (레지스트리 해석용) */
@@ -4408,12 +4412,12 @@ const jt = "_ogRowId", V = class V extends oe {
4408
4412
  /** fromIndex 를 잡고 드래그할 때 함께 이동할 행 집합 (다중선택에 포함되면 선택 전체) */
4409
4413
  _dragRowSet(t) {
4410
4414
  const e = [...this._rowMgr.selectedRows];
4411
- return e.length > 1 && e.includes(t) ? e.sort((s, i) => s - i) : [t];
4415
+ return e.length > 1 && e.includes(t) ? e.sort((s, o) => s - o) : [t];
4412
4416
  }
4413
4417
  /** 드래그 드롭 어댑터 → 공개 moveRowsTo 로 위임 */
4414
4418
  _handleCrossGridDrop(t, e, s) {
4415
- const i = ct.get(e);
4416
- !i || i === this || this.moveRowsTo(i, this._dragRowSet(t), s);
4419
+ const o = ht.get(e);
4420
+ !o || o === this || this.moveRowsTo(o, this._dragRowSet(t), s);
4417
4421
  }
4418
4422
  /**
4419
4423
  * 이 그리드의 행들을 다른 그리드로 이동(move)한다. 드래그·화살표 셔틀 공통 경로.
@@ -4424,24 +4428,24 @@ const jt = "_ogRowId", V = class V extends oe {
4424
4428
  * @returns 이동 성공 true, 취소/무효 false
4425
4429
  */
4426
4430
  async moveRowsTo(t, e, s) {
4427
- const i = t;
4428
- if (!i || i === this || !e.length) return !1;
4429
- const o = [...new Set(e)].sort((c, u) => c - u), n = s ?? i._data.rowCount;
4430
- let r = o.map((c) => {
4431
+ const o = t;
4432
+ if (!o || o === this || !e.length) return !1;
4433
+ const i = [...new Set(e)].sort((c, u) => c - u), n = s ?? o._data.rowCount;
4434
+ let r = i.map((c) => {
4431
4435
  const u = { ...this._data.getRowByIndex(c) };
4432
- return delete u[jt], u;
4436
+ return delete u[Gt], u;
4433
4437
  });
4434
- const l = await this._resolveCrossTransform(i);
4438
+ const l = await this._resolveCrossTransform(o);
4435
4439
  if (l === !1) return !1;
4436
4440
  l && (r = r.map((c) => l(c)));
4437
4441
  const a = {
4438
4442
  sourceGrid: this,
4439
- targetGrid: i,
4443
+ targetGrid: o,
4440
4444
  rows: r,
4441
- sourceIndexes: o,
4445
+ sourceIndexes: i,
4442
4446
  targetIndex: n
4443
4447
  };
4444
- return this._fireGridDropBefore(a) === !1 || a.cancel || i._fireGridDropBefore(a) === !1 || a.cancel ? !1 : (r.forEach((c, u) => i.insertRow(c, n + u)), [...o].sort((c, u) => u - c).forEach((c) => this.deleteRow(c)), this._fireGridDropAfter(a), i._fireGridDropAfter(a), this._fireGridDropComplete(a), i._fireGridDropComplete(a), !0);
4448
+ return this._fireGridDropBefore(a) === !1 || a.cancel || o._fireGridDropBefore(a) === !1 || a.cancel ? !1 : (r.forEach((c, u) => o.insertRow(c, n + u)), [...i].sort((c, u) => u - c).forEach((c) => this.deleteRow(c)), this._fireGridDropAfter(a), o._fireGridDropAfter(a), this._fireGridDropComplete(a), o._fireGridDropComplete(a), !0);
4445
4449
  }
4446
4450
  /** 체크된 행을 다른 그리드로 이동 (화살표 셔틀용). 체크 없으면 무시. */
4447
4451
  async moveCheckedTo(t) {
@@ -4457,18 +4461,18 @@ const jt = "_ogRowId", V = class V extends oe {
4457
4461
  const e = this._options.crossGridMapping;
4458
4462
  if (typeof e == "function") return e;
4459
4463
  if (e !== "interactive") return null;
4460
- const s = this._colLayout.visibleLeaves.map((a) => ({ field: a.field, header: a.header })), i = t._colLayout.visibleLeaves.map((a) => ({ field: a.field, header: a.header }));
4461
- if (ns(s.map((a) => a.field), i.map((a) => a.field))) return null;
4462
- const o = await rs(s, i);
4463
- if (!o) return !1;
4464
+ const s = this._colLayout.visibleLeaves.map((a) => ({ field: a.field, header: a.header })), o = t._colLayout.visibleLeaves.map((a) => ({ field: a.field, header: a.header }));
4465
+ if (ls(s.map((a) => a.field), o.map((a) => a.field))) return null;
4466
+ const i = await as(s, o);
4467
+ if (!i) return !1;
4464
4468
  const n = {
4465
4469
  sourceGrid: this,
4466
4470
  targetGrid: t,
4467
- mapping: o.mapping,
4468
- script: o.script
4471
+ mapping: i.mapping,
4472
+ script: i.script
4469
4473
  };
4470
4474
  return this.emit("gridDropMapping", n), (l = (r = this._options).onGridDropMapping) == null || l.call(r, n), console.log(`[OpenGrid] cross-grid mapping script:
4471
- ` + se(o.mapping)), os(o.mapping);
4475
+ ` + oe(i.mapping)), rs(i.mapping);
4472
4476
  }
4473
4477
  _fireGridDropBefore(t) {
4474
4478
  var e, s;
@@ -4519,18 +4523,18 @@ const jt = "_ogRowId", V = class V extends oe {
4519
4523
  return this._data.getOriginalData();
4520
4524
  }
4521
4525
  pushData(t) {
4522
- var i, o;
4526
+ var o, i;
4523
4527
  const e = [...this._data.getAllData(), ...t];
4524
4528
  this._data.setData(e);
4525
4529
  const s = this._data.rowCount;
4526
- (i = this._vs) == null || i.setTotalRows(s), (o = this._pagination) == null || o.setTotalRows(s);
4530
+ (o = this._vs) == null || o.setTotalRows(s), (i = this._pagination) == null || i.setTotalRows(s);
4527
4531
  }
4528
4532
  prefixData(t) {
4529
- var i, o;
4533
+ var o, i;
4530
4534
  const e = [...t, ...this._data.getAllData()];
4531
4535
  this._data.setData(e);
4532
4536
  const s = this._data.rowCount;
4533
- (i = this._vs) == null || i.setTotalRows(s), (o = this._pagination) == null || o.setTotalRows(s);
4537
+ (o = this._vs) == null || o.setTotalRows(s), (i = this._pagination) == null || i.setTotalRows(s);
4534
4538
  }
4535
4539
  clearData() {
4536
4540
  var t, e;
@@ -4540,26 +4544,26 @@ const jt = "_ogRowId", V = class V extends oe {
4540
4544
  var n, r, l, a;
4541
4545
  const s = this._trigMgr.mkCtx("insertRow", [t, e]);
4542
4546
  if (!this._trigMgr.exec("before:insertRow", s)) return;
4543
- const i = e === "before" ? 0 : e === "after" ? this._data.rowCount : e;
4544
- this._data.addRow(t, i);
4545
- const o = this._data.rowCount;
4546
- (n = this._vs) == null || n.setTotalRows(o), (r = this._pagination) == null || r.setTotalRows(o), this._doRender(...this._visRange()), this.emit("dataChange", this._data.getData()), (a = (l = this._options).onDataChange) == null || a.call(l, this._data.getData()), s.result = { rowCount: o, item: t }, this._trigMgr.exec("after:insertRow", s);
4547
+ const o = e === "before" ? 0 : e === "after" ? this._data.rowCount : e;
4548
+ this._data.addRow(t, o);
4549
+ const i = this._data.rowCount;
4550
+ (n = this._vs) == null || n.setTotalRows(i), (r = this._pagination) == null || r.setTotalRows(i), this._doRender(...this._visRange()), this.emit("dataChange", this._data.getData()), (a = (l = this._options).onDataChange) == null || a.call(l, this._data.getData()), s.result = { rowCount: i, item: t }, this._trigMgr.exec("after:insertRow", s);
4547
4551
  }
4548
4552
  pushRow(t) {
4549
- var i, o, n, r;
4553
+ var o, i, n, r;
4550
4554
  (Array.isArray(t) ? t : [t]).forEach((l) => this._data.addRow(l, "last"));
4551
4555
  const s = this._data.rowCount;
4552
- (i = this._vs) == null || i.setTotalRows(s), (o = this._pagination) == null || o.setTotalRows(s), this._doRender(...this._visRange()), this.emit("dataChange", this._data.getData()), (r = (n = this._options).onDataChange) == null || r.call(n, this._data.getData());
4556
+ (o = this._vs) == null || o.setTotalRows(s), (i = this._pagination) == null || i.setTotalRows(s), this._doRender(...this._visRange()), this.emit("dataChange", this._data.getData()), (r = (n = this._options).onDataChange) == null || r.call(n, this._data.getData());
4553
4557
  }
4554
4558
  /** @deprecated 하위호환 alias → pushRow */
4555
4559
  appendRows(t) {
4556
4560
  this.pushRow(t);
4557
4561
  }
4558
4562
  unshiftRow(t) {
4559
- var i, o, n, r;
4563
+ var o, i, n, r;
4560
4564
  (Array.isArray(t) ? t : [t]).forEach((l) => this._data.addRow(l, "first"));
4561
4565
  const s = this._data.rowCount;
4562
- (i = this._vs) == null || i.setTotalRows(s), (o = this._pagination) == null || o.setTotalRows(s), this._doRender(...this._visRange()), this.emit("dataChange", this._data.getData()), (r = (n = this._options).onDataChange) == null || r.call(n, this._data.getData());
4566
+ (o = this._vs) == null || o.setTotalRows(s), (i = this._pagination) == null || i.setTotalRows(s), this._doRender(...this._visRange()), this.emit("dataChange", this._data.getData()), (r = (n = this._options).onDataChange) == null || r.call(n, this._data.getData());
4563
4567
  }
4564
4568
  /** @deprecated 하위호환 alias → unshiftRow */
4565
4569
  prependRows(t) {
@@ -4569,10 +4573,10 @@ const jt = "_ogRowId", V = class V extends oe {
4569
4573
  var n, r, l, a;
4570
4574
  const e = this._trigMgr.mkCtx("deleteRow", [t]), s = Array.isArray(t) ? [...t] : [t];
4571
4575
  if (e.extra = { rows: s.map((c) => this._data.getRowByIndex(c)) }, !this._trigMgr.exec("before:deleteRow", e)) return;
4572
- const i = s.sort((c, u) => u - c);
4573
- i.forEach((c) => this._data.removeRow(c));
4574
- const o = this._data.rowCount;
4575
- (n = this._vs) == null || n.setTotalRows(o), (r = this._pagination) == null || r.setTotalRows(o), this._doRender(...this._visRange()), this.emit("dataChange", this._data.getData()), (a = (l = this._options).onDataChange) == null || a.call(l, this._data.getData()), e.result = { deleted: i.length, rowCount: o }, this._trigMgr.exec("after:deleteRow", e);
4576
+ const o = s.sort((c, u) => u - c);
4577
+ o.forEach((c) => this._data.removeRow(c));
4578
+ const i = this._data.rowCount;
4579
+ (n = this._vs) == null || n.setTotalRows(i), (r = this._pagination) == null || r.setTotalRows(i), this._doRender(...this._visRange()), this.emit("dataChange", this._data.getData()), (a = (l = this._options).onDataChange) == null || a.call(l, this._data.getData()), e.result = { deleted: o.length, rowCount: i }, this._trigMgr.exec("after:deleteRow", e);
4576
4580
  }
4577
4581
  deleteById(t) {
4578
4582
  }
@@ -4583,16 +4587,16 @@ const jt = "_ogRowId", V = class V extends oe {
4583
4587
  const s = this.readCell(t, e);
4584
4588
  return this._ovk.getStrategy(
4585
4589
  "displayFormatter",
4586
- (o, n, r) => o == null ? "" : String(o)
4590
+ (i, n, r) => i == null ? "" : String(i)
4587
4591
  )(s, e, this._data.getRowByIndex(t));
4588
4592
  }
4589
4593
  writeCell(t, e, s) {
4590
4594
  var c, u, h, g;
4591
- const i = this.readCell(t, e), o = this._trigMgr.mkCtx("writeCell", [t, e, s]);
4592
- if (o.extra = { oldValue: i, rowIndex: t, field: e }, !this._trigMgr.exec("before:writeCell", o)) return;
4595
+ const o = this.readCell(t, e), i = this._trigMgr.mkCtx("writeCell", [t, e, s]);
4596
+ if (i.extra = { oldValue: o, rowIndex: t, field: e }, !this._trigMgr.exec("before:writeCell", i)) return;
4593
4597
  this._data.updateCell(t, e, s);
4594
- const n = this._data.getRowByIndex(t), r = this._colLayout.getColumnByField(e), l = this._colLayout.getColumnIndex(e), a = { type: "editEnd", rowIndex: t, columnIndex: l, field: e, oldValue: i, newValue: s, row: n, column: r };
4595
- this.emit("editEnd", a), (u = (c = this._options).onEditEnd) == null || u.call(c, a), this.emit("dataChange", this._data.getData()), (g = (h = this._options).onDataChange) == null || g.call(h, this._data.getData()), this._doRender(...this._visRange()), o.result = { rowIndex: t, field: e, oldValue: i, newValue: s }, this._trigMgr.exec("after:writeCell", o);
4598
+ const n = this._data.getRowByIndex(t), r = this._colLayout.getColumnByField(e), l = this._colLayout.getColumnIndex(e), a = { type: "editEnd", rowIndex: t, columnIndex: l, field: e, oldValue: o, newValue: s, row: n, column: r };
4599
+ this.emit("editEnd", a), (u = (c = this._options).onEditEnd) == null || u.call(c, a), this.emit("dataChange", this._data.getData()), (g = (h = this._options).onDataChange) == null || g.call(h, this._data.getData()), this._doRender(...this._visRange()), i.result = { rowIndex: t, field: e, oldValue: o, newValue: s }, this._trigMgr.exec("after:writeCell", i);
4596
4600
  }
4597
4601
  getRowAt(t) {
4598
4602
  return this._data.getRowByIndex(t);
@@ -4651,8 +4655,8 @@ const jt = "_ogRowId", V = class V extends oe {
4651
4655
  var n, r;
4652
4656
  const s = this._colLayout.visibleLeaves.map((l) => l);
4653
4657
  if (t < 0 || e < 0 || t >= s.length || e >= s.length) return;
4654
- const i = [...this._options.columns], [o] = i.splice(t, 1);
4655
- i.splice(e, 0, o), this._options.columns = i, this.applyColumns(i), (r = (n = this._options).onColumnReorder) == null || r.call(n, { fromIndex: t, toIndex: e, field: o.field ?? "" });
4658
+ const o = [...this._options.columns], [i] = o.splice(t, 1);
4659
+ o.splice(e, 0, i), this._options.columns = o, this.applyColumns(o), (r = (n = this._options).onColumnReorder) == null || r.call(n, { fromIndex: t, toIndex: e, field: i.field ?? "" });
4656
4660
  }
4657
4661
  hideColumn(t) {
4658
4662
  this._colLayout.hideColumn(t), this._recalcWidths(this._container.getBoundingClientRect().width), this._renderHeader(), this._doRender(...this._visRange());
@@ -4741,12 +4745,12 @@ const jt = "_ogRowId", V = class V extends oe {
4741
4745
  /** 자동 병합: 지정 필드 컬럼에서 연속 같은 값을 rowSpan으로 묶는다 */
4742
4746
  /** ?먮룞 蹂묓빀: 吏€??field 而щ읆?먯꽌 ?곗냽 媛숈? 媛믪쓣 rowSpan */
4743
4747
  autoMerge(t) {
4744
- const e = this._colLayout.visibleLeaves, s = [], i = [];
4745
- for (const o of t) {
4746
- const n = e.findIndex((r) => r.field === o);
4747
- n >= 0 && (s.push(n), i.push(o));
4748
+ const e = this._colLayout.visibleLeaves, s = [], o = [];
4749
+ for (const i of t) {
4750
+ const n = e.findIndex((r) => r.field === i);
4751
+ n >= 0 && (s.push(n), o.push(i));
4748
4752
  }
4749
- this._mergeEngine.applyAutoMerge(this._data.getData(), s, i), this._doRender(...this._visRange());
4753
+ this._mergeEngine.applyAutoMerge(this._data.getData(), s, o), this._doRender(...this._visRange());
4750
4754
  }
4751
4755
  /** 蹂묓빀 ?댁젣 */
4752
4756
  clearMerge() {
@@ -4800,7 +4804,7 @@ const jt = "_ogRowId", V = class V extends oe {
4800
4804
  const e = this._data.getData();
4801
4805
  if (t) return e;
4802
4806
  const s = this._colLayout.visibleLeaves;
4803
- return e.map((i) => s.map((o) => i[o.field]));
4807
+ return e.map((o) => s.map((i) => o[i.field]));
4804
4808
  }
4805
4809
  jumpToRow(t) {
4806
4810
  var e;
@@ -4850,18 +4854,18 @@ const jt = "_ogRowId", V = class V extends oe {
4850
4854
  return this._trigMgr.exec(t, e);
4851
4855
  }
4852
4856
  destroy() {
4853
- var t, e, s, i, o, n, r, l;
4854
- this._destroyed || (this._destroyed = !0, this._renderer && ct.unregister(this._renderer.bodyWrapper), this._trigMgr.clear(), (t = this._ro) == null || t.disconnect(), (e = this._vs) == null || e.destroy(), (s = this._filterPanel) == null || s.destroy(), (i = this._dnd) == null || i.destroy(), this._cmHandler && this._container.removeEventListener("contextmenu", this._cmHandler), this._cmKbdHandler && this._container.removeEventListener("keydown", this._cmKbdHandler), this._cmHandler = this._cmKbdHandler = null, (o = this._ctxMenu) == null || o.destroy(), (n = this._wsManager) == null || n.destroy(), (r = this._renderer) == null || r.destroy(), (l = this._liveRegion) == null || l.remove(), this._liveRegion = null, this._container.innerHTML = "", this._container.classList.remove("og-container"), this.removeAllListeners());
4857
+ var t, e, s, o, i, n, r, l;
4858
+ this._destroyed || (this._destroyed = !0, this._renderer && ht.unregister(this._renderer.bodyWrapper), this._trigMgr.clear(), (t = this._ro) == null || t.disconnect(), (e = this._vs) == null || e.destroy(), (s = this._filterPanel) == null || s.destroy(), (o = this._dnd) == null || o.destroy(), this._cmHandler && this._container.removeEventListener("contextmenu", this._cmHandler), this._cmKbdHandler && this._container.removeEventListener("keydown", this._cmKbdHandler), this._cmHandler = this._cmKbdHandler = null, (i = this._ctxMenu) == null || i.destroy(), (n = this._wsManager) == null || n.destroy(), (r = this._renderer) == null || r.destroy(), (l = this._liveRegion) == null || l.remove(), this._liveRegion = null, this._container.innerHTML = "", this._container.classList.remove("og-container"), this.removeAllListeners());
4855
4859
  }
4856
4860
  };
4857
- V._defaultOverrides = [], V._defaultStrategies = [], V.defaults = {
4861
+ U._defaultOverrides = [], U._defaultStrategies = [], U.defaults = {
4858
4862
  strategy(t, e) {
4859
- return V._defaultStrategies.push([t, e]), V;
4863
+ return U._defaultStrategies.push([t, e]), U;
4860
4864
  }
4861
4865
  };
4862
- let Ut = V;
4866
+ let qt = U;
4863
4867
  export {
4864
- Ut as O,
4865
- Vt as b
4868
+ qt as O,
4869
+ Ut as b
4866
4870
  };
4867
- //# sourceMappingURL=OpenGrid-zBt01Yim.js.map
4871
+ //# sourceMappingURL=OpenGrid-Cjv7Os5a.js.map