@kingsimba/nc-ui 0.1.28 → 0.1.30

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,15 +1,14 @@
1
- var et = Object.defineProperty;
2
- var tt = (e, t, n) => t in e ? et(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
- var q = (e, t, n) => tt(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { jsx as s, jsxs as A, Fragment as nt } from "react/jsx-runtime";
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
- 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
- import { createPortal as ue } from "react-dom";
8
- import { useTranslation as U } from "react-i18next";
9
- import { c as gt } from "./YamlTextArea-ee1d1TLc.js";
10
- import { Y as fr } from "./YamlTextArea-ee1d1TLc.js";
11
- import bt from "i18next";
12
- function He({
1
+ var lt = Object.defineProperty;
2
+ var dt = (e, t, n) => t in e ? lt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
+ var Z = (e, t, n) => dt(e, typeof t != "symbol" ? t + "" : t, n);
4
+ import { jsx as s, jsxs as k, Fragment as ut } from "react/jsx-runtime";
5
+ import { d as Ce, E as pt, R as ft, T as ht, g as mt, V as gt, b as bt, a as vt, c as wt } from "./GeneratedIcons-HFZmBTBT.js";
6
+ import $e, { useState as R, useRef as V, useMemo as we, useEffect as B, createContext as ce, useContext as te, Children as yt, isValidElement as xt, forwardRef as kt, useImperativeHandle as Nt, useCallback as O, Suspense as At } from "react";
7
+ import { createPortal as pe } from "react-dom";
8
+ import { useTranslation as X } from "react-i18next";
9
+ import St from "i18next";
10
+ import { c as Ct } from "./clsx-OuTLNxxd.js";
11
+ function Ke({
13
12
  size: e = "default",
14
13
  color: t,
15
14
  overlay: n = !1,
@@ -38,7 +37,7 @@ function He({
38
37
  );
39
38
  return n ? /* @__PURE__ */ s("div", { className: "nc-activity-indicator-overlay", children: o }) : o;
40
39
  }
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 }) {
40
+ function U({ variant: e = "default", block: t, size: n = "default", appearance: r = "default", className: o, disabled: i, textSelectable: c, loading: a, onClick: l, children: u, ...f }) {
42
41
  const v = [
43
42
  "nc-button",
44
43
  e !== "default" ? `nc-${e}` : "",
@@ -46,21 +45,21 @@ function K({ variant: e = "default", block: t, size: n = "default", appearance:
46
45
  n === "small" ? "nc-small" : "",
47
46
  n === "large" ? "nc-large" : "",
48
47
  r === "transparent" ? "nc-transparent" : "",
49
- i || c ? "nc-disabled" : "",
50
- a ? "nc-text-selectable" : "",
51
- c ? "nc-loading" : "",
48
+ i || a ? "nc-disabled" : "",
49
+ c ? "nc-text-selectable" : "",
50
+ a ? "nc-loading" : "",
52
51
  o ?? ""
53
52
  ].filter(Boolean).join(" ");
54
- return /* @__PURE__ */ A(
53
+ return /* @__PURE__ */ k(
55
54
  "button",
56
55
  {
57
56
  className: v,
58
- disabled: i || c,
57
+ disabled: i || a,
59
58
  onClick: (m) => {
60
- if (!c) {
61
- if (a) {
62
- const y = window.getSelection();
63
- if (y && y.toString().length > 0)
59
+ if (!a) {
60
+ if (c) {
61
+ const w = window.getSelection();
62
+ if (w && w.toString().length > 0)
64
63
  return;
65
64
  }
66
65
  l == null || l(m);
@@ -68,8 +67,8 @@ function K({ variant: e = "default", block: t, size: n = "default", appearance:
68
67
  },
69
68
  ...f,
70
69
  children: [
71
- c && /* @__PURE__ */ s(
72
- He,
70
+ a && /* @__PURE__ */ s(
71
+ Ke,
73
72
  {
74
73
  size: "small",
75
74
  className: "nc-button-spinner",
@@ -81,64 +80,64 @@ function K({ variant: e = "default", block: t, size: n = "default", appearance:
81
80
  }
82
81
  );
83
82
  }
84
- const vt = {
83
+ const $t = {
85
84
  info: "primary",
86
85
  success: "success",
87
86
  warning: "warning",
88
87
  error: "danger",
89
88
  danger: "danger"
90
89
  };
91
- function Tn({
90
+ function jn({
92
91
  code: e,
93
92
  text: t,
94
93
  type: n,
95
94
  button: r,
96
95
  onAction: o,
97
96
  children: i,
98
- onClose: a,
99
- className: c = "",
97
+ onClose: c,
98
+ className: a = "",
100
99
  style: l
101
100
  }) {
102
- const u = i ?? /* @__PURE__ */ A(nt, { children: [
101
+ const u = i ?? /* @__PURE__ */ k(ut, { children: [
103
102
  e !== void 0 && /* @__PURE__ */ s("span", { className: "nc-alert-code", children: e }),
104
103
  t
105
104
  ] });
106
- return /* @__PURE__ */ A("div", { className: `nc-alert nc-${n} ${c}`.trim(), style: l, children: [
107
- /* @__PURE__ */ A("div", { className: "nc-alert-main", children: [
105
+ return /* @__PURE__ */ k("div", { className: `nc-alert nc-${n} ${a}`.trim(), style: l, children: [
106
+ /* @__PURE__ */ k("div", { className: "nc-alert-main", children: [
108
107
  /* @__PURE__ */ s("div", { className: `nc-alert-message nc-${n}`, children: u }),
109
- a && /* @__PURE__ */ s(
108
+ c && /* @__PURE__ */ s(
110
109
  "button",
111
110
  {
112
111
  type: "button",
113
112
  className: "nc-alert-close",
114
113
  "aria-label": "Close alert",
115
- onClick: a,
116
- children: /* @__PURE__ */ s(xe, { size: 16 })
114
+ onClick: c,
115
+ children: /* @__PURE__ */ s(Ce, { size: 16 })
117
116
  }
118
117
  )
119
118
  ] }),
120
119
  r && /* @__PURE__ */ s("span", { className: "nc-alert-action", children: /* @__PURE__ */ s(
121
- K,
120
+ U,
122
121
  {
123
122
  size: "small",
124
- variant: r.variant ?? vt[n],
123
+ variant: r.variant ?? $t[n],
125
124
  onClick: o,
126
125
  children: r.text
127
126
  }
128
127
  ) })
129
128
  ] });
130
129
  }
131
- function zn({
130
+ function Gn({
132
131
  percentage: e = 0.5,
133
132
  status: t = "discharging",
134
133
  darkMode: n = !1,
135
134
  colored: r = !1
136
135
  }) {
137
136
  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(
137
+ let c;
138
+ r ? o < 0.1 ? c = "var(--nc-danger)" : o < 0.2 ? c = "var(--nc-warning)" : c = "var(--nc-success)" : c = n ? "#ffffff" : "#000000";
139
+ const a = "var(--nc-battery-shell-bg)", l = 24, u = 14, f = 2, v = 0, d = 12, m = 0, w = 0, y = 0, g = l, N = u, b = N - m * 2, p = g - m * 2, h = Math.max(1, Math.min(4, N / 4)), A = o === 0 ? 0 : 0.05 + o * 0.95, C = l + f + d, T = 20, L = 0.65, x = Math.max(u, T * L), I = l + f + 1, S = (u - T * L) / 2;
140
+ return /* @__PURE__ */ k(
142
141
  "svg",
143
142
  {
144
143
  className: "nc-battery",
@@ -148,27 +147,27 @@ function zn({
148
147
  role: "img",
149
148
  "aria-label": `Battery ${i === "-" ? "-" : `${i}%`} ${t}`,
150
149
  children: [
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" }) }) }),
150
+ /* @__PURE__ */ s("defs", { children: /* @__PURE__ */ s("mask", { id: `nc-battery-fill-mask-${o}`, children: /* @__PURE__ */ s("rect", { x: "0", y: "0", width: p * A, height: b, fill: "white" }) }) }),
152
151
  /* @__PURE__ */ s(
153
152
  "rect",
154
153
  {
155
- x: y,
156
- y: g,
154
+ x: w,
155
+ y,
157
156
  rx: h,
158
157
  ry: h,
159
- width: w,
160
- height: k,
161
- fill: c
158
+ width: g,
159
+ height: N,
160
+ fill: a
162
161
  }
163
162
  ),
164
163
  /* @__PURE__ */ s(
165
164
  "rect",
166
165
  {
167
- x: y + m,
168
- y: g + m,
166
+ x: w + m,
167
+ y: y + m,
169
168
  width: p,
170
169
  height: b,
171
- fill: a,
170
+ fill: c,
172
171
  rx: h,
173
172
  ry: h,
174
173
  mask: `url(#nc-battery-fill-mask-${o})`
@@ -177,7 +176,7 @@ function zn({
177
176
  /* @__PURE__ */ s(
178
177
  "text",
179
178
  {
180
- x: y + w / 2,
179
+ x: w + g / 2,
181
180
  y: u - 3,
182
181
  fontSize: 11,
183
182
  fontWeight: "bold",
@@ -195,15 +194,15 @@ function zn({
195
194
  height: u * 0.48,
196
195
  rx: 0.8,
197
196
  ry: 0.8,
198
- fill: o === 1 ? a : c
197
+ fill: o === 1 ? c : a
199
198
  }
200
199
  ),
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
200
+ t === "charging" ? /* @__PURE__ */ s("g", { transform: `translate(${I}, ${S}) scale(${L})`, fill: c, children: /* @__PURE__ */ s("path", { d: "M10 0 L2 11 H8 L5 20 L14 8 H8 L10 0 Z" }) }) : null
202
201
  ]
203
202
  }
204
203
  );
205
204
  }
206
- function Pn({
205
+ function Yn({
207
206
  value: e,
208
207
  onChange: t,
209
208
  options: n,
@@ -211,21 +210,21 @@ function Pn({
211
210
  size: o = "default"
212
211
  }) {
213
212
  return /* @__PURE__ */ s("div", { className: `nc-button-group ${o === "small" ? "nc-small" : ""}`, children: n.map((i) => {
214
- const a = r || !!i.disabled;
213
+ const c = r || !!i.disabled;
215
214
  return /* @__PURE__ */ s(
216
215
  "button",
217
216
  {
218
217
  type: "button",
219
218
  className: `nc-button-group-item ${e === i.key ? "nc-active" : ""}`,
220
- onClick: () => !a && t(i.key),
221
- disabled: a,
219
+ onClick: () => !c && t(i.key),
220
+ disabled: c,
222
221
  children: i.label
223
222
  },
224
223
  i.key
225
224
  );
226
225
  }) });
227
226
  }
228
- function wt({ size: e }) {
227
+ function Mt({ size: e }) {
229
228
  return /* @__PURE__ */ s("svg", { className: `nc-checkbox-icon ${e === "small" ? "nc-small" : ""}`, viewBox: "0 0 12 12", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ s(
230
229
  "path",
231
230
  {
@@ -237,13 +236,13 @@ function wt({ size: e }) {
237
236
  }
238
237
  ) });
239
238
  }
240
- function Ln({ checked: e, onChange: t, disabled: n, label: r, size: o = "default", labelColor: i, style: a, className: c = "" }) {
239
+ function Kn({ checked: e, onChange: t, disabled: n, label: r, size: o = "default", labelColor: i, style: c, className: a = "" }) {
241
240
  const l = o === "small";
242
- return /* @__PURE__ */ A(
241
+ return /* @__PURE__ */ k(
243
242
  "label",
244
243
  {
245
- className: `nc-checkbox-label ${l ? "nc-small" : ""} ${n ? "nc-disabled" : ""} ${c}`.trim(),
246
- style: a,
244
+ className: `nc-checkbox-label ${l ? "nc-small" : ""} ${n ? "nc-disabled" : ""} ${a}`.trim(),
245
+ style: c,
247
246
  onClick: (u) => {
248
247
  n || (u.preventDefault(), t(!e));
249
248
  },
@@ -258,7 +257,7 @@ function Ln({ checked: e, onChange: t, disabled: n, label: r, size: o = "default
258
257
  onKeyDown: (u) => {
259
258
  n || (u.key === "Enter" || u.key === " ") && (u.preventDefault(), t(!e));
260
259
  },
261
- children: e && /* @__PURE__ */ s(wt, { size: o })
260
+ children: e && /* @__PURE__ */ s(Mt, { size: o })
262
261
  }
263
262
  ),
264
263
  r && /* @__PURE__ */ s("span", { className: "nc-checkbox-text", style: i ? { color: i } : void 0, children: r })
@@ -266,11 +265,11 @@ function Ln({ checked: e, onChange: t, disabled: n, label: r, size: o = "default
266
265
  }
267
266
  );
268
267
  }
269
- function yt({ option: e, onChange: t, selected: n, highlighted: r, small: o }) {
270
- const i = W(null), { t: a } = U();
268
+ function It({ option: e, onChange: t, selected: n, highlighted: r, small: o }) {
269
+ const i = V(null), { t: c } = X();
271
270
  return B(() => {
272
271
  r && i.current && i.current.scrollIntoView({ block: "nearest" });
273
- }, [r]), /* @__PURE__ */ A(
272
+ }, [r]), /* @__PURE__ */ k(
274
273
  "div",
275
274
  {
276
275
  ref: i,
@@ -284,38 +283,38 @@ function yt({ option: e, onChange: t, selected: n, highlighted: r, small: o }) {
284
283
  },
285
284
  children: [
286
285
  e.label,
287
- e.default && /* @__PURE__ */ A("span", { style: { fontSize: "0.85em", color: "var(--nc-text-weak)", marginLeft: 6 }, children: [
286
+ e.default && /* @__PURE__ */ k("span", { style: { fontSize: "0.85em", color: "var(--nc-text-weak)", marginLeft: 6 }, children: [
288
287
  "(",
289
- a("common.default"),
288
+ c("common.default"),
290
289
  ")"
291
290
  ] })
292
291
  ]
293
292
  }
294
293
  );
295
294
  }
296
- function xt({
295
+ function Rt({
297
296
  isOpen: e,
298
297
  options: t,
299
298
  onSelect: n,
300
299
  selectedValue: r,
301
300
  placement: o = "bottom",
302
301
  anchorRef: i,
303
- small: a,
304
- highlightedIndex: c = -1
302
+ small: c,
303
+ highlightedIndex: a = -1
305
304
  }) {
306
- const [l, u] = E({ top: 0, left: 0, width: 0 }), [f, v] = E(o), { t: d } = U();
305
+ const [l, u] = R({ top: 0, left: 0, width: 0 }), [f, v] = R(o), { t: d } = X();
307
306
  if (B(() => {
308
307
  if (e && i.current) {
309
- const y = i.current.getBoundingClientRect();
310
- let g = o;
308
+ const w = i.current.getBoundingClientRect();
309
+ let y = o;
311
310
  if (o === "bottom") {
312
- const w = window.innerHeight - y.bottom, k = y.top;
313
- w < 320 && k > w && (g = "top");
311
+ const g = window.innerHeight - w.bottom, N = w.top;
312
+ g < 320 && N > g && (y = "top");
314
313
  }
315
- v(g), u({
316
- top: g === "top" ? y.top - 4 : y.bottom + 4,
317
- left: y.left,
318
- width: y.width
314
+ v(y), u({
315
+ top: y === "top" ? w.top - 4 : w.bottom + 4,
316
+ left: w.left,
317
+ width: w.width
319
318
  });
320
319
  }
321
320
  }, [e, i, o]), !e) return null;
@@ -333,44 +332,49 @@ function xt({
333
332
  maxHeight: 300,
334
333
  overflowY: "auto"
335
334
  },
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))
335
+ children: t.length === 0 ? /* @__PURE__ */ s("div", { className: `nc-combo-dropdown-option nc-no-results ${c ? "nc-small" : ""}`, children: d("common.noResults") }) : t.map((w, y) => /* @__PURE__ */ s(It, { option: w, onChange: n, selected: w.value === r, highlighted: y === a, small: c }, w.value))
337
336
  }
338
337
  );
339
- return ue(m, document.body);
338
+ return pe(m, document.body);
340
339
  }
341
- function kt({ onClick: e, small: t }) {
340
+ function Et({ onClick: e, small: t }) {
342
341
  return /* @__PURE__ */ s(
343
- "button",
342
+ "span",
344
343
  {
345
- className: `nc-button nc-ghost nc-combo-button nc-combo-clear ${t ? "nc-small" : ""}`,
346
- onClick: e,
344
+ role: "button",
345
+ tabIndex: 0,
346
+ className: `nc-combo-button nc-combo-clear ${t ? "nc-small" : ""}`,
347
+ onClick: (n) => {
348
+ n.stopPropagation(), e();
349
+ },
347
350
  onMouseDown: (n) => n.stopPropagation(),
351
+ onKeyDown: (n) => {
352
+ (n.key === "Enter" || n.key === " ") && (n.preventDefault(), n.stopPropagation(), e());
353
+ },
348
354
  "aria-label": "Clear selection",
349
355
  children: "✕"
350
356
  }
351
357
  );
352
358
  }
353
- function Nt({ open: e, onClick: t, small: n }) {
359
+ function Tt({ open: e, small: t }) {
354
360
  return /* @__PURE__ */ s(
355
- "button",
361
+ "span",
356
362
  {
357
- className: `nc-button nc-ghost nc-combo-button nc-combo-toggle ${n ? "nc-small" : ""} ${e ? "nc-open" : ""}`,
358
- onClick: t,
359
- onMouseDown: (r) => r.stopPropagation(),
360
- "aria-label": e ? "Close" : "Open",
363
+ "aria-hidden": !0,
364
+ className: `nc-combo-button nc-combo-toggle ${t ? "nc-small" : ""} ${e ? "nc-open" : ""}`,
361
365
  children: "▾"
362
366
  }
363
367
  );
364
368
  }
365
- function Bn({
369
+ function _n({
366
370
  value: e,
367
371
  onChange: t,
368
372
  placeholder: n = "Select…",
369
373
  options: r,
370
374
  disabled: o,
371
375
  label: i,
372
- clearable: a = !0,
373
- allowTyping: c = !1,
376
+ clearable: c = !0,
377
+ allowTyping: a = !1,
374
378
  placement: l = "bottom",
375
379
  size: u = "default",
376
380
  appearance: f = "default",
@@ -378,66 +382,66 @@ function Bn({
378
382
  style: d,
379
383
  className: m
380
384
  }) {
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(() => {
382
- const M = w.toLowerCase();
383
- return c ? r.filter((L) => L.label.toLowerCase().includes(M)) : r;
384
- }, [r, w, c]);
385
+ const [w, y] = R(!1), [g, N] = R(""), [b, p] = R(-1), h = V(null), A = V(null), C = u === "small", { t: T } = X(), L = we(() => {
386
+ const E = g.toLowerCase();
387
+ return a ? r.filter((D) => D.label.toLowerCase().includes(E)) : r;
388
+ }, [r, g, a]);
385
389
  B(() => {
386
- y && p(-1);
387
- }, [y, T]), B(() => {
388
- if (!a && !e && r.length > 0 && t) {
389
- const M = r.find((L) => L.default) || r[0];
390
- t(M.value);
390
+ w && p(-1);
391
+ }, [w, L]), B(() => {
392
+ if (!c && !e && r.length > 0 && t) {
393
+ const E = r.find((D) => D.default) || r[0];
394
+ t(E.value);
391
395
  }
392
- }, [a, e, r, t]), B(() => {
393
- function M(L) {
394
- var D;
395
- L.target instanceof Node && h.current && ((D = h.current.parentElement) != null && D.contains(L.target) || g(!1));
396
+ }, [c, e, r, t]), B(() => {
397
+ function E(D) {
398
+ var P;
399
+ D.target instanceof Node && h.current && ((P = h.current.parentElement) != null && P.contains(D.target) || y(!1));
396
400
  }
397
- return document.addEventListener("mousedown", M), () => document.removeEventListener("mousedown", M);
401
+ return document.addEventListener("mousedown", E), () => document.removeEventListener("mousedown", E);
398
402
  }, []);
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) => {
400
- var D;
401
- t == null || t(M), g(!1), k(""), L && ((D = h.current) == null || D.blur());
402
- }, Z = () => {
403
- t == null || t(void 0), k(""), g(!1);
404
- }, Y = (M) => {
405
- if (!y) {
406
- (M.key === "ArrowDown" || M.key === "ArrowUp") && (g(!0), M.preventDefault());
403
+ const x = r.find((E) => E.value === e), I = x && c, S = !o && !I, $ = `nc-align-${v}`, z = !(w && a) && !!x, H = (E, D = !1) => {
404
+ var P;
405
+ t == null || t(E), y(!1), N(""), D && ((P = h.current) == null || P.blur());
406
+ }, K = () => {
407
+ t == null || t(void 0), N(""), y(!1);
408
+ }, j = (E) => {
409
+ if (!w) {
410
+ (E.key === "ArrowDown" || E.key === "ArrowUp") && (y(!0), E.preventDefault());
407
411
  return;
408
412
  }
409
- switch (M.key) {
413
+ switch (E.key) {
410
414
  case "ArrowDown":
411
- M.preventDefault(), p((L) => {
412
- const D = L + 1;
413
- return D >= T.length ? 0 : D;
415
+ E.preventDefault(), p((D) => {
416
+ const P = D + 1;
417
+ return P >= L.length ? 0 : P;
414
418
  });
415
419
  break;
416
420
  case "ArrowUp":
417
- M.preventDefault(), p((L) => {
418
- const D = L - 1;
419
- return D < 0 ? T.length - 1 : D;
421
+ E.preventDefault(), p((D) => {
422
+ const P = D - 1;
423
+ return P < 0 ? L.length - 1 : P;
420
424
  });
421
425
  break;
422
426
  case "Enter":
423
- M.preventDefault(), b >= 0 && b < T.length && F(T[b].value, !0);
427
+ E.preventDefault(), b >= 0 && b < L.length && H(L[b].value, !0);
424
428
  break;
425
429
  case "Escape":
426
- M.preventDefault(), g(!1), k("");
430
+ E.preventDefault(), y(!1), N("");
427
431
  break;
428
432
  }
429
433
  };
430
- return /* @__PURE__ */ A("div", { className: `nc-combo-container ${f === "transparent" ? "nc-transparent" : ""} ${$} ${m || ""}`.trim(), style: { position: "relative", ...d }, children: [
434
+ return /* @__PURE__ */ k("div", { className: `nc-combo-container ${f === "transparent" ? "nc-transparent" : ""} ${f === "plain" ? "nc-plain" : ""} ${w ? "nc-open" : ""} ${$} ${m || ""}`.trim(), style: { position: "relative", ...d }, children: [
431
435
  i && /* @__PURE__ */ s("span", { className: `nc-label ${C ? "nc-small" : ""}`, children: i }),
432
- /* @__PURE__ */ A(
436
+ /* @__PURE__ */ k(
433
437
  "div",
434
438
  {
435
- ref: N,
439
+ ref: A,
436
440
  style: { position: "relative", display: "flex", alignItems: "center" },
437
- onMouseDown: (M) => {
438
- o || c && M.target === h.current || (g((L) => (!L && c && x && k(x.label), !L)), c && !y && setTimeout(() => {
439
- var L, D;
440
- (L = h.current) == null || L.focus(), (D = h.current) == null || D.select();
441
+ onMouseDown: (E) => {
442
+ o || a && E.target === h.current || (y((D) => (!D && a && x && N(x.label), !D)), a && !w && setTimeout(() => {
443
+ var D, P;
444
+ (D = h.current) == null || D.focus(), (P = h.current) == null || P.select();
441
445
  }, 0));
442
446
  },
443
447
  children: [
@@ -448,27 +452,26 @@ function Bn({
448
452
  className: `nc-input ${C ? "nc-small" : ""}`,
449
453
  placeholder: n,
450
454
  onFocus: () => {
451
- var M;
452
- !o && c && (g(!0), x && (k(x.label), setTimeout(() => {
453
- var L;
454
- return (L = h.current) == null ? void 0 : L.select();
455
- }, 0))), c || (M = h.current) == null || M.blur();
455
+ !o && a && (y(!0), x && (N(x.label), setTimeout(() => {
456
+ var E;
457
+ return (E = h.current) == null ? void 0 : E.select();
458
+ }, 0)));
456
459
  },
457
- onChange: (M) => c && k(M.target.value),
458
- onKeyDown: Y,
459
- value: y && c ? w : (x == null ? void 0 : x.label) || "",
460
- readOnly: o || !c,
460
+ onChange: (E) => a && N(E.target.value),
461
+ onKeyDown: j,
462
+ value: w && a ? g : (x == null ? void 0 : x.label) || "",
463
+ readOnly: o || !a,
461
464
  style: {
462
465
  width: "100%",
463
- paddingRight: S || R ? C ? 32 : 44 : 12,
464
- caretColor: c ? void 0 : "transparent",
465
- cursor: c ? void 0 : "pointer",
466
- userSelect: c ? void 0 : "none",
467
- color: P ? "transparent" : "var(--nc-text)"
466
+ paddingRight: S || I ? C ? 32 : 44 : 12,
467
+ caretColor: a ? void 0 : "transparent",
468
+ cursor: a ? void 0 : "pointer",
469
+ userSelect: a ? void 0 : "none",
470
+ color: z ? "transparent" : "var(--nc-text)"
468
471
  }
469
472
  }
470
473
  ),
471
- P && /* @__PURE__ */ A(
474
+ z && /* @__PURE__ */ k(
472
475
  "div",
473
476
  {
474
477
  "aria-hidden": !0,
@@ -476,30 +479,30 @@ function Bn({
476
479
  style: {
477
480
  position: "absolute",
478
481
  left: C ? 8 : 12,
479
- right: S || R ? C ? 12 : 24 : C ? 8 : 12,
482
+ right: S || I ? C ? 12 : 24 : C ? 8 : 12,
480
483
  top: "50%",
481
484
  transform: "translateY(-50%)",
482
485
  pointerEvents: "none"
483
486
  },
484
487
  children: [
485
488
  /* @__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: [
489
+ (x == null ? void 0 : x.default) && /* @__PURE__ */ k("span", { className: `nc-combo-overlay-default ${C ? "nc-small" : ""}`, children: [
487
490
  "(",
488
- z("common.default"),
491
+ T("common.default"),
489
492
  ")"
490
493
  ] })
491
494
  ]
492
495
  }
493
496
  ),
494
- R && /* @__PURE__ */ s(kt, { onClick: Z, small: C }),
495
- S && /* @__PURE__ */ s(Nt, { open: y, onClick: () => g((M) => !M), small: C })
497
+ I && /* @__PURE__ */ s(Et, { onClick: K, small: C }),
498
+ S && /* @__PURE__ */ s(Tt, { open: w, small: C })
496
499
  ]
497
500
  }
498
501
  ),
499
- /* @__PURE__ */ s(xt, { isOpen: y, options: T, onSelect: F, selectedValue: e, placement: l, anchorRef: N, small: C, highlightedIndex: b })
502
+ /* @__PURE__ */ s(Rt, { isOpen: w, options: L, onSelect: H, selectedValue: e, placement: l, anchorRef: A, small: C, highlightedIndex: b })
500
503
  ] });
501
504
  }
502
- function Dn({ onClick: e, loading: t = !1, disabled: n = !1, size: r = "default", title: o, "aria-label": i }) {
505
+ function Un({ onClick: e, loading: t = !1, disabled: n = !1, size: r = "default", title: o, "aria-label": i }) {
503
506
  return /* @__PURE__ */ s(
504
507
  "button",
505
508
  {
@@ -509,11 +512,11 @@ function Dn({ onClick: e, loading: t = !1, disabled: n = !1, size: r = "default"
509
512
  title: o ?? (t ? "Refreshing..." : "Refresh"),
510
513
  "aria-label": i ?? (t ? "Refreshing" : "Refresh"),
511
514
  "data-size": r,
512
- children: /* @__PURE__ */ s(ot, { size: r === "small" ? 14 : r === "large" ? 20 : 18, className: t ? "nc-spinning" : "" })
515
+ children: /* @__PURE__ */ s(ft, { size: r === "small" ? 14 : r === "large" ? 20 : 18, className: t ? "nc-spinning" : "" })
513
516
  }
514
517
  );
515
518
  }
516
- function We({ onClick: e, disabled: t = !1, size: n = "default", title: r = "Close", "aria-label": o = "Close" }) {
519
+ function _e({ onClick: e, disabled: t = !1, size: n = "default", title: r = "Close", "aria-label": o = "Close" }) {
517
520
  return /* @__PURE__ */ s(
518
521
  "button",
519
522
  {
@@ -523,11 +526,11 @@ function We({ onClick: e, disabled: t = !1, size: n = "default", title: r = "Clo
523
526
  title: r,
524
527
  "aria-label": o,
525
528
  "data-size": n,
526
- children: /* @__PURE__ */ s(xe, { size: n === "small" ? 14 : n === "large" ? 20 : 18 })
529
+ children: /* @__PURE__ */ s(Ce, { size: n === "small" ? 14 : n === "large" ? 20 : 18 })
527
530
  }
528
531
  );
529
532
  }
530
- function Hn({ onClick: e, disabled: t = !1, size: n = "default", title: r = "Edit", "aria-label": o = "Edit" }) {
533
+ function qn({ onClick: e, disabled: t = !1, size: n = "default", title: r = "Edit", "aria-label": o = "Edit" }) {
531
534
  return /* @__PURE__ */ s(
532
535
  "button",
533
536
  {
@@ -537,11 +540,11 @@ function Hn({ onClick: e, disabled: t = !1, size: n = "default", title: r = "Edi
537
540
  title: r,
538
541
  "aria-label": o,
539
542
  "data-size": n,
540
- children: /* @__PURE__ */ s(rt, { size: n === "small" ? 14 : n === "large" ? 20 : 18 })
543
+ children: /* @__PURE__ */ s(pt, { size: n === "small" ? 14 : n === "large" ? 20 : 18 })
541
544
  }
542
545
  );
543
546
  }
544
- function Wn({ onClick: e, disabled: t = !1, size: n = "default", title: r = "Delete", "aria-label": o = "Delete" }) {
547
+ function Xn({ onClick: e, disabled: t = !1, size: n = "default", title: r = "Delete", "aria-label": o = "Delete" }) {
545
548
  return /* @__PURE__ */ s(
546
549
  "button",
547
550
  {
@@ -551,11 +554,11 @@ function Wn({ onClick: e, disabled: t = !1, size: n = "default", title: r = "Del
551
554
  title: r,
552
555
  "aria-label": o,
553
556
  "data-size": n,
554
- children: /* @__PURE__ */ s(st, { size: n === "small" ? 14 : n === "large" ? 20 : 18 })
557
+ children: /* @__PURE__ */ s(ht, { size: n === "small" ? 14 : n === "large" ? 20 : 18 })
555
558
  }
556
559
  );
557
560
  }
558
- function On({ onClick: e, disabled: t = !1, children: n, title: r, "aria-label": o, size: i = "default" }) {
561
+ function Jn({ onClick: e, disabled: t = !1, children: n, title: r, "aria-label": o, size: i = "default" }) {
559
562
  return /* @__PURE__ */ s(
560
563
  "button",
561
564
  {
@@ -569,7 +572,7 @@ function On({ onClick: e, disabled: t = !1, children: n, title: r, "aria-label":
569
572
  }
570
573
  );
571
574
  }
572
- function Fn({
575
+ function Zn({
573
576
  open: e,
574
577
  onClose: t,
575
578
  options: n,
@@ -577,16 +580,16 @@ function Fn({
577
580
  anchor: o,
578
581
  preferredDirection: i = "down"
579
582
  }) {
580
- const a = W(null), [c, l] = E({ top: 0, left: 0 }), u = o || (r == null ? void 0 : r.current);
583
+ const c = V(null), [a, l] = R({ top: 0, left: 0 }), u = o || (r == null ? void 0 : r.current);
581
584
  if (B(() => {
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;
585
+ if (!e || !u || !c.current) return;
586
+ const d = u.getBoundingClientRect(), m = c.current.getBoundingClientRect(), w = window.innerHeight, y = window.innerWidth, g = d.bottom + 8, N = g + m.height <= w - 8;
584
587
  let b = i;
585
- (!k && i === "down" || i === "up" && k) && (b = "up");
588
+ (!N && i === "down" || i === "up" && N) && (b = "up");
586
589
  let p;
587
- b === "down" ? p = w : p = d.top - m.height - 8;
590
+ b === "down" ? p = g : p = d.top - m.height - 8;
588
591
  let h = d.left;
589
- h + m.width > g - 8 && (h = d.right - m.width), l({
592
+ h + m.width > y - 8 && (h = d.right - m.width), l({
590
593
  top: Math.max(8, p),
591
594
  // Ensure minimum 8px from top
592
595
  left: Math.max(8, h)
@@ -594,10 +597,10 @@ function Fn({
594
597
  });
595
598
  }, [e, u, i]), B(() => {
596
599
  if (!e) return;
597
- const d = (y) => {
598
- a.current && !a.current.contains(y.target) && u && !u.contains(y.target) && t();
599
- }, m = (y) => {
600
- y.key === "Escape" && t();
600
+ const d = (w) => {
601
+ c.current && !c.current.contains(w.target) && u && !u.contains(w.target) && t();
602
+ }, m = (w) => {
603
+ w.key === "Escape" && t();
601
604
  };
602
605
  return document.addEventListener("mousedown", d), document.addEventListener("keydown", m), () => {
603
606
  document.removeEventListener("mousedown", d), document.removeEventListener("keydown", m);
@@ -606,16 +609,16 @@ function Fn({
606
609
  const f = (d) => {
607
610
  d.type !== "separator" && !d.disabled && d.onClick && (d.onClick(), t());
608
611
  }, v = n.some((d) => d.icon);
609
- return ue(
612
+ return pe(
610
613
  /* @__PURE__ */ s(
611
614
  "div",
612
615
  {
613
- ref: a,
616
+ ref: c,
614
617
  className: "nc-context-menu",
615
618
  style: {
616
619
  position: "fixed",
617
- top: `${c.top}px`,
618
- left: `${c.left}px`,
620
+ top: `${a.top}px`,
621
+ left: `${a.left}px`,
619
622
  zIndex: 1e4
620
623
  },
621
624
  role: "menu",
@@ -635,7 +638,7 @@ function Fn({
635
638
  d.disabled ? "nc-disabled" : "",
636
639
  v && !d.icon ? "nc-indented" : ""
637
640
  ].filter(Boolean).join(" ");
638
- return /* @__PURE__ */ A(
641
+ return /* @__PURE__ */ k(
639
642
  "button",
640
643
  {
641
644
  className: m,
@@ -655,114 +658,114 @@ function Fn({
655
658
  document.body
656
659
  );
657
660
  }
658
- const Oe = se(null);
659
- function At() {
660
- const e = Q(Oe);
661
+ const Ue = ce(null);
662
+ function Pt() {
663
+ const e = te(Ue);
661
664
  if (!e)
662
665
  throw new Error("useDialog must be used inside a Dialog component");
663
666
  return e;
664
667
  }
665
- function ne({ children: e, onClick: t, ...n }) {
666
- const { close: r } = At(), { t: o } = U();
667
- return /* @__PURE__ */ s(K, { onClick: (a) => {
668
- t == null || t(a), r();
668
+ function oe({ children: e, onClick: t, ...n }) {
669
+ const { close: r } = Pt(), { t: o } = X();
670
+ return /* @__PURE__ */ s(U, { onClick: (c) => {
671
+ t == null || t(c), r();
669
672
  }, ...n, children: e ?? o("common.close") });
670
673
  }
671
- function Vn({
674
+ function Qn({
672
675
  open: e,
673
676
  onClose: t,
674
677
  title: n,
675
678
  children: r,
676
679
  style: o,
677
680
  footerType: i = "ok-cancel",
678
- footer: a,
679
- onOk: c,
681
+ footer: c,
682
+ onOk: a,
680
683
  onSave: l,
681
684
  onDelete: u,
682
685
  onCancel: f,
683
686
  onConnect: v,
684
687
  closeOnOverlay: d = !0,
685
688
  primaryDisabled: m = !1,
686
- fullScreen: y = !1,
687
- hideTitleBar: g = !1,
688
- className: w = "",
689
- onContentHeightChange: k
689
+ fullScreen: w = !1,
690
+ hideTitleBar: y = !1,
691
+ className: g = "",
692
+ onContentHeightChange: N
690
693
  }) {
691
- const b = W(null), p = W(null), { t: h } = U(), N = { close: t }, C = (x) => {
694
+ const b = V(null), p = V(null), { t: h } = X(), A = { close: t }, C = (x) => {
692
695
  d && x.target === x.currentTarget && t();
693
696
  };
694
697
  if (B(() => {
695
698
  e && b.current && b.current.focus();
696
699
  }, [e]), B(() => {
697
- if (!k || !p.current) return;
698
- const x = new ResizeObserver((R) => {
699
- for (const S of R) {
700
+ if (!N || !p.current) return;
701
+ const x = new ResizeObserver((I) => {
702
+ for (const S of I) {
700
703
  const $ = S.contentRect.height;
701
- k($);
704
+ N($);
702
705
  }
703
706
  });
704
707
  return x.observe(p.current), () => {
705
708
  x.disconnect();
706
709
  };
707
- }, [k]), !e) return null;
708
- const z = () => {
710
+ }, [N]), !e) return null;
711
+ const T = () => {
709
712
  switch (i) {
710
713
  case "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") }) });
714
+ return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(U, { variant: "primary", onClick: a ?? t, disabled: m, children: h("common.ok") }) });
712
715
  case "ok-cancel":
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") })
716
+ return /* @__PURE__ */ k("div", { className: "nc-dialog-footer", children: [
717
+ /* @__PURE__ */ s(oe, { onClick: f, children: h("common.cancel") }),
718
+ /* @__PURE__ */ s(U, { variant: "primary", onClick: a ?? t, disabled: m, children: h("common.ok") })
716
719
  ] });
717
720
  case "save-cancel":
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") })
721
+ return /* @__PURE__ */ k("div", { className: "nc-dialog-footer", children: [
722
+ /* @__PURE__ */ s(oe, { onClick: f, children: h("common.cancel") }),
723
+ /* @__PURE__ */ s(U, { variant: "primary", onClick: l, disabled: m, children: h("common.save") })
721
724
  ] });
722
725
  case "delete-cancel":
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") })
726
+ return /* @__PURE__ */ k("div", { className: "nc-dialog-footer", children: [
727
+ /* @__PURE__ */ s(oe, { onClick: f, children: h("common.cancel") }),
728
+ /* @__PURE__ */ s(U, { variant: "danger", onClick: u, disabled: m, children: h("common.delete") })
726
729
  ] });
727
730
  case "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") })
731
+ return /* @__PURE__ */ k("div", { className: "nc-dialog-footer", children: [
732
+ /* @__PURE__ */ s(oe, { onClick: f, children: h("common.cancel") }),
733
+ /* @__PURE__ */ s(U, { variant: "primary", onClick: v, disabled: m, children: h("common.connect") })
731
734
  ] });
732
735
  case "close":
733
- return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(ne, { variant: "primary" }) });
736
+ return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(oe, { variant: "primary" }) });
734
737
  case "gotit":
735
- return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(ne, { variant: "primary", children: h("common.gotit") }) });
738
+ return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: /* @__PURE__ */ s(oe, { variant: "primary", children: h("common.gotit") }) });
736
739
  case "custom":
737
- return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: a });
740
+ return /* @__PURE__ */ s("div", { className: "nc-dialog-footer", children: c });
738
741
  case "none":
739
742
  return null;
740
743
  default:
741
744
  return null;
742
745
  }
743
- }, T = /* @__PURE__ */ s(Oe.Provider, { value: N, children: /* @__PURE__ */ s("div", { className: `nc-dialog-overlay${y ? " nc-fullscreen" : ""}`, onClick: C, children: /* @__PURE__ */ A(
746
+ }, L = /* @__PURE__ */ s(Ue.Provider, { value: A, children: /* @__PURE__ */ s("div", { className: `nc-dialog-overlay${w ? " nc-fullscreen" : ""}`, onClick: C, children: /* @__PURE__ */ k(
744
747
  "div",
745
748
  {
746
749
  ref: b,
747
- className: `nc-dialog-container ${w}`,
750
+ className: `nc-dialog-container ${g}`,
748
751
  style: o,
749
752
  tabIndex: -1,
750
753
  role: "dialog",
751
754
  "aria-modal": "true",
752
- "aria-labelledby": g ? void 0 : "nc-dialog-title",
755
+ "aria-labelledby": y ? void 0 : "nc-dialog-title",
753
756
  children: [
754
- !g && /* @__PURE__ */ A("div", { className: "nc-dialog-header", children: [
757
+ !y && /* @__PURE__ */ k("div", { className: "nc-dialog-header", children: [
755
758
  /* @__PURE__ */ s("h3", { id: "nc-dialog-title", className: "nc-dialog-title", children: n }),
756
- /* @__PURE__ */ s(We, { onClick: t, "aria-label": "Close dialog" })
759
+ /* @__PURE__ */ s(_e, { onClick: t, "aria-label": "Close dialog" })
757
760
  ] }),
758
761
  /* @__PURE__ */ s("div", { ref: p, className: "nc-dialog-content", children: r }),
759
- z()
762
+ T()
760
763
  ]
761
764
  }
762
765
  ) }) });
763
- return y ? ue(T, document.body) : T;
766
+ return w ? pe(L, document.body) : L;
764
767
  }
765
- function St({ onClick: e, size: t = "default", rightOffset: n = 4 }) {
768
+ function Lt({ onClick: e, size: t = "default", rightOffset: n = 4 }) {
766
769
  const r = t === "small" ? 28 : 34;
767
770
  return /* @__PURE__ */ s(
768
771
  "button",
@@ -791,7 +794,7 @@ function St({ onClick: e, size: t = "default", rightOffset: n = 4 }) {
791
794
  }
792
795
  );
793
796
  }
794
- function Ct({ visible: e, onClick: t, size: n = "default" }) {
797
+ function zt({ visible: e, onClick: t, size: n = "default" }) {
795
798
  const r = n === "small" ? 28 : 34, o = n === "small" ? 16 : 18;
796
799
  return /* @__PURE__ */ s(
797
800
  "button",
@@ -815,108 +818,134 @@ function Ct({ visible: e, onClick: t, size: n = "default" }) {
815
818
  alignItems: "center",
816
819
  justifyContent: "center"
817
820
  },
818
- children: e ? /* @__PURE__ */ s(it, { size: o }) : /* @__PURE__ */ s(ct, { size: o })
821
+ children: e ? /* @__PURE__ */ s(mt, { size: o }) : /* @__PURE__ */ s(gt, { size: o })
819
822
  }
820
823
  );
821
824
  }
822
- function Yn({
825
+ function er({
823
826
  value: e,
824
827
  defaultValue: t = "",
825
828
  onChange: n,
826
829
  onEnter: r,
827
830
  onClear: o,
828
831
  placeholder: i,
829
- disabled: a,
830
- label: c,
832
+ disabled: c,
833
+ label: a,
831
834
  clearable: l = !0,
832
835
  type: u = "text",
833
836
  className: f = "",
834
837
  size: v = "default",
835
- style: d,
836
- leadingIcon: m,
838
+ appearance: d = "default",
839
+ style: m,
840
+ leadingIcon: w,
837
841
  showPasswordToggle: y = !1,
838
842
  multiline: g = !1,
839
- rows: w = 3,
840
- validator: k,
841
- showErrorMessage: b = !0
843
+ rows: N = 3,
844
+ validator: b,
845
+ showErrorMessage: p = !0
842
846
  }) {
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;
844
- let D = 12;
845
- M && Y ? D = L * 2 : (M || Y) && (D = L);
846
- const V = m ? v === "small" ? 28 : 34 : void 0, Ze = () => {
847
- var te, ce;
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) => {
850
- te.key === "Enter" && !g && (r == null || r());
851
- }, $e = (te) => {
852
- const ce = te.target.value;
853
- x || S(ce), n == null || n(ce);
854
- }, Ie = () => {
855
- T(!0);
856
- }, Me = () => {
857
- T(!1);
858
- }, Re = `nc-input ${v === "small" ? "nc-small " : ""} ${F ? "nc-error " : ""}${f}`;
859
- return /* @__PURE__ */ A("div", { className: "nc-col", style: { position: "relative", flex: 1, ...d }, children: [
860
- c && /* @__PURE__ */ s("span", { className: "nc-label", children: c }),
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 }),
847
+ const h = V(null), A = V(null), C = V(!1), [T, L] = R(!1), [x, I] = R(!1), S = e !== void 0, [$, z] = R(t), H = S ? e : $, [K, j] = R(H), E = b ? b(H) : null, D = !!E, P = !g && d === "plain", re = P && x, F = re ? K : H;
848
+ B(() => {
849
+ re || j(H);
850
+ }, [H, re]);
851
+ const Ee = u === "password", fe = Ee && y && !c && !g, ye = l && F && !c && x, xe = v === "small" ? 32 : 44;
852
+ let he = 12;
853
+ ye && fe ? he = xe * 2 : (ye || fe) && (he = xe);
854
+ const me = w ? v === "small" ? 28 : 34 : void 0, Te = () => P ? (S || z(K), K !== H && (n == null || n(K)), K) : H, ct = () => {
855
+ j(H);
856
+ }, at = () => {
857
+ var G, J, We;
858
+ if (P) {
859
+ j(""), o == null || o(), (G = h.current) == null || G.focus();
860
+ return;
861
+ }
862
+ S || z(""), n == null || n(""), o == null || o(), g ? (J = A.current) == null || J.focus() : (We = h.current) == null || We.focus();
863
+ }, Pe = (G) => {
864
+ if (P && G.key === "Escape") {
865
+ G.preventDefault(), C.current = !0, ct(), G.currentTarget.blur();
866
+ return;
867
+ }
868
+ if (G.key === "Enter" && !g) {
869
+ const J = P ? Te() : H;
870
+ P && (G.preventDefault(), C.current = !0, G.currentTarget.blur()), r == null || r(J);
871
+ }
872
+ }, Le = (G) => {
873
+ const J = G.target.value;
874
+ if (P) {
875
+ j(J);
876
+ return;
877
+ }
878
+ S || z(J), n == null || n(J);
879
+ }, ze = () => {
880
+ I(!0), P && j(H);
881
+ }, Be = () => {
882
+ if (P && C.current) {
883
+ C.current = !1, I(!1);
884
+ return;
885
+ }
886
+ P && Te(), I(!1);
887
+ }, De = `nc-input ${v === "small" ? "nc-small " : ""}${!g && d === "plain" ? "nc-plain " : ""}${D ? "nc-error " : ""}${f}`;
888
+ return /* @__PURE__ */ k("div", { className: "nc-col", style: { position: "relative", flex: 1, ...m }, children: [
889
+ a && /* @__PURE__ */ s("span", { className: "nc-label", children: a }),
890
+ /* @__PURE__ */ k("div", { style: { position: "relative", display: "flex", alignItems: g ? "flex-start" : "center" }, children: [
891
+ w && /* @__PURE__ */ s("span", { className: "nc-input-leading-icon", style: { height: g ? void 0 : "100%", top: g ? 10 : void 0 }, children: w }),
863
892
  g ? /* @__PURE__ */ s(
864
893
  "textarea",
865
894
  {
866
- ref: h,
867
- className: Re,
895
+ ref: A,
896
+ className: De,
868
897
  placeholder: i,
869
- value: $,
870
- onChange: $e,
871
- onKeyDown: Ce,
872
- onFocus: Ie,
873
- onBlur: Me,
874
- readOnly: a,
875
- "aria-disabled": a,
876
- tabIndex: a ? -1 : void 0,
877
- rows: w,
898
+ value: F,
899
+ onChange: Le,
900
+ onKeyDown: Pe,
901
+ onFocus: ze,
902
+ onBlur: Be,
903
+ readOnly: c,
904
+ "aria-disabled": c,
905
+ tabIndex: c ? -1 : void 0,
906
+ rows: N,
878
907
  style: {
879
908
  width: "100%",
880
- paddingRight: D,
881
- ...V !== void 0 ? { paddingLeft: V } : {}
909
+ paddingRight: he,
910
+ ...me !== void 0 ? { paddingLeft: me } : {}
882
911
  }
883
912
  }
884
913
  ) : /* @__PURE__ */ s(
885
914
  "input",
886
915
  {
887
- ref: p,
888
- type: Z && N ? "text" : u,
889
- className: Re,
916
+ ref: h,
917
+ type: Ee && T ? "text" : u,
918
+ className: De,
890
919
  placeholder: i,
891
- value: $,
892
- onChange: $e,
893
- onKeyDown: Ce,
894
- onFocus: Ie,
895
- onBlur: Me,
896
- readOnly: a,
897
- "aria-disabled": a,
898
- tabIndex: a ? -1 : void 0,
920
+ value: F,
921
+ onChange: Le,
922
+ onKeyDown: Pe,
923
+ onFocus: ze,
924
+ onBlur: Be,
925
+ readOnly: c,
926
+ "aria-disabled": c,
927
+ tabIndex: c ? -1 : void 0,
899
928
  style: {
900
929
  width: "100%",
901
- paddingRight: D,
902
- ...V !== void 0 ? { paddingLeft: V } : {}
930
+ paddingRight: he,
931
+ ...me !== void 0 ? { paddingLeft: me } : {}
903
932
  }
904
933
  }
905
934
  ),
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 })
935
+ ye && /* @__PURE__ */ s(Lt, { onClick: at, size: v, rightOffset: fe ? xe + 4 : 4 }),
936
+ fe && /* @__PURE__ */ s(zt, { visible: T, onClick: () => L(!T), size: v })
908
937
  ] }),
909
- F && b && /* @__PURE__ */ s("span", { className: "nc-error-message", children: P })
938
+ D && p && /* @__PURE__ */ s("span", { className: "nc-error-message", children: E })
910
939
  ] });
911
940
  }
912
- function Gn({
941
+ function tr({
913
942
  children: e,
914
943
  onClick: t,
915
944
  showBorder: n = !0,
916
945
  selectable: r = !1,
917
946
  style: o
918
947
  }) {
919
- const [i, a] = ke.useState(!1);
948
+ const [i, c] = $e.useState(!1);
920
949
  return /* @__PURE__ */ s(
921
950
  "div",
922
951
  {
@@ -930,9 +959,9 @@ function Gn({
930
959
  t(l);
931
960
  }
932
961
  },
933
- onMouseDown: () => t && a(!0),
934
- onMouseUp: () => a(!1),
935
- onMouseLeave: () => a(!1),
962
+ onMouseDown: () => t && c(!0),
963
+ onMouseUp: () => c(!1),
964
+ onMouseLeave: () => c(!1),
936
965
  style: {
937
966
  cursor: t ? "pointer" : "default",
938
967
  userSelect: r ? "text" : void 0,
@@ -944,9 +973,9 @@ function Gn({
944
973
  }
945
974
  );
946
975
  }
947
- function jn({ title: e, titleTools: t, children: n, style: r }) {
948
- return /* @__PURE__ */ A("div", { className: "nc-list-group", style: r, children: [
949
- (e || t) && /* @__PURE__ */ A("div", { className: "nc-list-group-title", children: [
976
+ function nr({ title: e, titleTools: t, children: n, style: r }) {
977
+ return /* @__PURE__ */ k("div", { className: "nc-list-group", style: r, children: [
978
+ (e || t) && /* @__PURE__ */ k("div", { className: "nc-list-group-title", children: [
950
979
  /* @__PURE__ */ s("div", { children: e }),
951
980
  t && /* @__PURE__ */ s("div", { className: "nc-list-group-title-tools", children: t })
952
981
  ] }),
@@ -959,24 +988,24 @@ function jn({ title: e, titleTools: t, children: n, style: r }) {
959
988
  )
960
989
  ] });
961
990
  }
962
- function Kn({ values: e, onChange: t, options: n, placeholder: r = "Select…", label: o }) {
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]);
991
+ function rr({ values: e, onChange: t, options: n, placeholder: r = "Select…", label: o }) {
992
+ const [i, c] = R(!1), [a, l] = R(""), u = V(null), f = we(() => n.filter((d) => d.label.toLowerCase().includes(a.toLowerCase())), [n, a]);
964
993
  B(() => {
965
994
  function d(m) {
966
- !(m.target instanceof Node) || !u.current || u.current.contains(m.target) || a(!1);
995
+ !(m.target instanceof Node) || !u.current || u.current.contains(m.target) || c(!1);
967
996
  }
968
997
  return document.addEventListener("mousedown", d), () => document.removeEventListener("mousedown", d);
969
998
  }, []);
970
999
  const v = (d) => {
971
1000
  e.includes(d) ? t(e.filter((m) => m !== d)) : t([...e, d]);
972
1001
  };
973
- return /* @__PURE__ */ A("div", { ref: u, className: "nc-col", style: { position: "relative" }, children: [
1002
+ return /* @__PURE__ */ k("div", { ref: u, className: "nc-col", style: { position: "relative" }, children: [
974
1003
  o && /* @__PURE__ */ s("span", { className: "nc-label", children: o }),
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: [
1004
+ /* @__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: [
976
1005
  e.length === 0 && /* @__PURE__ */ s("span", { className: "nc-label", children: r }),
977
1006
  e.map((d) => {
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: [
1007
+ const m = n.find((w) => w.value === d);
1008
+ return m ? /* @__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: [
980
1009
  m.label,
981
1010
  /* @__PURE__ */ s(
982
1011
  "button",
@@ -994,17 +1023,17 @@ function Kn({ values: e, onChange: t, options: n, placeholder: r = "Select…",
994
1023
  "input",
995
1024
  {
996
1025
  className: "nc-input",
997
- value: c,
1026
+ value: a,
998
1027
  onChange: (d) => l(d.target.value),
999
- onFocus: () => a(!0),
1028
+ onFocus: () => c(!0),
1000
1029
  style: { minWidth: 50, border: "none", background: "transparent", padding: 4, minHeight: 32, flex: 1 }
1001
1030
  }
1002
1031
  )
1003
1032
  ] }),
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: [
1033
+ 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: [
1005
1034
  f.map((d) => {
1006
1035
  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: [
1036
+ return /* @__PURE__ */ k("div", { className: "nc-section nc-row", style: { justifyContent: "space-between", cursor: "pointer", padding: 12 }, onMouseDown: () => v(d.value), children: [
1008
1037
  /* @__PURE__ */ s("span", { children: d.label }),
1009
1038
  /* @__PURE__ */ s("span", { children: m ? "✔️" : "" })
1010
1039
  ] }, d.value);
@@ -1013,7 +1042,7 @@ function Kn({ values: e, onChange: t, options: n, placeholder: r = "Select…",
1013
1042
  ] })
1014
1043
  ] });
1015
1044
  }
1016
- function pe(e) {
1045
+ function ge(e) {
1017
1046
  if (!e) return null;
1018
1047
  const t = /^\d{2}-\d{1,2}$/, n = /^\d{4}-\d{1,2}$/;
1019
1048
  if (!t.test(e) && !n.test(e))
@@ -1021,7 +1050,7 @@ function pe(e) {
1021
1050
  const r = e.split("-"), o = parseInt(r[1], 10);
1022
1051
  return o < 1 || o > 12 ? "Month must be between 1 and 12" : null;
1023
1052
  }
1024
- function de(e) {
1053
+ function ue(e) {
1025
1054
  if (!e) return "";
1026
1055
  const t = e.split("-");
1027
1056
  if (t.length !== 2) return e;
@@ -1033,65 +1062,65 @@ function de(e) {
1033
1062
  }
1034
1063
  return `${n}-${r}`;
1035
1064
  }
1036
- function Ee(e) {
1065
+ function He(e) {
1037
1066
  if (!e) return "";
1038
- const t = de(e);
1067
+ const t = ue(e);
1039
1068
  if (!/^\d{4}-\d{2}$/.test(t)) return e;
1040
1069
  const [n, r] = t.split("-");
1041
1070
  return `${n}/${r}`;
1042
1071
  }
1043
- function Te() {
1072
+ function Ve() {
1044
1073
  const e = /* @__PURE__ */ new Date(), t = e.getFullYear(), n = String(e.getMonth() + 1).padStart(2, "0");
1045
1074
  return `${t}-${n}`;
1046
1075
  }
1047
- function _n({
1076
+ function or({
1048
1077
  startMonth: e,
1049
1078
  endMonth: t,
1050
1079
  onChange: n,
1051
1080
  label: r,
1052
1081
  className: o = "",
1053
1082
  disabled: i = !1,
1054
- size: a = "default"
1083
+ size: c = "default"
1055
1084
  }) {
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);
1085
+ const [a, l] = R(!1), [u, f] = R(""), [v, d] = R(""), [m, w] = R({ top: 0, left: 0, width: 0, right: void 0 }), y = V(null), g = V(null);
1057
1086
  B(() => {
1058
- if (c && g.current) {
1059
- const S = g.current.getBoundingClientRect(), P = Math.max(S.width, 400);
1060
- window.innerWidth - S.left < P && S.right >= P ? y({
1087
+ if (a && y.current) {
1088
+ const S = y.current.getBoundingClientRect(), z = Math.max(S.width, 400);
1089
+ window.innerWidth - S.left < z && S.right >= z ? w({
1061
1090
  top: S.bottom + 4,
1062
1091
  left: 0,
1063
1092
  // Not used but type needs it, let's just use 0
1064
1093
  right: window.innerWidth - S.right,
1065
- width: P
1066
- }) : y({
1094
+ width: z
1095
+ }) : w({
1067
1096
  top: S.bottom + 4,
1068
1097
  left: S.left,
1069
1098
  right: void 0,
1070
- width: P
1099
+ width: z
1071
1100
  });
1072
1101
  }
1073
- }, [c]), B(() => {
1074
- if (!c) return;
1102
+ }, [a]), B(() => {
1103
+ if (!a) return;
1075
1104
  const S = ($) => {
1076
- g.current && !g.current.contains($.target) && w.current && !w.current.contains($.target) && l(!1);
1105
+ y.current && !y.current.contains($.target) && g.current && !g.current.contains($.target) && l(!1);
1077
1106
  };
1078
1107
  return document.addEventListener("mousedown", S), () => document.removeEventListener("mousedown", S);
1079
- }, [c]);
1080
- const k = () => {
1081
- f(e || Te()), d(t || Te()), l(!0);
1108
+ }, [a]);
1109
+ const N = () => {
1110
+ f(e || Ve()), d(t || Ve()), l(!0);
1082
1111
  }, b = () => {
1083
1112
  l(!1);
1084
1113
  }, p = () => {
1085
- const S = pe(u), $ = pe(v);
1114
+ const S = ge(u), $ = ge(v);
1086
1115
  if (S || $)
1087
1116
  return;
1088
- const P = de(u), F = de(v);
1089
- P && F && (n == null || n(P, F)), l(!1);
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(
1117
+ const z = ue(u), H = ue(v);
1118
+ z && H && (n == null || n(z, H)), l(!1);
1119
+ }, h = e && t ? `${He(e)} - ${He(t)}` : "Select month range", A = ge(u), C = ge(v), T = ue(u), L = ue(v), x = T && L && T > L, I = a ? pe(
1091
1120
  /* @__PURE__ */ s(
1092
1121
  "div",
1093
1122
  {
1094
- ref: w,
1123
+ ref: g,
1095
1124
  className: "nc-month-range-picker-popup",
1096
1125
  style: {
1097
1126
  position: "fixed",
@@ -1100,23 +1129,23 @@ function _n({
1100
1129
  width: m.width,
1101
1130
  zIndex: 1e3
1102
1131
  },
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: [
1132
+ children: /* @__PURE__ */ k("div", { className: "nc-month-range-picker-content", children: [
1133
+ /* @__PURE__ */ k("div", { className: "nc-month-range-picker-row", children: [
1134
+ /* @__PURE__ */ k("div", { className: "nc-month-range-picker-column", children: [
1106
1135
  /* @__PURE__ */ s("label", { className: "nc-label", children: "Start Month" }),
1107
1136
  /* @__PURE__ */ s(
1108
1137
  "input",
1109
1138
  {
1110
1139
  type: "text",
1111
- className: `nc-month-input ${N ? "nc-error" : ""}`,
1140
+ className: `nc-month-input ${A ? "nc-error" : ""}`,
1112
1141
  value: u,
1113
1142
  onChange: (S) => f(S.target.value),
1114
1143
  placeholder: "YY-M(M) or YYYY-M(M)"
1115
1144
  }
1116
1145
  ),
1117
- N && /* @__PURE__ */ s("div", { className: "nc-month-error-text", children: N })
1146
+ A && /* @__PURE__ */ s("div", { className: "nc-month-error-text", children: A })
1118
1147
  ] }),
1119
- /* @__PURE__ */ A("div", { className: "nc-month-range-picker-column", children: [
1148
+ /* @__PURE__ */ k("div", { className: "nc-month-range-picker-column", children: [
1120
1149
  /* @__PURE__ */ s("label", { className: "nc-label", children: "End Month" }),
1121
1150
  /* @__PURE__ */ s(
1122
1151
  "input",
@@ -1131,50 +1160,50 @@ function _n({
1131
1160
  C && /* @__PURE__ */ s("div", { className: "nc-month-error-text", children: C })
1132
1161
  ] })
1133
1162
  ] }),
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: [
1163
+ x && !A && !C && /* @__PURE__ */ s("div", { className: "nc-month-range-error", children: "End month must be after or equal to start month" }),
1164
+ /* @__PURE__ */ k("div", { className: "nc-month-range-picker-footer", children: [
1136
1165
  /* @__PURE__ */ s(
1137
- K,
1166
+ U,
1138
1167
  {
1139
1168
  variant: "primary",
1140
1169
  onClick: p,
1141
- disabled: !u || !v || !!N || !!C || !!x,
1170
+ disabled: !u || !v || !!A || !!C || !!x,
1142
1171
  children: "Apply"
1143
1172
  }
1144
1173
  ),
1145
- /* @__PURE__ */ s(K, { variant: "ghost", onClick: b, children: "Cancel" })
1174
+ /* @__PURE__ */ s(U, { variant: "ghost", onClick: b, children: "Cancel" })
1146
1175
  ] })
1147
1176
  ] })
1148
1177
  }
1149
1178
  ),
1150
1179
  document.body
1151
1180
  ) : null;
1152
- return /* @__PURE__ */ A("div", { className: `nc-month-range-picker ${a === "small" ? "nc-small " : ""}${o}`, children: [
1153
- r && /* @__PURE__ */ s("label", { className: `nc-label${a === "small" ? " nc-small" : ""}`, children: r }),
1181
+ return /* @__PURE__ */ k("div", { className: `nc-month-range-picker ${c === "small" ? "nc-small " : ""}${o}`, children: [
1182
+ r && /* @__PURE__ */ s("label", { className: `nc-label${c === "small" ? " nc-small" : ""}`, children: r }),
1154
1183
  /* @__PURE__ */ s(
1155
1184
  "button",
1156
1185
  {
1157
- ref: g,
1158
- className: `nc-month-range-picker-input${a === "small" ? " nc-small" : ""}`,
1159
- onClick: k,
1186
+ ref: y,
1187
+ className: `nc-month-range-picker-input${c === "small" ? " nc-small" : ""}`,
1188
+ onClick: N,
1160
1189
  disabled: i,
1161
1190
  children: h
1162
1191
  }
1163
1192
  ),
1164
- R
1193
+ I
1165
1194
  ] });
1166
1195
  }
1167
- function Un({ value: e, onChange: t, min: n, max: r, step: o = 1, label: i, disabled: a, size: c = "default" }) {
1168
- const l = c === "small", u = () => {
1196
+ function sr({ value: e, onChange: t, min: n, max: r, step: o = 1, label: i, disabled: c, size: a = "default" }) {
1197
+ const l = a === "small", u = () => {
1169
1198
  const d = e - o;
1170
1199
  n !== void 0 && d < n || t(parseFloat(d.toFixed(10)));
1171
1200
  }, f = () => {
1172
1201
  const d = e + o;
1173
1202
  r !== void 0 && d > r || t(parseFloat(d.toFixed(10)));
1174
1203
  };
1175
- return /* @__PURE__ */ A("div", { className: `nc-col nc-number-input-col ${l ? "nc-small" : ""}`, children: [
1204
+ return /* @__PURE__ */ k("div", { className: `nc-col nc-number-input-col ${l ? "nc-small" : ""}`, children: [
1176
1205
  i && /* @__PURE__ */ s("span", { className: `nc-label ${l ? "nc-small" : ""}`, children: i }),
1177
- /* @__PURE__ */ A("div", { className: `nc-number-input-container ${l ? "nc-small" : ""}`, children: [
1206
+ /* @__PURE__ */ k("div", { className: `nc-number-input-container ${l ? "nc-small" : ""}`, children: [
1178
1207
  /* @__PURE__ */ s(
1179
1208
  "input",
1180
1209
  {
@@ -1188,7 +1217,7 @@ function Un({ value: e, onChange: t, min: n, max: r, step: o = 1, label: i, disa
1188
1217
  min: n,
1189
1218
  max: r,
1190
1219
  step: o,
1191
- disabled: a
1220
+ disabled: c
1192
1221
  }
1193
1222
  ),
1194
1223
  /* @__PURE__ */ s(
@@ -1196,7 +1225,7 @@ function Un({ value: e, onChange: t, min: n, max: r, step: o = 1, label: i, disa
1196
1225
  {
1197
1226
  className: `nc-button nc-ghost nc-number-input-button ${l ? "nc-small" : ""}`,
1198
1227
  onClick: u,
1199
- disabled: a || n !== void 0 && e <= n,
1228
+ disabled: c || n !== void 0 && e <= n,
1200
1229
  children: "−"
1201
1230
  }
1202
1231
  ),
@@ -1205,22 +1234,22 @@ function Un({ value: e, onChange: t, min: n, max: r, step: o = 1, label: i, disa
1205
1234
  {
1206
1235
  className: `nc-button nc-ghost nc-number-input-button ${l ? "nc-small" : ""}`,
1207
1236
  onClick: f,
1208
- disabled: a || r !== void 0 && e >= r,
1237
+ disabled: c || r !== void 0 && e >= r,
1209
1238
  children: "+"
1210
1239
  }
1211
1240
  )
1212
1241
  ] })
1213
1242
  ] });
1214
1243
  }
1215
- function qn({
1244
+ function ir({
1216
1245
  value: e,
1217
1246
  onChange: t,
1218
1247
  min: n = 0,
1219
1248
  max: r = 100,
1220
1249
  step: o = 1,
1221
1250
  label: i,
1222
- disabled: a,
1223
- showValue: c = !0,
1251
+ disabled: c,
1252
+ showValue: a = !0,
1224
1253
  formatValue: l = (f) => f.toString(),
1225
1254
  width: u = 200
1226
1255
  }) {
@@ -1228,9 +1257,9 @@ function qn({
1228
1257
  const m = parseFloat(d.target.value);
1229
1258
  t(m);
1230
1259
  }, v = (e - n) / (r - n) * 100;
1231
- return /* @__PURE__ */ A("div", { className: "nc-col", style: { gap: 6 }, children: [
1260
+ return /* @__PURE__ */ k("div", { className: "nc-col", style: { gap: 6 }, children: [
1232
1261
  i && /* @__PURE__ */ s("span", { className: "nc-label", children: i }),
1233
- /* @__PURE__ */ A("div", { style: { display: "flex", gap: 12, alignItems: "center" }, children: [
1262
+ /* @__PURE__ */ k("div", { style: { display: "flex", gap: 12, alignItems: "center" }, children: [
1234
1263
  /* @__PURE__ */ s(
1235
1264
  "input",
1236
1265
  {
@@ -1241,14 +1270,14 @@ function qn({
1241
1270
  min: n,
1242
1271
  max: r,
1243
1272
  step: o,
1244
- disabled: a,
1273
+ disabled: c,
1245
1274
  style: {
1246
1275
  width: u,
1247
1276
  "--nc-slider-percentage": `${v}%`
1248
1277
  }
1249
1278
  }
1250
1279
  ),
1251
- c && /* @__PURE__ */ s(
1280
+ a && /* @__PURE__ */ s(
1252
1281
  "span",
1253
1282
  {
1254
1283
  style: {
@@ -1264,114 +1293,114 @@ function qn({
1264
1293
  ] })
1265
1294
  ] });
1266
1295
  }
1267
- const $t = ({ size: e = 24, className: t, style: n }) => /* @__PURE__ */ s("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", className: t, style: n, children: /* @__PURE__ */ s("polyline", { points: "18 15 12 9 6 15" }) });
1268
- function It({ children: e, className: t = "", style: n }) {
1296
+ const Bt = ({ size: e = 24, className: t, style: n }) => /* @__PURE__ */ s("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", className: t, style: n, children: /* @__PURE__ */ s("polyline", { points: "18 15 12 9 6 15" }) });
1297
+ function Dt({ children: e, className: t = "", style: n }) {
1269
1298
  return /* @__PURE__ */ s("div", { className: `nc-tab-panel ${t}`, style: n, children: e });
1270
1299
  }
1271
- function Xn({ active: e, children: t, keepMounted: n = !1, className: r = "", style: o }) {
1272
- const i = ut.toArray(t).filter(
1273
- (c) => pt(c) && (c.type === It || c.type.displayName === "TabPanel")
1300
+ function cr({ active: e, children: t, keepMounted: n = !1, className: r = "", style: o }) {
1301
+ const i = yt.toArray(t).filter(
1302
+ (a) => xt(a) && (a.type === Dt || a.type.displayName === "TabPanel")
1274
1303
  );
1275
1304
  if (n)
1276
- return /* @__PURE__ */ s("div", { className: `nc-tab-panels ${r}`, style: o, children: i.map((c) => {
1277
- const l = c.props.tab === e;
1305
+ return /* @__PURE__ */ s("div", { className: `nc-tab-panels ${r}`, style: o, children: i.map((a) => {
1306
+ const l = a.props.tab === e;
1278
1307
  return /* @__PURE__ */ s(
1279
1308
  "div",
1280
1309
  {
1281
1310
  className: `nc-tab-panel-wrapper ${l ? "nc-active" : ""}`,
1282
1311
  style: { display: l ? void 0 : "none" },
1283
1312
  "aria-hidden": !l,
1284
- children: c
1313
+ children: a
1285
1314
  },
1286
- c.props.tab
1315
+ a.props.tab
1287
1316
  );
1288
1317
  }) });
1289
- const a = i.find((c) => c.props.tab === e);
1290
- return /* @__PURE__ */ s("div", { className: `nc-tab-panels ${r}`, style: o, children: a });
1318
+ const c = i.find((a) => a.props.tab === e);
1319
+ return /* @__PURE__ */ s("div", { className: `nc-tab-panels ${r}`, style: o, children: c });
1291
1320
  }
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);
1321
+ function ar({ tabs: e, active: t, onChange: n, onClose: r, permanentTabs: o, className: i, toolbar: c, multiline: a, orientation: l = "horizontal", style: u }) {
1322
+ const f = V(null), [v, d] = R(!1), [m, w] = R(!1), y = l === "verticalLeft" || l === "verticalRight", g = V(!1), N = V(0), b = V(0), p = V(!1);
1294
1323
  B(() => {
1295
1324
  const x = () => {
1296
1325
  if (f.current)
1297
- if (g) {
1298
- const { scrollTop: S, scrollHeight: $, clientHeight: P } = f.current;
1299
- d(S > 1), y(S < $ - P - 1);
1326
+ if (y) {
1327
+ const { scrollTop: S, scrollHeight: $, clientHeight: z } = f.current;
1328
+ d(S > 1), w(S < $ - z - 1);
1300
1329
  } else {
1301
- const { scrollLeft: S, scrollWidth: $, clientWidth: P } = f.current;
1302
- d(S > 1), y(S < $ - P - 1);
1330
+ const { scrollLeft: S, scrollWidth: $, clientWidth: z } = f.current;
1331
+ d(S > 1), w(S < $ - z - 1);
1303
1332
  }
1304
- }, R = f.current;
1305
- if (R)
1306
- return x(), R.addEventListener("scroll", x), window.addEventListener("resize", x), () => {
1307
- R.removeEventListener("scroll", x), window.removeEventListener("resize", x);
1333
+ }, I = f.current;
1334
+ if (I)
1335
+ return x(), I.addEventListener("scroll", x), window.addEventListener("resize", x), () => {
1336
+ I.removeEventListener("scroll", x), window.removeEventListener("resize", x);
1308
1337
  };
1309
- }, [e, g]);
1338
+ }, [e, y]);
1310
1339
  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");
1312
- }, N = (x) => {
1313
- if (!w.current || !f.current) return;
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;
1340
+ f.current && (g.current = !0, p.current = !1, N.current = y ? x.clientY : x.clientX, b.current = y ? f.current.scrollTop : f.current.scrollLeft, f.current.style.cursor = "grabbing", f.current.style.userSelect = "none");
1341
+ }, A = (x) => {
1342
+ if (!g.current || !f.current) return;
1343
+ const I = y ? x.clientY : x.clientX, S = N.current - I;
1344
+ Math.abs(S) > 3 && (p.current = !0), y ? f.current.scrollTop = b.current + S : f.current.scrollLeft = b.current + S;
1316
1345
  }, C = () => {
1317
- f.current && (w.current = !1, f.current.style.cursor = "", f.current.style.userSelect = "");
1318
- }, z = () => {
1346
+ f.current && (g.current = !1, f.current.style.cursor = "", f.current.style.userSelect = "");
1347
+ }, T = () => {
1319
1348
  C();
1320
1349
  };
1321
1350
  B(() => {
1322
1351
  const x = f.current;
1323
- if (!x || g) return;
1324
- const R = (S) => {
1352
+ if (!x || y) return;
1353
+ const I = (S) => {
1325
1354
  S.deltaY !== 0 && (S.preventDefault(), x.scrollLeft += S.deltaY * 0.3);
1326
1355
  };
1327
- return x.addEventListener("wheel", R, { passive: !1 }), () => {
1328
- x.removeEventListener("wheel", R);
1356
+ return x.addEventListener("wheel", I, { passive: !1 }), () => {
1357
+ x.removeEventListener("wheel", I);
1329
1358
  };
1330
- }, [g]);
1331
- const T = (x) => {
1359
+ }, [y]);
1360
+ const L = (x) => {
1332
1361
  p.current || n(x);
1333
1362
  };
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: [
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 }) }),
1363
+ return /* @__PURE__ */ k("div", { className: `nc-tab-container ${y ? `nc-vertical nc-${l}` : ""} ${i || ""}`, style: u, children: [
1364
+ /* @__PURE__ */ k("div", { className: "nc-tab-scroll-wrapper", children: [
1365
+ v && /* @__PURE__ */ s("div", { className: `nc-tab-scroll-indicator ${y ? "nc-top" : "nc-left"}`, children: y ? /* @__PURE__ */ s(Bt, { size: 16 }) : /* @__PURE__ */ s(bt, { size: 16 }) }),
1337
1366
  /* @__PURE__ */ s(
1338
1367
  "div",
1339
1368
  {
1340
1369
  ref: f,
1341
- className: `nc-tab-scroll ${c ? "nc-multiline" : ""}`,
1370
+ className: `nc-tab-scroll ${a ? "nc-multiline" : ""}`,
1342
1371
  onMouseDown: h,
1343
- onMouseMove: N,
1372
+ onMouseMove: A,
1344
1373
  onMouseUp: C,
1345
- onMouseLeave: z,
1374
+ onMouseLeave: T,
1346
1375
  style: { cursor: "grab" },
1347
1376
  children: e.map((x) => {
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(
1377
+ const I = typeof x == "string" ? x : x.id, S = typeof x == "string" ? x : x.label, $ = r && !(o != null && o.includes(I));
1378
+ return /* @__PURE__ */ k(
1350
1379
  "div",
1351
1380
  {
1352
- className: `nc-tab-item ${t === R ? "nc-active" : ""} ${$ ? "nc-closable" : ""}`,
1353
- onClick: () => T(R),
1381
+ className: `nc-tab-item ${t === I ? "nc-active" : ""} ${$ ? "nc-closable" : ""}`,
1382
+ onClick: () => L(I),
1354
1383
  role: "button",
1355
1384
  tabIndex: 0,
1356
- onKeyDown: (P) => {
1357
- (P.key === "Enter" || P.key === " ") && n(R);
1385
+ onKeyDown: (z) => {
1386
+ (z.key === "Enter" || z.key === " ") && n(I);
1358
1387
  },
1359
1388
  children: [
1360
- /* @__PURE__ */ s("span", { className: "nc-tab-label", children: g ? S : typeof S == "string" ? S.toUpperCase() : S }),
1389
+ /* @__PURE__ */ s("span", { className: "nc-tab-label", children: y ? S : typeof S == "string" ? S.toUpperCase() : S }),
1361
1390
  $ && /* @__PURE__ */ s(
1362
1391
  "span",
1363
1392
  {
1364
1393
  className: "nc-tab-close",
1365
1394
  role: "button",
1366
1395
  tabIndex: 0,
1367
- "aria-label": `Close ${typeof S == "string" ? S : R}`,
1368
- onClick: (P) => {
1369
- P.stopPropagation(), r(R);
1396
+ "aria-label": `Close ${typeof S == "string" ? S : I}`,
1397
+ onClick: (z) => {
1398
+ z.stopPropagation(), r(I);
1370
1399
  },
1371
- onKeyDown: (P) => {
1372
- (P.key === "Enter" || P.key === " ") && (P.stopPropagation(), r(R));
1400
+ onKeyDown: (z) => {
1401
+ (z.key === "Enter" || z.key === " ") && (z.stopPropagation(), r(I));
1373
1402
  },
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: [
1403
+ children: /* @__PURE__ */ k("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", children: [
1375
1404
  /* @__PURE__ */ s("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
1376
1405
  /* @__PURE__ */ s("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
1377
1406
  ] })
@@ -1379,18 +1408,18 @@ function Jn({ tabs: e, active: t, onChange: n, onClose: r, permanentTabs: o, cla
1379
1408
  )
1380
1409
  ]
1381
1410
  },
1382
- R
1411
+ I
1383
1412
  );
1384
1413
  })
1385
1414
  }
1386
1415
  ),
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 }) })
1416
+ m && /* @__PURE__ */ s("div", { className: `nc-tab-scroll-indicator ${y ? "nc-bottom" : "nc-right"}`, children: y ? /* @__PURE__ */ s(vt, { size: 16 }) : /* @__PURE__ */ s(wt, { size: 16 }) })
1388
1417
  ] }),
1389
- a && /* @__PURE__ */ s("div", { className: "nc-tab-toolbar", children: a })
1418
+ c && /* @__PURE__ */ s("div", { className: "nc-tab-toolbar", children: c })
1390
1419
  ] });
1391
1420
  }
1392
- function Qn({ checked: e, onChange: t, disabled: n, label: r }) {
1393
- return /* @__PURE__ */ A(
1421
+ function lr({ checked: e, onChange: t, disabled: n, label: r }) {
1422
+ return /* @__PURE__ */ k(
1394
1423
  "label",
1395
1424
  {
1396
1425
  className: "nc-row",
@@ -1441,7 +1470,7 @@ function Qn({ checked: e, onChange: t, disabled: n, label: r }) {
1441
1470
  }
1442
1471
  );
1443
1472
  }
1444
- const ze = [
1473
+ const Oe = [
1445
1474
  "var(--nc-csv-col-0)",
1446
1475
  "var(--nc-csv-col-1)",
1447
1476
  "var(--nc-csv-col-2)",
@@ -1453,24 +1482,24 @@ const ze = [
1453
1482
  "var(--nc-csv-col-8)",
1454
1483
  "var(--nc-csv-col-9)"
1455
1484
  ];
1456
- function Mt(e, t) {
1485
+ function Wt(e, t) {
1457
1486
  const r = e.slice(0, t).split(`
1458
- `), o = r.length, a = r[o - 1].split(" "), c = a.length, l = a[c - 1].length + 1;
1459
- return { line: o, column: c, character: l, offset: t };
1487
+ `), o = r.length, c = r[o - 1].split(" "), a = c.length, l = c[a - 1].length + 1;
1488
+ return { line: o, column: a, character: l, offset: t };
1460
1489
  }
1461
- function Rt(e, t, n, r) {
1490
+ function Ht(e, t, n, r) {
1462
1491
  const o = e.split(`
1463
1492
  `), i = Math.max(1, Math.min(t, o.length));
1464
- let a = 0;
1493
+ let c = 0;
1465
1494
  for (let v = 0; v < i - 1; v++)
1466
- a += o[v].length + 1;
1495
+ c += o[v].length + 1;
1467
1496
  const l = o[i - 1].split(" "), u = Math.max(1, Math.min(n, l.length));
1468
1497
  for (let v = 0; v < u - 1; v++)
1469
- a += l[v].length + 1;
1498
+ c += l[v].length + 1;
1470
1499
  const f = Math.max(1, Math.min(r, l[u - 1].length + 1));
1471
- return a += f - 1, a;
1500
+ return c += f - 1, c;
1472
1501
  }
1473
- function Et(e, t) {
1502
+ function Vt(e, t) {
1474
1503
  const n = e.split(`
1475
1504
  `), r = Math.max(1, Math.min(t, n.length));
1476
1505
  let o = 0;
@@ -1478,32 +1507,32 @@ function Et(e, t) {
1478
1507
  o += n[i].length + 1;
1479
1508
  return o;
1480
1509
  }
1481
- const Zn = ft(
1482
- function({ value: t, onChange: n, placeholder: r, className: o, style: i, showLineNumbers: a = !1, onCursorChange: c, highlightLine: l }, u) {
1483
- const f = W(null), v = W(null), d = W(null);
1484
- ht(u, () => ({
1510
+ const dr = kt(
1511
+ function({ value: t, onChange: n, placeholder: r, className: o, style: i, showLineNumbers: c = !1, onCursorChange: a, highlightLine: l }, u) {
1512
+ const f = V(null), v = V(null), d = V(null);
1513
+ Nt(u, () => ({
1485
1514
  goToLine(b) {
1486
1515
  const p = f.current;
1487
1516
  if (!p) return;
1488
- const h = Et(t, b);
1517
+ const h = Vt(t, b);
1489
1518
  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();
1519
+ const A = parseFloat(getComputedStyle(p).lineHeight) || 18;
1520
+ p.scrollTop = (Math.max(1, b) - 1) * A, w(), m();
1492
1521
  },
1493
1522
  goToPosition(b, p, h) {
1494
- const N = f.current;
1495
- if (!N) return;
1496
- const C = Rt(t, b, p, h);
1497
- N.focus(), N.setSelectionRange(C, C);
1498
- const z = parseFloat(getComputedStyle(N).lineHeight) || 18;
1499
- N.scrollTop = (Math.max(1, b) - 1) * z, y(), m();
1523
+ const A = f.current;
1524
+ if (!A) return;
1525
+ const C = Ht(t, b, p, h);
1526
+ A.focus(), A.setSelectionRange(C, C);
1527
+ const T = parseFloat(getComputedStyle(A).lineHeight) || 18;
1528
+ A.scrollTop = (Math.max(1, b) - 1) * T, w(), m();
1500
1529
  }
1501
1530
  }), [t]);
1502
1531
  const m = O(() => {
1503
- if (!c || !f.current) return;
1504
- const b = Mt(t, f.current.selectionStart);
1505
- c(b);
1506
- }, [c, t]), y = O(() => {
1532
+ if (!a || !f.current) return;
1533
+ const b = Wt(t, f.current.selectionStart);
1534
+ a(b);
1535
+ }, [a, t]), w = O(() => {
1507
1536
  const b = f.current;
1508
1537
  b && (v.current && (v.current.scrollTop = b.scrollTop, v.current.scrollLeft = b.scrollLeft), d.current && (d.current.scrollTop = b.scrollTop));
1509
1538
  }, []);
@@ -1511,33 +1540,33 @@ const Zn = ft(
1511
1540
  if (l == null || l < 1) return;
1512
1541
  const b = f.current;
1513
1542
  if (!b) return;
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();
1543
+ const p = parseFloat(getComputedStyle(b).lineHeight) || 18, h = (l - 1) * p, A = h + p;
1544
+ (h < b.scrollTop || A > b.scrollTop + b.clientHeight) && (b.scrollTop = h - b.clientHeight / 2 + p / 2), w();
1516
1545
  }, [l]);
1517
- const g = me(() => t.split(`
1518
- `).length, [t]), w = () => {
1546
+ const y = we(() => t.split(`
1547
+ `).length, [t]), g = () => {
1519
1548
  const b = [];
1520
- for (let p = 1; p <= g; p++)
1549
+ for (let p = 1; p <= y; p++)
1521
1550
  b.push(
1522
1551
  /* @__PURE__ */ s("div", { className: `nc-csv-line-number ${l === p ? "nc-csv-highlight" : ""}`, children: p }, p)
1523
1552
  );
1524
1553
  return /* @__PURE__ */ s("div", { className: "nc-csv-gutter", ref: d, children: b });
1525
- }, k = (b) => b ? b.split(`
1526
- `).map((h, N) => {
1554
+ }, N = (b) => b ? b.split(`
1555
+ `).map((h, A) => {
1527
1556
  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: [
1530
- T > 0 && /* @__PURE__ */ s("span", { className: "nc-csv-tab-char", children: " " }),
1531
- /* @__PURE__ */ s("span", { style: { color: ze[T % ze.length] }, children: z })
1532
- ] }, T)),
1557
+ return /* @__PURE__ */ k("div", { className: `nc-csv-line ${l === A + 1 ? "nc-csv-highlight" : ""}`, children: [
1558
+ C.map((T, L) => /* @__PURE__ */ k("span", { children: [
1559
+ L > 0 && /* @__PURE__ */ s("span", { className: "nc-csv-tab-char", children: " " }),
1560
+ /* @__PURE__ */ s("span", { style: { color: Oe[L % Oe.length] }, children: T })
1561
+ ] }, L)),
1533
1562
  h === "" && `
1534
1563
  `
1535
- ] }, N);
1564
+ ] }, A);
1536
1565
  }) : null;
1537
- return /* @__PURE__ */ A("div", { className: `nc-csv-textarea-container ${a ? "nc-csv-with-gutter" : ""} ${o ?? ""}`, style: i, children: [
1538
- a && w(),
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) }) }),
1566
+ return /* @__PURE__ */ k("div", { className: `nc-csv-textarea-container ${c ? "nc-csv-with-gutter" : ""} ${o ?? ""}`, style: i, children: [
1567
+ c && g(),
1568
+ /* @__PURE__ */ k("div", { className: "nc-csv-textarea-editor", children: [
1569
+ /* @__PURE__ */ s("div", { className: "nc-csv-textarea-backdrop", ref: v, children: /* @__PURE__ */ s("pre", { className: "nc-csv-textarea-highlights", children: N(t) }) }),
1541
1570
  /* @__PURE__ */ s(
1542
1571
  "textarea",
1543
1572
  {
@@ -1547,7 +1576,7 @@ const Zn = ft(
1547
1576
  onChange: (b) => {
1548
1577
  n(b.target.value), requestAnimationFrame(m);
1549
1578
  },
1550
- onScroll: y,
1579
+ onScroll: w,
1551
1580
  onSelect: m,
1552
1581
  onKeyUp: m,
1553
1582
  onClick: m,
@@ -1561,27 +1590,27 @@ const Zn = ft(
1561
1590
  ] });
1562
1591
  }
1563
1592
  );
1564
- let ee = { notifications: [] };
1565
- const ve = /* @__PURE__ */ new Set(), Pe = /* @__PURE__ */ new Map();
1566
- function we() {
1567
- const e = ee.notifications.slice();
1568
- for (const t of Array.from(ve))
1593
+ let ne = { notifications: [] };
1594
+ const Ne = /* @__PURE__ */ new Set(), Fe = /* @__PURE__ */ new Map();
1595
+ function Ae() {
1596
+ const e = ne.notifications.slice();
1597
+ for (const t of Array.from(Ne))
1569
1598
  try {
1570
1599
  t(e);
1571
1600
  } catch {
1572
1601
  }
1573
1602
  }
1574
- function Tt(e) {
1575
- ve.add(e);
1603
+ function Ot(e) {
1604
+ Ne.add(e);
1576
1605
  try {
1577
- e(ee.notifications.slice());
1606
+ e(ne.notifications.slice());
1578
1607
  } catch {
1579
1608
  }
1580
1609
  return () => {
1581
- ve.delete(e);
1610
+ Ne.delete(e);
1582
1611
  };
1583
1612
  }
1584
- function zt(e) {
1613
+ function Ft(e) {
1585
1614
  const t = `notification-${Date.now()}-${Math.random()}`, { duration: n, type: r, ...o } = e, i = {
1586
1615
  id: t,
1587
1616
  dismissible: !0,
@@ -1589,23 +1618,64 @@ function zt(e) {
1589
1618
  type: r === "error" ? "danger" : r ?? "info",
1590
1619
  duration: n ?? 5e3
1591
1620
  };
1592
- return ee.notifications = [i, ...ee.notifications], we(), i.duration && i.duration > 0 && setTimeout(() => {
1593
- Fe(t);
1621
+ return ne.notifications = [i, ...ne.notifications], Ae(), i.duration && i.duration > 0 && setTimeout(() => {
1622
+ qe(t);
1594
1623
  }, i.duration), t;
1595
1624
  }
1596
- function Fe(e) {
1597
- const t = ee.notifications.find((r) => r.id === e);
1625
+ function qe(e) {
1626
+ const t = ne.notifications.find((r) => r.id === e);
1598
1627
  if (!t) return;
1599
- t.isRemoving = !0, we();
1628
+ t.isRemoving = !0, Ae();
1600
1629
  const n = window.setTimeout(() => {
1601
- ee.notifications = ee.notifications.filter((r) => r.id !== e), we(), Pe.delete(e);
1630
+ ne.notifications = ne.notifications.filter((r) => r.id !== e), Ae(), Fe.delete(e);
1602
1631
  }, 300);
1603
- Pe.set(e, n);
1632
+ Fe.set(e, n);
1633
+ }
1634
+ function jt({ type: e }) {
1635
+ switch (e) {
1636
+ case "success":
1637
+ return /* @__PURE__ */ s("svg", { viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ s(
1638
+ "path",
1639
+ {
1640
+ d: "M5 10.5l3.1 3.1L15 6.8",
1641
+ stroke: "currentColor",
1642
+ strokeWidth: "2",
1643
+ strokeLinecap: "round",
1644
+ strokeLinejoin: "round"
1645
+ }
1646
+ ) });
1647
+ case "danger":
1648
+ return /* @__PURE__ */ k("svg", { viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: [
1649
+ /* @__PURE__ */ s("circle", { cx: "10", cy: "10", r: "7", stroke: "currentColor", strokeWidth: "2" }),
1650
+ /* @__PURE__ */ s("path", { d: "M10 6.5v4.25", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }),
1651
+ /* @__PURE__ */ s("circle", { cx: "10", cy: "13.75", r: "1", fill: "currentColor" })
1652
+ ] });
1653
+ case "warning":
1654
+ return /* @__PURE__ */ k("svg", { viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: [
1655
+ /* @__PURE__ */ s(
1656
+ "path",
1657
+ {
1658
+ d: "M10 3.5 16 15H4L10 3.5Z",
1659
+ stroke: "currentColor",
1660
+ strokeWidth: "2",
1661
+ strokeLinejoin: "round"
1662
+ }
1663
+ ),
1664
+ /* @__PURE__ */ s("path", { d: "M10 7.5v3.5", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }),
1665
+ /* @__PURE__ */ s("circle", { cx: "10", cy: "13.25", r: "1", fill: "currentColor" })
1666
+ ] });
1667
+ default:
1668
+ return /* @__PURE__ */ k("svg", { viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: [
1669
+ /* @__PURE__ */ s("circle", { cx: "10", cy: "10", r: "7", stroke: "currentColor", strokeWidth: "2" }),
1670
+ /* @__PURE__ */ s("path", { d: "M10 9v4", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }),
1671
+ /* @__PURE__ */ s("circle", { cx: "10", cy: "6.5", r: "1", fill: "currentColor" })
1672
+ ] });
1673
+ }
1604
1674
  }
1605
- function Pt({ notification: e }) {
1606
- const { t } = U(), n = () => {
1675
+ function Gt({ notification: e }) {
1676
+ const { t } = X(), n = e.type || "info", r = () => {
1607
1677
  if (e.title) return e.title;
1608
- switch (e.type) {
1678
+ switch (n) {
1609
1679
  case "success":
1610
1680
  return t("common.success");
1611
1681
  case "danger":
@@ -1615,44 +1685,46 @@ function Pt({ notification: e }) {
1615
1685
  default:
1616
1686
  return t("common.info");
1617
1687
  }
1618
- }, r = () => {
1619
- Fe(e.id);
1688
+ }, o = () => {
1689
+ qe(e.id);
1620
1690
  };
1621
1691
  return /* @__PURE__ */ s(
1622
1692
  "div",
1623
1693
  {
1624
- className: `nc-notification nc-notification-${e.type || "info"}`,
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: [
1627
- /* @__PURE__ */ s("div", { className: "nc-notification-title", children: n() }),
1694
+ className: `nc-notification nc-notification-${n}`,
1695
+ children: /* @__PURE__ */ k("div", { className: "nc-notification-content", children: [
1696
+ /* @__PURE__ */ s("div", { className: `nc-notification-icon nc-notification-icon-${n}`, children: /* @__PURE__ */ s(jt, { type: n }) }),
1697
+ /* @__PURE__ */ k("div", { className: "nc-notification-body", children: [
1698
+ /* @__PURE__ */ s("div", { className: "nc-notification-title", children: r() }),
1628
1699
  /* @__PURE__ */ s("div", { className: "nc-notification-message", children: e.message })
1629
1700
  ] }),
1630
1701
  e.dismissible && /* @__PURE__ */ s(
1631
1702
  "button",
1632
1703
  {
1633
1704
  className: "nc-notification-dismiss",
1634
- onClick: r,
1635
- children: /* @__PURE__ */ s(xe, { size: 16 })
1705
+ onClick: o,
1706
+ "aria-label": t("common.close"),
1707
+ children: /* @__PURE__ */ s(Ce, { size: 16 })
1636
1708
  }
1637
1709
  )
1638
1710
  ] })
1639
1711
  }
1640
1712
  );
1641
1713
  }
1642
- function er() {
1643
- const [e, t] = E([]), [n, r] = E(/* @__PURE__ */ new Map()), [o, i] = E(/* @__PURE__ */ new Set()), a = W(null), c = W([]);
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);
1714
+ function ur() {
1715
+ const [e, t] = R([]), [n, r] = R(/* @__PURE__ */ new Map()), [o, i] = R(/* @__PURE__ */ new Set()), c = V(null), a = V([]);
1716
+ return B(() => Ot((u) => {
1717
+ const f = new Set(a.current.map((d) => d.id)), v = u.filter((d) => !f.has(d.id)).map((d) => d.id);
1646
1718
  v.length > 0 ? (t(u), i(new Set(v)), requestAnimationFrame(() => {
1647
1719
  requestAnimationFrame(() => {
1648
1720
  i(/* @__PURE__ */ new Set());
1649
1721
  });
1650
- })) : t(u), c.current = u;
1722
+ })) : t(u), a.current = u;
1651
1723
  }), []), B(() => {
1652
- if (!a.current) return;
1724
+ if (!c.current) return;
1653
1725
  const l = /* @__PURE__ */ new Map();
1654
1726
  let u = 0;
1655
- const f = a.current.children;
1727
+ const f = c.current.children;
1656
1728
  e.forEach((v, d) => {
1657
1729
  if (l.set(v.id, u), f[d]) {
1658
1730
  const m = f[d].offsetHeight;
@@ -1664,18 +1736,20 @@ function er() {
1664
1736
  {
1665
1737
  style: {
1666
1738
  position: "fixed",
1667
- top: "16px",
1668
- left: "16px",
1739
+ top: "24px",
1740
+ left: "24px",
1669
1741
  zIndex: 9999,
1670
- pointerEvents: "none"
1742
+ pointerEvents: "none",
1743
+ width: "min(340px, calc(100vw - 32px))"
1671
1744
  },
1672
1745
  children: /* @__PURE__ */ s(
1673
1746
  "div",
1674
1747
  {
1675
- ref: a,
1748
+ ref: c,
1676
1749
  style: {
1677
1750
  pointerEvents: "auto",
1678
- position: "relative"
1751
+ position: "relative",
1752
+ width: "100%"
1679
1753
  },
1680
1754
  children: e.map((l) => {
1681
1755
  const u = o.has(l.id), f = l.isRemoving, v = n.get(l.id) || 0;
@@ -1686,13 +1760,13 @@ function er() {
1686
1760
  position: "absolute",
1687
1761
  top: 0,
1688
1762
  left: 0,
1689
- transform: u ? "translateY(-120px)" : `translateY(${v}px)`,
1763
+ transform: u ? `translate3d(-40px, ${v}px, 0)` : `translate3d(0, ${v}px, 0)`,
1690
1764
  // Only animate transform when not leaving, animate opacity always
1691
1765
  transition: f ? "opacity 300ms ease-out" : "transform 300ms ease-out, opacity 300ms ease-out",
1692
1766
  opacity: f ? 0 : 1,
1693
1767
  width: "100%"
1694
1768
  },
1695
- children: /* @__PURE__ */ s(Pt, { notification: l })
1769
+ children: /* @__PURE__ */ s(Gt, { notification: l })
1696
1770
  },
1697
1771
  l.id
1698
1772
  );
@@ -1702,14 +1776,14 @@ function er() {
1702
1776
  }
1703
1777
  );
1704
1778
  }
1705
- function Lt(e) {
1706
- return zt(e);
1779
+ function Yt(e) {
1780
+ return Ft(e);
1707
1781
  }
1708
- const tr = {
1709
- show: (e) => Lt(e)
1782
+ const pr = {
1783
+ show: (e) => Yt(e)
1710
1784
  };
1711
- function nr(e) {
1712
- const t = bt.createInstance(), n = {};
1785
+ function fr(e) {
1786
+ const t = St.createInstance(), n = {};
1713
1787
  for (const o in e)
1714
1788
  n[o] = { translation: e[o] };
1715
1789
  const r = typeof document < "u" && document.documentElement.lang || "en";
@@ -1722,16 +1796,16 @@ function nr(e) {
1722
1796
  // React already escapes by default
1723
1797
  }
1724
1798
  }), typeof MutationObserver < "u" && typeof document < "u" && new MutationObserver((i) => {
1725
- for (const a of i)
1726
- if (a.type === "attributes" && a.attributeName === "lang") {
1727
- const c = document.documentElement.lang || "en";
1728
- t.changeLanguage(c);
1799
+ for (const c of i)
1800
+ if (c.type === "attributes" && c.attributeName === "lang") {
1801
+ const a = document.documentElement.lang || "en";
1802
+ t.changeLanguage(a);
1729
1803
  }
1730
1804
  }).observe(document.documentElement, { attributes: !0 }), t;
1731
1805
  }
1732
- class Bt {
1806
+ class Kt {
1733
1807
  constructor() {
1734
- q(this, "apps", /* @__PURE__ */ new Map());
1808
+ Z(this, "apps", /* @__PURE__ */ new Map());
1735
1809
  }
1736
1810
  /**
1737
1811
  * Register an app definition.
@@ -1769,16 +1843,16 @@ class Bt {
1769
1843
  return this.apps.has(t);
1770
1844
  }
1771
1845
  }
1772
- const oe = new Bt(), Le = "nc-ui-app-state";
1773
- class Dt {
1846
+ const ie = new Kt(), je = "nc-ui-app-state";
1847
+ class _t {
1774
1848
  constructor() {
1775
- q(this, "state");
1776
- q(this, "listeners", /* @__PURE__ */ new Map());
1849
+ Z(this, "state");
1850
+ Z(this, "listeners", /* @__PURE__ */ new Map());
1777
1851
  this.state = this.loadState();
1778
1852
  }
1779
1853
  loadState() {
1780
1854
  try {
1781
- const t = localStorage.getItem(Le);
1855
+ const t = localStorage.getItem(je);
1782
1856
  if (t)
1783
1857
  return JSON.parse(t);
1784
1858
  } catch {
@@ -1787,7 +1861,7 @@ class Dt {
1787
1861
  }
1788
1862
  saveState() {
1789
1863
  try {
1790
- localStorage.setItem(Le, JSON.stringify(this.state));
1864
+ localStorage.setItem(je, JSON.stringify(this.state));
1791
1865
  } catch {
1792
1866
  }
1793
1867
  }
@@ -1817,13 +1891,13 @@ class Dt {
1817
1891
  (r = this.listeners.get(t)) == null || r.forEach((o) => o(n));
1818
1892
  }
1819
1893
  }
1820
- const _ = new Dt();
1821
- class Ht {
1894
+ const q = new _t();
1895
+ class Ut {
1822
1896
  constructor() {
1823
- q(this, "apps", []);
1824
- q(this, "activeAppId", null);
1825
- q(this, "listeners", /* @__PURE__ */ new Set());
1826
- q(this, "refReadyResolvers", /* @__PURE__ */ new Map());
1897
+ Z(this, "apps", []);
1898
+ Z(this, "activeAppId", null);
1899
+ Z(this, "listeners", /* @__PURE__ */ new Set());
1900
+ Z(this, "refReadyResolvers", /* @__PURE__ */ new Map());
1827
1901
  }
1828
1902
  /**
1829
1903
  * Launch an app and wait for it to be ready (ref populated).
@@ -1835,16 +1909,16 @@ class Ht {
1835
1909
  */
1836
1910
  async launchApp(t, n) {
1837
1911
  const { launchInBackground: r = !1 } = n || {};
1838
- if (!oe.has(t))
1912
+ if (!ie.has(t))
1839
1913
  return console.error(`Cannot launch app "${t}": not registered`), null;
1840
- const o = this.apps.find((a) => a.appId === t);
1914
+ const o = this.apps.find((c) => c.appId === t);
1841
1915
  if (o)
1842
- return r || (this.setActiveApp(t), _._setActiveAppId(t)), o.ref ? o : this.waitForRef(t);
1916
+ return r || (this.setActiveApp(t), q._setActiveAppId(t)), o.ref ? o : this.waitForRef(t);
1843
1917
  const i = {
1844
1918
  appId: t,
1845
1919
  launchedAt: Date.now()
1846
1920
  };
1847
- return this.apps.push(i), r || (this.activeAppId = t, _._setActiveAppId(t)), this.notify(), this.waitForRef(t);
1921
+ return this.apps.push(i), r || (this.activeAppId = t, q._setActiveAppId(t)), this.notify(), this.waitForRef(t);
1848
1922
  }
1849
1923
  waitForRef(t) {
1850
1924
  return new Promise((n) => {
@@ -1881,7 +1955,7 @@ class Ht {
1881
1955
  const r = this.apps[n];
1882
1956
  if (r.ref && (r.ref = void 0), this.apps.splice(n, 1), this.activeAppId === t) {
1883
1957
  const o = window.innerWidth >= 768;
1884
- this.activeAppId = o && this.apps.length > 0 ? this.apps[this.apps.length - 1].appId : null, _._setActiveAppId(this.activeAppId);
1958
+ this.activeAppId = o && this.apps.length > 0 ? this.apps[this.apps.length - 1].appId : null, q._setActiveAppId(this.activeAppId);
1885
1959
  }
1886
1960
  this.notify();
1887
1961
  }
@@ -1893,7 +1967,7 @@ class Ht {
1893
1967
  console.warn(`Cannot activate app "${t}": not running`);
1894
1968
  return;
1895
1969
  }
1896
- this.activeAppId !== t && (this.activeAppId = t, this.notify(), _._setActiveAppId(t));
1970
+ this.activeAppId !== t && (this.activeAppId = t, this.notify(), q._setActiveAppId(t));
1897
1971
  }
1898
1972
  /**
1899
1973
  * Toggle an app: if active, deactivate; if inactive, activate.
@@ -1911,7 +1985,7 @@ class Ht {
1911
1985
  * Get the currently active app definition.
1912
1986
  */
1913
1987
  getActiveApp() {
1914
- return this.activeAppId ? oe.get(this.activeAppId) ?? null : null;
1988
+ return this.activeAppId ? ie.get(this.activeAppId) ?? null : null;
1915
1989
  }
1916
1990
  /**
1917
1991
  * Get all running apps.
@@ -1937,15 +2011,15 @@ class Ht {
1937
2011
  this.listeners.forEach((t) => t());
1938
2012
  }
1939
2013
  }
1940
- const G = new Ht(), Ve = se(null);
1941
- function Wt() {
1942
- const e = Q(Ve);
2014
+ const Y = new Ut(), Xe = ce(null);
2015
+ function qt() {
2016
+ const e = te(Xe);
1943
2017
  if (!e)
1944
2018
  throw new Error("useApp must be used inside an App");
1945
2019
  return e;
1946
2020
  }
1947
- function Ot({ size: e = 16 }) {
1948
- return /* @__PURE__ */ A(
2021
+ function Xt({ size: e = 16 }) {
2022
+ return /* @__PURE__ */ k(
1949
2023
  "svg",
1950
2024
  {
1951
2025
  width: e,
@@ -1963,9 +2037,9 @@ function Ot({ size: e = 16 }) {
1963
2037
  }
1964
2038
  );
1965
2039
  }
1966
- function Ft({ title: e, onClose: t, onBack: n, toolbar: r, hideBackButton: o }) {
1967
- return /* @__PURE__ */ A("div", { className: "nc-app-title-bar", children: [
1968
- /* @__PURE__ */ A("div", { className: "nc-app-title-bar-left", children: [
2040
+ function Jt({ title: e, onClose: t, onBack: n, toolbar: r, hideBackButton: o }) {
2041
+ return /* @__PURE__ */ k("div", { className: "nc-app-title-bar", children: [
2042
+ /* @__PURE__ */ k("div", { className: "nc-app-title-bar-left", children: [
1969
2043
  n && !o && /* @__PURE__ */ s(
1970
2044
  "button",
1971
2045
  {
@@ -1973,18 +2047,18 @@ function Ft({ title: e, onClose: t, onBack: n, toolbar: r, hideBackButton: o })
1973
2047
  onClick: n,
1974
2048
  title: "Back",
1975
2049
  "aria-label": "Go back",
1976
- children: /* @__PURE__ */ s(Ot, { size: 16 })
2050
+ children: /* @__PURE__ */ s(Xt, { size: 16 })
1977
2051
  }
1978
2052
  ),
1979
2053
  /* @__PURE__ */ s("span", { className: "nc-app-title-bar-title", children: e })
1980
2054
  ] }),
1981
- /* @__PURE__ */ A("div", { className: "nc-app-title-bar-right", children: [
2055
+ /* @__PURE__ */ k("div", { className: "nc-app-title-bar-right", children: [
1982
2056
  r && /* @__PURE__ */ s("div", { className: "nc-app-title-bar-toolbar", children: r }),
1983
- /* @__PURE__ */ s(We, { onClick: t, "aria-label": "Close application" })
2057
+ /* @__PURE__ */ s(_e, { onClick: t, "aria-label": "Close application" })
1984
2058
  ] })
1985
2059
  ] });
1986
2060
  }
1987
- class Vt extends ke.Component {
2061
+ class Zt extends $e.Component {
1988
2062
  constructor(t) {
1989
2063
  super(t), this.state = { hasError: !1 };
1990
2064
  }
@@ -1995,7 +2069,7 @@ class Vt extends ke.Component {
1995
2069
  console.error(`Error loading app ${this.props.appId}:`, t, n);
1996
2070
  }
1997
2071
  render() {
1998
- return this.state.hasError ? /* @__PURE__ */ A(
2072
+ return this.state.hasError ? /* @__PURE__ */ k(
1999
2073
  "div",
2000
2074
  {
2001
2075
  style: {
@@ -2017,16 +2091,16 @@ class Vt extends ke.Component {
2017
2091
  ) : this.props.children;
2018
2092
  }
2019
2093
  }
2020
- function Ye({ appId: e, isActive: t, onClose: n }) {
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);
2022
- ke.useEffect(() => {
2023
- o != null && o.titleKey && a(r(o.titleKey));
2094
+ function Je({ appId: e, isActive: t, onClose: n }) {
2095
+ const { t: r } = X(), o = ie.get(e), [i, c] = R(""), [a, l] = R(null), [u, f] = R(null), [v, d] = R(!1), [m, w] = R(!1);
2096
+ $e.useEffect(() => {
2097
+ o != null && o.titleKey && c(r(o.titleKey));
2024
2098
  }, [o, r]);
2025
- const g = O((x) => {
2026
- a(x);
2027
- }, []), w = O((x) => {
2099
+ const y = O((x) => {
2100
+ c(x);
2101
+ }, []), g = O((x) => {
2028
2102
  l(() => x);
2029
- }, []), k = O(() => {
2103
+ }, []), N = O(() => {
2030
2104
  l(null);
2031
2105
  }, []), b = O((x) => {
2032
2106
  f(x);
@@ -2034,22 +2108,22 @@ function Ye({ appId: e, isActive: t, onClose: n }) {
2034
2108
  f(null);
2035
2109
  }, []), h = O((x) => {
2036
2110
  d(x);
2037
- }, []), N = O((x) => {
2038
- y(x);
2039
- }, []), C = me(() => ({
2040
- setTitle: g,
2041
- setBackHandler: w,
2042
- clearBackHandler: k,
2111
+ }, []), A = O((x) => {
2112
+ w(x);
2113
+ }, []), C = we(() => ({
2114
+ setTitle: y,
2115
+ setBackHandler: g,
2116
+ clearBackHandler: N,
2043
2117
  setToolbar: b,
2044
2118
  clearToolbar: p,
2045
2119
  setHideBackButton: h,
2046
- setHideTitleBar: N,
2120
+ setHideTitleBar: A,
2047
2121
  close: n
2048
- }), [g, w, k, b, p, h, N, n]);
2122
+ }), [y, g, N, b, p, h, A, n]);
2049
2123
  if (!o)
2050
2124
  return null;
2051
- const z = o.component, T = !o.hideTitleBar && !m;
2052
- return /* @__PURE__ */ A(
2125
+ const T = o.component, L = !o.hideTitleBar && !m;
2126
+ return /* @__PURE__ */ k(
2053
2127
  "div",
2054
2128
  {
2055
2129
  style: {
@@ -2059,12 +2133,12 @@ function Ye({ appId: e, isActive: t, onClose: n }) {
2059
2133
  minHeight: 0
2060
2134
  },
2061
2135
  children: [
2062
- T && /* @__PURE__ */ s(
2063
- Ft,
2136
+ L && /* @__PURE__ */ s(
2137
+ Jt,
2064
2138
  {
2065
2139
  title: i,
2066
2140
  onClose: n,
2067
- onBack: c ?? void 0,
2141
+ onBack: a ?? void 0,
2068
2142
  toolbar: u,
2069
2143
  hideBackButton: v
2070
2144
  }
@@ -2072,7 +2146,7 @@ function Ye({ appId: e, isActive: t, onClose: n }) {
2072
2146
  /* @__PURE__ */ s(
2073
2147
  "div",
2074
2148
  {
2075
- className: T ? "nc-app-content-wrapper" : "",
2149
+ className: L ? "nc-app-content-wrapper" : "",
2076
2150
  style: {
2077
2151
  padding: o.padding,
2078
2152
  flex: 1,
@@ -2082,8 +2156,8 @@ function Ye({ appId: e, isActive: t, onClose: n }) {
2082
2156
  backgroundColor: "var(--nc-bg-tertiary)",
2083
2157
  position: "relative"
2084
2158
  },
2085
- children: /* @__PURE__ */ s(Ve.Provider, { value: C, children: /* @__PURE__ */ s(Vt, { appId: e, children: /* @__PURE__ */ s(
2086
- mt,
2159
+ children: /* @__PURE__ */ s(Xe.Provider, { value: C, children: /* @__PURE__ */ s(Zt, { appId: e, children: /* @__PURE__ */ s(
2160
+ At,
2087
2161
  {
2088
2162
  fallback: /* @__PURE__ */ s(
2089
2163
  "div",
@@ -2094,10 +2168,10 @@ function Ye({ appId: e, isActive: t, onClose: n }) {
2094
2168
  justifyContent: "center",
2095
2169
  flex: 1
2096
2170
  },
2097
- children: /* @__PURE__ */ s(He, {})
2171
+ children: /* @__PURE__ */ s(Ke, {})
2098
2172
  }
2099
2173
  ),
2100
- children: /* @__PURE__ */ s(z, {})
2174
+ children: /* @__PURE__ */ s(T, {})
2101
2175
  }
2102
2176
  ) }) })
2103
2177
  }
@@ -2106,21 +2180,21 @@ function Ye({ appId: e, isActive: t, onClose: n }) {
2106
2180
  }
2107
2181
  );
2108
2182
  }
2109
- const fe = 768, he = 1024, Ge = {
2183
+ const be = 768, ve = 1024, Ze = {
2110
2184
  isMobile: !1,
2111
2185
  isTablet: !1,
2112
2186
  isDesktop: !0,
2113
2187
  width: typeof window < "u" ? window.innerWidth : 1024,
2114
2188
  height: typeof window < "u" ? window.innerHeight : 768
2115
- }, je = se(Ge);
2116
- function rr({ children: e }) {
2117
- const [t, n] = E(() => {
2118
- if (typeof window > "u") return Ge;
2189
+ }, Qe = ce(Ze);
2190
+ function hr({ children: e }) {
2191
+ const [t, n] = R(() => {
2192
+ if (typeof window > "u") return Ze;
2119
2193
  const r = window.innerWidth, o = window.innerHeight;
2120
2194
  return {
2121
- isMobile: r < fe,
2122
- isTablet: r >= fe && r < he,
2123
- isDesktop: r >= he,
2195
+ isMobile: r < be,
2196
+ isTablet: r >= be && r < ve,
2197
+ isDesktop: r >= ve,
2124
2198
  width: r,
2125
2199
  height: o
2126
2200
  };
@@ -2129,54 +2203,54 @@ function rr({ children: e }) {
2129
2203
  const r = () => {
2130
2204
  const o = window.innerWidth, i = window.innerHeight;
2131
2205
  n({
2132
- isMobile: o < fe,
2133
- isTablet: o >= fe && o < he,
2134
- isDesktop: o >= he,
2206
+ isMobile: o < be,
2207
+ isTablet: o >= be && o < ve,
2208
+ isDesktop: o >= ve,
2135
2209
  width: o,
2136
2210
  height: i
2137
2211
  });
2138
2212
  };
2139
2213
  return window.addEventListener("resize", r), () => window.removeEventListener("resize", r);
2140
- }, []), /* @__PURE__ */ s(je.Provider, { value: t, children: e });
2214
+ }, []), /* @__PURE__ */ s(Qe.Provider, { value: t, children: e });
2141
2215
  }
2142
- function Ke() {
2143
- return Q(je);
2216
+ function et() {
2217
+ return te(Qe);
2144
2218
  }
2145
- const Ne = "-", Yt = (e) => {
2146
- const t = jt(e), {
2219
+ const Me = "-", Qt = (e) => {
2220
+ const t = tn(e), {
2147
2221
  conflictingClassGroups: n,
2148
2222
  conflictingClassGroupModifiers: r
2149
2223
  } = e;
2150
2224
  return {
2151
- getClassGroupId: (a) => {
2152
- const c = a.split(Ne);
2153
- return c[0] === "" && c.length !== 1 && c.shift(), _e(c, t) || Gt(a);
2225
+ getClassGroupId: (c) => {
2226
+ const a = c.split(Me);
2227
+ return a[0] === "" && a.length !== 1 && a.shift(), tt(a, t) || en(c);
2154
2228
  },
2155
- getConflictingClassGroupIds: (a, c) => {
2156
- const l = n[a] || [];
2157
- return c && r[a] ? [...l, ...r[a]] : l;
2229
+ getConflictingClassGroupIds: (c, a) => {
2230
+ const l = n[c] || [];
2231
+ return a && r[c] ? [...l, ...r[c]] : l;
2158
2232
  }
2159
2233
  };
2160
- }, _e = (e, t) => {
2161
- var a;
2234
+ }, tt = (e, t) => {
2235
+ var c;
2162
2236
  if (e.length === 0)
2163
2237
  return t.classGroupId;
2164
- const n = e[0], r = t.nextPart.get(n), o = r ? _e(e.slice(1), r) : void 0;
2238
+ const n = e[0], r = t.nextPart.get(n), o = r ? tt(e.slice(1), r) : void 0;
2165
2239
  if (o)
2166
2240
  return o;
2167
2241
  if (t.validators.length === 0)
2168
2242
  return;
2169
- const i = e.join(Ne);
2170
- return (a = t.validators.find(({
2171
- validator: c
2172
- }) => c(i))) == null ? void 0 : a.classGroupId;
2173
- }, Be = /^\[(.+)\]$/, Gt = (e) => {
2174
- if (Be.test(e)) {
2175
- const t = Be.exec(e)[1], n = t == null ? void 0 : t.substring(0, t.indexOf(":"));
2243
+ const i = e.join(Me);
2244
+ return (c = t.validators.find(({
2245
+ validator: a
2246
+ }) => a(i))) == null ? void 0 : c.classGroupId;
2247
+ }, Ge = /^\[(.+)\]$/, en = (e) => {
2248
+ if (Ge.test(e)) {
2249
+ const t = Ge.exec(e)[1], n = t == null ? void 0 : t.substring(0, t.indexOf(":"));
2176
2250
  if (n)
2177
2251
  return "arbitrary.." + n;
2178
2252
  }
2179
- }, jt = (e) => {
2253
+ }, tn = (e) => {
2180
2254
  const {
2181
2255
  theme: t,
2182
2256
  prefix: n
@@ -2184,19 +2258,19 @@ const Ne = "-", Yt = (e) => {
2184
2258
  nextPart: /* @__PURE__ */ new Map(),
2185
2259
  validators: []
2186
2260
  };
2187
- return _t(Object.entries(e.classGroups), n).forEach(([i, a]) => {
2188
- ye(a, r, i, t);
2261
+ return rn(Object.entries(e.classGroups), n).forEach(([i, c]) => {
2262
+ Se(c, r, i, t);
2189
2263
  }), r;
2190
- }, ye = (e, t, n, r) => {
2264
+ }, Se = (e, t, n, r) => {
2191
2265
  e.forEach((o) => {
2192
2266
  if (typeof o == "string") {
2193
- const i = o === "" ? t : De(t, o);
2267
+ const i = o === "" ? t : Ye(t, o);
2194
2268
  i.classGroupId = n;
2195
2269
  return;
2196
2270
  }
2197
2271
  if (typeof o == "function") {
2198
- if (Kt(o)) {
2199
- ye(o(r), t, n, r);
2272
+ if (nn(o)) {
2273
+ Se(o(r), t, n, r);
2200
2274
  return;
2201
2275
  }
2202
2276
  t.validators.push({
@@ -2205,22 +2279,22 @@ const Ne = "-", Yt = (e) => {
2205
2279
  });
2206
2280
  return;
2207
2281
  }
2208
- Object.entries(o).forEach(([i, a]) => {
2209
- ye(a, De(t, i), n, r);
2282
+ Object.entries(o).forEach(([i, c]) => {
2283
+ Se(c, Ye(t, i), n, r);
2210
2284
  });
2211
2285
  });
2212
- }, De = (e, t) => {
2286
+ }, Ye = (e, t) => {
2213
2287
  let n = e;
2214
- return t.split(Ne).forEach((r) => {
2288
+ return t.split(Me).forEach((r) => {
2215
2289
  n.nextPart.has(r) || n.nextPart.set(r, {
2216
2290
  nextPart: /* @__PURE__ */ new Map(),
2217
2291
  validators: []
2218
2292
  }), n = n.nextPart.get(r);
2219
2293
  }), n;
2220
- }, Kt = (e) => e.isThemeGetter, _t = (e, t) => t ? e.map(([n, r]) => {
2221
- const o = r.map((i) => typeof i == "string" ? t + i : typeof i == "object" ? Object.fromEntries(Object.entries(i).map(([a, c]) => [t + a, c])) : i);
2294
+ }, nn = (e) => e.isThemeGetter, rn = (e, t) => t ? e.map(([n, r]) => {
2295
+ const o = r.map((i) => typeof i == "string" ? t + i : typeof i == "object" ? Object.fromEntries(Object.entries(i).map(([c, a]) => [t + c, a])) : i);
2222
2296
  return [n, o];
2223
- }) : e, Ut = (e) => {
2297
+ }) : e, on = (e) => {
2224
2298
  if (e < 1)
2225
2299
  return {
2226
2300
  get: () => {
@@ -2229,55 +2303,55 @@ const Ne = "-", Yt = (e) => {
2229
2303
  }
2230
2304
  };
2231
2305
  let t = 0, n = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Map();
2232
- const o = (i, a) => {
2233
- n.set(i, a), t++, t > e && (t = 0, r = n, n = /* @__PURE__ */ new Map());
2306
+ const o = (i, c) => {
2307
+ n.set(i, c), t++, t > e && (t = 0, r = n, n = /* @__PURE__ */ new Map());
2234
2308
  };
2235
2309
  return {
2236
2310
  get(i) {
2237
- let a = n.get(i);
2238
- if (a !== void 0)
2239
- return a;
2240
- if ((a = r.get(i)) !== void 0)
2241
- return o(i, a), a;
2311
+ let c = n.get(i);
2312
+ if (c !== void 0)
2313
+ return c;
2314
+ if ((c = r.get(i)) !== void 0)
2315
+ return o(i, c), c;
2242
2316
  },
2243
- set(i, a) {
2244
- n.has(i) ? n.set(i, a) : o(i, a);
2317
+ set(i, c) {
2318
+ n.has(i) ? n.set(i, c) : o(i, c);
2245
2319
  }
2246
2320
  };
2247
- }, Ue = "!", qt = (e) => {
2321
+ }, nt = "!", sn = (e) => {
2248
2322
  const {
2249
2323
  separator: t,
2250
2324
  experimentalParseClassName: n
2251
- } = e, r = t.length === 1, o = t[0], i = t.length, a = (c) => {
2325
+ } = e, r = t.length === 1, o = t[0], i = t.length, c = (a) => {
2252
2326
  const l = [];
2253
2327
  let u = 0, f = 0, v;
2254
- for (let w = 0; w < c.length; w++) {
2255
- let k = c[w];
2328
+ for (let g = 0; g < a.length; g++) {
2329
+ let N = a[g];
2256
2330
  if (u === 0) {
2257
- if (k === o && (r || c.slice(w, w + i) === t)) {
2258
- l.push(c.slice(f, w)), f = w + i;
2331
+ if (N === o && (r || a.slice(g, g + i) === t)) {
2332
+ l.push(a.slice(f, g)), f = g + i;
2259
2333
  continue;
2260
2334
  }
2261
- if (k === "/") {
2262
- v = w;
2335
+ if (N === "/") {
2336
+ v = g;
2263
2337
  continue;
2264
2338
  }
2265
2339
  }
2266
- k === "[" ? u++ : k === "]" && u--;
2340
+ N === "[" ? u++ : N === "]" && u--;
2267
2341
  }
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;
2342
+ const d = l.length === 0 ? a : a.substring(f), m = d.startsWith(nt), w = m ? d.substring(1) : d, y = v && v > f ? v - f : void 0;
2269
2343
  return {
2270
2344
  modifiers: l,
2271
2345
  hasImportantModifier: m,
2272
- baseClassName: y,
2273
- maybePostfixModifierPosition: g
2346
+ baseClassName: w,
2347
+ maybePostfixModifierPosition: y
2274
2348
  };
2275
2349
  };
2276
- return n ? (c) => n({
2277
- className: c,
2278
- parseClassName: a
2279
- }) : a;
2280
- }, Xt = (e) => {
2350
+ return n ? (a) => n({
2351
+ className: a,
2352
+ parseClassName: c
2353
+ }) : c;
2354
+ }, cn = (e) => {
2281
2355
  if (e.length <= 1)
2282
2356
  return e;
2283
2357
  const t = [];
@@ -2285,120 +2359,120 @@ const Ne = "-", Yt = (e) => {
2285
2359
  return e.forEach((r) => {
2286
2360
  r[0] === "[" ? (t.push(...n.sort(), r), n = []) : n.push(r);
2287
2361
  }), t.push(...n.sort()), t;
2288
- }, Jt = (e) => ({
2289
- cache: Ut(e.cacheSize),
2290
- parseClassName: qt(e),
2291
- ...Yt(e)
2292
- }), Qt = /\s+/, Zt = (e, t) => {
2362
+ }, an = (e) => ({
2363
+ cache: on(e.cacheSize),
2364
+ parseClassName: sn(e),
2365
+ ...Qt(e)
2366
+ }), ln = /\s+/, dn = (e, t) => {
2293
2367
  const {
2294
2368
  parseClassName: n,
2295
2369
  getClassGroupId: r,
2296
2370
  getConflictingClassGroupIds: o
2297
- } = t, i = [], a = e.trim().split(Qt);
2298
- let c = "";
2299
- for (let l = a.length - 1; l >= 0; l -= 1) {
2300
- const u = a[l], {
2371
+ } = t, i = [], c = e.trim().split(ln);
2372
+ let a = "";
2373
+ for (let l = c.length - 1; l >= 0; l -= 1) {
2374
+ const u = c[l], {
2301
2375
  modifiers: f,
2302
2376
  hasImportantModifier: v,
2303
2377
  baseClassName: d,
2304
2378
  maybePostfixModifierPosition: m
2305
2379
  } = n(u);
2306
- let y = !!m, g = r(y ? d.substring(0, m) : d);
2307
- if (!g) {
2308
- if (!y) {
2309
- c = u + (c.length > 0 ? " " + c : c);
2380
+ let w = !!m, y = r(w ? d.substring(0, m) : d);
2381
+ if (!y) {
2382
+ if (!w) {
2383
+ a = u + (a.length > 0 ? " " + a : a);
2310
2384
  continue;
2311
2385
  }
2312
- if (g = r(d), !g) {
2313
- c = u + (c.length > 0 ? " " + c : c);
2386
+ if (y = r(d), !y) {
2387
+ a = u + (a.length > 0 ? " " + a : a);
2314
2388
  continue;
2315
2389
  }
2316
- y = !1;
2390
+ w = !1;
2317
2391
  }
2318
- const w = Xt(f).join(":"), k = v ? w + Ue : w, b = k + g;
2392
+ const g = cn(f).join(":"), N = v ? g + nt : g, b = N + y;
2319
2393
  if (i.includes(b))
2320
2394
  continue;
2321
2395
  i.push(b);
2322
- const p = o(g, y);
2396
+ const p = o(y, w);
2323
2397
  for (let h = 0; h < p.length; ++h) {
2324
- const N = p[h];
2325
- i.push(k + N);
2398
+ const A = p[h];
2399
+ i.push(N + A);
2326
2400
  }
2327
- c = u + (c.length > 0 ? " " + c : c);
2401
+ a = u + (a.length > 0 ? " " + a : a);
2328
2402
  }
2329
- return c;
2403
+ return a;
2330
2404
  };
2331
- function en() {
2405
+ function un() {
2332
2406
  let e = 0, t, n, r = "";
2333
2407
  for (; e < arguments.length; )
2334
- (t = arguments[e++]) && (n = qe(t)) && (r && (r += " "), r += n);
2408
+ (t = arguments[e++]) && (n = rt(t)) && (r && (r += " "), r += n);
2335
2409
  return r;
2336
2410
  }
2337
- const qe = (e) => {
2411
+ const rt = (e) => {
2338
2412
  if (typeof e == "string")
2339
2413
  return e;
2340
2414
  let t, n = "";
2341
2415
  for (let r = 0; r < e.length; r++)
2342
- e[r] && (t = qe(e[r])) && (n && (n += " "), n += t);
2416
+ e[r] && (t = rt(e[r])) && (n && (n += " "), n += t);
2343
2417
  return n;
2344
2418
  };
2345
- function tn(e, ...t) {
2346
- let n, r, o, i = a;
2347
- function a(l) {
2419
+ function pn(e, ...t) {
2420
+ let n, r, o, i = c;
2421
+ function c(l) {
2348
2422
  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);
2423
+ return n = an(u), r = n.cache.get, o = n.cache.set, i = a, a(l);
2350
2424
  }
2351
- function c(l) {
2425
+ function a(l) {
2352
2426
  const u = r(l);
2353
2427
  if (u)
2354
2428
  return u;
2355
- const f = Zt(l, n);
2429
+ const f = dn(l, n);
2356
2430
  return o(l, f), f;
2357
2431
  }
2358
2432
  return function() {
2359
- return i(en.apply(null, arguments));
2433
+ return i(un.apply(null, arguments));
2360
2434
  };
2361
2435
  }
2362
- const H = (e) => {
2436
+ const W = (e) => {
2363
2437
  const t = (n) => n[e] || [];
2364
2438
  return t.isThemeGetter = !0, t;
2365
- }, Xe = /^\[(?:([a-z-]+):)?(.+)\]$/i, nn = /^\d+\/\d+$/, rn = /* @__PURE__ */ new Set(["px", "full", "screen"]), on = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, sn = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, cn = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/, an = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, ln = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, j = (e) => re(e) || rn.has(e) || nn.test(e), X = (e) => ie(e, "length", bn), re = (e) => !!e && !Number.isNaN(Number(e)), be = (e) => ie(e, "number", re), ae = (e) => !!e && Number.isInteger(Number(e)), dn = (e) => e.endsWith("%") && re(e.slice(0, -1)), I = (e) => Xe.test(e), J = (e) => on.test(e), un = /* @__PURE__ */ new Set(["length", "size", "percentage"]), pn = (e) => ie(e, un, Je), fn = (e) => ie(e, "position", Je), hn = /* @__PURE__ */ new Set(["image", "url"]), mn = (e) => ie(e, hn, wn), gn = (e) => ie(e, "", vn), le = () => !0, ie = (e, t, n) => {
2366
- const r = Xe.exec(e);
2439
+ }, ot = /^\[(?:([a-z-]+):)?(.+)\]$/i, fn = /^\d+\/\d+$/, hn = /* @__PURE__ */ new Set(["px", "full", "screen"]), mn = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, gn = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, bn = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/, vn = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, wn = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, _ = (e) => se(e) || hn.has(e) || fn.test(e), Q = (e) => ae(e, "length", $n), se = (e) => !!e && !Number.isNaN(Number(e)), ke = (e) => ae(e, "number", se), le = (e) => !!e && Number.isInteger(Number(e)), yn = (e) => e.endsWith("%") && se(e.slice(0, -1)), M = (e) => ot.test(e), ee = (e) => mn.test(e), xn = /* @__PURE__ */ new Set(["length", "size", "percentage"]), kn = (e) => ae(e, xn, st), Nn = (e) => ae(e, "position", st), An = /* @__PURE__ */ new Set(["image", "url"]), Sn = (e) => ae(e, An, In), Cn = (e) => ae(e, "", Mn), de = () => !0, ae = (e, t, n) => {
2440
+ const r = ot.exec(e);
2367
2441
  return r ? r[1] ? typeof t == "string" ? r[1] === t : t.has(r[1]) : n(r[2]) : !1;
2368
- }, bn = (e) => (
2442
+ }, $n = (e) => (
2369
2443
  // `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
2370
2444
  // For example, `hsl(0 0% 0%)` would be classified as a length without this check.
2371
2445
  // I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
2372
- sn.test(e) && !cn.test(e)
2373
- ), Je = () => !1, vn = (e) => an.test(e), wn = (e) => ln.test(e), yn = () => {
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];
2446
+ gn.test(e) && !bn.test(e)
2447
+ ), st = () => !1, Mn = (e) => vn.test(e), In = (e) => wn.test(e), Rn = () => {
2448
+ const e = W("colors"), t = W("spacing"), n = W("blur"), r = W("brightness"), o = W("borderColor"), i = W("borderRadius"), c = W("borderSpacing"), a = W("borderWidth"), l = W("contrast"), u = W("grayscale"), f = W("hueRotate"), v = W("invert"), d = W("gap"), m = W("gradientColorStops"), w = W("gradientColorStopPositions"), y = W("inset"), g = W("margin"), N = W("opacity"), b = W("padding"), p = W("saturate"), h = W("scale"), A = W("sepia"), C = W("skew"), T = W("space"), L = W("translate"), x = () => ["auto", "contain", "none"], I = () => ["auto", "hidden", "clip", "visible", "scroll"], S = () => ["auto", M, t], $ = () => [M, t], z = () => ["", _, Q], H = () => ["auto", se, M], K = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"], j = () => ["solid", "dashed", "dotted", "double", "none"], E = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], D = () => ["start", "end", "center", "between", "around", "evenly", "stretch"], P = () => ["", "0", M], re = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], F = () => [se, M];
2375
2449
  return {
2376
2450
  cacheSize: 500,
2377
2451
  separator: ":",
2378
2452
  theme: {
2379
- colors: [le],
2380
- spacing: [j, X],
2381
- blur: ["none", "", J, I],
2382
- brightness: V(),
2453
+ colors: [de],
2454
+ spacing: [_, Q],
2455
+ blur: ["none", "", ee, M],
2456
+ brightness: F(),
2383
2457
  borderColor: [e],
2384
- borderRadius: ["none", "", "full", J, I],
2458
+ borderRadius: ["none", "", "full", ee, M],
2385
2459
  borderSpacing: $(),
2386
- borderWidth: P(),
2387
- contrast: V(),
2388
- grayscale: D(),
2389
- hueRotate: V(),
2390
- invert: D(),
2460
+ borderWidth: z(),
2461
+ contrast: F(),
2462
+ grayscale: P(),
2463
+ hueRotate: F(),
2464
+ invert: P(),
2391
2465
  gap: $(),
2392
2466
  gradientColorStops: [e],
2393
- gradientColorStopPositions: [dn, X],
2467
+ gradientColorStopPositions: [yn, Q],
2394
2468
  inset: S(),
2395
2469
  margin: S(),
2396
- opacity: V(),
2470
+ opacity: F(),
2397
2471
  padding: $(),
2398
- saturate: V(),
2399
- scale: V(),
2400
- sepia: D(),
2401
- skew: V(),
2472
+ saturate: F(),
2473
+ scale: F(),
2474
+ sepia: P(),
2475
+ skew: F(),
2402
2476
  space: $(),
2403
2477
  translate: $()
2404
2478
  },
@@ -2409,7 +2483,7 @@ const H = (e) => {
2409
2483
  * @see https://tailwindcss.com/docs/aspect-ratio
2410
2484
  */
2411
2485
  aspect: [{
2412
- aspect: ["auto", "square", "video", I]
2486
+ aspect: ["auto", "square", "video", M]
2413
2487
  }],
2414
2488
  /**
2415
2489
  * Container
@@ -2421,21 +2495,21 @@ const H = (e) => {
2421
2495
  * @see https://tailwindcss.com/docs/columns
2422
2496
  */
2423
2497
  columns: [{
2424
- columns: [J]
2498
+ columns: [ee]
2425
2499
  }],
2426
2500
  /**
2427
2501
  * Break After
2428
2502
  * @see https://tailwindcss.com/docs/break-after
2429
2503
  */
2430
2504
  "break-after": [{
2431
- "break-after": ge()
2505
+ "break-after": re()
2432
2506
  }],
2433
2507
  /**
2434
2508
  * Break Before
2435
2509
  * @see https://tailwindcss.com/docs/break-before
2436
2510
  */
2437
2511
  "break-before": [{
2438
- "break-before": ge()
2512
+ "break-before": re()
2439
2513
  }],
2440
2514
  /**
2441
2515
  * Break Inside
@@ -2494,28 +2568,28 @@ const H = (e) => {
2494
2568
  * @see https://tailwindcss.com/docs/object-position
2495
2569
  */
2496
2570
  "object-position": [{
2497
- object: [...Z(), I]
2571
+ object: [...K(), M]
2498
2572
  }],
2499
2573
  /**
2500
2574
  * Overflow
2501
2575
  * @see https://tailwindcss.com/docs/overflow
2502
2576
  */
2503
2577
  overflow: [{
2504
- overflow: R()
2578
+ overflow: I()
2505
2579
  }],
2506
2580
  /**
2507
2581
  * Overflow X
2508
2582
  * @see https://tailwindcss.com/docs/overflow
2509
2583
  */
2510
2584
  "overflow-x": [{
2511
- "overflow-x": R()
2585
+ "overflow-x": I()
2512
2586
  }],
2513
2587
  /**
2514
2588
  * Overflow Y
2515
2589
  * @see https://tailwindcss.com/docs/overflow
2516
2590
  */
2517
2591
  "overflow-y": [{
2518
- "overflow-y": R()
2592
+ "overflow-y": I()
2519
2593
  }],
2520
2594
  /**
2521
2595
  * Overscroll Behavior
@@ -2548,63 +2622,63 @@ const H = (e) => {
2548
2622
  * @see https://tailwindcss.com/docs/top-right-bottom-left
2549
2623
  */
2550
2624
  inset: [{
2551
- inset: [g]
2625
+ inset: [y]
2552
2626
  }],
2553
2627
  /**
2554
2628
  * Right / Left
2555
2629
  * @see https://tailwindcss.com/docs/top-right-bottom-left
2556
2630
  */
2557
2631
  "inset-x": [{
2558
- "inset-x": [g]
2632
+ "inset-x": [y]
2559
2633
  }],
2560
2634
  /**
2561
2635
  * Top / Bottom
2562
2636
  * @see https://tailwindcss.com/docs/top-right-bottom-left
2563
2637
  */
2564
2638
  "inset-y": [{
2565
- "inset-y": [g]
2639
+ "inset-y": [y]
2566
2640
  }],
2567
2641
  /**
2568
2642
  * Start
2569
2643
  * @see https://tailwindcss.com/docs/top-right-bottom-left
2570
2644
  */
2571
2645
  start: [{
2572
- start: [g]
2646
+ start: [y]
2573
2647
  }],
2574
2648
  /**
2575
2649
  * End
2576
2650
  * @see https://tailwindcss.com/docs/top-right-bottom-left
2577
2651
  */
2578
2652
  end: [{
2579
- end: [g]
2653
+ end: [y]
2580
2654
  }],
2581
2655
  /**
2582
2656
  * Top
2583
2657
  * @see https://tailwindcss.com/docs/top-right-bottom-left
2584
2658
  */
2585
2659
  top: [{
2586
- top: [g]
2660
+ top: [y]
2587
2661
  }],
2588
2662
  /**
2589
2663
  * Right
2590
2664
  * @see https://tailwindcss.com/docs/top-right-bottom-left
2591
2665
  */
2592
2666
  right: [{
2593
- right: [g]
2667
+ right: [y]
2594
2668
  }],
2595
2669
  /**
2596
2670
  * Bottom
2597
2671
  * @see https://tailwindcss.com/docs/top-right-bottom-left
2598
2672
  */
2599
2673
  bottom: [{
2600
- bottom: [g]
2674
+ bottom: [y]
2601
2675
  }],
2602
2676
  /**
2603
2677
  * Left
2604
2678
  * @see https://tailwindcss.com/docs/top-right-bottom-left
2605
2679
  */
2606
2680
  left: [{
2607
- left: [g]
2681
+ left: [y]
2608
2682
  }],
2609
2683
  /**
2610
2684
  * Visibility
@@ -2616,7 +2690,7 @@ const H = (e) => {
2616
2690
  * @see https://tailwindcss.com/docs/z-index
2617
2691
  */
2618
2692
  z: [{
2619
- z: ["auto", ae, I]
2693
+ z: ["auto", le, M]
2620
2694
  }],
2621
2695
  // Flexbox and Grid
2622
2696
  /**
@@ -2645,35 +2719,35 @@ const H = (e) => {
2645
2719
  * @see https://tailwindcss.com/docs/flex
2646
2720
  */
2647
2721
  flex: [{
2648
- flex: ["1", "auto", "initial", "none", I]
2722
+ flex: ["1", "auto", "initial", "none", M]
2649
2723
  }],
2650
2724
  /**
2651
2725
  * Flex Grow
2652
2726
  * @see https://tailwindcss.com/docs/flex-grow
2653
2727
  */
2654
2728
  grow: [{
2655
- grow: D()
2729
+ grow: P()
2656
2730
  }],
2657
2731
  /**
2658
2732
  * Flex Shrink
2659
2733
  * @see https://tailwindcss.com/docs/flex-shrink
2660
2734
  */
2661
2735
  shrink: [{
2662
- shrink: D()
2736
+ shrink: P()
2663
2737
  }],
2664
2738
  /**
2665
2739
  * Order
2666
2740
  * @see https://tailwindcss.com/docs/order
2667
2741
  */
2668
2742
  order: [{
2669
- order: ["first", "last", "none", ae, I]
2743
+ order: ["first", "last", "none", le, M]
2670
2744
  }],
2671
2745
  /**
2672
2746
  * Grid Template Columns
2673
2747
  * @see https://tailwindcss.com/docs/grid-template-columns
2674
2748
  */
2675
2749
  "grid-cols": [{
2676
- "grid-cols": [le]
2750
+ "grid-cols": [de]
2677
2751
  }],
2678
2752
  /**
2679
2753
  * Grid Column Start / End
@@ -2681,29 +2755,29 @@ const H = (e) => {
2681
2755
  */
2682
2756
  "col-start-end": [{
2683
2757
  col: ["auto", {
2684
- span: ["full", ae, I]
2685
- }, I]
2758
+ span: ["full", le, M]
2759
+ }, M]
2686
2760
  }],
2687
2761
  /**
2688
2762
  * Grid Column Start
2689
2763
  * @see https://tailwindcss.com/docs/grid-column
2690
2764
  */
2691
2765
  "col-start": [{
2692
- "col-start": F()
2766
+ "col-start": H()
2693
2767
  }],
2694
2768
  /**
2695
2769
  * Grid Column End
2696
2770
  * @see https://tailwindcss.com/docs/grid-column
2697
2771
  */
2698
2772
  "col-end": [{
2699
- "col-end": F()
2773
+ "col-end": H()
2700
2774
  }],
2701
2775
  /**
2702
2776
  * Grid Template Rows
2703
2777
  * @see https://tailwindcss.com/docs/grid-template-rows
2704
2778
  */
2705
2779
  "grid-rows": [{
2706
- "grid-rows": [le]
2780
+ "grid-rows": [de]
2707
2781
  }],
2708
2782
  /**
2709
2783
  * Grid Row Start / End
@@ -2711,22 +2785,22 @@ const H = (e) => {
2711
2785
  */
2712
2786
  "row-start-end": [{
2713
2787
  row: ["auto", {
2714
- span: [ae, I]
2715
- }, I]
2788
+ span: [le, M]
2789
+ }, M]
2716
2790
  }],
2717
2791
  /**
2718
2792
  * Grid Row Start
2719
2793
  * @see https://tailwindcss.com/docs/grid-row
2720
2794
  */
2721
2795
  "row-start": [{
2722
- "row-start": F()
2796
+ "row-start": H()
2723
2797
  }],
2724
2798
  /**
2725
2799
  * Grid Row End
2726
2800
  * @see https://tailwindcss.com/docs/grid-row
2727
2801
  */
2728
2802
  "row-end": [{
2729
- "row-end": F()
2803
+ "row-end": H()
2730
2804
  }],
2731
2805
  /**
2732
2806
  * Grid Auto Flow
@@ -2740,14 +2814,14 @@ const H = (e) => {
2740
2814
  * @see https://tailwindcss.com/docs/grid-auto-columns
2741
2815
  */
2742
2816
  "auto-cols": [{
2743
- "auto-cols": ["auto", "min", "max", "fr", I]
2817
+ "auto-cols": ["auto", "min", "max", "fr", M]
2744
2818
  }],
2745
2819
  /**
2746
2820
  * Grid Auto Rows
2747
2821
  * @see https://tailwindcss.com/docs/grid-auto-rows
2748
2822
  */
2749
2823
  "auto-rows": [{
2750
- "auto-rows": ["auto", "min", "max", "fr", I]
2824
+ "auto-rows": ["auto", "min", "max", "fr", M]
2751
2825
  }],
2752
2826
  /**
2753
2827
  * Gap
@@ -2775,7 +2849,7 @@ const H = (e) => {
2775
2849
  * @see https://tailwindcss.com/docs/justify-content
2776
2850
  */
2777
2851
  "justify-content": [{
2778
- justify: ["normal", ...L()]
2852
+ justify: ["normal", ...D()]
2779
2853
  }],
2780
2854
  /**
2781
2855
  * Justify Items
@@ -2796,7 +2870,7 @@ const H = (e) => {
2796
2870
  * @see https://tailwindcss.com/docs/align-content
2797
2871
  */
2798
2872
  "align-content": [{
2799
- content: ["normal", ...L(), "baseline"]
2873
+ content: ["normal", ...D(), "baseline"]
2800
2874
  }],
2801
2875
  /**
2802
2876
  * Align Items
@@ -2817,7 +2891,7 @@ const H = (e) => {
2817
2891
  * @see https://tailwindcss.com/docs/place-content
2818
2892
  */
2819
2893
  "place-content": [{
2820
- "place-content": [...L(), "baseline"]
2894
+ "place-content": [...D(), "baseline"]
2821
2895
  }],
2822
2896
  /**
2823
2897
  * Place Items
@@ -2902,70 +2976,70 @@ const H = (e) => {
2902
2976
  * @see https://tailwindcss.com/docs/margin
2903
2977
  */
2904
2978
  m: [{
2905
- m: [w]
2979
+ m: [g]
2906
2980
  }],
2907
2981
  /**
2908
2982
  * Margin X
2909
2983
  * @see https://tailwindcss.com/docs/margin
2910
2984
  */
2911
2985
  mx: [{
2912
- mx: [w]
2986
+ mx: [g]
2913
2987
  }],
2914
2988
  /**
2915
2989
  * Margin Y
2916
2990
  * @see https://tailwindcss.com/docs/margin
2917
2991
  */
2918
2992
  my: [{
2919
- my: [w]
2993
+ my: [g]
2920
2994
  }],
2921
2995
  /**
2922
2996
  * Margin Start
2923
2997
  * @see https://tailwindcss.com/docs/margin
2924
2998
  */
2925
2999
  ms: [{
2926
- ms: [w]
3000
+ ms: [g]
2927
3001
  }],
2928
3002
  /**
2929
3003
  * Margin End
2930
3004
  * @see https://tailwindcss.com/docs/margin
2931
3005
  */
2932
3006
  me: [{
2933
- me: [w]
3007
+ me: [g]
2934
3008
  }],
2935
3009
  /**
2936
3010
  * Margin Top
2937
3011
  * @see https://tailwindcss.com/docs/margin
2938
3012
  */
2939
3013
  mt: [{
2940
- mt: [w]
3014
+ mt: [g]
2941
3015
  }],
2942
3016
  /**
2943
3017
  * Margin Right
2944
3018
  * @see https://tailwindcss.com/docs/margin
2945
3019
  */
2946
3020
  mr: [{
2947
- mr: [w]
3021
+ mr: [g]
2948
3022
  }],
2949
3023
  /**
2950
3024
  * Margin Bottom
2951
3025
  * @see https://tailwindcss.com/docs/margin
2952
3026
  */
2953
3027
  mb: [{
2954
- mb: [w]
3028
+ mb: [g]
2955
3029
  }],
2956
3030
  /**
2957
3031
  * Margin Left
2958
3032
  * @see https://tailwindcss.com/docs/margin
2959
3033
  */
2960
3034
  ml: [{
2961
- ml: [w]
3035
+ ml: [g]
2962
3036
  }],
2963
3037
  /**
2964
3038
  * Space Between X
2965
3039
  * @see https://tailwindcss.com/docs/space
2966
3040
  */
2967
3041
  "space-x": [{
2968
- "space-x": [z]
3042
+ "space-x": [T]
2969
3043
  }],
2970
3044
  /**
2971
3045
  * Space Between X Reverse
@@ -2977,7 +3051,7 @@ const H = (e) => {
2977
3051
  * @see https://tailwindcss.com/docs/space
2978
3052
  */
2979
3053
  "space-y": [{
2980
- "space-y": [z]
3054
+ "space-y": [T]
2981
3055
  }],
2982
3056
  /**
2983
3057
  * Space Between Y Reverse
@@ -2990,51 +3064,51 @@ const H = (e) => {
2990
3064
  * @see https://tailwindcss.com/docs/width
2991
3065
  */
2992
3066
  w: [{
2993
- w: ["auto", "min", "max", "fit", "svw", "lvw", "dvw", I, t]
3067
+ w: ["auto", "min", "max", "fit", "svw", "lvw", "dvw", M, t]
2994
3068
  }],
2995
3069
  /**
2996
3070
  * Min-Width
2997
3071
  * @see https://tailwindcss.com/docs/min-width
2998
3072
  */
2999
3073
  "min-w": [{
3000
- "min-w": [I, t, "min", "max", "fit"]
3074
+ "min-w": [M, t, "min", "max", "fit"]
3001
3075
  }],
3002
3076
  /**
3003
3077
  * Max-Width
3004
3078
  * @see https://tailwindcss.com/docs/max-width
3005
3079
  */
3006
3080
  "max-w": [{
3007
- "max-w": [I, t, "none", "full", "min", "max", "fit", "prose", {
3008
- screen: [J]
3009
- }, J]
3081
+ "max-w": [M, t, "none", "full", "min", "max", "fit", "prose", {
3082
+ screen: [ee]
3083
+ }, ee]
3010
3084
  }],
3011
3085
  /**
3012
3086
  * Height
3013
3087
  * @see https://tailwindcss.com/docs/height
3014
3088
  */
3015
3089
  h: [{
3016
- h: [I, t, "auto", "min", "max", "fit", "svh", "lvh", "dvh"]
3090
+ h: [M, t, "auto", "min", "max", "fit", "svh", "lvh", "dvh"]
3017
3091
  }],
3018
3092
  /**
3019
3093
  * Min-Height
3020
3094
  * @see https://tailwindcss.com/docs/min-height
3021
3095
  */
3022
3096
  "min-h": [{
3023
- "min-h": [I, t, "min", "max", "fit", "svh", "lvh", "dvh"]
3097
+ "min-h": [M, t, "min", "max", "fit", "svh", "lvh", "dvh"]
3024
3098
  }],
3025
3099
  /**
3026
3100
  * Max-Height
3027
3101
  * @see https://tailwindcss.com/docs/max-height
3028
3102
  */
3029
3103
  "max-h": [{
3030
- "max-h": [I, t, "min", "max", "fit", "svh", "lvh", "dvh"]
3104
+ "max-h": [M, t, "min", "max", "fit", "svh", "lvh", "dvh"]
3031
3105
  }],
3032
3106
  /**
3033
3107
  * Size
3034
3108
  * @see https://tailwindcss.com/docs/size
3035
3109
  */
3036
3110
  size: [{
3037
- size: [I, t, "auto", "min", "max", "fit"]
3111
+ size: [M, t, "auto", "min", "max", "fit"]
3038
3112
  }],
3039
3113
  // Typography
3040
3114
  /**
@@ -3042,7 +3116,7 @@ const H = (e) => {
3042
3116
  * @see https://tailwindcss.com/docs/font-size
3043
3117
  */
3044
3118
  "font-size": [{
3045
- text: ["base", J, X]
3119
+ text: ["base", ee, Q]
3046
3120
  }],
3047
3121
  /**
3048
3122
  * Font Smoothing
@@ -3059,14 +3133,14 @@ const H = (e) => {
3059
3133
  * @see https://tailwindcss.com/docs/font-weight
3060
3134
  */
3061
3135
  "font-weight": [{
3062
- font: ["thin", "extralight", "light", "normal", "medium", "semibold", "bold", "extrabold", "black", be]
3136
+ font: ["thin", "extralight", "light", "normal", "medium", "semibold", "bold", "extrabold", "black", ke]
3063
3137
  }],
3064
3138
  /**
3065
3139
  * Font Family
3066
3140
  * @see https://tailwindcss.com/docs/font-family
3067
3141
  */
3068
3142
  "font-family": [{
3069
- font: [le]
3143
+ font: [de]
3070
3144
  }],
3071
3145
  /**
3072
3146
  * Font Variant Numeric
@@ -3103,35 +3177,35 @@ const H = (e) => {
3103
3177
  * @see https://tailwindcss.com/docs/letter-spacing
3104
3178
  */
3105
3179
  tracking: [{
3106
- tracking: ["tighter", "tight", "normal", "wide", "wider", "widest", I]
3180
+ tracking: ["tighter", "tight", "normal", "wide", "wider", "widest", M]
3107
3181
  }],
3108
3182
  /**
3109
3183
  * Line Clamp
3110
3184
  * @see https://tailwindcss.com/docs/line-clamp
3111
3185
  */
3112
3186
  "line-clamp": [{
3113
- "line-clamp": ["none", re, be]
3187
+ "line-clamp": ["none", se, ke]
3114
3188
  }],
3115
3189
  /**
3116
3190
  * Line Height
3117
3191
  * @see https://tailwindcss.com/docs/line-height
3118
3192
  */
3119
3193
  leading: [{
3120
- leading: ["none", "tight", "snug", "normal", "relaxed", "loose", j, I]
3194
+ leading: ["none", "tight", "snug", "normal", "relaxed", "loose", _, M]
3121
3195
  }],
3122
3196
  /**
3123
3197
  * List Style Image
3124
3198
  * @see https://tailwindcss.com/docs/list-style-image
3125
3199
  */
3126
3200
  "list-image": [{
3127
- "list-image": ["none", I]
3201
+ "list-image": ["none", M]
3128
3202
  }],
3129
3203
  /**
3130
3204
  * List Style Type
3131
3205
  * @see https://tailwindcss.com/docs/list-style-type
3132
3206
  */
3133
3207
  "list-style-type": [{
3134
- list: ["none", "disc", "decimal", I]
3208
+ list: ["none", "disc", "decimal", M]
3135
3209
  }],
3136
3210
  /**
3137
3211
  * List Style Position
@@ -3153,7 +3227,7 @@ const H = (e) => {
3153
3227
  * @see https://tailwindcss.com/docs/placeholder-opacity
3154
3228
  */
3155
3229
  "placeholder-opacity": [{
3156
- "placeholder-opacity": [k]
3230
+ "placeholder-opacity": [N]
3157
3231
  }],
3158
3232
  /**
3159
3233
  * Text Alignment
@@ -3174,7 +3248,7 @@ const H = (e) => {
3174
3248
  * @see https://tailwindcss.com/docs/text-opacity
3175
3249
  */
3176
3250
  "text-opacity": [{
3177
- "text-opacity": [k]
3251
+ "text-opacity": [N]
3178
3252
  }],
3179
3253
  /**
3180
3254
  * Text Decoration
@@ -3186,21 +3260,21 @@ const H = (e) => {
3186
3260
  * @see https://tailwindcss.com/docs/text-decoration-style
3187
3261
  */
3188
3262
  "text-decoration-style": [{
3189
- decoration: [...Y(), "wavy"]
3263
+ decoration: [...j(), "wavy"]
3190
3264
  }],
3191
3265
  /**
3192
3266
  * Text Decoration Thickness
3193
3267
  * @see https://tailwindcss.com/docs/text-decoration-thickness
3194
3268
  */
3195
3269
  "text-decoration-thickness": [{
3196
- decoration: ["auto", "from-font", j, X]
3270
+ decoration: ["auto", "from-font", _, Q]
3197
3271
  }],
3198
3272
  /**
3199
3273
  * Text Underline Offset
3200
3274
  * @see https://tailwindcss.com/docs/text-underline-offset
3201
3275
  */
3202
3276
  "underline-offset": [{
3203
- "underline-offset": ["auto", j, I]
3277
+ "underline-offset": ["auto", _, M]
3204
3278
  }],
3205
3279
  /**
3206
3280
  * Text Decoration Color
@@ -3238,7 +3312,7 @@ const H = (e) => {
3238
3312
  * @see https://tailwindcss.com/docs/vertical-align
3239
3313
  */
3240
3314
  "vertical-align": [{
3241
- align: ["baseline", "top", "middle", "bottom", "text-top", "text-bottom", "sub", "super", I]
3315
+ align: ["baseline", "top", "middle", "bottom", "text-top", "text-bottom", "sub", "super", M]
3242
3316
  }],
3243
3317
  /**
3244
3318
  * Whitespace
@@ -3266,7 +3340,7 @@ const H = (e) => {
3266
3340
  * @see https://tailwindcss.com/docs/content
3267
3341
  */
3268
3342
  content: [{
3269
- content: ["none", I]
3343
+ content: ["none", M]
3270
3344
  }],
3271
3345
  // Backgrounds
3272
3346
  /**
@@ -3289,7 +3363,7 @@ const H = (e) => {
3289
3363
  * @see https://tailwindcss.com/docs/background-opacity
3290
3364
  */
3291
3365
  "bg-opacity": [{
3292
- "bg-opacity": [k]
3366
+ "bg-opacity": [N]
3293
3367
  }],
3294
3368
  /**
3295
3369
  * Background Origin
@@ -3303,7 +3377,7 @@ const H = (e) => {
3303
3377
  * @see https://tailwindcss.com/docs/background-position
3304
3378
  */
3305
3379
  "bg-position": [{
3306
- bg: [...Z(), fn]
3380
+ bg: [...K(), Nn]
3307
3381
  }],
3308
3382
  /**
3309
3383
  * Background Repeat
@@ -3319,7 +3393,7 @@ const H = (e) => {
3319
3393
  * @see https://tailwindcss.com/docs/background-size
3320
3394
  */
3321
3395
  "bg-size": [{
3322
- bg: ["auto", "cover", "contain", pn]
3396
+ bg: ["auto", "cover", "contain", kn]
3323
3397
  }],
3324
3398
  /**
3325
3399
  * Background Image
@@ -3328,7 +3402,7 @@ const H = (e) => {
3328
3402
  "bg-image": [{
3329
3403
  bg: ["none", {
3330
3404
  "gradient-to": ["t", "tr", "r", "br", "b", "bl", "l", "tl"]
3331
- }, mn]
3405
+ }, Sn]
3332
3406
  }],
3333
3407
  /**
3334
3408
  * Background Color
@@ -3342,21 +3416,21 @@ const H = (e) => {
3342
3416
  * @see https://tailwindcss.com/docs/gradient-color-stops
3343
3417
  */
3344
3418
  "gradient-from-pos": [{
3345
- from: [y]
3419
+ from: [w]
3346
3420
  }],
3347
3421
  /**
3348
3422
  * Gradient Color Stops Via Position
3349
3423
  * @see https://tailwindcss.com/docs/gradient-color-stops
3350
3424
  */
3351
3425
  "gradient-via-pos": [{
3352
- via: [y]
3426
+ via: [w]
3353
3427
  }],
3354
3428
  /**
3355
3429
  * Gradient Color Stops To Position
3356
3430
  * @see https://tailwindcss.com/docs/gradient-color-stops
3357
3431
  */
3358
3432
  "gradient-to-pos": [{
3359
- to: [y]
3433
+ to: [w]
3360
3434
  }],
3361
3435
  /**
3362
3436
  * Gradient Color Stops From
@@ -3490,84 +3564,84 @@ const H = (e) => {
3490
3564
  * @see https://tailwindcss.com/docs/border-width
3491
3565
  */
3492
3566
  "border-w": [{
3493
- border: [c]
3567
+ border: [a]
3494
3568
  }],
3495
3569
  /**
3496
3570
  * Border Width X
3497
3571
  * @see https://tailwindcss.com/docs/border-width
3498
3572
  */
3499
3573
  "border-w-x": [{
3500
- "border-x": [c]
3574
+ "border-x": [a]
3501
3575
  }],
3502
3576
  /**
3503
3577
  * Border Width Y
3504
3578
  * @see https://tailwindcss.com/docs/border-width
3505
3579
  */
3506
3580
  "border-w-y": [{
3507
- "border-y": [c]
3581
+ "border-y": [a]
3508
3582
  }],
3509
3583
  /**
3510
3584
  * Border Width Start
3511
3585
  * @see https://tailwindcss.com/docs/border-width
3512
3586
  */
3513
3587
  "border-w-s": [{
3514
- "border-s": [c]
3588
+ "border-s": [a]
3515
3589
  }],
3516
3590
  /**
3517
3591
  * Border Width End
3518
3592
  * @see https://tailwindcss.com/docs/border-width
3519
3593
  */
3520
3594
  "border-w-e": [{
3521
- "border-e": [c]
3595
+ "border-e": [a]
3522
3596
  }],
3523
3597
  /**
3524
3598
  * Border Width Top
3525
3599
  * @see https://tailwindcss.com/docs/border-width
3526
3600
  */
3527
3601
  "border-w-t": [{
3528
- "border-t": [c]
3602
+ "border-t": [a]
3529
3603
  }],
3530
3604
  /**
3531
3605
  * Border Width Right
3532
3606
  * @see https://tailwindcss.com/docs/border-width
3533
3607
  */
3534
3608
  "border-w-r": [{
3535
- "border-r": [c]
3609
+ "border-r": [a]
3536
3610
  }],
3537
3611
  /**
3538
3612
  * Border Width Bottom
3539
3613
  * @see https://tailwindcss.com/docs/border-width
3540
3614
  */
3541
3615
  "border-w-b": [{
3542
- "border-b": [c]
3616
+ "border-b": [a]
3543
3617
  }],
3544
3618
  /**
3545
3619
  * Border Width Left
3546
3620
  * @see https://tailwindcss.com/docs/border-width
3547
3621
  */
3548
3622
  "border-w-l": [{
3549
- "border-l": [c]
3623
+ "border-l": [a]
3550
3624
  }],
3551
3625
  /**
3552
3626
  * Border Opacity
3553
3627
  * @see https://tailwindcss.com/docs/border-opacity
3554
3628
  */
3555
3629
  "border-opacity": [{
3556
- "border-opacity": [k]
3630
+ "border-opacity": [N]
3557
3631
  }],
3558
3632
  /**
3559
3633
  * Border Style
3560
3634
  * @see https://tailwindcss.com/docs/border-style
3561
3635
  */
3562
3636
  "border-style": [{
3563
- border: [...Y(), "hidden"]
3637
+ border: [...j(), "hidden"]
3564
3638
  }],
3565
3639
  /**
3566
3640
  * Divide Width X
3567
3641
  * @see https://tailwindcss.com/docs/divide-width
3568
3642
  */
3569
3643
  "divide-x": [{
3570
- "divide-x": [c]
3644
+ "divide-x": [a]
3571
3645
  }],
3572
3646
  /**
3573
3647
  * Divide Width X Reverse
@@ -3579,7 +3653,7 @@ const H = (e) => {
3579
3653
  * @see https://tailwindcss.com/docs/divide-width
3580
3654
  */
3581
3655
  "divide-y": [{
3582
- "divide-y": [c]
3656
+ "divide-y": [a]
3583
3657
  }],
3584
3658
  /**
3585
3659
  * Divide Width Y Reverse
@@ -3591,14 +3665,14 @@ const H = (e) => {
3591
3665
  * @see https://tailwindcss.com/docs/divide-opacity
3592
3666
  */
3593
3667
  "divide-opacity": [{
3594
- "divide-opacity": [k]
3668
+ "divide-opacity": [N]
3595
3669
  }],
3596
3670
  /**
3597
3671
  * Divide Style
3598
3672
  * @see https://tailwindcss.com/docs/divide-style
3599
3673
  */
3600
3674
  "divide-style": [{
3601
- divide: Y()
3675
+ divide: j()
3602
3676
  }],
3603
3677
  /**
3604
3678
  * Border Color
@@ -3675,21 +3749,21 @@ const H = (e) => {
3675
3749
  * @see https://tailwindcss.com/docs/outline-style
3676
3750
  */
3677
3751
  "outline-style": [{
3678
- outline: ["", ...Y()]
3752
+ outline: ["", ...j()]
3679
3753
  }],
3680
3754
  /**
3681
3755
  * Outline Offset
3682
3756
  * @see https://tailwindcss.com/docs/outline-offset
3683
3757
  */
3684
3758
  "outline-offset": [{
3685
- "outline-offset": [j, I]
3759
+ "outline-offset": [_, M]
3686
3760
  }],
3687
3761
  /**
3688
3762
  * Outline Width
3689
3763
  * @see https://tailwindcss.com/docs/outline-width
3690
3764
  */
3691
3765
  "outline-w": [{
3692
- outline: [j, X]
3766
+ outline: [_, Q]
3693
3767
  }],
3694
3768
  /**
3695
3769
  * Outline Color
@@ -3703,7 +3777,7 @@ const H = (e) => {
3703
3777
  * @see https://tailwindcss.com/docs/ring-width
3704
3778
  */
3705
3779
  "ring-w": [{
3706
- ring: P()
3780
+ ring: z()
3707
3781
  }],
3708
3782
  /**
3709
3783
  * Ring Width Inset
@@ -3722,14 +3796,14 @@ const H = (e) => {
3722
3796
  * @see https://tailwindcss.com/docs/ring-opacity
3723
3797
  */
3724
3798
  "ring-opacity": [{
3725
- "ring-opacity": [k]
3799
+ "ring-opacity": [N]
3726
3800
  }],
3727
3801
  /**
3728
3802
  * Ring Offset Width
3729
3803
  * @see https://tailwindcss.com/docs/ring-offset-width
3730
3804
  */
3731
3805
  "ring-offset-w": [{
3732
- "ring-offset": [j, X]
3806
+ "ring-offset": [_, Q]
3733
3807
  }],
3734
3808
  /**
3735
3809
  * Ring Offset Color
@@ -3744,35 +3818,35 @@ const H = (e) => {
3744
3818
  * @see https://tailwindcss.com/docs/box-shadow
3745
3819
  */
3746
3820
  shadow: [{
3747
- shadow: ["", "inner", "none", J, gn]
3821
+ shadow: ["", "inner", "none", ee, Cn]
3748
3822
  }],
3749
3823
  /**
3750
3824
  * Box Shadow Color
3751
3825
  * @see https://tailwindcss.com/docs/box-shadow-color
3752
3826
  */
3753
3827
  "shadow-color": [{
3754
- shadow: [le]
3828
+ shadow: [de]
3755
3829
  }],
3756
3830
  /**
3757
3831
  * Opacity
3758
3832
  * @see https://tailwindcss.com/docs/opacity
3759
3833
  */
3760
3834
  opacity: [{
3761
- opacity: [k]
3835
+ opacity: [N]
3762
3836
  }],
3763
3837
  /**
3764
3838
  * Mix Blend Mode
3765
3839
  * @see https://tailwindcss.com/docs/mix-blend-mode
3766
3840
  */
3767
3841
  "mix-blend": [{
3768
- "mix-blend": [...M(), "plus-lighter", "plus-darker"]
3842
+ "mix-blend": [...E(), "plus-lighter", "plus-darker"]
3769
3843
  }],
3770
3844
  /**
3771
3845
  * Background Blend Mode
3772
3846
  * @see https://tailwindcss.com/docs/background-blend-mode
3773
3847
  */
3774
3848
  "bg-blend": [{
3775
- "bg-blend": M()
3849
+ "bg-blend": E()
3776
3850
  }],
3777
3851
  // Filters
3778
3852
  /**
@@ -3809,7 +3883,7 @@ const H = (e) => {
3809
3883
  * @see https://tailwindcss.com/docs/drop-shadow
3810
3884
  */
3811
3885
  "drop-shadow": [{
3812
- "drop-shadow": ["", "none", J, I]
3886
+ "drop-shadow": ["", "none", ee, M]
3813
3887
  }],
3814
3888
  /**
3815
3889
  * Grayscale
@@ -3844,7 +3918,7 @@ const H = (e) => {
3844
3918
  * @see https://tailwindcss.com/docs/sepia
3845
3919
  */
3846
3920
  sepia: [{
3847
- sepia: [N]
3921
+ sepia: [A]
3848
3922
  }],
3849
3923
  /**
3850
3924
  * Backdrop Filter
@@ -3901,7 +3975,7 @@ const H = (e) => {
3901
3975
  * @see https://tailwindcss.com/docs/backdrop-opacity
3902
3976
  */
3903
3977
  "backdrop-opacity": [{
3904
- "backdrop-opacity": [k]
3978
+ "backdrop-opacity": [N]
3905
3979
  }],
3906
3980
  /**
3907
3981
  * Backdrop Saturate
@@ -3915,7 +3989,7 @@ const H = (e) => {
3915
3989
  * @see https://tailwindcss.com/docs/backdrop-sepia
3916
3990
  */
3917
3991
  "backdrop-sepia": [{
3918
- "backdrop-sepia": [N]
3992
+ "backdrop-sepia": [A]
3919
3993
  }],
3920
3994
  // Tables
3921
3995
  /**
@@ -3930,21 +4004,21 @@ const H = (e) => {
3930
4004
  * @see https://tailwindcss.com/docs/border-spacing
3931
4005
  */
3932
4006
  "border-spacing": [{
3933
- "border-spacing": [a]
4007
+ "border-spacing": [c]
3934
4008
  }],
3935
4009
  /**
3936
4010
  * Border Spacing X
3937
4011
  * @see https://tailwindcss.com/docs/border-spacing
3938
4012
  */
3939
4013
  "border-spacing-x": [{
3940
- "border-spacing-x": [a]
4014
+ "border-spacing-x": [c]
3941
4015
  }],
3942
4016
  /**
3943
4017
  * Border Spacing Y
3944
4018
  * @see https://tailwindcss.com/docs/border-spacing
3945
4019
  */
3946
4020
  "border-spacing-y": [{
3947
- "border-spacing-y": [a]
4021
+ "border-spacing-y": [c]
3948
4022
  }],
3949
4023
  /**
3950
4024
  * Table Layout
@@ -3966,35 +4040,35 @@ const H = (e) => {
3966
4040
  * @see https://tailwindcss.com/docs/transition-property
3967
4041
  */
3968
4042
  transition: [{
3969
- transition: ["none", "all", "", "colors", "opacity", "shadow", "transform", I]
4043
+ transition: ["none", "all", "", "colors", "opacity", "shadow", "transform", M]
3970
4044
  }],
3971
4045
  /**
3972
4046
  * Transition Duration
3973
4047
  * @see https://tailwindcss.com/docs/transition-duration
3974
4048
  */
3975
4049
  duration: [{
3976
- duration: V()
4050
+ duration: F()
3977
4051
  }],
3978
4052
  /**
3979
4053
  * Transition Timing Function
3980
4054
  * @see https://tailwindcss.com/docs/transition-timing-function
3981
4055
  */
3982
4056
  ease: [{
3983
- ease: ["linear", "in", "out", "in-out", I]
4057
+ ease: ["linear", "in", "out", "in-out", M]
3984
4058
  }],
3985
4059
  /**
3986
4060
  * Transition Delay
3987
4061
  * @see https://tailwindcss.com/docs/transition-delay
3988
4062
  */
3989
4063
  delay: [{
3990
- delay: V()
4064
+ delay: F()
3991
4065
  }],
3992
4066
  /**
3993
4067
  * Animation
3994
4068
  * @see https://tailwindcss.com/docs/animation
3995
4069
  */
3996
4070
  animate: [{
3997
- animate: ["none", "spin", "ping", "pulse", "bounce", I]
4071
+ animate: ["none", "spin", "ping", "pulse", "bounce", M]
3998
4072
  }],
3999
4073
  // Transforms
4000
4074
  /**
@@ -4030,21 +4104,21 @@ const H = (e) => {
4030
4104
  * @see https://tailwindcss.com/docs/rotate
4031
4105
  */
4032
4106
  rotate: [{
4033
- rotate: [ae, I]
4107
+ rotate: [le, M]
4034
4108
  }],
4035
4109
  /**
4036
4110
  * Translate X
4037
4111
  * @see https://tailwindcss.com/docs/translate
4038
4112
  */
4039
4113
  "translate-x": [{
4040
- "translate-x": [T]
4114
+ "translate-x": [L]
4041
4115
  }],
4042
4116
  /**
4043
4117
  * Translate Y
4044
4118
  * @see https://tailwindcss.com/docs/translate
4045
4119
  */
4046
4120
  "translate-y": [{
4047
- "translate-y": [T]
4121
+ "translate-y": [L]
4048
4122
  }],
4049
4123
  /**
4050
4124
  * Skew X
@@ -4065,7 +4139,7 @@ const H = (e) => {
4065
4139
  * @see https://tailwindcss.com/docs/transform-origin
4066
4140
  */
4067
4141
  "transform-origin": [{
4068
- origin: ["center", "top", "top-right", "right", "bottom-right", "bottom", "bottom-left", "left", "top-left", I]
4142
+ origin: ["center", "top", "top-right", "right", "bottom-right", "bottom", "bottom-left", "left", "top-left", M]
4069
4143
  }],
4070
4144
  // Interactivity
4071
4145
  /**
@@ -4087,7 +4161,7 @@ const H = (e) => {
4087
4161
  * @see https://tailwindcss.com/docs/cursor
4088
4162
  */
4089
4163
  cursor: [{
4090
- cursor: ["auto", "default", "pointer", "wait", "text", "move", "help", "not-allowed", "none", "context-menu", "progress", "cell", "crosshair", "vertical-text", "alias", "copy", "no-drop", "grab", "grabbing", "all-scroll", "col-resize", "row-resize", "n-resize", "e-resize", "s-resize", "w-resize", "ne-resize", "nw-resize", "se-resize", "sw-resize", "ew-resize", "ns-resize", "nesw-resize", "nwse-resize", "zoom-in", "zoom-out", I]
4164
+ cursor: ["auto", "default", "pointer", "wait", "text", "move", "help", "not-allowed", "none", "context-menu", "progress", "cell", "crosshair", "vertical-text", "alias", "copy", "no-drop", "grab", "grabbing", "all-scroll", "col-resize", "row-resize", "n-resize", "e-resize", "s-resize", "w-resize", "ne-resize", "nw-resize", "se-resize", "sw-resize", "ew-resize", "ns-resize", "nesw-resize", "nwse-resize", "zoom-in", "zoom-out", M]
4091
4165
  }],
4092
4166
  /**
4093
4167
  * Caret Color
@@ -4309,7 +4383,7 @@ const H = (e) => {
4309
4383
  * @see https://tailwindcss.com/docs/will-change
4310
4384
  */
4311
4385
  "will-change": [{
4312
- "will-change": ["auto", "scroll", "contents", "transform", I]
4386
+ "will-change": ["auto", "scroll", "contents", "transform", M]
4313
4387
  }],
4314
4388
  // SVG
4315
4389
  /**
@@ -4324,7 +4398,7 @@ const H = (e) => {
4324
4398
  * @see https://tailwindcss.com/docs/stroke-width
4325
4399
  */
4326
4400
  "stroke-w": [{
4327
- stroke: [j, X, be]
4401
+ stroke: [_, Q, ke]
4328
4402
  }],
4329
4403
  /**
4330
4404
  * Stroke
@@ -4399,90 +4473,90 @@ const H = (e) => {
4399
4473
  "font-size": ["leading"]
4400
4474
  }
4401
4475
  };
4402
- }, xn = /* @__PURE__ */ tn(yn);
4403
- function kn(...e) {
4404
- return xn(gt(e));
4476
+ }, En = /* @__PURE__ */ pn(Rn);
4477
+ function Tn(...e) {
4478
+ return En(Ct(e));
4405
4479
  }
4406
- function or({ autoWidth: e = !0, className: t, style: n }) {
4407
- const [r, o] = E(() => _.getActiveAppId()), [i, a] = E(() => G.getRunningApps()), { isMobile: c } = Ke();
4480
+ function mr({ autoWidth: e = !0, className: t, style: n }) {
4481
+ const [r, o] = R(() => q.getActiveAppId()), [i, c] = R(() => Y.getRunningApps()), { isMobile: a } = et();
4408
4482
  B(() => {
4409
- const w = _.subscribe("activeAppId", (k) => {
4410
- o(k);
4483
+ const g = q.subscribe("activeAppId", (N) => {
4484
+ o(N);
4411
4485
  });
4412
4486
  return () => {
4413
- w();
4487
+ g();
4414
4488
  };
4415
- }, []), B(() => G.subscribe(() => {
4416
- a(G.getRunningApps());
4489
+ }, []), B(() => Y.subscribe(() => {
4490
+ c(Y.getRunningApps());
4417
4491
  }), []), B(() => {
4418
4492
  if (!new URLSearchParams(window.location.search).has("app")) {
4419
- const b = _.getActiveAppId();
4420
- b && !G.isRunning(b) && G.launchApp(b);
4493
+ const b = q.getActiveAppId();
4494
+ b && !Y.isRunning(b) && Y.launchApp(b);
4421
4495
  }
4422
4496
  }, []);
4423
- const l = (w) => {
4424
- G.closeApp(w);
4425
- }, u = r ? oe.get(r) : null, v = (u == null ? void 0 : u.width) ?? 400, d = r !== null, g = { ...{
4497
+ const l = (g) => {
4498
+ Y.closeApp(g);
4499
+ }, u = r ? ie.get(r) : null, v = (u == null ? void 0 : u.width) ?? 400, d = r !== null, y = { ...{
4426
4500
  overflow: "hidden",
4427
4501
  display: d ? "flex" : "none",
4428
4502
  flexDirection: "column",
4429
4503
  flexShrink: 0,
4430
4504
  // Only set width if autoWidth is enabled
4431
- ...e && d ? { width: c ? "100%" : v } : {}
4505
+ ...e && d ? { width: a ? "100%" : v } : {}
4432
4506
  }, ...n };
4433
- return /* @__PURE__ */ s("div", { className: kn("nc-app-panel", t), style: g, children: i.map((w) => /* @__PURE__ */ s(
4434
- Ye,
4507
+ return /* @__PURE__ */ s("div", { className: Tn("nc-app-panel", t), style: y, children: i.map((g) => /* @__PURE__ */ s(
4508
+ Je,
4435
4509
  {
4436
- appId: w.appId,
4437
- isActive: r === w.appId,
4438
- onClose: () => l(w.appId)
4510
+ appId: g.appId,
4511
+ isActive: r === g.appId,
4512
+ onClose: () => l(g.appId)
4439
4513
  },
4440
- w.appId
4514
+ g.appId
4441
4515
  )) });
4442
4516
  }
4443
- function sr({
4517
+ function gr({
4444
4518
  pinnedAppIds: e,
4445
4519
  className: t = "",
4446
4520
  showIndicators: n = !0,
4447
4521
  side: r = "left",
4448
4522
  getBadge: o
4449
4523
  }) {
4450
- const { t: i } = U(), { isMobile: a } = Ke(), [c, l] = E(() => _.getActiveAppId()), [u, f] = E(() => G.getRunningApps());
4524
+ const { t: i } = X(), { isMobile: c } = et(), [a, l] = R(() => q.getActiveAppId()), [u, f] = R(() => Y.getRunningApps());
4451
4525
  B(() => {
4452
- const p = _.subscribe("activeAppId", (h) => {
4526
+ const p = q.subscribe("activeAppId", (h) => {
4453
4527
  l(h);
4454
4528
  });
4455
4529
  return () => {
4456
4530
  p();
4457
4531
  };
4458
- }, []), B(() => G.subscribe(() => {
4459
- f(G.getRunningApps());
4532
+ }, []), B(() => Y.subscribe(() => {
4533
+ f(Y.getRunningApps());
4460
4534
  }), []);
4461
4535
  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);
4465
- return N ? /* @__PURE__ */ s(
4536
+ a === p ? Y.setActiveApp(null) : Y.launchApp(p);
4537
+ }, d = e.map((p) => ie.get(p)).filter((p) => !!p), m = u.filter((p) => !e.includes(p.appId)).map((p) => ({ running: p, def: ie.get(p.appId) })).filter((p) => !!p.def), w = (p) => u.some((h) => h.appId === p), y = (p) => p.titleKey ? String(i(p.titleKey)) : p.id, g = (p) => typeof p == "number" && p > 99 ? "99+" : p, N = (p, h) => {
4538
+ const A = o == null ? void 0 : o(p, h);
4539
+ return A ? /* @__PURE__ */ s(
4466
4540
  "span",
4467
4541
  {
4468
- className: `nc-app-taskbar-badge nc-${N.tone ?? "default"}`,
4469
- "aria-label": N.ariaLabel,
4470
- children: w(N.content)
4542
+ className: `nc-app-taskbar-badge nc-${A.tone ?? "default"}`,
4543
+ "aria-label": A.ariaLabel,
4544
+ children: g(A.content)
4471
4545
  }
4472
4546
  ) : null;
4473
- }, b = a ? 24 : 28;
4474
- return /* @__PURE__ */ A("div", { className: `nc-app-taskbar ${a ? "nc-mobile" : "nc-desktop"} nc-${r} ${t}`, children: [
4547
+ }, b = c ? 24 : 28;
4548
+ return /* @__PURE__ */ k("div", { className: `nc-app-taskbar ${c ? "nc-mobile" : "nc-desktop"} nc-${r} ${t}`, children: [
4475
4549
  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(
4550
+ const h = p.icon, A = a === p.id, C = w(p.id), T = { isActive: A, isRunning: C, isPinned: !0 };
4551
+ return /* @__PURE__ */ k(
4478
4552
  "button",
4479
4553
  {
4480
- className: `nc-app-taskbar-button ${N ? "nc-active" : ""} ${C ? "nc-running" : ""}`,
4554
+ className: `nc-app-taskbar-button ${A ? "nc-active" : ""} ${C ? "nc-running" : ""}`,
4481
4555
  onClick: () => v(p.id),
4482
- title: g(p),
4556
+ title: y(p),
4483
4557
  children: [
4484
4558
  /* @__PURE__ */ s(h, { size: b }),
4485
- k(p, z),
4559
+ N(p, T),
4486
4560
  n && C && /* @__PURE__ */ s("span", { className: "nc-app-taskbar-indicator" })
4487
4561
  ]
4488
4562
  },
@@ -4491,16 +4565,16 @@ function sr({
4491
4565
  }),
4492
4566
  m.length > 0 && /* @__PURE__ */ s("div", { className: "nc-app-taskbar-separator" }),
4493
4567
  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(
4568
+ const A = h.icon, C = a === p.appId, T = { isActive: C, isRunning: !0, isPinned: !1 };
4569
+ return /* @__PURE__ */ k(
4496
4570
  "button",
4497
4571
  {
4498
4572
  className: `nc-app-taskbar-button ${C ? "nc-active" : ""} nc-running`,
4499
4573
  onClick: () => v(p.appId),
4500
- title: g(h),
4574
+ title: y(h),
4501
4575
  children: [
4502
- /* @__PURE__ */ s(N, { size: b }),
4503
- k(h, z),
4576
+ /* @__PURE__ */ s(A, { size: b }),
4577
+ N(h, T),
4504
4578
  n && /* @__PURE__ */ s("span", { className: "nc-app-taskbar-indicator" })
4505
4579
  ]
4506
4580
  },
@@ -4509,7 +4583,7 @@ function sr({
4509
4583
  })
4510
4584
  ] });
4511
4585
  }
4512
- function ir({
4586
+ function br({
4513
4587
  appId: e,
4514
4588
  open: t,
4515
4589
  onClose: n,
@@ -4517,15 +4591,15 @@ function ir({
4517
4591
  className: o = "",
4518
4592
  style: i
4519
4593
  }) {
4520
- const a = (l) => {
4594
+ const c = (l) => {
4521
4595
  r && l.target === l.currentTarget && n();
4522
4596
  };
4523
4597
  if (!t) return null;
4524
- const c = /* @__PURE__ */ s(
4598
+ const a = /* @__PURE__ */ s(
4525
4599
  "div",
4526
4600
  {
4527
4601
  className: "nc-dialog-overlay nc-fullscreen",
4528
- onClick: a,
4602
+ onClick: c,
4529
4603
  children: /* @__PURE__ */ s(
4530
4604
  "div",
4531
4605
  {
@@ -4533,7 +4607,7 @@ function ir({
4533
4607
  style: i,
4534
4608
  onClick: (l) => l.stopPropagation(),
4535
4609
  children: /* @__PURE__ */ s(
4536
- Ye,
4610
+ Je,
4537
4611
  {
4538
4612
  appId: e,
4539
4613
  isActive: !0,
@@ -4544,86 +4618,86 @@ function ir({
4544
4618
  )
4545
4619
  }
4546
4620
  );
4547
- return ue(c, document.body);
4621
+ return pe(a, document.body);
4548
4622
  }
4549
- const Ae = se(null), Qe = se(null);
4550
- function cr() {
4551
- const e = Q(Ae);
4623
+ const Ie = ce(null), it = ce(null);
4624
+ function vr() {
4625
+ const e = te(Ie);
4552
4626
  if (!e)
4553
4627
  throw new Error("useNavStack must be used within a NavStackProvider");
4554
4628
  return e;
4555
4629
  }
4556
- function ar() {
4557
- const e = Q(Qe);
4630
+ function wr() {
4631
+ const e = te(it);
4558
4632
  if (!e)
4559
4633
  throw new Error("useNavView must be used within NavStack");
4560
4634
  return e;
4561
4635
  }
4562
- const Se = se(null);
4563
- function lr({ rootView: e, children: t }) {
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;
4636
+ const Re = ce(null);
4637
+ function yr({ rootView: e, children: t }) {
4638
+ const { t: n } = X(), r = qt(), [o, i] = R([e]), [c, a] = R([null]), l = O((h, A) => {
4639
+ a((C) => {
4640
+ const T = [...C];
4641
+ return T[h] = A, T;
4568
4642
  });
4569
4643
  }, []), u = O((h) => {
4570
- c((N) => {
4571
- const C = [...N];
4644
+ a((A) => {
4645
+ const C = [...A];
4572
4646
  return C[h] = null, C;
4573
4647
  });
4574
4648
  }, []), f = O((h) => {
4575
- i((N) => [...N, h]), c((N) => [...N, null]);
4649
+ i((A) => [...A, h]), a((A) => [...A, null]);
4576
4650
  }, []), v = O(() => {
4577
- i((h) => h.length <= 1 ? h : h.slice(0, -1)), c((h) => h.slice(0, -1));
4651
+ i((h) => h.length <= 1 ? h : h.slice(0, -1)), a((h) => h.slice(0, -1));
4578
4652
  }, []), d = O(() => {
4579
- i([e]), c([null]);
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) ?? "";
4653
+ i([e]), a([null]);
4654
+ }, [e]), m = o.length, w = m > 1, y = o.length - 1, g = o[o.length - 1], N = g != null && g.titleKey ? n(g.titleKey) : (g == null ? void 0 : g.title) ?? "";
4581
4655
  B(() => {
4582
- r.setTitle(k);
4583
- }, [k, r]), B(() => {
4584
- y ? r.setBackHandler(v) : r.clearBackHandler();
4585
- }, [y, v, r]), B(() => {
4586
- const h = a[a.length - 1];
4656
+ r.setTitle(N);
4657
+ }, [N, r]), B(() => {
4658
+ w ? r.setBackHandler(v) : r.clearBackHandler();
4659
+ }, [w, v, r]), B(() => {
4660
+ const h = c[c.length - 1];
4587
4661
  h ? r.setToolbar(h) : r.clearToolbar();
4588
- }, [a, r]);
4662
+ }, [c, r]);
4589
4663
  const b = {
4590
4664
  push: f,
4591
4665
  pop: v,
4592
4666
  reset: d,
4593
4667
  depth: m,
4594
- canGoBack: y,
4595
- currentTitle: k
4668
+ canGoBack: w,
4669
+ currentTitle: N
4596
4670
  }, p = {
4597
4671
  stack: o,
4598
- toolbarStack: a,
4672
+ toolbarStack: c,
4599
4673
  updateToolbar: l,
4600
4674
  clearToolbarAt: u,
4601
- topIndex: g
4675
+ topIndex: y
4602
4676
  };
4603
- return /* @__PURE__ */ s(Ae.Provider, { value: b, children: /* @__PURE__ */ s(Se.Provider, { value: p, children: t }) });
4677
+ return /* @__PURE__ */ s(Ie.Provider, { value: b, children: /* @__PURE__ */ s(Re.Provider, { value: p, children: t }) });
4604
4678
  }
4605
- function Nn({ index: e, children: t }) {
4606
- const n = Q(Se);
4679
+ function Pn({ index: e, children: t }) {
4680
+ const n = te(Re);
4607
4681
  if (!n)
4608
4682
  throw new Error("NavViewProvider must be used within NavStackProvider");
4609
- const { updateToolbar: r, clearToolbarAt: o, topIndex: i } = n, a = O((u) => {
4683
+ const { updateToolbar: r, clearToolbarAt: o, topIndex: i } = n, c = O((u) => {
4610
4684
  e === i && r(e, u);
4611
- }, [e, i, r]), c = O(() => {
4685
+ }, [e, i, r]), a = O(() => {
4612
4686
  e === i && o(e);
4613
4687
  }, [e, i, o]), l = {
4614
- setToolbar: a,
4615
- clearToolbar: c
4688
+ setToolbar: c,
4689
+ clearToolbar: a
4616
4690
  };
4617
- return /* @__PURE__ */ s(Qe.Provider, { value: l, children: t });
4691
+ return /* @__PURE__ */ s(it.Provider, { value: l, children: t });
4618
4692
  }
4619
- function dr() {
4620
- const e = Q(Ae), t = Q(Se);
4693
+ function xr() {
4694
+ const e = te(Ie), t = te(Re);
4621
4695
  if (!e || !t)
4622
4696
  throw new Error("NavStackContainer must be used within a NavStackProvider");
4623
4697
  const { stack: n } = t;
4624
4698
  return /* @__PURE__ */ s("div", { className: "nav-stack-container", children: /* @__PURE__ */ s("div", { className: "nav-stack-content", children: n.map((r, o) => {
4625
4699
  const i = o === n.length - 1;
4626
- return /* @__PURE__ */ s(Nn, { index: o, children: /* @__PURE__ */ s(
4700
+ return /* @__PURE__ */ s(Pn, { index: o, children: /* @__PURE__ */ s(
4627
4701
  "div",
4628
4702
  {
4629
4703
  style: { display: i ? "flex" : "none", flexDirection: "column", height: "100%" },
@@ -4633,56 +4707,55 @@ function dr() {
4633
4707
  }) }) });
4634
4708
  }
4635
4709
  export {
4636
- He as ActivityIndicator,
4637
- Tn as Alert,
4638
- Ye as AppContainer,
4639
- Ve as AppContext,
4640
- ir as AppDialog,
4641
- or as AppPanel,
4642
- sr as AppTaskbar,
4643
- Ft as AppTitleBar,
4644
- zn as Battery,
4645
- K as Button,
4646
- Pn as ButtonGroup,
4647
- Ln as Checkbox,
4648
- We as CloseButton,
4649
- Bn as ComboBox,
4650
- Fn as ContextMenu,
4651
- Zn as CsvTextArea,
4652
- Vn as Dialog,
4653
- ne as DialogClose,
4654
- Hn as EditButton,
4655
- On as Hyperlink,
4656
- Yn as Input,
4657
- jn as ListGroup,
4658
- Gn as ListGroupItem,
4659
- _n as MonthRangePicker,
4660
- Kn as MultiSelect,
4661
- dr as NavStackContainer,
4662
- lr as NavStackProvider,
4663
- Pt as Notification,
4664
- er as NotificationContainer,
4665
- Un as NumberInput,
4666
- Dn as RefreshButton,
4667
- qn as Slider,
4668
- It as TabPanel,
4669
- Xn as TabPanels,
4670
- Jn as Tabs,
4671
- Qn as Toggle,
4672
- Wn as TrashButton,
4673
- rr as ViewportProvider,
4674
- fr as YamlTextArea,
4675
- oe as appRegistry,
4676
- _ as appStateStore,
4677
- kn as cn,
4678
- nr as createAppI18nFactory,
4679
- tr as notificationManager,
4680
- G as runningAppsStore,
4681
- Lt as showNotification,
4682
- Wt as useApp,
4683
- At as useDialog,
4684
- cr as useNavStack,
4685
- ar as useNavView,
4686
- Ke as useViewport
4710
+ Ke as ActivityIndicator,
4711
+ jn as Alert,
4712
+ Je as AppContainer,
4713
+ Xe as AppContext,
4714
+ br as AppDialog,
4715
+ mr as AppPanel,
4716
+ gr as AppTaskbar,
4717
+ Jt as AppTitleBar,
4718
+ Gn as Battery,
4719
+ U as Button,
4720
+ Yn as ButtonGroup,
4721
+ Kn as Checkbox,
4722
+ _e as CloseButton,
4723
+ _n as ComboBox,
4724
+ Zn as ContextMenu,
4725
+ dr as CsvTextArea,
4726
+ Qn as Dialog,
4727
+ oe as DialogClose,
4728
+ qn as EditButton,
4729
+ Jn as Hyperlink,
4730
+ er as Input,
4731
+ nr as ListGroup,
4732
+ tr as ListGroupItem,
4733
+ or as MonthRangePicker,
4734
+ rr as MultiSelect,
4735
+ xr as NavStackContainer,
4736
+ yr as NavStackProvider,
4737
+ Gt as Notification,
4738
+ ur as NotificationContainer,
4739
+ sr as NumberInput,
4740
+ Un as RefreshButton,
4741
+ ir as Slider,
4742
+ Dt as TabPanel,
4743
+ cr as TabPanels,
4744
+ ar as Tabs,
4745
+ lr as Toggle,
4746
+ Xn as TrashButton,
4747
+ hr as ViewportProvider,
4748
+ ie as appRegistry,
4749
+ q as appStateStore,
4750
+ Tn as cn,
4751
+ fr as createAppI18nFactory,
4752
+ pr as notificationManager,
4753
+ Y as runningAppsStore,
4754
+ Yt as showNotification,
4755
+ qt as useApp,
4756
+ Pt as useDialog,
4757
+ vr as useNavStack,
4758
+ wr as useNavView,
4759
+ et as useViewport
4687
4760
  };
4688
4761
  //# sourceMappingURL=index.js.map