@shlinkio/shlink-frontend-kit 0.8.4 → 0.8.6

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/tailwind.js CHANGED
@@ -1,164 +1,165 @@
1
- import { jsx as n, jsxs as i, Fragment as T } from "react/jsx-runtime";
2
- import w, { clsx as f } from "clsx";
3
- import { createContext as S, useContext as g, useCallback as F, useId as H, useMemo as O, useRef as $, useEffect as L, useState as Q } from "react";
4
- import { Link as U, NavLink as V } from "react-router";
5
- import { faClose as X, faSearch as Y, faChevronLeft as M, faChevronRight as R, faCircleNotch as Z } from "@fortawesome/free-solid-svg-icons";
6
- import { FontAwesomeIcon as b } from "@fortawesome/react-fontawesome";
7
- import { createPortal as tt } from "react-dom";
8
- import { u as et } from "./use-timeout-mQ792qNj.js";
9
- const N = S(void 0), x = S({ responsive: !0 }), rt = ({ children: t, className: e }) => {
10
- const { responsive: r } = g(x);
11
- return /* @__PURE__ */ n(N.Provider, { value: { section: "head" }, children: /* @__PURE__ */ n(
1
+ import { jsx as o, jsxs as i, Fragment as S } from "react/jsx-runtime";
2
+ import w, { clsx as p } from "clsx";
3
+ import { createContext as M, useContext as f, forwardRef as b, useCallback as C, useId as j, useMemo as J, useRef as E, useEffect as F, useState as rt } from "react";
4
+ import { Link as K, NavLink as ot } from "react-router";
5
+ import { faClose as nt, faEyeSlash as at, faEye as dt, faSearch as lt, faChevronLeft as U, faChevronRight as W, faCircleNotch as st } from "@fortawesome/free-solid-svg-icons";
6
+ import { FontAwesomeIcon as u } from "@fortawesome/react-fontawesome";
7
+ import { a as wt, b as it, u as ct } from "./use-toggle-DlYE68B3.js";
8
+ import { createPortal as mt } from "react-dom";
9
+ const I = M(void 0), v = M({ responsive: !0 }), gt = ({ children: t, className: r }) => {
10
+ const { responsive: e } = f(v);
11
+ return /* @__PURE__ */ o(I.Provider, { value: { section: "head" }, children: /* @__PURE__ */ o(
12
12
  "thead",
13
13
  {
14
14
  className: w(
15
- { "tw:hidden tw:lg:table-header-group": r },
16
- e
15
+ { "tw:hidden tw:lg:table-header-group": e },
16
+ r
17
17
  ),
18
18
  children: t
19
19
  }
20
20
  ) });
21
- }, ot = ({ children: t, className: e }) => {
22
- const { responsive: r } = g(x);
23
- return /* @__PURE__ */ n(N.Provider, { value: { section: "body" }, children: /* @__PURE__ */ n(
21
+ }, bt = ({ children: t, className: r }) => {
22
+ const { responsive: e } = f(v);
23
+ return /* @__PURE__ */ o(I.Provider, { value: { section: "body" }, children: /* @__PURE__ */ o(
24
24
  "tbody",
25
25
  {
26
26
  className: w(
27
- { "tw:lg:table-row-group tw:flex tw:flex-col tw:gap-y-3": r },
28
- e
27
+ { "tw:lg:table-row-group tw:flex tw:flex-col tw:gap-y-3": e },
28
+ r
29
29
  ),
30
30
  children: t
31
31
  }
32
32
  ) });
33
- }, nt = ({ children: t, className: e }) => {
34
- const { responsive: r } = g(x);
35
- return /* @__PURE__ */ n(N.Provider, { value: { section: "footer" }, children: /* @__PURE__ */ n(
33
+ }, pt = ({ children: t, className: r }) => {
34
+ const { responsive: e } = f(v);
35
+ return /* @__PURE__ */ o(I.Provider, { value: { section: "footer" }, children: /* @__PURE__ */ o(
36
36
  "tfoot",
37
37
  {
38
38
  className: w(
39
- { "tw:lg:table-row-group tw:flex tw:flex-col tw:gap-y-3 tw:mt-4": r },
40
- e
39
+ { "tw:lg:table-row-group tw:flex tw:flex-col tw:gap-y-3 tw:mt-4": e },
40
+ r
41
41
  ),
42
42
  children: t
43
43
  }
44
44
  ) });
45
- }, dt = ({ children: t, className: e, ...r }) => {
46
- const o = g(N), d = (o == null ? void 0 : o.section) === "body", { responsive: a } = g(x);
47
- return /* @__PURE__ */ n(
45
+ }, ut = ({ children: t, className: r, ...e }) => {
46
+ const n = f(I), a = (n == null ? void 0 : n.section) === "body", { responsive: l } = f(v);
47
+ return /* @__PURE__ */ o(
48
48
  "tr",
49
49
  {
50
50
  className: w(
51
51
  "tw:group",
52
52
  {
53
- "tw:lg:table-row tw:flex tw:flex-col": a,
54
- "tw:lg:border-0 tw:border-y-2 tw:border-lm-border tw:dark:border-dm-border": a,
55
- "tw:hover:bg-lm-primary tw:dark:hover:bg-dm-primary": d,
53
+ "tw:lg:table-row tw:flex tw:flex-col": l,
54
+ "tw:lg:border-0 tw:border-y-2 tw:border-lm-border tw:dark:border-dm-border": l,
55
+ "tw:hover:bg-lm-primary tw:dark:hover:bg-dm-primary": a,
56
56
  // Use a different hover bg color depending on the table being inside a card or not
57
- "tw:group-[&]/card:hover:bg-lm-secondary tw:dark:group-[&]/card:hover:bg-dm-secondary": d
57
+ "tw:group-[&]/card:hover:bg-lm-secondary tw:dark:group-[&]/card:hover:bg-dm-secondary": a
58
58
  },
59
- e
59
+ r
60
60
  ),
61
- ...r,
61
+ ...e,
62
62
  children: t
63
63
  }
64
64
  );
65
- }, lt = ({ children: t, className: e, columnName: r, type: o, ...d }) => {
66
- const a = g(N), l = o ?? ((a == null ? void 0 : a.section) !== "body" ? "th" : "td"), { responsive: s } = g(x);
67
- return /* @__PURE__ */ n(
68
- l,
65
+ }, ht = ({ children: t, className: r, columnName: e, type: n, ...a }) => {
66
+ const l = f(I), d = n ?? ((l == null ? void 0 : l.section) !== "body" ? "th" : "td"), { responsive: s } = f(v);
67
+ return /* @__PURE__ */ o(
68
+ d,
69
69
  {
70
- "data-column": s ? r : void 0,
70
+ "data-column": s ? e : void 0,
71
71
  className: w(
72
72
  "tw:p-2 tw:border-lm-border tw:dark:border-dm-border",
73
73
  {
74
74
  "tw:border-b-1": !s,
75
75
  "tw:block tw:lg:table-cell tw:not-last:border-b-1 tw:lg:border-b-1": s,
76
76
  // For md and lower, display the content in data-column attribute as before
77
- "tw:before:lg:hidden tw:before:content-[attr(data-column)] tw:before:font-bold tw:before:mr-1": s && l === "td"
77
+ "tw:before:lg:hidden tw:before:content-[attr(data-column)] tw:before:font-bold tw:before:mr-1": s && d === "td"
78
78
  },
79
- e
79
+ r
80
80
  ),
81
- ...d,
81
+ ...a,
82
82
  children: t
83
83
  }
84
84
  );
85
- }, at = ({ header: t, footer: e, children: r, responsive: o = !0, ...d }) => /* @__PURE__ */ n(x.Provider, { value: { responsive: o }, children: /* @__PURE__ */ i("table", { className: "tw:w-full", ...d, children: [
86
- /* @__PURE__ */ n(rt, { children: t }),
87
- /* @__PURE__ */ n(ot, { children: r }),
88
- e && /* @__PURE__ */ n(nt, { children: e })
89
- ] }) }), Rt = Object.assign(at, { Row: dt, Cell: lt }), wt = ({
85
+ }, ft = ({ header: t, footer: r, children: e, responsive: n = !0, ...a }) => /* @__PURE__ */ o(v.Provider, { value: { responsive: n }, children: /* @__PURE__ */ i("table", { className: "tw:w-full", ...a, children: [
86
+ /* @__PURE__ */ o(gt, { children: t }),
87
+ /* @__PURE__ */ o(bt, { children: e }),
88
+ r && /* @__PURE__ */ o(pt, { children: r })
89
+ ] }) }), Kt = Object.assign(ft, { Row: ut, Cell: ht }), xt = ({
90
90
  children: t,
91
- className: e,
92
- disabled: r,
93
- variant: o = "primary",
94
- size: d = "md",
95
- inline: a = !1,
96
- solid: l = !1,
91
+ className: r,
92
+ disabled: e,
93
+ variant: n = "primary",
94
+ size: a = "md",
95
+ inline: l = !1,
96
+ solid: d = !1,
97
97
  ...s
98
98
  }) => {
99
- const c = "to" in s ? U : "button";
99
+ const c = "to" in s ? K : "button";
100
100
  return (
101
101
  // @ts-expect-error We are explicitly checking for the `to` prop before using Link
102
- /* @__PURE__ */ n(
102
+ /* @__PURE__ */ o(
103
103
  c,
104
104
  {
105
105
  className: w(
106
106
  {
107
- "tw:inline-flex": a,
108
- "tw:flex": !a
107
+ "tw:inline-flex": l,
108
+ "tw:flex": !l
109
109
  },
110
110
  "tw:gap-2 tw:items-center tw:justify-center",
111
111
  "tw:border tw:rounded-md tw:no-underline",
112
112
  "tw:transition-colors",
113
113
  {
114
- "tw:focus-ring": o !== "danger",
115
- "tw:focus-ring-danger": o === "danger"
114
+ "tw:focus-ring": n !== "danger",
115
+ "tw:focus-ring-danger": n === "danger"
116
116
  },
117
117
  {
118
- "tw:px-1.5 tw:py-1 tw:text-sm": d === "sm",
119
- "tw:px-3 tw:py-1.5": d === "md",
120
- "tw:px-4 tw:py-2 tw:text-lg": d === "lg"
118
+ "tw:px-1.5 tw:py-1 tw:text-sm": a === "sm",
119
+ "tw:px-3 tw:py-1.5": a === "md",
120
+ "tw:px-4 tw:py-2 tw:text-lg": a === "lg"
121
121
  },
122
122
  {
123
- "tw:border-brand tw:text-brand": o === "primary",
124
- "tw:border-zinc-500": o === "secondary",
125
- "tw:text-zinc-500": o === "secondary" && !l,
126
- "tw:border-danger": o === "danger",
127
- "tw:text-danger": o === "danger" && !l
123
+ "tw:border-brand tw:text-brand": n === "primary",
124
+ "tw:border-zinc-500": n === "secondary",
125
+ "tw:text-zinc-500": n === "secondary" && !d,
126
+ "tw:border-danger": n === "danger",
127
+ "tw:text-danger": n === "danger" && !d
128
128
  },
129
- l && {
129
+ d && {
130
130
  "tw:text-white": !0,
131
- "tw:bg-brand": o === "primary",
132
- "tw:highlight:bg-brand-dark tw:highlight:border-brand-dark": o === "primary",
133
- "tw:bg-zinc-500": o === "secondary",
134
- "tw:highlight:bg-zinc-600 tw:highlight:border-zinc-600": o === "secondary",
135
- "tw:bg-danger": o === "danger",
136
- "tw:highlight:bg-danger-dark tw:highlight:border-danger-dark": o === "danger"
131
+ "tw:bg-brand": n === "primary",
132
+ "tw:highlight:bg-brand-dark tw:highlight:border-brand-dark": n === "primary",
133
+ "tw:bg-zinc-500": n === "secondary",
134
+ "tw:highlight:bg-zinc-600 tw:highlight:border-zinc-600": n === "secondary",
135
+ "tw:bg-danger": n === "danger",
136
+ "tw:highlight:bg-danger-dark tw:highlight:border-danger-dark": n === "danger"
137
137
  },
138
- !r && {
139
- "tw:highlight:text-white": !l,
140
- "tw:highlight:bg-brand": o === "primary",
141
- "tw:highlight:bg-zinc-500": o === "secondary",
142
- "tw:highlight:bg-danger": o === "danger"
138
+ !e && {
139
+ "tw:highlight:text-white": !d,
140
+ "tw:highlight:bg-brand": n === "primary",
141
+ "tw:highlight:bg-zinc-500": n === "secondary",
142
+ "tw:highlight:bg-danger": n === "danger"
143
143
  },
144
144
  {
145
- "tw:pointer-events-none tw:opacity-65": r
145
+ "tw:pointer-events-none tw:opacity-65": e
146
146
  },
147
- e
147
+ r
148
148
  ),
149
- disabled: r,
149
+ disabled: e,
150
150
  ...s,
151
151
  children: t
152
152
  }
153
153
  )
154
154
  );
155
- }, z = ({ className: t, onChange: e, ...r }) => {
156
- const o = F((d) => e == null ? void 0 : e(d.target.checked, d), [e]);
157
- return /* @__PURE__ */ n(
155
+ }, Q = b(({ className: t, onChange: r, ...e }, n) => {
156
+ const a = C((l) => r == null ? void 0 : r(l.target.checked, l), [r]);
157
+ return /* @__PURE__ */ o(
158
158
  "input",
159
159
  {
160
+ ref: n,
160
161
  type: "checkbox",
161
- className: f(
162
+ className: p(
162
163
  "tw:appearance-none tw:focus-ring",
163
164
  "tw:border-1 tw:border-lm-input-border tw:dark:border-dm-input-border",
164
165
  "tw:bg-lm-primary tw:dark:bg-dm-primary tw:checked:bg-brand tw:bg-no-repeat",
@@ -166,17 +167,18 @@ const N = S(void 0), x = S({ responsive: !0 }), rt = ({ children: t, className:
166
167
  "tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input",
167
168
  t
168
169
  ),
169
- onChange: o,
170
- ...r
170
+ onChange: a,
171
+ ...e
171
172
  }
172
173
  );
173
- }, jt = ({ className: t, ...e }) => /* @__PURE__ */ n(
174
- z,
174
+ }), Qt = b(({ className: t, ...r }, e) => /* @__PURE__ */ o(
175
+ Q,
175
176
  {
176
- className: f("tw:rounded-sm tw:w-4 tw:h-4 tw:checked:bg-(image:--tick) tw:bg-center", t),
177
- ...e
177
+ ref: e,
178
+ className: p("tw:rounded-sm tw:w-4 tw:h-4 tw:checked:bg-(image:--tick) tw:bg-center", t),
179
+ ...r
178
180
  }
179
- ), j = ({ onClick: t, label: e = "Close" }) => /* @__PURE__ */ n(
181
+ )), q = ({ onClick: t, label: r = "Close" }) => /* @__PURE__ */ o(
180
182
  "button",
181
183
  {
182
184
  onClick: t,
@@ -184,187 +186,259 @@ const N = S(void 0), x = S({ responsive: !0 }), rt = ({ children: t, className:
184
186
  "tw:opacity-50 tw:highlight:opacity-80 tw:transition-opacity",
185
187
  "tw:rounded-md tw:focus-ring"
186
188
  ),
187
- "aria-label": e,
188
- children: /* @__PURE__ */ n(b, { icon: X, size: "xl" })
189
+ "aria-label": r,
190
+ children: /* @__PURE__ */ o(u, { icon: nt, size: "xl" })
189
191
  }
190
- ), A = ({
192
+ ), H = b(({
191
193
  borderless: t = !1,
192
- size: e = "md",
193
- feedback: r,
194
- className: o,
195
- disabled: d,
196
- readOnly: a,
197
- ...l
198
- }) => {
199
- const s = !d && !a;
200
- return /* @__PURE__ */ n(
194
+ size: r = "md",
195
+ feedback: e,
196
+ className: n,
197
+ disabled: a,
198
+ readOnly: l,
199
+ ...d
200
+ }, s) => {
201
+ const c = !a && !l;
202
+ return /* @__PURE__ */ o(
201
203
  "input",
202
204
  {
205
+ ref: s,
203
206
  className: w(
204
207
  "tw:w-full",
205
208
  {
206
- "tw:focus-ring": !r,
207
- "tw:focus-ring-danger": r === "error"
209
+ "tw:focus-ring": !e,
210
+ "tw:focus-ring-danger": e === "error"
208
211
  },
209
212
  {
210
- "tw:px-2 tw:py-1 tw:text-sm": e === "sm",
211
- "tw:px-3 tw:py-1.5": e === "md",
212
- "tw:px-4 tw:py-2 tw:text-xl": e === "lg"
213
+ "tw:px-2 tw:py-1 tw:text-sm": r === "sm",
214
+ "tw:px-3 tw:py-1.5": r === "md",
215
+ "tw:px-4 tw:py-2 tw:text-xl": r === "lg"
213
216
  },
214
217
  {
215
218
  "tw:rounded-md tw:border": !t,
216
- "tw:border-lm-input-border tw:dark:border-dm-input-border": !t && !r,
217
- "tw:border-danger": !t && r === "error",
218
- "tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input": !s,
219
- "tw:bg-lm-primary tw:dark:bg-dm-primary": s,
219
+ "tw:border-lm-input-border tw:dark:border-dm-input-border": !t && !e,
220
+ "tw:border-danger": !t && e === "error",
221
+ "tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input": !c,
222
+ "tw:bg-lm-primary tw:dark:bg-dm-primary": c,
220
223
  // Use different background color when rendered inside a card
221
- "tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input": s
224
+ "tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input": c
222
225
  },
223
- o
226
+ n
224
227
  ),
225
- disabled: d,
226
- readOnly: a,
227
- ...l
228
+ disabled: a,
229
+ readOnly: l,
230
+ ...d
228
231
  }
229
232
  );
230
- }, W = ({ required: t, children: e, ...r }) => /* @__PURE__ */ i("label", { ...r, children: [
231
- e,
232
- t && /* @__PURE__ */ n("span", { className: "tw:text-danger tw:ml-1", "data-testid": "required-indicator", children: "*" })
233
- ] }), Dt = ({ label: t, inputClassName: e, required: r, hiddenRequired: o, error: d, ...a }) => {
234
- const l = H();
233
+ }), D = ({ required: t, children: r, ...e }) => /* @__PURE__ */ i("label", { ...e, children: [
234
+ r,
235
+ t && /* @__PURE__ */ o("span", { className: "tw:text-danger tw:ml-1", "data-testid": "required-indicator", children: "*" })
236
+ ] }), Vt = b(({ label: t, inputClassName: r, required: e, hiddenRequired: n, error: a, ...l }, d) => {
237
+ const s = j();
235
238
  return /* @__PURE__ */ i("div", { className: "tw:flex tw:flex-col tw:gap-1", children: [
236
- /* @__PURE__ */ n(W, { htmlFor: l, required: r, children: t }),
237
- /* @__PURE__ */ n(
238
- A,
239
+ /* @__PURE__ */ o(D, { htmlFor: s, required: e, children: t }),
240
+ /* @__PURE__ */ o(
241
+ H,
239
242
  {
240
- id: l,
241
- className: e,
242
- required: r || o,
243
- feedback: d ? "error" : void 0,
244
- ...a
243
+ ref: d,
244
+ id: s,
245
+ className: r,
246
+ required: e || n,
247
+ feedback: a ? "error" : void 0,
248
+ ...l
249
+ }
250
+ ),
251
+ a && /* @__PURE__ */ o("span", { className: "tw:text-danger", children: a })
252
+ ] });
253
+ }), yt = b(({ containerClassName: t, className: r, size: e, ...n }, a) => {
254
+ const [l, d, , s] = wt(!1), c = it(), m = C(({ relatedTarget: y }) => {
255
+ var g;
256
+ (g = c.current) != null && g.contains(y) || s();
257
+ }, [c, s]);
258
+ return /* @__PURE__ */ i(
259
+ "div",
260
+ {
261
+ className: p("tw:group tw:relative", t),
262
+ ref: c,
263
+ onBlurCapture: m,
264
+ children: [
265
+ /* @__PURE__ */ o(
266
+ H,
267
+ {
268
+ ref: a,
269
+ type: l ? "text" : "password",
270
+ className: p(
271
+ {
272
+ "tw:pr-10": e !== "sm",
273
+ "tw:pr-8": e === "sm"
274
+ },
275
+ r
276
+ ),
277
+ size: e,
278
+ "data-testid": "input",
279
+ ...n
280
+ }
281
+ ),
282
+ /* @__PURE__ */ o(
283
+ "button",
284
+ {
285
+ onClick: d,
286
+ title: l ? "Hide password" : "Show password",
287
+ "aria-label": l ? "Hide password" : "Show password",
288
+ className: p(
289
+ "tw:absolute tw:top-[50%] tw:translate-y-[-50%] tw:px-1",
290
+ "tw:text-placeholder tw:hover:text-lm-text tw:hover:dark:text-dm-text tw:transition-colors",
291
+ {
292
+ "tw:right-1.5": e !== "sm",
293
+ "tw:scale-85 tw:right-1": e === "sm"
294
+ }
295
+ ),
296
+ tabIndex: -1,
297
+ children: /* @__PURE__ */ o(u, { fixedWidth: !0, icon: l ? at : dt })
298
+ }
299
+ )
300
+ ]
301
+ }
302
+ );
303
+ }), Xt = b(({ label: t, inputClassName: r, required: e, hiddenRequired: n, error: a, ...l }, d) => {
304
+ const s = j();
305
+ return /* @__PURE__ */ i("div", { className: "tw:flex tw:flex-col tw:gap-1", children: [
306
+ /* @__PURE__ */ o(D, { htmlFor: s, required: e, children: t }),
307
+ /* @__PURE__ */ o(
308
+ yt,
309
+ {
310
+ ref: d,
311
+ id: s,
312
+ className: r,
313
+ required: e || n,
314
+ feedback: a ? "error" : void 0,
315
+ ...l
245
316
  }
246
317
  ),
247
- d && /* @__PURE__ */ n("span", { className: "tw:text-danger", children: d })
318
+ a && /* @__PURE__ */ o("span", { className: "tw:text-danger", children: a })
248
319
  ] });
249
- }, st = ({
320
+ }), kt = b(({
250
321
  className: t,
251
- size: e = "md",
252
- feedback: r,
253
- style: o = {},
254
- disabled: d,
255
- ...a
256
- }) => /* @__PURE__ */ n(
322
+ size: r = "md",
323
+ feedback: e,
324
+ style: n = {},
325
+ disabled: a,
326
+ ...l
327
+ }, d) => /* @__PURE__ */ o(
257
328
  "select",
258
329
  {
330
+ ref: d,
259
331
  className: w(
260
332
  "tw:w-full tw:appearance-none tw:pr-9",
261
333
  "tw:bg-(image:--chevron-down) tw:bg-no-repeat",
262
334
  {
263
- "tw:focus-ring": !r,
264
- "tw:focus-ring-danger": r === "error"
335
+ "tw:focus-ring": !e,
336
+ "tw:focus-ring-danger": e === "error"
265
337
  },
266
338
  "tw:rounded-md tw:border",
267
339
  {
268
- "tw:border-lm-input-border tw:dark:border-dm-input-border": !r,
269
- "tw:border-danger": r === "error"
340
+ "tw:border-lm-input-border tw:dark:border-dm-input-border": !e,
341
+ "tw:border-danger": e === "error"
270
342
  },
271
343
  {
272
- "tw:pl-2 tw:py-1 tw:text-sm": e === "sm",
273
- "tw:pl-3 tw:py-1.5": e === "md",
274
- "tw:pl-4 tw:py-2 tw:text-xl": e === "lg",
275
- "tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input": d,
344
+ "tw:pl-2 tw:py-1 tw:text-sm": r === "sm",
345
+ "tw:pl-3 tw:py-1.5": r === "md",
346
+ "tw:pl-4 tw:py-2 tw:text-xl": r === "lg",
347
+ "tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input": a,
276
348
  // Apply different background color when rendered inside a card
277
- "tw:bg-lm-primary tw:dark:bg-dm-primary tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input": !d
349
+ "tw:bg-lm-primary tw:dark:bg-dm-primary tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input": !a
278
350
  },
279
351
  t
280
352
  ),
281
353
  style: {
282
- ...o,
354
+ ...n,
283
355
  background: "right 0.75rem center / 16px 12px"
284
356
  },
285
- disabled: d,
286
- ...a
357
+ disabled: a,
358
+ ...l
287
359
  }
288
- ), Ht = ({ selectClassName: t, label: e, required: r, hiddenRequired: o, ...d }) => {
289
- const a = H();
360
+ )), Yt = b(({ selectClassName: t, label: r, required: e, hiddenRequired: n, ...a }, l) => {
361
+ const d = j();
290
362
  return /* @__PURE__ */ i("div", { className: "tw:flex tw:flex-col tw:gap-1", children: [
291
- /* @__PURE__ */ n(W, { htmlFor: a, required: r, children: e }),
292
- /* @__PURE__ */ n(st, { id: a, className: t, required: r || o, ...d })
363
+ /* @__PURE__ */ o(D, { htmlFor: d, required: e, children: r }),
364
+ /* @__PURE__ */ o(kt, { ref: l, id: d, className: t, required: e || n, ...a })
293
365
  ] });
294
- }, Ot = ({
366
+ }), Zt = b(({
295
367
  onChange: t,
296
- containerClassName: e,
297
- inputClassName: r,
368
+ containerClassName: r,
369
+ inputClassName: e,
298
370
  // Inputs have a default 'md' size. Search inputs are usually 'lg' as they are rendered at the top of sections
299
- size: o = "lg",
300
- ...d
301
- }) => {
302
- const { setTimeout: a, clearCurrentTimeout: l } = et(500), s = F((c) => {
303
- c ? a(() => t(c)) : (l(), t(c));
304
- }, [l, t, a]);
305
- return /* @__PURE__ */ i("div", { className: w("tw:group tw:relative tw:focus-within:z-10", e), children: [
306
- /* @__PURE__ */ n(
307
- b,
371
+ size: n = "lg",
372
+ ...a
373
+ }, l) => {
374
+ const { setTimeout: d, clearCurrentTimeout: s } = ct(500), c = C((m) => {
375
+ m ? d(() => t(m)) : (s(), t(m));
376
+ }, [s, t, d]);
377
+ return /* @__PURE__ */ i("div", { className: w("tw:group tw:relative tw:focus-within:z-10", r), children: [
378
+ /* @__PURE__ */ o(
379
+ u,
308
380
  {
309
- icon: Y,
381
+ icon: lt,
310
382
  className: w(
311
383
  "tw:absolute tw:top-[50%] tw:translate-y-[-50%] tw:transition-colors",
312
384
  "tw:text-placeholder tw:group-focus-within:text-lm-text tw:dark:group-focus-within:text-dm-text",
313
385
  {
314
- "tw:left-3": o !== "sm",
315
- "tw:scale-85 tw:left-2": o === "sm"
386
+ "tw:left-3": n !== "sm",
387
+ "tw:scale-85 tw:left-2": n === "sm"
316
388
  }
317
389
  )
318
390
  }
319
391
  ),
320
- /* @__PURE__ */ n(
321
- A,
392
+ /* @__PURE__ */ o(
393
+ H,
322
394
  {
395
+ ref: l,
323
396
  type: "search",
324
397
  className: w(
325
398
  {
326
- "tw:pl-9": o !== "sm",
327
- "tw:pl-7": o === "sm"
399
+ "tw:pl-9": n !== "sm",
400
+ "tw:pl-7": n === "sm"
328
401
  },
329
- r
402
+ e
330
403
  ),
331
404
  placeholder: "Search...",
332
- onChange: (c) => s(c.target.value),
333
- size: o,
334
- ...d
405
+ onChange: (m) => c(m.target.value),
406
+ size: n,
407
+ ...a
335
408
  }
336
409
  )
337
410
  ] });
338
- }, $t = ({ className: t, ...e }) => /* @__PURE__ */ n(
339
- z,
411
+ }), zt = b(({ className: t, ...r }, e) => /* @__PURE__ */ o(
412
+ Q,
340
413
  {
341
- className: f(
414
+ ref: e,
415
+ className: p(
342
416
  "tw:rounded-full tw:w-8 tw:h-4",
343
417
  "tw:bg-(image:--circle-grey-dark) tw:dark:bg-(image:--circle-grey-light) tw:checked:bg-(image:--circle-white)",
344
418
  "tw:focus-visible:not-checked:bg-(image:--circle-light-blue)",
345
419
  "tw:checked:bg-right tw:transition-[background-position]",
346
420
  t
347
421
  ),
348
- ...e
422
+ ...r
349
423
  }
350
- ), it = ({ className: t, disabled: e, size: r = "md", ...o }) => /* @__PURE__ */ n(
424
+ )), Nt = ({ className: t, disabled: r, size: e = "md", ...n }) => /* @__PURE__ */ o(
351
425
  "button",
352
426
  {
353
427
  className: w(
354
428
  "tw:inline-flex tw:rounded-md tw:focus-ring",
355
429
  "tw:text-brand tw:highlight:text-brand-dark tw:highlight:underline",
356
430
  {
357
- "tw:px-1.5 tw:py-1 tw:text-sm": r === "sm",
358
- "tw:px-3 tw:py-1.5": r === "md",
359
- "tw:px-4 tw:py-2 tw:text-lg": r === "lg",
360
- "tw:pointer-events-none tw:opacity-65": e
431
+ "tw:px-1.5 tw:py-1 tw:text-sm": e === "sm",
432
+ "tw:px-3 tw:py-1.5": e === "md",
433
+ "tw:px-4 tw:py-2 tw:text-lg": e === "lg",
434
+ "tw:pointer-events-none tw:opacity-65": r
361
435
  },
362
436
  t
363
437
  ),
364
- disabled: e,
365
- ...o
438
+ disabled: r,
439
+ ...n
366
440
  }
367
- ), ct = ({ className: t, ...e }) => /* @__PURE__ */ n(
441
+ ), vt = ({ className: t, ...r }) => /* @__PURE__ */ o(
368
442
  "div",
369
443
  {
370
444
  className: w(
@@ -372,9 +446,9 @@ const N = S(void 0), x = S({ responsive: !0 }), rt = ({ children: t, className:
372
446
  "tw:bg-lm-primary tw:dark:bg-dm-primary tw:border-b tw:border-lm-border tw:dark:border-dm-border",
373
447
  t
374
448
  ),
375
- ...e
449
+ ...r
376
450
  }
377
- ), mt = ({ className: t, ...e }) => /* @__PURE__ */ n(
451
+ ), Pt = ({ className: t, ...r }) => /* @__PURE__ */ o(
378
452
  "div",
379
453
  {
380
454
  className: w(
@@ -382,9 +456,9 @@ const N = S(void 0), x = S({ responsive: !0 }), rt = ({ children: t, className:
382
456
  "tw:first:rounded-t-md tw:last:rounded-b-md",
383
457
  t
384
458
  ),
385
- ...e
459
+ ...r
386
460
  }
387
- ), gt = ({ className: t, ...e }) => /* @__PURE__ */ n(
461
+ ), Ct = ({ className: t, ...r }) => /* @__PURE__ */ o(
388
462
  "div",
389
463
  {
390
464
  className: w(
@@ -392,9 +466,9 @@ const N = S(void 0), x = S({ responsive: !0 }), rt = ({ children: t, className:
392
466
  "tw:bg-lm-primary tw:dark:bg-dm-primary tw:border-t tw:border-lm-border tw:dark:border-dm-border",
393
467
  t
394
468
  ),
395
- ...e
469
+ ...r
396
470
  }
397
- ), bt = ({ className: t, ...e }) => /* @__PURE__ */ n(
471
+ ), It = ({ className: t, ...r }) => /* @__PURE__ */ o(
398
472
  "div",
399
473
  {
400
474
  className: w(
@@ -402,190 +476,197 @@ const N = S(void 0), x = S({ responsive: !0 }), rt = ({ children: t, className:
402
476
  "tw:border tw:border-lm-border tw:dark:border-dm-border tw:bg-lm-primary tw:dark:bg-dm-primary",
403
477
  t
404
478
  ),
405
- ...e
479
+ ...r
406
480
  }
407
- ), m = Object.assign(bt, { Body: mt, Header: ct, Footer: gt }), pt = ({ bodyClassName: t, children: e, ...r }) => {
408
- const { title: o, titleSize: d = "md", ...a } = "title" in r ? r : {
409
- ...r,
481
+ ), h = Object.assign(It, { Body: Pt, Header: vt, Footer: Ct }), Rt = ({ bodyClassName: t, children: r, ...e }) => {
482
+ const { title: n, titleSize: a = "md", ...l } = "title" in e ? e : {
483
+ ...e,
410
484
  title: void 0,
411
485
  titleSize: void 0
412
486
  };
413
- return /* @__PURE__ */ i(m, { ...a, children: [
414
- o && /* @__PURE__ */ i(m.Header, { children: [
415
- d === "lg" && /* @__PURE__ */ n("h4", { children: o }),
416
- d === "md" && /* @__PURE__ */ n("h5", { children: o }),
417
- d === "sm" && /* @__PURE__ */ n("h6", { children: o })
487
+ return /* @__PURE__ */ i(h, { ...l, children: [
488
+ n && /* @__PURE__ */ i(h.Header, { children: [
489
+ a === "lg" && /* @__PURE__ */ o("h4", { children: n }),
490
+ a === "md" && /* @__PURE__ */ o("h5", { children: n }),
491
+ a === "sm" && /* @__PURE__ */ o("h6", { children: n })
418
492
  ] }),
419
- /* @__PURE__ */ n(m.Body, { className: t, children: e })
493
+ /* @__PURE__ */ o(h.Body, { className: t, children: r })
420
494
  ] });
421
- }, q = S(null), ht = ({ className: t, to: e, ...r }) => {
422
- const o = g(q);
423
- return /* @__PURE__ */ n(
424
- V,
495
+ }, V = M(null), Tt = ({ className: t, to: r, ...e }) => {
496
+ const n = f(V);
497
+ return /* @__PURE__ */ o(
498
+ ot,
425
499
  {
426
500
  role: "menuitem",
427
- to: e,
428
- className: ({ isActive: d }) => w(
501
+ to: r,
502
+ className: ({ isActive: a }) => w(
429
503
  "tw:px-4 tw:pt-2 tw:pb-[calc(0.5rem-3px)] tw:border-b-3",
430
504
  "tw:font-bold tw:no-underline tw:text-center tw:highlight:text-brand tw:transition-colors",
431
505
  "tw:rounded-none tw:outline-none tw:focus-visible:inset-ring-2 tw:focus-visible:inset-ring-brand/50",
432
506
  {
433
- "tw:border-b-brand active": d,
434
- "tw:border-b-transparent tw:text-gray-500": !d,
435
- "tw:flex-grow": o == null ? void 0 : o.fill
507
+ "tw:border-b-brand active": a,
508
+ "tw:border-b-transparent tw:text-gray-500": !a,
509
+ "tw:flex-grow": n == null ? void 0 : n.fill
436
510
  },
437
511
  t
438
512
  ),
439
- ...r
513
+ ...e
440
514
  }
441
515
  );
442
- }, ut = ({ children: t, className: e, fill: r }) => /* @__PURE__ */ n(q.Provider, { value: { fill: r }, children: /* @__PURE__ */ n(m, { role: "menubar", className: w("tw:flex tw:overflow-hidden", e), children: t }) }), Ut = Object.assign(ut, { Pill: ht }), ft = new Intl.NumberFormat("en-US"), xt = (t) => ft.format(Number(t)), D = 10, zt = (t) => Math.ceil(t / D) * D, u = 2, C = "...", yt = (t, e) => Array.from({ length: e - t }, (r, o) => t + o), kt = (t, e) => {
443
- const r = yt(
444
- Math.max(u, t - u),
445
- Math.min(e - 1, t + u) + 1
516
+ }, Bt = ({ children: t, className: r, fill: e }) => /* @__PURE__ */ o(V.Provider, { value: { fill: e }, children: /* @__PURE__ */ o(h, { role: "menubar", className: w("tw:flex tw:overflow-hidden", r), children: t }) }), te = Object.assign(Bt, { Pill: Tt }), Lt = new Intl.NumberFormat("en-US"), St = (t) => Lt.format(Number(t)), G = 10, ee = (t) => Math.ceil(t / G) * G, N = 2, B = "...", Et = (t, r) => Array.from({ length: r - t }, (e, n) => t + n), Ft = (t, r) => {
517
+ const e = Et(
518
+ Math.max(N, t - N),
519
+ Math.min(r - 1, t + N) + 1
446
520
  );
447
- return t - u > u && r.unshift(C), t + u < e - 1 && r.push(C), r.unshift(1), r.push(e), r;
448
- }, k = (t) => t === C, Nt = (t) => k(t) ? t : xt(t), vt = (t, e) => k(t) ? `${t}_${e}` : `${t}`, G = [
521
+ return t - N > N && e.unshift(B), t + N < r - 1 && e.push(B), e.unshift(1), e.push(r), e;
522
+ }, P = (t) => t === B, _t = (t) => P(t) ? t : St(t), Mt = (t, r) => P(t) ? `${t}_${r}` : `${t}`, X = [
449
523
  "tw:border tw:border-r-0 tw:last:border-r tw:border-lm-border tw:dark:border-dm-border",
450
524
  "tw:rounded-none tw:first:rounded-l tw:last:rounded-r"
451
- ], J = (t = !1) => w(
452
- G,
525
+ ], Y = (t = !1) => w(
526
+ X,
453
527
  "tw:px-3 py-2 tw:cursor-pointer tw:no-underline",
454
528
  "tw:focus-ring tw:focus-visible:z-1",
455
529
  {
456
530
  "tw:highlight:bg-lm-secondary tw:dark:highlight:bg-dm-secondary tw:text-brand": !t,
457
531
  "tw:bg-lm-brand tw:dark:bg-dm-brand tw:text-white": t
458
532
  }
459
- ), B = ({ children: t }) => /* @__PURE__ */ n("span", { "aria-hidden": !0, className: w(G, "tw:px-3 py-2 tw:text-gray-400"), children: t }), K = () => /* @__PURE__ */ n(B, { children: C });
460
- function Pt({ children: t, active: e, isEllipsis: r, href: o, ...d }) {
461
- const a = O(() => J(e), [e]);
462
- return r ? /* @__PURE__ */ n(K, {}) : /* @__PURE__ */ n(U, { className: a, to: o, ...d, children: t });
533
+ ), _ = ({ children: t }) => /* @__PURE__ */ o("span", { "aria-hidden": !0, className: w(X, "tw:px-3 py-2 tw:text-gray-400"), children: t }), Z = () => /* @__PURE__ */ o(_, { children: B });
534
+ function jt({ children: t, active: r, isEllipsis: e, href: n, ...a }) {
535
+ const l = J(() => Y(r), [r]);
536
+ return e ? /* @__PURE__ */ o(Z, {}) : /* @__PURE__ */ o(K, { className: l, to: n, ...a, children: t });
463
537
  }
464
- function Ct({ children: t, active: e, isEllipsis: r, ...o }) {
465
- const d = O(() => J(e), [e]);
466
- return r ? /* @__PURE__ */ n(K, {}) : /* @__PURE__ */ n("button", { type: "button", className: d, ...o, children: t });
538
+ function Ht({ children: t, active: r, isEllipsis: e, ...n }) {
539
+ const a = J(() => Y(r), [r]);
540
+ return e ? /* @__PURE__ */ o(Z, {}) : /* @__PURE__ */ o("button", { type: "button", className: a, ...n, children: t });
467
541
  }
468
- const At = ({ currentPage: t, pagesCount: e, ...r }) => {
469
- const o = "urlForPage" in r, d = o ? Pt : Ct, a = F(
470
- (l) => o ? { href: k(l) ? void 0 : r.urlForPage(l) } : { onClick: () => !k(l) && r.onPageChange(l) },
471
- [o, r]
542
+ const re = ({ currentPage: t, pagesCount: r, ...e }) => {
543
+ const n = "urlForPage" in e, a = n ? jt : Ht, l = C(
544
+ (d) => n ? { href: P(d) ? void 0 : e.urlForPage(d) } : { onClick: () => !P(d) && e.onPageChange(d) },
545
+ [n, e]
472
546
  );
473
- return e < 2 ? null : /* @__PURE__ */ i("div", { className: "tw:select-none tw:flex", "data-testid": "paginator", children: [
474
- t === 1 ? /* @__PURE__ */ n(B, { children: /* @__PURE__ */ n(b, { size: "xs", icon: M }) }) : /* @__PURE__ */ n(d, { ...a(Math.max(1, t - 1)), "aria-label": "Previous", children: /* @__PURE__ */ n(b, { size: "xs", icon: M }) }),
475
- kt(t, e).map((l, s) => /* @__PURE__ */ n(
476
- d,
547
+ return r < 2 ? null : /* @__PURE__ */ i("div", { className: "tw:select-none tw:flex", "data-testid": "paginator", children: [
548
+ t === 1 ? /* @__PURE__ */ o(_, { children: /* @__PURE__ */ o(u, { size: "xs", icon: U }) }) : /* @__PURE__ */ o(a, { ...l(Math.max(1, t - 1)), "aria-label": "Previous", children: /* @__PURE__ */ o(u, { size: "xs", icon: U }) }),
549
+ Ft(t, r).map((d, s) => /* @__PURE__ */ o(
550
+ a,
477
551
  {
478
- active: l === t,
479
- isEllipsis: k(l),
480
- ...a(l),
481
- children: Nt(l)
552
+ active: d === t,
553
+ isEllipsis: P(d),
554
+ ...l(d),
555
+ children: _t(d)
482
556
  },
483
- vt(l, s)
557
+ Mt(d, s)
484
558
  )),
485
- t === e ? /* @__PURE__ */ n(B, { children: /* @__PURE__ */ n(b, { size: "xs", icon: R }) }) : /* @__PURE__ */ n(d, { ...a(Math.min(e, t + 1)), "aria-label": "Next", children: /* @__PURE__ */ n(b, { size: "xs", icon: R }) })
559
+ t === r ? /* @__PURE__ */ o(_, { children: /* @__PURE__ */ o(u, { size: "xs", icon: W }) }) : /* @__PURE__ */ o(a, { ...l(Math.min(r, t + 1)), "aria-label": "Next", children: /* @__PURE__ */ o(u, { size: "xs", icon: W }) })
486
560
  ] });
487
- }, It = ({
561
+ }, Dt = ({
488
562
  open: t,
489
- children: e,
490
- className: r,
491
- onClose: o,
492
- ...d
563
+ children: r,
564
+ className: e,
565
+ onClose: n,
566
+ ...a
493
567
  }) => {
494
- const a = $(null);
495
- return L(() => {
496
- var v, y;
497
- const l = document.body, s = l.style.overflow, c = l.style.paddingRight;
568
+ const l = E(null);
569
+ return F(() => {
570
+ var m, y;
571
+ const d = document.body, s = d.style.overflow, c = d.style.paddingRight;
498
572
  if (t) {
499
- const I = window.outerWidth - l.clientWidth, p = l.scrollHeight > l.clientHeight;
500
- l.style.overflow = "hidden", p && (l.style.paddingRight = `${I}px`), (v = a.current) == null || v.showModal();
573
+ const g = window.outerWidth - d.clientWidth, k = d.scrollHeight > d.clientHeight;
574
+ d.style.overflow = "hidden", k && (d.style.paddingRight = `${g}px`), (m = l.current) == null || m.showModal();
501
575
  } else
502
- (y = a.current) == null || y.close();
576
+ (y = l.current) == null || y.close();
503
577
  return () => {
504
- l.style.overflow = s, l.style.paddingRight = c;
578
+ d.style.overflow = s, d.style.paddingRight = c;
505
579
  };
506
- }, [t]), tt(
507
- /* @__PURE__ */ n(
580
+ }, [t]), mt(
581
+ /* @__PURE__ */ o(
508
582
  "dialog",
509
583
  {
510
- ref: a,
511
- className: w("tw:bg-transparent tw:backdrop:bg-black/50", r),
512
- onCancel: (l) => {
513
- l.preventDefault(), o();
584
+ ref: l,
585
+ className: w("tw:bg-transparent tw:backdrop:bg-black/50", e),
586
+ onCancel: (d) => {
587
+ d.preventDefault(), n();
514
588
  },
515
- ...d,
516
- children: t && e
589
+ ...a,
590
+ children: t && r
517
591
  }
518
592
  ),
519
593
  document.body
520
594
  );
521
- }, Wt = ({
595
+ }, oe = ({
522
596
  open: t,
523
- onClose: e,
524
- variant: r = "default",
525
- title: o,
526
- children: d,
527
- className: a,
528
- ...l
597
+ onClose: r,
598
+ variant: e = "default",
599
+ title: n,
600
+ children: a,
601
+ className: l,
602
+ ...d
529
603
  }) => {
530
604
  const {
531
605
  size: s = "md",
532
606
  confirmText: c = "Confirm",
533
- confirmDisabled: v,
534
- onConfirm: y,
535
- ...I
536
- } = "onConfirm" in l ? l : { ...l }, [p, _] = Q(t), P = $(null);
537
- return L(() => {
607
+ cancelText: m = "Cancel",
608
+ confirmDisabled: y,
609
+ onConfirm: g,
610
+ onClosed: k,
611
+ ...z
612
+ } = "onConfirm" in d ? d : { ...d }, [R, O] = rt(t), T = E(null), L = E("cancel"), tt = C(() => {
613
+ L.current = "confirm", g == null || g();
614
+ }, [g]);
615
+ return F(() => {
538
616
  if (t) {
539
- _(!0);
617
+ L.current = "cancel", O(!0);
540
618
  return;
541
619
  }
542
- const h = P.current;
543
- if (h) {
544
- delete P.current.dataset.open;
545
- const E = () => _(!1);
546
- return h.addEventListener("transitionend", E, { once: !0 }), () => {
547
- h.removeEventListener("transitionend", E);
620
+ const x = T.current;
621
+ if (x) {
622
+ delete T.current.dataset.open;
623
+ let $ = !1;
624
+ const A = (et) => {
625
+ $ || et.target !== x || ($ = !0, O(!1), k == null || k(L.current));
626
+ };
627
+ return x.addEventListener("transitionend", A), () => {
628
+ x.removeEventListener("transitionend", A);
548
629
  };
549
630
  }
550
- }, [t]), L(() => {
551
- const h = P.current;
552
- p && h && (h.dataset.open = "");
553
- }, [p]), /* @__PURE__ */ n(
554
- It,
631
+ }, [k, t]), F(() => {
632
+ const x = T.current;
633
+ R && x && (x.dataset.open = "");
634
+ }, [R]), /* @__PURE__ */ o(
635
+ Dt,
555
636
  {
556
- open: p,
557
- onClose: e,
637
+ open: R,
638
+ onClose: r,
558
639
  className: w(
559
640
  {
560
- "tw:flex tw:w-screen tw:h-screen tw:max-w-screen tw:max-h-screen": p,
561
- "tw:overflow-hidden": r === "cover"
641
+ "tw:flex tw:w-screen tw:h-screen tw:max-w-screen tw:max-h-screen": R,
642
+ "tw:overflow-hidden": e === "cover"
562
643
  },
563
- a
644
+ l
564
645
  ),
565
- ...I,
566
- children: /* @__PURE__ */ n(
646
+ ...z,
647
+ children: /* @__PURE__ */ o(
567
648
  "div",
568
649
  {
569
650
  "data-testid": "transition-container",
570
- ref: P,
651
+ ref: T,
571
652
  className: w(
572
653
  "tw:w-full tw:m-auto tw:p-4 tw:sm:p-6",
573
654
  // CSS transitions are based on the presence of the `data-open` attribute
574
655
  "tw:-translate-y-4 tw:data-open:translate-y-0 tw:opacity-0 tw:data-open:opacity-100",
575
- "tw:transition-[opacity_transform] tw:duration-300",
656
+ "tw:transition-[opacity_,_translate] tw:duration-300",
576
657
  // Handle modal dimensions for different variants and sizes
577
- r !== "cover" && {
658
+ e !== "cover" && {
578
659
  "tw:sm:w-sm": s === "sm",
579
660
  "tw:md:w-lg": s === "md",
580
661
  "tw:md:w-4xl": s === "lg",
581
662
  "tw:md:w-6xl": s === "xl"
582
663
  },
583
- { "tw:h-full": r === "cover" }
664
+ { "tw:h-full": e === "cover" }
584
665
  ),
585
- children: /* @__PURE__ */ n(m, { className: w(
666
+ children: /* @__PURE__ */ o(h, { className: w(
586
667
  "tw:w-full",
587
- { "tw:h-full tw:relative tw:overflow-auto": r === "cover" }
588
- ), children: r === "cover" ? /* @__PURE__ */ i(T, { children: [
668
+ { "tw:h-full tw:relative tw:overflow-auto": e === "cover" }
669
+ ), children: e === "cover" ? /* @__PURE__ */ i(S, { children: [
589
670
  /* @__PURE__ */ i(
590
671
  "div",
591
672
  {
@@ -596,23 +677,23 @@ const At = ({ currentPage: t, pagesCount: e, ...r }) => {
596
677
  "tw:[text-shadow:_0_2px_4px_rgb(0_0_0/_0.8)]"
597
678
  ),
598
679
  children: [
599
- /* @__PURE__ */ n("h5", { children: o }),
600
- /* @__PURE__ */ n(j, { onClick: e, label: "Close dialog" })
680
+ /* @__PURE__ */ o("h5", { children: n }),
681
+ /* @__PURE__ */ o(q, { onClick: r, label: "Close dialog" })
601
682
  ]
602
683
  }
603
684
  ),
604
- /* @__PURE__ */ n("div", { children: d })
605
- ] }) : /* @__PURE__ */ i(T, { children: [
606
- /* @__PURE__ */ i(m.Header, { className: w(
685
+ /* @__PURE__ */ o("div", { children: a })
686
+ ] }) : /* @__PURE__ */ i(S, { children: [
687
+ /* @__PURE__ */ i(h.Header, { className: w(
607
688
  "tw:sticky tw:top-0",
608
689
  "tw:flex tw:items-center tw:justify-between tw:gap-x-2"
609
690
  ), children: [
610
- /* @__PURE__ */ n("h5", { className: w({ "tw:text-danger": r === "danger" }), children: o }),
611
- /* @__PURE__ */ n(j, { onClick: e, label: "Close dialog" })
691
+ /* @__PURE__ */ o("h5", { className: w({ "tw:text-danger": e === "danger" }), children: n }),
692
+ /* @__PURE__ */ o(q, { onClick: r, label: "Close dialog" })
612
693
  ] }),
613
- /* @__PURE__ */ n(m.Body, { children: d }),
614
- y && /* @__PURE__ */ i(
615
- m.Footer,
694
+ /* @__PURE__ */ o(h.Body, { children: a }),
695
+ g && /* @__PURE__ */ i(
696
+ h.Footer,
616
697
  {
617
698
  "data-testid": "footer",
618
699
  className: w(
@@ -620,14 +701,14 @@ const At = ({ currentPage: t, pagesCount: e, ...r }) => {
620
701
  "tw:[&]:px-3 tw:sticky tw:bottom-0"
621
702
  ),
622
703
  children: [
623
- /* @__PURE__ */ n(it, { onClick: e, children: "Cancel" }),
624
- /* @__PURE__ */ n(
625
- wt,
704
+ /* @__PURE__ */ o(Nt, { onClick: r, children: m }),
705
+ /* @__PURE__ */ o(
706
+ xt,
626
707
  {
627
708
  solid: !0,
628
- variant: r === "danger" ? "danger" : "primary",
629
- disabled: v,
630
- onClick: y,
709
+ variant: e === "danger" ? "danger" : "primary",
710
+ disabled: y,
711
+ onClick: tt,
631
712
  children: c
632
713
  }
633
714
  )
@@ -639,60 +720,62 @@ const At = ({ currentPage: t, pagesCount: e, ...r }) => {
639
720
  )
640
721
  }
641
722
  );
642
- }, qt = ({ className: t, children: e, loading: r = !1, variant: o = "default" }) => /* @__PURE__ */ n(pt, { className: f({ "tw:[&]:border-danger": o === "error" }, t), children: /* @__PURE__ */ i("h3", { className: f("tw:text-center", {
643
- "tw:text-gray-500 tw:dark:text-gray-400": o === "default",
644
- "tw:text-danger": o === "error"
723
+ }, ne = ({ className: t, children: r, loading: e = !1, variant: n = "default" }) => /* @__PURE__ */ o(Rt, { className: p({ "tw:[&]:border-danger": n === "error" }, t), children: /* @__PURE__ */ i("h3", { className: p("tw:text-center", {
724
+ "tw:text-gray-500 tw:dark:text-gray-400": n === "default",
725
+ "tw:text-danger": n === "error"
645
726
  }), children: [
646
- r && /* @__PURE__ */ i(T, { children: [
647
- /* @__PURE__ */ n(b, { icon: Z, spin: !0 }),
648
- /* @__PURE__ */ n("span", { className: "tw:ml-2", children: e ?? "Loading..." })
727
+ e && /* @__PURE__ */ i(S, { children: [
728
+ /* @__PURE__ */ o(u, { icon: st, spin: !0 }),
729
+ /* @__PURE__ */ o("span", { className: "tw:ml-2", children: r ?? "Loading..." })
649
730
  ] }),
650
- !r && e
651
- ] }) }), Gt = ({ variant: t, className: e, size: r = "md", children: o }) => /* @__PURE__ */ n(
731
+ !e && r
732
+ ] }) }), ae = ({ variant: t, className: r, size: e = "md", children: n }) => /* @__PURE__ */ o(
652
733
  "div",
653
734
  {
654
- className: f(
735
+ className: p(
655
736
  "tw:rounded-md tw:text-center",
656
737
  {
657
- "tw:p-2": r === "sm",
658
- "tw:p-4": r === "md",
659
- "tw:p-6": r === "lg",
738
+ "tw:p-2": e === "sm",
739
+ "tw:p-4": e === "md",
740
+ "tw:p-6": e === "lg",
660
741
  "tw:[&]:text-white": t !== "warning",
661
742
  "tw:bg-brand": t === "success",
662
743
  "tw:bg-danger": t === "error",
663
744
  "tw:bg-warning tw:text-black": t === "warning"
664
745
  },
665
- e
746
+ r
666
747
  ),
667
- children: o
748
+ children: n
668
749
  }
669
750
  );
670
751
  export {
671
- wt as Button,
672
- m as Card,
673
- Wt as CardModal,
674
- jt as Checkbox,
675
- j as CloseButton,
676
- C as ELLIPSIS,
677
- A as Input,
678
- W as Label,
679
- Dt as LabelledInput,
680
- Ht as LabelledSelect,
681
- it as LinkButton,
682
- qt as Message,
683
- It as ModalDialog,
684
- Ut as NavPills,
685
- At as Paginator,
686
- Gt as Result,
687
- Ot as SearchInput,
688
- st as Select,
689
- pt as SimpleCard,
690
- Rt as Table,
691
- $t as ToggleSwitch,
692
- xt as formatNumber,
693
- vt as keyForPage,
694
- k as pageIsEllipsis,
695
- Nt as prettifyPageNumber,
696
- kt as progressivePagination,
697
- zt as roundTen
752
+ xt as Button,
753
+ h as Card,
754
+ oe as CardModal,
755
+ Qt as Checkbox,
756
+ q as CloseButton,
757
+ B as ELLIPSIS,
758
+ H as Input,
759
+ D as Label,
760
+ Vt as LabelledInput,
761
+ Xt as LabelledRevealablePasswordInput,
762
+ Yt as LabelledSelect,
763
+ Nt as LinkButton,
764
+ ne as Message,
765
+ Dt as ModalDialog,
766
+ te as NavPills,
767
+ re as Paginator,
768
+ ae as Result,
769
+ yt as RevealablePasswordInput,
770
+ Zt as SearchInput,
771
+ kt as Select,
772
+ Rt as SimpleCard,
773
+ Kt as Table,
774
+ zt as ToggleSwitch,
775
+ St as formatNumber,
776
+ Mt as keyForPage,
777
+ P as pageIsEllipsis,
778
+ _t as prettifyPageNumber,
779
+ Ft as progressivePagination,
780
+ ee as roundTen
698
781
  };