@kingsimba/nc-ui 0.1.27 → 0.1.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  var et = Object.defineProperty;
2
2
  var tt = (e, t, n) => t in e ? et(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
3
  var q = (e, t, n) => tt(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { jsx as s, jsxs as k, Fragment as nt } from "react/jsx-runtime";
4
+ import { jsx as s, jsxs as A, Fragment as nt } from "react/jsx-runtime";
5
5
  import { d as xe, E as rt, R as ot, T as st, g as it, V as ct, b as at, a as lt, c as dt } from "./GeneratedIcons-HFZmBTBT.js";
6
6
  import ke, { useState as E, useRef as W, useMemo as me, useEffect as B, createContext as se, useContext as Q, Children as ut, isValidElement as pt, forwardRef as ft, useImperativeHandle as ht, useCallback as O, Suspense as mt } from "react";
7
7
  import { createPortal as ue } from "react-dom";
@@ -38,7 +38,7 @@ function He({
38
38
  );
39
39
  return n ? /* @__PURE__ */ s("div", { className: "nc-activity-indicator-overlay", children: o }) : o;
40
40
  }
41
- function K({ variant: e = "default", block: t, size: n = "default", appearance: r = "default", className: o, disabled: i, textSelectable: a, loading: c, onClick: l, children: p, ...f }) {
41
+ function K({ variant: e = "default", block: t, size: n = "default", appearance: r = "default", className: o, disabled: i, textSelectable: a, loading: c, onClick: l, children: u, ...f }) {
42
42
  const v = [
43
43
  "nc-button",
44
44
  e !== "default" ? `nc-${e}` : "",
@@ -51,19 +51,19 @@ function K({ variant: e = "default", block: t, size: n = "default", appearance:
51
51
  c ? "nc-loading" : "",
52
52
  o ?? ""
53
53
  ].filter(Boolean).join(" ");
54
- return /* @__PURE__ */ k(
54
+ return /* @__PURE__ */ A(
55
55
  "button",
56
56
  {
57
57
  className: v,
58
58
  disabled: i || c,
59
- onClick: (h) => {
59
+ onClick: (m) => {
60
60
  if (!c) {
61
61
  if (a) {
62
62
  const y = window.getSelection();
63
63
  if (y && y.toString().length > 0)
64
64
  return;
65
65
  }
66
- l == null || l(h);
66
+ l == null || l(m);
67
67
  }
68
68
  },
69
69
  ...f,
@@ -76,7 +76,7 @@ function K({ variant: e = "default", block: t, size: n = "default", appearance:
76
76
  color: r === "transparent" || e !== "default" && e !== "ghost" ? "white" : void 0
77
77
  }
78
78
  ),
79
- p
79
+ u
80
80
  ]
81
81
  }
82
82
  );
@@ -99,13 +99,13 @@ function Tn({
99
99
  className: c = "",
100
100
  style: l
101
101
  }) {
102
- const p = i ?? /* @__PURE__ */ k(nt, { children: [
102
+ const u = i ?? /* @__PURE__ */ A(nt, { children: [
103
103
  e !== void 0 && /* @__PURE__ */ s("span", { className: "nc-alert-code", children: e }),
104
104
  t
105
105
  ] });
106
- return /* @__PURE__ */ k("div", { className: `nc-alert nc-${n} ${c}`.trim(), style: l, children: [
107
- /* @__PURE__ */ k("div", { className: "nc-alert-main", children: [
108
- /* @__PURE__ */ s("div", { className: `nc-alert-message nc-${n}`, children: p }),
106
+ return /* @__PURE__ */ A("div", { className: `nc-alert nc-${n} ${c}`.trim(), style: l, children: [
107
+ /* @__PURE__ */ A("div", { className: "nc-alert-main", children: [
108
+ /* @__PURE__ */ s("div", { className: `nc-alert-message nc-${n}`, children: u }),
109
109
  a && /* @__PURE__ */ s(
110
110
  "button",
111
111
  {
@@ -134,67 +134,71 @@ function zn({
134
134
  darkMode: n = !1,
135
135
  colored: r = !1
136
136
  }) {
137
- const o = Math.max(0, Math.min(1, Number(e) || 0));
138
- let i;
139
- r ? o < 0.1 ? i = "var(--nc-danger)" : o < 0.2 ? i = "var(--nc-warning)" : i = "var(--nc-success)" : i = n ? "#ffffff" : "#000000";
140
- const a = n ? "rgba(255, 255, 255, 0.5)" : "rgba(0, 0, 0, 0.2)", c = 24, l = 14, p = 2, f = 0, v = 12, d = 0, h = 0, y = 0, g = c, w = l, A = w - d * 2, b = g - d * 2, u = Math.max(1, Math.min(4, w / 4)), m = o === 0 ? 0 : 0.05 + o * 0.95, N = c + p + v, S = 20, z = 0.65, T = Math.max(l, S * z), x = c + p + 1, R = (l - S * z) / 2;
141
- return /* @__PURE__ */ k(
137
+ const o = Math.max(0, Math.min(1, Number(e) || 0)), i = o === 0 ? "-" : String(Math.round(o * 100));
138
+ let a;
139
+ r ? o < 0.1 ? a = "var(--nc-danger)" : o < 0.2 ? a = "var(--nc-warning)" : a = "var(--nc-success)" : a = n ? "#ffffff" : "#000000";
140
+ const c = "var(--nc-battery-shell-bg)", l = 24, u = 14, f = 2, v = 0, d = 12, m = 0, y = 0, g = 0, w = l, k = u, b = k - m * 2, p = w - m * 2, h = Math.max(1, Math.min(4, k / 4)), N = o === 0 ? 0 : 0.05 + o * 0.95, C = l + f + d, z = 20, T = 0.65, x = Math.max(u, z * T), R = l + f + 1, S = (u - z * T) / 2;
141
+ return /* @__PURE__ */ A(
142
142
  "svg",
143
143
  {
144
144
  className: "nc-battery",
145
- width: N,
146
- height: T,
147
- viewBox: `0 0 ${N} ${T}`,
145
+ width: C,
146
+ height: x,
147
+ viewBox: `0 0 ${C} ${x}`,
148
148
  role: "img",
149
- "aria-label": `Battery ${o === 0 ? "-" : Math.round(o * 100) + "%"} ${t}`,
149
+ "aria-label": `Battery ${i === "-" ? "-" : `${i}%`} ${t}`,
150
150
  children: [
151
- /* @__PURE__ */ k("defs", { children: [
152
- /* @__PURE__ */ s("mask", { id: `nc-battery-fill-mask-${o}`, children: /* @__PURE__ */ s("rect", { x: "0", y: "0", width: b * m, height: A, fill: "white" }) }),
153
- /* @__PURE__ */ k("mask", { id: `nc-battery-text-mask-${o}`, children: [
154
- /* @__PURE__ */ s("rect", { x: "0", y: "0", width: N, height: T, fill: "white" }),
155
- /* @__PURE__ */ s("text", { x: h + g / 2, y: l - 3, fontSize: 11, fontWeight: "bold", fill: "black", textAnchor: "middle", children: o === 0 ? "-" : Math.round(o * 100) })
156
- ] })
157
- ] }),
158
- /* @__PURE__ */ k("g", { mask: `url(#nc-battery-text-mask-${o})`, children: [
159
- /* @__PURE__ */ s(
160
- "rect",
161
- {
162
- x: h,
163
- y,
164
- rx: u,
165
- ry: u,
166
- width: g,
167
- height: w,
168
- fill: a
169
- }
170
- ),
171
- /* @__PURE__ */ s(
172
- "rect",
173
- {
174
- x: h + d,
175
- y: y + d,
176
- width: b,
177
- height: A,
178
- fill: i,
179
- rx: u,
180
- ry: u,
181
- mask: `url(#nc-battery-fill-mask-${o})`
182
- }
183
- ),
184
- /* @__PURE__ */ s(
185
- "rect",
186
- {
187
- x: c + f,
188
- y: l * 0.26,
189
- width: p,
190
- height: l * 0.48,
191
- rx: 0.8,
192
- ry: 0.8,
193
- fill: o === 1 ? i : a
194
- }
195
- ),
196
- t === "charging" ? /* @__PURE__ */ s("g", { transform: `translate(${x}, ${R}) scale(${z})`, fill: i, children: /* @__PURE__ */ s("path", { d: "M10 0 L2 11 H8 L5 20 L14 8 H8 L10 0 Z" }) }) : null
197
- ] })
151
+ /* @__PURE__ */ s("defs", { children: /* @__PURE__ */ s("mask", { id: `nc-battery-fill-mask-${o}`, children: /* @__PURE__ */ s("rect", { x: "0", y: "0", width: p * N, height: b, fill: "white" }) }) }),
152
+ /* @__PURE__ */ s(
153
+ "rect",
154
+ {
155
+ x: y,
156
+ y: g,
157
+ rx: h,
158
+ ry: h,
159
+ width: w,
160
+ height: k,
161
+ fill: c
162
+ }
163
+ ),
164
+ /* @__PURE__ */ s(
165
+ "rect",
166
+ {
167
+ x: y + m,
168
+ y: g + m,
169
+ width: p,
170
+ height: b,
171
+ fill: a,
172
+ rx: h,
173
+ ry: h,
174
+ mask: `url(#nc-battery-fill-mask-${o})`
175
+ }
176
+ ),
177
+ /* @__PURE__ */ s(
178
+ "text",
179
+ {
180
+ x: y + w / 2,
181
+ y: u - 3,
182
+ fontSize: 11,
183
+ fontWeight: "bold",
184
+ fill: "var(--nc-battery-text-contrast)",
185
+ textAnchor: "middle",
186
+ children: i
187
+ }
188
+ ),
189
+ /* @__PURE__ */ s(
190
+ "rect",
191
+ {
192
+ x: l + v,
193
+ y: u * 0.26,
194
+ width: f,
195
+ height: u * 0.48,
196
+ rx: 0.8,
197
+ ry: 0.8,
198
+ fill: o === 1 ? a : c
199
+ }
200
+ ),
201
+ t === "charging" ? /* @__PURE__ */ s("g", { transform: `translate(${R}, ${S}) scale(${T})`, fill: a, children: /* @__PURE__ */ s("path", { d: "M10 0 L2 11 H8 L5 20 L14 8 H8 L10 0 Z" }) }) : null
198
202
  ]
199
203
  }
200
204
  );
@@ -235,13 +239,13 @@ function wt({ size: e }) {
235
239
  }
236
240
  function Ln({ checked: e, onChange: t, disabled: n, label: r, size: o = "default", labelColor: i, style: a, className: c = "" }) {
237
241
  const l = o === "small";
238
- return /* @__PURE__ */ k(
242
+ return /* @__PURE__ */ A(
239
243
  "label",
240
244
  {
241
245
  className: `nc-checkbox-label ${l ? "nc-small" : ""} ${n ? "nc-disabled" : ""} ${c}`.trim(),
242
246
  style: a,
243
- onClick: (p) => {
244
- n || (p.preventDefault(), t(!e));
247
+ onClick: (u) => {
248
+ n || (u.preventDefault(), t(!e));
245
249
  },
246
250
  children: [
247
251
  /* @__PURE__ */ s(
@@ -251,8 +255,8 @@ function Ln({ checked: e, onChange: t, disabled: n, label: r, size: o = "default
251
255
  "aria-checked": e,
252
256
  tabIndex: 0,
253
257
  className: `nc-checkbox-box ${l ? "nc-small" : ""} ${e ? "nc-checked" : ""}`,
254
- onKeyDown: (p) => {
255
- n || (p.key === "Enter" || p.key === " ") && (p.preventDefault(), t(!e));
258
+ onKeyDown: (u) => {
259
+ n || (u.key === "Enter" || u.key === " ") && (u.preventDefault(), t(!e));
256
260
  },
257
261
  children: e && /* @__PURE__ */ s(wt, { size: o })
258
262
  }
@@ -266,7 +270,7 @@ function yt({ option: e, onChange: t, selected: n, highlighted: r, small: o }) {
266
270
  const i = W(null), { t: a } = U();
267
271
  return B(() => {
268
272
  r && i.current && i.current.scrollIntoView({ block: "nearest" });
269
- }, [r]), /* @__PURE__ */ k(
273
+ }, [r]), /* @__PURE__ */ A(
270
274
  "div",
271
275
  {
272
276
  ref: i,
@@ -280,7 +284,7 @@ function yt({ option: e, onChange: t, selected: n, highlighted: r, small: o }) {
280
284
  },
281
285
  children: [
282
286
  e.label,
283
- e.default && /* @__PURE__ */ k("span", { style: { fontSize: "0.85em", color: "var(--nc-text-weak)", marginLeft: 6 }, children: [
287
+ e.default && /* @__PURE__ */ A("span", { style: { fontSize: "0.85em", color: "var(--nc-text-weak)", marginLeft: 6 }, children: [
284
288
  "(",
285
289
  a("common.default"),
286
290
  ")"
@@ -299,23 +303,23 @@ function xt({
299
303
  small: a,
300
304
  highlightedIndex: c = -1
301
305
  }) {
302
- const [l, p] = E({ top: 0, left: 0, width: 0 }), [f, v] = E(o), { t: d } = U();
306
+ const [l, u] = E({ top: 0, left: 0, width: 0 }), [f, v] = E(o), { t: d } = U();
303
307
  if (B(() => {
304
308
  if (e && i.current) {
305
309
  const y = i.current.getBoundingClientRect();
306
310
  let g = o;
307
311
  if (o === "bottom") {
308
- const w = window.innerHeight - y.bottom, A = y.top;
309
- w < 320 && A > w && (g = "top");
312
+ const w = window.innerHeight - y.bottom, k = y.top;
313
+ w < 320 && k > w && (g = "top");
310
314
  }
311
- v(g), p({
315
+ v(g), u({
312
316
  top: g === "top" ? y.top - 4 : y.bottom + 4,
313
317
  left: y.left,
314
318
  width: y.width
315
319
  });
316
320
  }
317
321
  }, [e, i, o]), !e) return null;
318
- const h = /* @__PURE__ */ s(
322
+ const m = /* @__PURE__ */ s(
319
323
  "div",
320
324
  {
321
325
  className: "nc-combo-dropdown",
@@ -332,7 +336,7 @@ function xt({
332
336
  children: t.length === 0 ? /* @__PURE__ */ s("div", { className: `nc-combo-dropdown-option nc-no-results ${a ? "nc-small" : ""}`, children: d("common.noResults") }) : t.map((y, g) => /* @__PURE__ */ s(yt, { option: y, onChange: n, selected: y.value === r, highlighted: g === c, small: a }, y.value))
333
337
  }
334
338
  );
335
- return ue(h, document.body);
339
+ return ue(m, document.body);
336
340
  }
337
341
  function kt({ onClick: e, small: t }) {
338
342
  return /* @__PURE__ */ s(
@@ -368,18 +372,18 @@ function Bn({
368
372
  clearable: a = !0,
369
373
  allowTyping: c = !1,
370
374
  placement: l = "bottom",
371
- size: p = "default",
375
+ size: u = "default",
372
376
  appearance: f = "default",
373
377
  textAlign: v = "left",
374
378
  style: d,
375
- className: h
379
+ className: m
376
380
  }) {
377
- const [y, g] = E(!1), [w, A] = E(""), [b, u] = E(-1), m = W(null), N = W(null), S = p === "small", { t: z } = U(), T = me(() => {
381
+ const [y, g] = E(!1), [w, k] = E(""), [b, p] = E(-1), h = W(null), N = W(null), C = u === "small", { t: z } = U(), T = me(() => {
378
382
  const M = w.toLowerCase();
379
383
  return c ? r.filter((L) => L.label.toLowerCase().includes(M)) : r;
380
384
  }, [r, w, c]);
381
385
  B(() => {
382
- y && u(-1);
386
+ y && p(-1);
383
387
  }, [y, T]), B(() => {
384
388
  if (!a && !e && r.length > 0 && t) {
385
389
  const M = r.find((L) => L.default) || r[0];
@@ -388,15 +392,15 @@ function Bn({
388
392
  }, [a, e, r, t]), B(() => {
389
393
  function M(L) {
390
394
  var D;
391
- L.target instanceof Node && m.current && ((D = m.current.parentElement) != null && D.contains(L.target) || g(!1));
395
+ L.target instanceof Node && h.current && ((D = h.current.parentElement) != null && D.contains(L.target) || g(!1));
392
396
  }
393
397
  return document.addEventListener("mousedown", M), () => document.removeEventListener("mousedown", M);
394
398
  }, []);
395
- const x = r.find((M) => M.value === e), R = x && a, C = !o && !R, $ = `nc-align-${v}`, P = !(y && c) && !!x, F = (M, L = !1) => {
399
+ const x = r.find((M) => M.value === e), R = x && a, S = !o && !R, $ = `nc-align-${v}`, P = !(y && c) && !!x, F = (M, L = !1) => {
396
400
  var D;
397
- t == null || t(M), g(!1), A(""), L && ((D = m.current) == null || D.blur());
401
+ t == null || t(M), g(!1), k(""), L && ((D = h.current) == null || D.blur());
398
402
  }, Z = () => {
399
- t == null || t(void 0), A(""), g(!1);
403
+ t == null || t(void 0), k(""), g(!1);
400
404
  }, Y = (M) => {
401
405
  if (!y) {
402
406
  (M.key === "ArrowDown" || M.key === "ArrowUp") && (g(!0), M.preventDefault());
@@ -404,13 +408,13 @@ function Bn({
404
408
  }
405
409
  switch (M.key) {
406
410
  case "ArrowDown":
407
- M.preventDefault(), u((L) => {
411
+ M.preventDefault(), p((L) => {
408
412
  const D = L + 1;
409
413
  return D >= T.length ? 0 : D;
410
414
  });
411
415
  break;
412
416
  case "ArrowUp":
413
- M.preventDefault(), u((L) => {
417
+ M.preventDefault(), p((L) => {
414
418
  const D = L - 1;
415
419
  return D < 0 ? T.length - 1 : D;
416
420
  });
@@ -419,44 +423,44 @@ function Bn({
419
423
  M.preventDefault(), b >= 0 && b < T.length && F(T[b].value, !0);
420
424
  break;
421
425
  case "Escape":
422
- M.preventDefault(), g(!1), A("");
426
+ M.preventDefault(), g(!1), k("");
423
427
  break;
424
428
  }
425
429
  };
426
- return /* @__PURE__ */ k("div", { className: `nc-combo-container ${f === "transparent" ? "nc-transparent" : ""} ${$} ${h || ""}`.trim(), style: { position: "relative", ...d }, children: [
427
- i && /* @__PURE__ */ s("span", { className: `nc-label ${S ? "nc-small" : ""}`, children: i }),
428
- /* @__PURE__ */ k(
430
+ return /* @__PURE__ */ A("div", { className: `nc-combo-container ${f === "transparent" ? "nc-transparent" : ""} ${$} ${m || ""}`.trim(), style: { position: "relative", ...d }, children: [
431
+ i && /* @__PURE__ */ s("span", { className: `nc-label ${C ? "nc-small" : ""}`, children: i }),
432
+ /* @__PURE__ */ A(
429
433
  "div",
430
434
  {
431
435
  ref: N,
432
436
  style: { position: "relative", display: "flex", alignItems: "center" },
433
437
  onMouseDown: (M) => {
434
- o || c && M.target === m.current || (g((L) => (!L && c && x && A(x.label), !L)), c && !y && setTimeout(() => {
438
+ o || c && M.target === h.current || (g((L) => (!L && c && x && k(x.label), !L)), c && !y && setTimeout(() => {
435
439
  var L, D;
436
- (L = m.current) == null || L.focus(), (D = m.current) == null || D.select();
440
+ (L = h.current) == null || L.focus(), (D = h.current) == null || D.select();
437
441
  }, 0));
438
442
  },
439
443
  children: [
440
444
  /* @__PURE__ */ s(
441
445
  "input",
442
446
  {
443
- ref: m,
444
- className: `nc-input ${S ? "nc-small" : ""}`,
447
+ ref: h,
448
+ className: `nc-input ${C ? "nc-small" : ""}`,
445
449
  placeholder: n,
446
450
  onFocus: () => {
447
451
  var M;
448
- !o && c && (g(!0), x && (A(x.label), setTimeout(() => {
452
+ !o && c && (g(!0), x && (k(x.label), setTimeout(() => {
449
453
  var L;
450
- return (L = m.current) == null ? void 0 : L.select();
451
- }, 0))), c || (M = m.current) == null || M.blur();
454
+ return (L = h.current) == null ? void 0 : L.select();
455
+ }, 0))), c || (M = h.current) == null || M.blur();
452
456
  },
453
- onChange: (M) => c && A(M.target.value),
457
+ onChange: (M) => c && k(M.target.value),
454
458
  onKeyDown: Y,
455
459
  value: y && c ? w : (x == null ? void 0 : x.label) || "",
456
460
  readOnly: o || !c,
457
461
  style: {
458
462
  width: "100%",
459
- paddingRight: C || R ? S ? 32 : 44 : 12,
463
+ paddingRight: S || R ? C ? 32 : 44 : 12,
460
464
  caretColor: c ? void 0 : "transparent",
461
465
  cursor: c ? void 0 : "pointer",
462
466
  userSelect: c ? void 0 : "none",
@@ -464,22 +468,22 @@ function Bn({
464
468
  }
465
469
  }
466
470
  ),
467
- P && /* @__PURE__ */ k(
471
+ P && /* @__PURE__ */ A(
468
472
  "div",
469
473
  {
470
474
  "aria-hidden": !0,
471
475
  className: `nc-combo-overlay ${$}`,
472
476
  style: {
473
477
  position: "absolute",
474
- left: S ? 8 : 12,
475
- right: C || R ? S ? 12 : 24 : S ? 8 : 12,
478
+ left: C ? 8 : 12,
479
+ right: S || R ? C ? 12 : 24 : C ? 8 : 12,
476
480
  top: "50%",
477
481
  transform: "translateY(-50%)",
478
482
  pointerEvents: "none"
479
483
  },
480
484
  children: [
481
- /* @__PURE__ */ s("span", { className: `nc-combo-overlay-text ${S ? "nc-small" : ""}`, children: x == null ? void 0 : x.label }),
482
- (x == null ? void 0 : x.default) && /* @__PURE__ */ k("span", { className: `nc-combo-overlay-default ${S ? "nc-small" : ""}`, children: [
485
+ /* @__PURE__ */ s("span", { className: `nc-combo-overlay-text ${C ? "nc-small" : ""}`, children: x == null ? void 0 : x.label }),
486
+ (x == null ? void 0 : x.default) && /* @__PURE__ */ A("span", { className: `nc-combo-overlay-default ${C ? "nc-small" : ""}`, children: [
483
487
  "(",
484
488
  z("common.default"),
485
489
  ")"
@@ -487,12 +491,12 @@ function Bn({
487
491
  ]
488
492
  }
489
493
  ),
490
- R && /* @__PURE__ */ s(kt, { onClick: Z, small: S }),
491
- C && /* @__PURE__ */ s(Nt, { open: y, onClick: () => g((M) => !M), small: S })
494
+ R && /* @__PURE__ */ s(kt, { onClick: Z, small: C }),
495
+ S && /* @__PURE__ */ s(Nt, { open: y, onClick: () => g((M) => !M), small: C })
492
496
  ]
493
497
  }
494
498
  ),
495
- /* @__PURE__ */ s(xt, { isOpen: y, options: T, onSelect: F, selectedValue: e, placement: l, anchorRef: N, small: S, highlightedIndex: b })
499
+ /* @__PURE__ */ s(xt, { isOpen: y, options: T, onSelect: F, selectedValue: e, placement: l, anchorRef: N, small: C, highlightedIndex: b })
496
500
  ] });
497
501
  }
498
502
  function Dn({ onClick: e, loading: t = !1, disabled: n = !1, size: r = "default", title: o, "aria-label": i }) {
@@ -573,32 +577,32 @@ function Fn({
573
577
  anchor: o,
574
578
  preferredDirection: i = "down"
575
579
  }) {
576
- const a = W(null), [c, l] = E({ top: 0, left: 0 }), p = o || (r == null ? void 0 : r.current);
580
+ const a = W(null), [c, l] = E({ top: 0, left: 0 }), u = o || (r == null ? void 0 : r.current);
577
581
  if (B(() => {
578
- if (!e || !p || !a.current) return;
579
- const d = p.getBoundingClientRect(), h = a.current.getBoundingClientRect(), y = window.innerHeight, g = window.innerWidth, w = d.bottom + 8, A = w + h.height <= y - 8;
582
+ if (!e || !u || !a.current) return;
583
+ const d = u.getBoundingClientRect(), m = a.current.getBoundingClientRect(), y = window.innerHeight, g = window.innerWidth, w = d.bottom + 8, k = w + m.height <= y - 8;
580
584
  let b = i;
581
- (!A && i === "down" || i === "up" && A) && (b = "up");
582
- let u;
583
- b === "down" ? u = w : u = d.top - h.height - 8;
584
- let m = d.left;
585
- m + h.width > g - 8 && (m = d.right - h.width), l({
586
- top: Math.max(8, u),
585
+ (!k && i === "down" || i === "up" && k) && (b = "up");
586
+ let p;
587
+ b === "down" ? p = w : p = d.top - m.height - 8;
588
+ let h = d.left;
589
+ h + m.width > g - 8 && (h = d.right - m.width), l({
590
+ top: Math.max(8, p),
587
591
  // Ensure minimum 8px from top
588
- left: Math.max(8, m)
592
+ left: Math.max(8, h)
589
593
  // Ensure minimum 8px from left
590
594
  });
591
- }, [e, p, i]), B(() => {
595
+ }, [e, u, i]), B(() => {
592
596
  if (!e) return;
593
597
  const d = (y) => {
594
- a.current && !a.current.contains(y.target) && p && !p.contains(y.target) && t();
595
- }, h = (y) => {
598
+ a.current && !a.current.contains(y.target) && u && !u.contains(y.target) && t();
599
+ }, m = (y) => {
596
600
  y.key === "Escape" && t();
597
601
  };
598
- return document.addEventListener("mousedown", d), document.addEventListener("keydown", h), () => {
599
- document.removeEventListener("mousedown", d), document.removeEventListener("keydown", h);
602
+ return document.addEventListener("mousedown", d), document.addEventListener("keydown", m), () => {
603
+ document.removeEventListener("mousedown", d), document.removeEventListener("keydown", m);
600
604
  };
601
- }, [e, t, p]), !e) return null;
605
+ }, [e, t, u]), !e) return null;
602
606
  const f = (d) => {
603
607
  d.type !== "separator" && !d.disabled && d.onClick && (d.onClick(), t());
604
608
  }, v = n.some((d) => d.icon);
@@ -625,16 +629,16 @@ function Fn({
625
629
  },
626
630
  d.id
627
631
  );
628
- const h = [
632
+ const m = [
629
633
  "nc-context-menu-item",
630
634
  d.variant && d.variant !== "default" ? `nc-${d.variant}` : "",
631
635
  d.disabled ? "nc-disabled" : "",
632
636
  v && !d.icon ? "nc-indented" : ""
633
637
  ].filter(Boolean).join(" ");
634
- return /* @__PURE__ */ k(
638
+ return /* @__PURE__ */ A(
635
639
  "button",
636
640
  {
637
- className: h,
641
+ className: m,
638
642
  onClick: () => f(d),
639
643
  disabled: d.disabled,
640
644
  role: "menuitem",
@@ -674,61 +678,61 @@ function Vn({
674
678
  footer: a,
675
679
  onOk: c,
676
680
  onSave: l,
677
- onDelete: p,
681
+ onDelete: u,
678
682
  onCancel: f,
679
683
  onConnect: v,
680
684
  closeOnOverlay: d = !0,
681
- primaryDisabled: h = !1,
685
+ primaryDisabled: m = !1,
682
686
  fullScreen: y = !1,
683
687
  hideTitleBar: g = !1,
684
688
  className: w = "",
685
- onContentHeightChange: A
689
+ onContentHeightChange: k
686
690
  }) {
687
- const b = W(null), u = W(null), { t: m } = U(), N = { close: t }, S = (x) => {
691
+ const b = W(null), p = W(null), { t: h } = U(), N = { close: t }, C = (x) => {
688
692
  d && x.target === x.currentTarget && t();
689
693
  };
690
694
  if (B(() => {
691
695
  e && b.current && b.current.focus();
692
696
  }, [e]), B(() => {
693
- if (!A || !u.current) return;
697
+ if (!k || !p.current) return;
694
698
  const x = new ResizeObserver((R) => {
695
- for (const C of R) {
696
- const $ = C.contentRect.height;
697
- A($);
699
+ for (const S of R) {
700
+ const $ = S.contentRect.height;
701
+ k($);
698
702
  }
699
703
  });
700
- return x.observe(u.current), () => {
704
+ return x.observe(p.current), () => {
701
705
  x.disconnect();
702
706
  };
703
- }, [A]), !e) return null;
707
+ }, [k]), !e) return null;
704
708
  const z = () => {
705
709
  switch (i) {
706
710
  case "ok":
707
- return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(K, { variant: "primary", onClick: c ?? t, disabled: h, children: m("common.ok") }) });
711
+ return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(K, { variant: "primary", onClick: c ?? t, disabled: m, children: h("common.ok") }) });
708
712
  case "ok-cancel":
709
- return /* @__PURE__ */ k("div", { className: "nc-dialog-footer", children: [
710
- /* @__PURE__ */ s(ne, { onClick: f, children: m("common.cancel") }),
711
- /* @__PURE__ */ s(K, { variant: "primary", onClick: c ?? t, disabled: h, children: m("common.ok") })
713
+ return /* @__PURE__ */ A("div", { className: "nc-dialog-footer", children: [
714
+ /* @__PURE__ */ s(ne, { onClick: f, children: h("common.cancel") }),
715
+ /* @__PURE__ */ s(K, { variant: "primary", onClick: c ?? t, disabled: m, children: h("common.ok") })
712
716
  ] });
713
717
  case "save-cancel":
714
- return /* @__PURE__ */ k("div", { className: "nc-dialog-footer", children: [
715
- /* @__PURE__ */ s(ne, { onClick: f, children: m("common.cancel") }),
716
- /* @__PURE__ */ s(K, { variant: "primary", onClick: l, disabled: h, children: m("common.save") })
718
+ return /* @__PURE__ */ A("div", { className: "nc-dialog-footer", children: [
719
+ /* @__PURE__ */ s(ne, { onClick: f, children: h("common.cancel") }),
720
+ /* @__PURE__ */ s(K, { variant: "primary", onClick: l, disabled: m, children: h("common.save") })
717
721
  ] });
718
722
  case "delete-cancel":
719
- return /* @__PURE__ */ k("div", { className: "nc-dialog-footer", children: [
720
- /* @__PURE__ */ s(ne, { onClick: f, children: m("common.cancel") }),
721
- /* @__PURE__ */ s(K, { variant: "danger", onClick: p, disabled: h, children: m("common.delete") })
723
+ return /* @__PURE__ */ A("div", { className: "nc-dialog-footer", children: [
724
+ /* @__PURE__ */ s(ne, { onClick: f, children: h("common.cancel") }),
725
+ /* @__PURE__ */ s(K, { variant: "danger", onClick: u, disabled: m, children: h("common.delete") })
722
726
  ] });
723
727
  case "connect":
724
- return /* @__PURE__ */ k("div", { className: "nc-dialog-footer", children: [
725
- /* @__PURE__ */ s(ne, { onClick: f, children: m("common.cancel") }),
726
- /* @__PURE__ */ s(K, { variant: "primary", onClick: v, disabled: h, children: m("common.connect") })
728
+ return /* @__PURE__ */ A("div", { className: "nc-dialog-footer", children: [
729
+ /* @__PURE__ */ s(ne, { onClick: f, children: h("common.cancel") }),
730
+ /* @__PURE__ */ s(K, { variant: "primary", onClick: v, disabled: m, children: h("common.connect") })
727
731
  ] });
728
732
  case "close":
729
733
  return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(ne, { variant: "primary" }) });
730
734
  case "gotit":
731
- return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(ne, { variant: "primary", children: m("common.gotit") }) });
735
+ return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(ne, { variant: "primary", children: h("common.gotit") }) });
732
736
  case "custom":
733
737
  return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: a });
734
738
  case "none":
@@ -736,7 +740,7 @@ function Vn({
736
740
  default:
737
741
  return null;
738
742
  }
739
- }, T = /* @__PURE__ */ s(Oe.Provider, { value: N, children: /* @__PURE__ */ s("div", { className: `nc-dialog-overlay${y ? " nc-fullscreen" : ""}`, onClick: S, children: /* @__PURE__ */ k(
743
+ }, T = /* @__PURE__ */ s(Oe.Provider, { value: N, children: /* @__PURE__ */ s("div", { className: `nc-dialog-overlay${y ? " nc-fullscreen" : ""}`, onClick: C, children: /* @__PURE__ */ A(
740
744
  "div",
741
745
  {
742
746
  ref: b,
@@ -747,18 +751,18 @@ function Vn({
747
751
  "aria-modal": "true",
748
752
  "aria-labelledby": g ? void 0 : "nc-dialog-title",
749
753
  children: [
750
- !g && /* @__PURE__ */ k("div", { className: "nc-dialog-header", children: [
754
+ !g && /* @__PURE__ */ A("div", { className: "nc-dialog-header", children: [
751
755
  /* @__PURE__ */ s("h3", { id: "nc-dialog-title", className: "nc-dialog-title", children: n }),
752
756
  /* @__PURE__ */ s(We, { onClick: t, "aria-label": "Close dialog" })
753
757
  ] }),
754
- /* @__PURE__ */ s("div", { ref: u, className: "nc-dialog-content", children: r }),
758
+ /* @__PURE__ */ s("div", { ref: p, className: "nc-dialog-content", children: r }),
755
759
  z()
756
760
  ]
757
761
  }
758
762
  ) }) });
759
763
  return y ? ue(T, document.body) : T;
760
764
  }
761
- function Ct({ onClick: e, size: t = "default", rightOffset: n = 4 }) {
765
+ function St({ onClick: e, size: t = "default", rightOffset: n = 4 }) {
762
766
  const r = t === "small" ? 28 : 34;
763
767
  return /* @__PURE__ */ s(
764
768
  "button",
@@ -787,7 +791,7 @@ function Ct({ onClick: e, size: t = "default", rightOffset: n = 4 }) {
787
791
  }
788
792
  );
789
793
  }
790
- function St({ visible: e, onClick: t, size: n = "default" }) {
794
+ function Ct({ visible: e, onClick: t, size: n = "default" }) {
791
795
  const r = n === "small" ? 28 : 34, o = n === "small" ? 16 : 18;
792
796
  return /* @__PURE__ */ s(
793
797
  "button",
@@ -825,46 +829,46 @@ function Yn({
825
829
  disabled: a,
826
830
  label: c,
827
831
  clearable: l = !0,
828
- type: p = "text",
832
+ type: u = "text",
829
833
  className: f = "",
830
834
  size: v = "default",
831
835
  style: d,
832
- leadingIcon: h,
836
+ leadingIcon: m,
833
837
  showPasswordToggle: y = !1,
834
838
  multiline: g = !1,
835
839
  rows: w = 3,
836
- validator: A,
840
+ validator: k,
837
841
  showErrorMessage: b = !0
838
842
  }) {
839
- const u = W(null), m = W(null), [N, S] = E(!1), [z, T] = E(!1), x = e !== void 0, [R, C] = E(t), $ = x ? e : R, P = A ? A($) : null, F = !!P, Z = p === "password", Y = Z && y && !a && !g, M = l && $ && !a && z, L = v === "small" ? 32 : 44;
843
+ const p = W(null), h = W(null), [N, C] = E(!1), [z, T] = E(!1), x = e !== void 0, [R, S] = E(t), $ = x ? e : R, P = k ? k($) : null, F = !!P, Z = u === "password", Y = Z && y && !a && !g, M = l && $ && !a && z, L = v === "small" ? 32 : 44;
840
844
  let D = 12;
841
845
  M && Y ? D = L * 2 : (M || Y) && (D = L);
842
- const V = h ? v === "small" ? 28 : 34 : void 0, Ze = () => {
846
+ const V = m ? v === "small" ? 28 : 34 : void 0, Ze = () => {
843
847
  var te, ce;
844
- x || C(""), n == null || n(""), o == null || o(), g ? (te = m.current) == null || te.focus() : (ce = u.current) == null || ce.focus();
845
- }, Se = (te) => {
848
+ x || S(""), n == null || n(""), o == null || o(), g ? (te = h.current) == null || te.focus() : (ce = p.current) == null || ce.focus();
849
+ }, Ce = (te) => {
846
850
  te.key === "Enter" && !g && (r == null || r());
847
851
  }, $e = (te) => {
848
852
  const ce = te.target.value;
849
- x || C(ce), n == null || n(ce);
853
+ x || S(ce), n == null || n(ce);
850
854
  }, Ie = () => {
851
855
  T(!0);
852
856
  }, Me = () => {
853
857
  T(!1);
854
858
  }, Re = `nc-input ${v === "small" ? "nc-small " : ""} ${F ? "nc-error " : ""}${f}`;
855
- return /* @__PURE__ */ k("div", { className: "nc-col", style: { position: "relative", flex: 1, ...d }, children: [
859
+ return /* @__PURE__ */ A("div", { className: "nc-col", style: { position: "relative", flex: 1, ...d }, children: [
856
860
  c && /* @__PURE__ */ s("span", { className: "nc-label", children: c }),
857
- /* @__PURE__ */ k("div", { style: { position: "relative", display: "flex", alignItems: g ? "flex-start" : "center" }, children: [
858
- h && /* @__PURE__ */ s("span", { className: "nc-input-leading-icon", style: { height: g ? void 0 : "100%", top: g ? 10 : void 0 }, children: h }),
861
+ /* @__PURE__ */ A("div", { style: { position: "relative", display: "flex", alignItems: g ? "flex-start" : "center" }, children: [
862
+ m && /* @__PURE__ */ s("span", { className: "nc-input-leading-icon", style: { height: g ? void 0 : "100%", top: g ? 10 : void 0 }, children: m }),
859
863
  g ? /* @__PURE__ */ s(
860
864
  "textarea",
861
865
  {
862
- ref: m,
866
+ ref: h,
863
867
  className: Re,
864
868
  placeholder: i,
865
869
  value: $,
866
870
  onChange: $e,
867
- onKeyDown: Se,
871
+ onKeyDown: Ce,
868
872
  onFocus: Ie,
869
873
  onBlur: Me,
870
874
  readOnly: a,
@@ -880,13 +884,13 @@ function Yn({
880
884
  ) : /* @__PURE__ */ s(
881
885
  "input",
882
886
  {
883
- ref: u,
884
- type: Z && N ? "text" : p,
887
+ ref: p,
888
+ type: Z && N ? "text" : u,
885
889
  className: Re,
886
890
  placeholder: i,
887
891
  value: $,
888
892
  onChange: $e,
889
- onKeyDown: Se,
893
+ onKeyDown: Ce,
890
894
  onFocus: Ie,
891
895
  onBlur: Me,
892
896
  readOnly: a,
@@ -899,8 +903,8 @@ function Yn({
899
903
  }
900
904
  }
901
905
  ),
902
- M && /* @__PURE__ */ s(Ct, { onClick: Ze, size: v, rightOffset: Y ? L + 4 : 4 }),
903
- Y && /* @__PURE__ */ s(St, { visible: N, onClick: () => S(!N), size: v })
906
+ M && /* @__PURE__ */ s(St, { onClick: Ze, size: v, rightOffset: Y ? L + 4 : 4 }),
907
+ Y && /* @__PURE__ */ s(Ct, { visible: N, onClick: () => C(!N), size: v })
904
908
  ] }),
905
909
  F && b && /* @__PURE__ */ s("span", { className: "nc-error-message", children: P })
906
910
  ] });
@@ -919,8 +923,8 @@ function Gn({
919
923
  onClick: (l) => {
920
924
  if (t) {
921
925
  if (r) {
922
- const p = window.getSelection();
923
- if (p && p.toString().length > 0)
926
+ const u = window.getSelection();
927
+ if (u && u.toString().length > 0)
924
928
  return;
925
929
  }
926
930
  t(l);
@@ -941,8 +945,8 @@ function Gn({
941
945
  );
942
946
  }
943
947
  function jn({ title: e, titleTools: t, children: n, style: r }) {
944
- return /* @__PURE__ */ k("div", { className: "nc-list-group", style: r, children: [
945
- (e || t) && /* @__PURE__ */ k("div", { className: "nc-list-group-title", children: [
948
+ return /* @__PURE__ */ A("div", { className: "nc-list-group", style: r, children: [
949
+ (e || t) && /* @__PURE__ */ A("div", { className: "nc-list-group-title", children: [
946
950
  /* @__PURE__ */ s("div", { children: e }),
947
951
  t && /* @__PURE__ */ s("div", { className: "nc-list-group-title-tools", children: t })
948
952
  ] }),
@@ -956,31 +960,31 @@ function jn({ title: e, titleTools: t, children: n, style: r }) {
956
960
  ] });
957
961
  }
958
962
  function Kn({ values: e, onChange: t, options: n, placeholder: r = "Select…", label: o }) {
959
- const [i, a] = E(!1), [c, l] = E(""), p = W(null), f = me(() => n.filter((d) => d.label.toLowerCase().includes(c.toLowerCase())), [n, c]);
963
+ const [i, a] = E(!1), [c, l] = E(""), u = W(null), f = me(() => n.filter((d) => d.label.toLowerCase().includes(c.toLowerCase())), [n, c]);
960
964
  B(() => {
961
- function d(h) {
962
- !(h.target instanceof Node) || !p.current || p.current.contains(h.target) || a(!1);
965
+ function d(m) {
966
+ !(m.target instanceof Node) || !u.current || u.current.contains(m.target) || a(!1);
963
967
  }
964
968
  return document.addEventListener("mousedown", d), () => document.removeEventListener("mousedown", d);
965
969
  }, []);
966
970
  const v = (d) => {
967
- e.includes(d) ? t(e.filter((h) => h !== d)) : t([...e, d]);
971
+ e.includes(d) ? t(e.filter((m) => m !== d)) : t([...e, d]);
968
972
  };
969
- return /* @__PURE__ */ k("div", { ref: p, className: "nc-col", style: { position: "relative" }, children: [
973
+ return /* @__PURE__ */ A("div", { ref: u, className: "nc-col", style: { position: "relative" }, children: [
970
974
  o && /* @__PURE__ */ s("span", { className: "nc-label", children: o }),
971
- /* @__PURE__ */ k("div", { className: "nc-row", style: { flexWrap: "wrap", gap: 6, minHeight: 42, alignItems: "center", border: "1px solid var(--nc-button-border)", borderRadius: 8, background: "var(--nc-button-bg)", padding: "4px 8px" }, children: [
975
+ /* @__PURE__ */ A("div", { className: "nc-row", style: { flexWrap: "wrap", gap: 6, minHeight: 42, alignItems: "center", border: "1px solid var(--nc-button-border)", borderRadius: 8, background: "var(--nc-button-bg)", padding: "4px 8px" }, children: [
972
976
  e.length === 0 && /* @__PURE__ */ s("span", { className: "nc-label", children: r }),
973
977
  e.map((d) => {
974
- const h = n.find((y) => y.value === d);
975
- return h ? /* @__PURE__ */ k("span", { style: { padding: "4px 8px", borderRadius: 6, display: "inline-flex", alignItems: "center", gap: 4, background: "var(--nc-button-bg)", border: "1px solid var(--nc-button-border)" }, children: [
976
- h.label,
978
+ const m = n.find((y) => y.value === d);
979
+ return m ? /* @__PURE__ */ A("span", { style: { padding: "4px 8px", borderRadius: 6, display: "inline-flex", alignItems: "center", gap: 4, background: "var(--nc-button-bg)", border: "1px solid var(--nc-button-border)" }, children: [
980
+ m.label,
977
981
  /* @__PURE__ */ s(
978
982
  "button",
979
983
  {
980
984
  className: "nc-button nc-ghost",
981
985
  style: { padding: 0, minHeight: 0, height: 20, width: 20, display: "inline-flex", alignItems: "center", justifyContent: "center", border: "none" },
982
986
  onClick: () => v(d),
983
- "aria-label": `Remove ${h.label}`,
987
+ "aria-label": `Remove ${m.label}`,
984
988
  children: "✕"
985
989
  }
986
990
  )
@@ -997,12 +1001,12 @@ function Kn({ values: e, onChange: t, options: n, placeholder: r = "Select…",
997
1001
  }
998
1002
  )
999
1003
  ] }),
1000
- i && /* @__PURE__ */ k("div", { className: "nc-combo-dropdown", style: { position: "absolute", top: "100%", left: 0, right: 0, zIndex: 10, marginTop: 4, boxShadow: "0 4px 12px var(--nc-shadow)" }, children: [
1004
+ i && /* @__PURE__ */ A("div", { className: "nc-combo-dropdown", style: { position: "absolute", top: "100%", left: 0, right: 0, zIndex: 10, marginTop: 4, boxShadow: "0 4px 12px var(--nc-shadow)" }, children: [
1001
1005
  f.map((d) => {
1002
- const h = e.includes(d.value);
1003
- return /* @__PURE__ */ k("div", { className: "nc-section nc-row", style: { justifyContent: "space-between", cursor: "pointer", padding: 12 }, onMouseDown: () => v(d.value), children: [
1006
+ const m = e.includes(d.value);
1007
+ return /* @__PURE__ */ A("div", { className: "nc-section nc-row", style: { justifyContent: "space-between", cursor: "pointer", padding: 12 }, onMouseDown: () => v(d.value), children: [
1004
1008
  /* @__PURE__ */ s("span", { children: d.label }),
1005
- /* @__PURE__ */ s("span", { children: h ? "✔️" : "" })
1009
+ /* @__PURE__ */ s("span", { children: m ? "✔️" : "" })
1006
1010
  ] }, d.value);
1007
1011
  }),
1008
1012
  f.length === 0 && /* @__PURE__ */ s("div", { className: "nc-section nc-label", children: "No results" })
@@ -1049,41 +1053,41 @@ function _n({
1049
1053
  disabled: i = !1,
1050
1054
  size: a = "default"
1051
1055
  }) {
1052
- const [c, l] = E(!1), [p, f] = E(""), [v, d] = E(""), [h, y] = E({ top: 0, left: 0, width: 0, right: void 0 }), g = W(null), w = W(null);
1056
+ const [c, l] = E(!1), [u, f] = E(""), [v, d] = E(""), [m, y] = E({ top: 0, left: 0, width: 0, right: void 0 }), g = W(null), w = W(null);
1053
1057
  B(() => {
1054
1058
  if (c && g.current) {
1055
- const C = g.current.getBoundingClientRect(), P = Math.max(C.width, 400);
1056
- window.innerWidth - C.left < P && C.right >= P ? y({
1057
- top: C.bottom + 4,
1059
+ const S = g.current.getBoundingClientRect(), P = Math.max(S.width, 400);
1060
+ window.innerWidth - S.left < P && S.right >= P ? y({
1061
+ top: S.bottom + 4,
1058
1062
  left: 0,
1059
1063
  // Not used but type needs it, let's just use 0
1060
- right: window.innerWidth - C.right,
1064
+ right: window.innerWidth - S.right,
1061
1065
  width: P
1062
1066
  }) : y({
1063
- top: C.bottom + 4,
1064
- left: C.left,
1067
+ top: S.bottom + 4,
1068
+ left: S.left,
1065
1069
  right: void 0,
1066
1070
  width: P
1067
1071
  });
1068
1072
  }
1069
1073
  }, [c]), B(() => {
1070
1074
  if (!c) return;
1071
- const C = ($) => {
1075
+ const S = ($) => {
1072
1076
  g.current && !g.current.contains($.target) && w.current && !w.current.contains($.target) && l(!1);
1073
1077
  };
1074
- return document.addEventListener("mousedown", C), () => document.removeEventListener("mousedown", C);
1078
+ return document.addEventListener("mousedown", S), () => document.removeEventListener("mousedown", S);
1075
1079
  }, [c]);
1076
- const A = () => {
1080
+ const k = () => {
1077
1081
  f(e || Te()), d(t || Te()), l(!0);
1078
1082
  }, b = () => {
1079
1083
  l(!1);
1080
- }, u = () => {
1081
- const C = pe(p), $ = pe(v);
1082
- if (C || $)
1084
+ }, p = () => {
1085
+ const S = pe(u), $ = pe(v);
1086
+ if (S || $)
1083
1087
  return;
1084
- const P = de(p), F = de(v);
1088
+ const P = de(u), F = de(v);
1085
1089
  P && F && (n == null || n(P, F)), l(!1);
1086
- }, m = e && t ? `${Ee(e)} - ${Ee(t)}` : "Select month range", N = pe(p), S = pe(v), z = de(p), T = de(v), x = z && T && z > T, R = c ? ue(
1090
+ }, h = e && t ? `${Ee(e)} - ${Ee(t)}` : "Select month range", N = pe(u), C = pe(v), z = de(u), T = de(v), x = z && T && z > T, R = c ? ue(
1087
1091
  /* @__PURE__ */ s(
1088
1092
  "div",
1089
1093
  {
@@ -1091,50 +1095,50 @@ function _n({
1091
1095
  className: "nc-month-range-picker-popup",
1092
1096
  style: {
1093
1097
  position: "fixed",
1094
- top: h.top,
1095
- ...h.right !== void 0 ? { right: h.right } : { left: h.left },
1096
- width: h.width,
1098
+ top: m.top,
1099
+ ...m.right !== void 0 ? { right: m.right } : { left: m.left },
1100
+ width: m.width,
1097
1101
  zIndex: 1e3
1098
1102
  },
1099
- children: /* @__PURE__ */ k("div", { className: "nc-month-range-picker-content", children: [
1100
- /* @__PURE__ */ k("div", { className: "nc-month-range-picker-row", children: [
1101
- /* @__PURE__ */ k("div", { className: "nc-month-range-picker-column", children: [
1103
+ children: /* @__PURE__ */ A("div", { className: "nc-month-range-picker-content", children: [
1104
+ /* @__PURE__ */ A("div", { className: "nc-month-range-picker-row", children: [
1105
+ /* @__PURE__ */ A("div", { className: "nc-month-range-picker-column", children: [
1102
1106
  /* @__PURE__ */ s("label", { className: "nc-label", children: "Start Month" }),
1103
1107
  /* @__PURE__ */ s(
1104
1108
  "input",
1105
1109
  {
1106
1110
  type: "text",
1107
1111
  className: `nc-month-input ${N ? "nc-error" : ""}`,
1108
- value: p,
1109
- onChange: (C) => f(C.target.value),
1112
+ value: u,
1113
+ onChange: (S) => f(S.target.value),
1110
1114
  placeholder: "YY-M(M) or YYYY-M(M)"
1111
1115
  }
1112
1116
  ),
1113
1117
  N && /* @__PURE__ */ s("div", { className: "nc-month-error-text", children: N })
1114
1118
  ] }),
1115
- /* @__PURE__ */ k("div", { className: "nc-month-range-picker-column", children: [
1119
+ /* @__PURE__ */ A("div", { className: "nc-month-range-picker-column", children: [
1116
1120
  /* @__PURE__ */ s("label", { className: "nc-label", children: "End Month" }),
1117
1121
  /* @__PURE__ */ s(
1118
1122
  "input",
1119
1123
  {
1120
1124
  type: "text",
1121
- className: `nc-month-input ${S ? "nc-error" : ""}`,
1125
+ className: `nc-month-input ${C ? "nc-error" : ""}`,
1122
1126
  value: v,
1123
- onChange: (C) => d(C.target.value),
1127
+ onChange: (S) => d(S.target.value),
1124
1128
  placeholder: "YY-M(M) or YYYY-M(M)"
1125
1129
  }
1126
1130
  ),
1127
- S && /* @__PURE__ */ s("div", { className: "nc-month-error-text", children: S })
1131
+ C && /* @__PURE__ */ s("div", { className: "nc-month-error-text", children: C })
1128
1132
  ] })
1129
1133
  ] }),
1130
- x && !N && !S && /* @__PURE__ */ s("div", { className: "nc-month-range-error", children: "End month must be after or equal to start month" }),
1131
- /* @__PURE__ */ k("div", { className: "nc-month-range-picker-footer", children: [
1134
+ x && !N && !C && /* @__PURE__ */ s("div", { className: "nc-month-range-error", children: "End month must be after or equal to start month" }),
1135
+ /* @__PURE__ */ A("div", { className: "nc-month-range-picker-footer", children: [
1132
1136
  /* @__PURE__ */ s(
1133
1137
  K,
1134
1138
  {
1135
1139
  variant: "primary",
1136
- onClick: u,
1137
- disabled: !p || !v || !!N || !!S || !!x,
1140
+ onClick: p,
1141
+ disabled: !u || !v || !!N || !!C || !!x,
1138
1142
  children: "Apply"
1139
1143
  }
1140
1144
  ),
@@ -1145,32 +1149,32 @@ function _n({
1145
1149
  ),
1146
1150
  document.body
1147
1151
  ) : null;
1148
- return /* @__PURE__ */ k("div", { className: `nc-month-range-picker ${a === "small" ? "nc-small " : ""}${o}`, children: [
1152
+ return /* @__PURE__ */ A("div", { className: `nc-month-range-picker ${a === "small" ? "nc-small " : ""}${o}`, children: [
1149
1153
  r && /* @__PURE__ */ s("label", { className: `nc-label${a === "small" ? " nc-small" : ""}`, children: r }),
1150
1154
  /* @__PURE__ */ s(
1151
1155
  "button",
1152
1156
  {
1153
1157
  ref: g,
1154
1158
  className: `nc-month-range-picker-input${a === "small" ? " nc-small" : ""}`,
1155
- onClick: A,
1159
+ onClick: k,
1156
1160
  disabled: i,
1157
- children: m
1161
+ children: h
1158
1162
  }
1159
1163
  ),
1160
1164
  R
1161
1165
  ] });
1162
1166
  }
1163
1167
  function Un({ value: e, onChange: t, min: n, max: r, step: o = 1, label: i, disabled: a, size: c = "default" }) {
1164
- const l = c === "small", p = () => {
1168
+ const l = c === "small", u = () => {
1165
1169
  const d = e - o;
1166
1170
  n !== void 0 && d < n || t(parseFloat(d.toFixed(10)));
1167
1171
  }, f = () => {
1168
1172
  const d = e + o;
1169
1173
  r !== void 0 && d > r || t(parseFloat(d.toFixed(10)));
1170
1174
  };
1171
- return /* @__PURE__ */ k("div", { className: `nc-col nc-number-input-col ${l ? "nc-small" : ""}`, children: [
1175
+ return /* @__PURE__ */ A("div", { className: `nc-col nc-number-input-col ${l ? "nc-small" : ""}`, children: [
1172
1176
  i && /* @__PURE__ */ s("span", { className: `nc-label ${l ? "nc-small" : ""}`, children: i }),
1173
- /* @__PURE__ */ k("div", { className: `nc-number-input-container ${l ? "nc-small" : ""}`, children: [
1177
+ /* @__PURE__ */ A("div", { className: `nc-number-input-container ${l ? "nc-small" : ""}`, children: [
1174
1178
  /* @__PURE__ */ s(
1175
1179
  "input",
1176
1180
  {
@@ -1178,8 +1182,8 @@ function Un({ value: e, onChange: t, min: n, max: r, step: o = 1, label: i, disa
1178
1182
  type: "number",
1179
1183
  value: e,
1180
1184
  onChange: (d) => {
1181
- const h = parseFloat(d.target.value);
1182
- isNaN(h) || n !== void 0 && h < n || r !== void 0 && h > r || t(h);
1185
+ const m = parseFloat(d.target.value);
1186
+ isNaN(m) || n !== void 0 && m < n || r !== void 0 && m > r || t(m);
1183
1187
  },
1184
1188
  min: n,
1185
1189
  max: r,
@@ -1191,7 +1195,7 @@ function Un({ value: e, onChange: t, min: n, max: r, step: o = 1, label: i, disa
1191
1195
  "button",
1192
1196
  {
1193
1197
  className: `nc-button nc-ghost nc-number-input-button ${l ? "nc-small" : ""}`,
1194
- onClick: p,
1198
+ onClick: u,
1195
1199
  disabled: a || n !== void 0 && e <= n,
1196
1200
  children: "−"
1197
1201
  }
@@ -1218,15 +1222,15 @@ function qn({
1218
1222
  disabled: a,
1219
1223
  showValue: c = !0,
1220
1224
  formatValue: l = (f) => f.toString(),
1221
- width: p = 200
1225
+ width: u = 200
1222
1226
  }) {
1223
1227
  const f = (d) => {
1224
- const h = parseFloat(d.target.value);
1225
- t(h);
1228
+ const m = parseFloat(d.target.value);
1229
+ t(m);
1226
1230
  }, v = (e - n) / (r - n) * 100;
1227
- return /* @__PURE__ */ k("div", { className: "nc-col", style: { gap: 6 }, children: [
1231
+ return /* @__PURE__ */ A("div", { className: "nc-col", style: { gap: 6 }, children: [
1228
1232
  i && /* @__PURE__ */ s("span", { className: "nc-label", children: i }),
1229
- /* @__PURE__ */ k("div", { style: { display: "flex", gap: 12, alignItems: "center" }, children: [
1233
+ /* @__PURE__ */ A("div", { style: { display: "flex", gap: 12, alignItems: "center" }, children: [
1230
1234
  /* @__PURE__ */ s(
1231
1235
  "input",
1232
1236
  {
@@ -1239,7 +1243,7 @@ function qn({
1239
1243
  step: o,
1240
1244
  disabled: a,
1241
1245
  style: {
1242
- width: p,
1246
+ width: u,
1243
1247
  "--nc-slider-percentage": `${v}%`
1244
1248
  }
1245
1249
  }
@@ -1285,17 +1289,17 @@ function Xn({ active: e, children: t, keepMounted: n = !1, className: r = "", st
1285
1289
  const a = i.find((c) => c.props.tab === e);
1286
1290
  return /* @__PURE__ */ s("div", { className: `nc-tab-panels ${r}`, style: o, children: a });
1287
1291
  }
1288
- function Jn({ tabs: e, active: t, onChange: n, onClose: r, permanentTabs: o, className: i, toolbar: a, multiline: c, orientation: l = "horizontal", style: p }) {
1289
- const f = W(null), [v, d] = E(!1), [h, y] = E(!1), g = l === "verticalLeft" || l === "verticalRight", w = W(!1), A = W(0), b = W(0), u = W(!1);
1292
+ function Jn({ tabs: e, active: t, onChange: n, onClose: r, permanentTabs: o, className: i, toolbar: a, multiline: c, orientation: l = "horizontal", style: u }) {
1293
+ const f = W(null), [v, d] = E(!1), [m, y] = E(!1), g = l === "verticalLeft" || l === "verticalRight", w = W(!1), k = W(0), b = W(0), p = W(!1);
1290
1294
  B(() => {
1291
1295
  const x = () => {
1292
1296
  if (f.current)
1293
1297
  if (g) {
1294
- const { scrollTop: C, scrollHeight: $, clientHeight: P } = f.current;
1295
- d(C > 1), y(C < $ - P - 1);
1298
+ const { scrollTop: S, scrollHeight: $, clientHeight: P } = f.current;
1299
+ d(S > 1), y(S < $ - P - 1);
1296
1300
  } else {
1297
- const { scrollLeft: C, scrollWidth: $, clientWidth: P } = f.current;
1298
- d(C > 1), y(C < $ - P - 1);
1301
+ const { scrollLeft: S, scrollWidth: $, clientWidth: P } = f.current;
1302
+ d(S > 1), y(S < $ - P - 1);
1299
1303
  }
1300
1304
  }, R = f.current;
1301
1305
  if (R)
@@ -1303,46 +1307,46 @@ function Jn({ tabs: e, active: t, onChange: n, onClose: r, permanentTabs: o, cla
1303
1307
  R.removeEventListener("scroll", x), window.removeEventListener("resize", x);
1304
1308
  };
1305
1309
  }, [e, g]);
1306
- const m = (x) => {
1307
- f.current && (w.current = !0, u.current = !1, A.current = g ? x.clientY : x.clientX, b.current = g ? f.current.scrollTop : f.current.scrollLeft, f.current.style.cursor = "grabbing", f.current.style.userSelect = "none");
1310
+ const h = (x) => {
1311
+ f.current && (w.current = !0, p.current = !1, k.current = g ? x.clientY : x.clientX, b.current = g ? f.current.scrollTop : f.current.scrollLeft, f.current.style.cursor = "grabbing", f.current.style.userSelect = "none");
1308
1312
  }, N = (x) => {
1309
1313
  if (!w.current || !f.current) return;
1310
- const R = g ? x.clientY : x.clientX, C = A.current - R;
1311
- Math.abs(C) > 3 && (u.current = !0), g ? f.current.scrollTop = b.current + C : f.current.scrollLeft = b.current + C;
1312
- }, S = () => {
1314
+ const R = g ? x.clientY : x.clientX, S = k.current - R;
1315
+ Math.abs(S) > 3 && (p.current = !0), g ? f.current.scrollTop = b.current + S : f.current.scrollLeft = b.current + S;
1316
+ }, C = () => {
1313
1317
  f.current && (w.current = !1, f.current.style.cursor = "", f.current.style.userSelect = "");
1314
1318
  }, z = () => {
1315
- S();
1319
+ C();
1316
1320
  };
1317
1321
  B(() => {
1318
1322
  const x = f.current;
1319
1323
  if (!x || g) return;
1320
- const R = (C) => {
1321
- C.deltaY !== 0 && (C.preventDefault(), x.scrollLeft += C.deltaY * 0.3);
1324
+ const R = (S) => {
1325
+ S.deltaY !== 0 && (S.preventDefault(), x.scrollLeft += S.deltaY * 0.3);
1322
1326
  };
1323
1327
  return x.addEventListener("wheel", R, { passive: !1 }), () => {
1324
1328
  x.removeEventListener("wheel", R);
1325
1329
  };
1326
1330
  }, [g]);
1327
1331
  const T = (x) => {
1328
- u.current || n(x);
1332
+ p.current || n(x);
1329
1333
  };
1330
- return /* @__PURE__ */ k("div", { className: `nc-tab-container ${g ? `nc-vertical nc-${l}` : ""} ${i || ""}`, style: p, children: [
1331
- /* @__PURE__ */ k("div", { className: "nc-tab-scroll-wrapper", children: [
1334
+ return /* @__PURE__ */ A("div", { className: `nc-tab-container ${g ? `nc-vertical nc-${l}` : ""} ${i || ""}`, style: u, children: [
1335
+ /* @__PURE__ */ A("div", { className: "nc-tab-scroll-wrapper", children: [
1332
1336
  v && /* @__PURE__ */ s("div", { className: `nc-tab-scroll-indicator ${g ? "nc-top" : "nc-left"}`, children: g ? /* @__PURE__ */ s($t, { size: 16 }) : /* @__PURE__ */ s(at, { size: 16 }) }),
1333
1337
  /* @__PURE__ */ s(
1334
1338
  "div",
1335
1339
  {
1336
1340
  ref: f,
1337
1341
  className: `nc-tab-scroll ${c ? "nc-multiline" : ""}`,
1338
- onMouseDown: m,
1342
+ onMouseDown: h,
1339
1343
  onMouseMove: N,
1340
- onMouseUp: S,
1344
+ onMouseUp: C,
1341
1345
  onMouseLeave: z,
1342
1346
  style: { cursor: "grab" },
1343
1347
  children: e.map((x) => {
1344
- const R = typeof x == "string" ? x : x.id, C = typeof x == "string" ? x : x.label, $ = r && !(o != null && o.includes(R));
1345
- return /* @__PURE__ */ k(
1348
+ const R = typeof x == "string" ? x : x.id, S = typeof x == "string" ? x : x.label, $ = r && !(o != null && o.includes(R));
1349
+ return /* @__PURE__ */ A(
1346
1350
  "div",
1347
1351
  {
1348
1352
  className: `nc-tab-item ${t === R ? "nc-active" : ""} ${$ ? "nc-closable" : ""}`,
@@ -1353,21 +1357,21 @@ function Jn({ tabs: e, active: t, onChange: n, onClose: r, permanentTabs: o, cla
1353
1357
  (P.key === "Enter" || P.key === " ") && n(R);
1354
1358
  },
1355
1359
  children: [
1356
- /* @__PURE__ */ s("span", { className: "nc-tab-label", children: g ? C : typeof C == "string" ? C.toUpperCase() : C }),
1360
+ /* @__PURE__ */ s("span", { className: "nc-tab-label", children: g ? S : typeof S == "string" ? S.toUpperCase() : S }),
1357
1361
  $ && /* @__PURE__ */ s(
1358
1362
  "span",
1359
1363
  {
1360
1364
  className: "nc-tab-close",
1361
1365
  role: "button",
1362
1366
  tabIndex: 0,
1363
- "aria-label": `Close ${typeof C == "string" ? C : R}`,
1367
+ "aria-label": `Close ${typeof S == "string" ? S : R}`,
1364
1368
  onClick: (P) => {
1365
1369
  P.stopPropagation(), r(R);
1366
1370
  },
1367
1371
  onKeyDown: (P) => {
1368
1372
  (P.key === "Enter" || P.key === " ") && (P.stopPropagation(), r(R));
1369
1373
  },
1370
- children: /* @__PURE__ */ k("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", children: [
1374
+ children: /* @__PURE__ */ A("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", children: [
1371
1375
  /* @__PURE__ */ s("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
1372
1376
  /* @__PURE__ */ s("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
1373
1377
  ] })
@@ -1380,13 +1384,13 @@ function Jn({ tabs: e, active: t, onChange: n, onClose: r, permanentTabs: o, cla
1380
1384
  })
1381
1385
  }
1382
1386
  ),
1383
- h && /* @__PURE__ */ s("div", { className: `nc-tab-scroll-indicator ${g ? "nc-bottom" : "nc-right"}`, children: g ? /* @__PURE__ */ s(lt, { size: 16 }) : /* @__PURE__ */ s(dt, { size: 16 }) })
1387
+ m && /* @__PURE__ */ s("div", { className: `nc-tab-scroll-indicator ${g ? "nc-bottom" : "nc-right"}`, children: g ? /* @__PURE__ */ s(lt, { size: 16 }) : /* @__PURE__ */ s(dt, { size: 16 }) })
1384
1388
  ] }),
1385
1389
  a && /* @__PURE__ */ s("div", { className: "nc-tab-toolbar", children: a })
1386
1390
  ] });
1387
1391
  }
1388
1392
  function Qn({ checked: e, onChange: t, disabled: n, label: r }) {
1389
- return /* @__PURE__ */ k(
1393
+ return /* @__PURE__ */ A(
1390
1394
  "label",
1391
1395
  {
1392
1396
  className: "nc-row",
@@ -1460,10 +1464,10 @@ function Rt(e, t, n, r) {
1460
1464
  let a = 0;
1461
1465
  for (let v = 0; v < i - 1; v++)
1462
1466
  a += o[v].length + 1;
1463
- const l = o[i - 1].split(" "), p = Math.max(1, Math.min(n, l.length));
1464
- for (let v = 0; v < p - 1; v++)
1467
+ const l = o[i - 1].split(" "), u = Math.max(1, Math.min(n, l.length));
1468
+ for (let v = 0; v < u - 1; v++)
1465
1469
  a += l[v].length + 1;
1466
- const f = Math.max(1, Math.min(r, l[p - 1].length + 1));
1470
+ const f = Math.max(1, Math.min(r, l[u - 1].length + 1));
1467
1471
  return a += f - 1, a;
1468
1472
  }
1469
1473
  function Et(e, t) {
@@ -1475,27 +1479,27 @@ function Et(e, t) {
1475
1479
  return o;
1476
1480
  }
1477
1481
  const Zn = ft(
1478
- function({ value: t, onChange: n, placeholder: r, className: o, style: i, showLineNumbers: a = !1, onCursorChange: c, highlightLine: l }, p) {
1482
+ function({ value: t, onChange: n, placeholder: r, className: o, style: i, showLineNumbers: a = !1, onCursorChange: c, highlightLine: l }, u) {
1479
1483
  const f = W(null), v = W(null), d = W(null);
1480
- ht(p, () => ({
1484
+ ht(u, () => ({
1481
1485
  goToLine(b) {
1482
- const u = f.current;
1483
- if (!u) return;
1484
- const m = Et(t, b);
1485
- u.focus(), u.setSelectionRange(m, m);
1486
- const N = parseFloat(getComputedStyle(u).lineHeight) || 18;
1487
- u.scrollTop = (Math.max(1, b) - 1) * N, y(), h();
1486
+ const p = f.current;
1487
+ if (!p) return;
1488
+ const h = Et(t, b);
1489
+ p.focus(), p.setSelectionRange(h, h);
1490
+ const N = parseFloat(getComputedStyle(p).lineHeight) || 18;
1491
+ p.scrollTop = (Math.max(1, b) - 1) * N, y(), m();
1488
1492
  },
1489
- goToPosition(b, u, m) {
1493
+ goToPosition(b, p, h) {
1490
1494
  const N = f.current;
1491
1495
  if (!N) return;
1492
- const S = Rt(t, b, u, m);
1493
- N.focus(), N.setSelectionRange(S, S);
1496
+ const C = Rt(t, b, p, h);
1497
+ N.focus(), N.setSelectionRange(C, C);
1494
1498
  const z = parseFloat(getComputedStyle(N).lineHeight) || 18;
1495
- N.scrollTop = (Math.max(1, b) - 1) * z, y(), h();
1499
+ N.scrollTop = (Math.max(1, b) - 1) * z, y(), m();
1496
1500
  }
1497
1501
  }), [t]);
1498
- const h = O(() => {
1502
+ const m = O(() => {
1499
1503
  if (!c || !f.current) return;
1500
1504
  const b = Mt(t, f.current.selectionStart);
1501
1505
  c(b);
@@ -1507,33 +1511,33 @@ const Zn = ft(
1507
1511
  if (l == null || l < 1) return;
1508
1512
  const b = f.current;
1509
1513
  if (!b) return;
1510
- const u = parseFloat(getComputedStyle(b).lineHeight) || 18, m = (l - 1) * u, N = m + u;
1511
- (m < b.scrollTop || N > b.scrollTop + b.clientHeight) && (b.scrollTop = m - b.clientHeight / 2 + u / 2), y();
1514
+ const p = parseFloat(getComputedStyle(b).lineHeight) || 18, h = (l - 1) * p, N = h + p;
1515
+ (h < b.scrollTop || N > b.scrollTop + b.clientHeight) && (b.scrollTop = h - b.clientHeight / 2 + p / 2), y();
1512
1516
  }, [l]);
1513
1517
  const g = me(() => t.split(`
1514
1518
  `).length, [t]), w = () => {
1515
1519
  const b = [];
1516
- for (let u = 1; u <= g; u++)
1520
+ for (let p = 1; p <= g; p++)
1517
1521
  b.push(
1518
- /* @__PURE__ */ s("div", { className: `nc-csv-line-number ${l === u ? "nc-csv-highlight" : ""}`, children: u }, u)
1522
+ /* @__PURE__ */ s("div", { className: `nc-csv-line-number ${l === p ? "nc-csv-highlight" : ""}`, children: p }, p)
1519
1523
  );
1520
1524
  return /* @__PURE__ */ s("div", { className: "nc-csv-gutter", ref: d, children: b });
1521
- }, A = (b) => b ? b.split(`
1522
- `).map((m, N) => {
1523
- const S = m.split(" ");
1524
- return /* @__PURE__ */ k("div", { className: `nc-csv-line ${l === N + 1 ? "nc-csv-highlight" : ""}`, children: [
1525
- S.map((z, T) => /* @__PURE__ */ k("span", { children: [
1525
+ }, k = (b) => b ? b.split(`
1526
+ `).map((h, N) => {
1527
+ const C = h.split(" ");
1528
+ return /* @__PURE__ */ A("div", { className: `nc-csv-line ${l === N + 1 ? "nc-csv-highlight" : ""}`, children: [
1529
+ C.map((z, T) => /* @__PURE__ */ A("span", { children: [
1526
1530
  T > 0 && /* @__PURE__ */ s("span", { className: "nc-csv-tab-char", children: " " }),
1527
1531
  /* @__PURE__ */ s("span", { style: { color: ze[T % ze.length] }, children: z })
1528
1532
  ] }, T)),
1529
- m === "" && `
1533
+ h === "" && `
1530
1534
  `
1531
1535
  ] }, N);
1532
1536
  }) : null;
1533
- return /* @__PURE__ */ k("div", { className: `nc-csv-textarea-container ${a ? "nc-csv-with-gutter" : ""} ${o ?? ""}`, style: i, children: [
1537
+ return /* @__PURE__ */ A("div", { className: `nc-csv-textarea-container ${a ? "nc-csv-with-gutter" : ""} ${o ?? ""}`, style: i, children: [
1534
1538
  a && w(),
1535
- /* @__PURE__ */ k("div", { className: "nc-csv-textarea-editor", children: [
1536
- /* @__PURE__ */ s("div", { className: "nc-csv-textarea-backdrop", ref: v, children: /* @__PURE__ */ s("pre", { className: "nc-csv-textarea-highlights", children: A(t) }) }),
1539
+ /* @__PURE__ */ A("div", { className: "nc-csv-textarea-editor", children: [
1540
+ /* @__PURE__ */ s("div", { className: "nc-csv-textarea-backdrop", ref: v, children: /* @__PURE__ */ s("pre", { className: "nc-csv-textarea-highlights", children: k(t) }) }),
1537
1541
  /* @__PURE__ */ s(
1538
1542
  "textarea",
1539
1543
  {
@@ -1541,12 +1545,12 @@ const Zn = ft(
1541
1545
  className: "nc-csv-textarea-input",
1542
1546
  value: t,
1543
1547
  onChange: (b) => {
1544
- n(b.target.value), requestAnimationFrame(h);
1548
+ n(b.target.value), requestAnimationFrame(m);
1545
1549
  },
1546
1550
  onScroll: y,
1547
- onSelect: h,
1548
- onKeyUp: h,
1549
- onClick: h,
1551
+ onSelect: m,
1552
+ onKeyUp: m,
1553
+ onClick: m,
1550
1554
  placeholder: r,
1551
1555
  spellCheck: !1,
1552
1556
  autoComplete: "off",
@@ -1618,8 +1622,8 @@ function Pt({ notification: e }) {
1618
1622
  "div",
1619
1623
  {
1620
1624
  className: `nc-notification nc-notification-${e.type || "info"}`,
1621
- children: /* @__PURE__ */ k("div", { className: "nc-notification-content", children: [
1622
- /* @__PURE__ */ k("div", { className: "nc-notification-body", style: { paddingRight: e.dismissible ? "8px" : "0" }, children: [
1625
+ children: /* @__PURE__ */ A("div", { className: "nc-notification-content", children: [
1626
+ /* @__PURE__ */ A("div", { className: "nc-notification-body", style: { paddingRight: e.dismissible ? "8px" : "0" }, children: [
1623
1627
  /* @__PURE__ */ s("div", { className: "nc-notification-title", children: n() }),
1624
1628
  /* @__PURE__ */ s("div", { className: "nc-notification-message", children: e.message })
1625
1629
  ] }),
@@ -1637,22 +1641,22 @@ function Pt({ notification: e }) {
1637
1641
  }
1638
1642
  function er() {
1639
1643
  const [e, t] = E([]), [n, r] = E(/* @__PURE__ */ new Map()), [o, i] = E(/* @__PURE__ */ new Set()), a = W(null), c = W([]);
1640
- return B(() => Tt((p) => {
1641
- const f = new Set(c.current.map((d) => d.id)), v = p.filter((d) => !f.has(d.id)).map((d) => d.id);
1642
- v.length > 0 ? (t(p), i(new Set(v)), requestAnimationFrame(() => {
1644
+ return B(() => Tt((u) => {
1645
+ const f = new Set(c.current.map((d) => d.id)), v = u.filter((d) => !f.has(d.id)).map((d) => d.id);
1646
+ v.length > 0 ? (t(u), i(new Set(v)), requestAnimationFrame(() => {
1643
1647
  requestAnimationFrame(() => {
1644
1648
  i(/* @__PURE__ */ new Set());
1645
1649
  });
1646
- })) : t(p), c.current = p;
1650
+ })) : t(u), c.current = u;
1647
1651
  }), []), B(() => {
1648
1652
  if (!a.current) return;
1649
1653
  const l = /* @__PURE__ */ new Map();
1650
- let p = 0;
1654
+ let u = 0;
1651
1655
  const f = a.current.children;
1652
1656
  e.forEach((v, d) => {
1653
- if (l.set(v.id, p), f[d]) {
1654
- const h = f[d].offsetHeight;
1655
- v.isRemoving || (p += h + 12);
1657
+ if (l.set(v.id, u), f[d]) {
1658
+ const m = f[d].offsetHeight;
1659
+ v.isRemoving || (u += m + 12);
1656
1660
  }
1657
1661
  }), r(l);
1658
1662
  }, [e]), /* @__PURE__ */ s(
@@ -1674,7 +1678,7 @@ function er() {
1674
1678
  position: "relative"
1675
1679
  },
1676
1680
  children: e.map((l) => {
1677
- const p = o.has(l.id), f = l.isRemoving, v = n.get(l.id) || 0;
1681
+ const u = o.has(l.id), f = l.isRemoving, v = n.get(l.id) || 0;
1678
1682
  return /* @__PURE__ */ s(
1679
1683
  "div",
1680
1684
  {
@@ -1682,7 +1686,7 @@ function er() {
1682
1686
  position: "absolute",
1683
1687
  top: 0,
1684
1688
  left: 0,
1685
- transform: p ? "translateY(-120px)" : `translateY(${v}px)`,
1689
+ transform: u ? "translateY(-120px)" : `translateY(${v}px)`,
1686
1690
  // Only animate transform when not leaving, animate opacity always
1687
1691
  transition: f ? "opacity 300ms ease-out" : "transform 300ms ease-out, opacity 300ms ease-out",
1688
1692
  opacity: f ? 0 : 1,
@@ -1941,7 +1945,7 @@ function Wt() {
1941
1945
  return e;
1942
1946
  }
1943
1947
  function Ot({ size: e = 16 }) {
1944
- return /* @__PURE__ */ k(
1948
+ return /* @__PURE__ */ A(
1945
1949
  "svg",
1946
1950
  {
1947
1951
  width: e,
@@ -1960,8 +1964,8 @@ function Ot({ size: e = 16 }) {
1960
1964
  );
1961
1965
  }
1962
1966
  function Ft({ title: e, onClose: t, onBack: n, toolbar: r, hideBackButton: o }) {
1963
- return /* @__PURE__ */ k("div", { className: "nc-app-title-bar", children: [
1964
- /* @__PURE__ */ k("div", { className: "nc-app-title-bar-left", children: [
1967
+ return /* @__PURE__ */ A("div", { className: "nc-app-title-bar", children: [
1968
+ /* @__PURE__ */ A("div", { className: "nc-app-title-bar-left", children: [
1965
1969
  n && !o && /* @__PURE__ */ s(
1966
1970
  "button",
1967
1971
  {
@@ -1974,7 +1978,7 @@ function Ft({ title: e, onClose: t, onBack: n, toolbar: r, hideBackButton: o })
1974
1978
  ),
1975
1979
  /* @__PURE__ */ s("span", { className: "nc-app-title-bar-title", children: e })
1976
1980
  ] }),
1977
- /* @__PURE__ */ k("div", { className: "nc-app-title-bar-right", children: [
1981
+ /* @__PURE__ */ A("div", { className: "nc-app-title-bar-right", children: [
1978
1982
  r && /* @__PURE__ */ s("div", { className: "nc-app-title-bar-toolbar", children: r }),
1979
1983
  /* @__PURE__ */ s(We, { onClick: t, "aria-label": "Close application" })
1980
1984
  ] })
@@ -1991,7 +1995,7 @@ class Vt extends ke.Component {
1991
1995
  console.error(`Error loading app ${this.props.appId}:`, t, n);
1992
1996
  }
1993
1997
  render() {
1994
- return this.state.hasError ? /* @__PURE__ */ k(
1998
+ return this.state.hasError ? /* @__PURE__ */ A(
1995
1999
  "div",
1996
2000
  {
1997
2001
  style: {
@@ -2014,7 +2018,7 @@ class Vt extends ke.Component {
2014
2018
  }
2015
2019
  }
2016
2020
  function Ye({ appId: e, isActive: t, onClose: n }) {
2017
- const { t: r } = U(), o = oe.get(e), [i, a] = E(""), [c, l] = E(null), [p, f] = E(null), [v, d] = E(!1), [h, y] = E(!1);
2021
+ const { t: r } = U(), o = oe.get(e), [i, a] = E(""), [c, l] = E(null), [u, f] = E(null), [v, d] = E(!1), [m, y] = E(!1);
2018
2022
  ke.useEffect(() => {
2019
2023
  o != null && o.titleKey && a(r(o.titleKey));
2020
2024
  }, [o, r]);
@@ -2022,30 +2026,30 @@ function Ye({ appId: e, isActive: t, onClose: n }) {
2022
2026
  a(x);
2023
2027
  }, []), w = O((x) => {
2024
2028
  l(() => x);
2025
- }, []), A = O(() => {
2029
+ }, []), k = O(() => {
2026
2030
  l(null);
2027
2031
  }, []), b = O((x) => {
2028
2032
  f(x);
2029
- }, []), u = O(() => {
2033
+ }, []), p = O(() => {
2030
2034
  f(null);
2031
- }, []), m = O((x) => {
2035
+ }, []), h = O((x) => {
2032
2036
  d(x);
2033
2037
  }, []), N = O((x) => {
2034
2038
  y(x);
2035
- }, []), S = me(() => ({
2039
+ }, []), C = me(() => ({
2036
2040
  setTitle: g,
2037
2041
  setBackHandler: w,
2038
- clearBackHandler: A,
2042
+ clearBackHandler: k,
2039
2043
  setToolbar: b,
2040
- clearToolbar: u,
2041
- setHideBackButton: m,
2044
+ clearToolbar: p,
2045
+ setHideBackButton: h,
2042
2046
  setHideTitleBar: N,
2043
2047
  close: n
2044
- }), [g, w, A, b, u, m, N, n]);
2048
+ }), [g, w, k, b, p, h, N, n]);
2045
2049
  if (!o)
2046
2050
  return null;
2047
- const z = o.component, T = !o.hideTitleBar && !h;
2048
- return /* @__PURE__ */ k(
2051
+ const z = o.component, T = !o.hideTitleBar && !m;
2052
+ return /* @__PURE__ */ A(
2049
2053
  "div",
2050
2054
  {
2051
2055
  style: {
@@ -2061,7 +2065,7 @@ function Ye({ appId: e, isActive: t, onClose: n }) {
2061
2065
  title: i,
2062
2066
  onClose: n,
2063
2067
  onBack: c ?? void 0,
2064
- toolbar: p,
2068
+ toolbar: u,
2065
2069
  hideBackButton: v
2066
2070
  }
2067
2071
  ),
@@ -2078,7 +2082,7 @@ function Ye({ appId: e, isActive: t, onClose: n }) {
2078
2082
  backgroundColor: "var(--nc-bg-tertiary)",
2079
2083
  position: "relative"
2080
2084
  },
2081
- children: /* @__PURE__ */ s(Ve.Provider, { value: S, children: /* @__PURE__ */ s(Vt, { appId: e, children: /* @__PURE__ */ s(
2085
+ children: /* @__PURE__ */ s(Ve.Provider, { value: C, children: /* @__PURE__ */ s(Vt, { appId: e, children: /* @__PURE__ */ s(
2082
2086
  mt,
2083
2087
  {
2084
2088
  fallback: /* @__PURE__ */ s(
@@ -2246,25 +2250,25 @@ const Ne = "-", Yt = (e) => {
2246
2250
  experimentalParseClassName: n
2247
2251
  } = e, r = t.length === 1, o = t[0], i = t.length, a = (c) => {
2248
2252
  const l = [];
2249
- let p = 0, f = 0, v;
2253
+ let u = 0, f = 0, v;
2250
2254
  for (let w = 0; w < c.length; w++) {
2251
- let A = c[w];
2252
- if (p === 0) {
2253
- if (A === o && (r || c.slice(w, w + i) === t)) {
2255
+ let k = c[w];
2256
+ if (u === 0) {
2257
+ if (k === o && (r || c.slice(w, w + i) === t)) {
2254
2258
  l.push(c.slice(f, w)), f = w + i;
2255
2259
  continue;
2256
2260
  }
2257
- if (A === "/") {
2261
+ if (k === "/") {
2258
2262
  v = w;
2259
2263
  continue;
2260
2264
  }
2261
2265
  }
2262
- A === "[" ? p++ : A === "]" && p--;
2266
+ k === "[" ? u++ : k === "]" && u--;
2263
2267
  }
2264
- const d = l.length === 0 ? c : c.substring(f), h = d.startsWith(Ue), y = h ? d.substring(1) : d, g = v && v > f ? v - f : void 0;
2268
+ const d = l.length === 0 ? c : c.substring(f), m = d.startsWith(Ue), y = m ? d.substring(1) : d, g = v && v > f ? v - f : void 0;
2265
2269
  return {
2266
2270
  modifiers: l,
2267
- hasImportantModifier: h,
2271
+ hasImportantModifier: m,
2268
2272
  baseClassName: y,
2269
2273
  maybePostfixModifierPosition: g
2270
2274
  };
@@ -2293,34 +2297,34 @@ const Ne = "-", Yt = (e) => {
2293
2297
  } = t, i = [], a = e.trim().split(Qt);
2294
2298
  let c = "";
2295
2299
  for (let l = a.length - 1; l >= 0; l -= 1) {
2296
- const p = a[l], {
2300
+ const u = a[l], {
2297
2301
  modifiers: f,
2298
2302
  hasImportantModifier: v,
2299
2303
  baseClassName: d,
2300
- maybePostfixModifierPosition: h
2301
- } = n(p);
2302
- let y = !!h, g = r(y ? d.substring(0, h) : d);
2304
+ maybePostfixModifierPosition: m
2305
+ } = n(u);
2306
+ let y = !!m, g = r(y ? d.substring(0, m) : d);
2303
2307
  if (!g) {
2304
2308
  if (!y) {
2305
- c = p + (c.length > 0 ? " " + c : c);
2309
+ c = u + (c.length > 0 ? " " + c : c);
2306
2310
  continue;
2307
2311
  }
2308
2312
  if (g = r(d), !g) {
2309
- c = p + (c.length > 0 ? " " + c : c);
2313
+ c = u + (c.length > 0 ? " " + c : c);
2310
2314
  continue;
2311
2315
  }
2312
2316
  y = !1;
2313
2317
  }
2314
- const w = Xt(f).join(":"), A = v ? w + Ue : w, b = A + g;
2318
+ const w = Xt(f).join(":"), k = v ? w + Ue : w, b = k + g;
2315
2319
  if (i.includes(b))
2316
2320
  continue;
2317
2321
  i.push(b);
2318
- const u = o(g, y);
2319
- for (let m = 0; m < u.length; ++m) {
2320
- const N = u[m];
2321
- i.push(A + N);
2322
+ const p = o(g, y);
2323
+ for (let h = 0; h < p.length; ++h) {
2324
+ const N = p[h];
2325
+ i.push(k + N);
2322
2326
  }
2323
- c = p + (c.length > 0 ? " " + c : c);
2327
+ c = u + (c.length > 0 ? " " + c : c);
2324
2328
  }
2325
2329
  return c;
2326
2330
  };
@@ -2341,13 +2345,13 @@ const qe = (e) => {
2341
2345
  function tn(e, ...t) {
2342
2346
  let n, r, o, i = a;
2343
2347
  function a(l) {
2344
- const p = t.reduce((f, v) => v(f), e());
2345
- return n = Jt(p), r = n.cache.get, o = n.cache.set, i = c, c(l);
2348
+ const u = t.reduce((f, v) => v(f), e());
2349
+ return n = Jt(u), r = n.cache.get, o = n.cache.set, i = c, c(l);
2346
2350
  }
2347
2351
  function c(l) {
2348
- const p = r(l);
2349
- if (p)
2350
- return p;
2352
+ const u = r(l);
2353
+ if (u)
2354
+ return u;
2351
2355
  const f = Zt(l, n);
2352
2356
  return o(l, f), f;
2353
2357
  }
@@ -2367,7 +2371,7 @@ const H = (e) => {
2367
2371
  // I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
2368
2372
  sn.test(e) && !cn.test(e)
2369
2373
  ), Je = () => !1, vn = (e) => an.test(e), wn = (e) => ln.test(e), yn = () => {
2370
- const e = H("colors"), t = H("spacing"), n = H("blur"), r = H("brightness"), o = H("borderColor"), i = H("borderRadius"), a = H("borderSpacing"), c = H("borderWidth"), l = H("contrast"), p = H("grayscale"), f = H("hueRotate"), v = H("invert"), d = H("gap"), h = H("gradientColorStops"), y = H("gradientColorStopPositions"), g = H("inset"), w = H("margin"), A = H("opacity"), b = H("padding"), u = H("saturate"), m = H("scale"), N = H("sepia"), S = H("skew"), z = H("space"), T = H("translate"), x = () => ["auto", "contain", "none"], R = () => ["auto", "hidden", "clip", "visible", "scroll"], C = () => ["auto", I, t], $ = () => [I, t], P = () => ["", j, X], F = () => ["auto", re, I], Z = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"], Y = () => ["solid", "dashed", "dotted", "double", "none"], M = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], L = () => ["start", "end", "center", "between", "around", "evenly", "stretch"], D = () => ["", "0", I], ge = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], V = () => [re, I];
2374
+ const e = H("colors"), t = H("spacing"), n = H("blur"), r = H("brightness"), o = H("borderColor"), i = H("borderRadius"), a = H("borderSpacing"), c = H("borderWidth"), l = H("contrast"), u = H("grayscale"), f = H("hueRotate"), v = H("invert"), d = H("gap"), m = H("gradientColorStops"), y = H("gradientColorStopPositions"), g = H("inset"), w = H("margin"), k = H("opacity"), b = H("padding"), p = H("saturate"), h = H("scale"), N = H("sepia"), C = H("skew"), z = H("space"), T = H("translate"), x = () => ["auto", "contain", "none"], R = () => ["auto", "hidden", "clip", "visible", "scroll"], S = () => ["auto", I, t], $ = () => [I, t], P = () => ["", j, X], F = () => ["auto", re, I], Z = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"], Y = () => ["solid", "dashed", "dotted", "double", "none"], M = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], L = () => ["start", "end", "center", "between", "around", "evenly", "stretch"], D = () => ["", "0", I], ge = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], V = () => [re, I];
2371
2375
  return {
2372
2376
  cacheSize: 500,
2373
2377
  separator: ":",
@@ -2387,8 +2391,8 @@ const H = (e) => {
2387
2391
  gap: $(),
2388
2392
  gradientColorStops: [e],
2389
2393
  gradientColorStopPositions: [dn, X],
2390
- inset: C(),
2391
- margin: C(),
2394
+ inset: S(),
2395
+ margin: S(),
2392
2396
  opacity: V(),
2393
2397
  padding: $(),
2394
2398
  saturate: V(),
@@ -2620,7 +2624,7 @@ const H = (e) => {
2620
2624
  * @see https://tailwindcss.com/docs/flex-basis
2621
2625
  */
2622
2626
  basis: [{
2623
- basis: C()
2627
+ basis: S()
2624
2628
  }],
2625
2629
  /**
2626
2630
  * Flex Direction
@@ -3149,7 +3153,7 @@ const H = (e) => {
3149
3153
  * @see https://tailwindcss.com/docs/placeholder-opacity
3150
3154
  */
3151
3155
  "placeholder-opacity": [{
3152
- "placeholder-opacity": [A]
3156
+ "placeholder-opacity": [k]
3153
3157
  }],
3154
3158
  /**
3155
3159
  * Text Alignment
@@ -3170,7 +3174,7 @@ const H = (e) => {
3170
3174
  * @see https://tailwindcss.com/docs/text-opacity
3171
3175
  */
3172
3176
  "text-opacity": [{
3173
- "text-opacity": [A]
3177
+ "text-opacity": [k]
3174
3178
  }],
3175
3179
  /**
3176
3180
  * Text Decoration
@@ -3285,7 +3289,7 @@ const H = (e) => {
3285
3289
  * @see https://tailwindcss.com/docs/background-opacity
3286
3290
  */
3287
3291
  "bg-opacity": [{
3288
- "bg-opacity": [A]
3292
+ "bg-opacity": [k]
3289
3293
  }],
3290
3294
  /**
3291
3295
  * Background Origin
@@ -3359,21 +3363,21 @@ const H = (e) => {
3359
3363
  * @see https://tailwindcss.com/docs/gradient-color-stops
3360
3364
  */
3361
3365
  "gradient-from": [{
3362
- from: [h]
3366
+ from: [m]
3363
3367
  }],
3364
3368
  /**
3365
3369
  * Gradient Color Stops Via
3366
3370
  * @see https://tailwindcss.com/docs/gradient-color-stops
3367
3371
  */
3368
3372
  "gradient-via": [{
3369
- via: [h]
3373
+ via: [m]
3370
3374
  }],
3371
3375
  /**
3372
3376
  * Gradient Color Stops To
3373
3377
  * @see https://tailwindcss.com/docs/gradient-color-stops
3374
3378
  */
3375
3379
  "gradient-to": [{
3376
- to: [h]
3380
+ to: [m]
3377
3381
  }],
3378
3382
  // Borders
3379
3383
  /**
@@ -3549,7 +3553,7 @@ const H = (e) => {
3549
3553
  * @see https://tailwindcss.com/docs/border-opacity
3550
3554
  */
3551
3555
  "border-opacity": [{
3552
- "border-opacity": [A]
3556
+ "border-opacity": [k]
3553
3557
  }],
3554
3558
  /**
3555
3559
  * Border Style
@@ -3587,7 +3591,7 @@ const H = (e) => {
3587
3591
  * @see https://tailwindcss.com/docs/divide-opacity
3588
3592
  */
3589
3593
  "divide-opacity": [{
3590
- "divide-opacity": [A]
3594
+ "divide-opacity": [k]
3591
3595
  }],
3592
3596
  /**
3593
3597
  * Divide Style
@@ -3718,7 +3722,7 @@ const H = (e) => {
3718
3722
  * @see https://tailwindcss.com/docs/ring-opacity
3719
3723
  */
3720
3724
  "ring-opacity": [{
3721
- "ring-opacity": [A]
3725
+ "ring-opacity": [k]
3722
3726
  }],
3723
3727
  /**
3724
3728
  * Ring Offset Width
@@ -3754,7 +3758,7 @@ const H = (e) => {
3754
3758
  * @see https://tailwindcss.com/docs/opacity
3755
3759
  */
3756
3760
  opacity: [{
3757
- opacity: [A]
3761
+ opacity: [k]
3758
3762
  }],
3759
3763
  /**
3760
3764
  * Mix Blend Mode
@@ -3812,7 +3816,7 @@ const H = (e) => {
3812
3816
  * @see https://tailwindcss.com/docs/grayscale
3813
3817
  */
3814
3818
  grayscale: [{
3815
- grayscale: [p]
3819
+ grayscale: [u]
3816
3820
  }],
3817
3821
  /**
3818
3822
  * Hue Rotate
@@ -3833,7 +3837,7 @@ const H = (e) => {
3833
3837
  * @see https://tailwindcss.com/docs/saturate
3834
3838
  */
3835
3839
  saturate: [{
3836
- saturate: [u]
3840
+ saturate: [p]
3837
3841
  }],
3838
3842
  /**
3839
3843
  * Sepia
@@ -3876,7 +3880,7 @@ const H = (e) => {
3876
3880
  * @see https://tailwindcss.com/docs/backdrop-grayscale
3877
3881
  */
3878
3882
  "backdrop-grayscale": [{
3879
- "backdrop-grayscale": [p]
3883
+ "backdrop-grayscale": [u]
3880
3884
  }],
3881
3885
  /**
3882
3886
  * Backdrop Hue Rotate
@@ -3897,14 +3901,14 @@ const H = (e) => {
3897
3901
  * @see https://tailwindcss.com/docs/backdrop-opacity
3898
3902
  */
3899
3903
  "backdrop-opacity": [{
3900
- "backdrop-opacity": [A]
3904
+ "backdrop-opacity": [k]
3901
3905
  }],
3902
3906
  /**
3903
3907
  * Backdrop Saturate
3904
3908
  * @see https://tailwindcss.com/docs/backdrop-saturate
3905
3909
  */
3906
3910
  "backdrop-saturate": [{
3907
- "backdrop-saturate": [u]
3911
+ "backdrop-saturate": [p]
3908
3912
  }],
3909
3913
  /**
3910
3914
  * Backdrop Sepia
@@ -4005,21 +4009,21 @@ const H = (e) => {
4005
4009
  * @see https://tailwindcss.com/docs/scale
4006
4010
  */
4007
4011
  scale: [{
4008
- scale: [m]
4012
+ scale: [h]
4009
4013
  }],
4010
4014
  /**
4011
4015
  * Scale X
4012
4016
  * @see https://tailwindcss.com/docs/scale
4013
4017
  */
4014
4018
  "scale-x": [{
4015
- "scale-x": [m]
4019
+ "scale-x": [h]
4016
4020
  }],
4017
4021
  /**
4018
4022
  * Scale Y
4019
4023
  * @see https://tailwindcss.com/docs/scale
4020
4024
  */
4021
4025
  "scale-y": [{
4022
- "scale-y": [m]
4026
+ "scale-y": [h]
4023
4027
  }],
4024
4028
  /**
4025
4029
  * Rotate
@@ -4047,14 +4051,14 @@ const H = (e) => {
4047
4051
  * @see https://tailwindcss.com/docs/skew
4048
4052
  */
4049
4053
  "skew-x": [{
4050
- "skew-x": [S]
4054
+ "skew-x": [C]
4051
4055
  }],
4052
4056
  /**
4053
4057
  * Skew Y
4054
4058
  * @see https://tailwindcss.com/docs/skew
4055
4059
  */
4056
4060
  "skew-y": [{
4057
- "skew-y": [S]
4061
+ "skew-y": [C]
4058
4062
  }],
4059
4063
  /**
4060
4064
  * Transform Origin
@@ -4402,8 +4406,8 @@ function kn(...e) {
4402
4406
  function or({ autoWidth: e = !0, className: t, style: n }) {
4403
4407
  const [r, o] = E(() => _.getActiveAppId()), [i, a] = E(() => G.getRunningApps()), { isMobile: c } = Ke();
4404
4408
  B(() => {
4405
- const w = _.subscribe("activeAppId", (A) => {
4406
- o(A);
4409
+ const w = _.subscribe("activeAppId", (k) => {
4410
+ o(k);
4407
4411
  });
4408
4412
  return () => {
4409
4413
  w();
@@ -4418,7 +4422,7 @@ function or({ autoWidth: e = !0, className: t, style: n }) {
4418
4422
  }, []);
4419
4423
  const l = (w) => {
4420
4424
  G.closeApp(w);
4421
- }, p = r ? oe.get(r) : null, v = (p == null ? void 0 : p.width) ?? 400, d = r !== null, g = { ...{
4425
+ }, u = r ? oe.get(r) : null, v = (u == null ? void 0 : u.width) ?? 400, d = r !== null, g = { ...{
4422
4426
  overflow: "hidden",
4423
4427
  display: d ? "flex" : "none",
4424
4428
  flexDirection: "column",
@@ -4443,21 +4447,21 @@ function sr({
4443
4447
  side: r = "left",
4444
4448
  getBadge: o
4445
4449
  }) {
4446
- const { t: i } = U(), { isMobile: a } = Ke(), [c, l] = E(() => _.getActiveAppId()), [p, f] = E(() => G.getRunningApps());
4450
+ const { t: i } = U(), { isMobile: a } = Ke(), [c, l] = E(() => _.getActiveAppId()), [u, f] = E(() => G.getRunningApps());
4447
4451
  B(() => {
4448
- const u = _.subscribe("activeAppId", (m) => {
4449
- l(m);
4452
+ const p = _.subscribe("activeAppId", (h) => {
4453
+ l(h);
4450
4454
  });
4451
4455
  return () => {
4452
- u();
4456
+ p();
4453
4457
  };
4454
4458
  }, []), B(() => G.subscribe(() => {
4455
4459
  f(G.getRunningApps());
4456
4460
  }), []);
4457
- const v = (u) => {
4458
- c === u ? G.setActiveApp(null) : G.launchApp(u);
4459
- }, d = e.map((u) => oe.get(u)).filter((u) => !!u), h = p.filter((u) => !e.includes(u.appId)).map((u) => ({ running: u, def: oe.get(u.appId) })).filter((u) => !!u.def), y = (u) => p.some((m) => m.appId === u), g = (u) => u.titleKey ? String(i(u.titleKey)) : u.id, w = (u) => typeof u == "number" && u > 99 ? "99+" : u, A = (u, m) => {
4460
- const N = o == null ? void 0 : o(u, m);
4461
+ const v = (p) => {
4462
+ c === p ? G.setActiveApp(null) : G.launchApp(p);
4463
+ }, d = e.map((p) => oe.get(p)).filter((p) => !!p), m = u.filter((p) => !e.includes(p.appId)).map((p) => ({ running: p, def: oe.get(p.appId) })).filter((p) => !!p.def), y = (p) => u.some((h) => h.appId === p), g = (p) => p.titleKey ? String(i(p.titleKey)) : p.id, w = (p) => typeof p == "number" && p > 99 ? "99+" : p, k = (p, h) => {
4464
+ const N = o == null ? void 0 : o(p, h);
4461
4465
  return N ? /* @__PURE__ */ s(
4462
4466
  "span",
4463
4467
  {
@@ -4467,40 +4471,40 @@ function sr({
4467
4471
  }
4468
4472
  ) : null;
4469
4473
  }, b = a ? 24 : 28;
4470
- return /* @__PURE__ */ k("div", { className: `nc-app-taskbar ${a ? "nc-mobile" : "nc-desktop"} nc-${r} ${t}`, children: [
4471
- d.map((u) => {
4472
- const m = u.icon, N = c === u.id, S = y(u.id), z = { isActive: N, isRunning: S, isPinned: !0 };
4473
- return /* @__PURE__ */ k(
4474
+ return /* @__PURE__ */ A("div", { className: `nc-app-taskbar ${a ? "nc-mobile" : "nc-desktop"} nc-${r} ${t}`, children: [
4475
+ d.map((p) => {
4476
+ const h = p.icon, N = c === p.id, C = y(p.id), z = { isActive: N, isRunning: C, isPinned: !0 };
4477
+ return /* @__PURE__ */ A(
4474
4478
  "button",
4475
4479
  {
4476
- className: `nc-app-taskbar-button ${N ? "nc-active" : ""} ${S ? "nc-running" : ""}`,
4477
- onClick: () => v(u.id),
4478
- title: g(u),
4480
+ className: `nc-app-taskbar-button ${N ? "nc-active" : ""} ${C ? "nc-running" : ""}`,
4481
+ onClick: () => v(p.id),
4482
+ title: g(p),
4479
4483
  children: [
4480
- /* @__PURE__ */ s(m, { size: b }),
4481
- A(u, z),
4482
- n && S && /* @__PURE__ */ s("span", { className: "nc-app-taskbar-indicator" })
4484
+ /* @__PURE__ */ s(h, { size: b }),
4485
+ k(p, z),
4486
+ n && C && /* @__PURE__ */ s("span", { className: "nc-app-taskbar-indicator" })
4483
4487
  ]
4484
4488
  },
4485
- u.id
4489
+ p.id
4486
4490
  );
4487
4491
  }),
4488
- h.length > 0 && /* @__PURE__ */ s("div", { className: "nc-app-taskbar-separator" }),
4489
- h.map(({ running: u, def: m }) => {
4490
- const N = m.icon, S = c === u.appId, z = { isActive: S, isRunning: !0, isPinned: !1 };
4491
- return /* @__PURE__ */ k(
4492
+ m.length > 0 && /* @__PURE__ */ s("div", { className: "nc-app-taskbar-separator" }),
4493
+ m.map(({ running: p, def: h }) => {
4494
+ const N = h.icon, C = c === p.appId, z = { isActive: C, isRunning: !0, isPinned: !1 };
4495
+ return /* @__PURE__ */ A(
4492
4496
  "button",
4493
4497
  {
4494
- className: `nc-app-taskbar-button ${S ? "nc-active" : ""} nc-running`,
4495
- onClick: () => v(u.appId),
4496
- title: g(m),
4498
+ className: `nc-app-taskbar-button ${C ? "nc-active" : ""} nc-running`,
4499
+ onClick: () => v(p.appId),
4500
+ title: g(h),
4497
4501
  children: [
4498
4502
  /* @__PURE__ */ s(N, { size: b }),
4499
- A(m, z),
4503
+ k(h, z),
4500
4504
  n && /* @__PURE__ */ s("span", { className: "nc-app-taskbar-indicator" })
4501
4505
  ]
4502
4506
  },
4503
- u.appId
4507
+ p.appId
4504
4508
  );
4505
4509
  })
4506
4510
  ] });
@@ -4555,55 +4559,55 @@ function ar() {
4555
4559
  throw new Error("useNavView must be used within NavStack");
4556
4560
  return e;
4557
4561
  }
4558
- const Ce = se(null);
4562
+ const Se = se(null);
4559
4563
  function lr({ rootView: e, children: t }) {
4560
- const { t: n } = U(), r = Wt(), [o, i] = E([e]), [a, c] = E([null]), l = O((m, N) => {
4561
- c((S) => {
4562
- const z = [...S];
4563
- return z[m] = N, z;
4564
+ const { t: n } = U(), r = Wt(), [o, i] = E([e]), [a, c] = E([null]), l = O((h, N) => {
4565
+ c((C) => {
4566
+ const z = [...C];
4567
+ return z[h] = N, z;
4564
4568
  });
4565
- }, []), p = O((m) => {
4569
+ }, []), u = O((h) => {
4566
4570
  c((N) => {
4567
- const S = [...N];
4568
- return S[m] = null, S;
4571
+ const C = [...N];
4572
+ return C[h] = null, C;
4569
4573
  });
4570
- }, []), f = O((m) => {
4571
- i((N) => [...N, m]), c((N) => [...N, null]);
4574
+ }, []), f = O((h) => {
4575
+ i((N) => [...N, h]), c((N) => [...N, null]);
4572
4576
  }, []), v = O(() => {
4573
- i((m) => m.length <= 1 ? m : m.slice(0, -1)), c((m) => m.slice(0, -1));
4577
+ i((h) => h.length <= 1 ? h : h.slice(0, -1)), c((h) => h.slice(0, -1));
4574
4578
  }, []), d = O(() => {
4575
4579
  i([e]), c([null]);
4576
- }, [e]), h = o.length, y = h > 1, g = o.length - 1, w = o[o.length - 1], A = w != null && w.titleKey ? n(w.titleKey) : (w == null ? void 0 : w.title) ?? "";
4580
+ }, [e]), m = o.length, y = m > 1, g = o.length - 1, w = o[o.length - 1], k = w != null && w.titleKey ? n(w.titleKey) : (w == null ? void 0 : w.title) ?? "";
4577
4581
  B(() => {
4578
- r.setTitle(A);
4579
- }, [A, r]), B(() => {
4582
+ r.setTitle(k);
4583
+ }, [k, r]), B(() => {
4580
4584
  y ? r.setBackHandler(v) : r.clearBackHandler();
4581
4585
  }, [y, v, r]), B(() => {
4582
- const m = a[a.length - 1];
4583
- m ? r.setToolbar(m) : r.clearToolbar();
4586
+ const h = a[a.length - 1];
4587
+ h ? r.setToolbar(h) : r.clearToolbar();
4584
4588
  }, [a, r]);
4585
4589
  const b = {
4586
4590
  push: f,
4587
4591
  pop: v,
4588
4592
  reset: d,
4589
- depth: h,
4593
+ depth: m,
4590
4594
  canGoBack: y,
4591
- currentTitle: A
4592
- }, u = {
4595
+ currentTitle: k
4596
+ }, p = {
4593
4597
  stack: o,
4594
4598
  toolbarStack: a,
4595
4599
  updateToolbar: l,
4596
- clearToolbarAt: p,
4600
+ clearToolbarAt: u,
4597
4601
  topIndex: g
4598
4602
  };
4599
- return /* @__PURE__ */ s(Ae.Provider, { value: b, children: /* @__PURE__ */ s(Ce.Provider, { value: u, children: t }) });
4603
+ return /* @__PURE__ */ s(Ae.Provider, { value: b, children: /* @__PURE__ */ s(Se.Provider, { value: p, children: t }) });
4600
4604
  }
4601
4605
  function Nn({ index: e, children: t }) {
4602
- const n = Q(Ce);
4606
+ const n = Q(Se);
4603
4607
  if (!n)
4604
4608
  throw new Error("NavViewProvider must be used within NavStackProvider");
4605
- const { updateToolbar: r, clearToolbarAt: o, topIndex: i } = n, a = O((p) => {
4606
- e === i && r(e, p);
4609
+ const { updateToolbar: r, clearToolbarAt: o, topIndex: i } = n, a = O((u) => {
4610
+ e === i && r(e, u);
4607
4611
  }, [e, i, r]), c = O(() => {
4608
4612
  e === i && o(e);
4609
4613
  }, [e, i, o]), l = {
@@ -4613,7 +4617,7 @@ function Nn({ index: e, children: t }) {
4613
4617
  return /* @__PURE__ */ s(Qe.Provider, { value: l, children: t });
4614
4618
  }
4615
4619
  function dr() {
4616
- const e = Q(Ae), t = Q(Ce);
4620
+ const e = Q(Ae), t = Q(Se);
4617
4621
  if (!e || !t)
4618
4622
  throw new Error("NavStackContainer must be used within a NavStackProvider");
4619
4623
  const { stack: n } = t;