@shlinkio/shlink-frontend-kit 0.9.9 → 0.9.11
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.d.ts +13 -0
- package/dist/index.js +32 -31
- package/dist/ordering-pAYMfJPl.js +108 -0
- package/dist/tailwind.d.ts +62 -2
- package/dist/tailwind.js +619 -481
- package/dist/tailwind.preset.css +26 -2
- package/package.json +9 -9
- package/dist/ordering-B_hekQuu.js +0 -96
package/dist/tailwind.js
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import w, { clsx as
|
|
3
|
-
import { useRef as
|
|
4
|
-
import { Link as
|
|
5
|
-
import { faClose as
|
|
6
|
-
import { FontAwesomeIcon as
|
|
7
|
-
import { u as
|
|
8
|
-
import { useFloating as
|
|
9
|
-
import { createPortal as
|
|
1
|
+
import { jsxs as m, jsx as n, Fragment as F } from "react/jsx-runtime";
|
|
2
|
+
import w, { clsx as y } from "clsx";
|
|
3
|
+
import { useRef as P, useState as M, useEffect as T, forwardRef as v, useCallback as I, createContext as X, useContext as E, useId as H, useImperativeHandle as ut, useMemo as K } from "react";
|
|
4
|
+
import { Link as J, NavLink as bt } from "react-router";
|
|
5
|
+
import { faClose as gt, faEyeSlash as ht, faEye as ft, faCircleNotch as at, faSearch as xt, faCaretDown as yt, faChevronLeft as tt, faChevronRight as et, faEllipsisV as kt, faSortAmountUp as vt, faSortAmountDown as Nt, faCheck as Ct } from "@fortawesome/free-solid-svg-icons";
|
|
6
|
+
import { FontAwesomeIcon as C } from "@fortawesome/react-fontawesome";
|
|
7
|
+
import { u as It, b as Rt, i as Pt, a as Ot, e as Lt, c as St } from "./ordering-pAYMfJPl.js";
|
|
8
|
+
import { useFloating as lt, flip as Dt, offset as Et, useClick as Mt, useInteractions as dt, autoPlacement as Bt, arrow as At, useHover as Tt, useTransitionStyles as _t } from "@floating-ui/react";
|
|
9
|
+
import { createPortal as $t } from "react-dom";
|
|
10
10
|
import "reactstrap";
|
|
11
|
-
import { faClone as
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
return
|
|
15
|
-
const i =
|
|
11
|
+
import { faClone as jt } from "@fortawesome/free-regular-svg-icons";
|
|
12
|
+
const _e = ({ children: r, summary: e, summaryClasses: t, ...o }) => {
|
|
13
|
+
const l = P(null), [a, d] = M(!1);
|
|
14
|
+
return T(() => {
|
|
15
|
+
const i = l.current, s = () => d(!!(i != null && i.open));
|
|
16
16
|
return i == null || i.addEventListener("toggle", s), () => i == null ? void 0 : i.removeEventListener("toggle", s);
|
|
17
|
-
}, []), /* @__PURE__ */
|
|
18
|
-
/* @__PURE__ */ n("summary", { className:
|
|
19
|
-
|
|
17
|
+
}, []), /* @__PURE__ */ m("details", { ref: l, ...o, children: [
|
|
18
|
+
/* @__PURE__ */ n("summary", { className: y("tw:focus-ring tw:px-1 tw:-mx-1 tw:rounded-sm", t), children: e }),
|
|
19
|
+
a && /* @__PURE__ */ n("div", { className: "tw:mt-3 tw:flex tw:flex-col tw:gap-y-3", children: r })
|
|
20
20
|
] });
|
|
21
|
-
},
|
|
21
|
+
}, Ft = v(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
22
22
|
"div",
|
|
23
23
|
{
|
|
24
24
|
className: w(
|
|
@@ -29,7 +29,7 @@ const Oe = ({ children: r, summary: e, summaryClasses: t, ...o }) => {
|
|
|
29
29
|
...e,
|
|
30
30
|
ref: t
|
|
31
31
|
}
|
|
32
|
-
)),
|
|
32
|
+
)), Ht = v(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
33
33
|
"div",
|
|
34
34
|
{
|
|
35
35
|
className: w(
|
|
@@ -40,7 +40,7 @@ const Oe = ({ children: r, summary: e, summaryClasses: t, ...o }) => {
|
|
|
40
40
|
...e,
|
|
41
41
|
ref: t
|
|
42
42
|
}
|
|
43
|
-
)),
|
|
43
|
+
)), Wt = v(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
44
44
|
"div",
|
|
45
45
|
{
|
|
46
46
|
className: w(
|
|
@@ -51,7 +51,7 @@ const Oe = ({ children: r, summary: e, summaryClasses: t, ...o }) => {
|
|
|
51
51
|
...e,
|
|
52
52
|
ref: t
|
|
53
53
|
}
|
|
54
|
-
)),
|
|
54
|
+
)), Ut = v(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
55
55
|
"div",
|
|
56
56
|
{
|
|
57
57
|
className: w(
|
|
@@ -62,83 +62,83 @@ const Oe = ({ children: r, summary: e, summaryClasses: t, ...o }) => {
|
|
|
62
62
|
...e,
|
|
63
63
|
ref: t
|
|
64
64
|
}
|
|
65
|
-
)),
|
|
66
|
-
const { title:
|
|
65
|
+
)), L = Object.assign(Ut, { Body: Ht, Header: Ft, Footer: Wt }), Kt = v(({ bodyClassName: r, children: e, ...t }, o) => {
|
|
66
|
+
const { title: l, titleSize: a = "md", ...d } = "title" in t ? t : {
|
|
67
67
|
...t,
|
|
68
68
|
title: void 0,
|
|
69
69
|
titleSize: void 0
|
|
70
70
|
};
|
|
71
|
-
return /* @__PURE__ */
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
71
|
+
return /* @__PURE__ */ m(L, { ...d, ref: o, children: [
|
|
72
|
+
l && /* @__PURE__ */ m(L.Header, { children: [
|
|
73
|
+
a === "lg" && /* @__PURE__ */ n("h4", { children: l }),
|
|
74
|
+
a === "md" && /* @__PURE__ */ n("h5", { children: l }),
|
|
75
|
+
a === "sm" && /* @__PURE__ */ n("h6", { children: l })
|
|
76
76
|
] }),
|
|
77
|
-
/* @__PURE__ */ n(
|
|
77
|
+
/* @__PURE__ */ n(L.Body, { className: r, children: e })
|
|
78
78
|
] });
|
|
79
79
|
});
|
|
80
|
-
function
|
|
80
|
+
function Gt({
|
|
81
81
|
id: r,
|
|
82
82
|
items: e,
|
|
83
83
|
onSelectItem: t,
|
|
84
84
|
onActiveItemChange: o,
|
|
85
|
-
renderItem:
|
|
86
|
-
className:
|
|
85
|
+
renderItem: l,
|
|
86
|
+
className: a,
|
|
87
87
|
noItemsMessage: d = "No items",
|
|
88
88
|
anchor: i,
|
|
89
89
|
"aria-label": s = "Items",
|
|
90
90
|
...c
|
|
91
91
|
}) {
|
|
92
|
-
const [
|
|
93
|
-
if (
|
|
94
|
-
const [
|
|
95
|
-
o(
|
|
92
|
+
const [f, u] = M(0), p = I((k) => {
|
|
93
|
+
if (u(k), o) {
|
|
94
|
+
const [x, b] = [...e.entries()][k];
|
|
95
|
+
o(x, b);
|
|
96
96
|
}
|
|
97
97
|
}, [e, o]);
|
|
98
|
-
return
|
|
99
|
-
const
|
|
100
|
-
if (!
|
|
98
|
+
return T(() => {
|
|
99
|
+
const k = i == null ? void 0 : i.current;
|
|
100
|
+
if (!k)
|
|
101
101
|
return;
|
|
102
|
-
const
|
|
103
|
-
["Enter", "ArrowUp", "ArrowDown"].includes(
|
|
102
|
+
const x = (b) => {
|
|
103
|
+
["Enter", "ArrowUp", "ArrowDown"].includes(b.key) && b.preventDefault(), b.key === "ArrowDown" ? p(Math.min(f + 1, e.size - 1)) : b.key === "ArrowUp" ? p(Math.max(f - 1, 0)) : b.key === "Enter" && t([...e.values()][f]);
|
|
104
104
|
};
|
|
105
|
-
return
|
|
106
|
-
}, [
|
|
107
|
-
|
|
105
|
+
return k.addEventListener("keydown", x), () => k.removeEventListener("keydown", x);
|
|
106
|
+
}, [f, i, p, e, t]), /* @__PURE__ */ m(
|
|
107
|
+
L,
|
|
108
108
|
{
|
|
109
109
|
id: r,
|
|
110
|
-
className: w("tw:py-1 tw:flex tw:flex-col",
|
|
110
|
+
className: w("tw:py-1 tw:flex tw:flex-col", a),
|
|
111
111
|
role: "listbox",
|
|
112
112
|
"aria-orientation": "vertical",
|
|
113
113
|
"aria-label": s,
|
|
114
114
|
...c,
|
|
115
115
|
children: [
|
|
116
116
|
e.size === 0 && /* @__PURE__ */ n("i", { role: "option", "aria-disabled": !0, "aria-selected": !1, "data-testid": "no-items", className: "tw:px-2 tw:py-1", children: d }),
|
|
117
|
-
[...e.entries()].map(([
|
|
117
|
+
[...e.entries()].map(([k, x], b) => /* @__PURE__ */ n(
|
|
118
118
|
"button",
|
|
119
119
|
{
|
|
120
|
-
id: `${r}_${
|
|
120
|
+
id: `${r}_${k}`,
|
|
121
121
|
type: "button",
|
|
122
122
|
role: "option",
|
|
123
|
-
"aria-selected":
|
|
123
|
+
"aria-selected": b === f,
|
|
124
124
|
className: w(
|
|
125
125
|
"tw:px-2 tw:py-1 tw:text-left tw:truncate",
|
|
126
|
-
{ "tw:bg-lm-secondary tw:dark:bg-dm-secondary":
|
|
126
|
+
{ "tw:bg-lm-secondary tw:dark:bg-dm-secondary": b === f }
|
|
127
127
|
),
|
|
128
128
|
tabIndex: -1,
|
|
129
|
-
onClick: () => t(
|
|
130
|
-
onMouseOver: () =>
|
|
131
|
-
children:
|
|
129
|
+
onClick: () => t(x),
|
|
130
|
+
onMouseOver: () => p(b),
|
|
131
|
+
children: l(x)
|
|
132
132
|
},
|
|
133
|
-
|
|
133
|
+
k
|
|
134
134
|
))
|
|
135
135
|
]
|
|
136
136
|
}
|
|
137
137
|
);
|
|
138
138
|
}
|
|
139
|
-
const
|
|
140
|
-
const { responsive: t } =
|
|
141
|
-
return /* @__PURE__ */ n(
|
|
139
|
+
const W = X(void 0), _ = X({ responsive: !0, size: "md" }), qt = ({ children: r, className: e }) => {
|
|
140
|
+
const { responsive: t } = E(_);
|
|
141
|
+
return /* @__PURE__ */ n(W.Provider, { value: { section: "head" }, children: /* @__PURE__ */ n(
|
|
142
142
|
"thead",
|
|
143
143
|
{
|
|
144
144
|
className: w(
|
|
@@ -148,9 +148,9 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
148
148
|
children: r
|
|
149
149
|
}
|
|
150
150
|
) });
|
|
151
|
-
},
|
|
152
|
-
const { responsive: t } =
|
|
153
|
-
return /* @__PURE__ */ n(
|
|
151
|
+
}, Xt = ({ children: r, className: e }) => {
|
|
152
|
+
const { responsive: t } = E(_);
|
|
153
|
+
return /* @__PURE__ */ n(W.Provider, { value: { section: "body" }, children: /* @__PURE__ */ n(
|
|
154
154
|
"tbody",
|
|
155
155
|
{
|
|
156
156
|
className: w(
|
|
@@ -160,9 +160,9 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
160
160
|
children: r
|
|
161
161
|
}
|
|
162
162
|
) });
|
|
163
|
-
},
|
|
164
|
-
const { responsive: t } =
|
|
165
|
-
return /* @__PURE__ */ n(
|
|
163
|
+
}, Jt = ({ children: r, className: e }) => {
|
|
164
|
+
const { responsive: t } = E(_);
|
|
165
|
+
return /* @__PURE__ */ n(W.Provider, { value: { section: "footer" }, children: /* @__PURE__ */ n(
|
|
166
166
|
"tfoot",
|
|
167
167
|
{
|
|
168
168
|
className: w(
|
|
@@ -172,19 +172,19 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
172
172
|
children: r
|
|
173
173
|
}
|
|
174
174
|
) });
|
|
175
|
-
},
|
|
176
|
-
const o =
|
|
175
|
+
}, Qt = ({ children: r, className: e, ...t }) => {
|
|
176
|
+
const o = E(W), l = (o == null ? void 0 : o.section) === "body", { responsive: a } = E(_);
|
|
177
177
|
return /* @__PURE__ */ n(
|
|
178
178
|
"tr",
|
|
179
179
|
{
|
|
180
180
|
className: w(
|
|
181
181
|
"tw:group",
|
|
182
182
|
{
|
|
183
|
-
"tw:lg:table-row tw:flex tw:flex-col":
|
|
184
|
-
"tw:lg:border-0 tw:border-y-2 tw:border-lm-border tw:dark:border-dm-border":
|
|
185
|
-
"tw:hover:bg-lm-primary tw:dark:hover:bg-dm-primary":
|
|
183
|
+
"tw:lg:table-row tw:flex tw:flex-col": a,
|
|
184
|
+
"tw:lg:border-0 tw:border-y-2 tw:border-lm-border tw:dark:border-dm-border": a,
|
|
185
|
+
"tw:hover:bg-lm-primary tw:dark:hover:bg-dm-primary": l,
|
|
186
186
|
// Use a different hover bg color depending on the table being inside a card or not
|
|
187
|
-
"tw:group-[&]/card:hover:bg-lm-secondary tw:dark:group-[&]/card:hover:bg-dm-secondary":
|
|
187
|
+
"tw:group-[&]/card:hover:bg-lm-secondary tw:dark:group-[&]/card:hover:bg-dm-secondary": l
|
|
188
188
|
},
|
|
189
189
|
e
|
|
190
190
|
),
|
|
@@ -192,8 +192,8 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
192
192
|
children: r
|
|
193
193
|
}
|
|
194
194
|
);
|
|
195
|
-
},
|
|
196
|
-
const
|
|
195
|
+
}, Yt = ({ children: r, className: e, columnName: t, type: o, ...l }) => {
|
|
196
|
+
const a = E(W), d = o ?? ((a == null ? void 0 : a.section) !== "body" ? "th" : "td"), { responsive: i, size: s } = E(_);
|
|
197
197
|
return /* @__PURE__ */ n(
|
|
198
198
|
d,
|
|
199
199
|
{
|
|
@@ -206,38 +206,39 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
206
206
|
"tw:p-3": s === "lg",
|
|
207
207
|
"tw:border-b-1": !i,
|
|
208
208
|
"tw:block tw:lg:table-cell tw:not-last:border-b-1 tw:lg:border-b-1": i,
|
|
209
|
+
"tw:text-left": d === "th",
|
|
209
210
|
// For responsive tables, display the content in data-column attribute for md sizes and lower
|
|
210
211
|
"tw:before:lg:hidden tw:before:content-[attr(data-column)] tw:before:font-bold tw:before:mr-1": i && d === "td"
|
|
211
212
|
},
|
|
212
213
|
e
|
|
213
214
|
),
|
|
214
|
-
...
|
|
215
|
+
...l,
|
|
215
216
|
children: r
|
|
216
217
|
}
|
|
217
218
|
);
|
|
218
|
-
},
|
|
219
|
-
/* @__PURE__ */ n(
|
|
220
|
-
/* @__PURE__ */ n(
|
|
221
|
-
e && /* @__PURE__ */ n(
|
|
222
|
-
] }) }),
|
|
219
|
+
}, Zt = ({ header: r, footer: e, children: t, responsive: o = !0, size: l = "md", ...a }) => /* @__PURE__ */ n(_.Provider, { value: { responsive: o, size: l }, children: /* @__PURE__ */ m("table", { className: "tw:w-full", ...a, children: [
|
|
220
|
+
/* @__PURE__ */ n(qt, { children: r }),
|
|
221
|
+
/* @__PURE__ */ n(Xt, { children: t }),
|
|
222
|
+
e && /* @__PURE__ */ n(Jt, { children: e })
|
|
223
|
+
] }) }), $e = Object.assign(Zt, { Row: Qt, Cell: Yt }), zt = v(({
|
|
223
224
|
className: r,
|
|
224
225
|
disabled: e,
|
|
225
226
|
variant: t = "primary",
|
|
226
227
|
size: o = "md",
|
|
227
|
-
inline:
|
|
228
|
-
solid:
|
|
228
|
+
inline: l = !1,
|
|
229
|
+
solid: a = !1,
|
|
229
230
|
type: d = "button",
|
|
230
231
|
...i
|
|
231
232
|
}, s) => {
|
|
232
|
-
const c = "to" in i,
|
|
233
|
+
const c = "to" in i && typeof i.to == "string", f = c ? J : "button", u = c ? void 0 : d;
|
|
233
234
|
return /* @__PURE__ */ n(
|
|
234
|
-
|
|
235
|
+
f,
|
|
235
236
|
{
|
|
236
237
|
ref: s,
|
|
237
238
|
className: w(
|
|
238
239
|
{
|
|
239
|
-
"tw:inline-flex":
|
|
240
|
-
"tw:flex": !
|
|
240
|
+
"tw:inline-flex": l,
|
|
241
|
+
"tw:flex": !l
|
|
241
242
|
},
|
|
242
243
|
"tw:gap-2 tw:items-center tw:justify-center",
|
|
243
244
|
"tw:border tw:rounded-md tw:no-underline",
|
|
@@ -254,13 +255,13 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
254
255
|
},
|
|
255
256
|
{
|
|
256
257
|
"tw:border-lm-brand tw:dark:border-dm-brand": t === "primary",
|
|
257
|
-
"tw:text-lm-brand tw:dark:text-dm-brand": t === "primary" && !
|
|
258
|
+
"tw:text-lm-brand tw:dark:text-dm-brand": t === "primary" && !a,
|
|
258
259
|
"tw:border-zinc-500": t === "secondary",
|
|
259
|
-
"tw:text-zinc-500": t === "secondary" && !
|
|
260
|
+
"tw:text-zinc-500": t === "secondary" && !a,
|
|
260
261
|
"tw:border-danger": t === "danger",
|
|
261
|
-
"tw:text-danger": t === "danger" && !
|
|
262
|
+
"tw:text-danger": t === "danger" && !a
|
|
262
263
|
},
|
|
263
|
-
|
|
264
|
+
a && {
|
|
264
265
|
"tw:text-white": !0,
|
|
265
266
|
"tw:bg-lm-brand tw:dark:bg-dm-brand": t === "primary",
|
|
266
267
|
"tw:highlight:bg-lm-brand-dark tw:dark:highlight:bg-dm-brand-dark": t === "primary",
|
|
@@ -271,30 +272,31 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
271
272
|
"tw:highlight:bg-danger-dark tw:highlight:border-danger-dark": t === "danger"
|
|
272
273
|
},
|
|
273
274
|
!e && {
|
|
274
|
-
"tw:highlight:text-white": !
|
|
275
|
+
"tw:highlight:text-white": !a,
|
|
275
276
|
"tw:highlight:bg-lm-brand tw:dark:highlight:bg-dm-brand": t === "primary",
|
|
276
277
|
"tw:highlight:bg-zinc-500": t === "secondary",
|
|
277
278
|
"tw:highlight:bg-danger": t === "danger"
|
|
278
279
|
},
|
|
279
280
|
{
|
|
281
|
+
"tw:cursor-pointer": !e,
|
|
280
282
|
"tw:pointer-events-none tw:opacity-65": e
|
|
281
283
|
},
|
|
282
284
|
r
|
|
283
285
|
),
|
|
284
286
|
disabled: c ? void 0 : e,
|
|
285
287
|
"aria-disabled": c ? e : void 0,
|
|
286
|
-
type:
|
|
288
|
+
type: u,
|
|
287
289
|
...i
|
|
288
290
|
}
|
|
289
291
|
);
|
|
290
|
-
}),
|
|
291
|
-
const
|
|
292
|
+
}), it = v(({ className: r, onChange: e, ...t }, o) => {
|
|
293
|
+
const l = I((a) => e == null ? void 0 : e(a.target.checked, a), [e]);
|
|
292
294
|
return /* @__PURE__ */ n(
|
|
293
295
|
"input",
|
|
294
296
|
{
|
|
295
297
|
ref: o,
|
|
296
298
|
type: "checkbox",
|
|
297
|
-
className:
|
|
299
|
+
className: y(
|
|
298
300
|
"tw:appearance-none tw:focus-ring tw:cursor-[inherit]",
|
|
299
301
|
"tw:border-1 tw:border-lm-input-border tw:dark:border-dm-input-border",
|
|
300
302
|
"tw:bg-lm-primary tw:dark:bg-dm-primary tw:checked:bg-lm-brand tw:dark:checked:bg-dm-brand tw:bg-no-repeat",
|
|
@@ -302,71 +304,73 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
302
304
|
"tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input",
|
|
303
305
|
r
|
|
304
306
|
),
|
|
305
|
-
onChange:
|
|
307
|
+
onChange: l,
|
|
306
308
|
...t
|
|
307
309
|
}
|
|
308
310
|
);
|
|
309
|
-
}),
|
|
310
|
-
|
|
311
|
+
}), je = v(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
312
|
+
it,
|
|
311
313
|
{
|
|
312
314
|
ref: t,
|
|
313
|
-
className:
|
|
315
|
+
className: y("tw:rounded-sm tw:w-4 tw:h-4 tw:checked:bg-(image:--tick) tw:bg-center", r),
|
|
314
316
|
...e
|
|
315
317
|
}
|
|
316
|
-
)),
|
|
318
|
+
)), G = v(({ onClick: r, className: e, label: t = "Close", size: o = "lg", solid: l }, a) => /* @__PURE__ */ n(
|
|
317
319
|
"button",
|
|
318
320
|
{
|
|
319
|
-
ref:
|
|
321
|
+
ref: a,
|
|
320
322
|
type: "button",
|
|
321
323
|
onClick: r,
|
|
322
324
|
className: w(
|
|
323
|
-
"tw:
|
|
324
|
-
|
|
325
|
+
"tw:rounded-md tw:focus-ring tw:cursor-pointer",
|
|
326
|
+
{
|
|
327
|
+
"tw:opacity-50 tw:highlight:opacity-80 tw:transition-opacity": !l
|
|
328
|
+
},
|
|
325
329
|
e
|
|
326
330
|
),
|
|
327
331
|
"aria-label": t,
|
|
328
|
-
children: /* @__PURE__ */ n(
|
|
332
|
+
children: /* @__PURE__ */ n(C, { icon: gt, size: o === "lg" ? "xl" : o === "md" ? "lg" : void 0 })
|
|
329
333
|
}
|
|
330
|
-
)),
|
|
334
|
+
)), Q = v(({
|
|
331
335
|
borderless: r = !1,
|
|
332
336
|
size: e = "md",
|
|
333
337
|
feedback: t,
|
|
334
|
-
|
|
338
|
+
variant: o = "default",
|
|
339
|
+
className: l,
|
|
335
340
|
disabled: a,
|
|
336
|
-
...
|
|
337
|
-
},
|
|
341
|
+
...d
|
|
342
|
+
}, i) => /* @__PURE__ */ n(
|
|
338
343
|
"input",
|
|
339
344
|
{
|
|
340
|
-
ref:
|
|
345
|
+
ref: i,
|
|
341
346
|
className: w(
|
|
342
|
-
"tw:
|
|
343
|
-
|
|
344
|
-
"tw:
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
o
|
|
347
|
+
"tw:outline-none",
|
|
348
|
+
o === "default" && [
|
|
349
|
+
"tw:w-full",
|
|
350
|
+
{
|
|
351
|
+
"tw:focus-ring": !t,
|
|
352
|
+
"tw:focus-ring-danger": t === "error",
|
|
353
|
+
"tw:px-2 tw:py-1 tw:text-sm": e === "sm",
|
|
354
|
+
"tw:px-3 tw:py-1.5": e === "md",
|
|
355
|
+
"tw:px-4 tw:py-2 tw:text-xl": e === "lg",
|
|
356
|
+
"tw:rounded-md tw:border": !r,
|
|
357
|
+
"tw:border-lm-input-border tw:dark:border-dm-input-border": !r && !t,
|
|
358
|
+
"tw:border-danger": !r && t === "error",
|
|
359
|
+
"tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input": a,
|
|
360
|
+
"tw:bg-lm-primary tw:dark:bg-dm-primary": !a,
|
|
361
|
+
// Use different background color when rendered inside a card
|
|
362
|
+
"tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input": !a
|
|
363
|
+
}
|
|
364
|
+
],
|
|
365
|
+
l
|
|
362
366
|
),
|
|
363
367
|
disabled: a,
|
|
364
|
-
...
|
|
368
|
+
...d
|
|
365
369
|
}
|
|
366
|
-
)),
|
|
370
|
+
)), Y = ({ required: r, children: e, className: t, ...o }) => /* @__PURE__ */ m("label", { className: y("tw:cursor-pointer", t), ...o, children: [
|
|
367
371
|
e,
|
|
368
372
|
r && /* @__PURE__ */ n("span", { className: "tw:text-danger tw:ml-1", "data-testid": "required-indicator", children: "*" })
|
|
369
|
-
] }),
|
|
373
|
+
] }), Z = ({ children: r, helpText: e, error: t, "data-testid": o }) => /* @__PURE__ */ m("div", { className: "tw:flex tw:flex-col tw:gap-1", "data-testid": o, children: [
|
|
370
374
|
r,
|
|
371
375
|
e && /* @__PURE__ */ n(
|
|
372
376
|
"small",
|
|
@@ -377,40 +381,40 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
377
381
|
}
|
|
378
382
|
),
|
|
379
383
|
t && /* @__PURE__ */ n("span", { "data-testid": o ? `${o}-error` : "error", className: "tw:text-danger", children: t })
|
|
380
|
-
] }),
|
|
381
|
-
const c =
|
|
382
|
-
return /* @__PURE__ */
|
|
383
|
-
/* @__PURE__ */ n(
|
|
384
|
+
] }), Fe = v(({ label: r, inputClassName: e, required: t, hiddenRequired: o, error: l, helpText: a, "data-testid": d, ...i }, s) => {
|
|
385
|
+
const c = H();
|
|
386
|
+
return /* @__PURE__ */ m(Z, { error: l, helpText: a, "data-testid": d, children: [
|
|
387
|
+
/* @__PURE__ */ n(Y, { htmlFor: c, required: t, children: r }),
|
|
384
388
|
/* @__PURE__ */ n(
|
|
385
|
-
|
|
389
|
+
Q,
|
|
386
390
|
{
|
|
387
391
|
ref: s,
|
|
388
392
|
id: c,
|
|
389
393
|
className: e,
|
|
390
394
|
required: t || o,
|
|
391
|
-
feedback:
|
|
395
|
+
feedback: l ? "error" : void 0,
|
|
392
396
|
...i
|
|
393
397
|
}
|
|
394
398
|
)
|
|
395
399
|
] });
|
|
396
|
-
}),
|
|
397
|
-
const [
|
|
398
|
-
var
|
|
399
|
-
(
|
|
400
|
+
}), Vt = v(({ containerClassName: r, className: e, size: t, ...o }, l) => {
|
|
401
|
+
const [a, d, , i] = It(!1), s = P(null), c = I(({ relatedTarget: f }) => {
|
|
402
|
+
var u;
|
|
403
|
+
(u = s.current) != null && u.contains(f) || i();
|
|
400
404
|
}, [s, i]);
|
|
401
|
-
return /* @__PURE__ */
|
|
405
|
+
return /* @__PURE__ */ m(
|
|
402
406
|
"div",
|
|
403
407
|
{
|
|
404
|
-
className:
|
|
408
|
+
className: y("tw:group tw:relative", r),
|
|
405
409
|
ref: s,
|
|
406
410
|
onBlurCapture: c,
|
|
407
411
|
children: [
|
|
408
412
|
/* @__PURE__ */ n(
|
|
409
|
-
|
|
413
|
+
Q,
|
|
410
414
|
{
|
|
411
|
-
ref:
|
|
412
|
-
type:
|
|
413
|
-
className:
|
|
415
|
+
ref: l,
|
|
416
|
+
type: a ? "text" : "password",
|
|
417
|
+
className: y(
|
|
414
418
|
{
|
|
415
419
|
"tw:pr-10": t !== "sm",
|
|
416
420
|
"tw:pr-8": t === "sm"
|
|
@@ -427,10 +431,10 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
427
431
|
{
|
|
428
432
|
type: "button",
|
|
429
433
|
onClick: d,
|
|
430
|
-
title:
|
|
431
|
-
"aria-label":
|
|
432
|
-
className:
|
|
433
|
-
"tw:absolute tw:top-[50%] tw:translate-y-[-50%] tw:px-1",
|
|
434
|
+
title: a ? "Hide password" : "Show password",
|
|
435
|
+
"aria-label": a ? "Hide password" : "Show password",
|
|
436
|
+
className: y(
|
|
437
|
+
"tw:absolute tw:top-[50%] tw:translate-y-[-50%] tw:px-1 tw:cursor-pointer",
|
|
434
438
|
"tw:text-placeholder tw:hover:text-lm-text tw:hover:dark:text-dm-text tw:transition-colors",
|
|
435
439
|
{
|
|
436
440
|
"tw:right-1.5": t !== "sm",
|
|
@@ -438,35 +442,35 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
438
442
|
}
|
|
439
443
|
),
|
|
440
444
|
tabIndex: -1,
|
|
441
|
-
children: /* @__PURE__ */ n(
|
|
445
|
+
children: /* @__PURE__ */ n(C, { fixedWidth: !0, icon: a ? ht : ft })
|
|
442
446
|
}
|
|
443
447
|
)
|
|
444
448
|
]
|
|
445
449
|
}
|
|
446
450
|
);
|
|
447
|
-
}),
|
|
448
|
-
const c =
|
|
449
|
-
return /* @__PURE__ */
|
|
450
|
-
/* @__PURE__ */ n(
|
|
451
|
+
}), He = v(({ label: r, inputClassName: e, required: t, hiddenRequired: o, error: l, helpText: a, "data-testid": d, ...i }, s) => {
|
|
452
|
+
const c = H();
|
|
453
|
+
return /* @__PURE__ */ m(Z, { error: l, helpText: a, "data-testid": d, children: [
|
|
454
|
+
/* @__PURE__ */ n(Y, { htmlFor: c, required: t, children: r }),
|
|
451
455
|
/* @__PURE__ */ n(
|
|
452
|
-
|
|
456
|
+
Vt,
|
|
453
457
|
{
|
|
454
458
|
ref: s,
|
|
455
459
|
id: c,
|
|
456
460
|
className: e,
|
|
457
461
|
required: t || o,
|
|
458
|
-
feedback:
|
|
462
|
+
feedback: l ? "error" : void 0,
|
|
459
463
|
...i
|
|
460
464
|
}
|
|
461
465
|
)
|
|
462
466
|
] });
|
|
463
|
-
}),
|
|
467
|
+
}), te = v(({
|
|
464
468
|
className: r,
|
|
465
469
|
size: e = "md",
|
|
466
470
|
feedback: t,
|
|
467
471
|
style: o = {},
|
|
468
|
-
disabled:
|
|
469
|
-
...
|
|
472
|
+
disabled: l,
|
|
473
|
+
...a
|
|
470
474
|
}, d) => /* @__PURE__ */ n(
|
|
471
475
|
"select",
|
|
472
476
|
{
|
|
@@ -487,9 +491,9 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
487
491
|
"tw:pl-2 tw:py-1 tw:text-sm": e === "sm",
|
|
488
492
|
"tw:pl-3 tw:py-1.5": e === "md",
|
|
489
493
|
"tw:pl-4 tw:py-2 tw:text-xl": e === "lg",
|
|
490
|
-
"tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input":
|
|
494
|
+
"tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input": l,
|
|
491
495
|
// Apply different background color when rendered inside a card
|
|
492
|
-
"tw:bg-lm-primary tw:dark:bg-dm-primary tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input": !
|
|
496
|
+
"tw:bg-lm-primary tw:dark:bg-dm-primary tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input": !l
|
|
493
497
|
},
|
|
494
498
|
r
|
|
495
499
|
),
|
|
@@ -497,43 +501,45 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
497
501
|
...o,
|
|
498
502
|
background: "right 0.75rem center / 16px 12px"
|
|
499
503
|
},
|
|
500
|
-
disabled:
|
|
501
|
-
...
|
|
504
|
+
disabled: l,
|
|
505
|
+
...a
|
|
502
506
|
}
|
|
503
|
-
)),
|
|
504
|
-
const c =
|
|
505
|
-
return /* @__PURE__ */
|
|
506
|
-
/* @__PURE__ */ n(
|
|
507
|
+
)), We = v(({ selectClassName: r, label: e, error: t, helpText: o, required: l, hiddenRequired: a, "data-testid": d, ...i }, s) => {
|
|
508
|
+
const c = H();
|
|
509
|
+
return /* @__PURE__ */ m(Z, { error: t, helpText: o, "data-testid": d, children: [
|
|
510
|
+
/* @__PURE__ */ n(Y, { htmlFor: c, required: l, children: e }),
|
|
507
511
|
/* @__PURE__ */ n(
|
|
508
|
-
|
|
512
|
+
te,
|
|
509
513
|
{
|
|
510
514
|
ref: s,
|
|
511
515
|
id: c,
|
|
512
516
|
className: r,
|
|
513
|
-
required:
|
|
517
|
+
required: l || a,
|
|
514
518
|
feedback: t ? "error" : void 0,
|
|
515
519
|
...i
|
|
516
520
|
}
|
|
517
521
|
)
|
|
518
522
|
] });
|
|
519
|
-
}),
|
|
523
|
+
}), ee = v(({
|
|
520
524
|
onChange: r,
|
|
521
525
|
containerClassName: e,
|
|
522
526
|
inputClassName: t,
|
|
523
527
|
// Inputs have a default 'md' size. Search inputs are usually 'lg' as they are rendered at the top of sections
|
|
524
528
|
size: o = "lg",
|
|
525
|
-
loading:
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
529
|
+
loading: l = !1,
|
|
530
|
+
variant: a = "default",
|
|
531
|
+
immediate: d = !1,
|
|
532
|
+
...i
|
|
533
|
+
}, s) => {
|
|
534
|
+
const { setTimeout: c, clearCurrentTimeout: f } = Rt(500), u = I((p) => {
|
|
535
|
+
!p || d ? (f(), r(p)) : c(() => r(p));
|
|
536
|
+
}, [f, d, r, c]);
|
|
537
|
+
return /* @__PURE__ */ m("div", { className: w("tw:group tw:relative tw:focus-within:z-10", e), children: [
|
|
538
|
+
a === "default" && /* @__PURE__ */ n(
|
|
539
|
+
C,
|
|
534
540
|
{
|
|
535
|
-
icon:
|
|
536
|
-
spin:
|
|
541
|
+
icon: l ? at : xt,
|
|
542
|
+
spin: l,
|
|
537
543
|
className: w(
|
|
538
544
|
"tw:absolute tw:top-[50%] tw:translate-y-[-50%] tw:transition-colors",
|
|
539
545
|
"tw:text-placeholder tw:group-focus-within:text-lm-text tw:dark:group-focus-within:text-dm-text",
|
|
@@ -545,84 +551,90 @@ const H = q(void 0), F = q({ responsive: !0, size: "md" }), Ut = ({ children: r,
|
|
|
545
551
|
}
|
|
546
552
|
),
|
|
547
553
|
/* @__PURE__ */ n(
|
|
548
|
-
|
|
554
|
+
Q,
|
|
549
555
|
{
|
|
550
|
-
ref:
|
|
556
|
+
ref: s,
|
|
557
|
+
variant: a,
|
|
551
558
|
type: "search",
|
|
552
559
|
className: w(
|
|
553
|
-
{
|
|
560
|
+
a === "default" && {
|
|
554
561
|
"tw:pl-9": o !== "sm",
|
|
555
562
|
"tw:pl-7": o === "sm"
|
|
556
563
|
},
|
|
557
564
|
t
|
|
558
565
|
),
|
|
559
566
|
placeholder: "Search...",
|
|
560
|
-
onChange: (
|
|
567
|
+
onChange: (p) => u(p.target.value),
|
|
561
568
|
size: o,
|
|
562
|
-
...
|
|
569
|
+
...i
|
|
563
570
|
}
|
|
564
571
|
)
|
|
565
572
|
] });
|
|
566
573
|
});
|
|
567
|
-
function
|
|
574
|
+
function re({
|
|
568
575
|
searchResults: r,
|
|
569
576
|
onSearch: e,
|
|
570
577
|
onSelectSearchResult: t,
|
|
571
578
|
renderSearchResult: o,
|
|
572
|
-
size:
|
|
579
|
+
size: l = "md",
|
|
573
580
|
// SearchInput defaults its size to 'lg'. Change it to 'md'
|
|
574
|
-
listboxSpan:
|
|
581
|
+
listboxSpan: a = "full",
|
|
575
582
|
onFocus: d,
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
583
|
+
containerClassName: i,
|
|
584
|
+
listboxClassName: s,
|
|
585
|
+
...c
|
|
586
|
+
}, f) {
|
|
587
|
+
const u = H(), [p, k] = M(), x = P(null);
|
|
588
|
+
ut(f, () => x.current);
|
|
589
|
+
const b = K(
|
|
590
|
+
() => r ? p ?? [...r.keys()][0] : void 0,
|
|
591
|
+
[p, r]
|
|
592
|
+
), h = I((g) => {
|
|
593
|
+
t(g), e(""), x.current.value = "";
|
|
594
|
+
}, [e, t, x]);
|
|
595
|
+
return /* @__PURE__ */ m(
|
|
585
596
|
"div",
|
|
586
597
|
{
|
|
587
|
-
className: "tw:relative",
|
|
588
|
-
onBlur: (
|
|
589
|
-
|
|
598
|
+
className: w("tw:relative", i),
|
|
599
|
+
onBlur: (g) => {
|
|
600
|
+
g.currentTarget.contains(g.relatedTarget) || e("");
|
|
590
601
|
},
|
|
591
602
|
children: [
|
|
592
603
|
/* @__PURE__ */ n(
|
|
593
|
-
|
|
604
|
+
ee,
|
|
594
605
|
{
|
|
595
606
|
onChange: e,
|
|
596
|
-
size:
|
|
597
|
-
ref:
|
|
607
|
+
size: l,
|
|
608
|
+
ref: x,
|
|
598
609
|
role: "combobox",
|
|
599
610
|
"aria-autocomplete": "list",
|
|
600
611
|
"aria-expanded": !!r,
|
|
601
|
-
"aria-controls":
|
|
602
|
-
"aria-activedescendant":
|
|
612
|
+
"aria-controls": u,
|
|
613
|
+
"aria-activedescendant": b ? `${u}_${b}` : void 0,
|
|
603
614
|
autoComplete: "off",
|
|
604
615
|
autoCorrect: "off",
|
|
605
|
-
onFocus: (
|
|
606
|
-
d == null || d(
|
|
616
|
+
onFocus: (g) => {
|
|
617
|
+
d == null || d(g), e(g.target.value);
|
|
607
618
|
},
|
|
608
|
-
...
|
|
619
|
+
...c
|
|
609
620
|
}
|
|
610
621
|
),
|
|
611
622
|
r && /* @__PURE__ */ n(
|
|
612
|
-
|
|
623
|
+
Gt,
|
|
613
624
|
{
|
|
614
|
-
id:
|
|
625
|
+
id: u,
|
|
615
626
|
items: r,
|
|
616
|
-
anchor:
|
|
617
|
-
onSelectItem:
|
|
618
|
-
onActiveItemChange:
|
|
627
|
+
anchor: x,
|
|
628
|
+
onSelectItem: h,
|
|
629
|
+
onActiveItemChange: k,
|
|
619
630
|
renderItem: o,
|
|
620
631
|
className: w(
|
|
621
632
|
"tw:absolute tw:top-full tw:mt-1 tw:z-10",
|
|
622
633
|
{
|
|
623
|
-
"tw:min-w-60
|
|
624
|
-
"tw:w-full":
|
|
625
|
-
}
|
|
634
|
+
"tw:min-w-60": a === "auto",
|
|
635
|
+
"tw:w-full": a === "full"
|
|
636
|
+
},
|
|
637
|
+
s
|
|
626
638
|
),
|
|
627
639
|
"aria-label": "Matching items",
|
|
628
640
|
noItemsMessage: "No results found matching search"
|
|
@@ -632,11 +644,132 @@ function Fe({
|
|
|
632
644
|
}
|
|
633
645
|
);
|
|
634
646
|
}
|
|
635
|
-
const
|
|
636
|
-
|
|
647
|
+
const ne = v(re), oe = ({ name: r, color: e }) => /* @__PURE__ */ m("div", { className: "tw:inline-flex tw:items-center tw:gap-2", children: [
|
|
648
|
+
/* @__PURE__ */ n("div", { "aria-hidden": !0, className: "tw:w-4 tw:h-4 tw:rounded-full", style: { backgroundColor: e } }),
|
|
649
|
+
r
|
|
650
|
+
] }), ae = ({ tag: r, color: e, size: t, onRemove: o }) => (
|
|
651
|
+
// eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-noninteractive-element-interactions
|
|
652
|
+
/* @__PURE__ */ m(
|
|
653
|
+
"li",
|
|
654
|
+
{
|
|
655
|
+
className: y(
|
|
656
|
+
"tw:inline-flex tw:items-center tw:gap-1 tw:font-bold tw:[&]:rounded-md",
|
|
657
|
+
{
|
|
658
|
+
"tw:px-1 tw:text-sm": t === "sm",
|
|
659
|
+
"tw:py-0.25 tw:px-1.5": t === "md",
|
|
660
|
+
"tw:py-0.5 tw:px-1.5": t === "lg"
|
|
661
|
+
}
|
|
662
|
+
),
|
|
663
|
+
style: {
|
|
664
|
+
backgroundColor: e,
|
|
665
|
+
color: Pt(e) ? "#000" : "#fff"
|
|
666
|
+
},
|
|
667
|
+
onClick: (l) => l.stopPropagation(),
|
|
668
|
+
children: [
|
|
669
|
+
r,
|
|
670
|
+
/* @__PURE__ */ n(G, { label: `Remove ${r}`, solid: !0, size: "sm", onClick: () => o(r) })
|
|
671
|
+
]
|
|
672
|
+
}
|
|
673
|
+
)
|
|
674
|
+
), le = /\s+/g, rt = "#99a1af", nt = (r) => r.trim().toLowerCase().replace(le, "-"), Ue = ({
|
|
675
|
+
tags: r,
|
|
676
|
+
selectedTags: e = [],
|
|
677
|
+
onTagsChange: t,
|
|
678
|
+
getColorForTag: o,
|
|
679
|
+
searchMode: l = "startsWith",
|
|
680
|
+
immutable: a = !1,
|
|
681
|
+
size: d = "md",
|
|
682
|
+
disabled: i,
|
|
683
|
+
containerClassName: s,
|
|
684
|
+
...c
|
|
685
|
+
}) => {
|
|
686
|
+
const [f, u] = M(), p = I((h) => {
|
|
687
|
+
const g = h.toLowerCase().trim();
|
|
688
|
+
if (!g) {
|
|
689
|
+
u(void 0);
|
|
690
|
+
return;
|
|
691
|
+
}
|
|
692
|
+
const O = r.filter((N) => {
|
|
693
|
+
if (e.includes(N))
|
|
694
|
+
return !1;
|
|
695
|
+
const D = N.toLowerCase();
|
|
696
|
+
return l === "startsWith" ? D.startsWith(g) : D.includes(g);
|
|
697
|
+
}).slice(0, 5);
|
|
698
|
+
a || O.push(`Add "${g.split(",").map(nt).join(",")}" tag`), u(new Map(O.map((N) => [N, N])));
|
|
699
|
+
}, [a, l, e, r]), k = I((h) => {
|
|
700
|
+
const g = h.match(/Add\s+"([^"]+)"\s+tag/), O = ((g == null ? void 0 : g[1]) ?? h).split(",").map(nt);
|
|
701
|
+
t == null || t([.../* @__PURE__ */ new Set([...e, ...O])]);
|
|
702
|
+
}, [t, e]), x = I(
|
|
703
|
+
(h) => t == null ? void 0 : t(e.filter((g) => g !== h)),
|
|
704
|
+
[t, e]
|
|
705
|
+
), b = P(null);
|
|
706
|
+
return (
|
|
707
|
+
// eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
|
|
708
|
+
/* @__PURE__ */ m(
|
|
709
|
+
"div",
|
|
710
|
+
{
|
|
711
|
+
className: y(
|
|
712
|
+
"tw:rounded-md tw:flex tw:flex-wrap tw:gap-1",
|
|
713
|
+
"tw:border tw:border-lm-input-border tw:dark:border-dm-input-border",
|
|
714
|
+
"tw:cursor-text tw:focus-within:focus-within-ring",
|
|
715
|
+
{
|
|
716
|
+
"tw:p-0.5": d === "sm",
|
|
717
|
+
"tw:p-1.25": d === "md",
|
|
718
|
+
"tw:p-2": d === "lg",
|
|
719
|
+
"tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input": i,
|
|
720
|
+
"tw:bg-lm-primary tw:dark:bg-dm-primary": !i,
|
|
721
|
+
// Use different background color when rendered inside a card
|
|
722
|
+
"tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input": !i
|
|
723
|
+
},
|
|
724
|
+
s
|
|
725
|
+
),
|
|
726
|
+
onClick: (h) => {
|
|
727
|
+
var g;
|
|
728
|
+
h.target !== b.current && ((g = b.current) == null || g.focus());
|
|
729
|
+
},
|
|
730
|
+
children: [
|
|
731
|
+
/* @__PURE__ */ n("ul", { className: "tw:m-0 tw:p-0 tw:flex tw:flex-wrap tw:gap-1", children: e.map((h, g) => {
|
|
732
|
+
const O = (o == null ? void 0 : o(h)) ?? rt;
|
|
733
|
+
return /* @__PURE__ */ n(ae, { tag: h, color: O, onRemove: x, size: d }, `${h}${g}`);
|
|
734
|
+
}) }),
|
|
735
|
+
/* @__PURE__ */ n(
|
|
736
|
+
ne,
|
|
737
|
+
{
|
|
738
|
+
variant: "unstyled",
|
|
739
|
+
listboxSpan: "auto",
|
|
740
|
+
containerClassName: "tw:flex tw:items-center",
|
|
741
|
+
listboxClassName: "tw:whitespace-nowrap",
|
|
742
|
+
inputClassName: y(
|
|
743
|
+
"tw:no-clear-button",
|
|
744
|
+
{
|
|
745
|
+
"tw:px-1 tw:text-sm": d === "sm",
|
|
746
|
+
"tw:px-2 tw:h-[26px]": d === "md",
|
|
747
|
+
"tw:px-3 tw:text-xl": d === "lg"
|
|
748
|
+
}
|
|
749
|
+
),
|
|
750
|
+
searchResults: f,
|
|
751
|
+
onSearch: p,
|
|
752
|
+
onSelectSearchResult: k,
|
|
753
|
+
renderSearchResult: (h) => h.match(/Add\s+"([^"]+)"\s+tag/) ? h : /* @__PURE__ */ n(oe, { name: h, color: (o == null ? void 0 : o(h)) ?? rt }),
|
|
754
|
+
onKeyDown: (h) => {
|
|
755
|
+
h.key === "Backspace" && !f && x(e[e.length - 1]);
|
|
756
|
+
},
|
|
757
|
+
size: d,
|
|
758
|
+
disabled: i,
|
|
759
|
+
ref: b,
|
|
760
|
+
immediate: !0,
|
|
761
|
+
...c
|
|
762
|
+
}
|
|
763
|
+
)
|
|
764
|
+
]
|
|
765
|
+
}
|
|
766
|
+
)
|
|
767
|
+
);
|
|
768
|
+
}, Ke = v(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
769
|
+
it,
|
|
637
770
|
{
|
|
638
771
|
ref: t,
|
|
639
|
-
className:
|
|
772
|
+
className: y(
|
|
640
773
|
"tw:rounded-full tw:w-8 tw:h-4",
|
|
641
774
|
"tw:bg-(image:--circle-grey-dark) tw:dark:bg-(image:--circle-grey-light) tw:checked:bg-(image:--circle-white)",
|
|
642
775
|
"tw:focus-visible:not-checked:bg-(image:--circle-light-blue)",
|
|
@@ -645,20 +778,22 @@ const Ee = y(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
|
645
778
|
),
|
|
646
779
|
...e
|
|
647
780
|
}
|
|
648
|
-
)),
|
|
649
|
-
const
|
|
781
|
+
)), de = ({ className: r, selected: e, disabled: t, ...o }) => {
|
|
782
|
+
const l = "to" in o && typeof o.to == "string";
|
|
650
783
|
return (
|
|
651
784
|
// @ts-expect-error The Tag is inferred from provided props, so they should always match
|
|
652
785
|
/* @__PURE__ */ n(
|
|
653
|
-
|
|
786
|
+
l ? J : "button",
|
|
654
787
|
{
|
|
655
788
|
role: "menuitem",
|
|
656
789
|
"data-selected": e,
|
|
657
|
-
className:
|
|
658
|
-
"tw:flex tw:items-center tw:
|
|
790
|
+
className: y(
|
|
791
|
+
"tw:flex tw:items-center tw:gap-2",
|
|
792
|
+
"tw:w-full tw:px-3 tw:py-1.5 tw:focus-ring",
|
|
659
793
|
// Overwrite link styles in case a Link is being used
|
|
660
794
|
"tw:no-underline tw:text-inherit",
|
|
661
795
|
{
|
|
796
|
+
"tw:cursor-pointer": !t,
|
|
662
797
|
"tw:pointer-events-none tw:opacity-50": t,
|
|
663
798
|
"tw:bg-lm-secondary tw:dark:bg-dm-secondary": e && !t,
|
|
664
799
|
"tw:highlight:bg-lm-secondary tw:dark:highlight:bg-dm-secondary tw:highlight:z-1 tw:relative": !e && !t
|
|
@@ -666,109 +801,110 @@ const Ee = y(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
|
666
801
|
r
|
|
667
802
|
),
|
|
668
803
|
tabIndex: -1,
|
|
669
|
-
disabled:
|
|
670
|
-
"aria-disabled":
|
|
804
|
+
disabled: l ? void 0 : t,
|
|
805
|
+
"aria-disabled": l ? t : void 0,
|
|
671
806
|
...o
|
|
672
807
|
}
|
|
673
808
|
)
|
|
674
809
|
);
|
|
675
|
-
},
|
|
810
|
+
}, ie = () => (
|
|
676
811
|
// TODO Use an <hr /> tag once tailwind styles are not set with !important
|
|
677
812
|
/* @__PURE__ */ n("div", { role: "separator", "aria-hidden": !0, className: "tw:border-b tw:border-lm-border tw:dark:border-dm-border tw:my-2" })
|
|
678
|
-
),
|
|
813
|
+
), se = ({ children: r }) => /* @__PURE__ */ n(
|
|
679
814
|
"div",
|
|
680
815
|
{
|
|
681
816
|
role: "heading",
|
|
682
817
|
"aria-level": 6,
|
|
683
818
|
"aria-hidden": !0,
|
|
684
|
-
className:
|
|
819
|
+
className: y(
|
|
685
820
|
"tw:flex tw:items-center tw:w-full tw:px-3 tw:py-1.5",
|
|
686
821
|
"tw:text-gray-500 tw:text-sm tw:font-semibold"
|
|
687
822
|
),
|
|
688
823
|
onClick: (e) => e.stopPropagation(),
|
|
689
824
|
children: r
|
|
690
825
|
}
|
|
691
|
-
),
|
|
826
|
+
), ce = ({ className: r, onClick: e, ...t }) => (
|
|
692
827
|
// eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
|
|
693
828
|
/* @__PURE__ */ n(
|
|
694
829
|
"div",
|
|
695
830
|
{
|
|
696
|
-
className:
|
|
831
|
+
className: y("tw:px-3 tw:py-1.5", r),
|
|
697
832
|
...t,
|
|
698
833
|
onClick: (o) => {
|
|
699
834
|
o.stopPropagation(), e == null || e(o);
|
|
700
835
|
}
|
|
701
836
|
}
|
|
702
837
|
)
|
|
703
|
-
),
|
|
838
|
+
), we = ({
|
|
704
839
|
children: r,
|
|
705
840
|
className: e,
|
|
706
841
|
focusableElementsSelector: t = '[role="menuitem"]:not([disabled]):not([aria-disabled])',
|
|
707
842
|
focusFirstItem: o = !1,
|
|
708
|
-
...
|
|
843
|
+
...l
|
|
709
844
|
}) => {
|
|
710
|
-
const
|
|
711
|
-
return
|
|
712
|
-
},
|
|
845
|
+
const a = P(null);
|
|
846
|
+
return Ot(a, { elementsSelector: t, focusFirstItem: o }), /* @__PURE__ */ n(L, { ref: a, role: "menu", className: y("tw:py-2 tw:whitespace-nowrap", e), ...l, children: r });
|
|
847
|
+
}, $ = Object.assign(we, { Item: de, Separator: ie, Title: se, Misc: ce }), me = ({
|
|
713
848
|
children: r,
|
|
714
849
|
menuAlignment: e = "left",
|
|
715
850
|
buttonVariant: t = "button",
|
|
716
851
|
buttonContent: o,
|
|
717
|
-
buttonClassName:
|
|
718
|
-
buttonSize:
|
|
852
|
+
buttonClassName: l,
|
|
853
|
+
buttonSize: a = "md",
|
|
719
854
|
buttonDisabled: d = !1,
|
|
720
855
|
containerClassName: i,
|
|
721
856
|
menuClassName: s,
|
|
722
857
|
caretless: c,
|
|
723
|
-
buttonLabel:
|
|
858
|
+
buttonLabel: f
|
|
724
859
|
}) => {
|
|
725
|
-
const [
|
|
726
|
-
open:
|
|
727
|
-
onOpenChange:
|
|
860
|
+
const [u, p] = M(!1), k = P(null), { refs: x, floatingStyles: b, context: h } = lt({
|
|
861
|
+
open: u,
|
|
862
|
+
onOpenChange: p,
|
|
728
863
|
placement: e === "right" ? "bottom-end" : "bottom-start",
|
|
729
|
-
middleware: [
|
|
864
|
+
middleware: [Dt(), Et(3)],
|
|
730
865
|
// eslint-disable-next-line react-compiler/react-compiler
|
|
731
|
-
elements: { reference:
|
|
732
|
-
}),
|
|
733
|
-
|
|
734
|
-
]),
|
|
735
|
-
return
|
|
736
|
-
const
|
|
737
|
-
if (!
|
|
866
|
+
elements: { reference: k.current }
|
|
867
|
+
}), g = Mt(h), { getReferenceProps: O, getFloatingProps: N } = dt([
|
|
868
|
+
g
|
|
869
|
+
]), D = H(), B = P(null);
|
|
870
|
+
return T(() => {
|
|
871
|
+
const R = B.current, z = k.current;
|
|
872
|
+
if (!R || !z)
|
|
738
873
|
return () => {
|
|
739
874
|
};
|
|
740
|
-
const
|
|
741
|
-
return document.body.addEventListener("click", (
|
|
742
|
-
|
|
743
|
-
}, { signal:
|
|
875
|
+
const V = new AbortController();
|
|
876
|
+
return document.body.addEventListener("click", (pt) => {
|
|
877
|
+
pt.composedPath().includes(z) || p(!1);
|
|
878
|
+
}, { signal: V.signal }), () => V.abort();
|
|
744
879
|
}, []), // eslint-disable-next-line jsx-a11y/no-static-element-interactions
|
|
745
|
-
/* @__PURE__ */
|
|
880
|
+
/* @__PURE__ */ m(
|
|
746
881
|
"div",
|
|
747
882
|
{
|
|
748
|
-
ref:
|
|
749
|
-
className:
|
|
750
|
-
onKeyDown: (
|
|
751
|
-
|
|
883
|
+
ref: B,
|
|
884
|
+
className: y("tw:relative tw:inline-block", i),
|
|
885
|
+
onKeyDown: (R) => {
|
|
886
|
+
R.key === "Escape" && p(!1);
|
|
752
887
|
},
|
|
753
|
-
onBlur: (
|
|
754
|
-
|
|
888
|
+
onBlur: (R) => {
|
|
889
|
+
R.relatedTarget && !B.current.contains(R.relatedTarget) && p(!1);
|
|
755
890
|
},
|
|
756
891
|
children: [
|
|
757
|
-
/* @__PURE__ */
|
|
892
|
+
/* @__PURE__ */ m(
|
|
758
893
|
"button",
|
|
759
894
|
{
|
|
760
|
-
ref:
|
|
761
|
-
...
|
|
895
|
+
ref: k,
|
|
896
|
+
...O(),
|
|
762
897
|
type: "button",
|
|
763
898
|
"aria-haspopup": !0,
|
|
764
|
-
"aria-expanded":
|
|
765
|
-
"aria-controls":
|
|
766
|
-
"aria-label":
|
|
899
|
+
"aria-expanded": u,
|
|
900
|
+
"aria-controls": D,
|
|
901
|
+
"aria-label": f,
|
|
767
902
|
disabled: d,
|
|
768
|
-
className:
|
|
903
|
+
className: y(
|
|
769
904
|
"tw:flex tw:items-center tw:rounded-md tw:focus-ring",
|
|
770
905
|
{
|
|
771
906
|
"tw:justify-between": !c,
|
|
907
|
+
"tw:cursor-pointer": !d,
|
|
772
908
|
"tw:pointer-events-none tw:opacity-50": d,
|
|
773
909
|
// Button variant
|
|
774
910
|
"tw:border tw:border-lm-border tw:dark:border-dm-border": t === "button",
|
|
@@ -779,33 +915,33 @@ const Ee = y(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
|
779
915
|
"tw:text-lm-brand tw:dark:text-dm-brand": t === "link",
|
|
780
916
|
"tw:highlight:text-lm-brand-dark tw:dark:highlight:text-dm-brand-dark tw:highlight:underline": t === "link",
|
|
781
917
|
// Button sizes
|
|
782
|
-
"tw:px-1.5 tw:py-1 tw:text-sm tw:gap-x-1.5":
|
|
783
|
-
"tw:px-3 tw:py-1.5 tw:gap-x-2":
|
|
784
|
-
"tw:px-4 tw:py-2 tw:text-lg tw:gap-x-2":
|
|
918
|
+
"tw:px-1.5 tw:py-1 tw:text-sm tw:gap-x-1.5": a === "sm",
|
|
919
|
+
"tw:px-3 tw:py-1.5 tw:gap-x-2": a === "md",
|
|
920
|
+
"tw:px-4 tw:py-2 tw:text-lg tw:gap-x-2": a === "lg"
|
|
785
921
|
},
|
|
786
|
-
|
|
922
|
+
l
|
|
787
923
|
),
|
|
788
|
-
onKeyDown: (
|
|
789
|
-
|
|
924
|
+
onKeyDown: (R) => {
|
|
925
|
+
R.key === "ArrowDown" && (R.preventDefault(), p(!0));
|
|
790
926
|
},
|
|
791
927
|
children: [
|
|
792
928
|
o,
|
|
793
|
-
!c && /* @__PURE__ */ n(
|
|
929
|
+
!c && /* @__PURE__ */ n(C, { icon: yt, size: "xs" })
|
|
794
930
|
]
|
|
795
931
|
}
|
|
796
932
|
),
|
|
797
|
-
|
|
933
|
+
u && /* @__PURE__ */ n(
|
|
798
934
|
"div",
|
|
799
935
|
{
|
|
800
|
-
ref:
|
|
801
|
-
style:
|
|
936
|
+
ref: x.setFloating,
|
|
937
|
+
style: b,
|
|
802
938
|
className: "tw:min-w-full tw:z-1000",
|
|
803
|
-
...
|
|
939
|
+
...N(),
|
|
804
940
|
children: /* @__PURE__ */ n(
|
|
805
|
-
|
|
941
|
+
$,
|
|
806
942
|
{
|
|
807
943
|
className: s,
|
|
808
|
-
id:
|
|
944
|
+
id: D,
|
|
809
945
|
focusableElementsSelector: '[role="menuitem"]:not([disabled]):not([aria-disabled]),input:not([disabled]),select:not([disabled])',
|
|
810
946
|
focusFirstItem: !0,
|
|
811
947
|
children: r
|
|
@@ -816,12 +952,12 @@ const Ee = y(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
|
816
952
|
]
|
|
817
953
|
}
|
|
818
954
|
);
|
|
819
|
-
},
|
|
820
|
-
Item:
|
|
821
|
-
Separator:
|
|
822
|
-
Title:
|
|
823
|
-
Misc:
|
|
824
|
-
}),
|
|
955
|
+
}, S = Object.assign(me, {
|
|
956
|
+
Item: $.Item,
|
|
957
|
+
Separator: $.Separator,
|
|
958
|
+
Title: $.Title,
|
|
959
|
+
Misc: $.Misc
|
|
960
|
+
}), pe = v(({ className: r, disabled: e, size: t = "md", type: o = "button", ...l }, a) => /* @__PURE__ */ n(
|
|
825
961
|
"button",
|
|
826
962
|
{
|
|
827
963
|
className: w(
|
|
@@ -832,32 +968,33 @@ const Ee = y(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
|
832
968
|
"tw:px-1.5 tw:py-1 tw:text-sm": t === "sm",
|
|
833
969
|
"tw:px-3 tw:py-1.5": t === "md",
|
|
834
970
|
"tw:px-4 tw:py-2 tw:text-lg": t === "lg",
|
|
971
|
+
"tw:cursor-pointer": !e,
|
|
835
972
|
"tw:pointer-events-none tw:opacity-65": e
|
|
836
973
|
},
|
|
837
974
|
r
|
|
838
975
|
),
|
|
839
976
|
disabled: e,
|
|
840
977
|
type: o,
|
|
841
|
-
...
|
|
842
|
-
ref:
|
|
978
|
+
...l,
|
|
979
|
+
ref: a
|
|
843
980
|
}
|
|
844
|
-
)),
|
|
845
|
-
const o =
|
|
981
|
+
)), st = X(null), ue = ({ className: r, to: e, ...t }) => {
|
|
982
|
+
const o = E(st);
|
|
846
983
|
return /* @__PURE__ */ n(
|
|
847
|
-
|
|
984
|
+
bt,
|
|
848
985
|
{
|
|
849
986
|
role: "menuitem",
|
|
850
987
|
to: e,
|
|
851
|
-
className: ({ isActive:
|
|
988
|
+
className: ({ isActive: l }) => w(
|
|
852
989
|
"tw:px-4 tw:pt-2 tw:pb-[calc(0.5rem-3px)] tw:border-b-3",
|
|
853
990
|
"tw:highlight:text-lm-brand tw:dark:highlight:text-dm-brand",
|
|
854
991
|
"tw:font-bold tw:text-center tw:no-underline tw:transition-colors",
|
|
855
992
|
"tw:rounded-none tw:outline-none tw:focus-visible:inset-ring-2",
|
|
856
993
|
"tw:focus-visible:inset-ring-lm-brand/50 tw:dark:focus-visible:inset-ring-dm-brand/50",
|
|
857
994
|
{
|
|
858
|
-
"tw:text-lm-brand tw:dark:text-dm-brand":
|
|
859
|
-
"tw:border-b-lm-brand tw:dark:border-b-dm-brand active":
|
|
860
|
-
"tw:border-b-transparent tw:text-gray-500": !
|
|
995
|
+
"tw:text-lm-brand tw:dark:text-dm-brand": l,
|
|
996
|
+
"tw:border-b-lm-brand tw:dark:border-b-dm-brand active": l,
|
|
997
|
+
"tw:border-b-transparent tw:text-gray-500": !l,
|
|
861
998
|
"tw:flex-grow": o == null ? void 0 : o.fill
|
|
862
999
|
},
|
|
863
1000
|
r
|
|
@@ -865,18 +1002,18 @@ const Ee = y(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
|
865
1002
|
...t
|
|
866
1003
|
}
|
|
867
1004
|
);
|
|
868
|
-
},
|
|
869
|
-
const t =
|
|
870
|
-
Math.max(
|
|
871
|
-
Math.min(e - 1, r +
|
|
1005
|
+
}, be = ({ children: r, className: e, fill: t }) => /* @__PURE__ */ n(st.Provider, { value: { fill: t }, children: /* @__PURE__ */ n(L, { role: "menubar", className: w("tw:flex tw:overflow-hidden", e), children: r }) }), Ge = Object.assign(be, { Pill: ue }), ge = new Intl.NumberFormat("en-US"), he = (r) => ge.format(Number(r)), ot = 10, qe = (r) => Math.ceil(r / ot) * ot, A = 2, U = "...", fe = (r, e) => Array.from({ length: e - r }, (t, o) => r + o), xe = (r, e) => {
|
|
1006
|
+
const t = fe(
|
|
1007
|
+
Math.max(A, r - A),
|
|
1008
|
+
Math.min(e - 1, r + A) + 1
|
|
872
1009
|
);
|
|
873
|
-
return r -
|
|
874
|
-
},
|
|
1010
|
+
return r - A > A && t.unshift(U), r + A < e - 1 && t.push(U), t.unshift(1), t.push(e), t;
|
|
1011
|
+
}, j = (r) => r === U, ye = (r) => j(r) ? r : he(r), ke = (r, e) => j(r) ? `${r}_${e}` : `${r}`, ct = [
|
|
875
1012
|
"tw:border tw:border-r-0 tw:last:border-r tw:border-lm-border tw:dark:border-dm-border",
|
|
876
1013
|
"tw:rounded-none tw:first:rounded-l tw:last:rounded-r"
|
|
877
|
-
],
|
|
878
|
-
|
|
879
|
-
"tw:px-3 py-2 tw:cursor-pointer tw:no-underline",
|
|
1014
|
+
], wt = (r = !1) => w(
|
|
1015
|
+
ct,
|
|
1016
|
+
"tw:px-3 tw:py-2 tw:cursor-pointer tw:no-underline",
|
|
880
1017
|
"tw:focus-ring tw:focus-visible:z-1",
|
|
881
1018
|
!r && [
|
|
882
1019
|
"tw:text-lm-brand tw:dark:text-dm-brand",
|
|
@@ -884,42 +1021,42 @@ const Ee = y(({ className: r, ...e }, t) => /* @__PURE__ */ n(
|
|
|
884
1021
|
"tw:highlight:bg-lm-secondary tw:dark:highlight:bg-dm-secondary"
|
|
885
1022
|
],
|
|
886
1023
|
r && "tw:bg-lm-main tw:dark:bg-dm-main tw:text-white"
|
|
887
|
-
),
|
|
888
|
-
function
|
|
889
|
-
const
|
|
890
|
-
return t ? /* @__PURE__ */ n(
|
|
1024
|
+
), q = ({ children: r }) => /* @__PURE__ */ n("span", { "aria-hidden": !0, className: w(ct, "tw:px-3 tw:py-2 tw:text-gray-400"), children: r }), mt = () => /* @__PURE__ */ n(q, { children: U });
|
|
1025
|
+
function ve({ children: r, active: e, isEllipsis: t, href: o, ...l }) {
|
|
1026
|
+
const a = K(() => wt(e), [e]);
|
|
1027
|
+
return t ? /* @__PURE__ */ n(mt, {}) : /* @__PURE__ */ n(J, { className: a, to: o, ...l, children: r });
|
|
891
1028
|
}
|
|
892
|
-
function
|
|
893
|
-
const
|
|
894
|
-
return t ? /* @__PURE__ */ n(
|
|
1029
|
+
function Ne({ children: r, active: e, isEllipsis: t, ...o }) {
|
|
1030
|
+
const l = K(() => wt(e), [e]);
|
|
1031
|
+
return t ? /* @__PURE__ */ n(mt, {}) : /* @__PURE__ */ n("button", { type: "button", className: l, ...o, children: r });
|
|
895
1032
|
}
|
|
896
|
-
const
|
|
897
|
-
const o = "urlForPage" in t,
|
|
898
|
-
(d) => o ? { href:
|
|
1033
|
+
const Xe = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
1034
|
+
const o = "urlForPage" in t, l = o ? ve : Ne, a = I(
|
|
1035
|
+
(d) => o ? { href: j(d) ? void 0 : t.urlForPage(d) } : { onClick: () => !j(d) && t.onPageChange(d) },
|
|
899
1036
|
[o, t]
|
|
900
1037
|
);
|
|
901
|
-
return e < 2 ? null : /* @__PURE__ */
|
|
902
|
-
r === 1 ? /* @__PURE__ */ n(
|
|
903
|
-
|
|
904
|
-
|
|
1038
|
+
return e < 2 ? null : /* @__PURE__ */ m("div", { className: "tw:select-none tw:flex", "data-testid": "paginator", children: [
|
|
1039
|
+
r === 1 ? /* @__PURE__ */ n(q, { children: /* @__PURE__ */ n(C, { size: "xs", icon: tt }) }) : /* @__PURE__ */ n(l, { ...a(Math.max(1, r - 1)), "aria-label": "Previous", children: /* @__PURE__ */ n(C, { size: "xs", icon: tt }) }),
|
|
1040
|
+
xe(r, e).map((d, i) => /* @__PURE__ */ n(
|
|
1041
|
+
l,
|
|
905
1042
|
{
|
|
906
1043
|
active: d === r,
|
|
907
|
-
isEllipsis:
|
|
908
|
-
...
|
|
909
|
-
children:
|
|
1044
|
+
isEllipsis: j(d),
|
|
1045
|
+
...a(d),
|
|
1046
|
+
children: ye(d)
|
|
910
1047
|
},
|
|
911
|
-
|
|
1048
|
+
ke(d, i)
|
|
912
1049
|
)),
|
|
913
|
-
r === e ? /* @__PURE__ */ n(
|
|
1050
|
+
r === e ? /* @__PURE__ */ n(q, { children: /* @__PURE__ */ n(C, { size: "xs", icon: et }) }) : /* @__PURE__ */ n(l, { ...a(Math.min(e, r + 1)), "aria-label": "Next", children: /* @__PURE__ */ n(C, { size: "xs", icon: et }) })
|
|
914
1051
|
] });
|
|
915
|
-
},
|
|
916
|
-
|
|
1052
|
+
}, Ce = ({ buttonLabel: r = "Options", buttonSize: e = "md", ...t }) => /* @__PURE__ */ n(
|
|
1053
|
+
S,
|
|
917
1054
|
{
|
|
918
1055
|
buttonContent: /* @__PURE__ */ n(
|
|
919
|
-
|
|
1056
|
+
C,
|
|
920
1057
|
{
|
|
921
|
-
icon:
|
|
922
|
-
className:
|
|
1058
|
+
icon: kt,
|
|
1059
|
+
className: y({ "tw:px-1": e === "sm" })
|
|
923
1060
|
}
|
|
924
1061
|
),
|
|
925
1062
|
caretless: !0,
|
|
@@ -927,102 +1064,102 @@ const Ae = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
|
927
1064
|
buttonSize: e,
|
|
928
1065
|
...t
|
|
929
1066
|
}
|
|
930
|
-
),
|
|
931
|
-
Item:
|
|
932
|
-
Separator:
|
|
933
|
-
Title:
|
|
934
|
-
Misc:
|
|
935
|
-
}),
|
|
1067
|
+
), Je = Object.assign(Ce, {
|
|
1068
|
+
Item: S.Item,
|
|
1069
|
+
Separator: S.Separator,
|
|
1070
|
+
Title: S.Title,
|
|
1071
|
+
Misc: S.Misc
|
|
1072
|
+
}), Ie = ({
|
|
936
1073
|
open: r,
|
|
937
1074
|
children: e,
|
|
938
1075
|
className: t,
|
|
939
1076
|
onClose: o,
|
|
940
|
-
...
|
|
1077
|
+
...l
|
|
941
1078
|
}) => {
|
|
942
|
-
const
|
|
943
|
-
return
|
|
944
|
-
var c,
|
|
1079
|
+
const a = P(null);
|
|
1080
|
+
return T(() => {
|
|
1081
|
+
var c, f;
|
|
945
1082
|
const d = document.body, i = d.style.overflow, s = d.style.paddingRight;
|
|
946
1083
|
if (r) {
|
|
947
|
-
const
|
|
948
|
-
d.style.overflow = "hidden",
|
|
1084
|
+
const u = window.outerWidth - d.clientWidth, p = d.scrollHeight > d.clientHeight;
|
|
1085
|
+
d.style.overflow = "hidden", p && (d.style.paddingRight = `${u}px`), (c = a.current) == null || c.showModal();
|
|
949
1086
|
} else
|
|
950
|
-
(
|
|
1087
|
+
(f = a.current) == null || f.close();
|
|
951
1088
|
return () => {
|
|
952
1089
|
d.style.overflow = i, d.style.paddingRight = s;
|
|
953
1090
|
};
|
|
954
|
-
}, [r]),
|
|
1091
|
+
}, [r]), $t(
|
|
955
1092
|
/* @__PURE__ */ n(
|
|
956
1093
|
"dialog",
|
|
957
1094
|
{
|
|
958
|
-
ref:
|
|
1095
|
+
ref: a,
|
|
959
1096
|
className: w("tw:bg-transparent tw:backdrop:bg-black/50", t),
|
|
960
1097
|
onCancel: (d) => {
|
|
961
1098
|
d.preventDefault(), o();
|
|
962
1099
|
},
|
|
963
|
-
...
|
|
1100
|
+
...l,
|
|
964
1101
|
children: r && e
|
|
965
1102
|
}
|
|
966
1103
|
),
|
|
967
1104
|
document.body
|
|
968
1105
|
);
|
|
969
|
-
},
|
|
1106
|
+
}, Qe = ({
|
|
970
1107
|
open: r,
|
|
971
1108
|
onClose: e,
|
|
972
1109
|
variant: t = "default",
|
|
973
1110
|
title: o,
|
|
974
|
-
children:
|
|
975
|
-
className:
|
|
1111
|
+
children: l,
|
|
1112
|
+
className: a,
|
|
976
1113
|
...d
|
|
977
1114
|
}) => {
|
|
978
1115
|
const {
|
|
979
1116
|
size: i = "md",
|
|
980
1117
|
confirmText: s = "Confirm",
|
|
981
1118
|
cancelText: c = "Cancel",
|
|
982
|
-
confirmDisabled:
|
|
983
|
-
onConfirm:
|
|
984
|
-
onClosed:
|
|
985
|
-
...
|
|
986
|
-
} = "onConfirm" in d ? d : { ...d }, [
|
|
987
|
-
|
|
988
|
-
}, [
|
|
989
|
-
return
|
|
1119
|
+
confirmDisabled: f,
|
|
1120
|
+
onConfirm: u,
|
|
1121
|
+
onClosed: p,
|
|
1122
|
+
...k
|
|
1123
|
+
} = "onConfirm" in d ? d : { ...d }, [x, b] = M(r), h = P(null), g = P("cancel"), O = I((N) => {
|
|
1124
|
+
N.preventDefault(), N.stopPropagation(), g.current = "confirm", u == null || u();
|
|
1125
|
+
}, [u]);
|
|
1126
|
+
return T(() => {
|
|
990
1127
|
if (r) {
|
|
991
|
-
|
|
1128
|
+
g.current = "cancel", b(!0);
|
|
992
1129
|
return;
|
|
993
1130
|
}
|
|
994
|
-
const
|
|
995
|
-
if (
|
|
996
|
-
delete
|
|
997
|
-
let
|
|
998
|
-
const
|
|
999
|
-
|
|
1131
|
+
const N = h.current;
|
|
1132
|
+
if (N) {
|
|
1133
|
+
delete h.current.dataset.open;
|
|
1134
|
+
let D = !1;
|
|
1135
|
+
const B = (R) => {
|
|
1136
|
+
D || R.target !== N || (D = !0, b(!1), p == null || p(g.current));
|
|
1000
1137
|
};
|
|
1001
|
-
return
|
|
1002
|
-
|
|
1138
|
+
return N.addEventListener("transitionend", B), () => {
|
|
1139
|
+
N.removeEventListener("transitionend", B);
|
|
1003
1140
|
};
|
|
1004
1141
|
}
|
|
1005
|
-
}, [
|
|
1006
|
-
const
|
|
1007
|
-
|
|
1008
|
-
}, [
|
|
1009
|
-
|
|
1142
|
+
}, [p, r]), T(() => {
|
|
1143
|
+
const N = h.current;
|
|
1144
|
+
x && N && (N.dataset.open = "");
|
|
1145
|
+
}, [x]), /* @__PURE__ */ n(
|
|
1146
|
+
Ie,
|
|
1010
1147
|
{
|
|
1011
|
-
open:
|
|
1148
|
+
open: x,
|
|
1012
1149
|
onClose: e,
|
|
1013
1150
|
className: w(
|
|
1014
1151
|
{
|
|
1015
|
-
"tw:flex tw:w-screen tw:h-screen tw:max-w-screen tw:max-h-screen":
|
|
1152
|
+
"tw:flex tw:w-screen tw:h-screen tw:max-w-screen tw:max-h-screen": x,
|
|
1016
1153
|
"tw:overflow-hidden": t === "cover"
|
|
1017
1154
|
},
|
|
1018
|
-
|
|
1155
|
+
a
|
|
1019
1156
|
),
|
|
1020
|
-
...
|
|
1157
|
+
...k,
|
|
1021
1158
|
children: /* @__PURE__ */ n(
|
|
1022
1159
|
"form",
|
|
1023
1160
|
{
|
|
1024
1161
|
"data-testid": "transition-container",
|
|
1025
|
-
ref:
|
|
1162
|
+
ref: h,
|
|
1026
1163
|
className: w(
|
|
1027
1164
|
"tw:w-full tw:m-auto tw:p-4 tw:sm:p-6",
|
|
1028
1165
|
// CSS transitions are based on the presence of the `data-open` attribute
|
|
@@ -1037,12 +1174,12 @@ const Ae = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
|
1037
1174
|
},
|
|
1038
1175
|
{ "tw:h-full": t === "cover" }
|
|
1039
1176
|
),
|
|
1040
|
-
onSubmit:
|
|
1041
|
-
children: /* @__PURE__ */ n(
|
|
1177
|
+
onSubmit: O,
|
|
1178
|
+
children: /* @__PURE__ */ n(L, { className: w(
|
|
1042
1179
|
"tw:w-full",
|
|
1043
1180
|
{ "tw:h-full tw:relative tw:overflow-auto": t === "cover" }
|
|
1044
|
-
), children: t === "cover" ? /* @__PURE__ */
|
|
1045
|
-
/* @__PURE__ */
|
|
1181
|
+
), children: t === "cover" ? /* @__PURE__ */ m(F, { children: [
|
|
1182
|
+
/* @__PURE__ */ m(
|
|
1046
1183
|
"div",
|
|
1047
1184
|
{
|
|
1048
1185
|
className: w(
|
|
@@ -1053,22 +1190,22 @@ const Ae = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
|
1053
1190
|
),
|
|
1054
1191
|
children: [
|
|
1055
1192
|
/* @__PURE__ */ n("h5", { children: o }),
|
|
1056
|
-
/* @__PURE__ */ n(
|
|
1193
|
+
/* @__PURE__ */ n(G, { onClick: e, label: "Close dialog" })
|
|
1057
1194
|
]
|
|
1058
1195
|
}
|
|
1059
1196
|
),
|
|
1060
|
-
|
|
1061
|
-
] }) : /* @__PURE__ */
|
|
1062
|
-
/* @__PURE__ */
|
|
1197
|
+
l
|
|
1198
|
+
] }) : /* @__PURE__ */ m(F, { children: [
|
|
1199
|
+
/* @__PURE__ */ m(L.Header, { className: w(
|
|
1063
1200
|
"tw:sticky tw:top-0",
|
|
1064
1201
|
"tw:flex tw:items-center tw:justify-between tw:gap-x-2"
|
|
1065
1202
|
), children: [
|
|
1066
1203
|
/* @__PURE__ */ n("h5", { className: w({ "tw:text-danger": t === "danger" }), children: o }),
|
|
1067
|
-
/* @__PURE__ */ n(
|
|
1204
|
+
/* @__PURE__ */ n(G, { onClick: e, label: "Close dialog" })
|
|
1068
1205
|
] }),
|
|
1069
|
-
/* @__PURE__ */ n(
|
|
1070
|
-
|
|
1071
|
-
|
|
1206
|
+
/* @__PURE__ */ n(L.Body, { children: l }),
|
|
1207
|
+
u && /* @__PURE__ */ m(
|
|
1208
|
+
L.Footer,
|
|
1072
1209
|
{
|
|
1073
1210
|
"data-testid": "footer",
|
|
1074
1211
|
className: w(
|
|
@@ -1076,13 +1213,13 @@ const Ae = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
|
1076
1213
|
"tw:[&]:px-3 tw:sticky tw:bottom-0"
|
|
1077
1214
|
),
|
|
1078
1215
|
children: [
|
|
1079
|
-
/* @__PURE__ */ n(
|
|
1216
|
+
/* @__PURE__ */ n(pe, { onClick: e, children: c }),
|
|
1080
1217
|
/* @__PURE__ */ n(
|
|
1081
|
-
|
|
1218
|
+
zt,
|
|
1082
1219
|
{
|
|
1083
1220
|
solid: !0,
|
|
1084
1221
|
variant: t === "danger" ? "danger" : "primary",
|
|
1085
|
-
disabled:
|
|
1222
|
+
disabled: f,
|
|
1086
1223
|
type: "submit",
|
|
1087
1224
|
children: s
|
|
1088
1225
|
}
|
|
@@ -1095,19 +1232,19 @@ const Ae = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
|
1095
1232
|
)
|
|
1096
1233
|
}
|
|
1097
1234
|
);
|
|
1098
|
-
},
|
|
1235
|
+
}, Ye = ({ className: r, children: e, loading: t = !1, variant: o = "default" }) => /* @__PURE__ */ n(Kt, { className: y({ "tw:[&]:border-danger": o === "error" }, r), children: /* @__PURE__ */ m("h3", { className: y("tw:text-center", {
|
|
1099
1236
|
"tw:text-gray-500 tw:dark:text-gray-400": o === "default",
|
|
1100
1237
|
"tw:text-danger": o === "error"
|
|
1101
1238
|
}), children: [
|
|
1102
|
-
t && /* @__PURE__ */
|
|
1103
|
-
/* @__PURE__ */ n(
|
|
1239
|
+
t && /* @__PURE__ */ m(F, { children: [
|
|
1240
|
+
/* @__PURE__ */ n(C, { icon: at, spin: !0 }),
|
|
1104
1241
|
/* @__PURE__ */ n("span", { className: "tw:ml-2", children: e ?? "Loading..." })
|
|
1105
1242
|
] }),
|
|
1106
1243
|
!t && e
|
|
1107
|
-
] }) }),
|
|
1244
|
+
] }) }), Ze = ({ variant: r, className: e, size: t = "md", children: o }) => /* @__PURE__ */ n(
|
|
1108
1245
|
"div",
|
|
1109
1246
|
{
|
|
1110
|
-
className:
|
|
1247
|
+
className: y(
|
|
1111
1248
|
"tw:rounded-md tw:text-center",
|
|
1112
1249
|
{
|
|
1113
1250
|
"tw:p-2": t === "sm",
|
|
@@ -1122,47 +1259,47 @@ const Ae = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
|
1122
1259
|
),
|
|
1123
1260
|
children: o
|
|
1124
1261
|
}
|
|
1125
|
-
),
|
|
1126
|
-
const e =
|
|
1127
|
-
const
|
|
1128
|
-
return r === "auto" &&
|
|
1129
|
-
})(), [o,
|
|
1262
|
+
), ze = ({ placement: r = "auto" } = {}) => {
|
|
1263
|
+
const e = P(null), t = (() => {
|
|
1264
|
+
const b = [];
|
|
1265
|
+
return r === "auto" && b.push(Bt()), b.push(At({ element: e })), b;
|
|
1266
|
+
})(), [o, l] = M(!1), { refs: a, floatingStyles: d, context: i, middlewareData: s } = lt({
|
|
1130
1267
|
placement: r === "auto" ? void 0 : r,
|
|
1131
1268
|
open: o,
|
|
1132
|
-
onOpenChange:
|
|
1269
|
+
onOpenChange: l,
|
|
1133
1270
|
middleware: t
|
|
1134
|
-
}), c =
|
|
1271
|
+
}), c = Tt(i, {
|
|
1135
1272
|
delay: { open: 300 },
|
|
1136
1273
|
move: !0
|
|
1137
|
-
}), { getFloatingProps:
|
|
1138
|
-
const
|
|
1274
|
+
}), { getFloatingProps: f, getReferenceProps: u } = dt([c]), { isMounted: p, styles: k } = _t(i, { duration: 200 }), x = K(() => {
|
|
1275
|
+
const b = i.placement.split("-")[0];
|
|
1139
1276
|
return {
|
|
1140
1277
|
top: "bottom",
|
|
1141
1278
|
right: "left",
|
|
1142
1279
|
bottom: "top",
|
|
1143
1280
|
left: "right"
|
|
1144
|
-
}[
|
|
1281
|
+
}[b] ?? "";
|
|
1145
1282
|
}, [i.placement]);
|
|
1146
1283
|
return {
|
|
1147
|
-
anchor: { ...
|
|
1284
|
+
anchor: { ...u(), ref: a.setReference },
|
|
1148
1285
|
tooltip: {
|
|
1149
|
-
...
|
|
1150
|
-
refSetter:
|
|
1151
|
-
isMounted:
|
|
1152
|
-
styles: { ...d, ...
|
|
1286
|
+
...f(),
|
|
1287
|
+
refSetter: a.setFloating,
|
|
1288
|
+
isMounted: p,
|
|
1289
|
+
styles: { ...d, ...k },
|
|
1153
1290
|
arrowPos: s.arrow,
|
|
1154
1291
|
arrowRef: e,
|
|
1155
|
-
arrowSide:
|
|
1292
|
+
arrowSide: x
|
|
1156
1293
|
}
|
|
1157
1294
|
};
|
|
1158
|
-
},
|
|
1295
|
+
}, Ve = ({ children: r, isMounted: e, styles: t, refSetter: o, arrowRef: l, arrowPos: a, arrowSide: d, ...i }) => {
|
|
1159
1296
|
var s;
|
|
1160
1297
|
return e && /* @__PURE__ */ n(
|
|
1161
1298
|
"div",
|
|
1162
1299
|
{
|
|
1163
1300
|
role: "tooltip",
|
|
1164
1301
|
"aria-live": "polite",
|
|
1165
|
-
className:
|
|
1302
|
+
className: y(
|
|
1166
1303
|
"tw:z-1000 tw:max-w-64",
|
|
1167
1304
|
// Add space between anchor and tooltip via padding, so that if the tooltip is inside the anchor, you can hover it
|
|
1168
1305
|
// and it's never closed
|
|
@@ -1176,14 +1313,14 @@ const Ae = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
|
1176
1313
|
ref: o,
|
|
1177
1314
|
style: t,
|
|
1178
1315
|
...i,
|
|
1179
|
-
children: /* @__PURE__ */
|
|
1316
|
+
children: /* @__PURE__ */ m("div", { className: "tw:relative tw:px-1.5 tw:py-1 tw:rounded tw:bg-black/90 tw:text-white tw:text-center", children: [
|
|
1180
1317
|
/* @__PURE__ */ n("span", { className: "tw:sr-only", children: "Tooltip: " }),
|
|
1181
1318
|
r,
|
|
1182
1319
|
/* @__PURE__ */ n(
|
|
1183
1320
|
"div",
|
|
1184
1321
|
{
|
|
1185
|
-
ref:
|
|
1186
|
-
className:
|
|
1322
|
+
ref: l,
|
|
1323
|
+
className: y(
|
|
1187
1324
|
"tw:absolute",
|
|
1188
1325
|
// Render as a triangle
|
|
1189
1326
|
"tw:border-l-6 tw:border-r-6 tw:border-b-6 tw:border-l-transparent tw:border-r-transparent tw:border-b-black/90",
|
|
@@ -1195,9 +1332,9 @@ const Ae = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
|
1195
1332
|
}
|
|
1196
1333
|
),
|
|
1197
1334
|
style: {
|
|
1198
|
-
left:
|
|
1199
|
-
top:
|
|
1200
|
-
[d]: `${-(((s =
|
|
1335
|
+
left: a == null ? void 0 : a.x,
|
|
1336
|
+
top: a == null ? void 0 : a.y,
|
|
1337
|
+
[d]: `${-(((s = l.current) == null ? void 0 : s.offsetWidth) ?? 0) / 2}px`
|
|
1201
1338
|
},
|
|
1202
1339
|
"data-testid": "arrow"
|
|
1203
1340
|
}
|
|
@@ -1206,57 +1343,57 @@ const Ae = ({ currentPage: r, pagesCount: e, ...t }) => {
|
|
|
1206
1343
|
}
|
|
1207
1344
|
);
|
|
1208
1345
|
};
|
|
1209
|
-
function
|
|
1210
|
-
const d =
|
|
1211
|
-
const c =
|
|
1346
|
+
function tr({ items: r, order: e, onChange: t, prefixed: o = !0, buttonVariant: l = "button", ...a }) {
|
|
1347
|
+
const d = I((s) => {
|
|
1348
|
+
const c = Lt({ currentOrderDir: e.dir, currentField: e.field, newField: s });
|
|
1212
1349
|
t(c);
|
|
1213
|
-
}, [t, e.dir, e.field]), i =
|
|
1214
|
-
return /* @__PURE__ */
|
|
1215
|
-
|
|
1350
|
+
}, [t, e.dir, e.field]), i = l === "button";
|
|
1351
|
+
return /* @__PURE__ */ m(
|
|
1352
|
+
S,
|
|
1216
1353
|
{
|
|
1217
|
-
buttonContent: /* @__PURE__ */
|
|
1354
|
+
buttonContent: /* @__PURE__ */ m(F, { children: [
|
|
1218
1355
|
!i && "Order by",
|
|
1219
1356
|
i && !e.field && /* @__PURE__ */ n("i", { children: "Order by..." }),
|
|
1220
|
-
i && e.field && /* @__PURE__ */
|
|
1357
|
+
i && e.field && /* @__PURE__ */ m(F, { children: [
|
|
1221
1358
|
o && "Order by: ",
|
|
1222
1359
|
r[e.field],
|
|
1223
1360
|
" - ",
|
|
1224
1361
|
e.dir ?? "DESC"
|
|
1225
1362
|
] })
|
|
1226
1363
|
] }),
|
|
1227
|
-
buttonVariant:
|
|
1228
|
-
...
|
|
1364
|
+
buttonVariant: l,
|
|
1365
|
+
...a,
|
|
1229
1366
|
children: [
|
|
1230
|
-
Object.entries(r).map(([s, c]) => /* @__PURE__ */
|
|
1231
|
-
|
|
1367
|
+
Object.entries(r).map(([s, c]) => /* @__PURE__ */ m(
|
|
1368
|
+
S.Item,
|
|
1232
1369
|
{
|
|
1233
1370
|
selected: e.field === s,
|
|
1234
1371
|
onClick: () => d(s),
|
|
1235
|
-
className: "tw:flex tw:items-center tw:justify-between",
|
|
1372
|
+
className: "tw:flex tw:items-center tw:justify-between tw:gap-2",
|
|
1236
1373
|
children: [
|
|
1237
1374
|
c,
|
|
1238
|
-
e.field === s && /* @__PURE__ */ n(
|
|
1375
|
+
e.field === s && /* @__PURE__ */ n(C, { icon: e.dir === "ASC" ? vt : Nt })
|
|
1239
1376
|
]
|
|
1240
1377
|
},
|
|
1241
1378
|
s
|
|
1242
1379
|
)),
|
|
1243
|
-
/* @__PURE__ */ n(
|
|
1244
|
-
/* @__PURE__ */ n(
|
|
1380
|
+
/* @__PURE__ */ n(S.Separator, {}),
|
|
1381
|
+
/* @__PURE__ */ n(S.Item, { disabled: !e.field, onClick: () => t({}), children: /* @__PURE__ */ n("i", { children: "Clear selection" }) })
|
|
1245
1382
|
]
|
|
1246
1383
|
}
|
|
1247
1384
|
);
|
|
1248
1385
|
}
|
|
1249
|
-
const
|
|
1250
|
-
const [d, i] =
|
|
1251
|
-
() =>
|
|
1252
|
-
[
|
|
1386
|
+
const er = ({ text: r, className: e, size: t = "lg", initialCopied: o = !1, navigator_: l = globalThis.navigator, ...a }) => {
|
|
1387
|
+
const [d, i] = St(o), s = I(
|
|
1388
|
+
() => l.clipboard.writeText(r).then(i),
|
|
1389
|
+
[l.clipboard, r, i]
|
|
1253
1390
|
);
|
|
1254
1391
|
return /* @__PURE__ */ n(
|
|
1255
1392
|
"button",
|
|
1256
1393
|
{
|
|
1257
1394
|
type: "button",
|
|
1258
|
-
className:
|
|
1259
|
-
"tw:focus-ring tw:rounded-sm",
|
|
1395
|
+
className: y(
|
|
1396
|
+
"tw:focus-ring tw:rounded-sm tw:cursor-pointer",
|
|
1260
1397
|
{
|
|
1261
1398
|
"tw:text-md": t === "sm",
|
|
1262
1399
|
"tw:text-lg": t === "md",
|
|
@@ -1267,49 +1404,50 @@ const qe = ({ text: r, className: e, size: t = "lg", initialCopied: o = !1, navi
|
|
|
1267
1404
|
"aria-label": `Copy ${r} to clipboard`,
|
|
1268
1405
|
title: "Copy to clipboard",
|
|
1269
1406
|
onClick: s,
|
|
1270
|
-
...
|
|
1271
|
-
children: /* @__PURE__ */ n(
|
|
1407
|
+
...a,
|
|
1408
|
+
children: /* @__PURE__ */ n(C, { icon: d ? Ct : jt, fixedWidth: !0 })
|
|
1272
1409
|
}
|
|
1273
1410
|
);
|
|
1274
1411
|
};
|
|
1275
1412
|
export {
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1413
|
+
zt as Button,
|
|
1414
|
+
L as Card,
|
|
1415
|
+
Qe as CardModal,
|
|
1416
|
+
je as Checkbox,
|
|
1417
|
+
G as CloseButton,
|
|
1418
|
+
er as CopyToClipboardButton,
|
|
1419
|
+
_e as Details,
|
|
1420
|
+
S as Dropdown,
|
|
1284
1421
|
U as ELLIPSIS,
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
Ke as
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1422
|
+
Q as Input,
|
|
1423
|
+
Y as Label,
|
|
1424
|
+
Fe as LabelledInput,
|
|
1425
|
+
He as LabelledRevealablePasswordInput,
|
|
1426
|
+
We as LabelledSelect,
|
|
1427
|
+
pe as LinkButton,
|
|
1428
|
+
Gt as Listbox,
|
|
1429
|
+
$ as Menu,
|
|
1430
|
+
Ye as Message,
|
|
1431
|
+
Ie as ModalDialog,
|
|
1432
|
+
Ge as NavPills,
|
|
1433
|
+
tr as OrderingDropdown,
|
|
1434
|
+
Xe as Paginator,
|
|
1435
|
+
Ze as Result,
|
|
1436
|
+
Vt as RevealablePasswordInput,
|
|
1437
|
+
Je as RowDropdown,
|
|
1438
|
+
ne as SearchCombobox,
|
|
1439
|
+
ee as SearchInput,
|
|
1440
|
+
te as Select,
|
|
1441
|
+
Kt as SimpleCard,
|
|
1442
|
+
$e as Table,
|
|
1443
|
+
Ue as TagsAutocomplete,
|
|
1444
|
+
Ke as ToggleSwitch,
|
|
1445
|
+
Ve as Tooltip,
|
|
1446
|
+
he as formatNumber,
|
|
1447
|
+
ke as keyForPage,
|
|
1448
|
+
j as pageIsEllipsis,
|
|
1449
|
+
ye as prettifyPageNumber,
|
|
1450
|
+
xe as progressivePagination,
|
|
1451
|
+
qe as roundTen,
|
|
1452
|
+
ze as useTooltip
|
|
1315
1453
|
};
|