tempest-react-sdk 0.1.4 → 0.1.5
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 +52 -11
- package/dist/styles.css +1 -1
- package/dist/tempest-react-sdk.cjs +3 -3
- package/dist/tempest-react-sdk.cjs.map +1 -1
- package/dist/tempest-react-sdk.js +1151 -1078
- package/dist/tempest-react-sdk.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { jsxs as w, jsx as l, Fragment as
|
|
2
|
-
import { useState as v, useMemo as
|
|
3
|
-
import { createPortal as
|
|
1
|
+
import { jsxs as w, jsx as l, Fragment as ke } from "react/jsx-runtime";
|
|
2
|
+
import { useState as v, useMemo as B, Fragment as Re, forwardRef as W, useRef as E, useEffect as k, useId as ce, useContext as ne, createContext as re, cloneElement as Ye, useCallback as S, lazy as Ze, Component as Xe, useSyncExternalStore as Fe } from "react";
|
|
3
|
+
import { createPortal as xe } from "react-dom";
|
|
4
4
|
import { QueryClient as et, QueryClientProvider as tt } from "@tanstack/react-query";
|
|
5
5
|
import { create as nt } from "zustand";
|
|
6
6
|
import { persist as rt, createJSONStorage as st } from "zustand/middleware";
|
|
7
7
|
import ot from "dexie";
|
|
8
8
|
import { useForm as it } from "react-hook-form";
|
|
9
|
-
function
|
|
9
|
+
function g(...e) {
|
|
10
10
|
const t = [];
|
|
11
11
|
for (const n of e)
|
|
12
12
|
if (!(n == null || n === !1 || n === !0)) {
|
|
@@ -15,13 +15,13 @@ function _(...e) {
|
|
|
15
15
|
else if (typeof n == "number" || typeof n == "bigint")
|
|
16
16
|
t.push(String(n));
|
|
17
17
|
else if (Array.isArray(n)) {
|
|
18
|
-
const r =
|
|
18
|
+
const r = g(...n);
|
|
19
19
|
r && t.push(r);
|
|
20
20
|
}
|
|
21
21
|
}
|
|
22
22
|
return t.join(" ");
|
|
23
23
|
}
|
|
24
|
-
const at = "tempest_avatar_3xMuZ", ct = "tempest_image_ieqGp", lt = "tempest_xs_oSaLL", ut = "tempest_sm_sZ2bk", dt = "tempest_md_Fdkbz", pt = "tempest_lg_pTTUA", ft = "tempest_xl_mW58F", mt = "tempest_status_ISBnL", ht = "tempest_dot_Wgfo-",
|
|
24
|
+
const at = "tempest_avatar_3xMuZ", ct = "tempest_image_ieqGp", lt = "tempest_xs_oSaLL", ut = "tempest_sm_sZ2bk", dt = "tempest_md_Fdkbz", pt = "tempest_lg_pTTUA", ft = "tempest_xl_mW58F", mt = "tempest_status_ISBnL", ht = "tempest_dot_Wgfo-", _t = "tempest_online_-aWoW", gt = "tempest_offline_-StX3", yt = "tempest_busy_TbwuF", Z = {
|
|
25
25
|
avatar: at,
|
|
26
26
|
image: ct,
|
|
27
27
|
xs: lt,
|
|
@@ -31,15 +31,15 @@ const at = "tempest_avatar_3xMuZ", ct = "tempest_image_ieqGp", lt = "tempest_xs_
|
|
|
31
31
|
xl: ft,
|
|
32
32
|
status: mt,
|
|
33
33
|
dot: ht,
|
|
34
|
-
online:
|
|
35
|
-
offline:
|
|
34
|
+
online: _t,
|
|
35
|
+
offline: gt,
|
|
36
36
|
busy: yt
|
|
37
37
|
};
|
|
38
38
|
function wt(e) {
|
|
39
39
|
const t = e.trim().split(/\s+/).filter(Boolean);
|
|
40
40
|
return t.length === 0 ? "?" : t.length === 1 ? t[0].slice(0, 2) : `${t[0].charAt(0)}${t[t.length - 1].charAt(0)}`;
|
|
41
41
|
}
|
|
42
|
-
function
|
|
42
|
+
function xa({
|
|
43
43
|
src: e,
|
|
44
44
|
alt: t,
|
|
45
45
|
name: n = "",
|
|
@@ -48,16 +48,16 @@ function ta({
|
|
|
48
48
|
className: o,
|
|
49
49
|
onClick: i
|
|
50
50
|
}) {
|
|
51
|
-
const [c, a] = v(!1), u =
|
|
51
|
+
const [c, a] = v(!1), u = B(() => wt(n), [n]), d = e && !c, p = i ? "button" : void 0, f = i ? 0 : void 0;
|
|
52
52
|
return /* @__PURE__ */ w(
|
|
53
53
|
"span",
|
|
54
54
|
{
|
|
55
|
-
className:
|
|
55
|
+
className: g(Z.avatar, Z[r], s && Z.status, o),
|
|
56
56
|
role: p,
|
|
57
57
|
tabIndex: f,
|
|
58
58
|
onClick: i,
|
|
59
|
-
onKeyDown: i ? (
|
|
60
|
-
(
|
|
59
|
+
onKeyDown: i ? (h) => {
|
|
60
|
+
(h.key === "Enter" || h.key === " ") && (h.preventDefault(), i());
|
|
61
61
|
} : void 0,
|
|
62
62
|
children: [
|
|
63
63
|
d ? /* @__PURE__ */ l(
|
|
@@ -65,111 +65,158 @@ function ta({
|
|
|
65
65
|
{
|
|
66
66
|
src: e,
|
|
67
67
|
alt: t ?? n,
|
|
68
|
-
className:
|
|
68
|
+
className: Z.image,
|
|
69
69
|
onError: () => a(!0)
|
|
70
70
|
}
|
|
71
71
|
) : /* @__PURE__ */ l("span", { "aria-label": t ?? n, children: u }),
|
|
72
|
-
s && /* @__PURE__ */ l("span", { className:
|
|
72
|
+
s && /* @__PURE__ */ l("span", { className: g(Z.dot, Z[s]), "aria-hidden": !0 })
|
|
73
73
|
]
|
|
74
74
|
}
|
|
75
75
|
);
|
|
76
76
|
}
|
|
77
|
-
const bt = "tempest_badge_RsuMz", vt = "
|
|
77
|
+
const bt = "tempest_badge_RsuMz", vt = "tempest_sm_LYsCn", $t = "tempest_md_4Or8q", Nt = "tempest_lg_Bseje", kt = "tempest_square_l63D-", xt = "tempest_neutral_lulSm", St = "tempest_solid_0Leug", Et = "tempest_outline_x06HL", Tt = "tempest_success_u9JiS", Ct = "tempest_warning_nsGp-", Lt = "tempest_danger_PD2hz", It = "tempest_info_na6DQ", Dt = "tempest_primary_S0WCS", Mt = "tempest_dot_i0c-G", V = {
|
|
78
78
|
badge: bt,
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
79
|
+
sm: vt,
|
|
80
|
+
md: $t,
|
|
81
|
+
lg: Nt,
|
|
82
|
+
square: kt,
|
|
83
|
+
neutral: xt,
|
|
84
|
+
solid: St,
|
|
85
|
+
outline: Et,
|
|
86
|
+
success: Tt,
|
|
87
|
+
warning: Ct,
|
|
88
|
+
danger: Lt,
|
|
89
|
+
info: It,
|
|
90
|
+
primary: Dt,
|
|
91
|
+
dot: Mt
|
|
84
92
|
};
|
|
85
|
-
function
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
93
|
+
function Sa({
|
|
94
|
+
variant: e = "neutral",
|
|
95
|
+
appearance: t = "soft",
|
|
96
|
+
size: n = "md",
|
|
97
|
+
shape: r = "pill",
|
|
98
|
+
dot: s = !1,
|
|
99
|
+
className: o,
|
|
100
|
+
children: i,
|
|
101
|
+
...c
|
|
102
|
+
}) {
|
|
103
|
+
return /* @__PURE__ */ w(
|
|
104
|
+
"span",
|
|
105
|
+
{
|
|
106
|
+
className: g(
|
|
107
|
+
V.badge,
|
|
108
|
+
V[e],
|
|
109
|
+
t === "solid" && V.solid,
|
|
110
|
+
t === "outline" && V.outline,
|
|
111
|
+
V[n],
|
|
112
|
+
r === "square" && V.square,
|
|
113
|
+
o
|
|
114
|
+
),
|
|
115
|
+
...c,
|
|
116
|
+
children: [
|
|
117
|
+
s && /* @__PURE__ */ l("span", { className: V.dot, "aria-hidden": !0 }),
|
|
118
|
+
i
|
|
119
|
+
]
|
|
120
|
+
}
|
|
121
|
+
);
|
|
122
|
+
}
|
|
123
|
+
const Pt = "tempest_nav_H4g6P", At = "tempest_item_O4g3P", Rt = "tempest_link_7WM67", Ft = "tempest_current_JdlcS", Ot = "tempest_separator_zGWyJ", se = {
|
|
124
|
+
nav: Pt,
|
|
125
|
+
item: At,
|
|
126
|
+
link: Rt,
|
|
127
|
+
current: Ft,
|
|
128
|
+
separator: Ot
|
|
94
129
|
};
|
|
95
|
-
function
|
|
96
|
-
return /* @__PURE__ */ l("nav", { "aria-label": "breadcrumb", className:
|
|
130
|
+
function Ea({ items: e, separator: t = "/", className: n }) {
|
|
131
|
+
return /* @__PURE__ */ l("nav", { "aria-label": "breadcrumb", className: g(se.nav, n), children: e.map((r, s) => {
|
|
97
132
|
const o = s === e.length - 1, i = !o && (r.href || r.onClick);
|
|
98
133
|
return /* @__PURE__ */ w(Re, { children: [
|
|
99
|
-
/* @__PURE__ */ l("span", { className:
|
|
134
|
+
/* @__PURE__ */ l("span", { className: se.item, children: i ? /* @__PURE__ */ l(
|
|
100
135
|
"a",
|
|
101
136
|
{
|
|
102
137
|
href: r.href,
|
|
103
138
|
onClick: (c) => {
|
|
104
139
|
r.onClick && (c.preventDefault(), r.onClick());
|
|
105
140
|
},
|
|
106
|
-
className:
|
|
141
|
+
className: se.link,
|
|
107
142
|
children: r.label
|
|
108
143
|
}
|
|
109
144
|
) : /* @__PURE__ */ l(
|
|
110
145
|
"span",
|
|
111
146
|
{
|
|
112
147
|
"aria-current": o ? "page" : void 0,
|
|
113
|
-
className: o ?
|
|
148
|
+
className: o ? se.current : void 0,
|
|
114
149
|
children: r.label
|
|
115
150
|
}
|
|
116
151
|
) }),
|
|
117
|
-
!o && /* @__PURE__ */ l("span", { className:
|
|
152
|
+
!o && /* @__PURE__ */ l("span", { className: se.separator, "aria-hidden": !0, children: t })
|
|
118
153
|
] }, s);
|
|
119
154
|
}) });
|
|
120
155
|
}
|
|
121
|
-
const
|
|
122
|
-
button:
|
|
123
|
-
primary:
|
|
124
|
-
secondary:
|
|
125
|
-
danger:
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
156
|
+
const Wt = "tempest_button_2ZuB7", Bt = "tempest_primary_s1sM6", zt = "tempest_secondary_R0waJ", jt = "tempest_danger_V4fX8", Ut = "tempest_success_w6qB6", qt = "tempest_ghost_1KINV", Jt = "tempest_soft_c3kzm", Gt = "tempest_outline_F5jq-", Ht = "tempest_link_Zt5hw", Kt = "tempest_xs_cF6m0", Vt = "tempest_sm_NhG0g", Qt = "tempest_md_hH4h3", Yt = "tempest_lg_2plQf", Zt = "tempest_xl_nx4V0", Xt = "tempest_iconOnly_WCpTS", en = "tempest_pill_lx8lt", tn = "tempest_fullWidth_36oJT", nn = "tempest_loading_EQAt2", rn = "tempest_hiddenText_hIiJ2", sn = "tempest_spinner_ZExvW", on = "tempest_tempest-spin_UOSVC", z = {
|
|
157
|
+
button: Wt,
|
|
158
|
+
primary: Bt,
|
|
159
|
+
secondary: zt,
|
|
160
|
+
danger: jt,
|
|
161
|
+
success: Ut,
|
|
162
|
+
ghost: qt,
|
|
163
|
+
soft: Jt,
|
|
164
|
+
outline: Gt,
|
|
165
|
+
link: Ht,
|
|
166
|
+
xs: Kt,
|
|
167
|
+
sm: Vt,
|
|
168
|
+
md: Qt,
|
|
169
|
+
lg: Yt,
|
|
170
|
+
xl: Zt,
|
|
171
|
+
iconOnly: Xt,
|
|
172
|
+
pill: en,
|
|
173
|
+
fullWidth: tn,
|
|
174
|
+
loading: nn,
|
|
175
|
+
hiddenText: rn,
|
|
176
|
+
spinner: sn,
|
|
177
|
+
tempestSpin: on
|
|
135
178
|
};
|
|
136
|
-
function
|
|
179
|
+
function $e({
|
|
137
180
|
variant: e = "primary",
|
|
138
181
|
size: t = "md",
|
|
139
182
|
loading: n = !1,
|
|
140
183
|
fullWidth: r = !1,
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
184
|
+
iconOnly: s = !1,
|
|
185
|
+
pill: o = !1,
|
|
186
|
+
leftIcon: i,
|
|
187
|
+
rightIcon: c,
|
|
188
|
+
disabled: a,
|
|
189
|
+
className: u,
|
|
190
|
+
children: d,
|
|
191
|
+
...p
|
|
147
192
|
}) {
|
|
148
193
|
return /* @__PURE__ */ w(
|
|
149
194
|
"button",
|
|
150
195
|
{
|
|
151
|
-
className:
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
196
|
+
className: g(
|
|
197
|
+
z.button,
|
|
198
|
+
z[e],
|
|
199
|
+
z[t],
|
|
200
|
+
s && z.iconOnly,
|
|
201
|
+
o && z.pill,
|
|
202
|
+
n && z.loading,
|
|
203
|
+
r && z.fullWidth,
|
|
204
|
+
u
|
|
158
205
|
),
|
|
159
|
-
disabled:
|
|
160
|
-
...
|
|
206
|
+
disabled: a || n,
|
|
207
|
+
...p,
|
|
161
208
|
children: [
|
|
162
|
-
n && /* @__PURE__ */ l("span", { className:
|
|
163
|
-
/* @__PURE__ */ w("span", { className:
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
209
|
+
n && /* @__PURE__ */ l("span", { className: z.spinner, "aria-hidden": !0, children: /* @__PURE__ */ l(an, {}) }),
|
|
210
|
+
/* @__PURE__ */ w("span", { className: g(n && z.hiddenText), children: [
|
|
211
|
+
i,
|
|
212
|
+
d,
|
|
213
|
+
c
|
|
167
214
|
] })
|
|
168
215
|
]
|
|
169
216
|
}
|
|
170
217
|
);
|
|
171
218
|
}
|
|
172
|
-
function
|
|
219
|
+
function an() {
|
|
173
220
|
return /* @__PURE__ */ l(
|
|
174
221
|
"svg",
|
|
175
222
|
{
|
|
@@ -190,45 +237,66 @@ function Jt() {
|
|
|
190
237
|
}
|
|
191
238
|
);
|
|
192
239
|
}
|
|
193
|
-
const
|
|
194
|
-
card:
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
240
|
+
const cn = "tempest_card_Cb1o4", ln = "tempest_flat_LRpce", un = "tempest_raised_WmIqk", dn = "tempest_elevated_5VEDw", pn = "tempest_interactive_B8Tah", fn = "tempest_padded_oOxwN", mn = "tempest_flush_aiDZi", hn = "tempest_header_PTXf2", _n = "tempest_title_mSgoo", gn = "tempest_body_W441Z", yn = "tempest_footer_Mu-JC", R = {
|
|
241
|
+
card: cn,
|
|
242
|
+
flat: ln,
|
|
243
|
+
raised: un,
|
|
244
|
+
elevated: dn,
|
|
245
|
+
interactive: pn,
|
|
246
|
+
padded: fn,
|
|
247
|
+
flush: mn,
|
|
248
|
+
header: hn,
|
|
249
|
+
title: _n,
|
|
250
|
+
body: gn,
|
|
251
|
+
footer: yn
|
|
200
252
|
};
|
|
201
|
-
function
|
|
202
|
-
|
|
253
|
+
function Ta({
|
|
254
|
+
title: e,
|
|
255
|
+
actions: t,
|
|
256
|
+
footer: n,
|
|
257
|
+
flush: r = !1,
|
|
258
|
+
interactive: s = !1,
|
|
259
|
+
elevation: o = "default",
|
|
260
|
+
className: i,
|
|
261
|
+
children: c,
|
|
262
|
+
...a
|
|
263
|
+
}) {
|
|
264
|
+
const u = !!(e || t);
|
|
203
265
|
return /* @__PURE__ */ w(
|
|
204
266
|
"div",
|
|
205
267
|
{
|
|
206
|
-
className:
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
268
|
+
className: g(
|
|
269
|
+
R.card,
|
|
270
|
+
o === "flat" && R.flat,
|
|
271
|
+
o === "raised" && R.raised,
|
|
272
|
+
o === "elevated" && R.elevated,
|
|
273
|
+
s && R.interactive,
|
|
274
|
+
!u && !r && R.padded,
|
|
275
|
+
r && R.flush,
|
|
276
|
+
i
|
|
211
277
|
),
|
|
212
|
-
|
|
278
|
+
tabIndex: s ? a.tabIndex ?? 0 : a.tabIndex,
|
|
279
|
+
...a,
|
|
213
280
|
children: [
|
|
214
|
-
|
|
215
|
-
typeof e == "string" ? /* @__PURE__ */ l("h3", { className:
|
|
281
|
+
u && /* @__PURE__ */ w("header", { className: R.header, children: [
|
|
282
|
+
typeof e == "string" ? /* @__PURE__ */ l("h3", { className: R.title, children: e }) : e,
|
|
216
283
|
t
|
|
217
284
|
] }),
|
|
218
|
-
|
|
285
|
+
u ? /* @__PURE__ */ l("div", { className: R.body, children: c }) : c,
|
|
286
|
+
n && /* @__PURE__ */ l("footer", { className: R.footer, children: n })
|
|
219
287
|
]
|
|
220
288
|
}
|
|
221
289
|
);
|
|
222
290
|
}
|
|
223
|
-
const
|
|
224
|
-
wrapper:
|
|
225
|
-
disabled:
|
|
226
|
-
input:
|
|
227
|
-
box:
|
|
228
|
-
labelWrap:
|
|
229
|
-
label:
|
|
230
|
-
description:
|
|
231
|
-
},
|
|
291
|
+
const wn = "tempest_wrapper_rpthW", bn = "tempest_disabled_x7-eg", vn = "tempest_input_2kt-h", $n = "tempest_box_OCPee", Nn = "tempest_labelWrap_Ktbp0", kn = "tempest_label_cwRtI", xn = "tempest_description_rMhG1", Q = {
|
|
292
|
+
wrapper: wn,
|
|
293
|
+
disabled: bn,
|
|
294
|
+
input: vn,
|
|
295
|
+
box: $n,
|
|
296
|
+
labelWrap: Nn,
|
|
297
|
+
label: kn,
|
|
298
|
+
description: xn
|
|
299
|
+
}, Ca = W(function({ label: t, description: n, indeterminate: r, disabled: s, wrapperClassName: o, className: i, ...c }, a) {
|
|
232
300
|
const u = E(null);
|
|
233
301
|
k(() => {
|
|
234
302
|
u.current && (u.current.indeterminate = !!r);
|
|
@@ -236,25 +304,25 @@ const Yt = "tempest_wrapper_rpthW", Xt = "tempest_disabled_x7-eg", Zt = "tempest
|
|
|
236
304
|
function d(p) {
|
|
237
305
|
u.current = p, typeof a == "function" ? a(p) : a && (a.current = p);
|
|
238
306
|
}
|
|
239
|
-
return /* @__PURE__ */ w("label", { className:
|
|
307
|
+
return /* @__PURE__ */ w("label", { className: g(Q.wrapper, s && Q.disabled, o), children: [
|
|
240
308
|
/* @__PURE__ */ l(
|
|
241
309
|
"input",
|
|
242
310
|
{
|
|
243
311
|
ref: d,
|
|
244
312
|
type: "checkbox",
|
|
245
313
|
disabled: s,
|
|
246
|
-
className:
|
|
314
|
+
className: g(Q.input, i),
|
|
247
315
|
...c
|
|
248
316
|
}
|
|
249
317
|
),
|
|
250
|
-
/* @__PURE__ */ l("span", { className:
|
|
251
|
-
(t || n) && /* @__PURE__ */ w("span", { className:
|
|
252
|
-
t && /* @__PURE__ */ l("span", { className:
|
|
253
|
-
n && /* @__PURE__ */ l("span", { className:
|
|
318
|
+
/* @__PURE__ */ l("span", { className: Q.box, "aria-hidden": !0, children: r ? /* @__PURE__ */ l(En, {}) : /* @__PURE__ */ l(Sn, {}) }),
|
|
319
|
+
(t || n) && /* @__PURE__ */ w("span", { className: Q.labelWrap, children: [
|
|
320
|
+
t && /* @__PURE__ */ l("span", { className: Q.label, children: t }),
|
|
321
|
+
n && /* @__PURE__ */ l("span", { className: Q.description, children: n })
|
|
254
322
|
] })
|
|
255
323
|
] });
|
|
256
324
|
});
|
|
257
|
-
function
|
|
325
|
+
function Sn() {
|
|
258
326
|
return /* @__PURE__ */ l("svg", { width: "12", height: "12", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ l(
|
|
259
327
|
"path",
|
|
260
328
|
{
|
|
@@ -266,21 +334,21 @@ function sn() {
|
|
|
266
334
|
}
|
|
267
335
|
) });
|
|
268
336
|
}
|
|
269
|
-
function
|
|
337
|
+
function En() {
|
|
270
338
|
return /* @__PURE__ */ l("svg", { width: "12", height: "12", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ l("path", { d: "M5 12h14", stroke: "currentColor", strokeWidth: "3", strokeLinecap: "round" }) });
|
|
271
339
|
}
|
|
272
|
-
const
|
|
273
|
-
wrapper:
|
|
274
|
-
label:
|
|
275
|
-
field:
|
|
276
|
-
error:
|
|
277
|
-
chip:
|
|
278
|
-
remove:
|
|
279
|
-
input:
|
|
280
|
-
helper:
|
|
281
|
-
errorText:
|
|
340
|
+
const Tn = "tempest_wrapper_KR4-F", Cn = "tempest_label_Mz-wX", Ln = "tempest_field_iIBJw", In = "tempest_error_O9n-9", Dn = "tempest_chip_GEwrc", Mn = "tempest_remove_JYDIq", Pn = "tempest_input_frJmk", An = "tempest_helper_Yts53", Rn = "tempest_errorText_llJGq", j = {
|
|
341
|
+
wrapper: Tn,
|
|
342
|
+
label: Cn,
|
|
343
|
+
field: Ln,
|
|
344
|
+
error: In,
|
|
345
|
+
chip: Dn,
|
|
346
|
+
remove: Mn,
|
|
347
|
+
input: Pn,
|
|
348
|
+
helper: An,
|
|
349
|
+
errorText: Rn
|
|
282
350
|
};
|
|
283
|
-
function
|
|
351
|
+
function La({
|
|
284
352
|
value: e,
|
|
285
353
|
onChange: t,
|
|
286
354
|
label: n,
|
|
@@ -293,74 +361,74 @@ function ia({
|
|
|
293
361
|
}) {
|
|
294
362
|
const [u, d] = v(""), p = E(null);
|
|
295
363
|
function f() {
|
|
296
|
-
const
|
|
297
|
-
if (
|
|
298
|
-
if (e.includes(
|
|
364
|
+
const m = c ? u.trim().toLowerCase() : u.trim();
|
|
365
|
+
if (m) {
|
|
366
|
+
if (e.includes(m)) {
|
|
299
367
|
d("");
|
|
300
368
|
return;
|
|
301
369
|
}
|
|
302
|
-
t([...e,
|
|
370
|
+
t([...e, m]), d("");
|
|
303
371
|
}
|
|
304
372
|
}
|
|
305
|
-
function m
|
|
306
|
-
if (i.includes(
|
|
307
|
-
|
|
373
|
+
function h(m) {
|
|
374
|
+
if (i.includes(m.key)) {
|
|
375
|
+
m.preventDefault(), f();
|
|
308
376
|
return;
|
|
309
377
|
}
|
|
310
|
-
|
|
378
|
+
m.key === "Backspace" && !u && e.length > 0 && t(e.slice(0, -1));
|
|
311
379
|
}
|
|
312
|
-
function
|
|
380
|
+
function _(m) {
|
|
313
381
|
const b = e.slice();
|
|
314
|
-
b.splice(
|
|
382
|
+
b.splice(m, 1), t(b);
|
|
315
383
|
}
|
|
316
|
-
return /* @__PURE__ */ w("div", { className:
|
|
317
|
-
n && /* @__PURE__ */ l("label", { className:
|
|
318
|
-
/* @__PURE__ */ w("div", { className:
|
|
319
|
-
e.map((
|
|
320
|
-
|
|
384
|
+
return /* @__PURE__ */ w("div", { className: g(j.wrapper, o && j.error, a), children: [
|
|
385
|
+
n && /* @__PURE__ */ l("label", { className: j.label, children: n }),
|
|
386
|
+
/* @__PURE__ */ w("div", { className: j.field, onClick: () => p.current?.focus(), children: [
|
|
387
|
+
e.map((m, b) => /* @__PURE__ */ w("span", { className: j.chip, children: [
|
|
388
|
+
m,
|
|
321
389
|
/* @__PURE__ */ l(
|
|
322
390
|
"button",
|
|
323
391
|
{
|
|
324
392
|
type: "button",
|
|
325
|
-
className:
|
|
326
|
-
"aria-label": `Remover ${
|
|
327
|
-
onClick: () =>
|
|
393
|
+
className: j.remove,
|
|
394
|
+
"aria-label": `Remover ${m}`,
|
|
395
|
+
onClick: () => _(b),
|
|
328
396
|
children: "×"
|
|
329
397
|
}
|
|
330
398
|
)
|
|
331
|
-
] }, `${
|
|
399
|
+
] }, `${m}-${b}`)),
|
|
332
400
|
/* @__PURE__ */ l(
|
|
333
401
|
"input",
|
|
334
402
|
{
|
|
335
403
|
ref: p,
|
|
336
|
-
className:
|
|
404
|
+
className: j.input,
|
|
337
405
|
value: u,
|
|
338
406
|
placeholder: e.length === 0 ? r : "",
|
|
339
|
-
onChange: (
|
|
340
|
-
onKeyDown:
|
|
407
|
+
onChange: (m) => d(m.target.value),
|
|
408
|
+
onKeyDown: h,
|
|
341
409
|
onBlur: f
|
|
342
410
|
}
|
|
343
411
|
)
|
|
344
412
|
] }),
|
|
345
|
-
o ? /* @__PURE__ */ l("span", { className:
|
|
413
|
+
o ? /* @__PURE__ */ l("span", { className: j.errorText, children: o }) : s ? /* @__PURE__ */ l("span", { className: j.helper, children: s }) : null
|
|
346
414
|
] });
|
|
347
415
|
}
|
|
348
|
-
const
|
|
349
|
-
overlay:
|
|
350
|
-
tempestFadeIn:
|
|
351
|
-
dialog:
|
|
352
|
-
tempestModalIn:
|
|
353
|
-
sm:
|
|
354
|
-
md:
|
|
355
|
-
lg:
|
|
356
|
-
xl:
|
|
357
|
-
header:
|
|
358
|
-
title:
|
|
359
|
-
close:
|
|
360
|
-
body:
|
|
361
|
-
footer:
|
|
416
|
+
const Fn = "tempest_overlay_dd9h1", On = "tempest_tempest-fade-in_DvgSp", Wn = "tempest_dialog_ptM-K", Bn = "tempest_tempest-modal-in_UoxQC", zn = "tempest_sm_K5k3W", jn = "tempest_md_gvyR7", Un = "tempest_lg_BgB1a", qn = "tempest_xl_MR-68", Jn = "tempest_header_ILG9i", Gn = "tempest_title_A5OeE", Hn = "tempest_close_-ER1C", Kn = "tempest_body_lVhql", Vn = "tempest_footer_rro2w", G = {
|
|
417
|
+
overlay: Fn,
|
|
418
|
+
tempestFadeIn: On,
|
|
419
|
+
dialog: Wn,
|
|
420
|
+
tempestModalIn: Bn,
|
|
421
|
+
sm: zn,
|
|
422
|
+
md: jn,
|
|
423
|
+
lg: Un,
|
|
424
|
+
xl: qn,
|
|
425
|
+
header: Jn,
|
|
426
|
+
title: Gn,
|
|
427
|
+
close: Hn,
|
|
428
|
+
body: Kn,
|
|
429
|
+
footer: Vn
|
|
362
430
|
};
|
|
363
|
-
function
|
|
431
|
+
function Qn({
|
|
364
432
|
open: e,
|
|
365
433
|
onClose: t,
|
|
366
434
|
title: n,
|
|
@@ -382,11 +450,11 @@ function Cn({
|
|
|
382
450
|
return window.addEventListener("keydown", p), () => {
|
|
383
451
|
document.body.style.overflow = d, window.removeEventListener("keydown", p);
|
|
384
452
|
};
|
|
385
|
-
}, [e, c, t]), !e || typeof document > "u" ? null :
|
|
453
|
+
}, [e, c, t]), !e || typeof document > "u" ? null : xe(
|
|
386
454
|
/* @__PURE__ */ l(
|
|
387
455
|
"div",
|
|
388
456
|
{
|
|
389
|
-
className:
|
|
457
|
+
className: G.overlay,
|
|
390
458
|
role: "presentation",
|
|
391
459
|
onClick: () => {
|
|
392
460
|
i && t();
|
|
@@ -396,24 +464,24 @@ function Cn({
|
|
|
396
464
|
{
|
|
397
465
|
role: "dialog",
|
|
398
466
|
"aria-modal": "true",
|
|
399
|
-
className:
|
|
467
|
+
className: g(G.dialog, G[o], a),
|
|
400
468
|
onClick: (d) => d.stopPropagation(),
|
|
401
469
|
children: [
|
|
402
|
-
(n || !u) && /* @__PURE__ */ w("header", { className:
|
|
403
|
-
/* @__PURE__ */ l("h3", { className:
|
|
470
|
+
(n || !u) && /* @__PURE__ */ w("header", { className: G.header, children: [
|
|
471
|
+
/* @__PURE__ */ l("h3", { className: G.title, children: n }),
|
|
404
472
|
!u && /* @__PURE__ */ l(
|
|
405
473
|
"button",
|
|
406
474
|
{
|
|
407
475
|
type: "button",
|
|
408
|
-
className:
|
|
476
|
+
className: G.close,
|
|
409
477
|
"aria-label": "Fechar",
|
|
410
478
|
onClick: t,
|
|
411
|
-
children: /* @__PURE__ */ l(
|
|
479
|
+
children: /* @__PURE__ */ l(Yn, {})
|
|
412
480
|
}
|
|
413
481
|
)
|
|
414
482
|
] }),
|
|
415
|
-
/* @__PURE__ */ l("div", { className:
|
|
416
|
-
s && /* @__PURE__ */ l("footer", { className:
|
|
483
|
+
/* @__PURE__ */ l("div", { className: G.body, children: r }),
|
|
484
|
+
s && /* @__PURE__ */ l("footer", { className: G.footer, children: s })
|
|
417
485
|
]
|
|
418
486
|
}
|
|
419
487
|
)
|
|
@@ -422,7 +490,7 @@ function Cn({
|
|
|
422
490
|
document.body
|
|
423
491
|
);
|
|
424
492
|
}
|
|
425
|
-
function
|
|
493
|
+
function Yn() {
|
|
426
494
|
return /* @__PURE__ */ l("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ l(
|
|
427
495
|
"path",
|
|
428
496
|
{
|
|
@@ -433,7 +501,7 @@ function Ln() {
|
|
|
433
501
|
}
|
|
434
502
|
) });
|
|
435
503
|
}
|
|
436
|
-
function
|
|
504
|
+
function Ia({
|
|
437
505
|
open: e,
|
|
438
506
|
title: t,
|
|
439
507
|
description: n,
|
|
@@ -445,15 +513,15 @@ function aa({
|
|
|
445
513
|
onCancel: a
|
|
446
514
|
}) {
|
|
447
515
|
return /* @__PURE__ */ l(
|
|
448
|
-
|
|
516
|
+
Qn,
|
|
449
517
|
{
|
|
450
518
|
open: e,
|
|
451
519
|
onClose: a,
|
|
452
520
|
title: t,
|
|
453
521
|
size: "sm",
|
|
454
|
-
footer: /* @__PURE__ */ w(
|
|
455
|
-
/* @__PURE__ */ l(
|
|
456
|
-
/* @__PURE__ */ l(
|
|
522
|
+
footer: /* @__PURE__ */ w(ke, { children: [
|
|
523
|
+
/* @__PURE__ */ l($e, { variant: "secondary", onClick: a, disabled: i, children: s }),
|
|
524
|
+
/* @__PURE__ */ l($e, { variant: o, loading: i, onClick: () => {
|
|
457
525
|
c();
|
|
458
526
|
}, children: r })
|
|
459
527
|
] }),
|
|
@@ -461,20 +529,23 @@ function aa({
|
|
|
461
529
|
}
|
|
462
530
|
);
|
|
463
531
|
}
|
|
464
|
-
const
|
|
465
|
-
wrapper:
|
|
466
|
-
label:
|
|
467
|
-
required:
|
|
468
|
-
field:
|
|
469
|
-
input:
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
532
|
+
const Zn = "tempest_wrapper_iHNUs", Xn = "tempest_label_-OEBL", er = "tempest_required_CTss-", tr = "tempest_field_65yGJ", nr = "tempest_input_WjT81", rr = "tempest_sizeSm_cgds6", sr = "tempest_sizeMd_EPFGy", or = "tempest_sizeLg_5Cq8k", ir = "tempest_hasLeftIcon_xYO-v", ar = "tempest_hasRightIcon_C7uyr", cr = "tempest_iconLeft_KrUhI", lr = "tempest_iconRight_Ssr47", ur = "tempest_error_VLISa", dr = "tempest_helper_7Vc-s", pr = "tempest_errorText_xz4xS", C = {
|
|
533
|
+
wrapper: Zn,
|
|
534
|
+
label: Xn,
|
|
535
|
+
required: er,
|
|
536
|
+
field: tr,
|
|
537
|
+
input: nr,
|
|
538
|
+
sizeSm: rr,
|
|
539
|
+
sizeMd: sr,
|
|
540
|
+
sizeLg: or,
|
|
541
|
+
hasLeftIcon: ir,
|
|
542
|
+
hasRightIcon: ar,
|
|
543
|
+
iconLeft: cr,
|
|
544
|
+
iconRight: lr,
|
|
545
|
+
error: ur,
|
|
546
|
+
helper: dr,
|
|
547
|
+
errorText: pr
|
|
548
|
+
}, Se = W(function({
|
|
478
549
|
label: t,
|
|
479
550
|
helperText: n,
|
|
480
551
|
error: r,
|
|
@@ -484,40 +555,42 @@ const In = "tempest_wrapper_iHNUs", Dn = "tempest_label_-OEBL", Mn = "tempest_re
|
|
|
484
555
|
className: c,
|
|
485
556
|
id: a,
|
|
486
557
|
required: u,
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
558
|
+
size: d = "md",
|
|
559
|
+
...p
|
|
560
|
+
}, f) {
|
|
561
|
+
const h = ce(), _ = a ?? h, m = r ? `${_}-error` : n ? `${_}-helper` : void 0, b = d === "sm" ? C.sizeSm : d === "lg" ? C.sizeLg : C.sizeMd;
|
|
562
|
+
return /* @__PURE__ */ w("div", { className: g(C.wrapper, r && C.error, i), children: [
|
|
563
|
+
t && /* @__PURE__ */ w("label", { htmlFor: _, className: C.label, children: [
|
|
492
564
|
t,
|
|
493
|
-
u && /* @__PURE__ */ l("span", { className:
|
|
565
|
+
u && /* @__PURE__ */ l("span", { className: C.required, children: "*" })
|
|
494
566
|
] }),
|
|
495
|
-
/* @__PURE__ */ w("div", { className:
|
|
496
|
-
s && /* @__PURE__ */ l("span", { className:
|
|
567
|
+
/* @__PURE__ */ w("div", { className: C.field, children: [
|
|
568
|
+
s && /* @__PURE__ */ l("span", { className: C.iconLeft, children: s }),
|
|
497
569
|
/* @__PURE__ */ l(
|
|
498
570
|
"input",
|
|
499
571
|
{
|
|
500
|
-
ref:
|
|
501
|
-
id:
|
|
572
|
+
ref: f,
|
|
573
|
+
id: _,
|
|
502
574
|
"aria-invalid": !!r,
|
|
503
|
-
"aria-describedby":
|
|
575
|
+
"aria-describedby": m,
|
|
504
576
|
required: u,
|
|
505
|
-
className:
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
577
|
+
className: g(
|
|
578
|
+
C.input,
|
|
579
|
+
b,
|
|
580
|
+
s && C.hasLeftIcon,
|
|
581
|
+
o && C.hasRightIcon,
|
|
509
582
|
c
|
|
510
583
|
),
|
|
511
|
-
...
|
|
584
|
+
...p
|
|
512
585
|
}
|
|
513
586
|
),
|
|
514
|
-
o && /* @__PURE__ */ l("span", { className:
|
|
587
|
+
o && /* @__PURE__ */ l("span", { className: C.iconRight, children: o })
|
|
515
588
|
] }),
|
|
516
|
-
r ? /* @__PURE__ */ l("span", { id: `${
|
|
589
|
+
r ? /* @__PURE__ */ l("span", { id: `${_}-error`, className: C.errorText, children: r }) : n ? /* @__PURE__ */ l("span", { id: `${_}-helper`, className: C.helper, children: n }) : null
|
|
517
590
|
] });
|
|
518
|
-
}),
|
|
591
|
+
}), Da = W(function({ value: t, onChange: n, mode: r = "date", ...s }, o) {
|
|
519
592
|
return /* @__PURE__ */ l(
|
|
520
|
-
|
|
593
|
+
Se,
|
|
521
594
|
{
|
|
522
595
|
...s,
|
|
523
596
|
ref: o,
|
|
@@ -526,25 +599,25 @@ const In = "tempest_wrapper_iHNUs", Dn = "tempest_label_-OEBL", Mn = "tempest_re
|
|
|
526
599
|
onChange: (i) => n(i.target.value)
|
|
527
600
|
}
|
|
528
601
|
);
|
|
529
|
-
}),
|
|
530
|
-
overlay:
|
|
531
|
-
tempestDrawerOverlay:
|
|
532
|
-
panel:
|
|
533
|
-
right:
|
|
534
|
-
tempestDrawerInRight:
|
|
535
|
-
left:
|
|
536
|
-
tempestDrawerInLeft:
|
|
537
|
-
top:
|
|
538
|
-
tempestDrawerInTop:
|
|
539
|
-
bottom:
|
|
540
|
-
tempestDrawerInBottom:
|
|
541
|
-
header:
|
|
542
|
-
title:
|
|
543
|
-
close:
|
|
544
|
-
body:
|
|
545
|
-
footer:
|
|
602
|
+
}), fr = "tempest_overlay_hcG1G", mr = "tempest_tempest-drawer-overlay_XFbxY", hr = "tempest_panel_wUX0N", _r = "tempest_right_-oX-6", gr = "tempest_tempest-drawer-in-right_pWYHv", yr = "tempest_left_xi3nD", wr = "tempest_tempest-drawer-in-left_o7JSb", br = "tempest_top_7rGCn", vr = "tempest_tempest-drawer-in-top_kn6AF", $r = "tempest_bottom_zd-25", Nr = "tempest_tempest-drawer-in-bottom_0x3u7", kr = "tempest_header_sYoP1", xr = "tempest_title_LqUOu", Sr = "tempest_close_tYPhU", Er = "tempest_body_aV9FG", Tr = "tempest_footer_AuvUP", H = {
|
|
603
|
+
overlay: fr,
|
|
604
|
+
tempestDrawerOverlay: mr,
|
|
605
|
+
panel: hr,
|
|
606
|
+
right: _r,
|
|
607
|
+
tempestDrawerInRight: gr,
|
|
608
|
+
left: yr,
|
|
609
|
+
tempestDrawerInLeft: wr,
|
|
610
|
+
top: br,
|
|
611
|
+
tempestDrawerInTop: vr,
|
|
612
|
+
bottom: $r,
|
|
613
|
+
tempestDrawerInBottom: Nr,
|
|
614
|
+
header: kr,
|
|
615
|
+
title: xr,
|
|
616
|
+
close: Sr,
|
|
617
|
+
body: Er,
|
|
618
|
+
footer: Tr
|
|
546
619
|
};
|
|
547
|
-
function
|
|
620
|
+
function Ma({
|
|
548
621
|
open: e,
|
|
549
622
|
onClose: t,
|
|
550
623
|
placement: n = "right",
|
|
@@ -566,12 +639,12 @@ function la({
|
|
|
566
639
|
return window.addEventListener("keydown", p), () => {
|
|
567
640
|
document.body.style.overflow = d, window.removeEventListener("keydown", p);
|
|
568
641
|
};
|
|
569
|
-
}, [e, c, t]), !e || typeof document > "u" ? null :
|
|
570
|
-
/* @__PURE__ */ w(
|
|
642
|
+
}, [e, c, t]), !e || typeof document > "u" ? null : xe(
|
|
643
|
+
/* @__PURE__ */ w(ke, { children: [
|
|
571
644
|
/* @__PURE__ */ l(
|
|
572
645
|
"div",
|
|
573
646
|
{
|
|
574
|
-
className:
|
|
647
|
+
className: H.overlay,
|
|
575
648
|
onClick: () => {
|
|
576
649
|
i && t();
|
|
577
650
|
}
|
|
@@ -582,23 +655,23 @@ function la({
|
|
|
582
655
|
{
|
|
583
656
|
role: "dialog",
|
|
584
657
|
"aria-modal": "true",
|
|
585
|
-
className:
|
|
658
|
+
className: g(H.panel, H[n], u),
|
|
586
659
|
children: [
|
|
587
|
-
(r || !a) && /* @__PURE__ */ w("header", { className:
|
|
588
|
-
/* @__PURE__ */ l("h3", { className:
|
|
660
|
+
(r || !a) && /* @__PURE__ */ w("header", { className: H.header, children: [
|
|
661
|
+
/* @__PURE__ */ l("h3", { className: H.title, children: r }),
|
|
589
662
|
!a && /* @__PURE__ */ l(
|
|
590
663
|
"button",
|
|
591
664
|
{
|
|
592
665
|
type: "button",
|
|
593
666
|
"aria-label": "Fechar",
|
|
594
|
-
className:
|
|
667
|
+
className: H.close,
|
|
595
668
|
onClick: t,
|
|
596
|
-
children: /* @__PURE__ */ l(
|
|
669
|
+
children: /* @__PURE__ */ l(Cr, {})
|
|
597
670
|
}
|
|
598
671
|
)
|
|
599
672
|
] }),
|
|
600
|
-
/* @__PURE__ */ l("div", { className:
|
|
601
|
-
o && /* @__PURE__ */ l("footer", { className:
|
|
673
|
+
/* @__PURE__ */ l("div", { className: H.body, children: s }),
|
|
674
|
+
o && /* @__PURE__ */ l("footer", { className: H.footer, children: o })
|
|
602
675
|
]
|
|
603
676
|
}
|
|
604
677
|
)
|
|
@@ -606,7 +679,7 @@ function la({
|
|
|
606
679
|
document.body
|
|
607
680
|
);
|
|
608
681
|
}
|
|
609
|
-
function
|
|
682
|
+
function Cr() {
|
|
610
683
|
return /* @__PURE__ */ l("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ l(
|
|
611
684
|
"path",
|
|
612
685
|
{
|
|
@@ -617,29 +690,29 @@ function or() {
|
|
|
617
690
|
}
|
|
618
691
|
) });
|
|
619
692
|
}
|
|
620
|
-
const
|
|
621
|
-
wrapper:
|
|
622
|
-
icon:
|
|
623
|
-
title:
|
|
624
|
-
description:
|
|
625
|
-
action:
|
|
693
|
+
const Lr = "tempest_wrapper_gzyTd", Ir = "tempest_icon_qVCyh", Dr = "tempest_title_xPfUf", Mr = "tempest_description_oWwH1", Pr = "tempest_action_dqxw1", oe = {
|
|
694
|
+
wrapper: Lr,
|
|
695
|
+
icon: Ir,
|
|
696
|
+
title: Dr,
|
|
697
|
+
description: Mr,
|
|
698
|
+
action: Pr
|
|
626
699
|
};
|
|
627
|
-
function
|
|
628
|
-
return /* @__PURE__ */ w("div", { className:
|
|
629
|
-
e && /* @__PURE__ */ l("div", { className:
|
|
630
|
-
/* @__PURE__ */ l("h4", { className:
|
|
631
|
-
n && /* @__PURE__ */ l("p", { className:
|
|
632
|
-
r && /* @__PURE__ */ l("div", { className:
|
|
700
|
+
function Pa({ icon: e, title: t, description: n, action: r, className: s }) {
|
|
701
|
+
return /* @__PURE__ */ w("div", { className: g(oe.wrapper, s), children: [
|
|
702
|
+
e && /* @__PURE__ */ l("div", { className: oe.icon, children: e }),
|
|
703
|
+
/* @__PURE__ */ l("h4", { className: oe.title, children: t }),
|
|
704
|
+
n && /* @__PURE__ */ l("p", { className: oe.description, children: n }),
|
|
705
|
+
r && /* @__PURE__ */ l("div", { className: oe.action, children: r })
|
|
633
706
|
] });
|
|
634
707
|
}
|
|
635
|
-
const
|
|
636
|
-
wrapper:
|
|
637
|
-
icon:
|
|
638
|
-
title:
|
|
639
|
-
description:
|
|
640
|
-
action:
|
|
708
|
+
const Ar = "tempest_wrapper_luRyF", Rr = "tempest_icon_dEdBl", Fr = "tempest_title_StutD", Or = "tempest_description_A2XCb", Wr = "tempest_action_vm1LC", ie = {
|
|
709
|
+
wrapper: Ar,
|
|
710
|
+
icon: Rr,
|
|
711
|
+
title: Fr,
|
|
712
|
+
description: Or,
|
|
713
|
+
action: Wr
|
|
641
714
|
};
|
|
642
|
-
function
|
|
715
|
+
function Aa({
|
|
643
716
|
title: e = "Algo deu errado",
|
|
644
717
|
description: t = "Não foi possível carregar essas informações.",
|
|
645
718
|
onRetry: n,
|
|
@@ -647,14 +720,14 @@ function da({
|
|
|
647
720
|
icon: s,
|
|
648
721
|
className: o
|
|
649
722
|
}) {
|
|
650
|
-
return /* @__PURE__ */ w("div", { className:
|
|
651
|
-
/* @__PURE__ */ l("div", { className:
|
|
652
|
-
/* @__PURE__ */ l("h4", { className:
|
|
653
|
-
t && /* @__PURE__ */ l("p", { className:
|
|
654
|
-
n && /* @__PURE__ */ l("div", { className:
|
|
723
|
+
return /* @__PURE__ */ w("div", { className: g(ie.wrapper, o), children: [
|
|
724
|
+
/* @__PURE__ */ l("div", { className: ie.icon, children: s ?? /* @__PURE__ */ l(Br, {}) }),
|
|
725
|
+
/* @__PURE__ */ l("h4", { className: ie.title, children: e }),
|
|
726
|
+
t && /* @__PURE__ */ l("p", { className: ie.description, children: t }),
|
|
727
|
+
n && /* @__PURE__ */ l("div", { className: ie.action, children: /* @__PURE__ */ l($e, { variant: "secondary", onClick: n, children: r }) })
|
|
655
728
|
] });
|
|
656
729
|
}
|
|
657
|
-
function
|
|
730
|
+
function Br() {
|
|
658
731
|
return /* @__PURE__ */ l("svg", { width: "22", height: "22", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ l(
|
|
659
732
|
"path",
|
|
660
733
|
{
|
|
@@ -666,30 +739,30 @@ function gr() {
|
|
|
666
739
|
}
|
|
667
740
|
) });
|
|
668
741
|
}
|
|
669
|
-
const
|
|
670
|
-
wrapper:
|
|
671
|
-
label:
|
|
672
|
-
dropzone:
|
|
673
|
-
active:
|
|
674
|
-
disabled:
|
|
675
|
-
icon:
|
|
676
|
-
title:
|
|
677
|
-
subtitle:
|
|
678
|
-
files:
|
|
679
|
-
file:
|
|
680
|
-
fileMeta:
|
|
681
|
-
remove:
|
|
682
|
-
hidden:
|
|
742
|
+
const zr = "tempest_wrapper_E0qHs", jr = "tempest_label_lbMkx", Ur = "tempest_dropzone_jqua0", qr = "tempest_active_CG9Uk", Jr = "tempest_disabled_WNUUl", Gr = "tempest_icon_i9fGH", Hr = "tempest_title_bTVFl", Kr = "tempest_subtitle_S54OV", Vr = "tempest_files_WljYm", Qr = "tempest_file_Lp-dR", Yr = "tempest_fileMeta_LTnN2", Zr = "tempest_remove_jskra", Xr = "tempest_hidden_ReEq6", M = {
|
|
743
|
+
wrapper: zr,
|
|
744
|
+
label: jr,
|
|
745
|
+
dropzone: Ur,
|
|
746
|
+
active: qr,
|
|
747
|
+
disabled: Jr,
|
|
748
|
+
icon: Gr,
|
|
749
|
+
title: Hr,
|
|
750
|
+
subtitle: Kr,
|
|
751
|
+
files: Vr,
|
|
752
|
+
file: Qr,
|
|
753
|
+
fileMeta: Yr,
|
|
754
|
+
remove: Zr,
|
|
755
|
+
hidden: Xr
|
|
683
756
|
};
|
|
684
|
-
function
|
|
757
|
+
function es(e) {
|
|
685
758
|
return e < 1024 ? `${e} B` : e < 1024 * 1024 ? `${(e / 1024).toFixed(1)} KB` : `${(e / 1024 / 1024).toFixed(1)} MB`;
|
|
686
759
|
}
|
|
687
|
-
function
|
|
760
|
+
function ts(e, t) {
|
|
688
761
|
if (!t) return !0;
|
|
689
762
|
const n = t.split(",").map((o) => o.trim().toLowerCase()), r = e.name.toLowerCase(), s = e.type.toLowerCase();
|
|
690
763
|
return n.some((o) => o.startsWith(".") ? r.endsWith(o) : o.endsWith("/*") ? s.startsWith(o.replace("/*", "/")) : s === o);
|
|
691
764
|
}
|
|
692
|
-
function
|
|
765
|
+
function Ra({
|
|
693
766
|
value: e,
|
|
694
767
|
onChange: t,
|
|
695
768
|
label: n,
|
|
@@ -702,93 +775,93 @@ function pa({
|
|
|
702
775
|
subtitle: u,
|
|
703
776
|
className: d
|
|
704
777
|
}) {
|
|
705
|
-
const [p, f] = v(!1),
|
|
706
|
-
function
|
|
707
|
-
const
|
|
708
|
-
for (const
|
|
709
|
-
if (!
|
|
710
|
-
|
|
778
|
+
const [p, f] = v(!1), h = E(null);
|
|
779
|
+
function _(y) {
|
|
780
|
+
const $ = [], N = [];
|
|
781
|
+
for (const D of Array.from(y)) {
|
|
782
|
+
if (!ts(D, r)) {
|
|
783
|
+
N.push({ file: D, reason: "type" });
|
|
711
784
|
continue;
|
|
712
785
|
}
|
|
713
|
-
if (o &&
|
|
714
|
-
|
|
786
|
+
if (o && D.size > o) {
|
|
787
|
+
N.push({ file: D, reason: "size" });
|
|
715
788
|
continue;
|
|
716
789
|
}
|
|
717
|
-
|
|
790
|
+
$.push(D);
|
|
718
791
|
}
|
|
719
|
-
if (
|
|
720
|
-
const
|
|
721
|
-
t(
|
|
792
|
+
if (N.length > 0 && i?.(N), $.length === 0) return;
|
|
793
|
+
const L = s ? [...e, ...$] : $.slice(0, 1);
|
|
794
|
+
t(L);
|
|
722
795
|
}
|
|
723
|
-
function
|
|
724
|
-
y.preventDefault(), f(!1), !c && y.dataTransfer?.files &&
|
|
796
|
+
function m(y) {
|
|
797
|
+
y.preventDefault(), f(!1), !c && y.dataTransfer?.files && _(y.dataTransfer.files);
|
|
725
798
|
}
|
|
726
799
|
function b(y) {
|
|
727
|
-
const
|
|
728
|
-
|
|
800
|
+
const $ = e.slice();
|
|
801
|
+
$.splice(y, 1), t($);
|
|
729
802
|
}
|
|
730
|
-
return /* @__PURE__ */ w("div", { className:
|
|
731
|
-
n && /* @__PURE__ */ l("label", { className:
|
|
803
|
+
return /* @__PURE__ */ w("div", { className: g(M.wrapper, d), children: [
|
|
804
|
+
n && /* @__PURE__ */ l("label", { className: M.label, children: n }),
|
|
732
805
|
/* @__PURE__ */ w(
|
|
733
806
|
"div",
|
|
734
807
|
{
|
|
735
|
-
className:
|
|
736
|
-
|
|
737
|
-
p &&
|
|
738
|
-
c &&
|
|
808
|
+
className: g(
|
|
809
|
+
M.dropzone,
|
|
810
|
+
p && M.active,
|
|
811
|
+
c && M.disabled
|
|
739
812
|
),
|
|
740
813
|
role: "button",
|
|
741
814
|
tabIndex: c ? -1 : 0,
|
|
742
|
-
onClick: () => !c &&
|
|
815
|
+
onClick: () => !c && h.current?.click(),
|
|
743
816
|
onKeyDown: (y) => {
|
|
744
|
-
(y.key === "Enter" || y.key === " ") && (y.preventDefault(),
|
|
817
|
+
(y.key === "Enter" || y.key === " ") && (y.preventDefault(), h.current?.click());
|
|
745
818
|
},
|
|
746
819
|
onDragEnter: (y) => {
|
|
747
820
|
y.preventDefault(), c || f(!0);
|
|
748
821
|
},
|
|
749
822
|
onDragOver: (y) => y.preventDefault(),
|
|
750
823
|
onDragLeave: () => f(!1),
|
|
751
|
-
onDrop:
|
|
824
|
+
onDrop: m,
|
|
752
825
|
children: [
|
|
753
|
-
/* @__PURE__ */ l("div", { className:
|
|
754
|
-
/* @__PURE__ */ l("p", { className:
|
|
755
|
-
u && /* @__PURE__ */ l("p", { className:
|
|
826
|
+
/* @__PURE__ */ l("div", { className: M.icon, "aria-hidden": !0, children: /* @__PURE__ */ l(ns, {}) }),
|
|
827
|
+
/* @__PURE__ */ l("p", { className: M.title, children: a }),
|
|
828
|
+
u && /* @__PURE__ */ l("p", { className: M.subtitle, children: u }),
|
|
756
829
|
/* @__PURE__ */ l(
|
|
757
830
|
"input",
|
|
758
831
|
{
|
|
759
|
-
ref:
|
|
832
|
+
ref: h,
|
|
760
833
|
type: "file",
|
|
761
834
|
accept: r,
|
|
762
835
|
multiple: s,
|
|
763
836
|
disabled: c,
|
|
764
|
-
className:
|
|
837
|
+
className: M.hidden,
|
|
765
838
|
onChange: (y) => {
|
|
766
|
-
y.target.files &&
|
|
839
|
+
y.target.files && _(y.target.files), y.target.value = "";
|
|
767
840
|
}
|
|
768
841
|
}
|
|
769
842
|
)
|
|
770
843
|
]
|
|
771
844
|
}
|
|
772
845
|
),
|
|
773
|
-
e.length > 0 && /* @__PURE__ */ l("ul", { className:
|
|
846
|
+
e.length > 0 && /* @__PURE__ */ l("ul", { className: M.files, children: e.map((y, $) => /* @__PURE__ */ w("li", { className: M.file, children: [
|
|
774
847
|
/* @__PURE__ */ w("div", { children: [
|
|
775
848
|
/* @__PURE__ */ l("div", { children: y.name }),
|
|
776
|
-
/* @__PURE__ */ l("div", { className:
|
|
849
|
+
/* @__PURE__ */ l("div", { className: M.fileMeta, children: es(y.size) })
|
|
777
850
|
] }),
|
|
778
851
|
/* @__PURE__ */ l(
|
|
779
852
|
"button",
|
|
780
853
|
{
|
|
781
854
|
type: "button",
|
|
782
855
|
"aria-label": `Remover ${y.name}`,
|
|
783
|
-
className:
|
|
784
|
-
onClick: () => b(
|
|
856
|
+
className: M.remove,
|
|
857
|
+
onClick: () => b($),
|
|
785
858
|
children: "×"
|
|
786
859
|
}
|
|
787
860
|
)
|
|
788
|
-
] }, `${y.name}-${
|
|
861
|
+
] }, `${y.name}-${$}`)) })
|
|
789
862
|
] });
|
|
790
863
|
}
|
|
791
|
-
function
|
|
864
|
+
function ns() {
|
|
792
865
|
return /* @__PURE__ */ l("svg", { width: "32", height: "32", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ l(
|
|
793
866
|
"path",
|
|
794
867
|
{
|
|
@@ -800,32 +873,32 @@ function Dr() {
|
|
|
800
873
|
}
|
|
801
874
|
) });
|
|
802
875
|
}
|
|
803
|
-
const
|
|
804
|
-
form:
|
|
805
|
-
stack:
|
|
806
|
-
inline:
|
|
807
|
-
grid:
|
|
808
|
-
section:
|
|
809
|
-
sectionHeader:
|
|
810
|
-
sectionTitle:
|
|
811
|
-
sectionDescription:
|
|
812
|
-
sectionBody:
|
|
813
|
-
row:
|
|
814
|
-
actions:
|
|
815
|
-
start:
|
|
816
|
-
center:
|
|
817
|
-
end:
|
|
818
|
-
between:
|
|
876
|
+
const rs = "tempest_form_jNBDR", ss = "tempest_stack_O1Hl-", os = "tempest_inline_LBQAv", is = "tempest_grid_-B86T", as = "tempest_section_HGqw3", cs = "tempest_sectionHeader_ji9hQ", ls = "tempest_sectionTitle_GTPwe", us = "tempest_sectionDescription_KjW7k", ds = "tempest_sectionBody_Vp2wz", ps = "tempest_row_1EkVR", fs = "tempest_actions_hK95I", ms = "tempest_start_gXnm3", hs = "tempest_center_mKkz4", _s = "tempest_end_O3yDQ", gs = "tempest_between_tte2z", O = {
|
|
877
|
+
form: rs,
|
|
878
|
+
stack: ss,
|
|
879
|
+
inline: os,
|
|
880
|
+
grid: is,
|
|
881
|
+
section: as,
|
|
882
|
+
sectionHeader: cs,
|
|
883
|
+
sectionTitle: ls,
|
|
884
|
+
sectionDescription: us,
|
|
885
|
+
sectionBody: ds,
|
|
886
|
+
row: ps,
|
|
887
|
+
actions: fs,
|
|
888
|
+
start: ms,
|
|
889
|
+
center: hs,
|
|
890
|
+
end: _s,
|
|
891
|
+
between: gs
|
|
819
892
|
};
|
|
820
|
-
function
|
|
893
|
+
function pe(e, t) {
|
|
821
894
|
return e === void 0 ? `${t * 4}px` : typeof e == "number" ? `${e * 4}px` : e;
|
|
822
895
|
}
|
|
823
896
|
function Oe(e) {
|
|
824
897
|
return e === void 0 ? "repeat(2, minmax(0, 1fr))" : typeof e == "number" ? `repeat(${e}, minmax(0, 1fr))` : e;
|
|
825
898
|
}
|
|
826
|
-
const
|
|
899
|
+
const Fa = W(function({ layout: t = "stack", columns: n, gap: r, className: s, style: o, children: i, ...c }, a) {
|
|
827
900
|
const u = {
|
|
828
|
-
gap:
|
|
901
|
+
gap: pe(r, 4),
|
|
829
902
|
...t === "grid" ? { gridTemplateColumns: Oe(n) } : null,
|
|
830
903
|
...o
|
|
831
904
|
};
|
|
@@ -833,14 +906,14 @@ const fa = O(function({ layout: t = "stack", columns: n, gap: r, className: s, s
|
|
|
833
906
|
"form",
|
|
834
907
|
{
|
|
835
908
|
ref: a,
|
|
836
|
-
className:
|
|
909
|
+
className: g(O.form, O[t], s),
|
|
837
910
|
style: u,
|
|
838
911
|
...c,
|
|
839
912
|
children: i
|
|
840
913
|
}
|
|
841
914
|
);
|
|
842
915
|
});
|
|
843
|
-
function
|
|
916
|
+
function Oa({
|
|
844
917
|
title: e,
|
|
845
918
|
description: t,
|
|
846
919
|
layout: n = "stack",
|
|
@@ -852,22 +925,22 @@ function ma({
|
|
|
852
925
|
...a
|
|
853
926
|
}) {
|
|
854
927
|
const u = {
|
|
855
|
-
gap:
|
|
928
|
+
gap: pe(s, 4),
|
|
856
929
|
...n === "grid" ? { gridTemplateColumns: Oe(r) } : null
|
|
857
930
|
};
|
|
858
|
-
return /* @__PURE__ */ w("section", { className:
|
|
859
|
-
(e || t) && /* @__PURE__ */ w("header", { className:
|
|
860
|
-
e && /* @__PURE__ */ l("h3", { className:
|
|
861
|
-
t && /* @__PURE__ */ l("p", { className:
|
|
931
|
+
return /* @__PURE__ */ w("section", { className: g(O.section, o), style: i, ...a, children: [
|
|
932
|
+
(e || t) && /* @__PURE__ */ w("header", { className: O.sectionHeader, children: [
|
|
933
|
+
e && /* @__PURE__ */ l("h3", { className: O.sectionTitle, children: e }),
|
|
934
|
+
t && /* @__PURE__ */ l("p", { className: O.sectionDescription, children: t })
|
|
862
935
|
] }),
|
|
863
|
-
/* @__PURE__ */ l("div", { className:
|
|
936
|
+
/* @__PURE__ */ l("div", { className: g(O.sectionBody, O[n]), style: u, children: c })
|
|
864
937
|
] });
|
|
865
938
|
}
|
|
866
|
-
function
|
|
867
|
-
const o = { gap:
|
|
868
|
-
return /* @__PURE__ */ l("div", { className:
|
|
939
|
+
function Wa({ gap: e, className: t, style: n, children: r, ...s }) {
|
|
940
|
+
const o = { gap: pe(e, 3), ...n };
|
|
941
|
+
return /* @__PURE__ */ l("div", { className: g(O.row, t), style: o, ...s, children: r });
|
|
869
942
|
}
|
|
870
|
-
function
|
|
943
|
+
function Ba({
|
|
871
944
|
align: e = "end",
|
|
872
945
|
gap: t,
|
|
873
946
|
className: n,
|
|
@@ -875,34 +948,34 @@ function ga({
|
|
|
875
948
|
children: s,
|
|
876
949
|
...o
|
|
877
950
|
}) {
|
|
878
|
-
const i = { gap:
|
|
879
|
-
return /* @__PURE__ */ l("div", { className:
|
|
880
|
-
}
|
|
881
|
-
const
|
|
882
|
-
container:
|
|
883
|
-
sm:
|
|
884
|
-
md:
|
|
885
|
-
lg:
|
|
886
|
-
xl:
|
|
887
|
-
full:
|
|
888
|
-
stack:
|
|
889
|
-
vertical:
|
|
890
|
-
horizontal:
|
|
891
|
-
center:
|
|
892
|
-
start:
|
|
893
|
-
end:
|
|
894
|
-
stretch:
|
|
895
|
-
justifyStart:
|
|
896
|
-
justifyCenter:
|
|
897
|
-
justifyEnd:
|
|
898
|
-
justifyBetween:
|
|
899
|
-
wrap:
|
|
900
|
-
grid:
|
|
951
|
+
const i = { gap: pe(t, 2), ...r };
|
|
952
|
+
return /* @__PURE__ */ l("div", { className: g(O.actions, O[e], n), style: i, ...o, children: s });
|
|
953
|
+
}
|
|
954
|
+
const ys = "tempest_container_fJfOt", ws = "tempest_sm_k8D4-", bs = "tempest_md_EnpYy", vs = "tempest_lg_UU-Ig", $s = "tempest_xl_2TEWj", Ns = "tempest_full_l8bvG", ks = "tempest_stack_sxR8u", xs = "tempest_vertical_2TMf5", Ss = "tempest_horizontal_r7-c-", Es = "tempest_center_EDSAh", Ts = "tempest_start_ucQ-K", Cs = "tempest_end_pnKlF", Ls = "tempest_stretch_pX6l7", Is = "tempest_justifyStart_lHYsS", Ds = "tempest_justifyCenter_JH2m6", Ms = "tempest_justifyEnd_EBisT", Ps = "tempest_justifyBetween_mAJwT", As = "tempest_wrap_-xxOh", Rs = "tempest_grid_o-JIX", A = {
|
|
955
|
+
container: ys,
|
|
956
|
+
sm: ws,
|
|
957
|
+
md: bs,
|
|
958
|
+
lg: vs,
|
|
959
|
+
xl: $s,
|
|
960
|
+
full: Ns,
|
|
961
|
+
stack: ks,
|
|
962
|
+
vertical: xs,
|
|
963
|
+
horizontal: Ss,
|
|
964
|
+
center: Es,
|
|
965
|
+
start: Ts,
|
|
966
|
+
end: Cs,
|
|
967
|
+
stretch: Ls,
|
|
968
|
+
justifyStart: Is,
|
|
969
|
+
justifyCenter: Ds,
|
|
970
|
+
justifyEnd: Ms,
|
|
971
|
+
justifyBetween: Ps,
|
|
972
|
+
wrap: As,
|
|
973
|
+
grid: Rs
|
|
901
974
|
};
|
|
902
|
-
function
|
|
903
|
-
return /* @__PURE__ */ l("div", { className:
|
|
975
|
+
function za({ size: e = "lg", className: t, children: n, ...r }) {
|
|
976
|
+
return /* @__PURE__ */ l("div", { className: g(A.container, A[e], t), ...r, children: n });
|
|
904
977
|
}
|
|
905
|
-
function
|
|
978
|
+
function ja({
|
|
906
979
|
direction: e = "vertical",
|
|
907
980
|
gap: t = 2,
|
|
908
981
|
align: n,
|
|
@@ -917,7 +990,7 @@ function ya({
|
|
|
917
990
|
return /* @__PURE__ */ l(
|
|
918
991
|
"div",
|
|
919
992
|
{
|
|
920
|
-
className:
|
|
993
|
+
className: g(
|
|
921
994
|
A.stack,
|
|
922
995
|
e === "vertical" ? A.vertical : A.horizontal,
|
|
923
996
|
n && A[n],
|
|
@@ -931,27 +1004,27 @@ function ya({
|
|
|
931
1004
|
}
|
|
932
1005
|
);
|
|
933
1006
|
}
|
|
934
|
-
function
|
|
1007
|
+
function Ua({ columns: e = 2, gap: t = 4, className: n, style: r, children: s, ...o }) {
|
|
935
1008
|
const i = typeof e == "number" ? `repeat(${e}, minmax(0, 1fr))` : e, c = typeof t == "number" ? `${t * 4}px` : t;
|
|
936
1009
|
return /* @__PURE__ */ l(
|
|
937
1010
|
"div",
|
|
938
1011
|
{
|
|
939
|
-
className:
|
|
1012
|
+
className: g(A.grid, n),
|
|
940
1013
|
style: { gridTemplateColumns: i, gap: c, ...r },
|
|
941
1014
|
...o,
|
|
942
1015
|
children: s
|
|
943
1016
|
}
|
|
944
1017
|
);
|
|
945
1018
|
}
|
|
946
|
-
const
|
|
947
|
-
wrapper:
|
|
948
|
-
controls:
|
|
949
|
-
page:
|
|
950
|
-
active:
|
|
951
|
-
ellipsis:
|
|
952
|
-
sizeSelect:
|
|
1019
|
+
const Fs = "tempest_wrapper_cRGQm", Os = "tempest_controls_fdL-y", Ws = "tempest_page_WjG0l", Bs = "tempest_active_1kqsJ", zs = "tempest_ellipsis_V294k", js = "tempest_sizeSelect_ZayTo", K = {
|
|
1020
|
+
wrapper: Fs,
|
|
1021
|
+
controls: Os,
|
|
1022
|
+
page: Ws,
|
|
1023
|
+
active: Bs,
|
|
1024
|
+
ellipsis: zs,
|
|
1025
|
+
sizeSelect: js
|
|
953
1026
|
};
|
|
954
|
-
function
|
|
1027
|
+
function Us(e, t, n) {
|
|
955
1028
|
const r = n + 4;
|
|
956
1029
|
if (t <= r)
|
|
957
1030
|
return Array.from({ length: t }, (c, a) => a + 1);
|
|
@@ -960,7 +1033,7 @@ function ws(e, t, n) {
|
|
|
960
1033
|
for (let c = s; c <= o; c++) i.push(c);
|
|
961
1034
|
return o < t - 1 && i.push("..."), i.push(t), i;
|
|
962
1035
|
}
|
|
963
|
-
function
|
|
1036
|
+
function qa({
|
|
964
1037
|
page: e,
|
|
965
1038
|
totalPages: t,
|
|
966
1039
|
onPageChange: n,
|
|
@@ -971,18 +1044,18 @@ function ba({
|
|
|
971
1044
|
siblingCount: c = 3,
|
|
972
1045
|
className: a
|
|
973
1046
|
}) {
|
|
974
|
-
const u =
|
|
975
|
-
() =>
|
|
1047
|
+
const u = B(
|
|
1048
|
+
() => Us(e, t, c),
|
|
976
1049
|
[e, t, c]
|
|
977
1050
|
);
|
|
978
|
-
return t <= 1 && !s ? null : /* @__PURE__ */ w("div", { className:
|
|
1051
|
+
return t <= 1 && !s ? null : /* @__PURE__ */ w("div", { className: g(K.wrapper, a), children: [
|
|
979
1052
|
/* @__PURE__ */ l("div", { children: typeof i == "number" ? `${i} resultado${i === 1 ? "" : "s"}` : null }),
|
|
980
|
-
/* @__PURE__ */ w("div", { className:
|
|
1053
|
+
/* @__PURE__ */ w("div", { className: K.controls, children: [
|
|
981
1054
|
/* @__PURE__ */ l(
|
|
982
1055
|
"button",
|
|
983
1056
|
{
|
|
984
1057
|
type: "button",
|
|
985
|
-
className:
|
|
1058
|
+
className: K.page,
|
|
986
1059
|
onClick: () => n(Math.max(1, e - 1)),
|
|
987
1060
|
disabled: e <= 1,
|
|
988
1061
|
"aria-label": "Página anterior",
|
|
@@ -990,11 +1063,11 @@ function ba({
|
|
|
990
1063
|
}
|
|
991
1064
|
),
|
|
992
1065
|
u.map(
|
|
993
|
-
(d, p) => d === "..." ? /* @__PURE__ */ l("span", { className:
|
|
1066
|
+
(d, p) => d === "..." ? /* @__PURE__ */ l("span", { className: K.ellipsis, children: "…" }, `ellipsis-${p}`) : /* @__PURE__ */ l(
|
|
994
1067
|
"button",
|
|
995
1068
|
{
|
|
996
1069
|
type: "button",
|
|
997
|
-
className:
|
|
1070
|
+
className: g(K.page, d === e && K.active),
|
|
998
1071
|
onClick: () => n(d),
|
|
999
1072
|
"aria-current": d === e ? "page" : void 0,
|
|
1000
1073
|
children: d
|
|
@@ -1006,7 +1079,7 @@ function ba({
|
|
|
1006
1079
|
"button",
|
|
1007
1080
|
{
|
|
1008
1081
|
type: "button",
|
|
1009
|
-
className:
|
|
1082
|
+
className: K.page,
|
|
1010
1083
|
onClick: () => n(Math.min(t, e + 1)),
|
|
1011
1084
|
disabled: e >= t,
|
|
1012
1085
|
"aria-label": "Próxima página",
|
|
@@ -1016,7 +1089,7 @@ function ba({
|
|
|
1016
1089
|
s && /* @__PURE__ */ l(
|
|
1017
1090
|
"select",
|
|
1018
1091
|
{
|
|
1019
|
-
className:
|
|
1092
|
+
className: K.sizeSelect,
|
|
1020
1093
|
value: r,
|
|
1021
1094
|
onChange: (d) => s(Number(d.target.value)),
|
|
1022
1095
|
"aria-label": "Itens por página",
|
|
@@ -1029,18 +1102,18 @@ function ba({
|
|
|
1029
1102
|
] })
|
|
1030
1103
|
] });
|
|
1031
1104
|
}
|
|
1032
|
-
const
|
|
1033
|
-
wrapper:
|
|
1034
|
-
bar:
|
|
1035
|
-
fill:
|
|
1036
|
-
success:
|
|
1037
|
-
warning:
|
|
1038
|
-
danger:
|
|
1039
|
-
indeterminate:
|
|
1040
|
-
tempestProgressLoop:
|
|
1041
|
-
label:
|
|
1105
|
+
const qs = "tempest_wrapper_BQek1", Js = "tempest_bar_uC-0x", Gs = "tempest_fill_vmg7x", Hs = "tempest_success_gWJ8U", Ks = "tempest_warning_DGkPO", Vs = "tempest_danger_gfwHh", Qs = "tempest_indeterminate_HojUj", Ys = "tempest_tempest-progress-loop_0nEdF", Zs = "tempest_label_qqHJM", X = {
|
|
1106
|
+
wrapper: qs,
|
|
1107
|
+
bar: Js,
|
|
1108
|
+
fill: Gs,
|
|
1109
|
+
success: Hs,
|
|
1110
|
+
warning: Ks,
|
|
1111
|
+
danger: Vs,
|
|
1112
|
+
indeterminate: Qs,
|
|
1113
|
+
tempestProgressLoop: Ys,
|
|
1114
|
+
label: Zs
|
|
1042
1115
|
};
|
|
1043
|
-
function
|
|
1116
|
+
function Ja({
|
|
1044
1117
|
value: e = 0,
|
|
1045
1118
|
max: t = 100,
|
|
1046
1119
|
variant: n = "primary",
|
|
@@ -1050,7 +1123,7 @@ function va({
|
|
|
1050
1123
|
className: i
|
|
1051
1124
|
}) {
|
|
1052
1125
|
const c = r ? 0 : Math.max(0, Math.min(100, e / t * 100));
|
|
1053
|
-
return /* @__PURE__ */ w("div", { className:
|
|
1126
|
+
return /* @__PURE__ */ w("div", { className: g(X.wrapper, i), children: [
|
|
1054
1127
|
(s || o) && /* @__PURE__ */ w("div", { className: X.label, children: [
|
|
1055
1128
|
o && /* @__PURE__ */ l("span", { children: o }),
|
|
1056
1129
|
s && !r && /* @__PURE__ */ w("span", { children: [
|
|
@@ -1065,11 +1138,11 @@ function va({
|
|
|
1065
1138
|
"aria-valuemin": 0,
|
|
1066
1139
|
"aria-valuemax": t,
|
|
1067
1140
|
"aria-valuenow": r ? void 0 : e,
|
|
1068
|
-
className:
|
|
1141
|
+
className: g(X.bar, r && X.indeterminate),
|
|
1069
1142
|
children: /* @__PURE__ */ l(
|
|
1070
1143
|
"div",
|
|
1071
1144
|
{
|
|
1072
|
-
className:
|
|
1145
|
+
className: g(X.fill, n !== "primary" && X[n]),
|
|
1073
1146
|
style: { width: r ? void 0 : `${c}%` }
|
|
1074
1147
|
}
|
|
1075
1148
|
)
|
|
@@ -1077,17 +1150,17 @@ function va({
|
|
|
1077
1150
|
)
|
|
1078
1151
|
] });
|
|
1079
1152
|
}
|
|
1080
|
-
const
|
|
1081
|
-
wrapper:
|
|
1082
|
-
disabled:
|
|
1083
|
-
input:
|
|
1084
|
-
dot:
|
|
1085
|
-
labelWrap:
|
|
1086
|
-
label:
|
|
1087
|
-
description:
|
|
1088
|
-
group:
|
|
1089
|
-
horizontal:
|
|
1090
|
-
}, We =
|
|
1153
|
+
const Xs = "tempest_wrapper_P-gFm", eo = "tempest_disabled_0-cna", to = "tempest_input_7R8ZN", no = "tempest_dot_P7ejP", ro = "tempest_labelWrap_iQ1HR", so = "tempest_label_vAFIP", oo = "tempest_description_bEB8u", io = "tempest_group_oi329", ao = "tempest_horizontal_1Ovgu", J = {
|
|
1154
|
+
wrapper: Xs,
|
|
1155
|
+
disabled: eo,
|
|
1156
|
+
input: to,
|
|
1157
|
+
dot: no,
|
|
1158
|
+
labelWrap: ro,
|
|
1159
|
+
label: so,
|
|
1160
|
+
description: oo,
|
|
1161
|
+
group: io,
|
|
1162
|
+
horizontal: ao
|
|
1163
|
+
}, We = re(null), Ga = W(function({
|
|
1091
1164
|
label: t,
|
|
1092
1165
|
description: n,
|
|
1093
1166
|
value: r,
|
|
@@ -1099,39 +1172,39 @@ const Cs = "tempest_wrapper_P-gFm", Ls = "tempest_disabled_0-cna", Is = "tempest
|
|
|
1099
1172
|
className: u,
|
|
1100
1173
|
...d
|
|
1101
1174
|
}, p) {
|
|
1102
|
-
const f =
|
|
1175
|
+
const f = ne(We), h = f?.name ?? o, _ = f?.disabled ?? s, m = f ? f.value === r : i;
|
|
1103
1176
|
function b(y) {
|
|
1104
1177
|
f && f.onChange?.(r), c?.(y);
|
|
1105
1178
|
}
|
|
1106
1179
|
return /* @__PURE__ */ w(
|
|
1107
1180
|
"label",
|
|
1108
1181
|
{
|
|
1109
|
-
className:
|
|
1182
|
+
className: g(J.wrapper, _ && J.disabled, a),
|
|
1110
1183
|
children: [
|
|
1111
1184
|
/* @__PURE__ */ l(
|
|
1112
1185
|
"input",
|
|
1113
1186
|
{
|
|
1114
1187
|
ref: p,
|
|
1115
1188
|
type: "radio",
|
|
1116
|
-
name:
|
|
1189
|
+
name: h,
|
|
1117
1190
|
value: r,
|
|
1118
|
-
checked:
|
|
1119
|
-
disabled:
|
|
1191
|
+
checked: m,
|
|
1192
|
+
disabled: _,
|
|
1120
1193
|
onChange: b,
|
|
1121
|
-
className:
|
|
1194
|
+
className: g(J.input, u),
|
|
1122
1195
|
...d
|
|
1123
1196
|
}
|
|
1124
1197
|
),
|
|
1125
|
-
/* @__PURE__ */ l("span", { className:
|
|
1126
|
-
(t || n) && /* @__PURE__ */ w("span", { className:
|
|
1127
|
-
t && /* @__PURE__ */ l("span", { className:
|
|
1128
|
-
n && /* @__PURE__ */ l("span", { className:
|
|
1198
|
+
/* @__PURE__ */ l("span", { className: J.dot, "aria-hidden": !0 }),
|
|
1199
|
+
(t || n) && /* @__PURE__ */ w("span", { className: J.labelWrap, children: [
|
|
1200
|
+
t && /* @__PURE__ */ l("span", { className: J.label, children: t }),
|
|
1201
|
+
n && /* @__PURE__ */ l("span", { className: J.description, children: n })
|
|
1129
1202
|
] })
|
|
1130
1203
|
]
|
|
1131
1204
|
}
|
|
1132
1205
|
);
|
|
1133
1206
|
});
|
|
1134
|
-
function
|
|
1207
|
+
function Ha({
|
|
1135
1208
|
value: e,
|
|
1136
1209
|
defaultValue: t,
|
|
1137
1210
|
onChange: n,
|
|
@@ -1141,36 +1214,36 @@ function $a({
|
|
|
1141
1214
|
className: i,
|
|
1142
1215
|
children: c
|
|
1143
1216
|
}) {
|
|
1144
|
-
const a =
|
|
1145
|
-
function
|
|
1146
|
-
f || p(
|
|
1217
|
+
const a = ce(), u = r ?? a, [d, p] = v(t), f = e !== void 0, h = f ? e : d;
|
|
1218
|
+
function _(m) {
|
|
1219
|
+
f || p(m), n?.(m);
|
|
1147
1220
|
}
|
|
1148
1221
|
return /* @__PURE__ */ l(
|
|
1149
1222
|
We.Provider,
|
|
1150
1223
|
{
|
|
1151
|
-
value: { name: u, value:
|
|
1224
|
+
value: { name: u, value: h, onChange: _, disabled: s },
|
|
1152
1225
|
children: /* @__PURE__ */ l(
|
|
1153
1226
|
"div",
|
|
1154
1227
|
{
|
|
1155
1228
|
role: "radiogroup",
|
|
1156
|
-
className:
|
|
1229
|
+
className: g(J.group, o && J.horizontal, i),
|
|
1157
1230
|
children: c
|
|
1158
1231
|
}
|
|
1159
1232
|
)
|
|
1160
1233
|
}
|
|
1161
1234
|
);
|
|
1162
1235
|
}
|
|
1163
|
-
const
|
|
1164
|
-
wrapper:
|
|
1165
|
-
input:
|
|
1166
|
-
iconLeft:
|
|
1167
|
-
clear:
|
|
1168
|
-
},
|
|
1236
|
+
const co = "tempest_wrapper_dKXJJ", lo = "tempest_input_m0lPc", uo = "tempest_iconLeft_030-U", po = "tempest_clear_nb6lG", ue = {
|
|
1237
|
+
wrapper: co,
|
|
1238
|
+
input: lo,
|
|
1239
|
+
iconLeft: uo,
|
|
1240
|
+
clear: po
|
|
1241
|
+
}, Ka = W(function({ value: t, onChange: n, onClear: r, wrapperClassName: s, placeholder: o = "Buscar...", className: i, ...c }, a) {
|
|
1169
1242
|
function u() {
|
|
1170
1243
|
n(""), r?.();
|
|
1171
1244
|
}
|
|
1172
|
-
return /* @__PURE__ */ w("div", { className:
|
|
1173
|
-
/* @__PURE__ */ l("span", { className:
|
|
1245
|
+
return /* @__PURE__ */ w("div", { className: g(ue.wrapper, s), children: [
|
|
1246
|
+
/* @__PURE__ */ l("span", { className: ue.iconLeft, "aria-hidden": !0, children: /* @__PURE__ */ l(fo, {}) }),
|
|
1174
1247
|
/* @__PURE__ */ l(
|
|
1175
1248
|
"input",
|
|
1176
1249
|
{
|
|
@@ -1179,7 +1252,7 @@ const Os = "tempest_wrapper_dKXJJ", Ws = "tempest_input_m0lPc", Bs = "tempest_ic
|
|
|
1179
1252
|
value: t,
|
|
1180
1253
|
onChange: (d) => n(d.target.value),
|
|
1181
1254
|
placeholder: o,
|
|
1182
|
-
className:
|
|
1255
|
+
className: g(ue.input, i),
|
|
1183
1256
|
...c
|
|
1184
1257
|
}
|
|
1185
1258
|
),
|
|
@@ -1187,21 +1260,21 @@ const Os = "tempest_wrapper_dKXJJ", Ws = "tempest_input_m0lPc", Bs = "tempest_ic
|
|
|
1187
1260
|
"button",
|
|
1188
1261
|
{
|
|
1189
1262
|
type: "button",
|
|
1190
|
-
className:
|
|
1263
|
+
className: ue.clear,
|
|
1191
1264
|
"aria-label": "Limpar busca",
|
|
1192
1265
|
onClick: u,
|
|
1193
|
-
children: /* @__PURE__ */ l(
|
|
1266
|
+
children: /* @__PURE__ */ l(mo, {})
|
|
1194
1267
|
}
|
|
1195
1268
|
)
|
|
1196
1269
|
] });
|
|
1197
1270
|
});
|
|
1198
|
-
function
|
|
1271
|
+
function fo() {
|
|
1199
1272
|
return /* @__PURE__ */ w("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", children: [
|
|
1200
1273
|
/* @__PURE__ */ l("circle", { cx: "11", cy: "11", r: "7", stroke: "currentColor", strokeWidth: "2" }),
|
|
1201
1274
|
/* @__PURE__ */ l("path", { d: "M20 20l-3.5-3.5", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" })
|
|
1202
1275
|
] });
|
|
1203
1276
|
}
|
|
1204
|
-
function
|
|
1277
|
+
function mo() {
|
|
1205
1278
|
return /* @__PURE__ */ l("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ l(
|
|
1206
1279
|
"path",
|
|
1207
1280
|
{
|
|
@@ -1212,17 +1285,17 @@ function zs() {
|
|
|
1212
1285
|
}
|
|
1213
1286
|
) });
|
|
1214
1287
|
}
|
|
1215
|
-
const
|
|
1216
|
-
wrapper:
|
|
1217
|
-
label:
|
|
1218
|
-
required:
|
|
1219
|
-
field:
|
|
1220
|
-
select:
|
|
1221
|
-
caret:
|
|
1222
|
-
error:
|
|
1223
|
-
helper:
|
|
1224
|
-
errorText:
|
|
1225
|
-
},
|
|
1288
|
+
const ho = "tempest_wrapper_KS2K3", _o = "tempest_label_Lmgos", go = "tempest_required_PvDVJ", yo = "tempest_field_h-wBy", wo = "tempest_select_cjdcr", bo = "tempest_caret_MdCao", vo = "tempest_error_sw9MU", $o = "tempest_helper_frosK", No = "tempest_errorText_-zd6i", U = {
|
|
1289
|
+
wrapper: ho,
|
|
1290
|
+
label: _o,
|
|
1291
|
+
required: go,
|
|
1292
|
+
field: yo,
|
|
1293
|
+
select: wo,
|
|
1294
|
+
caret: bo,
|
|
1295
|
+
error: vo,
|
|
1296
|
+
helper: $o,
|
|
1297
|
+
errorText: No
|
|
1298
|
+
}, Va = W(function({
|
|
1226
1299
|
label: t,
|
|
1227
1300
|
helperText: n,
|
|
1228
1301
|
error: r,
|
|
@@ -1235,35 +1308,35 @@ const Js = "tempest_wrapper_KS2K3", Gs = "tempest_label_Lmgos", qs = "tempest_re
|
|
|
1235
1308
|
required: d,
|
|
1236
1309
|
...p
|
|
1237
1310
|
}, f) {
|
|
1238
|
-
const
|
|
1239
|
-
return /* @__PURE__ */ w("div", { className:
|
|
1240
|
-
t && /* @__PURE__ */ w("label", { htmlFor:
|
|
1311
|
+
const h = ce(), _ = u ?? h;
|
|
1312
|
+
return /* @__PURE__ */ w("div", { className: g(U.wrapper, r && U.error, i), children: [
|
|
1313
|
+
t && /* @__PURE__ */ w("label", { htmlFor: _, className: U.label, children: [
|
|
1241
1314
|
t,
|
|
1242
|
-
d && /* @__PURE__ */ l("span", { className:
|
|
1315
|
+
d && /* @__PURE__ */ l("span", { className: U.required, children: "*" })
|
|
1243
1316
|
] }),
|
|
1244
|
-
/* @__PURE__ */ w("div", { className:
|
|
1317
|
+
/* @__PURE__ */ w("div", { className: U.field, children: [
|
|
1245
1318
|
/* @__PURE__ */ w(
|
|
1246
1319
|
"select",
|
|
1247
1320
|
{
|
|
1248
1321
|
ref: f,
|
|
1249
|
-
id:
|
|
1322
|
+
id: _,
|
|
1250
1323
|
"aria-invalid": !!r,
|
|
1251
1324
|
required: d,
|
|
1252
|
-
className:
|
|
1325
|
+
className: g(U.select, c),
|
|
1253
1326
|
...p,
|
|
1254
1327
|
children: [
|
|
1255
1328
|
o && /* @__PURE__ */ l("option", { value: "", disabled: !0, hidden: !0, children: o }),
|
|
1256
|
-
s?.map((
|
|
1329
|
+
s?.map((m) => /* @__PURE__ */ l("option", { value: m.value, disabled: m.disabled, children: m.label }, m.value)),
|
|
1257
1330
|
a
|
|
1258
1331
|
]
|
|
1259
1332
|
}
|
|
1260
1333
|
),
|
|
1261
|
-
/* @__PURE__ */ l("span", { className:
|
|
1334
|
+
/* @__PURE__ */ l("span", { className: U.caret, "aria-hidden": !0, children: /* @__PURE__ */ l(ko, {}) })
|
|
1262
1335
|
] }),
|
|
1263
|
-
r ? /* @__PURE__ */ l("span", { className:
|
|
1336
|
+
r ? /* @__PURE__ */ l("span", { className: U.errorText, children: r }) : n ? /* @__PURE__ */ l("span", { className: U.helper, children: n }) : null
|
|
1264
1337
|
] });
|
|
1265
1338
|
});
|
|
1266
|
-
function
|
|
1339
|
+
function ko() {
|
|
1267
1340
|
return /* @__PURE__ */ l("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ l(
|
|
1268
1341
|
"path",
|
|
1269
1342
|
{
|
|
@@ -1275,17 +1348,17 @@ function Zs() {
|
|
|
1275
1348
|
}
|
|
1276
1349
|
) });
|
|
1277
1350
|
}
|
|
1278
|
-
const
|
|
1279
|
-
skeleton:
|
|
1280
|
-
text:
|
|
1281
|
-
circle:
|
|
1351
|
+
const xo = "tempest_skeleton_CB4uF", So = "tempest_text_-A8IF", Eo = "tempest_circle_DYcl8", ge = {
|
|
1352
|
+
skeleton: xo,
|
|
1353
|
+
text: So,
|
|
1354
|
+
circle: Eo
|
|
1282
1355
|
};
|
|
1283
|
-
function
|
|
1356
|
+
function Qa({ variant: e = "rect", width: t, height: n, className: r, style: s }) {
|
|
1284
1357
|
return /* @__PURE__ */ l(
|
|
1285
1358
|
"span",
|
|
1286
1359
|
{
|
|
1287
1360
|
"aria-hidden": !0,
|
|
1288
|
-
className:
|
|
1361
|
+
className: g(
|
|
1289
1362
|
ge.skeleton,
|
|
1290
1363
|
e === "text" && ge.text,
|
|
1291
1364
|
e === "circle" && ge.circle,
|
|
@@ -1295,60 +1368,60 @@ function Sa({ variant: e = "rect", width: t, height: n, className: r, style: s }
|
|
|
1295
1368
|
}
|
|
1296
1369
|
);
|
|
1297
1370
|
}
|
|
1298
|
-
const
|
|
1299
|
-
spinner:
|
|
1300
|
-
tempestSpinner:
|
|
1301
|
-
sm:
|
|
1302
|
-
md:
|
|
1303
|
-
lg:
|
|
1371
|
+
const To = "tempest_spinner_GpFZS", Co = "tempest_tempest-spinner_wKVCY", Lo = "tempest_sm_3sIoD", Io = "tempest_md_M2sPj", Do = "tempest_lg_IxTw2", Te = {
|
|
1372
|
+
spinner: To,
|
|
1373
|
+
tempestSpinner: Co,
|
|
1374
|
+
sm: Lo,
|
|
1375
|
+
md: Io,
|
|
1376
|
+
lg: Do
|
|
1304
1377
|
};
|
|
1305
|
-
function
|
|
1378
|
+
function Ya({ size: e = "md", className: t, label: n = "Carregando" }) {
|
|
1306
1379
|
return /* @__PURE__ */ l(
|
|
1307
1380
|
"span",
|
|
1308
1381
|
{
|
|
1309
1382
|
role: "status",
|
|
1310
1383
|
"aria-label": n,
|
|
1311
|
-
className:
|
|
1384
|
+
className: g(Te.spinner, Te[e], t)
|
|
1312
1385
|
}
|
|
1313
1386
|
);
|
|
1314
1387
|
}
|
|
1315
|
-
const
|
|
1316
|
-
stepper:
|
|
1317
|
-
vertical:
|
|
1318
|
-
step:
|
|
1319
|
-
dot:
|
|
1320
|
-
completed:
|
|
1321
|
-
active:
|
|
1322
|
-
label:
|
|
1323
|
-
connector:
|
|
1388
|
+
const Mo = "tempest_stepper_w3qjQ", Po = "tempest_vertical_d4mOs", Ao = "tempest_step_s2nqL", Ro = "tempest_dot_d1bSL", Fo = "tempest_completed_gcFHM", Oo = "tempest_active_kL-CH", Wo = "tempest_label_8irAI", Bo = "tempest_connector_lyeWp", q = {
|
|
1389
|
+
stepper: Mo,
|
|
1390
|
+
vertical: Po,
|
|
1391
|
+
step: Ao,
|
|
1392
|
+
dot: Ro,
|
|
1393
|
+
completed: Fo,
|
|
1394
|
+
active: Oo,
|
|
1395
|
+
label: Wo,
|
|
1396
|
+
connector: Bo
|
|
1324
1397
|
};
|
|
1325
|
-
function
|
|
1398
|
+
function Za({ steps: e, current: t, orientation: n = "horizontal", className: r }) {
|
|
1326
1399
|
return /* @__PURE__ */ l(
|
|
1327
1400
|
"ol",
|
|
1328
1401
|
{
|
|
1329
|
-
className:
|
|
1402
|
+
className: g(q.stepper, n === "vertical" && q.vertical, r),
|
|
1330
1403
|
children: e.map((s, o) => {
|
|
1331
1404
|
const i = o < t, c = o === t;
|
|
1332
1405
|
return /* @__PURE__ */ w(Re, { children: [
|
|
1333
1406
|
/* @__PURE__ */ w(
|
|
1334
1407
|
"li",
|
|
1335
1408
|
{
|
|
1336
|
-
className:
|
|
1337
|
-
|
|
1338
|
-
i &&
|
|
1339
|
-
c &&
|
|
1409
|
+
className: g(
|
|
1410
|
+
q.step,
|
|
1411
|
+
i && q.completed,
|
|
1412
|
+
c && q.active
|
|
1340
1413
|
),
|
|
1341
1414
|
"aria-current": c ? "step" : void 0,
|
|
1342
1415
|
children: [
|
|
1343
|
-
/* @__PURE__ */ l("span", { className:
|
|
1344
|
-
/* @__PURE__ */ l("span", { className:
|
|
1416
|
+
/* @__PURE__ */ l("span", { className: q.dot, children: i ? "✓" : o + 1 }),
|
|
1417
|
+
/* @__PURE__ */ l("span", { className: q.label, children: s.label })
|
|
1345
1418
|
]
|
|
1346
1419
|
}
|
|
1347
1420
|
),
|
|
1348
1421
|
o < e.length - 1 && /* @__PURE__ */ l(
|
|
1349
1422
|
"span",
|
|
1350
1423
|
{
|
|
1351
|
-
className:
|
|
1424
|
+
className: g(q.connector, i && q.completed),
|
|
1352
1425
|
"aria-hidden": !0
|
|
1353
1426
|
}
|
|
1354
1427
|
)
|
|
@@ -1357,15 +1430,15 @@ function Ta({ steps: e, current: t, orientation: n = "horizontal", className: r
|
|
|
1357
1430
|
}
|
|
1358
1431
|
);
|
|
1359
1432
|
}
|
|
1360
|
-
const
|
|
1361
|
-
wrapper:
|
|
1362
|
-
disabled:
|
|
1363
|
-
input:
|
|
1364
|
-
track:
|
|
1365
|
-
thumb:
|
|
1366
|
-
label:
|
|
1367
|
-
},
|
|
1368
|
-
return /* @__PURE__ */ w("label", { className:
|
|
1433
|
+
const zo = "tempest_wrapper_kudO9", jo = "tempest_disabled_2aZ0V", Uo = "tempest_input_5BPNu", qo = "tempest_track_7ObdZ", Jo = "tempest_thumb_-FTeK", Go = "tempest_label_LrH7V", ee = {
|
|
1434
|
+
wrapper: zo,
|
|
1435
|
+
disabled: jo,
|
|
1436
|
+
input: Uo,
|
|
1437
|
+
track: qo,
|
|
1438
|
+
thumb: Jo,
|
|
1439
|
+
label: Go
|
|
1440
|
+
}, Xa = W(function({ label: t, disabled: n, wrapperClassName: r, className: s, ...o }, i) {
|
|
1441
|
+
return /* @__PURE__ */ w("label", { className: g(ee.wrapper, n && ee.disabled, r), children: [
|
|
1369
1442
|
/* @__PURE__ */ l(
|
|
1370
1443
|
"input",
|
|
1371
1444
|
{
|
|
@@ -1373,25 +1446,25 @@ const _o = "tempest_wrapper_kudO9", yo = "tempest_disabled_2aZ0V", wo = "tempest
|
|
|
1373
1446
|
type: "checkbox",
|
|
1374
1447
|
role: "switch",
|
|
1375
1448
|
disabled: n,
|
|
1376
|
-
className:
|
|
1449
|
+
className: g(ee.input, s),
|
|
1377
1450
|
...o
|
|
1378
1451
|
}
|
|
1379
1452
|
),
|
|
1380
|
-
/* @__PURE__ */ l("span", { className:
|
|
1381
|
-
t && /* @__PURE__ */ l("span", { className:
|
|
1453
|
+
/* @__PURE__ */ l("span", { className: ee.track, "aria-hidden": !0, children: /* @__PURE__ */ l("span", { className: ee.thumb }) }),
|
|
1454
|
+
t && /* @__PURE__ */ l("span", { className: ee.label, children: t })
|
|
1382
1455
|
] });
|
|
1383
|
-
}),
|
|
1384
|
-
scroll:
|
|
1385
|
-
table:
|
|
1386
|
-
th:
|
|
1387
|
-
td:
|
|
1388
|
-
tr:
|
|
1389
|
-
clickable:
|
|
1390
|
-
alignRight:
|
|
1391
|
-
alignCenter:
|
|
1392
|
-
emptyRow:
|
|
1456
|
+
}), Ho = "tempest_scroll_unrJp", Ko = "tempest_table_Dkosn", Vo = "tempest_th_PNuEx", Qo = "tempest_td_jv9tA", Yo = "tempest_tr_7UG8J", Zo = "tempest_clickable_B6Si-", Xo = "tempest_alignRight_9hY0G", ei = "tempest_alignCenter_YiUQy", ti = "tempest_emptyRow_kdMiv", F = {
|
|
1457
|
+
scroll: Ho,
|
|
1458
|
+
table: Ko,
|
|
1459
|
+
th: Vo,
|
|
1460
|
+
td: Qo,
|
|
1461
|
+
tr: Yo,
|
|
1462
|
+
clickable: Zo,
|
|
1463
|
+
alignRight: Xo,
|
|
1464
|
+
alignCenter: ei,
|
|
1465
|
+
emptyRow: ti
|
|
1393
1466
|
};
|
|
1394
|
-
function
|
|
1467
|
+
function ec({
|
|
1395
1468
|
columns: e,
|
|
1396
1469
|
data: t,
|
|
1397
1470
|
rowKey: n,
|
|
@@ -1399,34 +1472,34 @@ function La({
|
|
|
1399
1472
|
emptyMessage: s = "Nenhum registro encontrado.",
|
|
1400
1473
|
className: o
|
|
1401
1474
|
}) {
|
|
1402
|
-
return /* @__PURE__ */ l("div", { className:
|
|
1475
|
+
return /* @__PURE__ */ l("div", { className: g(F.scroll, o), children: /* @__PURE__ */ w("table", { className: F.table, children: [
|
|
1403
1476
|
/* @__PURE__ */ l("thead", { children: /* @__PURE__ */ l("tr", { children: e.map((i) => /* @__PURE__ */ l(
|
|
1404
1477
|
"th",
|
|
1405
1478
|
{
|
|
1406
|
-
className:
|
|
1407
|
-
|
|
1408
|
-
i.align === "right" &&
|
|
1409
|
-
i.align === "center" &&
|
|
1479
|
+
className: g(
|
|
1480
|
+
F.th,
|
|
1481
|
+
i.align === "right" && F.alignRight,
|
|
1482
|
+
i.align === "center" && F.alignCenter
|
|
1410
1483
|
),
|
|
1411
1484
|
style: { width: i.width },
|
|
1412
1485
|
children: i.header
|
|
1413
1486
|
},
|
|
1414
1487
|
i.key
|
|
1415
1488
|
)) }) }),
|
|
1416
|
-
/* @__PURE__ */ l("tbody", { children: t.length === 0 ? /* @__PURE__ */ l("tr", { children: /* @__PURE__ */ l("td", { className:
|
|
1489
|
+
/* @__PURE__ */ l("tbody", { children: t.length === 0 ? /* @__PURE__ */ l("tr", { children: /* @__PURE__ */ l("td", { className: F.emptyRow, colSpan: e.length, children: s }) }) : t.map((i, c) => /* @__PURE__ */ l(
|
|
1417
1490
|
"tr",
|
|
1418
1491
|
{
|
|
1419
|
-
className:
|
|
1492
|
+
className: g(F.tr, r && F.clickable),
|
|
1420
1493
|
onClick: r ? () => r(i) : void 0,
|
|
1421
1494
|
children: e.map((a) => {
|
|
1422
1495
|
const u = a.render ? a.render(i, c) : i[a.key];
|
|
1423
1496
|
return /* @__PURE__ */ l(
|
|
1424
1497
|
"td",
|
|
1425
1498
|
{
|
|
1426
|
-
className:
|
|
1427
|
-
|
|
1428
|
-
a.align === "right" &&
|
|
1429
|
-
a.align === "center" &&
|
|
1499
|
+
className: g(
|
|
1500
|
+
F.td,
|
|
1501
|
+
a.align === "right" && F.alignRight,
|
|
1502
|
+
a.align === "center" && F.alignCenter,
|
|
1430
1503
|
a.className
|
|
1431
1504
|
),
|
|
1432
1505
|
children: u
|
|
@@ -1439,14 +1512,14 @@ function La({
|
|
|
1439
1512
|
)) })
|
|
1440
1513
|
] }) });
|
|
1441
1514
|
}
|
|
1442
|
-
const
|
|
1443
|
-
tablist:
|
|
1444
|
-
tab:
|
|
1445
|
-
active:
|
|
1446
|
-
panel:
|
|
1447
|
-
pill:
|
|
1515
|
+
const ni = "tempest_tablist_WR6ag", ri = "tempest_tab_IdDYc", si = "tempest_active_PTNtG", oi = "tempest_panel_08i9c", ii = "tempest_pill_lGuqn", ae = {
|
|
1516
|
+
tablist: ni,
|
|
1517
|
+
tab: ri,
|
|
1518
|
+
active: si,
|
|
1519
|
+
panel: oi,
|
|
1520
|
+
pill: ii
|
|
1448
1521
|
};
|
|
1449
|
-
function
|
|
1522
|
+
function tc({
|
|
1450
1523
|
items: e,
|
|
1451
1524
|
defaultId: t,
|
|
1452
1525
|
activeId: n,
|
|
@@ -1454,27 +1527,27 @@ function Ia({
|
|
|
1454
1527
|
variant: s = "underline",
|
|
1455
1528
|
className: o
|
|
1456
1529
|
}) {
|
|
1457
|
-
const i = e.find((
|
|
1458
|
-
function f(
|
|
1459
|
-
u || a(
|
|
1530
|
+
const i = e.find((h) => !h.disabled), [c, a] = v(t ?? i?.id), u = n !== void 0, d = u ? n : c, p = e.find((h) => h.id === d) ?? i;
|
|
1531
|
+
function f(h) {
|
|
1532
|
+
u || a(h), r?.(h);
|
|
1460
1533
|
}
|
|
1461
1534
|
return /* @__PURE__ */ w("div", { className: o, children: [
|
|
1462
|
-
/* @__PURE__ */ l("div", { role: "tablist", className:
|
|
1463
|
-
const
|
|
1535
|
+
/* @__PURE__ */ l("div", { role: "tablist", className: g(ae.tablist, s === "pill" && ae.pill), children: e.map((h) => {
|
|
1536
|
+
const _ = h.id === p?.id;
|
|
1464
1537
|
return /* @__PURE__ */ l(
|
|
1465
1538
|
"button",
|
|
1466
1539
|
{
|
|
1467
1540
|
type: "button",
|
|
1468
1541
|
role: "tab",
|
|
1469
|
-
"aria-selected":
|
|
1470
|
-
"aria-controls": `panel-${
|
|
1471
|
-
id: `tab-${
|
|
1472
|
-
disabled:
|
|
1473
|
-
className:
|
|
1474
|
-
onClick: () => f(
|
|
1475
|
-
children:
|
|
1542
|
+
"aria-selected": _,
|
|
1543
|
+
"aria-controls": `panel-${h.id}`,
|
|
1544
|
+
id: `tab-${h.id}`,
|
|
1545
|
+
disabled: h.disabled,
|
|
1546
|
+
className: g(ae.tab, _ && ae.active),
|
|
1547
|
+
onClick: () => f(h.id),
|
|
1548
|
+
children: h.label
|
|
1476
1549
|
},
|
|
1477
|
-
|
|
1550
|
+
h.id
|
|
1478
1551
|
);
|
|
1479
1552
|
}) }),
|
|
1480
1553
|
p && /* @__PURE__ */ l(
|
|
@@ -1483,26 +1556,26 @@ function Ia({
|
|
|
1483
1556
|
role: "tabpanel",
|
|
1484
1557
|
id: `panel-${p.id}`,
|
|
1485
1558
|
"aria-labelledby": `tab-${p.id}`,
|
|
1486
|
-
className:
|
|
1559
|
+
className: ae.panel,
|
|
1487
1560
|
children: p.content
|
|
1488
1561
|
}
|
|
1489
1562
|
)
|
|
1490
1563
|
] });
|
|
1491
1564
|
}
|
|
1492
|
-
const
|
|
1493
|
-
wrapper:
|
|
1494
|
-
label:
|
|
1495
|
-
required:
|
|
1496
|
-
textarea:
|
|
1497
|
-
error:
|
|
1498
|
-
helper:
|
|
1499
|
-
errorText:
|
|
1500
|
-
},
|
|
1501
|
-
const d =
|
|
1502
|
-
return /* @__PURE__ */ w("div", { className:
|
|
1503
|
-
t && /* @__PURE__ */ w("label", { htmlFor: p, className:
|
|
1565
|
+
const ai = "tempest_wrapper_C0gfg", ci = "tempest_label_cWLXP", li = "tempest_required_rDZXE", ui = "tempest_textarea_Z-y6g", di = "tempest_error_NWC9f", pi = "tempest_helper_gedut", fi = "tempest_errorText_ey07q", Y = {
|
|
1566
|
+
wrapper: ai,
|
|
1567
|
+
label: ci,
|
|
1568
|
+
required: li,
|
|
1569
|
+
textarea: ui,
|
|
1570
|
+
error: di,
|
|
1571
|
+
helper: pi,
|
|
1572
|
+
errorText: fi
|
|
1573
|
+
}, nc = W(function({ label: t, helperText: n, error: r, wrapperClassName: s, className: o, id: i, required: c, ...a }, u) {
|
|
1574
|
+
const d = ce(), p = i ?? d;
|
|
1575
|
+
return /* @__PURE__ */ w("div", { className: g(Y.wrapper, r && Y.error, s), children: [
|
|
1576
|
+
t && /* @__PURE__ */ w("label", { htmlFor: p, className: Y.label, children: [
|
|
1504
1577
|
t,
|
|
1505
|
-
c && /* @__PURE__ */ l("span", { className:
|
|
1578
|
+
c && /* @__PURE__ */ l("span", { className: Y.required, children: "*" })
|
|
1506
1579
|
] }),
|
|
1507
1580
|
/* @__PURE__ */ l(
|
|
1508
1581
|
"textarea",
|
|
@@ -1511,29 +1584,29 @@ const Fo = "tempest_wrapper_C0gfg", Oo = "tempest_label_cWLXP", Wo = "tempest_re
|
|
|
1511
1584
|
id: p,
|
|
1512
1585
|
"aria-invalid": !!r,
|
|
1513
1586
|
required: c,
|
|
1514
|
-
className:
|
|
1587
|
+
className: g(Y.textarea, o),
|
|
1515
1588
|
...a
|
|
1516
1589
|
}
|
|
1517
1590
|
),
|
|
1518
|
-
r ? /* @__PURE__ */ l("span", { className:
|
|
1591
|
+
r ? /* @__PURE__ */ l("span", { className: Y.errorText, children: r }) : n ? /* @__PURE__ */ l("span", { className: Y.helper, children: n }) : null
|
|
1519
1592
|
] });
|
|
1520
|
-
}),
|
|
1521
|
-
trigger:
|
|
1522
|
-
bubble:
|
|
1523
|
-
tempestTooltipIn:
|
|
1524
|
-
top:
|
|
1525
|
-
bottom:
|
|
1526
|
-
left:
|
|
1527
|
-
right:
|
|
1593
|
+
}), mi = "tempest_trigger_Dmc5E", hi = "tempest_bubble_TPGHB", _i = "tempest_tempest-tooltip-in_csYeZ", gi = "tempest_top_m2tnn", yi = "tempest_bottom_9Twz4", wi = "tempest_left_UPdrG", bi = "tempest_right_CV--T", ye = {
|
|
1594
|
+
trigger: mi,
|
|
1595
|
+
bubble: hi,
|
|
1596
|
+
tempestTooltipIn: _i,
|
|
1597
|
+
top: gi,
|
|
1598
|
+
bottom: yi,
|
|
1599
|
+
left: wi,
|
|
1600
|
+
right: bi
|
|
1528
1601
|
};
|
|
1529
|
-
function
|
|
1602
|
+
function rc({
|
|
1530
1603
|
content: e,
|
|
1531
1604
|
placement: t = "top",
|
|
1532
1605
|
children: n,
|
|
1533
1606
|
disabled: r = !1,
|
|
1534
1607
|
openDelay: s = 150
|
|
1535
1608
|
}) {
|
|
1536
|
-
const [o, i] = v(!1), c =
|
|
1609
|
+
const [o, i] = v(!1), c = ce();
|
|
1537
1610
|
let a = null;
|
|
1538
1611
|
function u() {
|
|
1539
1612
|
r || (a && clearTimeout(a), a = setTimeout(() => i(!0), s));
|
|
@@ -1548,37 +1621,37 @@ function Ma({
|
|
|
1548
1621
|
onBlur: d,
|
|
1549
1622
|
"aria-describedby": o ? c : void 0
|
|
1550
1623
|
});
|
|
1551
|
-
return /* @__PURE__ */ w("span", { className:
|
|
1624
|
+
return /* @__PURE__ */ w("span", { className: ye.trigger, children: [
|
|
1552
1625
|
p,
|
|
1553
1626
|
o && /* @__PURE__ */ l(
|
|
1554
1627
|
"span",
|
|
1555
1628
|
{
|
|
1556
1629
|
id: c,
|
|
1557
1630
|
role: "tooltip",
|
|
1558
|
-
className:
|
|
1631
|
+
className: g(ye.bubble, ye[t]),
|
|
1559
1632
|
children: e
|
|
1560
1633
|
}
|
|
1561
1634
|
)
|
|
1562
1635
|
] });
|
|
1563
1636
|
}
|
|
1564
|
-
const
|
|
1565
|
-
container:
|
|
1566
|
-
toast:
|
|
1567
|
-
tempestToastIn:
|
|
1568
|
-
success:
|
|
1569
|
-
warning:
|
|
1570
|
-
error:
|
|
1571
|
-
info:
|
|
1572
|
-
title:
|
|
1573
|
-
description:
|
|
1574
|
-
close:
|
|
1575
|
-
}, Be =
|
|
1576
|
-
function
|
|
1577
|
-
const e =
|
|
1637
|
+
const vi = "tempest_container_x4-Qm", $i = "tempest_toast_FLdHz", Ni = "tempest_tempest-toast-in_E2d-A", ki = "tempest_success_Oy694", xi = "tempest_warning_84GC8", Si = "tempest_error_hrQAA", Ei = "tempest_info_eq5bQ", Ti = "tempest_title_-H6R2", Ci = "tempest_description_-QwfC", Li = "tempest_close_i10-s", te = {
|
|
1638
|
+
container: vi,
|
|
1639
|
+
toast: $i,
|
|
1640
|
+
tempestToastIn: Ni,
|
|
1641
|
+
success: ki,
|
|
1642
|
+
warning: xi,
|
|
1643
|
+
error: Si,
|
|
1644
|
+
info: Ei,
|
|
1645
|
+
title: Ti,
|
|
1646
|
+
description: Ci,
|
|
1647
|
+
close: Li
|
|
1648
|
+
}, Be = re(null);
|
|
1649
|
+
function sc() {
|
|
1650
|
+
const e = ne(Be);
|
|
1578
1651
|
if (!e) throw new Error("useToast must be used inside a <ToastProvider>");
|
|
1579
1652
|
return e;
|
|
1580
1653
|
}
|
|
1581
|
-
function
|
|
1654
|
+
function oc({ children: e, defaultDuration: t = 4e3 }) {
|
|
1582
1655
|
const [n, r] = v([]), s = E(0), o = S((a) => {
|
|
1583
1656
|
r((u) => u.filter((d) => d.id !== a));
|
|
1584
1657
|
}, []), i = S(
|
|
@@ -1593,7 +1666,7 @@ function Aa({ children: e, defaultDuration: t = 4e3 }) {
|
|
|
1593
1666
|
return r((p) => [...p, d]), u;
|
|
1594
1667
|
},
|
|
1595
1668
|
[t]
|
|
1596
|
-
), c =
|
|
1669
|
+
), c = B(
|
|
1597
1670
|
() => ({
|
|
1598
1671
|
show: i,
|
|
1599
1672
|
dismiss: o,
|
|
@@ -1606,38 +1679,38 @@ function Aa({ children: e, defaultDuration: t = 4e3 }) {
|
|
|
1606
1679
|
);
|
|
1607
1680
|
return /* @__PURE__ */ w(Be.Provider, { value: c, children: [
|
|
1608
1681
|
e,
|
|
1609
|
-
/* @__PURE__ */ l(
|
|
1682
|
+
/* @__PURE__ */ l(Ii, { toasts: n, onDismiss: o })
|
|
1610
1683
|
] });
|
|
1611
1684
|
}
|
|
1612
|
-
function
|
|
1613
|
-
return typeof document > "u" ? null :
|
|
1614
|
-
/* @__PURE__ */ l("div", { className:
|
|
1685
|
+
function Ii({ toasts: e, onDismiss: t }) {
|
|
1686
|
+
return typeof document > "u" ? null : xe(
|
|
1687
|
+
/* @__PURE__ */ l("div", { className: te.container, "aria-live": "polite", "aria-atomic": "true", children: e.map((n) => /* @__PURE__ */ l(Di, { toast: n, onDismiss: t }, n.id)) }),
|
|
1615
1688
|
document.body
|
|
1616
1689
|
);
|
|
1617
1690
|
}
|
|
1618
|
-
function
|
|
1691
|
+
function Di({ toast: e, onDismiss: t }) {
|
|
1619
1692
|
return k(() => {
|
|
1620
1693
|
if (!e.duration) return;
|
|
1621
1694
|
const n = setTimeout(() => t(e.id), e.duration);
|
|
1622
1695
|
return () => clearTimeout(n);
|
|
1623
|
-
}, [e.id, e.duration, t]), /* @__PURE__ */ w("div", { className:
|
|
1696
|
+
}, [e.id, e.duration, t]), /* @__PURE__ */ w("div", { className: g(te.toast, te[e.variant]), role: "status", children: [
|
|
1624
1697
|
/* @__PURE__ */ w("div", { children: [
|
|
1625
|
-
e.title && /* @__PURE__ */ l("p", { className:
|
|
1626
|
-
e.description && /* @__PURE__ */ l("p", { className:
|
|
1698
|
+
e.title && /* @__PURE__ */ l("p", { className: te.title, children: e.title }),
|
|
1699
|
+
e.description && /* @__PURE__ */ l("p", { className: te.description, children: e.description })
|
|
1627
1700
|
] }),
|
|
1628
1701
|
/* @__PURE__ */ l(
|
|
1629
1702
|
"button",
|
|
1630
1703
|
{
|
|
1631
1704
|
type: "button",
|
|
1632
|
-
className:
|
|
1705
|
+
className: te.close,
|
|
1633
1706
|
"aria-label": "Fechar notificação",
|
|
1634
1707
|
onClick: () => t(e.id),
|
|
1635
|
-
children: /* @__PURE__ */ l(
|
|
1708
|
+
children: /* @__PURE__ */ l(Mi, {})
|
|
1636
1709
|
}
|
|
1637
1710
|
)
|
|
1638
1711
|
] });
|
|
1639
1712
|
}
|
|
1640
|
-
function
|
|
1713
|
+
function Mi() {
|
|
1641
1714
|
return /* @__PURE__ */ l("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ l(
|
|
1642
1715
|
"path",
|
|
1643
1716
|
{
|
|
@@ -1648,12 +1721,12 @@ function li() {
|
|
|
1648
1721
|
}
|
|
1649
1722
|
) });
|
|
1650
1723
|
}
|
|
1651
|
-
const
|
|
1652
|
-
scroll:
|
|
1653
|
-
spacer:
|
|
1654
|
-
row:
|
|
1724
|
+
const Pi = "tempest_scroll_8Giwl", Ai = "tempest_spacer_P3Pvl", Ri = "tempest_row_Ff0VU", we = {
|
|
1725
|
+
scroll: Pi,
|
|
1726
|
+
spacer: Ai,
|
|
1727
|
+
row: Ri
|
|
1655
1728
|
};
|
|
1656
|
-
function
|
|
1729
|
+
function ic({
|
|
1657
1730
|
items: e,
|
|
1658
1731
|
itemHeight: t,
|
|
1659
1732
|
renderItem: n,
|
|
@@ -1667,47 +1740,47 @@ function Ra({
|
|
|
1667
1740
|
k(() => {
|
|
1668
1741
|
const y = a.current;
|
|
1669
1742
|
if (!y || (f(y.clientHeight), typeof ResizeObserver > "u")) return;
|
|
1670
|
-
const
|
|
1671
|
-
return
|
|
1743
|
+
const $ = new ResizeObserver(() => f(y.clientHeight));
|
|
1744
|
+
return $.observe(y), () => $.disconnect();
|
|
1672
1745
|
}, []);
|
|
1673
|
-
const
|
|
1746
|
+
const h = e.length * t, _ = Math.max(0, Math.floor(u / t) - s), m = Math.ceil(p / t) + s * 2, b = Math.min(e.length, _ + m);
|
|
1674
1747
|
return /* @__PURE__ */ l(
|
|
1675
1748
|
"div",
|
|
1676
1749
|
{
|
|
1677
1750
|
ref: a,
|
|
1678
|
-
className:
|
|
1751
|
+
className: g(we.scroll, i),
|
|
1679
1752
|
style: { height: r, ...c },
|
|
1680
1753
|
onScroll: (y) => d(y.target.scrollTop),
|
|
1681
1754
|
role: "list",
|
|
1682
|
-
children: /* @__PURE__ */ l("div", { className:
|
|
1683
|
-
const
|
|
1755
|
+
children: /* @__PURE__ */ l("div", { className: we.spacer, style: { height: h }, children: e.slice(_, b).map((y, $) => {
|
|
1756
|
+
const N = _ + $, L = o ? o(y, N) : N;
|
|
1684
1757
|
return /* @__PURE__ */ l(
|
|
1685
1758
|
"div",
|
|
1686
1759
|
{
|
|
1687
1760
|
role: "listitem",
|
|
1688
|
-
className:
|
|
1689
|
-
style: { top:
|
|
1690
|
-
children: n(y,
|
|
1761
|
+
className: we.row,
|
|
1762
|
+
style: { top: N * t, height: t },
|
|
1763
|
+
children: n(y, N)
|
|
1691
1764
|
},
|
|
1692
|
-
|
|
1765
|
+
L
|
|
1693
1766
|
);
|
|
1694
1767
|
}) })
|
|
1695
1768
|
}
|
|
1696
1769
|
);
|
|
1697
1770
|
}
|
|
1698
|
-
function
|
|
1771
|
+
function ac(e, t = 300) {
|
|
1699
1772
|
const [n, r] = v(e);
|
|
1700
1773
|
return k(() => {
|
|
1701
1774
|
const s = setTimeout(() => r(e), t);
|
|
1702
1775
|
return () => clearTimeout(s);
|
|
1703
1776
|
}, [e, t]), n;
|
|
1704
1777
|
}
|
|
1705
|
-
function
|
|
1778
|
+
function cc(e = 1, t = 50) {
|
|
1706
1779
|
const [n, r] = v(e), [s, o] = v(t), i = S(() => r(1), []);
|
|
1707
1780
|
return { page: n, size: s, setPage: r, setSize: o, reset: i };
|
|
1708
1781
|
}
|
|
1709
|
-
function
|
|
1710
|
-
return
|
|
1782
|
+
function lc(e, t, n) {
|
|
1783
|
+
return B(() => {
|
|
1711
1784
|
const r = t.trim().toLowerCase();
|
|
1712
1785
|
return r ? typeof n == "function" ? e.filter((s) => n(s, r)) : e.filter(
|
|
1713
1786
|
(s) => n.some((o) => {
|
|
@@ -1717,7 +1790,7 @@ function Wa(e, t, n) {
|
|
|
1717
1790
|
) : e;
|
|
1718
1791
|
}, [e, t, n]);
|
|
1719
1792
|
}
|
|
1720
|
-
function
|
|
1793
|
+
function uc(e) {
|
|
1721
1794
|
const [t, n] = v(() => typeof window > "u" ? !1 : window.matchMedia(e).matches);
|
|
1722
1795
|
return k(() => {
|
|
1723
1796
|
if (typeof window > "u") return;
|
|
@@ -1725,7 +1798,7 @@ function Ba(e) {
|
|
|
1725
1798
|
return n(r.matches), r.addEventListener("change", s), () => r.removeEventListener("change", s);
|
|
1726
1799
|
}, [e]), t;
|
|
1727
1800
|
}
|
|
1728
|
-
function
|
|
1801
|
+
function dc() {
|
|
1729
1802
|
const [e, t] = v(
|
|
1730
1803
|
() => typeof navigator > "u" ? !0 : navigator.onLine
|
|
1731
1804
|
);
|
|
@@ -1737,7 +1810,7 @@ function ja() {
|
|
|
1737
1810
|
};
|
|
1738
1811
|
}, []), e;
|
|
1739
1812
|
}
|
|
1740
|
-
function
|
|
1813
|
+
function pc() {
|
|
1741
1814
|
const [e, t] = v(
|
|
1742
1815
|
() => typeof document > "u" ? "visible" : document.visibilityState
|
|
1743
1816
|
);
|
|
@@ -1747,7 +1820,7 @@ function Ua() {
|
|
|
1747
1820
|
return document.addEventListener("visibilitychange", n), () => document.removeEventListener("visibilitychange", n);
|
|
1748
1821
|
}, []), e;
|
|
1749
1822
|
}
|
|
1750
|
-
function
|
|
1823
|
+
function fc(e, t = {}) {
|
|
1751
1824
|
const [n, r] = v(null), { once: s = !1, root: o, rootMargin: i, threshold: c } = t;
|
|
1752
1825
|
return k(() => {
|
|
1753
1826
|
const a = e.current;
|
|
@@ -1761,7 +1834,7 @@ function za(e, t = {}) {
|
|
|
1761
1834
|
return u.observe(a), () => u.disconnect();
|
|
1762
1835
|
}, [e, s, o, i, c]), n;
|
|
1763
1836
|
}
|
|
1764
|
-
function
|
|
1837
|
+
function mc(e) {
|
|
1765
1838
|
const [t, n] = v(null);
|
|
1766
1839
|
return k(() => {
|
|
1767
1840
|
const r = e.current;
|
|
@@ -1775,7 +1848,7 @@ function Ja(e) {
|
|
|
1775
1848
|
return s.observe(r), () => s.disconnect();
|
|
1776
1849
|
}, [e]), t;
|
|
1777
1850
|
}
|
|
1778
|
-
function
|
|
1851
|
+
function hc(e = {}) {
|
|
1779
1852
|
const { resetAfter: t = 1500 } = e, [n, r] = v(!1), s = E(null), o = S(() => {
|
|
1780
1853
|
s.current && (clearTimeout(s.current), s.current = null), r(!1);
|
|
1781
1854
|
}, []);
|
|
@@ -1799,7 +1872,7 @@ function Ga(e = {}) {
|
|
|
1799
1872
|
);
|
|
1800
1873
|
return { copied: n, copy: i, reset: o };
|
|
1801
1874
|
}
|
|
1802
|
-
function
|
|
1875
|
+
function Fi(e, t) {
|
|
1803
1876
|
if (e.key.toLowerCase() !== t.key.toLowerCase()) return !1;
|
|
1804
1877
|
const n = !!t.ctrl, r = !!t.meta, s = !!t.shift, o = !!t.alt;
|
|
1805
1878
|
if (t.mod) {
|
|
@@ -1807,17 +1880,17 @@ function fi(e, t) {
|
|
|
1807
1880
|
} else if (e.ctrlKey !== n || e.metaKey !== r) return !1;
|
|
1808
1881
|
return !(e.shiftKey !== s || e.altKey !== o);
|
|
1809
1882
|
}
|
|
1810
|
-
function
|
|
1883
|
+
function Oi(e) {
|
|
1811
1884
|
if (!(e instanceof HTMLElement)) return !1;
|
|
1812
1885
|
const t = e.tagName.toLowerCase();
|
|
1813
1886
|
return t === "input" || t === "textarea" || t === "select" ? !0 : e.isContentEditable;
|
|
1814
1887
|
}
|
|
1815
|
-
function
|
|
1888
|
+
function _c(e, t, n = {}) {
|
|
1816
1889
|
const { disabled: r = !1, ignoreInput: s = !0 } = n;
|
|
1817
1890
|
k(() => {
|
|
1818
1891
|
if (r || typeof window > "u") return;
|
|
1819
1892
|
const o = (i) => {
|
|
1820
|
-
s &&
|
|
1893
|
+
s && Oi(i.target) || Fi(i, e) && t(i);
|
|
1821
1894
|
};
|
|
1822
1895
|
return window.addEventListener("keydown", o), () => window.removeEventListener("keydown", o);
|
|
1823
1896
|
}, [
|
|
@@ -1832,7 +1905,7 @@ function qa(e, t, n = {}) {
|
|
|
1832
1905
|
t
|
|
1833
1906
|
]);
|
|
1834
1907
|
}
|
|
1835
|
-
function
|
|
1908
|
+
function gc() {
|
|
1836
1909
|
const [e, t] = v(null), [n, r] = v(!1);
|
|
1837
1910
|
k(() => {
|
|
1838
1911
|
if (typeof window > "u") return;
|
|
@@ -1865,7 +1938,7 @@ const Ce = [
|
|
|
1865
1938
|
"wheel",
|
|
1866
1939
|
"scroll"
|
|
1867
1940
|
];
|
|
1868
|
-
function
|
|
1941
|
+
function yc(e = 6e4) {
|
|
1869
1942
|
const [t, n] = v(!1);
|
|
1870
1943
|
return k(() => {
|
|
1871
1944
|
if (typeof window > "u") return;
|
|
@@ -1882,7 +1955,7 @@ function Ka(e = 6e4) {
|
|
|
1882
1955
|
};
|
|
1883
1956
|
}, [e]), t;
|
|
1884
1957
|
}
|
|
1885
|
-
function
|
|
1958
|
+
function wc(e = {}) {
|
|
1886
1959
|
const { watch: t = !1, disabled: n = !1, ...r } = e, [s, o] = v({
|
|
1887
1960
|
loading: !n,
|
|
1888
1961
|
error: null,
|
|
@@ -1921,7 +1994,7 @@ function Va(e = {}) {
|
|
|
1921
1994
|
r.timeout
|
|
1922
1995
|
]), s;
|
|
1923
1996
|
}
|
|
1924
|
-
function
|
|
1997
|
+
function bc(e) {
|
|
1925
1998
|
k(() => {
|
|
1926
1999
|
if (!e || typeof document > "u") return;
|
|
1927
2000
|
const t = document.body, n = t.style.overflow;
|
|
@@ -1930,7 +2003,7 @@ function Qa(e) {
|
|
|
1930
2003
|
};
|
|
1931
2004
|
}, [e]);
|
|
1932
2005
|
}
|
|
1933
|
-
const
|
|
2006
|
+
const Wi = [
|
|
1934
2007
|
"a[href]",
|
|
1935
2008
|
"button:not([disabled])",
|
|
1936
2009
|
"textarea:not([disabled])",
|
|
@@ -1938,7 +2011,7 @@ const hi = [
|
|
|
1938
2011
|
"select:not([disabled])",
|
|
1939
2012
|
"[tabindex]:not([tabindex='-1'])"
|
|
1940
2013
|
].join(",");
|
|
1941
|
-
function
|
|
2014
|
+
function vc(e, t) {
|
|
1942
2015
|
k(() => {
|
|
1943
2016
|
if (!t) return;
|
|
1944
2017
|
const n = e.current;
|
|
@@ -1946,7 +2019,7 @@ function Ya(e, t) {
|
|
|
1946
2019
|
const r = document.activeElement;
|
|
1947
2020
|
function s() {
|
|
1948
2021
|
return Array.from(
|
|
1949
|
-
n?.querySelectorAll(
|
|
2022
|
+
n?.querySelectorAll(Wi) ?? []
|
|
1950
2023
|
).filter((c) => {
|
|
1951
2024
|
if (c.hasAttribute("aria-hidden")) return !1;
|
|
1952
2025
|
const a = typeof window < "u" ? window.getComputedStyle(c) : null;
|
|
@@ -1968,7 +2041,7 @@ function Ya(e, t) {
|
|
|
1968
2041
|
};
|
|
1969
2042
|
}, [e, t]);
|
|
1970
2043
|
}
|
|
1971
|
-
function
|
|
2044
|
+
function $c(e) {
|
|
1972
2045
|
const t = E(e);
|
|
1973
2046
|
return t.current = e, S((...n) => t.current(...n), []);
|
|
1974
2047
|
}
|
|
@@ -1982,18 +2055,18 @@ function Ne(e, t) {
|
|
|
1982
2055
|
(s) => Ne(e[s], t[s])
|
|
1983
2056
|
);
|
|
1984
2057
|
}
|
|
1985
|
-
function
|
|
2058
|
+
function Nc(e) {
|
|
1986
2059
|
const t = E(e);
|
|
1987
2060
|
return Ne(t.current, e) || (t.current = e), t.current;
|
|
1988
2061
|
}
|
|
1989
|
-
function
|
|
2062
|
+
function Bi(e, t, n) {
|
|
1990
2063
|
const r = new URL(t, e.endsWith("/") ? e : `${e}/`);
|
|
1991
2064
|
if (n)
|
|
1992
2065
|
for (const [s, o] of Object.entries(n))
|
|
1993
2066
|
o != null && r.searchParams.set(s, String(o));
|
|
1994
2067
|
return r.toString();
|
|
1995
2068
|
}
|
|
1996
|
-
function
|
|
2069
|
+
function zi(e) {
|
|
1997
2070
|
return typeof FormData < "u" && e instanceof FormData;
|
|
1998
2071
|
}
|
|
1999
2072
|
async function Le(e) {
|
|
@@ -2014,25 +2087,25 @@ async function Le(e) {
|
|
|
2014
2087
|
body: t
|
|
2015
2088
|
};
|
|
2016
2089
|
}
|
|
2017
|
-
function
|
|
2090
|
+
function kc(e) {
|
|
2018
2091
|
const t = e.fetcher ?? globalThis.fetch.bind(globalThis);
|
|
2019
2092
|
function n() {
|
|
2020
2093
|
const i = e.getToken?.();
|
|
2021
2094
|
return i ? { Authorization: `Bearer ${i}` } : {};
|
|
2022
2095
|
}
|
|
2023
2096
|
async function r(i, c) {
|
|
2024
|
-
const { body: a, params: u, headers: d, ...p } = c, f =
|
|
2097
|
+
const { body: a, params: u, headers: d, ...p } = c, f = zi(a), h = {
|
|
2025
2098
|
...f ? {} : { "Content-Type": "application/json" },
|
|
2026
2099
|
...e.headers,
|
|
2027
2100
|
...n(),
|
|
2028
2101
|
...d
|
|
2029
|
-
},
|
|
2102
|
+
}, _ = {
|
|
2030
2103
|
...p,
|
|
2031
|
-
headers:
|
|
2104
|
+
headers: h,
|
|
2032
2105
|
credentials: e.withCredentials ? "include" : p.credentials,
|
|
2033
2106
|
body: a == null ? void 0 : f ? a : JSON.stringify(a)
|
|
2034
2107
|
};
|
|
2035
|
-
return t(
|
|
2108
|
+
return t(Bi(e.baseURL, i, u), _);
|
|
2036
2109
|
}
|
|
2037
2110
|
async function s(i, c = {}) {
|
|
2038
2111
|
let a = await r(i, c);
|
|
@@ -2062,7 +2135,7 @@ function ec(e) {
|
|
|
2062
2135
|
upload: o
|
|
2063
2136
|
};
|
|
2064
2137
|
}
|
|
2065
|
-
function
|
|
2138
|
+
function xc(e, t, n) {
|
|
2066
2139
|
const r = e.safeParse(t);
|
|
2067
2140
|
if (r.success)
|
|
2068
2141
|
return r.data;
|
|
@@ -2078,7 +2151,7 @@ Raw payload: ${JSON.stringify(t, null, 2)}`
|
|
|
2078
2151
|
}
|
|
2079
2152
|
throw new Error(`Resposta inválida do servidor (${n}).`);
|
|
2080
2153
|
}
|
|
2081
|
-
function
|
|
2154
|
+
function ji(e) {
|
|
2082
2155
|
if (!e) return null;
|
|
2083
2156
|
try {
|
|
2084
2157
|
return JSON.parse(e);
|
|
@@ -2086,7 +2159,7 @@ function yi(e) {
|
|
|
2086
2159
|
return e;
|
|
2087
2160
|
}
|
|
2088
2161
|
}
|
|
2089
|
-
function
|
|
2162
|
+
function Sc(e) {
|
|
2090
2163
|
const {
|
|
2091
2164
|
url: t,
|
|
2092
2165
|
body: n,
|
|
@@ -2105,9 +2178,9 @@ function nc(e) {
|
|
|
2105
2178
|
}
|
|
2106
2179
|
const f = new XMLHttpRequest();
|
|
2107
2180
|
f.open(r, t), f.withCredentials = i;
|
|
2108
|
-
const
|
|
2109
|
-
|
|
2110
|
-
for (const [b, y] of Object.entries(
|
|
2181
|
+
const h = o?.(), _ = { ...s };
|
|
2182
|
+
h && !("Authorization" in _) && (_.Authorization = `Bearer ${h}`);
|
|
2183
|
+
for (const [b, y] of Object.entries(_))
|
|
2111
2184
|
f.setRequestHeader(b, y);
|
|
2112
2185
|
c && (f.upload.onprogress = (b) => {
|
|
2113
2186
|
c({
|
|
@@ -2117,19 +2190,19 @@ function nc(e) {
|
|
|
2117
2190
|
lengthComputable: b.lengthComputable
|
|
2118
2191
|
});
|
|
2119
2192
|
});
|
|
2120
|
-
function
|
|
2193
|
+
function m() {
|
|
2121
2194
|
f.abort();
|
|
2122
2195
|
}
|
|
2123
|
-
a?.addEventListener("abort",
|
|
2124
|
-
a?.removeEventListener("abort",
|
|
2196
|
+
a?.addEventListener("abort", m), f.onload = () => {
|
|
2197
|
+
a?.removeEventListener("abort", m);
|
|
2125
2198
|
const b = f.status >= 200 && f.status < 300, y = f.getResponseHeader("content-type") ?? "";
|
|
2126
2199
|
if (!b) {
|
|
2127
|
-
const
|
|
2200
|
+
const $ = ji(f.responseText), N = (typeof $ == "object" && $ !== null ? $.detail ?? $.message : void 0) ?? `Erro ${f.status}`, L = {
|
|
2128
2201
|
status: f.status,
|
|
2129
|
-
detail: String(
|
|
2130
|
-
body:
|
|
2202
|
+
detail: String(N),
|
|
2203
|
+
body: $
|
|
2131
2204
|
};
|
|
2132
|
-
p(
|
|
2205
|
+
p(L);
|
|
2133
2206
|
return;
|
|
2134
2207
|
}
|
|
2135
2208
|
if (f.status === 204 || !f.responseText) {
|
|
@@ -2139,19 +2212,19 @@ function nc(e) {
|
|
|
2139
2212
|
if (y.includes("application/json"))
|
|
2140
2213
|
try {
|
|
2141
2214
|
d(u(f.responseText));
|
|
2142
|
-
} catch (
|
|
2143
|
-
p(
|
|
2215
|
+
} catch ($) {
|
|
2216
|
+
p($);
|
|
2144
2217
|
}
|
|
2145
2218
|
else
|
|
2146
2219
|
d(f.responseText);
|
|
2147
2220
|
}, f.onerror = () => {
|
|
2148
|
-
a?.removeEventListener("abort",
|
|
2221
|
+
a?.removeEventListener("abort", m), p({ status: 0, detail: "Falha de rede no upload." });
|
|
2149
2222
|
}, f.onabort = () => {
|
|
2150
|
-
a?.removeEventListener("abort",
|
|
2223
|
+
a?.removeEventListener("abort", m), p(new DOMException("Aborted", "AbortError"));
|
|
2151
2224
|
}, f.send(n);
|
|
2152
2225
|
});
|
|
2153
2226
|
}
|
|
2154
|
-
function
|
|
2227
|
+
function Ui(e, t) {
|
|
2155
2228
|
return new Promise((n, r) => {
|
|
2156
2229
|
if (t?.aborted) {
|
|
2157
2230
|
r(new DOMException("Aborted", "AbortError"));
|
|
@@ -2167,7 +2240,7 @@ function wi(e, t) {
|
|
|
2167
2240
|
);
|
|
2168
2241
|
});
|
|
2169
2242
|
}
|
|
2170
|
-
async function
|
|
2243
|
+
async function Ec(e, t = {}) {
|
|
2171
2244
|
const {
|
|
2172
2245
|
retries: n = 3,
|
|
2173
2246
|
initialDelay: r = 300,
|
|
@@ -2185,22 +2258,22 @@ async function rc(e, t = {}) {
|
|
|
2185
2258
|
if (u = d, a += 1, a >= n || !o(d, a))
|
|
2186
2259
|
throw d;
|
|
2187
2260
|
const p = Math.min(r * 2 ** (a - 1), s);
|
|
2188
|
-
i?.({ attempt: a, delay: p, error: d }), await
|
|
2261
|
+
i?.({ attempt: a, delay: p, error: d }), await Ui(p, c);
|
|
2189
2262
|
}
|
|
2190
2263
|
}
|
|
2191
2264
|
throw u;
|
|
2192
2265
|
}
|
|
2193
|
-
function
|
|
2266
|
+
function Tc() {
|
|
2194
2267
|
return typeof crypto < "u" && "randomUUID" in crypto ? crypto.randomUUID() : "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (e) => {
|
|
2195
2268
|
const t = Math.random() * 16;
|
|
2196
2269
|
return (e === "x" ? Math.floor(t) : Math.floor(t) & 3 | 8).toString(16);
|
|
2197
2270
|
});
|
|
2198
2271
|
}
|
|
2199
|
-
function
|
|
2200
|
-
const { interval: n, disabled: r = !1, stopWhen: s, onError: o } = t, [i, c] = v(null), [a, u] = v(null), [d, p] = v(!r), f = E(r),
|
|
2201
|
-
async function
|
|
2202
|
-
if (!(f.current ||
|
|
2203
|
-
|
|
2272
|
+
function Cc(e, t) {
|
|
2273
|
+
const { interval: n, disabled: r = !1, stopWhen: s, onError: o } = t, [i, c] = v(null), [a, u] = v(null), [d, p] = v(!r), f = E(r), h = E(!1), _ = E(null);
|
|
2274
|
+
async function m() {
|
|
2275
|
+
if (!(f.current || h.current)) {
|
|
2276
|
+
h.current = !0;
|
|
2204
2277
|
try {
|
|
2205
2278
|
const b = await e();
|
|
2206
2279
|
if (f.current) return;
|
|
@@ -2208,31 +2281,31 @@ function oc(e, t) {
|
|
|
2208
2281
|
} catch (b) {
|
|
2209
2282
|
f.current || (u(b), o?.(b));
|
|
2210
2283
|
} finally {
|
|
2211
|
-
|
|
2284
|
+
h.current = !1, p(!1), f.current || (_.current = setTimeout(m, n));
|
|
2212
2285
|
}
|
|
2213
2286
|
}
|
|
2214
2287
|
}
|
|
2215
2288
|
return k(() => {
|
|
2216
2289
|
if (f.current = r, r) {
|
|
2217
|
-
|
|
2290
|
+
_.current && clearTimeout(_.current);
|
|
2218
2291
|
return;
|
|
2219
2292
|
}
|
|
2220
|
-
return p(!0),
|
|
2221
|
-
f.current = !0,
|
|
2293
|
+
return p(!0), m(), () => {
|
|
2294
|
+
f.current = !0, _.current && clearTimeout(_.current);
|
|
2222
2295
|
};
|
|
2223
2296
|
}, [n, r]), {
|
|
2224
2297
|
data: i,
|
|
2225
2298
|
error: a,
|
|
2226
2299
|
loading: d,
|
|
2227
2300
|
stop: () => {
|
|
2228
|
-
f.current = !0,
|
|
2301
|
+
f.current = !0, _.current && clearTimeout(_.current);
|
|
2229
2302
|
},
|
|
2230
2303
|
start: () => {
|
|
2231
|
-
f.current && (f.current = !1,
|
|
2304
|
+
f.current && (f.current = !1, m());
|
|
2232
2305
|
}
|
|
2233
2306
|
};
|
|
2234
2307
|
}
|
|
2235
|
-
function
|
|
2308
|
+
function Lc(e = {}) {
|
|
2236
2309
|
const t = e.name ?? "tempest-auth", n = e.storage === "session" ? () => sessionStorage : () => localStorage;
|
|
2237
2310
|
return nt()(
|
|
2238
2311
|
rt(
|
|
@@ -2256,14 +2329,14 @@ function ic(e = {}) {
|
|
|
2256
2329
|
)
|
|
2257
2330
|
);
|
|
2258
2331
|
}
|
|
2259
|
-
function
|
|
2260
|
-
return /* @__PURE__ */ l(
|
|
2332
|
+
function Ic({ isAuthenticated: e, children: t, fallback: n }) {
|
|
2333
|
+
return /* @__PURE__ */ l(ke, { children: e ? t : n });
|
|
2261
2334
|
}
|
|
2262
2335
|
function Ie(e) {
|
|
2263
2336
|
const t = e.replace(/-/g, "+").replace(/_/g, "/"), n = t.length % 4 === 0 ? "" : "=".repeat(4 - t.length % 4);
|
|
2264
2337
|
return typeof atob < "u" ? atob(t + n) : Buffer.from(t + n, "base64").toString("binary");
|
|
2265
2338
|
}
|
|
2266
|
-
function
|
|
2339
|
+
function qi(e) {
|
|
2267
2340
|
const t = e.split(".");
|
|
2268
2341
|
if (t.length !== 3) throw new Error("Invalid JWT: must contain three segments.");
|
|
2269
2342
|
const [n, r, s] = t;
|
|
@@ -2277,9 +2350,9 @@ function bi(e) {
|
|
|
2277
2350
|
throw new Error("Invalid JWT: header or payload is not valid JSON.");
|
|
2278
2351
|
}
|
|
2279
2352
|
}
|
|
2280
|
-
function
|
|
2353
|
+
function Dc(e, t = 0) {
|
|
2281
2354
|
try {
|
|
2282
|
-
const { payload: n } =
|
|
2355
|
+
const { payload: n } = qi(e);
|
|
2283
2356
|
if (typeof n.exp != "number") return !0;
|
|
2284
2357
|
const r = Math.floor(Date.now() / 1e3);
|
|
2285
2358
|
return n.exp <= r + t;
|
|
@@ -2287,7 +2360,7 @@ function cc(e, t = 0) {
|
|
|
2287
2360
|
return !0;
|
|
2288
2361
|
}
|
|
2289
2362
|
}
|
|
2290
|
-
function
|
|
2363
|
+
function Mc(e, t = {}) {
|
|
2291
2364
|
const { retries: n = 3, initialDelay: r = 400, reloadOnFinalFailure: s = !0 } = t;
|
|
2292
2365
|
async function o(i = 1) {
|
|
2293
2366
|
try {
|
|
@@ -2298,9 +2371,9 @@ function lc(e, t = {}) {
|
|
|
2298
2371
|
return await new Promise((a) => setTimeout(a, r * 2 ** (i - 1))), o(i + 1);
|
|
2299
2372
|
}
|
|
2300
2373
|
}
|
|
2301
|
-
return
|
|
2374
|
+
return Ze(o);
|
|
2302
2375
|
}
|
|
2303
|
-
function
|
|
2376
|
+
function Pc(e) {
|
|
2304
2377
|
let t = null;
|
|
2305
2378
|
return () => t || (t = (async () => {
|
|
2306
2379
|
try {
|
|
@@ -2310,34 +2383,34 @@ function uc(e) {
|
|
|
2310
2383
|
}
|
|
2311
2384
|
})(), t);
|
|
2312
2385
|
}
|
|
2313
|
-
const
|
|
2386
|
+
const Ji = {
|
|
2314
2387
|
SHORT: 30 * 1e3,
|
|
2315
2388
|
DEFAULT: 300 * 1e3,
|
|
2316
2389
|
LONG: 1800 * 1e3,
|
|
2317
2390
|
INFINITE: 1 / 0
|
|
2318
|
-
},
|
|
2391
|
+
}, Gi = {
|
|
2319
2392
|
SHORT: 300 * 1e3,
|
|
2320
2393
|
DEFAULT: 1800 * 1e3,
|
|
2321
2394
|
LONG: 3600 * 1e3
|
|
2322
|
-
},
|
|
2395
|
+
}, Ac = {
|
|
2323
2396
|
REALTIME: 5 * 1e3,
|
|
2324
2397
|
FAST: 30 * 1e3,
|
|
2325
2398
|
DEFAULT: 60 * 1e3,
|
|
2326
2399
|
SLOW: 300 * 1e3
|
|
2327
2400
|
};
|
|
2328
|
-
function
|
|
2401
|
+
function Rc(e, t) {
|
|
2329
2402
|
const n = { all: [e] };
|
|
2330
2403
|
for (const [r, s] of Object.entries(t))
|
|
2331
2404
|
typeof s == "function" ? n[r] = (...o) => [e, ...s(...o)] : n[r] = [e, ...s];
|
|
2332
2405
|
return n;
|
|
2333
2406
|
}
|
|
2334
|
-
function
|
|
2407
|
+
function Fc({ children: e, client: t, defaultOptions: n }) {
|
|
2335
2408
|
const [r] = v(
|
|
2336
2409
|
() => t ?? new et({
|
|
2337
2410
|
defaultOptions: {
|
|
2338
2411
|
queries: {
|
|
2339
|
-
staleTime:
|
|
2340
|
-
gcTime:
|
|
2412
|
+
staleTime: Ji.DEFAULT,
|
|
2413
|
+
gcTime: Gi.DEFAULT,
|
|
2341
2414
|
retry: 1,
|
|
2342
2415
|
refetchOnWindowFocus: !1,
|
|
2343
2416
|
...n?.queries ?? {}
|
|
@@ -2351,14 +2424,14 @@ function fc({ children: e, client: t, defaultOptions: n }) {
|
|
|
2351
2424
|
);
|
|
2352
2425
|
return /* @__PURE__ */ l(tt, { client: r, children: e });
|
|
2353
2426
|
}
|
|
2354
|
-
function
|
|
2427
|
+
function Hi(e) {
|
|
2355
2428
|
try {
|
|
2356
2429
|
return JSON.parse(e);
|
|
2357
2430
|
} catch {
|
|
2358
2431
|
return e;
|
|
2359
2432
|
}
|
|
2360
2433
|
}
|
|
2361
|
-
function
|
|
2434
|
+
function Ki(e, t = {}) {
|
|
2362
2435
|
const {
|
|
2363
2436
|
withCredentials: n = !1,
|
|
2364
2437
|
namedEvents: r = [],
|
|
@@ -2366,71 +2439,71 @@ function ki(e, t = {}) {
|
|
|
2366
2439
|
maxRetries: o = 10,
|
|
2367
2440
|
initialBackoff: i = 1e3,
|
|
2368
2441
|
maxBackoff: c = 3e4,
|
|
2369
|
-
parser: a =
|
|
2442
|
+
parser: a = Hi,
|
|
2370
2443
|
onOpen: u,
|
|
2371
2444
|
onMessage: d,
|
|
2372
2445
|
onError: p,
|
|
2373
2446
|
onStatusChange: f
|
|
2374
2447
|
} = t;
|
|
2375
|
-
let
|
|
2376
|
-
function
|
|
2448
|
+
let h = null, _ = null, m = 0, b = "idle", y = !1;
|
|
2449
|
+
function $(x) {
|
|
2377
2450
|
b !== x && (b = x, f?.(x));
|
|
2378
2451
|
}
|
|
2379
|
-
function
|
|
2452
|
+
function N(x, I) {
|
|
2380
2453
|
s.includes(x) || d?.({
|
|
2381
2454
|
event: x,
|
|
2382
|
-
data: a(
|
|
2383
|
-
id:
|
|
2384
|
-
raw:
|
|
2455
|
+
data: a(I.data),
|
|
2456
|
+
id: I.lastEventId || void 0,
|
|
2457
|
+
raw: I
|
|
2385
2458
|
});
|
|
2386
2459
|
}
|
|
2387
|
-
function
|
|
2460
|
+
function L() {
|
|
2388
2461
|
if (y) return;
|
|
2389
|
-
if (
|
|
2390
|
-
|
|
2462
|
+
if (m >= o) {
|
|
2463
|
+
$("error");
|
|
2391
2464
|
return;
|
|
2392
2465
|
}
|
|
2393
|
-
const x = Math.min(i * 2 **
|
|
2394
|
-
|
|
2466
|
+
const x = Math.min(i * 2 ** m, c);
|
|
2467
|
+
m += 1, _ = setTimeout(D, x);
|
|
2395
2468
|
}
|
|
2396
|
-
function
|
|
2469
|
+
function D() {
|
|
2397
2470
|
if (y) return;
|
|
2398
|
-
|
|
2471
|
+
h && h.close(), $("connecting");
|
|
2399
2472
|
const x = new EventSource(e, { withCredentials: n });
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
}, x.onmessage = (
|
|
2403
|
-
for (const
|
|
2404
|
-
x.addEventListener(
|
|
2405
|
-
for (const
|
|
2406
|
-
x.addEventListener(
|
|
2473
|
+
h = x, x.onopen = () => {
|
|
2474
|
+
m = 0, $("open"), u?.();
|
|
2475
|
+
}, x.onmessage = (I) => N("message", I);
|
|
2476
|
+
for (const I of r)
|
|
2477
|
+
x.addEventListener(I, (_e) => N(I, _e));
|
|
2478
|
+
for (const I of s)
|
|
2479
|
+
x.addEventListener(I, () => {
|
|
2407
2480
|
});
|
|
2408
|
-
x.onerror = (
|
|
2409
|
-
p?.(
|
|
2481
|
+
x.onerror = (I) => {
|
|
2482
|
+
p?.(I), x.close(), h = null, $("closed"), L();
|
|
2410
2483
|
};
|
|
2411
2484
|
}
|
|
2412
|
-
function fe() {
|
|
2413
|
-
y = !0, g && (clearTimeout(g), g = null), h = 0, m && (m.close(), m = null), N("closed");
|
|
2414
|
-
}
|
|
2415
2485
|
function me() {
|
|
2416
|
-
|
|
2486
|
+
y = !0, _ && (clearTimeout(_), _ = null), m = 0, h && (h.close(), h = null), $("closed");
|
|
2487
|
+
}
|
|
2488
|
+
function he() {
|
|
2489
|
+
_ && (clearTimeout(_), _ = null), m = 0, y = !1, D();
|
|
2417
2490
|
}
|
|
2418
|
-
return
|
|
2419
|
-
close:
|
|
2420
|
-
reconnect:
|
|
2491
|
+
return D(), {
|
|
2492
|
+
close: me,
|
|
2493
|
+
reconnect: he,
|
|
2421
2494
|
get status() {
|
|
2422
2495
|
return b;
|
|
2423
2496
|
}
|
|
2424
2497
|
};
|
|
2425
2498
|
}
|
|
2426
|
-
function
|
|
2499
|
+
function Oc(e, t = {}) {
|
|
2427
2500
|
const { enabled: n = !0, onMessage: r, ...s } = t, [o, i] = v("idle"), [c, a] = v(null), u = E(null), d = E(r);
|
|
2428
2501
|
return d.current = r, k(() => {
|
|
2429
2502
|
if (!n || !e) {
|
|
2430
2503
|
i("idle");
|
|
2431
2504
|
return;
|
|
2432
2505
|
}
|
|
2433
|
-
const p =
|
|
2506
|
+
const p = Ki(e, {
|
|
2434
2507
|
...s,
|
|
2435
2508
|
onStatusChange: i,
|
|
2436
2509
|
onMessage: (f) => {
|
|
@@ -2446,13 +2519,13 @@ function mc(e, t = {}) {
|
|
|
2446
2519
|
reconnect: () => u.current?.()
|
|
2447
2520
|
};
|
|
2448
2521
|
}
|
|
2449
|
-
function
|
|
2522
|
+
function Vi(e) {
|
|
2450
2523
|
const t = "=".repeat((4 - e.length % 4) % 4), n = (e + t).replace(/-/g, "+").replace(/_/g, "/"), r = window.atob(n), s = new ArrayBuffer(r.length), o = new Uint8Array(s);
|
|
2451
2524
|
for (let i = 0; i < r.length; i++)
|
|
2452
2525
|
o[i] = r.charCodeAt(i);
|
|
2453
2526
|
return o;
|
|
2454
2527
|
}
|
|
2455
|
-
function
|
|
2528
|
+
function de() {
|
|
2456
2529
|
return typeof window < "u" && "serviceWorker" in navigator && "PushManager" in window && "Notification" in window;
|
|
2457
2530
|
}
|
|
2458
2531
|
class De extends Error {
|
|
@@ -2460,22 +2533,22 @@ class De extends Error {
|
|
|
2460
2533
|
super("Web Push não suportado neste navegador."), this.name = "WebPushUnsupportedError";
|
|
2461
2534
|
}
|
|
2462
2535
|
}
|
|
2463
|
-
class
|
|
2536
|
+
class Qi extends Error {
|
|
2464
2537
|
constructor() {
|
|
2465
2538
|
super("Permissão de notificação negada pelo usuário."), this.name = "WebPushPermissionDeniedError";
|
|
2466
2539
|
}
|
|
2467
2540
|
}
|
|
2468
|
-
class
|
|
2541
|
+
class Yi {
|
|
2469
2542
|
config;
|
|
2470
2543
|
constructor(t) {
|
|
2471
2544
|
this.config = t;
|
|
2472
2545
|
}
|
|
2473
2546
|
/** Whether the runtime supports the Push API. */
|
|
2474
2547
|
static isSupported() {
|
|
2475
|
-
return
|
|
2548
|
+
return de();
|
|
2476
2549
|
}
|
|
2477
2550
|
async registration() {
|
|
2478
|
-
if (!
|
|
2551
|
+
if (!de()) throw new De();
|
|
2479
2552
|
return this.config.getRegistration ? await this.config.getRegistration() : await navigator.serviceWorker.ready;
|
|
2480
2553
|
}
|
|
2481
2554
|
/** Current `Notification.permission` value, or `"unsupported"`. */
|
|
@@ -2498,7 +2571,7 @@ class Ei {
|
|
|
2498
2571
|
}
|
|
2499
2572
|
/** True when a subscription already exists for this browser. */
|
|
2500
2573
|
async isSubscribed() {
|
|
2501
|
-
return
|
|
2574
|
+
return de() ? await this.getSubscription() !== null : !1;
|
|
2502
2575
|
}
|
|
2503
2576
|
/**
|
|
2504
2577
|
* Subscribe the current device. Requests permission, creates a push
|
|
@@ -2510,13 +2583,13 @@ class Ei {
|
|
|
2510
2583
|
* @throws {WebPushPermissionDeniedError} If the user denies the prompt.
|
|
2511
2584
|
*/
|
|
2512
2585
|
async subscribe() {
|
|
2513
|
-
if (await this.requestPermission() !== "granted") throw new
|
|
2586
|
+
if (await this.requestPermission() !== "granted") throw new Qi();
|
|
2514
2587
|
const n = await this.registration(), r = await n.pushManager.getSubscription();
|
|
2515
2588
|
if (r)
|
|
2516
2589
|
return await this.config.onSubscribe(r.toJSON()), r;
|
|
2517
2590
|
const s = await n.pushManager.subscribe({
|
|
2518
2591
|
userVisibleOnly: !0,
|
|
2519
|
-
applicationServerKey:
|
|
2592
|
+
applicationServerKey: Vi(this.config.vapidPublicKey)
|
|
2520
2593
|
});
|
|
2521
2594
|
return await this.config.onSubscribe(s.toJSON()), s;
|
|
2522
2595
|
}
|
|
@@ -2531,51 +2604,51 @@ class Ei {
|
|
|
2531
2604
|
return t ? (this.config.onUnsubscribe && await this.config.onUnsubscribe(t.toJSON()), t.unsubscribe()) : !1;
|
|
2532
2605
|
}
|
|
2533
2606
|
}
|
|
2534
|
-
function
|
|
2607
|
+
function Wc(e) {
|
|
2535
2608
|
const t = E(e);
|
|
2536
2609
|
t.current = e;
|
|
2537
|
-
const n =
|
|
2538
|
-
() => new
|
|
2610
|
+
const n = B(
|
|
2611
|
+
() => new Yi({
|
|
2539
2612
|
vapidPublicKey: e.vapidPublicKey,
|
|
2540
|
-
onSubscribe: (
|
|
2541
|
-
onUnsubscribe: (
|
|
2613
|
+
onSubscribe: (m) => t.current.onSubscribe(m),
|
|
2614
|
+
onUnsubscribe: (m) => t.current.onUnsubscribe?.(m),
|
|
2542
2615
|
getRegistration: e.getRegistration
|
|
2543
2616
|
}),
|
|
2544
2617
|
[e.vapidPublicKey, e.getRegistration]
|
|
2545
|
-
), [r] = v(() =>
|
|
2618
|
+
), [r] = v(() => de()), [s, o] = v(
|
|
2546
2619
|
() => n.permission()
|
|
2547
2620
|
), [i, c] = v(!1), [a, u] = v(!1), [d, p] = v(null), f = S(async () => {
|
|
2548
2621
|
if (r) {
|
|
2549
2622
|
o(n.permission());
|
|
2550
2623
|
try {
|
|
2551
|
-
const
|
|
2552
|
-
c(
|
|
2553
|
-
} catch (
|
|
2554
|
-
p(
|
|
2624
|
+
const m = await n.isSubscribed();
|
|
2625
|
+
c(m);
|
|
2626
|
+
} catch (m) {
|
|
2627
|
+
p(m instanceof Error ? m : new Error(String(m)));
|
|
2555
2628
|
}
|
|
2556
2629
|
}
|
|
2557
2630
|
}, [n, r]);
|
|
2558
2631
|
k(() => {
|
|
2559
2632
|
f();
|
|
2560
2633
|
}, [f]);
|
|
2561
|
-
const
|
|
2634
|
+
const h = S(async () => {
|
|
2562
2635
|
if (r) {
|
|
2563
2636
|
u(!0), p(null);
|
|
2564
2637
|
try {
|
|
2565
2638
|
await n.subscribe(), c(!0), o(n.permission());
|
|
2566
|
-
} catch (
|
|
2567
|
-
throw p(
|
|
2639
|
+
} catch (m) {
|
|
2640
|
+
throw p(m instanceof Error ? m : new Error(String(m))), m;
|
|
2568
2641
|
} finally {
|
|
2569
2642
|
u(!1);
|
|
2570
2643
|
}
|
|
2571
2644
|
}
|
|
2572
|
-
}, [n, r]),
|
|
2645
|
+
}, [n, r]), _ = S(async () => {
|
|
2573
2646
|
if (r) {
|
|
2574
2647
|
u(!0), p(null);
|
|
2575
2648
|
try {
|
|
2576
2649
|
await n.unsubscribe(), c(!1);
|
|
2577
|
-
} catch (
|
|
2578
|
-
throw p(
|
|
2650
|
+
} catch (m) {
|
|
2651
|
+
throw p(m instanceof Error ? m : new Error(String(m))), m;
|
|
2579
2652
|
} finally {
|
|
2580
2653
|
u(!1);
|
|
2581
2654
|
}
|
|
@@ -2587,12 +2660,12 @@ function hc(e) {
|
|
|
2587
2660
|
subscribed: i,
|
|
2588
2661
|
loading: a,
|
|
2589
2662
|
error: d,
|
|
2590
|
-
subscribe:
|
|
2591
|
-
unsubscribe:
|
|
2663
|
+
subscribe: h,
|
|
2664
|
+
unsubscribe: _,
|
|
2592
2665
|
refresh: f
|
|
2593
2666
|
};
|
|
2594
2667
|
}
|
|
2595
|
-
async function
|
|
2668
|
+
async function Bc(e) {
|
|
2596
2669
|
if (typeof navigator > "u" || !("serviceWorker" in navigator))
|
|
2597
2670
|
return null;
|
|
2598
2671
|
try {
|
|
@@ -2609,10 +2682,10 @@ async function gc(e) {
|
|
|
2609
2682
|
return e.onError?.(t), null;
|
|
2610
2683
|
}
|
|
2611
2684
|
}
|
|
2612
|
-
function
|
|
2685
|
+
function zc(e) {
|
|
2613
2686
|
e.postMessage({ type: "SKIP_WAITING" });
|
|
2614
2687
|
}
|
|
2615
|
-
async function
|
|
2688
|
+
async function jc() {
|
|
2616
2689
|
if (typeof navigator > "u" || !("serviceWorker" in navigator)) return 0;
|
|
2617
2690
|
const e = await navigator.serviceWorker.getRegistrations();
|
|
2618
2691
|
let t = 0;
|
|
@@ -2620,11 +2693,11 @@ async function yc() {
|
|
|
2620
2693
|
await n.unregister() && (t += 1);
|
|
2621
2694
|
return t;
|
|
2622
2695
|
}
|
|
2623
|
-
function
|
|
2696
|
+
function Ee() {
|
|
2624
2697
|
return globalThis;
|
|
2625
2698
|
}
|
|
2626
|
-
function
|
|
2627
|
-
const t =
|
|
2699
|
+
function Uc(e = {}) {
|
|
2700
|
+
const t = Ee(), { defaultTitle: n = "Notificação", defaultIcon: r, defaultBadge: s, transform: o } = e;
|
|
2628
2701
|
t.addEventListener("push", (i) => {
|
|
2629
2702
|
if (!i.data) return;
|
|
2630
2703
|
let c;
|
|
@@ -2646,8 +2719,8 @@ function wc(e = {}) {
|
|
|
2646
2719
|
i.waitUntil(t.registration.showNotification(u, d));
|
|
2647
2720
|
});
|
|
2648
2721
|
}
|
|
2649
|
-
function
|
|
2650
|
-
const t =
|
|
2722
|
+
function qc(e = {}) {
|
|
2723
|
+
const t = Ee(), n = e.resolveUrl ?? ((r) => {
|
|
2651
2724
|
if (typeof r == "string") return r;
|
|
2652
2725
|
if (r && typeof r == "object" && "url" in r) {
|
|
2653
2726
|
const s = r.url;
|
|
@@ -2672,13 +2745,13 @@ function bc(e = {}) {
|
|
|
2672
2745
|
);
|
|
2673
2746
|
});
|
|
2674
2747
|
}
|
|
2675
|
-
function
|
|
2676
|
-
const e =
|
|
2748
|
+
function Jc() {
|
|
2749
|
+
const e = Ee();
|
|
2677
2750
|
e.addEventListener("message", (t) => {
|
|
2678
2751
|
t.data?.type === "SKIP_WAITING" && e.skipWaiting();
|
|
2679
2752
|
});
|
|
2680
2753
|
}
|
|
2681
|
-
function
|
|
2754
|
+
function ze() {
|
|
2682
2755
|
let e = null;
|
|
2683
2756
|
async function t(r, {
|
|
2684
2757
|
volume: s = 1,
|
|
@@ -2701,19 +2774,19 @@ function je() {
|
|
|
2701
2774
|
}
|
|
2702
2775
|
return { play: t, stop: n, current: () => e };
|
|
2703
2776
|
}
|
|
2704
|
-
let
|
|
2705
|
-
function
|
|
2706
|
-
return
|
|
2777
|
+
let be = null;
|
|
2778
|
+
function je() {
|
|
2779
|
+
return be || (be = ze()), be;
|
|
2707
2780
|
}
|
|
2708
|
-
async function
|
|
2709
|
-
return
|
|
2781
|
+
async function Gc(e, t) {
|
|
2782
|
+
return je().play(e, t);
|
|
2710
2783
|
}
|
|
2711
|
-
function
|
|
2712
|
-
|
|
2784
|
+
function Hc() {
|
|
2785
|
+
je().stop();
|
|
2713
2786
|
}
|
|
2714
|
-
function
|
|
2787
|
+
function Kc() {
|
|
2715
2788
|
const e = E(null), [t, n] = v(!1);
|
|
2716
|
-
e.current || (e.current =
|
|
2789
|
+
e.current || (e.current = ze()), k(() => () => {
|
|
2717
2790
|
e.current?.stop();
|
|
2718
2791
|
}, []);
|
|
2719
2792
|
const r = S(async (o, i) => {
|
|
@@ -2723,33 +2796,33 @@ function kc() {
|
|
|
2723
2796
|
}, []);
|
|
2724
2797
|
return { play: r, stop: s, unlocked: t };
|
|
2725
2798
|
}
|
|
2726
|
-
class
|
|
2799
|
+
class Zi extends ot {
|
|
2727
2800
|
store;
|
|
2728
2801
|
constructor(t, n, r, s) {
|
|
2729
2802
|
super(t), this.version(n).stores({ [r]: s }), this.store = this.table(r);
|
|
2730
2803
|
}
|
|
2731
2804
|
}
|
|
2732
|
-
function
|
|
2733
|
-
const { databaseName: t, version: n, tableName: r, indexes: s, keyPath: o = "id", ownerField: i } = e, c = new
|
|
2805
|
+
function Vc(e) {
|
|
2806
|
+
const { databaseName: t, version: n, tableName: r, indexes: s, keyPath: o = "id", ownerField: i } = e, c = new Zi(t, n, r, s), a = c.store;
|
|
2734
2807
|
function u(p, f) {
|
|
2735
2808
|
return !i || !f ? p : { ...p, [i]: f };
|
|
2736
2809
|
}
|
|
2737
2810
|
async function d(p, f = {}) {
|
|
2738
|
-
const { orderBy:
|
|
2739
|
-
let
|
|
2740
|
-
y && (
|
|
2741
|
-
let
|
|
2742
|
-
return
|
|
2811
|
+
const { orderBy: h = o, reverse: _ = !1, limit: m, offset: b, filter: y } = f;
|
|
2812
|
+
let $ = i && p ? a.where(i).equals(p) : a.toCollection();
|
|
2813
|
+
y && ($ = $.filter(y));
|
|
2814
|
+
let N = h === o ? await $.toArray() : await $.sortBy(h);
|
|
2815
|
+
return _ && (N = N.reverse()), b && (N = N.slice(b)), typeof m == "number" && (N = N.slice(0, m)), N;
|
|
2743
2816
|
}
|
|
2744
2817
|
return {
|
|
2745
2818
|
put: (p, f) => a.put(u(p, f)),
|
|
2746
|
-
bulkPut: (p, f) => a.bulkPut(p.map((
|
|
2819
|
+
bulkPut: (p, f) => a.bulkPut(p.map((h) => u(h, f))),
|
|
2747
2820
|
get: (p) => a.get(p),
|
|
2748
2821
|
list: d,
|
|
2749
2822
|
update: (p, f) => a.update(p, f),
|
|
2750
2823
|
updateMany: async (p, f) => {
|
|
2751
|
-
const
|
|
2752
|
-
return i && p ? a.where(i).equals(p).modify(
|
|
2824
|
+
const h = f;
|
|
2825
|
+
return i && p ? a.where(i).equals(p).modify(h) : a.toCollection().modify(h);
|
|
2753
2826
|
},
|
|
2754
2827
|
delete: (p) => a.delete(p),
|
|
2755
2828
|
clear: async (p) => {
|
|
@@ -2764,13 +2837,13 @@ function xc(e) {
|
|
|
2764
2837
|
db: c
|
|
2765
2838
|
};
|
|
2766
2839
|
}
|
|
2767
|
-
function
|
|
2840
|
+
function Xi(e = [], t = []) {
|
|
2768
2841
|
if (e.length !== t.length) return !0;
|
|
2769
2842
|
for (let n = 0; n < e.length; n++)
|
|
2770
2843
|
if (!Object.is(e[n], t[n])) return !0;
|
|
2771
2844
|
return !1;
|
|
2772
2845
|
}
|
|
2773
|
-
class
|
|
2846
|
+
class Qc extends Xe {
|
|
2774
2847
|
state = { error: null };
|
|
2775
2848
|
static getDerivedStateFromError(t) {
|
|
2776
2849
|
return { error: t };
|
|
@@ -2779,7 +2852,7 @@ class Sc extends Ze {
|
|
|
2779
2852
|
this.props.onError?.(t, n);
|
|
2780
2853
|
}
|
|
2781
2854
|
componentDidUpdate(t) {
|
|
2782
|
-
this.state.error &&
|
|
2855
|
+
this.state.error && Xi(t.resetKeys, this.props.resetKeys) && this.reset();
|
|
2783
2856
|
}
|
|
2784
2857
|
reset = () => {
|
|
2785
2858
|
this.setState({ error: null });
|
|
@@ -2791,7 +2864,7 @@ class Sc extends Ze {
|
|
|
2791
2864
|
return typeof n == "function" ? n({ error: t, reset: this.reset }) : n;
|
|
2792
2865
|
}
|
|
2793
2866
|
}
|
|
2794
|
-
function
|
|
2867
|
+
function Yc() {
|
|
2795
2868
|
const [, e] = v(null);
|
|
2796
2869
|
return S((t) => {
|
|
2797
2870
|
e(() => {
|
|
@@ -2799,7 +2872,7 @@ function Ec() {
|
|
|
2799
2872
|
});
|
|
2800
2873
|
}, []);
|
|
2801
2874
|
}
|
|
2802
|
-
function
|
|
2875
|
+
function Zc(e, t) {
|
|
2803
2876
|
const n = e.safeParse(t);
|
|
2804
2877
|
if (n.success)
|
|
2805
2878
|
return { success: !0, data: n.data, errors: {} };
|
|
@@ -2810,7 +2883,7 @@ function Tc(e, t) {
|
|
|
2810
2883
|
}
|
|
2811
2884
|
return { success: !1, errors: r };
|
|
2812
2885
|
}
|
|
2813
|
-
function
|
|
2886
|
+
function ea(e) {
|
|
2814
2887
|
return async (t, n, r) => {
|
|
2815
2888
|
const s = e.safeParse(t);
|
|
2816
2889
|
if (s.success)
|
|
@@ -2823,17 +2896,17 @@ function Li(e) {
|
|
|
2823
2896
|
return { values: {}, errors: o };
|
|
2824
2897
|
};
|
|
2825
2898
|
}
|
|
2826
|
-
function
|
|
2899
|
+
function Xc(e, t = {}) {
|
|
2827
2900
|
return it({
|
|
2828
2901
|
...t,
|
|
2829
|
-
resolver:
|
|
2902
|
+
resolver: ea(e)
|
|
2830
2903
|
});
|
|
2831
2904
|
}
|
|
2832
|
-
function
|
|
2905
|
+
function le(e) {
|
|
2833
2906
|
return e.replace(/\D/g, "");
|
|
2834
2907
|
}
|
|
2835
|
-
function
|
|
2836
|
-
const t =
|
|
2908
|
+
function el(e) {
|
|
2909
|
+
const t = le(e);
|
|
2837
2910
|
if (t.length !== 11 || /^(\d)\1+$/.test(t)) return !1;
|
|
2838
2911
|
const n = t.split("").map(Number);
|
|
2839
2912
|
let r = 0;
|
|
@@ -2844,8 +2917,8 @@ function Lc(e) {
|
|
|
2844
2917
|
for (let o = 0; o < 10; o++) r += n[o] * (11 - o);
|
|
2845
2918
|
return s = r * 10 % 11, s === 10 && (s = 0), s === n[10];
|
|
2846
2919
|
}
|
|
2847
|
-
function
|
|
2848
|
-
const t =
|
|
2920
|
+
function tl(e) {
|
|
2921
|
+
const t = le(e);
|
|
2849
2922
|
if (t.length !== 14 || /^(\d)\1+$/.test(t)) return !1;
|
|
2850
2923
|
const n = t.split("").map(Number), r = [5, 4, 3, 2, 9, 8, 7, 6, 5, 4, 3, 2], s = [6, 5, 4, 3, 2, 9, 8, 7, 6, 5, 4, 3, 2];
|
|
2851
2924
|
let o = 0;
|
|
@@ -2856,50 +2929,50 @@ function Ic(e) {
|
|
|
2856
2929
|
for (let c = 0; c < 13; c++) o += n[c] * s[c];
|
|
2857
2930
|
return i = o % 11, i = i < 2 ? 0 : 11 - i, i === n[13];
|
|
2858
2931
|
}
|
|
2859
|
-
function
|
|
2860
|
-
return
|
|
2932
|
+
function ta(e) {
|
|
2933
|
+
return le(e).slice(0, 8).replace(/(\d{5})(\d)/, "$1-$2");
|
|
2861
2934
|
}
|
|
2862
|
-
function
|
|
2863
|
-
return
|
|
2935
|
+
function na(e) {
|
|
2936
|
+
return le(e).slice(0, 14).replace(/(\d{2})(\d)/, "$1.$2").replace(/(\d{3})(\d)/, "$1.$2").replace(/(\d{3})(\d)/, "$1/$2").replace(/(\d{4})(\d)/, "$1-$2");
|
|
2864
2937
|
}
|
|
2865
|
-
function
|
|
2866
|
-
return
|
|
2938
|
+
function nl(e) {
|
|
2939
|
+
return le(e);
|
|
2867
2940
|
}
|
|
2868
|
-
function
|
|
2941
|
+
function rl(e) {
|
|
2869
2942
|
return new Intl.NumberFormat("pt-BR", {
|
|
2870
2943
|
style: "currency",
|
|
2871
2944
|
currency: "BRL"
|
|
2872
2945
|
}).format(e);
|
|
2873
2946
|
}
|
|
2874
|
-
function
|
|
2947
|
+
function sl(e) {
|
|
2875
2948
|
const t = typeof e == "string" ? new Date(e) : e;
|
|
2876
2949
|
return Number.isNaN(t.getTime()) ? "" : new Intl.DateTimeFormat("pt-BR").format(t);
|
|
2877
2950
|
}
|
|
2878
|
-
function
|
|
2951
|
+
function ol(e) {
|
|
2879
2952
|
const t = typeof e == "string" ? new Date(e) : e;
|
|
2880
2953
|
return Number.isNaN(t.getTime()) ? "" : new Intl.DateTimeFormat("pt-BR", {
|
|
2881
2954
|
dateStyle: "short",
|
|
2882
2955
|
timeStyle: "short"
|
|
2883
2956
|
}).format(t);
|
|
2884
2957
|
}
|
|
2885
|
-
function
|
|
2958
|
+
function ra(e) {
|
|
2886
2959
|
const t = e.replace(/\D/g, "").slice(0, 11);
|
|
2887
2960
|
return t.length <= 10 ? t.replace(/(\d{2})(\d)/, "($1) $2").replace(/(\d{4})(\d)/, "$1-$2") : t.replace(/(\d{2})(\d)/, "($1) $2").replace(/(\d{5})(\d)/, "$1-$2");
|
|
2888
2961
|
}
|
|
2889
|
-
function
|
|
2962
|
+
function sa(e) {
|
|
2890
2963
|
return e.replace(/\D/g, "").slice(0, 11).replace(/(\d{3})(\d)/, "$1.$2").replace(/(\d{3})(\d)/, "$1.$2").replace(/(\d{3})(\d{1,2})$/, "$1-$2");
|
|
2891
2964
|
}
|
|
2892
|
-
function
|
|
2965
|
+
function il(e) {
|
|
2893
2966
|
return new Intl.NumberFormat("pt-BR", {
|
|
2894
2967
|
style: "percent",
|
|
2895
2968
|
minimumFractionDigits: 1,
|
|
2896
2969
|
maximumFractionDigits: 1
|
|
2897
2970
|
}).format(e);
|
|
2898
2971
|
}
|
|
2899
|
-
function
|
|
2900
|
-
return
|
|
2972
|
+
function fe(e, t = "numeric") {
|
|
2973
|
+
return W(function({ value: r, onChange: s, ...o }, i) {
|
|
2901
2974
|
return /* @__PURE__ */ l(
|
|
2902
|
-
|
|
2975
|
+
Se,
|
|
2903
2976
|
{
|
|
2904
2977
|
...o,
|
|
2905
2978
|
ref: i,
|
|
@@ -2910,28 +2983,28 @@ function pe(e, t = "numeric") {
|
|
|
2910
2983
|
);
|
|
2911
2984
|
});
|
|
2912
2985
|
}
|
|
2913
|
-
const
|
|
2914
|
-
function
|
|
2986
|
+
const al = fe(sa), cl = fe(na), ll = fe(ra, "tel"), ul = fe(ta);
|
|
2987
|
+
function oa(e, t, n) {
|
|
2915
2988
|
return new Intl.NumberFormat(t, { style: "currency", currency: n }).format(e / 100);
|
|
2916
2989
|
}
|
|
2917
|
-
function
|
|
2990
|
+
function ia(e) {
|
|
2918
2991
|
const t = e.replace(/\D/g, "");
|
|
2919
2992
|
return t ? Number.parseInt(t, 10) : 0;
|
|
2920
2993
|
}
|
|
2921
|
-
const
|
|
2994
|
+
const dl = W(function({ value: t, onChange: n, currency: r = "BRL", locale: s = "pt-BR", ...o }, i) {
|
|
2922
2995
|
return /* @__PURE__ */ l(
|
|
2923
|
-
|
|
2996
|
+
Se,
|
|
2924
2997
|
{
|
|
2925
2998
|
...o,
|
|
2926
2999
|
ref: i,
|
|
2927
3000
|
type: "text",
|
|
2928
3001
|
inputMode: "numeric",
|
|
2929
|
-
value:
|
|
2930
|
-
onChange: (c) => n(
|
|
3002
|
+
value: oa(t || 0, s, r),
|
|
3003
|
+
onChange: (c) => n(ia(c.target.value))
|
|
2931
3004
|
}
|
|
2932
3005
|
);
|
|
2933
3006
|
});
|
|
2934
|
-
function
|
|
3007
|
+
function pl() {
|
|
2935
3008
|
const [e, t] = v(!1), [n, r] = v(null), [s, o] = v(null), i = S(async (a) => {
|
|
2936
3009
|
const u = a.replace(/\D/g, "");
|
|
2937
3010
|
if (u.length !== 8)
|
|
@@ -2950,14 +3023,14 @@ function Uc() {
|
|
|
2950
3023
|
}, []);
|
|
2951
3024
|
return { loading: e, error: n, data: s, lookup: i, reset: c };
|
|
2952
3025
|
}
|
|
2953
|
-
function
|
|
3026
|
+
function aa(e) {
|
|
2954
3027
|
try {
|
|
2955
3028
|
return JSON.parse(e);
|
|
2956
3029
|
} catch {
|
|
2957
3030
|
return e;
|
|
2958
3031
|
}
|
|
2959
3032
|
}
|
|
2960
|
-
function
|
|
3033
|
+
function ca(e, t = {}) {
|
|
2961
3034
|
const {
|
|
2962
3035
|
protocols: n,
|
|
2963
3036
|
maxRetries: r = 10,
|
|
@@ -2965,101 +3038,101 @@ function Oi(e, t = {}) {
|
|
|
2965
3038
|
maxBackoff: o = 3e4,
|
|
2966
3039
|
pingInterval: i = 0,
|
|
2967
3040
|
pingPayload: c = JSON.stringify({ type: "ping" }),
|
|
2968
|
-
parser: a =
|
|
3041
|
+
parser: a = aa,
|
|
2969
3042
|
onOpen: u,
|
|
2970
3043
|
onMessage: d,
|
|
2971
3044
|
onClose: p,
|
|
2972
3045
|
onError: f,
|
|
2973
|
-
onStatusChange:
|
|
3046
|
+
onStatusChange: h
|
|
2974
3047
|
} = t;
|
|
2975
|
-
let
|
|
2976
|
-
function
|
|
2977
|
-
|
|
3048
|
+
let _ = null, m = null, b = null, y = 0, $ = "idle", N = !1;
|
|
3049
|
+
function L(T) {
|
|
3050
|
+
$ !== T && ($ = T, h?.(T));
|
|
2978
3051
|
}
|
|
2979
|
-
function
|
|
3052
|
+
function D() {
|
|
2980
3053
|
b && (clearInterval(b), b = null);
|
|
2981
3054
|
}
|
|
2982
|
-
function
|
|
2983
|
-
!i || i <= 0 || (
|
|
2984
|
-
|
|
3055
|
+
function me() {
|
|
3056
|
+
!i || i <= 0 || (D(), b = setInterval(() => {
|
|
3057
|
+
_?.readyState === WebSocket.OPEN && _.send(c);
|
|
2985
3058
|
}, i));
|
|
2986
3059
|
}
|
|
2987
|
-
function
|
|
2988
|
-
if (
|
|
3060
|
+
function he() {
|
|
3061
|
+
if (N) return;
|
|
2989
3062
|
if (y >= r) {
|
|
2990
|
-
|
|
3063
|
+
L("error");
|
|
2991
3064
|
return;
|
|
2992
3065
|
}
|
|
2993
3066
|
const T = Math.min(s * 2 ** y, o);
|
|
2994
|
-
y += 1,
|
|
3067
|
+
y += 1, m = setTimeout(x, T);
|
|
2995
3068
|
}
|
|
2996
3069
|
function x() {
|
|
2997
|
-
if (
|
|
2998
|
-
|
|
3070
|
+
if (N) return;
|
|
3071
|
+
_ && (_.onopen = null, _.onmessage = null, _.onclose = null, _.onerror = null, _.close()), L("connecting");
|
|
2999
3072
|
const T = new WebSocket(e, n);
|
|
3000
|
-
|
|
3001
|
-
y = 0,
|
|
3002
|
-
}, T.onmessage = (
|
|
3003
|
-
const Qe = typeof
|
|
3073
|
+
_ = T, T.onopen = (P) => {
|
|
3074
|
+
y = 0, L("open"), me(), u?.(P);
|
|
3075
|
+
}, T.onmessage = (P) => {
|
|
3076
|
+
const Qe = typeof P.data == "string" ? P.data : "";
|
|
3004
3077
|
d?.({
|
|
3005
3078
|
data: a(Qe),
|
|
3006
|
-
raw:
|
|
3079
|
+
raw: P
|
|
3007
3080
|
});
|
|
3008
|
-
}, T.onerror = (
|
|
3009
|
-
f?.(
|
|
3010
|
-
}, T.onclose = (
|
|
3011
|
-
|
|
3081
|
+
}, T.onerror = (P) => {
|
|
3082
|
+
f?.(P);
|
|
3083
|
+
}, T.onclose = (P) => {
|
|
3084
|
+
D(), p?.(P), _ = null, L("closed"), !N && !P.wasClean && he();
|
|
3012
3085
|
};
|
|
3013
3086
|
}
|
|
3014
|
-
function
|
|
3015
|
-
return
|
|
3087
|
+
function I(T) {
|
|
3088
|
+
return _?.readyState !== WebSocket.OPEN ? !1 : (_.send(T), !0);
|
|
3016
3089
|
}
|
|
3017
|
-
function
|
|
3018
|
-
|
|
3090
|
+
function _e(T, P) {
|
|
3091
|
+
N = !0, m && (clearTimeout(m), m = null), D(), y = 0, _ && (L("closing"), _.close(T, P), _ = null), L("closed");
|
|
3019
3092
|
}
|
|
3020
3093
|
function Ve() {
|
|
3021
|
-
|
|
3094
|
+
m && (clearTimeout(m), m = null), y = 0, N = !1, x();
|
|
3022
3095
|
}
|
|
3023
3096
|
return x(), {
|
|
3024
|
-
send:
|
|
3025
|
-
close:
|
|
3097
|
+
send: I,
|
|
3098
|
+
close: _e,
|
|
3026
3099
|
reconnect: Ve,
|
|
3027
3100
|
get status() {
|
|
3028
|
-
return
|
|
3101
|
+
return $;
|
|
3029
3102
|
}
|
|
3030
3103
|
};
|
|
3031
3104
|
}
|
|
3032
|
-
function
|
|
3105
|
+
function fl(e, t = {}) {
|
|
3033
3106
|
const { enabled: n = !0, onMessage: r, ...s } = t, [o, i] = v("idle"), [c, a] = v(null), u = E(null), d = E(r);
|
|
3034
3107
|
d.current = r, k(() => {
|
|
3035
3108
|
if (!n || !e) {
|
|
3036
3109
|
i("idle");
|
|
3037
3110
|
return;
|
|
3038
3111
|
}
|
|
3039
|
-
const
|
|
3112
|
+
const h = ca(e, {
|
|
3040
3113
|
...s,
|
|
3041
3114
|
onStatusChange: i,
|
|
3042
|
-
onMessage: (
|
|
3043
|
-
a(
|
|
3115
|
+
onMessage: (_) => {
|
|
3116
|
+
a(_), d.current?.(_);
|
|
3044
3117
|
}
|
|
3045
3118
|
});
|
|
3046
|
-
return u.current =
|
|
3047
|
-
|
|
3119
|
+
return u.current = h, () => {
|
|
3120
|
+
h.close(), u.current = null;
|
|
3048
3121
|
};
|
|
3049
3122
|
}, [e, n]);
|
|
3050
3123
|
const p = S(
|
|
3051
|
-
(
|
|
3124
|
+
(h) => u.current?.send(h) ?? !1,
|
|
3052
3125
|
[]
|
|
3053
3126
|
), f = S(() => {
|
|
3054
3127
|
u.current?.reconnect();
|
|
3055
3128
|
}, []);
|
|
3056
3129
|
return { status: o, lastMessage: c, send: p, reconnect: f };
|
|
3057
3130
|
}
|
|
3058
|
-
const
|
|
3131
|
+
const Ue = re(null);
|
|
3059
3132
|
function Me(e) {
|
|
3060
3133
|
return e === "dark" || e === "light" ? e : typeof window > "u" ? "light" : window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
|
|
3061
3134
|
}
|
|
3062
|
-
function
|
|
3135
|
+
function la(e) {
|
|
3063
3136
|
if (!e || typeof window > "u") return null;
|
|
3064
3137
|
try {
|
|
3065
3138
|
const t = window.localStorage.getItem(e);
|
|
@@ -3068,7 +3141,7 @@ function Wi(e) {
|
|
|
3068
3141
|
return null;
|
|
3069
3142
|
}
|
|
3070
3143
|
}
|
|
3071
|
-
function
|
|
3144
|
+
function ml({
|
|
3072
3145
|
children: e,
|
|
3073
3146
|
defaultTheme: t = "system",
|
|
3074
3147
|
storageKey: n = "tempest-theme",
|
|
@@ -3076,44 +3149,44 @@ function Jc({
|
|
|
3076
3149
|
attribute: s = "data-tempest-theme"
|
|
3077
3150
|
}) {
|
|
3078
3151
|
const [o, i] = v(
|
|
3079
|
-
() =>
|
|
3152
|
+
() => la(n) ?? t
|
|
3080
3153
|
), [c, a] = v(() => Me(o)), u = E(r);
|
|
3081
3154
|
u.current = r, k(() => {
|
|
3082
|
-
const
|
|
3083
|
-
if (!
|
|
3084
|
-
const
|
|
3085
|
-
|
|
3155
|
+
const h = u.current?.() ?? document.documentElement;
|
|
3156
|
+
if (!h) return;
|
|
3157
|
+
const _ = Me(o);
|
|
3158
|
+
h.setAttribute(s, _), a(_);
|
|
3086
3159
|
}, [o, s]), k(() => {
|
|
3087
3160
|
if (o !== "system" || typeof window > "u") return;
|
|
3088
|
-
const
|
|
3089
|
-
const
|
|
3090
|
-
|
|
3161
|
+
const h = window.matchMedia("(prefers-color-scheme: dark)"), _ = () => {
|
|
3162
|
+
const m = u.current?.() ?? document.documentElement, b = h.matches ? "dark" : "light";
|
|
3163
|
+
m?.setAttribute(s, b), a(b);
|
|
3091
3164
|
};
|
|
3092
|
-
return
|
|
3165
|
+
return h.addEventListener("change", _), () => h.removeEventListener("change", _);
|
|
3093
3166
|
}, [o, s]);
|
|
3094
3167
|
const d = S(
|
|
3095
|
-
(
|
|
3096
|
-
if (i(
|
|
3168
|
+
(h) => {
|
|
3169
|
+
if (i(h), n && typeof window < "u")
|
|
3097
3170
|
try {
|
|
3098
|
-
window.localStorage.setItem(n,
|
|
3171
|
+
window.localStorage.setItem(n, h);
|
|
3099
3172
|
} catch {
|
|
3100
3173
|
}
|
|
3101
3174
|
},
|
|
3102
3175
|
[n]
|
|
3103
3176
|
), p = S(() => {
|
|
3104
3177
|
d(c === "dark" ? "light" : "dark");
|
|
3105
|
-
}, [c, d]), f =
|
|
3178
|
+
}, [c, d]), f = B(
|
|
3106
3179
|
() => ({ theme: o, resolvedTheme: c, setTheme: d, toggle: p }),
|
|
3107
3180
|
[o, c, d, p]
|
|
3108
3181
|
);
|
|
3109
|
-
return /* @__PURE__ */ l(
|
|
3182
|
+
return /* @__PURE__ */ l(Ue.Provider, { value: f, children: e });
|
|
3110
3183
|
}
|
|
3111
|
-
function
|
|
3112
|
-
const e =
|
|
3184
|
+
function hl() {
|
|
3185
|
+
const e = ne(Ue);
|
|
3113
3186
|
if (!e) throw new Error("useTheme must be used inside a <ThemeProvider>");
|
|
3114
3187
|
return e;
|
|
3115
3188
|
}
|
|
3116
|
-
function
|
|
3189
|
+
function _l(e = {}) {
|
|
3117
3190
|
const { storageKey: t = "tempest-theme", defaultTheme: n = "system" } = e;
|
|
3118
3191
|
if (typeof window > "u")
|
|
3119
3192
|
return n === "dark" ? "dark" : "light";
|
|
@@ -3126,7 +3199,7 @@ function qc(e = {}) {
|
|
|
3126
3199
|
const s = r ?? n;
|
|
3127
3200
|
return s === "dark" || s === "light" ? s : window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
|
|
3128
3201
|
}
|
|
3129
|
-
function
|
|
3202
|
+
function gl(e = {}) {
|
|
3130
3203
|
const t = e.storageKey ?? "tempest-theme", n = e.defaultTheme ?? "system";
|
|
3131
3204
|
return `
|
|
3132
3205
|
(function(){try{
|
|
@@ -3145,7 +3218,7 @@ function Pe(e, t) {
|
|
|
3145
3218
|
return s === void 0 ? `{${r}}` : String(s);
|
|
3146
3219
|
}) : e;
|
|
3147
3220
|
}
|
|
3148
|
-
function
|
|
3221
|
+
function ve(e, t, n, r) {
|
|
3149
3222
|
const s = e[t]?.[r];
|
|
3150
3223
|
if (s !== void 0) return s;
|
|
3151
3224
|
if (n) {
|
|
@@ -3154,14 +3227,14 @@ function be(e, t, n, r) {
|
|
|
3154
3227
|
}
|
|
3155
3228
|
return null;
|
|
3156
3229
|
}
|
|
3157
|
-
function
|
|
3230
|
+
function qe(e) {
|
|
3158
3231
|
const { locale: t, fallbackLocale: n = null, messages: r } = e;
|
|
3159
3232
|
function s(a, u) {
|
|
3160
|
-
const d =
|
|
3233
|
+
const d = ve(r, t, n, a);
|
|
3161
3234
|
return d === null ? a : Pe(d, u);
|
|
3162
3235
|
}
|
|
3163
3236
|
function o(a, u, d) {
|
|
3164
|
-
const f =
|
|
3237
|
+
const f = ve(r, t, n, `${a}${u === 1 ? "_one" : "_other"}`) ?? ve(r, t, n, a);
|
|
3165
3238
|
return f === null ? a : Pe(f, { count: u, ...d ?? {} });
|
|
3166
3239
|
}
|
|
3167
3240
|
function i(a, u) {
|
|
@@ -3178,15 +3251,15 @@ function Je(e) {
|
|
|
3178
3251
|
plural: o,
|
|
3179
3252
|
formatNumber: i,
|
|
3180
3253
|
formatDate: c,
|
|
3181
|
-
withLocale: (a) =>
|
|
3254
|
+
withLocale: (a) => qe({
|
|
3182
3255
|
locale: a,
|
|
3183
3256
|
fallbackLocale: n ?? void 0,
|
|
3184
3257
|
messages: r
|
|
3185
3258
|
})
|
|
3186
3259
|
};
|
|
3187
3260
|
}
|
|
3188
|
-
const
|
|
3189
|
-
function
|
|
3261
|
+
const Je = re(null);
|
|
3262
|
+
function ua(e, t) {
|
|
3190
3263
|
if (!e || typeof window > "u") return null;
|
|
3191
3264
|
try {
|
|
3192
3265
|
const n = window.localStorage.getItem(e);
|
|
@@ -3195,15 +3268,15 @@ function Bi(e, t) {
|
|
|
3195
3268
|
return null;
|
|
3196
3269
|
}
|
|
3197
3270
|
}
|
|
3198
|
-
function
|
|
3271
|
+
function yl({
|
|
3199
3272
|
children: e,
|
|
3200
3273
|
locale: t,
|
|
3201
3274
|
fallbackLocale: n,
|
|
3202
3275
|
messages: r,
|
|
3203
3276
|
storageKey: s = "tempest-locale"
|
|
3204
3277
|
}) {
|
|
3205
|
-
const o =
|
|
3206
|
-
() =>
|
|
3278
|
+
const o = B(() => Object.keys(r), [r]), [i, c] = v(
|
|
3279
|
+
() => ua(s, o) ?? t
|
|
3207
3280
|
);
|
|
3208
3281
|
k(() => {
|
|
3209
3282
|
typeof document < "u" && document.documentElement.setAttribute("lang", i);
|
|
@@ -3217,29 +3290,29 @@ function Kc({
|
|
|
3217
3290
|
}
|
|
3218
3291
|
},
|
|
3219
3292
|
[s]
|
|
3220
|
-
), u =
|
|
3221
|
-
return /* @__PURE__ */ l(
|
|
3293
|
+
), u = B(() => ({ ...qe({ locale: i, fallbackLocale: n, messages: r }), setLocale: a, availableLocales: o }), [i, n, r, a, o]);
|
|
3294
|
+
return /* @__PURE__ */ l(Je.Provider, { value: u, children: e });
|
|
3222
3295
|
}
|
|
3223
|
-
function
|
|
3224
|
-
const e =
|
|
3296
|
+
function da() {
|
|
3297
|
+
const e = ne(Je);
|
|
3225
3298
|
if (!e) throw new Error("useI18n must be used inside an <I18nProvider>");
|
|
3226
3299
|
return e;
|
|
3227
3300
|
}
|
|
3228
|
-
function
|
|
3229
|
-
return
|
|
3301
|
+
function wl() {
|
|
3302
|
+
return da().t;
|
|
3230
3303
|
}
|
|
3231
3304
|
const Ae = ["debug", "info", "warn", "error"];
|
|
3232
|
-
function
|
|
3305
|
+
function pa(e, t) {
|
|
3233
3306
|
return Ae.indexOf(t) >= Ae.indexOf(e);
|
|
3234
3307
|
}
|
|
3235
|
-
const
|
|
3308
|
+
const fa = ({ level: e, message: t, context: n }) => {
|
|
3236
3309
|
const r = e === "debug" ? "log" : e;
|
|
3237
3310
|
n ? console[r](t, n) : console[r](t);
|
|
3238
3311
|
};
|
|
3239
|
-
function
|
|
3240
|
-
const t = e.level ?? "info", n = e.sinks ?? [
|
|
3312
|
+
function ma(e = {}) {
|
|
3313
|
+
const t = e.level ?? "info", n = e.sinks ?? [fa], r = e.namespace ?? "";
|
|
3241
3314
|
function s(o, i, c) {
|
|
3242
|
-
if (!
|
|
3315
|
+
if (!pa(t, o)) return;
|
|
3243
3316
|
const a = {
|
|
3244
3317
|
level: o,
|
|
3245
3318
|
message: r ? `[${r}] ${i}` : i,
|
|
@@ -3257,25 +3330,25 @@ function Ji(e = {}) {
|
|
|
3257
3330
|
info: (o, i) => s("info", o, i),
|
|
3258
3331
|
warn: (o, i) => s("warn", o, i),
|
|
3259
3332
|
error: (o, i) => s("error", o, i),
|
|
3260
|
-
child: (o) =>
|
|
3333
|
+
child: (o) => ma({
|
|
3261
3334
|
level: t,
|
|
3262
3335
|
sinks: n,
|
|
3263
3336
|
namespace: r ? `${r}:${o}` : o
|
|
3264
3337
|
})
|
|
3265
3338
|
};
|
|
3266
3339
|
}
|
|
3267
|
-
const
|
|
3268
|
-
function
|
|
3340
|
+
const Ge = re(null);
|
|
3341
|
+
function bl({ adapter: e, children: t }) {
|
|
3269
3342
|
k(() => (e.init?.(), () => {
|
|
3270
3343
|
e.flush?.();
|
|
3271
3344
|
}), [e]);
|
|
3272
|
-
const n =
|
|
3273
|
-
return /* @__PURE__ */ l(
|
|
3345
|
+
const n = B(() => e, [e]);
|
|
3346
|
+
return /* @__PURE__ */ l(Ge.Provider, { value: n, children: t });
|
|
3274
3347
|
}
|
|
3275
|
-
function
|
|
3276
|
-
return
|
|
3348
|
+
function vl() {
|
|
3349
|
+
return ne(Ge);
|
|
3277
3350
|
}
|
|
3278
|
-
const
|
|
3351
|
+
const $l = {
|
|
3279
3352
|
identify(e) {
|
|
3280
3353
|
console.info("[telemetry] identify", e);
|
|
3281
3354
|
},
|
|
@@ -3286,7 +3359,7 @@ const Xc = {
|
|
|
3286
3359
|
console.error("[telemetry] exception", e, t);
|
|
3287
3360
|
}
|
|
3288
3361
|
};
|
|
3289
|
-
function
|
|
3362
|
+
function ha(e) {
|
|
3290
3363
|
if (e === null) return null;
|
|
3291
3364
|
const { id: t, email: n, name: r, traits: s } = e;
|
|
3292
3365
|
return {
|
|
@@ -3296,14 +3369,14 @@ function Gi(e) {
|
|
|
3296
3369
|
...s ?? null
|
|
3297
3370
|
};
|
|
3298
3371
|
}
|
|
3299
|
-
function
|
|
3372
|
+
function Nl(e) {
|
|
3300
3373
|
const { sentry: t, initOptions: n, flushTimeout: r = 2e3, breadcrumbCategory: s = "app" } = e;
|
|
3301
3374
|
return {
|
|
3302
3375
|
init() {
|
|
3303
3376
|
n && t.init && t.init(n);
|
|
3304
3377
|
},
|
|
3305
3378
|
identify(o) {
|
|
3306
|
-
t.setUser(
|
|
3379
|
+
t.setUser(ha(o));
|
|
3307
3380
|
},
|
|
3308
3381
|
track(o) {
|
|
3309
3382
|
t.addBreadcrumb({
|
|
@@ -3321,7 +3394,7 @@ function Zc(e) {
|
|
|
3321
3394
|
}
|
|
3322
3395
|
};
|
|
3323
3396
|
}
|
|
3324
|
-
function
|
|
3397
|
+
function _a(e) {
|
|
3325
3398
|
const { email: t, name: n, traits: r } = e;
|
|
3326
3399
|
return {
|
|
3327
3400
|
...t !== void 0 ? { email: t } : null,
|
|
@@ -3329,7 +3402,7 @@ function qi(e) {
|
|
|
3329
3402
|
...r ?? null
|
|
3330
3403
|
};
|
|
3331
3404
|
}
|
|
3332
|
-
function
|
|
3405
|
+
function kl(e) {
|
|
3333
3406
|
const { posthog: t, init: n } = e;
|
|
3334
3407
|
return {
|
|
3335
3408
|
init() {
|
|
@@ -3340,7 +3413,7 @@ function el(e) {
|
|
|
3340
3413
|
t.reset?.();
|
|
3341
3414
|
return;
|
|
3342
3415
|
}
|
|
3343
|
-
r.id !== void 0 && t.identify(r.id,
|
|
3416
|
+
r.id !== void 0 && t.identify(r.id, _a(r));
|
|
3344
3417
|
},
|
|
3345
3418
|
track(r) {
|
|
3346
3419
|
t.capture(r.name, r.properties);
|
|
@@ -3360,28 +3433,28 @@ function el(e) {
|
|
|
3360
3433
|
}
|
|
3361
3434
|
};
|
|
3362
3435
|
}
|
|
3363
|
-
const He =
|
|
3364
|
-
function
|
|
3365
|
-
const n =
|
|
3436
|
+
const He = re(null);
|
|
3437
|
+
function xl({ adapter: e, children: t }) {
|
|
3438
|
+
const n = B(() => e, [e]);
|
|
3366
3439
|
return k(() => {
|
|
3367
3440
|
}, [n]), /* @__PURE__ */ l(He.Provider, { value: n, children: t });
|
|
3368
3441
|
}
|
|
3369
3442
|
function Ke() {
|
|
3370
|
-
const e =
|
|
3443
|
+
const e = ne(He);
|
|
3371
3444
|
if (!e) throw new Error("useFeatureFlag requires <FeatureFlagsProvider>");
|
|
3372
3445
|
return e;
|
|
3373
3446
|
}
|
|
3374
|
-
function
|
|
3447
|
+
function Sl(e, t = !1) {
|
|
3375
3448
|
const n = Ke(), r = (o) => n.onChange ? n.onChange(o) : () => {
|
|
3376
3449
|
}, s = () => n.isEnabled(e, t);
|
|
3377
3450
|
return Fe(r, s, s);
|
|
3378
3451
|
}
|
|
3379
|
-
function
|
|
3452
|
+
function El(e, t) {
|
|
3380
3453
|
const n = Ke(), r = (o) => n.onChange ? n.onChange(o) : () => {
|
|
3381
3454
|
}, s = () => n.get(e, t);
|
|
3382
3455
|
return Fe(r, s, s);
|
|
3383
3456
|
}
|
|
3384
|
-
function
|
|
3457
|
+
function Tl(e = {}) {
|
|
3385
3458
|
const t = { ...e.initial ?? {} }, n = /* @__PURE__ */ new Set();
|
|
3386
3459
|
function r() {
|
|
3387
3460
|
for (const s of n) s();
|
|
@@ -3401,7 +3474,7 @@ function sl(e = {}) {
|
|
|
3401
3474
|
}
|
|
3402
3475
|
};
|
|
3403
3476
|
}
|
|
3404
|
-
function
|
|
3477
|
+
function Cl(e) {
|
|
3405
3478
|
const { growthbook: t } = e, n = /* @__PURE__ */ new Set();
|
|
3406
3479
|
let r = !1;
|
|
3407
3480
|
function s() {
|
|
@@ -3424,7 +3497,7 @@ function ol(e) {
|
|
|
3424
3497
|
}
|
|
3425
3498
|
};
|
|
3426
3499
|
}
|
|
3427
|
-
function
|
|
3500
|
+
function Ll(e) {
|
|
3428
3501
|
const { client: t } = e;
|
|
3429
3502
|
return {
|
|
3430
3503
|
isEnabled(n, r = !1) {
|
|
@@ -3441,7 +3514,7 @@ function il(e) {
|
|
|
3441
3514
|
}
|
|
3442
3515
|
};
|
|
3443
3516
|
}
|
|
3444
|
-
async function
|
|
3517
|
+
async function Il(e) {
|
|
3445
3518
|
if (typeof navigator > "u" || !("share" in navigator))
|
|
3446
3519
|
return { shared: !1, unsupported: !0, cancelled: !1 };
|
|
3447
3520
|
if (e.files && !navigator.canShare?.({ files: e.files }))
|
|
@@ -3452,10 +3525,10 @@ async function al(e) {
|
|
|
3452
3525
|
return t instanceof DOMException && t.name === "AbortError" ? { shared: !1, unsupported: !1, cancelled: !0 } : { shared: !1, unsupported: !1, cancelled: !1, error: t };
|
|
3453
3526
|
}
|
|
3454
3527
|
}
|
|
3455
|
-
function
|
|
3528
|
+
function Dl() {
|
|
3456
3529
|
return typeof navigator < "u" && "share" in navigator;
|
|
3457
3530
|
}
|
|
3458
|
-
const
|
|
3531
|
+
const Ml = {
|
|
3459
3532
|
get(e, t) {
|
|
3460
3533
|
if (typeof window > "u") return t;
|
|
3461
3534
|
try {
|
|
@@ -3481,146 +3554,146 @@ const ll = {
|
|
|
3481
3554
|
}
|
|
3482
3555
|
};
|
|
3483
3556
|
export {
|
|
3484
|
-
|
|
3485
|
-
|
|
3486
|
-
|
|
3487
|
-
|
|
3488
|
-
|
|
3489
|
-
|
|
3490
|
-
|
|
3491
|
-
|
|
3492
|
-
|
|
3493
|
-
|
|
3494
|
-
|
|
3495
|
-
|
|
3496
|
-
|
|
3497
|
-
|
|
3498
|
-
|
|
3499
|
-
|
|
3500
|
-
|
|
3501
|
-
|
|
3502
|
-
|
|
3503
|
-
|
|
3504
|
-
|
|
3505
|
-
|
|
3506
|
-
|
|
3507
|
-
|
|
3508
|
-
|
|
3509
|
-
|
|
3510
|
-
|
|
3511
|
-
|
|
3512
|
-
|
|
3513
|
-
|
|
3514
|
-
|
|
3515
|
-
|
|
3516
|
-
|
|
3517
|
-
|
|
3518
|
-
|
|
3519
|
-
|
|
3520
|
-
|
|
3521
|
-
|
|
3522
|
-
|
|
3523
|
-
|
|
3524
|
-
|
|
3525
|
-
|
|
3526
|
-
|
|
3527
|
-
|
|
3528
|
-
|
|
3529
|
-
|
|
3530
|
-
|
|
3531
|
-
|
|
3532
|
-
|
|
3533
|
-
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
|
|
3537
|
-
|
|
3538
|
-
|
|
3557
|
+
Ic as AuthGuard,
|
|
3558
|
+
xa as Avatar,
|
|
3559
|
+
Sa as Badge,
|
|
3560
|
+
Ea as Breadcrumbs,
|
|
3561
|
+
$e as Button,
|
|
3562
|
+
Gi as CACHE_TIME,
|
|
3563
|
+
ul as CEPInput,
|
|
3564
|
+
cl as CNPJInput,
|
|
3565
|
+
al as CPFInput,
|
|
3566
|
+
Ta as Card,
|
|
3567
|
+
Ca as Checkbox,
|
|
3568
|
+
La as ChipInput,
|
|
3569
|
+
Ia as ConfirmDialog,
|
|
3570
|
+
za as Container,
|
|
3571
|
+
Da as DatePicker,
|
|
3572
|
+
Ma as Drawer,
|
|
3573
|
+
Pa as EmptyState,
|
|
3574
|
+
Qc as ErrorBoundary,
|
|
3575
|
+
Aa as ErrorState,
|
|
3576
|
+
xl as FeatureFlagsProvider,
|
|
3577
|
+
Ra as FileUpload,
|
|
3578
|
+
Fa as Form,
|
|
3579
|
+
Ba as FormActions,
|
|
3580
|
+
Wa as FormRow,
|
|
3581
|
+
Oa as FormSection,
|
|
3582
|
+
Ua as Grid,
|
|
3583
|
+
yl as I18nProvider,
|
|
3584
|
+
Se as Input,
|
|
3585
|
+
Qn as Modal,
|
|
3586
|
+
dl as MoneyInput,
|
|
3587
|
+
qa as Pagination,
|
|
3588
|
+
ll as PhoneInput,
|
|
3589
|
+
Ja as Progress,
|
|
3590
|
+
Fc as QueryProvider,
|
|
3591
|
+
Ac as REFETCH_TIME,
|
|
3592
|
+
Ga as Radio,
|
|
3593
|
+
Ha as RadioGroup,
|
|
3594
|
+
Ji as STALE_TIME,
|
|
3595
|
+
Ka as SearchBar,
|
|
3596
|
+
Va as Select,
|
|
3597
|
+
Qa as Skeleton,
|
|
3598
|
+
Ya as Spinner,
|
|
3599
|
+
ja as Stack,
|
|
3600
|
+
Za as Stepper,
|
|
3601
|
+
Xa as Switch,
|
|
3602
|
+
ec as Table,
|
|
3603
|
+
tc as Tabs,
|
|
3604
|
+
bl as TelemetryProvider,
|
|
3605
|
+
nc as Textarea,
|
|
3606
|
+
ml as ThemeProvider,
|
|
3607
|
+
oc as ToastProvider,
|
|
3608
|
+
rc as Tooltip,
|
|
3609
|
+
ic as VirtualList,
|
|
3610
|
+
Yi as WebPushClient,
|
|
3611
|
+
Qi as WebPushPermissionDeniedError,
|
|
3539
3612
|
De as WebPushUnsupportedError,
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3543
|
-
|
|
3544
|
-
|
|
3545
|
-
|
|
3546
|
-
|
|
3547
|
-
|
|
3548
|
-
|
|
3549
|
-
|
|
3550
|
-
|
|
3551
|
-
|
|
3552
|
-
|
|
3553
|
-
|
|
3554
|
-
|
|
3555
|
-
|
|
3556
|
-
|
|
3557
|
-
|
|
3558
|
-
|
|
3559
|
-
|
|
3560
|
-
|
|
3561
|
-
|
|
3562
|
-
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
-
|
|
3566
|
-
|
|
3567
|
-
|
|
3568
|
-
|
|
3569
|
-
|
|
3570
|
-
|
|
3571
|
-
|
|
3572
|
-
|
|
3573
|
-
|
|
3574
|
-
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
|
|
3578
|
-
|
|
3579
|
-
|
|
3580
|
-
|
|
3581
|
-
|
|
3582
|
-
|
|
3583
|
-
|
|
3584
|
-
|
|
3585
|
-
|
|
3586
|
-
|
|
3587
|
-
|
|
3588
|
-
|
|
3589
|
-
|
|
3590
|
-
|
|
3591
|
-
|
|
3592
|
-
|
|
3593
|
-
|
|
3594
|
-
|
|
3595
|
-
|
|
3596
|
-
|
|
3597
|
-
|
|
3598
|
-
|
|
3599
|
-
|
|
3600
|
-
|
|
3601
|
-
|
|
3602
|
-
|
|
3603
|
-
|
|
3604
|
-
|
|
3605
|
-
|
|
3606
|
-
|
|
3607
|
-
|
|
3608
|
-
|
|
3609
|
-
|
|
3610
|
-
|
|
3611
|
-
|
|
3612
|
-
|
|
3613
|
-
|
|
3614
|
-
|
|
3615
|
-
|
|
3616
|
-
|
|
3617
|
-
|
|
3618
|
-
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
|
|
3622
|
-
|
|
3623
|
-
|
|
3624
|
-
|
|
3613
|
+
g as cn,
|
|
3614
|
+
fa as consoleSink,
|
|
3615
|
+
$l as consoleTelemetryAdapter,
|
|
3616
|
+
kc as createApiClient,
|
|
3617
|
+
ze as createAudioPlayer,
|
|
3618
|
+
Lc as createAuthStore,
|
|
3619
|
+
Ki as createEventStream,
|
|
3620
|
+
Cl as createGrowthBookFeatureFlagsAdapter,
|
|
3621
|
+
qe as createI18n,
|
|
3622
|
+
Tl as createInMemoryFlags,
|
|
3623
|
+
Ll as createLaunchDarklyFeatureFlagsAdapter,
|
|
3624
|
+
ma as createLogger,
|
|
3625
|
+
Vc as createOfflineStore,
|
|
3626
|
+
kl as createPostHogTelemetryAdapter,
|
|
3627
|
+
Rc as createQueryKeys,
|
|
3628
|
+
Pc as createRefreshQueue,
|
|
3629
|
+
Nl as createSentryTelemetryAdapter,
|
|
3630
|
+
ca as createWebSocket,
|
|
3631
|
+
qi as decodeJWT,
|
|
3632
|
+
ta as formatCEP,
|
|
3633
|
+
na as formatCNPJ,
|
|
3634
|
+
sa as formatCPF,
|
|
3635
|
+
rl as formatCurrency,
|
|
3636
|
+
sl as formatDate,
|
|
3637
|
+
ol as formatDateTime,
|
|
3638
|
+
il as formatPercent,
|
|
3639
|
+
ra as formatPhone,
|
|
3640
|
+
Tc as generateIdempotencyKey,
|
|
3641
|
+
_l as getInitialTheme,
|
|
3642
|
+
qc as installNotificationClickHandler,
|
|
3643
|
+
Uc as installPushHandler,
|
|
3644
|
+
Jc as installSkipWaitingListener,
|
|
3645
|
+
Dc as isJWTExpired,
|
|
3646
|
+
de as isPushSupported,
|
|
3647
|
+
Dl as isShareSupported,
|
|
3648
|
+
Mc as lazyWithRetry,
|
|
3649
|
+
xc as parseResponse,
|
|
3650
|
+
Gc as playAudio,
|
|
3651
|
+
Bc as registerServiceWorker,
|
|
3652
|
+
Ec as retry,
|
|
3653
|
+
Il as share,
|
|
3654
|
+
zc as skipWaiting,
|
|
3655
|
+
Hc as stopAudio,
|
|
3656
|
+
Ml as storage,
|
|
3657
|
+
gl as themeInitScript,
|
|
3658
|
+
nl as unmask,
|
|
3659
|
+
jc as unregisterAllServiceWorkers,
|
|
3660
|
+
Sc as uploadWithProgress,
|
|
3661
|
+
Vi as urlBase64ToUint8Array,
|
|
3662
|
+
Kc as useAudio,
|
|
3663
|
+
gc as useBeforeInstallPrompt,
|
|
3664
|
+
lc as useClientFilter,
|
|
3665
|
+
hc as useClipboard,
|
|
3666
|
+
ac as useDebounce,
|
|
3667
|
+
Nc as useDeepMemo,
|
|
3668
|
+
pc as useDocumentVisibility,
|
|
3669
|
+
Yc as useErrorHandler,
|
|
3670
|
+
Oc as useEventStream,
|
|
3671
|
+
Sl as useFeatureFlag,
|
|
3672
|
+
El as useFlagValue,
|
|
3673
|
+
vc as useFocusTrap,
|
|
3674
|
+
wc as useGeolocation,
|
|
3675
|
+
da as useI18n,
|
|
3676
|
+
yc as useIdle,
|
|
3677
|
+
fc as useIntersectionObserver,
|
|
3678
|
+
_c as useKeyboardShortcut,
|
|
3679
|
+
uc as useMediaQuery,
|
|
3680
|
+
dc as useOnline,
|
|
3681
|
+
cc as usePagination,
|
|
3682
|
+
Cc as usePoll,
|
|
3683
|
+
Wc as usePushSubscription,
|
|
3684
|
+
mc as useResizeObserver,
|
|
3685
|
+
bc as useScrollLock,
|
|
3686
|
+
$c as useStableCallback,
|
|
3687
|
+
vl as useTelemetry,
|
|
3688
|
+
hl as useTheme,
|
|
3689
|
+
sc as useToast,
|
|
3690
|
+
wl as useTranslate,
|
|
3691
|
+
pl as useViaCEP,
|
|
3692
|
+
fl as useWebSocket,
|
|
3693
|
+
Xc as useZodForm,
|
|
3694
|
+
tl as validateCNPJ,
|
|
3695
|
+
el as validateCPF,
|
|
3696
|
+
Zc as validateForm,
|
|
3697
|
+
ea as zodResolver
|
|
3625
3698
|
};
|
|
3626
3699
|
//# sourceMappingURL=tempest-react-sdk.js.map
|