@handamade/psi-react 0.11.0 → 0.13.0

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,21 +1,21 @@
1
1
  import { jsx as n, jsxs as p, Fragment as G } from "react/jsx-runtime";
2
- import { createContext as K, useId as U, useRef as B, useEffect as N, useContext as L, useState as le, useCallback as m, cloneElement as ee, isValidElement as O, useMemo as de, Children as W, Fragment as re } from "react";
3
- const ye = "_button_c94w9_3", me = "_disabled_c94w9_30", we = "_size24_c94w9_44", ke = "_size32_c94w9_54", xe = "_size40_c94w9_64", Ce = "_size48_c94w9_74", Be = "_accent_c94w9_87", Ne = "_accentSubtle_c94w9_99", $e = "_neutral_c94w9_111", Le = "_neutralSubtle_c94w9_123", je = "_ghost_c94w9_135", Se = "_danger_c94w9_147", ze = "_dangerSubtle_c94w9_159", Ie = "_outline_c94w9_171", w = {
4
- button: ye,
5
- disabled: me,
6
- size24: we,
7
- size32: ke,
8
- size40: xe,
9
- size48: Ce,
10
- accent: Be,
11
- accentSubtle: Ne,
12
- neutral: $e,
13
- neutralSubtle: Le,
14
- ghost: je,
15
- danger: Se,
16
- dangerSubtle: ze,
17
- outline: Ie
18
- }, Te = {
2
+ import { createContext as R, useId as H, useRef as x, useEffect as N, useContext as S, useState as he, useCallback as g, cloneElement as te, isValidElement as U, useMemo as ne, Children as A, Fragment as ae } from "react";
3
+ const Ce = "_button_c94w9_3", Be = "_disabled_c94w9_30", $e = "_size24_c94w9_44", Ne = "_size32_c94w9_54", Le = "_size40_c94w9_64", Se = "_size48_c94w9_74", ze = "_accent_c94w9_87", je = "_accentSubtle_c94w9_99", Te = "_neutral_c94w9_111", Ie = "_neutralSubtle_c94w9_123", Ee = "_ghost_c94w9_135", Me = "_danger_c94w9_147", Ae = "_dangerSubtle_c94w9_159", Pe = "_outline_c94w9_171", w = {
4
+ button: Ce,
5
+ disabled: Be,
6
+ size24: $e,
7
+ size32: Ne,
8
+ size40: Le,
9
+ size48: Se,
10
+ accent: ze,
11
+ accentSubtle: je,
12
+ neutral: Te,
13
+ neutralSubtle: Ie,
14
+ ghost: Ee,
15
+ danger: Me,
16
+ dangerSubtle: Ae,
17
+ outline: Pe
18
+ }, We = {
19
19
  accent: w.accent,
20
20
  "accent-subtle": w.accentSubtle,
21
21
  neutral: w.neutral,
@@ -24,13 +24,13 @@ const ye = "_button_c94w9_3", me = "_disabled_c94w9_30", we = "_size24_c94w9_44"
24
24
  danger: w.danger,
25
25
  "danger-subtle": w.dangerSubtle,
26
26
  outline: w.outline
27
- }, Ee = {
27
+ }, De = {
28
28
  24: w.size24,
29
29
  32: w.size32,
30
30
  40: w.size40,
31
31
  48: w.size48
32
32
  };
33
- function Me({
33
+ function Re({
34
34
  variant: e = "neutral",
35
35
  size: t = 32,
36
36
  href: i,
@@ -39,60 +39,60 @@ function Me({
39
39
  disabled: r,
40
40
  className: o,
41
41
  onClick: s,
42
- ref: l,
43
- ...d
42
+ ref: d,
43
+ ...l
44
44
  }) {
45
45
  const u = [
46
46
  w.button,
47
- Te[e],
48
- Ee[t],
47
+ We[e],
48
+ De[t],
49
49
  i !== void 0 && r ? w.disabled : void 0,
50
50
  o
51
51
  ].filter(Boolean).join(" ");
52
52
  return i !== void 0 ? /* @__PURE__ */ n(
53
53
  "a",
54
54
  {
55
- ref: l,
55
+ ref: d,
56
56
  className: u,
57
57
  href: r ? void 0 : i,
58
58
  target: a,
59
59
  rel: c,
60
60
  "aria-disabled": r || void 0,
61
61
  onClick: r ? void 0 : s,
62
- ...d
62
+ ...l
63
63
  }
64
64
  ) : /* @__PURE__ */ n(
65
65
  "button",
66
66
  {
67
- ref: l,
67
+ ref: d,
68
68
  className: u,
69
69
  disabled: r,
70
70
  onClick: s,
71
- ...d
71
+ ...l
72
72
  }
73
73
  );
74
74
  }
75
- const We = "_iconButton_129ca_3", Ae = "_disabled_129ca_29", Pe = "_size24_129ca_37", De = "_size32_129ca_42", Re = "_size40_129ca_47", He = "_size48_129ca_52", Ve = "_accent_129ca_60", qe = "_neutral_129ca_72", Fe = "_ghost_129ca_84", Oe = "_danger_129ca_96", $ = {
76
- iconButton: We,
77
- disabled: Ae,
78
- size24: Pe,
79
- size32: De,
80
- size40: Re,
81
- size48: He,
82
- accent: Ve,
83
- neutral: qe,
84
- ghost: Fe,
85
- danger: Oe
86
- }, Ke = {
87
- accent: $.accent,
88
- neutral: $.neutral,
89
- ghost: $.ghost,
90
- danger: $.danger
91
- }, Ue = {
92
- 24: $.size24,
93
- 32: $.size32,
94
- 40: $.size40,
95
- 48: $.size48
75
+ const He = "_iconButton_129ca_3", Ve = "_disabled_129ca_29", qe = "_size24_129ca_37", Fe = "_size32_129ca_42", Ke = "_size40_129ca_47", Oe = "_size48_129ca_52", Ue = "_accent_129ca_60", Ye = "_neutral_129ca_72", Ze = "_ghost_129ca_84", Ge = "_danger_129ca_96", z = {
76
+ iconButton: He,
77
+ disabled: Ve,
78
+ size24: qe,
79
+ size32: Fe,
80
+ size40: Ke,
81
+ size48: Oe,
82
+ accent: Ue,
83
+ neutral: Ye,
84
+ ghost: Ze,
85
+ danger: Ge
86
+ }, Xe = {
87
+ accent: z.accent,
88
+ neutral: z.neutral,
89
+ ghost: z.ghost,
90
+ danger: z.danger
91
+ }, Je = {
92
+ 24: z.size24,
93
+ 32: z.size32,
94
+ 40: z.size40,
95
+ 48: z.size48
96
96
  };
97
97
  function X({
98
98
  variant: e = "neutral",
@@ -103,48 +103,48 @@ function X({
103
103
  disabled: r,
104
104
  className: o,
105
105
  onClick: s,
106
- ref: l,
107
- ...d
106
+ ref: d,
107
+ ...l
108
108
  }) {
109
109
  const u = [
110
- $.iconButton,
111
- Ke[e],
112
- Ue[t],
113
- i !== void 0 && r ? $.disabled : void 0,
110
+ z.iconButton,
111
+ Xe[e],
112
+ Je[t],
113
+ i !== void 0 && r ? z.disabled : void 0,
114
114
  o
115
115
  ].filter(Boolean).join(" ");
116
116
  return i !== void 0 ? /* @__PURE__ */ n(
117
117
  "a",
118
118
  {
119
- ref: l,
119
+ ref: d,
120
120
  className: u,
121
121
  href: r ? void 0 : i,
122
122
  target: a,
123
123
  rel: c,
124
124
  "aria-disabled": r || void 0,
125
125
  onClick: r ? void 0 : s,
126
- ...d
126
+ ...l
127
127
  }
128
128
  ) : /* @__PURE__ */ n(
129
129
  "button",
130
130
  {
131
- ref: l,
131
+ ref: d,
132
132
  className: u,
133
133
  disabled: r,
134
134
  onClick: s,
135
- ...d
135
+ ...l
136
136
  }
137
137
  );
138
138
  }
139
- const Ye = "_card_1btb3_1", Ze = "_stacked_1btb3_8", Ge = "_featured_1btb3_10", Xe = "_media_1btb3_22", Je = "_body_1btb3_23", Qe = "_hoverLift_1btb3_31", T = {
140
- card: Ye,
141
- stacked: Ze,
142
- featured: Ge,
143
- media: Xe,
144
- body: Je,
145
- hoverLift: Qe
139
+ const Qe = "_card_1btb3_1", et = "_stacked_1btb3_8", tt = "_featured_1btb3_10", nt = "_media_1btb3_22", ot = "_body_1btb3_23", rt = "_hoverLift_1btb3_31", I = {
140
+ card: Qe,
141
+ stacked: et,
142
+ featured: tt,
143
+ media: nt,
144
+ body: ot,
145
+ hoverLift: rt
146
146
  };
147
- function po({
147
+ function So({
148
148
  variant: e = "stacked",
149
149
  media: t,
150
150
  hoverLift: i = !1,
@@ -154,54 +154,54 @@ function po({
154
154
  ...o
155
155
  }) {
156
156
  const s = [
157
- T.card,
158
- e === "featured" ? T.featured : T.stacked,
159
- i ? T.hoverLift : void 0,
157
+ I.card,
158
+ e === "featured" ? I.featured : I.stacked,
159
+ i ? I.hoverLift : void 0,
160
160
  a
161
161
  ].filter(Boolean).join(" ");
162
162
  return /* @__PURE__ */ p("div", { ref: r, className: s, ...o, children: [
163
- t != null && /* @__PURE__ */ n("div", { className: T.media, children: t }),
164
- /* @__PURE__ */ n("div", { className: T.body, children: c })
163
+ t != null && /* @__PURE__ */ n("div", { className: I.media, children: t }),
164
+ /* @__PURE__ */ n("div", { className: I.body, children: c })
165
165
  ] });
166
166
  }
167
- const et = "_panel_jn8w4_1", tt = "_padding16_jn8w4_8", ie = {
168
- panel: et,
169
- padding16: tt
167
+ const it = "_panel_jn8w4_1", st = "_padding16_jn8w4_8", ce = {
168
+ panel: it,
169
+ padding16: st
170
170
  };
171
- function vo({ padding: e = 24, className: t, children: i, ref: a, ...c }) {
172
- const r = [ie.panel, e === 16 ? ie.padding16 : void 0, t].filter(Boolean).join(" ");
171
+ function zo({ padding: e = 24, className: t, children: i, ref: a, ...c }) {
172
+ const r = [ce.panel, e === 16 ? ce.padding16 : void 0, t].filter(Boolean).join(" ");
173
173
  return /* @__PURE__ */ n("div", { ref: a, className: r, ...c, children: i });
174
174
  }
175
- const nt = "_navbar_1gyow_1", ot = "_inner_1gyow_12", rt = "_brand_1gyow_19", it = "_links_1gyow_20", st = "_actions_1gyow_50", V = {
176
- navbar: nt,
177
- inner: ot,
178
- brand: rt,
179
- links: it,
180
- actions: st
175
+ const at = "_navbar_1gyow_1", ct = "_inner_1gyow_12", lt = "_brand_1gyow_19", dt = "_links_1gyow_20", ut = "_actions_1gyow_50", F = {
176
+ navbar: at,
177
+ inner: ct,
178
+ brand: lt,
179
+ links: dt,
180
+ actions: ut
181
181
  };
182
- function go({ brand: e, actions: t, children: i, className: a, ref: c, ...r }) {
183
- const o = [V.navbar, a].filter(Boolean).join(" ");
184
- return /* @__PURE__ */ n("header", { ref: c, className: o, ...r, children: /* @__PURE__ */ p("div", { className: `psi-container ${V.inner}`, children: [
185
- e != null && /* @__PURE__ */ n("div", { className: V.brand, children: e }),
186
- /* @__PURE__ */ n("nav", { className: V.links, children: i }),
187
- t != null && /* @__PURE__ */ n("div", { className: V.actions, children: t })
182
+ function jo({ brand: e, actions: t, children: i, className: a, ref: c, ...r }) {
183
+ const o = [F.navbar, a].filter(Boolean).join(" ");
184
+ return /* @__PURE__ */ n("header", { ref: c, className: o, ...r, children: /* @__PURE__ */ p("div", { className: `psi-container ${F.inner}`, children: [
185
+ e != null && /* @__PURE__ */ n("div", { className: F.brand, children: e }),
186
+ /* @__PURE__ */ n("nav", { className: F.links, children: i }),
187
+ t != null && /* @__PURE__ */ n("div", { className: F.actions, children: t })
188
188
  ] }) });
189
189
  }
190
- const at = "_frame_et4fc_1", ct = {
191
- frame: at
190
+ const ht = "_frame_et4fc_1", _t = {
191
+ frame: ht
192
192
  };
193
- function bo({ ratio: e, className: t, style: i, children: a, ref: c, ...r }) {
194
- const o = [ct.frame, t].filter(Boolean).join(" ");
193
+ function To({ ratio: e, className: t, style: i, children: a, ref: c, ...r }) {
194
+ const o = [_t.frame, t].filter(Boolean).join(" ");
195
195
  return /* @__PURE__ */ n("div", { ref: c, className: o, style: { aspectRatio: String(e), ...i }, ...r, children: a });
196
196
  }
197
- const lt = "_field_lplye_1", dt = "_label_lplye_10", ut = "_marker_lplye_16", ht = "_message_lplye_20", _t = "_invalid_lplye_26", E = {
198
- field: lt,
199
- label: dt,
200
- marker: ut,
201
- message: ht,
202
- invalid: _t
203
- }, te = K(null);
204
- function yo({
197
+ const ft = "_field_lplye_1", pt = "_label_lplye_10", vt = "_marker_lplye_16", bt = "_message_lplye_20", gt = "_invalid_lplye_26", E = {
198
+ field: ft,
199
+ label: pt,
200
+ marker: vt,
201
+ message: bt,
202
+ invalid: gt
203
+ }, oe = R(null);
204
+ function Io({
205
205
  label: e,
206
206
  description: t,
207
207
  error: i,
@@ -210,102 +210,102 @@ function yo({
210
210
  htmlFor: r,
211
211
  className: o,
212
212
  children: s,
213
- ref: l,
214
- ...d
213
+ ref: d,
214
+ ...l
215
215
  }) {
216
- const u = U(), h = r ?? u, _ = !!i, b = _ ? i : t, y = b != null && b !== !1 ? `${h}-message` : void 0, j = [E.field, _ && E.invalid, o].filter(Boolean).join(" "), v = e != null ? /* @__PURE__ */ p(G, { children: [
216
+ const u = H(), h = r ?? u, _ = !!i, y = _ ? i : t, m = y != null && y !== !1 ? `${h}-message` : void 0, j = [E.field, _ && E.invalid, o].filter(Boolean).join(" "), C = e != null ? /* @__PURE__ */ p(G, { children: [
217
217
  e,
218
218
  a && /* @__PURE__ */ n("span", { "aria-hidden": "true", className: E.marker, children: " *" })
219
- ] }) : null, I = /* @__PURE__ */ p(G, { children: [
220
- v != null && (c ? /* @__PURE__ */ n("legend", { className: E.label, children: v }) : /* @__PURE__ */ n("label", { className: E.label, htmlFor: h, children: v })),
221
- /* @__PURE__ */ n(te.Provider, { value: { id: h, describedBy: y, invalid: _, required: a }, children: s }),
222
- y && /* @__PURE__ */ n("p", { id: y, className: E.message, "aria-live": "polite", children: b })
219
+ ] }) : null, b = /* @__PURE__ */ p(G, { children: [
220
+ C != null && (c ? /* @__PURE__ */ n("legend", { className: E.label, children: C }) : /* @__PURE__ */ n("label", { className: E.label, htmlFor: h, children: C })),
221
+ /* @__PURE__ */ n(oe.Provider, { value: { id: h, describedBy: m, invalid: _, required: a }, children: s }),
222
+ m && /* @__PURE__ */ n("p", { id: m, className: E.message, "aria-live": "polite", children: y })
223
223
  ] });
224
224
  return c ? /* @__PURE__ */ n(
225
225
  "fieldset",
226
226
  {
227
- ref: l,
227
+ ref: d,
228
228
  className: j,
229
- "aria-describedby": y,
230
- ...d,
231
- children: I
229
+ "aria-describedby": m,
230
+ ...l,
231
+ children: b
232
232
  }
233
- ) : /* @__PURE__ */ n("div", { ref: l, className: j, ...d, children: I });
233
+ ) : /* @__PURE__ */ n("div", { ref: d, className: j, ...l, children: b });
234
234
  }
235
- function mo({ size: e = 20, ...t }) {
235
+ function Eo({ size: e = 20, ...t }) {
236
236
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
237
237
  /* @__PURE__ */ n("line", { x1: "12", y1: "5", x2: "12", y2: "19" }),
238
238
  /* @__PURE__ */ n("line", { x1: "5", y1: "12", x2: "19", y2: "12" })
239
239
  ] });
240
240
  }
241
- function wo({ size: e = 20, ...t }) {
241
+ function Mo({ size: e = 20, ...t }) {
242
242
  return /* @__PURE__ */ n("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: /* @__PURE__ */ n("line", { x1: "5", y1: "12", x2: "19", y2: "12" }) });
243
243
  }
244
- function ue({ size: e = 20, ...t }) {
244
+ function _e({ size: e = 20, ...t }) {
245
245
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
246
246
  /* @__PURE__ */ n("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
247
247
  /* @__PURE__ */ n("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
248
248
  ] });
249
249
  }
250
- function ft({ size: e = 20, ...t }) {
250
+ function yt({ size: e = 20, ...t }) {
251
251
  return /* @__PURE__ */ n("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: /* @__PURE__ */ n("polyline", { points: "20 6 9 17 4 12" }) });
252
252
  }
253
- function ko({ size: e = 20, ...t }) {
253
+ function Ao({ size: e = 20, ...t }) {
254
254
  return /* @__PURE__ */ n("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: /* @__PURE__ */ n("polyline", { points: "6 9 12 15 18 9" }) });
255
255
  }
256
- function xo({ size: e = 20, ...t }) {
256
+ function Po({ size: e = 20, ...t }) {
257
257
  return /* @__PURE__ */ n("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: /* @__PURE__ */ n("polyline", { points: "9 18 15 12 9 6" }) });
258
258
  }
259
- function Co({ size: e = 20, ...t }) {
259
+ function Wo({ size: e = 20, ...t }) {
260
260
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
261
261
  /* @__PURE__ */ n("circle", { cx: "11", cy: "11", r: "8" }),
262
262
  /* @__PURE__ */ n("line", { x1: "21", y1: "21", x2: "16.65", y2: "16.65" })
263
263
  ] });
264
264
  }
265
- function Bo({ size: e = 20, ...t }) {
265
+ function Do({ size: e = 20, ...t }) {
266
266
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
267
267
  /* @__PURE__ */ n("circle", { cx: "12", cy: "12", r: "3" }),
268
268
  /* @__PURE__ */ n("path", { d: "M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1-2.83 2.83l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-4 0v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83-2.83l.06-.06A1.65 1.65 0 0 0 4.68 15a1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1 0-4h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 2.83-2.83l.06.06A1.65 1.65 0 0 0 9 4.68a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 4 0v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 2.83l-.06.06A1.65 1.65 0 0 0 19.4 9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 0 4h-.09a1.65 1.65 0 0 0-1.51 1z" })
269
269
  ] });
270
270
  }
271
- function No({ size: e = 20, ...t }) {
271
+ function Ro({ size: e = 20, ...t }) {
272
272
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
273
273
  /* @__PURE__ */ n("path", { d: "M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2" }),
274
274
  /* @__PURE__ */ n("circle", { cx: "12", cy: "7", r: "4" })
275
275
  ] });
276
276
  }
277
- function $o({ size: e = 20, ...t }) {
277
+ function Ho({ size: e = 20, ...t }) {
278
278
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
279
279
  /* @__PURE__ */ n("path", { d: "M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7" }),
280
280
  /* @__PURE__ */ n("path", { d: "M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z" })
281
281
  ] });
282
282
  }
283
- function Lo({ size: e = 20, ...t }) {
283
+ function Vo({ size: e = 20, ...t }) {
284
284
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
285
285
  /* @__PURE__ */ n("polyline", { points: "3 6 5 6 21 6" }),
286
286
  /* @__PURE__ */ n("path", { d: "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6m3 0V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2" })
287
287
  ] });
288
288
  }
289
- function jo({ size: e = 20, ...t }) {
289
+ function qo({ size: e = 20, ...t }) {
290
290
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
291
291
  /* @__PURE__ */ n("rect", { x: "9", y: "9", width: "13", height: "13", rx: "2", ry: "2" }),
292
292
  /* @__PURE__ */ n("path", { d: "M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1" })
293
293
  ] });
294
294
  }
295
- function So({ size: e = 20, ...t }) {
295
+ function Fo({ size: e = 20, ...t }) {
296
296
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
297
297
  /* @__PURE__ */ n("path", { d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6" }),
298
298
  /* @__PURE__ */ n("polyline", { points: "15 3 21 3 21 9" }),
299
299
  /* @__PURE__ */ n("line", { x1: "10", y1: "14", x2: "21", y2: "3" })
300
300
  ] });
301
301
  }
302
- function zo({ size: e = 20, ...t }) {
302
+ function Ko({ size: e = 20, ...t }) {
303
303
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
304
304
  /* @__PURE__ */ n("path", { d: "M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z" }),
305
305
  /* @__PURE__ */ n("circle", { cx: "12", cy: "12", r: "3" })
306
306
  ] });
307
307
  }
308
- function Io({ size: e = 20, ...t }) {
308
+ function Oo({ size: e = 20, ...t }) {
309
309
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
310
310
  /* @__PURE__ */ n("path", { d: "M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94" }),
311
311
  /* @__PURE__ */ n("path", { d: "M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19" }),
@@ -313,7 +313,7 @@ function Io({ size: e = 20, ...t }) {
313
313
  /* @__PURE__ */ n("line", { x1: "1", y1: "1", x2: "23", y2: "23" })
314
314
  ] });
315
315
  }
316
- function To({ size: e = 20, ...t }) {
316
+ function Uo({ size: e = 20, ...t }) {
317
317
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
318
318
  /* @__PURE__ */ n("line", { x1: "12", y1: "2", x2: "12", y2: "6" }),
319
319
  /* @__PURE__ */ n("line", { x1: "12", y1: "18", x2: "12", y2: "22" }),
@@ -325,171 +325,180 @@ function To({ size: e = 20, ...t }) {
325
325
  /* @__PURE__ */ n("line", { x1: "16.24", y1: "7.76", x2: "19.07", y2: "4.93" })
326
326
  ] });
327
327
  }
328
- function Eo({ size: e = 20, ...t }) {
328
+ function Yo({ size: e = 20, ...t }) {
329
329
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
330
330
  /* @__PURE__ */ n("line", { x1: "12", y1: "5", x2: "12", y2: "19" }),
331
331
  /* @__PURE__ */ n("polyline", { points: "19 12 12 19 5 12" })
332
332
  ] });
333
333
  }
334
- function Mo({ size: e = 20, ...t }) {
334
+ function Zo({ size: e = 20, ...t }) {
335
335
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
336
336
  /* @__PURE__ */ n("line", { x1: "7", y1: "17", x2: "17", y2: "7" }),
337
337
  /* @__PURE__ */ n("polyline", { points: "7 7 17 7 17 17" })
338
338
  ] });
339
339
  }
340
- function Wo({ size: e = 20, ...t }) {
340
+ function Go({ size: e = 20, ...t }) {
341
341
  return /* @__PURE__ */ n("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "currentColor", "aria-hidden": "true", ...t, children: /* @__PURE__ */ n("path", { d: "M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433c-1.144 0-2.063-.926-2.063-2.065 0-1.138.92-2.063 2.063-2.063 1.14 0 2.064.925 2.064 2.063 0 1.139-.925 2.065-2.064 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z" }) });
342
342
  }
343
- function Ao({ size: e = 20, ...t }) {
343
+ function Xo({ size: e = 20, ...t }) {
344
344
  return /* @__PURE__ */ n("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "currentColor", "aria-hidden": "true", ...t, children: /* @__PURE__ */ n("path", { d: "M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12" }) });
345
345
  }
346
- function Po({ size: e = 20, ...t }) {
346
+ function Jo({ size: e = 20, ...t }) {
347
347
  return /* @__PURE__ */ n("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "currentColor", "aria-hidden": "true", ...t, children: /* @__PURE__ */ n("path", { d: "M18.901 1.153h3.68l-8.04 9.19L24 22.846h-7.406l-5.8-7.584-6.638 7.584H.474l8.6-9.83L0 1.154h7.594l5.243 6.932ZM17.61 20.644h2.039L6.486 3.24H4.298Z" }) });
348
348
  }
349
- function Do({ size: e = 20, ...t }) {
349
+ function Qo({ size: e = 20, ...t }) {
350
350
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
351
351
  /* @__PURE__ */ n("rect", { x: "2", y: "2", width: "20", height: "20", rx: "5", ry: "5" }),
352
352
  /* @__PURE__ */ n("path", { d: "M16 11.37A4 4 0 1 1 12.63 8 4 4 0 0 1 16 11.37z" }),
353
353
  /* @__PURE__ */ n("line", { x1: "17.5", y1: "6.5", x2: "17.51", y2: "6.5" })
354
354
  ] });
355
355
  }
356
- function pt({ size: e = 20, ...t }) {
356
+ function mt({ size: e = 20, ...t }) {
357
357
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
358
358
  /* @__PURE__ */ n("circle", { cx: "12", cy: "12", r: "10" }),
359
359
  /* @__PURE__ */ n("line", { x1: "12", y1: "11", x2: "12", y2: "16" }),
360
360
  /* @__PURE__ */ n("line", { x1: "12", y1: "8", x2: "12", y2: "8" })
361
361
  ] });
362
362
  }
363
- function vt({ size: e = 20, ...t }) {
363
+ function wt({ size: e = 20, ...t }) {
364
364
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
365
365
  /* @__PURE__ */ n("path", { d: "M10.29 3.86 1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0Z" }),
366
366
  /* @__PURE__ */ n("line", { x1: "12", y1: "9", x2: "12", y2: "13" }),
367
367
  /* @__PURE__ */ n("line", { x1: "12", y1: "17", x2: "12", y2: "17" })
368
368
  ] });
369
369
  }
370
- function gt({ size: e = 20, ...t }) {
370
+ function xt({ size: e = 20, ...t }) {
371
371
  return /* @__PURE__ */ p("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", ...t, children: [
372
372
  /* @__PURE__ */ n("circle", { cx: "12", cy: "12", r: "10" }),
373
373
  /* @__PURE__ */ n("line", { x1: "12", y1: "8", x2: "12", y2: "12" }),
374
374
  /* @__PURE__ */ n("line", { x1: "12", y1: "16", x2: "12", y2: "16" })
375
375
  ] });
376
376
  }
377
- const bt = "_dialog_l23jf_2", yt = "_w400_l23jf_31", mt = "_w560_l23jf_32", wt = "_w720_l23jf_33", kt = "_panel_l23jf_35", xt = "_header_l23jf_41", Ct = "_title_l23jf_48", Bt = "_footer_l23jf_54", z = {
378
- dialog: bt,
379
- w400: yt,
380
- w560: mt,
381
- w720: wt,
382
- panel: kt,
383
- header: xt,
384
- title: Ct,
385
- footer: Bt
386
- }, Nt = {
387
- 400: z.w400,
388
- 560: z.w560,
389
- 720: z.w720
377
+ const kt = "_dialog_h5f0e_2", Ct = "_center_h5f0e_32", Bt = "_inlineStart_h5f0e_40", $t = "_inlineEnd_h5f0e_41", Nt = "_w400_h5f0e_90", Lt = "_w560_h5f0e_91", St = "_w720_h5f0e_92", zt = "_panel_h5f0e_94", jt = "_header_h5f0e_114", Tt = "_title_h5f0e_121", It = "_footer_h5f0e_127", L = {
378
+ dialog: kt,
379
+ center: Ct,
380
+ inlineStart: Bt,
381
+ inlineEnd: $t,
382
+ w400: Nt,
383
+ w560: Lt,
384
+ w720: St,
385
+ panel: zt,
386
+ header: jt,
387
+ title: Tt,
388
+ footer: It
389
+ }, Et = {
390
+ 400: L.w400,
391
+ 560: L.w560,
392
+ 720: L.w720
393
+ }, Mt = {
394
+ center: L.center,
395
+ "inline-start": L.inlineStart,
396
+ "inline-end": L.inlineEnd
390
397
  };
391
- function Ro({
398
+ function er({
392
399
  open: e,
393
400
  onClose: t,
394
401
  title: i,
395
402
  footer: a,
396
403
  width: c = 560,
397
- dismissible: r = !0,
398
- className: o,
399
- children: s,
404
+ placement: r = "center",
405
+ dismissible: o = !0,
406
+ className: s,
407
+ children: d,
400
408
  ref: l,
401
- ...d
409
+ ...u
402
410
  }) {
403
- const u = B(null), h = U(), _ = (v) => {
404
- u.current = v, typeof l == "function" ? l(v) : l && (l.current = v);
411
+ const h = x(null), _ = H(), y = (b) => {
412
+ h.current = b, typeof l == "function" ? l(b) : l && (l.current = b);
405
413
  };
406
414
  N(() => {
407
- const v = u.current;
408
- v && (e && !v.open ? v.showModal() : !e && v.open && v.close());
415
+ const b = h.current;
416
+ b && (e && !b.open ? b.showModal() : !e && b.open && b.close());
409
417
  }, [e]), N(() => {
410
418
  if (!e) return;
411
- const v = document.body.style.overflow;
419
+ const b = document.body.style.overflow;
412
420
  return document.body.style.overflow = "hidden", () => {
413
- document.body.style.overflow = v;
421
+ document.body.style.overflow = b;
414
422
  };
415
423
  }, [e]);
416
- const b = (v) => {
417
- v.preventDefault(), r && t("esc");
418
- }, y = (v) => {
419
- r && v.target === u.current && t("backdrop");
420
- }, j = [z.dialog, Nt[c], o].filter(Boolean).join(" ");
424
+ const m = (b) => {
425
+ b.preventDefault(), o && t("esc");
426
+ }, j = (b) => {
427
+ o && b.target === h.current && t("backdrop");
428
+ }, C = [L.dialog, Et[c], Mt[r], s].filter(Boolean).join(" ");
421
429
  return /* @__PURE__ */ n(
422
430
  "dialog",
423
431
  {
424
- ref: _,
425
- className: j,
426
- "aria-labelledby": i != null ? h : void 0,
427
- onCancel: b,
428
- onClick: y,
429
- ...d,
430
- children: /* @__PURE__ */ p("div", { className: z.panel, children: [
431
- (i != null || r) && /* @__PURE__ */ p("div", { className: z.header, children: [
432
- i != null && /* @__PURE__ */ n("h2", { id: h, className: z.title, children: i }),
433
- r && /* @__PURE__ */ n(
432
+ ref: y,
433
+ className: C,
434
+ "data-placement": r,
435
+ "aria-labelledby": i != null ? _ : void 0,
436
+ onCancel: m,
437
+ onClick: j,
438
+ ...u,
439
+ children: /* @__PURE__ */ p("div", { className: L.panel, children: [
440
+ (i != null || o) && /* @__PURE__ */ p("div", { className: L.header, children: [
441
+ i != null && /* @__PURE__ */ n("h2", { id: _, className: L.title, children: i }),
442
+ o && /* @__PURE__ */ n(
434
443
  X,
435
444
  {
436
445
  variant: "ghost",
437
446
  size: 32,
438
447
  "aria-label": "Close dialog",
439
448
  onClick: () => t("close-button"),
440
- children: /* @__PURE__ */ n(ue, { "aria-hidden": "true" })
449
+ children: /* @__PURE__ */ n(_e, { "aria-hidden": "true" })
441
450
  }
442
451
  )
443
452
  ] }),
444
- s,
445
- a != null && /* @__PURE__ */ n("div", { className: z.footer, children: a })
453
+ d,
454
+ a != null && /* @__PURE__ */ n("div", { className: L.footer, children: a })
446
455
  ] })
447
456
  }
448
457
  );
449
458
  }
450
- const $t = "_input_hpei8_3", Lt = "_size24_hpei8_37", jt = "_size32_hpei8_43", St = "_size40_hpei8_49", zt = "_size48_hpei8_55", It = "_error_hpei8_63", A = {
451
- input: $t,
452
- size24: Lt,
453
- size32: jt,
454
- size40: St,
455
- size48: zt,
456
- error: It
457
- }, Tt = {
458
- 24: A.size24,
459
- 32: A.size32,
460
- 40: A.size40,
461
- 48: A.size48
459
+ const At = "_input_hpei8_3", Pt = "_size24_hpei8_37", Wt = "_size32_hpei8_43", Dt = "_size40_hpei8_49", Rt = "_size48_hpei8_55", Ht = "_error_hpei8_63", P = {
460
+ input: At,
461
+ size24: Pt,
462
+ size32: Wt,
463
+ size40: Dt,
464
+ size48: Rt,
465
+ error: Ht
466
+ }, Vt = {
467
+ 24: P.size24,
468
+ 32: P.size32,
469
+ 40: P.size40,
470
+ 48: P.size48
462
471
  };
463
- function Ho({ size: e = 32, error: t = !1, type: i = "text", className: a, ref: c, ...r }) {
464
- const o = L(te), s = t || ((o == null ? void 0 : o.invalid) ?? !1), l = [o == null ? void 0 : o.describedBy, r["aria-describedby"]].filter(Boolean).join(" ") || void 0, d = [A.input, Tt[e], s && A.error, a].filter(Boolean).join(" ");
472
+ function tr({ size: e = 32, error: t = !1, type: i = "text", className: a, ref: c, ...r }) {
473
+ const o = S(oe), s = t || ((o == null ? void 0 : o.invalid) ?? !1), d = [o == null ? void 0 : o.describedBy, r["aria-describedby"]].filter(Boolean).join(" ") || void 0, l = [P.input, Vt[e], s && P.error, a].filter(Boolean).join(" ");
465
474
  return /* @__PURE__ */ n(
466
475
  "input",
467
476
  {
468
477
  ref: c,
469
- className: d,
478
+ className: l,
470
479
  id: r.id ?? (o == null ? void 0 : o.id),
471
480
  required: r.required ?? ((o == null ? void 0 : o.required) || void 0),
472
481
  "aria-invalid": (o == null ? void 0 : o.invalid) || void 0,
473
482
  type: i,
474
483
  ...r,
475
- "aria-describedby": l
484
+ "aria-describedby": d
476
485
  }
477
486
  );
478
487
  }
479
- const Et = "_select_4x9ck_3", Mt = "_size24_4x9ck_37", Wt = "_size32_4x9ck_45", At = "_size40_4x9ck_53", Pt = "_size48_4x9ck_61", Dt = "_error_4x9ck_71", P = {
480
- select: Et,
481
- size24: Mt,
482
- size32: Wt,
483
- size40: At,
484
- size48: Pt,
485
- error: Dt
486
- }, Rt = {
487
- 24: P.size24,
488
- 32: P.size32,
489
- 40: P.size40,
490
- 48: P.size48
488
+ const qt = "_select_4x9ck_3", Ft = "_size24_4x9ck_37", Kt = "_size32_4x9ck_45", Ot = "_size40_4x9ck_53", Ut = "_size48_4x9ck_61", Yt = "_error_4x9ck_71", W = {
489
+ select: qt,
490
+ size24: Ft,
491
+ size32: Kt,
492
+ size40: Ot,
493
+ size48: Ut,
494
+ error: Yt
495
+ }, Zt = {
496
+ 24: W.size24,
497
+ 32: W.size32,
498
+ 40: W.size40,
499
+ 48: W.size48
491
500
  };
492
- function Vo({
501
+ function nr({
493
502
  size: e = 32,
494
503
  error: t = !1,
495
504
  className: i,
@@ -497,65 +506,65 @@ function Vo({
497
506
  children: c,
498
507
  ...r
499
508
  }) {
500
- const o = L(te), s = t || ((o == null ? void 0 : o.invalid) ?? !1), l = [o == null ? void 0 : o.describedBy, r["aria-describedby"]].filter(Boolean).join(" ") || void 0, d = [
501
- P.select,
502
- Rt[e],
503
- s && P.error,
509
+ const o = S(oe), s = t || ((o == null ? void 0 : o.invalid) ?? !1), d = [o == null ? void 0 : o.describedBy, r["aria-describedby"]].filter(Boolean).join(" ") || void 0, l = [
510
+ W.select,
511
+ Zt[e],
512
+ s && W.error,
504
513
  i
505
514
  ].filter(Boolean).join(" ");
506
515
  return /* @__PURE__ */ n(
507
516
  "select",
508
517
  {
509
518
  ref: a,
510
- className: d,
519
+ className: l,
511
520
  id: r.id ?? (o == null ? void 0 : o.id),
512
521
  required: r.required ?? ((o == null ? void 0 : o.required) || void 0),
513
522
  "aria-invalid": (o == null ? void 0 : o.invalid) || void 0,
514
523
  ...r,
515
- "aria-describedby": l,
524
+ "aria-describedby": d,
516
525
  children: c
517
526
  }
518
527
  );
519
528
  }
520
- const Ht = "_label_1v4vv_3", Vt = "_disabled_1v4vv_13", qt = "_input_1v4vv_20", Ft = "_indicator_1v4vv_34", Ot = "_text_1v4vv_75", q = {
521
- label: Ht,
522
- disabled: Vt,
523
- input: qt,
524
- indicator: Ft,
525
- text: Ot
529
+ const Gt = "_label_1v4vv_3", Xt = "_disabled_1v4vv_13", Jt = "_input_1v4vv_20", Qt = "_indicator_1v4vv_34", en = "_text_1v4vv_75", K = {
530
+ label: Gt,
531
+ disabled: Xt,
532
+ input: Jt,
533
+ indicator: Qt,
534
+ text: en
526
535
  };
527
- function he({
536
+ function fe({
528
537
  children: e,
529
538
  className: t,
530
539
  disabled: i,
531
540
  ref: a,
532
541
  ...c
533
542
  }) {
534
- const r = [q.label, i && q.disabled, t].filter(Boolean).join(" ");
543
+ const r = [K.label, i && K.disabled, t].filter(Boolean).join(" ");
535
544
  return /* @__PURE__ */ p("label", { className: r, children: [
536
545
  /* @__PURE__ */ n(
537
546
  "input",
538
547
  {
539
548
  ref: a,
540
549
  type: "checkbox",
541
- className: q.input,
550
+ className: K.input,
542
551
  disabled: i,
543
552
  ...c
544
553
  }
545
554
  ),
546
- /* @__PURE__ */ n("span", { className: q.indicator, "aria-hidden": "true" }),
547
- e && /* @__PURE__ */ n("span", { className: q.text, children: e })
555
+ /* @__PURE__ */ n("span", { className: K.indicator, "aria-hidden": "true" }),
556
+ e && /* @__PURE__ */ n("span", { className: K.text, children: e })
548
557
  ] });
549
558
  }
550
- const Kt = "_label_jru2c_3", Ut = "_disabled_jru2c_13", Yt = "_input_jru2c_20", Zt = "_track_jru2c_34", Gt = "_thumb_jru2c_58", Xt = "_text_jru2c_75", M = {
551
- label: Kt,
552
- disabled: Ut,
553
- input: Yt,
554
- track: Zt,
555
- thumb: Gt,
556
- text: Xt
559
+ const tn = "_label_jru2c_3", nn = "_disabled_jru2c_13", on = "_input_jru2c_20", rn = "_track_jru2c_34", sn = "_thumb_jru2c_58", an = "_text_jru2c_75", M = {
560
+ label: tn,
561
+ disabled: nn,
562
+ input: on,
563
+ track: rn,
564
+ thumb: sn,
565
+ text: an
557
566
  };
558
- function qo({
567
+ function or({
559
568
  children: e,
560
569
  className: t,
561
570
  disabled: i,
@@ -579,33 +588,33 @@ function qo({
579
588
  e && /* @__PURE__ */ n("span", { className: M.text, children: e })
580
589
  ] });
581
590
  }
582
- const Jt = "_tag_3oysa_3", Qt = "_dismiss_3oysa_17", en = "_neutral_3oysa_43", tn = "_accent_3oysa_48", nn = "_success_3oysa_53", on = "_warning_3oysa_58", rn = "_danger_3oysa_63", sn = "_neutralSubtle_3oysa_70", an = "_accentSubtle_3oysa_75", cn = "_successSubtle_3oysa_80", ln = "_warningSubtle_3oysa_85", dn = "_dangerSubtle_3oysa_90", x = {
583
- tag: Jt,
584
- dismiss: Qt,
585
- neutral: en,
586
- accent: tn,
587
- success: nn,
588
- warning: on,
589
- danger: rn,
590
- neutralSubtle: sn,
591
- accentSubtle: an,
592
- successSubtle: cn,
593
- warningSubtle: ln,
594
- dangerSubtle: dn
595
- }, un = {
596
- neutral: x.neutral,
597
- accent: x.accent,
598
- success: x.success,
599
- warning: x.warning,
600
- danger: x.danger
601
- }, hn = {
602
- neutral: x.neutralSubtle,
603
- accent: x.accentSubtle,
604
- success: x.successSubtle,
605
- warning: x.warningSubtle,
606
- danger: x.dangerSubtle
591
+ const cn = "_tag_3oysa_3", ln = "_dismiss_3oysa_17", dn = "_neutral_3oysa_43", un = "_accent_3oysa_48", hn = "_success_3oysa_53", _n = "_warning_3oysa_58", fn = "_danger_3oysa_63", pn = "_neutralSubtle_3oysa_70", vn = "_accentSubtle_3oysa_75", bn = "_successSubtle_3oysa_80", gn = "_warningSubtle_3oysa_85", yn = "_dangerSubtle_3oysa_90", B = {
592
+ tag: cn,
593
+ dismiss: ln,
594
+ neutral: dn,
595
+ accent: un,
596
+ success: hn,
597
+ warning: _n,
598
+ danger: fn,
599
+ neutralSubtle: pn,
600
+ accentSubtle: vn,
601
+ successSubtle: bn,
602
+ warningSubtle: gn,
603
+ dangerSubtle: yn
604
+ }, mn = {
605
+ neutral: B.neutral,
606
+ accent: B.accent,
607
+ success: B.success,
608
+ warning: B.warning,
609
+ danger: B.danger
610
+ }, wn = {
611
+ neutral: B.neutralSubtle,
612
+ accent: B.accentSubtle,
613
+ success: B.successSubtle,
614
+ warning: B.warningSubtle,
615
+ danger: B.dangerSubtle
607
616
  };
608
- function Fo({
617
+ function rr({
609
618
  variant: e = "neutral",
610
619
  subtle: t = !1,
611
620
  onDismiss: i,
@@ -614,14 +623,14 @@ function Fo({
614
623
  ref: r,
615
624
  ...o
616
625
  }) {
617
- const s = t ? hn : un, l = [x.tag, s[e], a].filter(Boolean).join(" ");
618
- return /* @__PURE__ */ p("span", { ref: r, className: l, ...o, children: [
626
+ const s = t ? wn : mn, d = [B.tag, s[e], a].filter(Boolean).join(" ");
627
+ return /* @__PURE__ */ p("span", { ref: r, className: d, ...o, children: [
619
628
  c,
620
629
  i && /* @__PURE__ */ n(
621
630
  "button",
622
631
  {
623
632
  type: "button",
624
- className: x.dismiss,
633
+ className: B.dismiss,
625
634
  onClick: i,
626
635
  "aria-label": "Dismiss",
627
636
  children: /* @__PURE__ */ p(
@@ -646,53 +655,53 @@ function Fo({
646
655
  )
647
656
  ] });
648
657
  }
649
- const _n = "_wrapper_1eu6z_3", fn = "_tooltip_1eu6z_10", pn = "_top_1eu6z_24", vn = "_bottom_1eu6z_31", gn = "_left_1eu6z_38", bn = "_right_1eu6z_45", D = {
650
- wrapper: _n,
651
- tooltip: fn,
652
- top: pn,
653
- bottom: vn,
654
- left: gn,
655
- right: bn
656
- }, yn = {
658
+ const xn = "_wrapper_1eu6z_3", kn = "_tooltip_1eu6z_10", Cn = "_top_1eu6z_24", Bn = "_bottom_1eu6z_31", $n = "_left_1eu6z_38", Nn = "_right_1eu6z_45", D = {
659
+ wrapper: xn,
660
+ tooltip: kn,
661
+ top: Cn,
662
+ bottom: Bn,
663
+ left: $n,
664
+ right: Nn
665
+ }, Ln = {
657
666
  top: D.top,
658
667
  bottom: D.bottom,
659
668
  left: D.left,
660
669
  right: D.right
661
- }, mn = 150;
662
- function Oo({
670
+ }, Sn = 150;
671
+ function ir({
663
672
  content: e,
664
673
  children: t,
665
674
  placement: i = "top"
666
675
  }) {
667
- const [a, c] = le(!1), r = U(), o = B(void 0), s = m(() => {
676
+ const [a, c] = he(!1), r = H(), o = x(void 0), s = g(() => {
668
677
  o.current !== void 0 && (window.clearTimeout(o.current), o.current = void 0);
669
- }, []), l = m(() => c(!0), []), d = m(() => c(!1), []);
678
+ }, []), d = g(() => c(!0), []), l = g(() => c(!1), []);
670
679
  N(() => s, [s]), N(() => {
671
680
  if (!a) return;
672
681
  const h = (_) => {
673
- _.key === "Escape" && d();
682
+ _.key === "Escape" && l();
674
683
  };
675
684
  return document.addEventListener("keydown", h), () => document.removeEventListener("keydown", h);
676
- }, [a, d]);
677
- const u = ee(t, {
685
+ }, [a, l]);
686
+ const u = te(t, {
678
687
  "aria-describedby": a ? r : void 0,
679
688
  onMouseEnter: (h) => {
680
- s(), o.current = window.setTimeout(l, mn);
689
+ s(), o.current = window.setTimeout(d, Sn);
681
690
  const _ = t.props.onMouseEnter;
682
691
  _ == null || _(h);
683
692
  },
684
693
  onMouseLeave: (h) => {
685
- s(), d();
694
+ s(), l();
686
695
  const _ = t.props.onMouseLeave;
687
696
  _ == null || _(h);
688
697
  },
689
698
  onFocus: (h) => {
690
- l();
699
+ d();
691
700
  const _ = t.props.onFocus;
692
701
  _ == null || _(h);
693
702
  },
694
703
  onBlur: (h) => {
695
- s(), d();
704
+ s(), l();
696
705
  const _ = t.props.onBlur;
697
706
  _ == null || _(h);
698
707
  }
@@ -704,114 +713,114 @@ function Oo({
704
713
  {
705
714
  id: r,
706
715
  role: "tooltip",
707
- className: [D.tooltip, yn[i]].filter(Boolean).join(" "),
716
+ className: [D.tooltip, Ln[i]].filter(Boolean).join(" "),
708
717
  children: e
709
718
  }
710
719
  )
711
720
  ] });
712
721
  }
713
- const wn = "_toolbar_1i848_1", kn = "_gap8_1i848_7", xn = "_gap12_1i848_8", Cn = "_gap16_1i848_9", Z = {
714
- toolbar: wn,
715
- gap8: kn,
716
- gap12: xn,
717
- gap16: Cn
718
- }, Bn = { 8: Z.gap8, 12: Z.gap12, 16: Z.gap16 };
719
- function Ko({ gap: e = 8, className: t, children: i, ref: a, ...c }) {
720
- const r = [Z.toolbar, Bn[e], t].filter(Boolean).join(" ");
722
+ const zn = "_toolbar_1i848_1", jn = "_gap8_1i848_7", Tn = "_gap12_1i848_8", In = "_gap16_1i848_9", Z = {
723
+ toolbar: zn,
724
+ gap8: jn,
725
+ gap12: Tn,
726
+ gap16: In
727
+ }, En = { 8: Z.gap8, 12: Z.gap12, 16: Z.gap16 };
728
+ function sr({ gap: e = 8, className: t, children: i, ref: a, ...c }) {
729
+ const r = [Z.toolbar, En[e], t].filter(Boolean).join(" ");
721
730
  return /* @__PURE__ */ n("div", { ref: a, role: c["aria-label"] != null ? "group" : void 0, className: r, ...c, children: i });
722
731
  }
723
- const Nn = "_trigger_vpa0u_4", $n = "_menu_vpa0u_16", Ln = "_item_vpa0u_37", jn = "_separator_vpa0u_74", J = {
724
- trigger: Nn,
725
- menu: $n,
726
- item: Ln,
727
- separator: jn
728
- }, Sn = 500;
729
- function zn({ popoverRef: e, triggerRef: t, open: i, onEsc: a }) {
730
- const c = B(""), r = B(0), o = m(() => {
731
- const d = e.current;
732
- return d ? Array.from(
733
- d.querySelectorAll('[data-psi-menu-item]:not([aria-disabled="true"])')
732
+ const Mn = "_trigger_vpa0u_4", An = "_menu_vpa0u_16", Pn = "_item_vpa0u_37", Wn = "_separator_vpa0u_74", J = {
733
+ trigger: Mn,
734
+ menu: An,
735
+ item: Pn,
736
+ separator: Wn
737
+ }, Dn = 500;
738
+ function Rn({ popoverRef: e, triggerRef: t, open: i, onEsc: a }) {
739
+ const c = x(""), r = x(0), o = g(() => {
740
+ const l = e.current;
741
+ return l ? Array.from(
742
+ l.querySelectorAll('[data-psi-menu-item]:not([aria-disabled="true"])')
734
743
  ) : [];
735
- }, [e]), s = m(
736
- (d) => {
737
- if (d) {
738
- for (const u of o()) u.tabIndex = u === d ? 0 : -1;
739
- d.focus();
744
+ }, [e]), s = g(
745
+ (l) => {
746
+ if (l) {
747
+ for (const u of o()) u.tabIndex = u === l ? 0 : -1;
748
+ l.focus();
740
749
  }
741
750
  },
742
751
  [o]
743
- ), l = m(() => {
752
+ ), d = g(() => {
744
753
  var u;
745
- const d = (u = t.current) == null ? void 0 : u.querySelector("button, a, [tabindex]");
746
- d == null || d.focus();
754
+ const l = (u = t.current) == null ? void 0 : u.querySelector("button, a, [tabindex]");
755
+ l == null || l.focus();
747
756
  }, [t]);
748
757
  return N(() => {
749
758
  if (!i) return;
750
- const d = o();
751
- return s(d[0]), () => {
759
+ const l = o();
760
+ return s(l[0]), () => {
752
761
  var u;
753
- (u = e.current) != null && u.contains(document.activeElement) && l();
762
+ (u = e.current) != null && u.contains(document.activeElement) && d();
754
763
  };
755
- }, [i, e, o, s, l]), m(
756
- (d) => {
757
- if (d.key === "Escape") {
758
- d.preventDefault(), a();
764
+ }, [i, e, o, s, d]), g(
765
+ (l) => {
766
+ if (l.key === "Escape") {
767
+ l.preventDefault(), a();
759
768
  return;
760
769
  }
761
770
  const u = o();
762
771
  if (u.length === 0) return;
763
772
  const h = u.indexOf(document.activeElement);
764
- switch (d.key) {
773
+ switch (l.key) {
765
774
  case "ArrowDown":
766
- d.preventDefault(), s(u[(h + 1 + u.length) % u.length]);
775
+ l.preventDefault(), s(u[(h + 1 + u.length) % u.length]);
767
776
  return;
768
777
  case "ArrowUp":
769
- d.preventDefault(), s(u[h <= 0 ? u.length - 1 : h - 1]);
778
+ l.preventDefault(), s(u[h <= 0 ? u.length - 1 : h - 1]);
770
779
  return;
771
780
  case "Home":
772
- d.preventDefault(), s(u[0]);
781
+ l.preventDefault(), s(u[0]);
773
782
  return;
774
783
  case "End":
775
- d.preventDefault(), s(u[u.length - 1]);
784
+ l.preventDefault(), s(u[u.length - 1]);
776
785
  return;
777
786
  }
778
- if (d.key.length !== 1 || d.metaKey || d.ctrlKey || d.altKey) return;
787
+ if (l.key.length !== 1 || l.metaKey || l.ctrlKey || l.altKey) return;
779
788
  const _ = Date.now();
780
- c.current = _ - r.current > Sn ? d.key.toLowerCase() : c.current + d.key.toLowerCase(), r.current = _;
781
- const b = u.find(
782
- (y) => (y.textContent ?? "").trim().toLowerCase().startsWith(c.current)
789
+ c.current = _ - r.current > Dn ? l.key.toLowerCase() : c.current + l.key.toLowerCase(), r.current = _;
790
+ const y = u.find(
791
+ (m) => (m.textContent ?? "").trim().toLowerCase().startsWith(c.current)
783
792
  );
784
- b && (d.preventDefault(), s(b));
793
+ y && (l.preventDefault(), s(y));
785
794
  },
786
795
  [o, s, a]
787
796
  );
788
797
  }
789
- function In() {
798
+ function Hn() {
790
799
  return typeof CSS < "u" && CSS.supports("anchor-name", "--x");
791
800
  }
792
- function Tn({ popoverRef: e, triggerRef: t, open: i, placement: a, anchorName: c }) {
801
+ function Vn({ popoverRef: e, triggerRef: t, open: i, placement: a, anchorName: c }) {
793
802
  N(() => {
794
803
  const r = t.current, o = e.current;
795
804
  !r || !o || (r.style.setProperty("anchor-name", c), o.style.setProperty("position-anchor", c));
796
805
  }, [e, t, c]), N(() => {
797
- if (!i || In()) return;
806
+ if (!i || Hn()) return;
798
807
  const r = t.current, o = e.current;
799
808
  if (!r || !o) return;
800
809
  const s = () => {
801
- const l = r.getBoundingClientRect(), d = a.startsWith("bottom"), u = a.endsWith("end"), h = getComputedStyle(r).direction === "rtl", _ = u !== h;
802
- o.style.position = "fixed", o.style.top = d ? `${l.bottom}px` : "", o.style.bottom = d ? "" : `${window.innerHeight - l.top}px`, o.style.left = _ ? "" : `${l.left}px`, o.style.right = _ ? `${window.innerWidth - l.right}px` : "";
810
+ const d = r.getBoundingClientRect(), l = a.startsWith("bottom"), u = a.endsWith("end"), h = getComputedStyle(r).direction === "rtl", _ = u !== h;
811
+ o.style.position = "fixed", o.style.top = l ? `${d.bottom}px` : "", o.style.bottom = l ? "" : `${window.innerHeight - d.top}px`, o.style.left = _ ? "" : `${d.left}px`, o.style.right = _ ? `${window.innerWidth - d.right}px` : "";
803
812
  };
804
813
  return s(), window.addEventListener("scroll", s, !0), window.addEventListener("resize", s), () => {
805
814
  window.removeEventListener("scroll", s, !0), window.removeEventListener("resize", s);
806
815
  };
807
816
  }, [i, a, e, t]);
808
817
  }
809
- const _e = K({ close: () => {
818
+ const pe = R({ close: () => {
810
819
  } });
811
- function se(e) {
820
+ function le(e) {
812
821
  return e.hasAttribute("data-open") || e.matches(":popover-open");
813
822
  }
814
- function Uo({
823
+ function ar({
815
824
  open: e,
816
825
  onClose: t,
817
826
  trigger: i,
@@ -821,45 +830,45 @@ function Uo({
821
830
  ref: o,
822
831
  ...s
823
832
  }) {
824
- const l = B(null), d = B(null), u = B(!1), h = `--psi-menu-${U().replace(/:/g, "")}`;
825
- Tn({ popoverRef: l, triggerRef: d, open: e, placement: a, anchorName: h });
833
+ const d = x(null), l = x(null), u = x(!1), h = `--psi-menu-${H().replace(/:/g, "")}`;
834
+ Vn({ popoverRef: d, triggerRef: l, open: e, placement: a, anchorName: h });
826
835
  const _ = (f) => {
827
- l.current = f, typeof o == "function" ? o(f) : o && (o.current = f);
836
+ d.current = f, typeof o == "function" ? o(f) : o && (o.current = f);
828
837
  };
829
838
  N(() => {
830
- const f = l.current;
839
+ const f = d.current;
831
840
  if (!f) return;
832
- const g = se(f);
833
- e && !g ? f.showPopover() : !e && g && (u.current = !0, f.hidePopover());
841
+ const v = le(f);
842
+ e && !v ? f.showPopover() : !e && v && (u.current = !0, f.hidePopover());
834
843
  }, [e]);
835
- const b = m(() => {
836
- const f = l.current;
844
+ const y = g(() => {
845
+ const f = d.current;
837
846
  if (f) {
838
847
  if (u.current) {
839
848
  u.current = !1;
840
849
  return;
841
850
  }
842
- se(f) || e && t("outside");
851
+ le(f) || e && t("outside");
843
852
  }
844
- }, [t, e]), y = zn({
845
- popoverRef: l,
846
- triggerRef: d,
853
+ }, [t, e]), m = Rn({
854
+ popoverRef: d,
855
+ triggerRef: l,
847
856
  open: e,
848
857
  onEsc: () => t("esc")
849
- }), j = m(
858
+ }), j = g(
850
859
  (f) => {
851
860
  t(f);
852
861
  },
853
862
  [t]
854
- ), v = O(i);
863
+ ), C = U(i);
855
864
  N(() => {
856
- v || console.warn(
865
+ C || console.warn(
857
866
  "Psi Menu: `trigger` must be a single React element that forwards props to a focusable node. Menu clones it to attach aria-haspopup and aria-expanded; a string, fragment or array cannot carry them, so the menu renders without its trigger ARIA."
858
867
  );
859
- }, [v]);
860
- const I = v ? ee(i, { "aria-haspopup": "menu", "aria-expanded": e }) : i;
868
+ }, [C]);
869
+ const b = C ? te(i, { "aria-haspopup": "menu", "aria-expanded": e }) : i;
861
870
  return /* @__PURE__ */ p(G, { children: [
862
- /* @__PURE__ */ n("div", { ref: d, className: J.trigger, "data-psi-menu-trigger": !0, children: I }),
871
+ /* @__PURE__ */ n("div", { ref: l, className: J.trigger, "data-psi-menu-trigger": !0, children: b }),
863
872
  /* @__PURE__ */ n(
864
873
  "div",
865
874
  {
@@ -870,15 +879,15 @@ function Uo({
870
879
  "data-psi-menu": !0,
871
880
  "data-placement": a,
872
881
  className: [J.menu, r].filter(Boolean).join(" "),
873
- onToggle: b,
874
- onKeyDown: y,
875
- children: /* @__PURE__ */ n(_e.Provider, { value: { close: j }, children: c })
882
+ onToggle: y,
883
+ onKeyDown: m,
884
+ children: /* @__PURE__ */ n(pe.Provider, { value: { close: j }, children: c })
876
885
  }
877
886
  )
878
887
  ] });
879
888
  }
880
- function Yo({ children: e, onSelect: t, variant: i = "neutral", disabled: a = !1 }) {
881
- const { close: c } = L(_e);
889
+ function cr({ children: e, onSelect: t, variant: i = "neutral", disabled: a = !1 }) {
890
+ const { close: c } = S(pe);
882
891
  return /* @__PURE__ */ n(
883
892
  "button",
884
893
  {
@@ -896,107 +905,107 @@ function Yo({ children: e, onSelect: t, variant: i = "neutral", disabled: a = !1
896
905
  }
897
906
  );
898
907
  }
899
- function Zo() {
908
+ function lr() {
900
909
  return /* @__PURE__ */ n("div", { role: "separator", "data-psi-menu-separator": !0, className: J.separator });
901
910
  }
902
- const En = "_table_146hc_3", Mn = "_headerCell_146hc_13", Wn = "_cell_146hc_19", An = "_sortButton_146hc_30", Pn = "_sortIndicator_146hc_47", Dn = "_selectCell_146hc_79", Rn = "_body_146hc_86", Hn = "_row_146hc_89", Vn = "_sticky_146hc_111", k = {
903
- table: En,
904
- headerCell: Mn,
905
- cell: Wn,
906
- sortButton: An,
907
- sortIndicator: Pn,
908
- selectCell: Dn,
909
- body: Rn,
910
- row: Hn,
911
- sticky: Vn
912
- }, fe = /* @__PURE__ */ new Set(), R = K({
911
+ const qn = "_table_146hc_3", Fn = "_headerCell_146hc_13", Kn = "_cell_146hc_19", On = "_sortButton_146hc_30", Un = "_sortIndicator_146hc_47", Yn = "_selectCell_146hc_79", Zn = "_body_146hc_86", Gn = "_row_146hc_89", Xn = "_sticky_146hc_111", k = {
912
+ table: qn,
913
+ headerCell: Fn,
914
+ cell: Kn,
915
+ sortButton: On,
916
+ sortIndicator: Un,
917
+ selectCell: Yn,
918
+ body: Zn,
919
+ row: Gn,
920
+ sticky: Xn
921
+ }, ve = /* @__PURE__ */ new Set(), V = R({
913
922
  size: 40,
914
923
  sortable: !1,
915
924
  sort: null,
916
925
  selectable: !1,
917
- selected: fe
918
- }), pe = K([]);
919
- function qn({ children: e, className: t }) {
926
+ selected: ve
927
+ }), be = R([]);
928
+ function Jn({ children: e, className: t }) {
920
929
  return /* @__PURE__ */ n("tbody", { className: [k.body, t].filter(Boolean).join(" "), children: e });
921
930
  }
922
- function Fn(e) {
931
+ function Qn(e) {
923
932
  const t = [];
924
933
  let i = !1, a = !1;
925
934
  const c = (r) => {
926
- W.forEach(r, function o(s) {
927
- if (!O(s)) return;
928
- if (s.type === re) {
929
- W.forEach(s.props.children, o);
935
+ A.forEach(r, function o(s) {
936
+ if (!U(s)) return;
937
+ if (s.type === ae) {
938
+ A.forEach(s.props.children, o);
930
939
  return;
931
940
  }
932
- const l = s.props.rowId;
933
- typeof l == "string" ? t.push(l) : a = !0;
941
+ const d = s.props.rowId;
942
+ typeof d == "string" ? t.push(d) : a = !0;
934
943
  });
935
944
  };
936
- return W.forEach(e, function r(o) {
937
- if (O(o)) {
938
- if (o.type === re) {
939
- W.forEach(o.props.children, r);
945
+ return A.forEach(e, function r(o) {
946
+ if (U(o)) {
947
+ if (o.type === ae) {
948
+ A.forEach(o.props.children, r);
940
949
  return;
941
950
  }
942
- o.type === qn && (i = !0, c(o.props.children));
951
+ o.type === Jn && (i = !0, c(o.props.children));
943
952
  }
944
953
  }), { ids: t, sawBody: i, hasRowWithoutId: a };
945
954
  }
946
- function Go({
955
+ function dr({
947
956
  size: e = 40,
948
957
  stickyHeader: t,
949
958
  sortable: i = !1,
950
959
  sort: a = null,
951
960
  onSortChange: c,
952
961
  selectable: r = !1,
953
- selected: o = fe,
962
+ selected: o = ve,
954
963
  onSelectionChange: s,
955
- children: l,
956
- className: d,
964
+ children: d,
965
+ className: l,
957
966
  ref: u
958
967
  }) {
959
- const h = [k.table, t && k.sticky, d].filter(Boolean).join(" "), { ids: _, sawBody: b, hasRowWithoutId: y } = de(() => Fn(l), [l]);
960
- return process.env.NODE_ENV !== "production" && (i && !c && console.warn("Psi Table: `sortable` is set without `onSortChange`; sorting will not respond."), r && !s && console.warn("Psi Table: `selectable` is set without `onSelectionChange`; selection will not respond."), r && !b && console.warn("Psi Table: `selectable` is set but no `TableBody` is visible to `Table`. Wrapping `TableBody` in a component other than a Fragment hides its rows, and select-all will clear the selection instead of filling it."), r && y && console.warn("Psi Table: `selectable` is set but a row in `TableBody` has no `rowId`. That row will render without a selection checkbox and select-all will not include it.")), /* @__PURE__ */ n(R.Provider, { value: { size: e, sortable: i, sort: a, onSortChange: c, selectable: r, selected: o, onSelectionChange: s }, children: /* @__PURE__ */ n(pe.Provider, { value: _, children: /* @__PURE__ */ n("table", { ref: u, className: h, "data-size": e, children: l }) }) });
968
+ const h = [k.table, t && k.sticky, l].filter(Boolean).join(" "), { ids: _, sawBody: y, hasRowWithoutId: m } = ne(() => Qn(d), [d]);
969
+ return process.env.NODE_ENV !== "production" && (i && !c && console.warn("Psi Table: `sortable` is set without `onSortChange`; sorting will not respond."), r && !s && console.warn("Psi Table: `selectable` is set without `onSelectionChange`; selection will not respond."), r && !y && console.warn("Psi Table: `selectable` is set but no `TableBody` is visible to `Table`. Wrapping `TableBody` in a component other than a Fragment hides its rows, and select-all will clear the selection instead of filling it."), r && m && console.warn("Psi Table: `selectable` is set but a row in `TableBody` has no `rowId`. That row will render without a selection checkbox and select-all will not include it.")), /* @__PURE__ */ n(V.Provider, { value: { size: e, sortable: i, sort: a, onSortChange: c, selectable: r, selected: o, onSelectionChange: s }, children: /* @__PURE__ */ n(be.Provider, { value: _, children: /* @__PURE__ */ n("table", { ref: u, className: h, "data-size": e, children: d }) }) });
961
970
  }
962
- function On({ rowId: e, label: t }) {
963
- const { selected: i, onSelectionChange: a } = L(R), c = () => {
971
+ function eo({ rowId: e, label: t }) {
972
+ const { selected: i, onSelectionChange: a } = S(V), c = () => {
964
973
  const r = new Set(i);
965
974
  r.has(e) ? r.delete(e) : r.add(e), a == null || a(r);
966
975
  };
967
- return /* @__PURE__ */ n("td", { className: `${k.cell} ${k.selectCell}`, children: /* @__PURE__ */ n(he, { "aria-label": t, checked: i.has(e), onChange: c }) });
976
+ return /* @__PURE__ */ n("td", { className: `${k.cell} ${k.selectCell}`, children: /* @__PURE__ */ n(fe, { "aria-label": t, checked: i.has(e), onChange: c }) });
968
977
  }
969
- function Kn() {
970
- const { selected: e, onSelectionChange: t } = L(R), i = L(pe), a = B(null), c = i.length > 0 && i.every((s) => e.has(s)), r = i.some((s) => e.has(s));
978
+ function to() {
979
+ const { selected: e, onSelectionChange: t } = S(V), i = S(be), a = x(null), c = i.length > 0 && i.every((s) => e.has(s)), r = i.some((s) => e.has(s));
971
980
  N(() => {
972
981
  a.current && (a.current.indeterminate = r && !c);
973
982
  }, [r, c]);
974
983
  const o = () => {
975
984
  const s = new Set(e);
976
- c ? i.forEach((l) => s.delete(l)) : i.forEach((l) => s.add(l)), t == null || t(s);
985
+ c ? i.forEach((d) => s.delete(d)) : i.forEach((d) => s.add(d)), t == null || t(s);
977
986
  };
978
- return /* @__PURE__ */ n("th", { scope: "col", className: `${k.headerCell} ${k.selectCell}`, children: /* @__PURE__ */ n(he, { ref: a, "aria-label": "Select all rows", checked: c, onChange: o }) });
987
+ return /* @__PURE__ */ n("th", { scope: "col", className: `${k.headerCell} ${k.selectCell}`, children: /* @__PURE__ */ n(fe, { ref: a, "aria-label": "Select all rows", checked: c, onChange: o }) });
979
988
  }
980
- function Xo({ children: e, className: t }) {
981
- const { selectable: i } = L(R);
989
+ function ur({ children: e, className: t }) {
990
+ const { selectable: i } = S(V);
982
991
  let a = !1;
983
- const c = i ? W.map(e, (r) => {
984
- if (a || !O(r)) return r;
992
+ const c = i ? A.map(e, (r) => {
993
+ if (a || !U(r)) return r;
985
994
  a = !0;
986
995
  const o = r;
987
- return ee(
996
+ return te(
988
997
  o,
989
998
  void 0,
990
999
  /* @__PURE__ */ p(G, { children: [
991
- /* @__PURE__ */ n(Kn, {}),
1000
+ /* @__PURE__ */ n(to, {}),
992
1001
  o.props.children
993
1002
  ] })
994
1003
  );
995
1004
  }) : e;
996
1005
  return /* @__PURE__ */ n("thead", { className: [k.head, t].filter(Boolean).join(" "), children: c });
997
1006
  }
998
- function Jo({ rowId: e, selectLabel: t, children: i, className: a }) {
999
- const { selectable: c, selected: r } = L(R), o = e !== void 0 && r.has(e);
1007
+ function hr({ rowId: e, selectLabel: t, children: i, className: a }) {
1008
+ const { selectable: c, selected: r } = S(V), o = e !== void 0 && r.has(e);
1000
1009
  return /* @__PURE__ */ p(
1001
1010
  "tr",
1002
1011
  {
@@ -1004,16 +1013,16 @@ function Jo({ rowId: e, selectLabel: t, children: i, className: a }) {
1004
1013
  "data-row-id": e,
1005
1014
  "data-selected": o || void 0,
1006
1015
  children: [
1007
- c && e !== void 0 && /* @__PURE__ */ n(On, { rowId: e, label: t ?? `Select row ${e}` }),
1016
+ c && e !== void 0 && /* @__PURE__ */ n(eo, { rowId: e, label: t ?? `Select row ${e}` }),
1008
1017
  i
1009
1018
  ]
1010
1019
  }
1011
1020
  );
1012
1021
  }
1013
- function Qo({ sortKey: e, numeric: t, children: i, className: a }) {
1014
- const { sortable: c, sort: r, onSortChange: o } = L(R), s = c && e !== void 0, l = s && (r == null ? void 0 : r.key) === e, d = s ? l ? r.direction === "asc" ? "ascending" : "descending" : "none" : void 0, u = () => {
1022
+ function _r({ sortKey: e, numeric: t, children: i, className: a }) {
1023
+ const { sortable: c, sort: r, onSortChange: o } = S(V), s = c && e !== void 0, d = s && (r == null ? void 0 : r.key) === e, l = s ? d ? r.direction === "asc" ? "ascending" : "descending" : "none" : void 0, u = () => {
1015
1024
  if (!e) return;
1016
- const h = l && r.direction === "asc" ? "desc" : "asc";
1025
+ const h = d && r.direction === "asc" ? "desc" : "asc";
1017
1026
  o == null || o({ key: e, direction: h });
1018
1027
  };
1019
1028
  return /* @__PURE__ */ n(
@@ -1022,40 +1031,40 @@ function Qo({ sortKey: e, numeric: t, children: i, className: a }) {
1022
1031
  scope: "col",
1023
1032
  className: [k.headerCell, a].filter(Boolean).join(" "),
1024
1033
  "data-numeric": t || void 0,
1025
- "aria-sort": d,
1034
+ "aria-sort": l,
1026
1035
  children: s ? /* @__PURE__ */ p("button", { type: "button", className: k.sortButton, onClick: u, children: [
1027
1036
  i,
1028
- /* @__PURE__ */ n("span", { className: k.sortIndicator, "aria-hidden": "true", children: l ? r.direction === "asc" ? "↑" : "↓" : "" })
1037
+ /* @__PURE__ */ n("span", { className: k.sortIndicator, "aria-hidden": "true", children: d ? r.direction === "asc" ? "↑" : "↓" : "" })
1029
1038
  ] }) : i
1030
1039
  }
1031
1040
  );
1032
1041
  }
1033
- function er({ numeric: e, children: t, className: i }) {
1042
+ function fr({ numeric: e, children: t, className: i }) {
1034
1043
  return /* @__PURE__ */ n("td", { className: [k.cell, i].filter(Boolean).join(" "), "data-numeric": e || void 0, children: t });
1035
1044
  }
1036
- const Un = "_nav_166vs_6", Yn = "_ellipsis_166vs_12", ae = {
1037
- nav: Un,
1038
- ellipsis: Yn
1045
+ const no = "_nav_166vs_6", oo = "_ellipsis_166vs_12", de = {
1046
+ nav: no,
1047
+ ellipsis: oo
1039
1048
  };
1040
- function F(e, t) {
1049
+ function O(e, t) {
1041
1050
  return Array.from({ length: t - e + 1 }, (i, a) => e + a);
1042
1051
  }
1043
- function Zn(e, t, i) {
1052
+ function ro(e, t, i) {
1044
1053
  const a = Math.max(0, i), c = a * 2 + 1, r = c + 4;
1045
1054
  if (t <= r)
1046
- return F(1, t);
1047
- const o = Math.max(e - a, 1), s = Math.min(e + a, t), l = o > 3, d = s < t - 2;
1048
- if (!l && d) {
1055
+ return O(1, t);
1056
+ const o = Math.max(e - a, 1), s = Math.min(e + a, t), d = o > 3, l = s < t - 2;
1057
+ if (!d && l) {
1049
1058
  const u = Math.max(s, c);
1050
- return [...F(1, u), "ellipsis", t];
1059
+ return [...O(1, u), "ellipsis", t];
1051
1060
  }
1052
- if (l && !d) {
1061
+ if (d && !l) {
1053
1062
  const u = Math.min(o, t - c + 1);
1054
- return [1, "ellipsis", ...F(u, t)];
1063
+ return [1, "ellipsis", ...O(u, t)];
1055
1064
  }
1056
- return l && d ? [1, "ellipsis", ...F(o, s), "ellipsis", t] : F(1, t);
1065
+ return d && l ? [1, "ellipsis", ...O(o, s), "ellipsis", t] : O(1, t);
1057
1066
  }
1058
- function tr({
1067
+ function pr({
1059
1068
  page: e,
1060
1069
  pageCount: t,
1061
1070
  onPageChange: i,
@@ -1063,8 +1072,8 @@ function tr({
1063
1072
  "aria-label": c = "Pagination",
1064
1073
  className: r
1065
1074
  }) {
1066
- const o = Zn(e, t, a);
1067
- return /* @__PURE__ */ p("nav", { "aria-label": c, className: [ae.nav, r].filter(Boolean).join(" "), children: [
1075
+ const o = ro(e, t, a);
1076
+ return /* @__PURE__ */ p("nav", { "aria-label": c, className: [de.nav, r].filter(Boolean).join(" "), children: [
1068
1077
  /* @__PURE__ */ n(
1069
1078
  X,
1070
1079
  {
@@ -1077,8 +1086,8 @@ function tr({
1077
1086
  }
1078
1087
  ),
1079
1088
  o.map(
1080
- (s, l) => s === "ellipsis" ? /* @__PURE__ */ n("span", { className: ae.ellipsis, "aria-hidden": "true", children: "…" }, `e${l}`) : /* @__PURE__ */ n(
1081
- Me,
1089
+ (s, d) => s === "ellipsis" ? /* @__PURE__ */ n("span", { className: de.ellipsis, "aria-hidden": "true", children: "…" }, `e${d}`) : /* @__PURE__ */ n(
1090
+ Re,
1082
1091
  {
1083
1092
  size: 32,
1084
1093
  variant: s === e ? "accent-subtle" : "ghost",
@@ -1102,35 +1111,35 @@ function tr({
1102
1111
  )
1103
1112
  ] });
1104
1113
  }
1105
- const Gn = "_toast_7toru_10", Xn = "_icon_7toru_39", Jn = "_iconNeutral_7toru_44", Qn = "_iconSuccess_7toru_45", eo = "_iconWarning_7toru_46", to = "_iconDanger_7toru_47", no = "_body_7toru_51", oo = "_action_7toru_55", ro = "_srOnly_7toru_60", io = "_region_7toru_74", so = "_live_7toru_104", C = {
1106
- toast: Gn,
1107
- icon: Xn,
1108
- iconNeutral: Jn,
1109
- iconSuccess: Qn,
1110
- iconWarning: eo,
1111
- iconDanger: to,
1112
- body: no,
1113
- action: oo,
1114
- srOnly: ro,
1115
- region: io,
1116
- live: so
1117
- }, ao = {
1118
- neutral: pt,
1119
- success: ft,
1120
- warning: vt,
1121
- danger: gt
1122
- }, co = {
1114
+ const io = "_toast_7toru_10", so = "_icon_7toru_39", ao = "_iconNeutral_7toru_44", co = "_iconSuccess_7toru_45", lo = "_iconWarning_7toru_46", uo = "_iconDanger_7toru_47", ho = "_body_7toru_51", _o = "_action_7toru_55", fo = "_srOnly_7toru_60", po = "_region_7toru_74", vo = "_live_7toru_104", $ = {
1115
+ toast: io,
1116
+ icon: so,
1117
+ iconNeutral: ao,
1118
+ iconSuccess: co,
1119
+ iconWarning: lo,
1120
+ iconDanger: uo,
1121
+ body: ho,
1122
+ action: _o,
1123
+ srOnly: fo,
1124
+ region: po,
1125
+ live: vo
1126
+ }, bo = {
1127
+ neutral: mt,
1128
+ success: yt,
1129
+ warning: wt,
1130
+ danger: xt
1131
+ }, go = {
1123
1132
  neutral: null,
1124
1133
  success: "Success:",
1125
1134
  warning: "Warning:",
1126
1135
  danger: "Error:"
1127
- }, lo = {
1128
- neutral: C.iconNeutral,
1129
- success: C.iconSuccess,
1130
- warning: C.iconWarning,
1131
- danger: C.iconDanger
1136
+ }, yo = {
1137
+ neutral: $.iconNeutral,
1138
+ success: $.iconSuccess,
1139
+ warning: $.iconWarning,
1140
+ danger: $.iconDanger
1132
1141
  };
1133
- function ve({
1142
+ function ge({
1134
1143
  variant: e = "neutral",
1135
1144
  children: t,
1136
1145
  action: i,
@@ -1138,14 +1147,14 @@ function ve({
1138
1147
  className: c,
1139
1148
  ref: r
1140
1149
  }) {
1141
- const o = ao[e], s = co[e], l = [C.toast, c].filter(Boolean).join(" ");
1142
- return /* @__PURE__ */ p("div", { ref: r, className: l, "data-variant": e, "data-psi-toast": !0, children: [
1143
- /* @__PURE__ */ n("span", { className: [C.icon, lo[e]].join(" "), children: /* @__PURE__ */ n(o, { size: 20, "aria-hidden": "true" }) }),
1144
- /* @__PURE__ */ p("div", { className: C.body, children: [
1145
- s && /* @__PURE__ */ n("span", { className: C.srOnly, children: s }),
1150
+ const o = bo[e], s = go[e], d = [$.toast, c].filter(Boolean).join(" ");
1151
+ return /* @__PURE__ */ p("div", { ref: r, className: d, "data-variant": e, "data-psi-toast": !0, children: [
1152
+ /* @__PURE__ */ n("span", { className: [$.icon, yo[e]].join(" "), children: /* @__PURE__ */ n(o, { size: 20, "aria-hidden": "true" }) }),
1153
+ /* @__PURE__ */ p("div", { className: $.body, children: [
1154
+ s && /* @__PURE__ */ n("span", { className: $.srOnly, children: s }),
1146
1155
  t
1147
1156
  ] }),
1148
- i != null && /* @__PURE__ */ n("div", { className: C.action, children: i }),
1157
+ i != null && /* @__PURE__ */ n("div", { className: $.action, children: i }),
1149
1158
  a && /* @__PURE__ */ n(
1150
1159
  X,
1151
1160
  {
@@ -1153,25 +1162,25 @@ function ve({
1153
1162
  size: 32,
1154
1163
  "aria-label": "Dismiss notification",
1155
1164
  onClick: a,
1156
- children: /* @__PURE__ */ n(ue, { "aria-hidden": "true" })
1165
+ children: /* @__PURE__ */ n(_e, { "aria-hidden": "true" })
1157
1166
  }
1158
1167
  )
1159
1168
  ] });
1160
1169
  }
1161
- const uo = /* @__PURE__ */ new Set(["warning", "danger"]);
1162
- function ce(e) {
1163
- if (!O(e) || e.type !== ve) return !1;
1170
+ const mo = /* @__PURE__ */ new Set(["warning", "danger"]);
1171
+ function ue(e) {
1172
+ if (!U(e) || e.type !== ge) return !1;
1164
1173
  const { variant: t } = e.props;
1165
- return uo.has(t ?? "neutral");
1174
+ return mo.has(t ?? "neutral");
1166
1175
  }
1167
- function ho({
1176
+ function wo({
1168
1177
  placement: e = "bottom-end",
1169
1178
  "aria-label": t = "Notifications",
1170
1179
  children: i,
1171
1180
  className: a,
1172
1181
  ref: c
1173
1182
  }) {
1174
- const r = B(null), o = (u) => {
1183
+ const r = x(null), o = (u) => {
1175
1184
  r.current = u, typeof c == "function" ? c(u) : c && (c.current = u);
1176
1185
  };
1177
1186
  N(() => {
@@ -1183,7 +1192,7 @@ function ho({
1183
1192
  (_ = u.hidePopover) == null || _.call(u);
1184
1193
  };
1185
1194
  }, []);
1186
- const s = W.toArray(i), l = s.filter(ce), d = s.filter((u) => !ce(u));
1195
+ const s = A.toArray(i), d = s.filter(ue), l = s.filter((u) => !ue(u));
1187
1196
  return /* @__PURE__ */ p(
1188
1197
  "div",
1189
1198
  {
@@ -1192,77 +1201,77 @@ function ho({
1192
1201
  "aria-label": t,
1193
1202
  "data-placement": e,
1194
1203
  "data-psi-toast-region": !0,
1195
- className: [C.region, a].filter(Boolean).join(" "),
1204
+ className: [$.region, a].filter(Boolean).join(" "),
1196
1205
  children: [
1197
- /* @__PURE__ */ n("div", { role: "status", "aria-live": "polite", className: C.live, children: d }),
1198
- /* @__PURE__ */ n("div", { role: "alert", "aria-live": "assertive", className: C.live, children: l })
1206
+ /* @__PURE__ */ n("div", { role: "status", "aria-live": "polite", className: $.live, children: l }),
1207
+ /* @__PURE__ */ n("div", { role: "alert", "aria-live": "assertive", className: $.live, children: d })
1199
1208
  ]
1200
1209
  }
1201
1210
  );
1202
1211
  }
1203
- const ge = K(null);
1204
- function nr() {
1205
- const e = L(ge);
1212
+ const ye = R(null);
1213
+ function vr() {
1214
+ const e = S(ye);
1206
1215
  if (!e)
1207
1216
  throw new Error(
1208
1217
  "Psi useToast: no ToastProvider found. Wrap your app (or the subtree that raises toasts) in <ToastProvider> — it owns the queue, the auto-dismiss timers and the single ToastRegion."
1209
1218
  );
1210
1219
  return e;
1211
1220
  }
1212
- function or({
1221
+ function br({
1213
1222
  limit: e = 3,
1214
1223
  duration: t = 5e3,
1215
1224
  actionDuration: i = 1e4,
1216
1225
  placement: a = "bottom-end",
1217
1226
  children: c
1218
1227
  }) {
1219
- const [r, o] = le([]), s = B(/* @__PURE__ */ new Map()), l = B(!1), d = B(0), u = U(), h = m((f) => {
1220
- const g = s.current.get(f);
1221
- (g == null ? void 0 : g.handle) !== void 0 && clearTimeout(g.handle), s.current.delete(f), o((S) => S.filter((H) => H.id !== f));
1222
- }, []), _ = m(
1223
- (f, g) => {
1224
- const S = l.current ? { handle: void 0, remaining: g, startedAt: void 0 } : { handle: setTimeout(() => h(f), g), remaining: g, startedAt: Date.now() };
1225
- s.current.set(f, S);
1228
+ const [r, o] = he([]), s = x(/* @__PURE__ */ new Map()), d = x(!1), l = x(0), u = H(), h = g((f) => {
1229
+ const v = s.current.get(f);
1230
+ (v == null ? void 0 : v.handle) !== void 0 && clearTimeout(v.handle), s.current.delete(f), o((T) => T.filter((q) => q.id !== f));
1231
+ }, []), _ = g(
1232
+ (f, v) => {
1233
+ const T = d.current ? { handle: void 0, remaining: v, startedAt: void 0 } : { handle: setTimeout(() => h(f), v), remaining: v, startedAt: Date.now() };
1234
+ s.current.set(f, T);
1226
1235
  },
1227
1236
  [h]
1228
- ), b = m(
1229
- ({ variant: f = "neutral", message: g, action: S }) => {
1230
- const H = `${u}-${d.current++}`, ne = S != null ? i : t;
1231
- return o((be) => {
1232
- const Q = [...be, { id: H, variant: f, message: g, action: S, duration: ne }];
1233
- for (; Q.length > e; ) {
1234
- const oe = Q.shift(), Y = s.current.get(oe.id);
1235
- (Y == null ? void 0 : Y.handle) !== void 0 && clearTimeout(Y.handle), s.current.delete(oe.id);
1237
+ ), y = g(
1238
+ ({ variant: f = "neutral", message: v, action: T }) => {
1239
+ const q = `${u}-${l.current++}`, ie = T != null ? i : t;
1240
+ return o((ke) => {
1241
+ const ee = [...ke, { id: q, variant: f, message: v, action: T, duration: ie }];
1242
+ for (; ee.length > e; ) {
1243
+ const se = ee.shift(), Y = s.current.get(se.id);
1244
+ (Y == null ? void 0 : Y.handle) !== void 0 && clearTimeout(Y.handle), s.current.delete(se.id);
1236
1245
  }
1237
- return Q;
1238
- }), _(H, ne), H;
1246
+ return ee;
1247
+ }), _(q, ie), q;
1239
1248
  },
1240
1249
  [i, _, t, u, e]
1241
- ), y = m(() => {
1250
+ ), m = g(() => {
1242
1251
  for (const f of s.current.values())
1243
1252
  f.handle !== void 0 && clearTimeout(f.handle);
1244
1253
  s.current.clear(), o([]);
1245
- }, []), j = m(() => {
1246
- if (!l.current) {
1247
- l.current = !0;
1248
- for (const [f, g] of s.current) {
1249
- if (g.handle === void 0) continue;
1250
- clearTimeout(g.handle);
1251
- const S = g.startedAt === void 0 ? 0 : Date.now() - g.startedAt;
1254
+ }, []), j = g(() => {
1255
+ if (!d.current) {
1256
+ d.current = !0;
1257
+ for (const [f, v] of s.current) {
1258
+ if (v.handle === void 0) continue;
1259
+ clearTimeout(v.handle);
1260
+ const T = v.startedAt === void 0 ? 0 : Date.now() - v.startedAt;
1252
1261
  s.current.set(f, {
1253
1262
  handle: void 0,
1254
- remaining: Math.max(0, g.remaining - S),
1263
+ remaining: Math.max(0, v.remaining - T),
1255
1264
  startedAt: void 0
1256
1265
  });
1257
1266
  }
1258
1267
  }
1259
- }, []), v = m(() => {
1260
- if (l.current) {
1261
- l.current = !1;
1262
- for (const [f, g] of s.current)
1263
- g.handle === void 0 && s.current.set(f, {
1264
- handle: setTimeout(() => h(f), g.remaining),
1265
- remaining: g.remaining,
1268
+ }, []), C = g(() => {
1269
+ if (d.current) {
1270
+ d.current = !1;
1271
+ for (const [f, v] of s.current)
1272
+ v.handle === void 0 && s.current.set(f, {
1273
+ handle: setTimeout(() => h(f), v.remaining),
1274
+ remaining: v.remaining,
1266
1275
  startedAt: Date.now()
1267
1276
  });
1268
1277
  }
@@ -1270,84 +1279,226 @@ function or({
1270
1279
  N(() => {
1271
1280
  const f = s.current;
1272
1281
  return () => {
1273
- for (const g of f.values())
1274
- g.handle !== void 0 && clearTimeout(g.handle);
1282
+ for (const v of f.values())
1283
+ v.handle !== void 0 && clearTimeout(v.handle);
1275
1284
  f.clear();
1276
1285
  };
1277
1286
  }, []);
1278
- const I = de(
1279
- () => ({ show: b, dismiss: h, clear: y }),
1280
- [b, h, y]
1287
+ const b = ne(
1288
+ () => ({ show: y, dismiss: h, clear: m }),
1289
+ [y, h, m]
1281
1290
  );
1282
- return /* @__PURE__ */ p(ge.Provider, { value: I, children: [
1291
+ return /* @__PURE__ */ p(ye.Provider, { value: b, children: [
1283
1292
  c,
1284
1293
  /* @__PURE__ */ n(
1285
1294
  "div",
1286
1295
  {
1287
1296
  onPointerEnter: j,
1288
- onPointerLeave: v,
1297
+ onPointerLeave: C,
1289
1298
  onFocusCapture: j,
1290
- onBlurCapture: v,
1291
- children: /* @__PURE__ */ n(ho, { placement: a, children: r.map((f) => /* @__PURE__ */ n(ve, { variant: f.variant, action: f.action, onDismiss: () => h(f.id), children: f.message }, f.id)) })
1299
+ onBlurCapture: C,
1300
+ children: /* @__PURE__ */ n(wo, { placement: a, children: r.map((f) => /* @__PURE__ */ n(ge, { variant: f.variant, action: f.action, onDismiss: () => h(f.id), children: f.message }, f.id)) })
1292
1301
  }
1293
1302
  )
1294
1303
  ] });
1295
1304
  }
1305
+ const xo = "_tabs_17vw6_8", ko = "_list_17vw6_21", Co = "_tab_17vw6_8", Bo = "_panel_17vw6_97", Q = {
1306
+ tabs: xo,
1307
+ list: ko,
1308
+ tab: Co,
1309
+ panel: Bo
1310
+ }, me = R(null);
1311
+ function re(e) {
1312
+ const t = S(me);
1313
+ if (!t)
1314
+ throw new Error(
1315
+ `Psi ${e}: must be rendered inside <Tabs>. Tabs owns the selected value, the orientation and the ids that wire aria-controls and aria-labelledby together.`
1316
+ );
1317
+ return t;
1318
+ }
1319
+ function gr({
1320
+ value: e,
1321
+ onValueChange: t,
1322
+ orientation: i = "horizontal",
1323
+ children: a,
1324
+ className: c,
1325
+ ref: r
1326
+ }) {
1327
+ const o = H(), s = ne(
1328
+ () => ({ value: e, onValueChange: t, orientation: i, idPrefix: o }),
1329
+ [e, t, i, o]
1330
+ );
1331
+ return /* @__PURE__ */ n(me.Provider, { value: s, children: /* @__PURE__ */ n(
1332
+ "div",
1333
+ {
1334
+ ref: r,
1335
+ className: [Q.tabs, c].filter(Boolean).join(" "),
1336
+ "data-orientation": i,
1337
+ children: a
1338
+ }
1339
+ ) });
1340
+ }
1341
+ function we(e, t) {
1342
+ return `${e}tab-${t}`;
1343
+ }
1344
+ function xe(e, t) {
1345
+ return `${e}panel-${t}`;
1346
+ }
1347
+ function $o({ listRef: e, orientation: t, onValueChange: i }) {
1348
+ const a = g(() => {
1349
+ const r = e.current;
1350
+ return r ? Array.from(
1351
+ r.querySelectorAll('[data-psi-tab]:not([aria-disabled="true"])')
1352
+ ) : [];
1353
+ }, [e]), c = g(
1354
+ (r) => {
1355
+ if (!r) return;
1356
+ for (const s of a()) s.tabIndex = s === r ? 0 : -1;
1357
+ r.focus();
1358
+ const o = r.dataset.value;
1359
+ o != null && i(o);
1360
+ },
1361
+ [a, i]
1362
+ );
1363
+ return g(
1364
+ (r) => {
1365
+ const o = a();
1366
+ if (o.length === 0) return;
1367
+ const [s, d] = t === "vertical" ? ["ArrowUp", "ArrowDown"] : ["ArrowLeft", "ArrowRight"], l = o.indexOf(document.activeElement);
1368
+ switch (r.key) {
1369
+ case d:
1370
+ r.preventDefault(), c(o[(l + 1 + o.length) % o.length]);
1371
+ break;
1372
+ case s:
1373
+ r.preventDefault(), c(o[(l - 1 + o.length) % o.length]);
1374
+ break;
1375
+ case "Home":
1376
+ r.preventDefault(), c(o[0]);
1377
+ break;
1378
+ case "End":
1379
+ r.preventDefault(), c(o[o.length - 1]);
1380
+ break;
1381
+ }
1382
+ },
1383
+ [c, a, t]
1384
+ );
1385
+ }
1386
+ function yr({ "aria-label": e, children: t, className: i, ref: a }) {
1387
+ const { orientation: c, onValueChange: r } = re("TabList"), o = x(null), s = (l) => {
1388
+ o.current = l, typeof a == "function" ? a(l) : a && (a.current = l);
1389
+ }, d = $o({ listRef: o, orientation: c, onValueChange: r });
1390
+ return /* @__PURE__ */ n(
1391
+ "div",
1392
+ {
1393
+ ref: s,
1394
+ role: "tablist",
1395
+ "aria-label": e,
1396
+ "aria-orientation": c,
1397
+ className: [Q.list, i].filter(Boolean).join(" "),
1398
+ onKeyDown: d,
1399
+ children: t
1400
+ }
1401
+ );
1402
+ }
1403
+ function mr({ value: e, children: t, disabled: i = !1, className: a, ref: c }) {
1404
+ const r = re("Tab"), o = r.value === e;
1405
+ return /* @__PURE__ */ n(
1406
+ "button",
1407
+ {
1408
+ ref: c,
1409
+ type: "button",
1410
+ role: "tab",
1411
+ id: we(r.idPrefix, e),
1412
+ "data-psi-tab": !0,
1413
+ "data-value": e,
1414
+ "aria-selected": o,
1415
+ "aria-controls": xe(r.idPrefix, e),
1416
+ "aria-disabled": i || void 0,
1417
+ tabIndex: o ? 0 : -1,
1418
+ className: [Q.tab, a].filter(Boolean).join(" "),
1419
+ onClick: () => {
1420
+ i || r.onValueChange(e);
1421
+ },
1422
+ children: t
1423
+ }
1424
+ );
1425
+ }
1426
+ function wr({ value: e, children: t, className: i, ref: a }) {
1427
+ const c = re("TabPanel"), r = c.value === e;
1428
+ return /* @__PURE__ */ n(
1429
+ "div",
1430
+ {
1431
+ ref: a,
1432
+ role: "tabpanel",
1433
+ id: xe(c.idPrefix, e),
1434
+ "aria-labelledby": we(c.idPrefix, e),
1435
+ hidden: !r,
1436
+ tabIndex: 0,
1437
+ className: [Q.panel, i].filter(Boolean).join(" "),
1438
+ children: t
1439
+ }
1440
+ );
1441
+ }
1296
1442
  export {
1297
- bo as AspectRatio,
1298
- Me as Button,
1299
- po as Card,
1300
- he as Checkbox,
1301
- Ro as Dialog,
1302
- yo as Field,
1303
- gt as IconAlertCircle,
1304
- vt as IconAlertTriangle,
1305
- Eo as IconArrowDown,
1306
- Mo as IconArrowUpRight,
1443
+ To as AspectRatio,
1444
+ Re as Button,
1445
+ So as Card,
1446
+ fe as Checkbox,
1447
+ er as Dialog,
1448
+ Io as Field,
1449
+ xt as IconAlertCircle,
1450
+ wt as IconAlertTriangle,
1451
+ Yo as IconArrowDown,
1452
+ Zo as IconArrowUpRight,
1307
1453
  X as IconButton,
1308
- ft as IconCheck,
1309
- ko as IconChevronDown,
1310
- xo as IconChevronRight,
1311
- ue as IconClose,
1312
- jo as IconCopy,
1313
- $o as IconEdit,
1314
- So as IconExternalLink,
1315
- zo as IconEye,
1316
- Io as IconEyeOff,
1317
- Ao as IconGitHub,
1318
- pt as IconInfo,
1319
- Do as IconInstagram,
1320
- Wo as IconLinkedIn,
1321
- To as IconLoader,
1322
- wo as IconMinus,
1323
- mo as IconPlus,
1324
- Co as IconSearch,
1325
- Bo as IconSettings,
1326
- Lo as IconTrash,
1327
- No as IconUser,
1328
- Po as IconX,
1329
- Ho as Input,
1330
- Uo as Menu,
1331
- _e as MenuContext,
1332
- Yo as MenuItem,
1333
- Zo as MenuSeparator,
1334
- go as NavBar,
1335
- tr as Pagination,
1336
- vo as Panel,
1337
- Vo as Select,
1338
- qo as Switch,
1339
- Go as Table,
1340
- qn as TableBody,
1341
- er as TableCell,
1342
- Xo as TableHead,
1343
- Qo as TableHeaderCell,
1344
- Jo as TableRow,
1345
- Fo as Tag,
1346
- ve as Toast,
1347
- ge as ToastContext,
1348
- or as ToastProvider,
1349
- ho as ToastRegion,
1350
- Ko as Toolbar,
1351
- Oo as Tooltip,
1352
- nr as useToast
1454
+ yt as IconCheck,
1455
+ Ao as IconChevronDown,
1456
+ Po as IconChevronRight,
1457
+ _e as IconClose,
1458
+ qo as IconCopy,
1459
+ Ho as IconEdit,
1460
+ Fo as IconExternalLink,
1461
+ Ko as IconEye,
1462
+ Oo as IconEyeOff,
1463
+ Xo as IconGitHub,
1464
+ mt as IconInfo,
1465
+ Qo as IconInstagram,
1466
+ Go as IconLinkedIn,
1467
+ Uo as IconLoader,
1468
+ Mo as IconMinus,
1469
+ Eo as IconPlus,
1470
+ Wo as IconSearch,
1471
+ Do as IconSettings,
1472
+ Vo as IconTrash,
1473
+ Ro as IconUser,
1474
+ Jo as IconX,
1475
+ tr as Input,
1476
+ ar as Menu,
1477
+ pe as MenuContext,
1478
+ cr as MenuItem,
1479
+ lr as MenuSeparator,
1480
+ jo as NavBar,
1481
+ pr as Pagination,
1482
+ zo as Panel,
1483
+ nr as Select,
1484
+ or as Switch,
1485
+ mr as Tab,
1486
+ yr as TabList,
1487
+ wr as TabPanel,
1488
+ dr as Table,
1489
+ Jn as TableBody,
1490
+ fr as TableCell,
1491
+ ur as TableHead,
1492
+ _r as TableHeaderCell,
1493
+ hr as TableRow,
1494
+ gr as Tabs,
1495
+ me as TabsContext,
1496
+ rr as Tag,
1497
+ ge as Toast,
1498
+ ye as ToastContext,
1499
+ br as ToastProvider,
1500
+ wo as ToastRegion,
1501
+ sr as Toolbar,
1502
+ ir as Tooltip,
1503
+ vr as useToast
1353
1504
  };