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