@zeo-app/design-system 0.3.1 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Icon/Icon.d.ts +8 -0
- package/dist/components/Icon/ModuleIcons.d.ts +8 -0
- package/dist/components/Icon/index.d.ts +3 -0
- package/dist/components/Shell/AppNavbar.d.ts +14 -0
- package/dist/components/Shell/AppShellLayout.d.ts +18 -0
- package/dist/components/Shell/AppSidebar.d.ts +60 -0
- package/dist/components/Shell/HelpMenu.d.ts +13 -0
- package/dist/components/Shell/NavbarParts.d.ts +33 -0
- package/dist/components/Shell/UserMenu.d.ts +26 -0
- package/dist/components/Shell/index.d.ts +15 -0
- package/dist/components/Shell/moduleCatalog.d.ts +34 -0
- package/dist/components/Shell/useDismiss.d.ts +3 -0
- package/dist/components/index.d.ts +2 -0
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +1120 -516
- package/dist/lib.d.ts +1 -0
- package/dist/preset.cjs +1 -1
- package/dist/preset.d.ts +26 -50
- package/dist/preset.mjs +36 -56
- package/dist/style.css +1 -1
- package/dist/theme/ThemeProvider.d.ts +24 -0
- package/dist/theme/index.d.ts +4 -0
- package/dist/theme/tokens.d.ts +312 -0
- package/dist/tokens-B2LtOn7a.cjs +1 -0
- package/dist/tokens-CaVTghf2.js +114 -0
- package/package.json +65 -65
package/dist/index.mjs
CHANGED
|
@@ -1,39 +1,41 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { forwardRef as
|
|
3
|
-
import { createPortal as
|
|
4
|
-
|
|
1
|
+
import { jsxs as i, jsx as t, Fragment as ne } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as B, useState as k, useRef as M, useCallback as j, useLayoutEffect as xe, useEffect as C, useId as be, createContext as G, useMemo as ge, useContext as E } from "react";
|
|
3
|
+
import { createPortal as we } from "react-dom";
|
|
4
|
+
import { a as U, T as W } from "./tokens-CaVTghf2.js";
|
|
5
|
+
import { c as Xt, s as Pt } from "./tokens-CaVTghf2.js";
|
|
6
|
+
const ve = {
|
|
5
7
|
info: {
|
|
6
|
-
container: "bg-blue-50 border-blue-200 text-blue-800",
|
|
7
|
-
icon: "text-blue-500",
|
|
8
|
+
container: "bg-blue-50 border-blue-200 text-blue-800 dark:bg-info-container dark:border-info/30 dark:text-info",
|
|
9
|
+
icon: "text-blue-500 dark:text-info",
|
|
8
10
|
defaultIcon: "info"
|
|
9
11
|
},
|
|
10
12
|
success: {
|
|
11
|
-
container: "bg-green-50 border-green-200 text-green-800",
|
|
12
|
-
icon: "text-green-500",
|
|
13
|
+
container: "bg-green-50 border-green-200 text-green-800 dark:bg-success-container dark:border-success/30 dark:text-success",
|
|
14
|
+
icon: "text-green-500 dark:text-success",
|
|
13
15
|
defaultIcon: "check_circle"
|
|
14
16
|
},
|
|
15
17
|
warning: {
|
|
16
|
-
container: "bg-yellow-50 border-yellow-200 text-yellow-800",
|
|
17
|
-
icon: "text-yellow-500",
|
|
18
|
+
container: "bg-yellow-50 border-yellow-200 text-yellow-800 dark:bg-warning-container dark:border-warning/30 dark:text-warning",
|
|
19
|
+
icon: "text-yellow-500 dark:text-warning",
|
|
18
20
|
defaultIcon: "warning"
|
|
19
21
|
},
|
|
20
22
|
danger: {
|
|
21
|
-
container: "bg-red-50 border-red-200 text-red-800",
|
|
22
|
-
icon: "text-red-500",
|
|
23
|
+
container: "bg-red-50 border-red-200 text-red-800 dark:bg-danger-container dark:border-danger/30 dark:text-danger",
|
|
24
|
+
icon: "text-red-500 dark:text-danger",
|
|
23
25
|
defaultIcon: "error"
|
|
24
26
|
}
|
|
25
27
|
};
|
|
26
|
-
function
|
|
28
|
+
function ut({
|
|
27
29
|
variant: e = "info",
|
|
28
|
-
title:
|
|
29
|
-
children:
|
|
30
|
+
title: r,
|
|
31
|
+
children: n,
|
|
30
32
|
onClose: a,
|
|
31
33
|
icon: o,
|
|
32
34
|
className: s = "",
|
|
33
|
-
...
|
|
35
|
+
...l
|
|
34
36
|
}) {
|
|
35
|
-
const c =
|
|
36
|
-
return /* @__PURE__ */
|
|
37
|
+
const c = ve[e], d = o ?? c.defaultIcon;
|
|
38
|
+
return /* @__PURE__ */ i(
|
|
37
39
|
"div",
|
|
38
40
|
{
|
|
39
41
|
role: "alert",
|
|
@@ -42,165 +44,165 @@ function Ge({
|
|
|
42
44
|
c.container,
|
|
43
45
|
s
|
|
44
46
|
].filter(Boolean).join(" "),
|
|
45
|
-
...
|
|
47
|
+
...l,
|
|
46
48
|
children: [
|
|
47
|
-
/* @__PURE__ */
|
|
48
|
-
/* @__PURE__ */
|
|
49
|
-
|
|
50
|
-
/* @__PURE__ */
|
|
49
|
+
/* @__PURE__ */ t("span", { className: `material-symbols-outlined text-[20px] shrink-0 mt-0.5 ${c.icon}`, children: d }),
|
|
50
|
+
/* @__PURE__ */ i("div", { className: "flex-1 min-w-0", children: [
|
|
51
|
+
r && /* @__PURE__ */ t("p", { className: "font-semibold text-sm mb-0.5", children: r }),
|
|
52
|
+
/* @__PURE__ */ t("div", { className: "text-sm leading-relaxed", children: n })
|
|
51
53
|
] }),
|
|
52
|
-
a && /* @__PURE__ */
|
|
54
|
+
a && /* @__PURE__ */ t(
|
|
53
55
|
"button",
|
|
54
56
|
{
|
|
55
57
|
onClick: a,
|
|
56
58
|
className: "shrink-0 opacity-70 hover:opacity-100 transition-opacity",
|
|
57
59
|
"aria-label": "Fechar alerta",
|
|
58
|
-
children: /* @__PURE__ */
|
|
60
|
+
children: /* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[18px]", children: "close" })
|
|
59
61
|
}
|
|
60
62
|
)
|
|
61
63
|
]
|
|
62
64
|
}
|
|
63
65
|
);
|
|
64
66
|
}
|
|
65
|
-
const
|
|
67
|
+
const ye = {
|
|
66
68
|
xs: "w-6 h-6 text-[10px]",
|
|
67
69
|
sm: "w-8 h-8 text-xs",
|
|
68
70
|
md: "w-10 h-10 text-sm",
|
|
69
71
|
lg: "w-12 h-12 text-base",
|
|
70
72
|
xl: "w-16 h-16 text-lg"
|
|
71
|
-
},
|
|
73
|
+
}, Ne = {
|
|
72
74
|
xs: "w-1.5 h-1.5",
|
|
73
75
|
sm: "w-2 h-2",
|
|
74
76
|
md: "w-2.5 h-2.5",
|
|
75
77
|
lg: "w-3 h-3",
|
|
76
78
|
xl: "w-3.5 h-3.5"
|
|
77
|
-
},
|
|
79
|
+
}, ke = {
|
|
78
80
|
online: "bg-green-500",
|
|
79
81
|
offline: "bg-gray-400",
|
|
80
82
|
busy: "bg-red-500",
|
|
81
83
|
away: "bg-yellow-400"
|
|
82
84
|
};
|
|
83
|
-
function
|
|
84
|
-
return e.split(" ").slice(0, 2).map((
|
|
85
|
+
function je(e) {
|
|
86
|
+
return e.split(" ").slice(0, 2).map((r) => r[0]).join("").toUpperCase();
|
|
85
87
|
}
|
|
86
|
-
function
|
|
87
|
-
const
|
|
88
|
-
"bg-orange-100 text-orange-700",
|
|
89
|
-
"bg-blue-100 text-blue-700",
|
|
90
|
-
"bg-green-100 text-green-700",
|
|
91
|
-
"bg-purple-100 text-purple-700",
|
|
92
|
-
"bg-pink-100 text-pink-700",
|
|
93
|
-
"bg-teal-100 text-teal-700"
|
|
94
|
-
],
|
|
95
|
-
return
|
|
88
|
+
function Ce(e) {
|
|
89
|
+
const r = [
|
|
90
|
+
"bg-orange-100 text-orange-700 dark:bg-zeo-orange/20 dark:text-primary",
|
|
91
|
+
"bg-blue-100 text-blue-700 dark:bg-info-container dark:text-info",
|
|
92
|
+
"bg-green-100 text-green-700 dark:bg-success-container dark:text-success",
|
|
93
|
+
"bg-purple-100 text-purple-700 dark:bg-purple-500/20 dark:text-purple-300",
|
|
94
|
+
"bg-pink-100 text-pink-700 dark:bg-pink-500/20 dark:text-pink-300",
|
|
95
|
+
"bg-teal-100 text-teal-700 dark:bg-teal-500/20 dark:text-teal-300"
|
|
96
|
+
], n = e.charCodeAt(0) % r.length;
|
|
97
|
+
return r[n];
|
|
96
98
|
}
|
|
97
|
-
function
|
|
99
|
+
function P({
|
|
98
100
|
src: e,
|
|
99
|
-
alt:
|
|
100
|
-
name:
|
|
101
|
+
alt: r = "",
|
|
102
|
+
name: n,
|
|
101
103
|
size: a = "md",
|
|
102
104
|
status: o,
|
|
103
105
|
className: s = "",
|
|
104
|
-
...
|
|
106
|
+
...l
|
|
105
107
|
}) {
|
|
106
|
-
return /* @__PURE__ */
|
|
107
|
-
/* @__PURE__ */
|
|
108
|
+
return /* @__PURE__ */ i("div", { className: ["relative inline-flex shrink-0", s].filter(Boolean).join(" "), ...l, children: [
|
|
109
|
+
/* @__PURE__ */ t(
|
|
108
110
|
"div",
|
|
109
111
|
{
|
|
110
112
|
className: [
|
|
111
113
|
"rounded-full overflow-hidden flex items-center justify-center font-semibold",
|
|
112
|
-
|
|
113
|
-
!e &&
|
|
114
|
+
ye[a],
|
|
115
|
+
!e && n ? Ce(n) : "bg-surface-container"
|
|
114
116
|
].filter(Boolean).join(" "),
|
|
115
|
-
children: e ? /* @__PURE__ */
|
|
117
|
+
children: e ? /* @__PURE__ */ t(
|
|
116
118
|
"img",
|
|
117
119
|
{
|
|
118
120
|
src: e,
|
|
119
|
-
alt:
|
|
121
|
+
alt: r || n,
|
|
120
122
|
className: "w-full h-full object-cover"
|
|
121
123
|
}
|
|
122
|
-
) :
|
|
124
|
+
) : n ? je(n) : /* @__PURE__ */ t("span", { className: "material-symbols-outlined text-on-surface-variant", style: { fontSize: "60%" }, children: "person" })
|
|
123
125
|
}
|
|
124
126
|
),
|
|
125
|
-
o && /* @__PURE__ */
|
|
127
|
+
o && /* @__PURE__ */ t(
|
|
126
128
|
"span",
|
|
127
129
|
{
|
|
128
130
|
className: [
|
|
129
|
-
"absolute bottom-0 right-0 rounded-full border-2 border-white",
|
|
130
|
-
|
|
131
|
-
|
|
131
|
+
"absolute bottom-0 right-0 rounded-full border-2 border-white dark:border-card",
|
|
132
|
+
Ne[a],
|
|
133
|
+
ke[o]
|
|
132
134
|
].filter(Boolean).join(" ")
|
|
133
135
|
}
|
|
134
136
|
)
|
|
135
137
|
] });
|
|
136
138
|
}
|
|
137
|
-
const
|
|
139
|
+
const Be = {
|
|
138
140
|
default: "bg-surface-container text-on-surface-variant",
|
|
139
|
-
primary: "bg-orange-100 text-orange-700",
|
|
140
|
-
success: "bg-green-100 text-green-700",
|
|
141
|
-
warning: "bg-yellow-100 text-yellow-700",
|
|
142
|
-
danger: "bg-red-100 text-red-700",
|
|
143
|
-
info: "bg-blue-100 text-blue-700"
|
|
144
|
-
},
|
|
141
|
+
primary: "bg-orange-100 text-orange-700 dark:bg-zeo-orange/20 dark:text-primary",
|
|
142
|
+
success: "bg-green-100 text-green-700 dark:bg-success-container dark:text-success",
|
|
143
|
+
warning: "bg-yellow-100 text-yellow-700 dark:bg-warning-container dark:text-warning",
|
|
144
|
+
danger: "bg-red-100 text-red-700 dark:bg-danger-container dark:text-danger",
|
|
145
|
+
info: "bg-blue-100 text-blue-700 dark:bg-info-container dark:text-info"
|
|
146
|
+
}, ze = {
|
|
145
147
|
default: "bg-on-surface-variant",
|
|
146
148
|
primary: "bg-orange-500",
|
|
147
149
|
success: "bg-green-500",
|
|
148
150
|
warning: "bg-yellow-500",
|
|
149
151
|
danger: "bg-red-500",
|
|
150
152
|
info: "bg-blue-500"
|
|
151
|
-
},
|
|
153
|
+
}, Le = {
|
|
152
154
|
sm: "px-2 py-0.5 text-xs gap-1",
|
|
153
155
|
md: "px-2.5 py-1 text-xs gap-1.5"
|
|
154
156
|
};
|
|
155
|
-
function
|
|
157
|
+
function ft({
|
|
156
158
|
variant: e = "default",
|
|
157
|
-
size:
|
|
158
|
-
dot:
|
|
159
|
+
size: r = "md",
|
|
160
|
+
dot: n = !1,
|
|
159
161
|
icon: a,
|
|
160
162
|
children: o,
|
|
161
163
|
className: s = "",
|
|
162
|
-
...
|
|
164
|
+
...l
|
|
163
165
|
}) {
|
|
164
|
-
return /* @__PURE__ */
|
|
166
|
+
return /* @__PURE__ */ i(
|
|
165
167
|
"span",
|
|
166
168
|
{
|
|
167
169
|
className: [
|
|
168
170
|
"inline-flex items-center font-medium rounded-full",
|
|
169
|
-
|
|
170
|
-
|
|
171
|
+
Be[e],
|
|
172
|
+
Le[r],
|
|
171
173
|
s
|
|
172
174
|
].filter(Boolean).join(" "),
|
|
173
|
-
...
|
|
175
|
+
...l,
|
|
174
176
|
children: [
|
|
175
|
-
|
|
176
|
-
a && !
|
|
177
|
+
n && /* @__PURE__ */ t("span", { className: `w-1.5 h-1.5 rounded-full shrink-0 ${ze[e]}` }),
|
|
178
|
+
a && !n && /* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[12px]", children: a }),
|
|
177
179
|
o
|
|
178
180
|
]
|
|
179
181
|
}
|
|
180
182
|
);
|
|
181
183
|
}
|
|
182
|
-
function
|
|
183
|
-
return /* @__PURE__ */
|
|
184
|
+
function mt({ items: e, className: r = "", ...n }) {
|
|
185
|
+
return /* @__PURE__ */ t("nav", { "aria-label": "Breadcrumb", className: r, ...n, children: /* @__PURE__ */ t("ol", { className: "inline-flex items-center gap-1.5 text-sm flex-wrap", children: e.map((a, o) => {
|
|
184
186
|
const s = o === e.length - 1;
|
|
185
|
-
return /* @__PURE__ */
|
|
186
|
-
o > 0 && /* @__PURE__ */
|
|
187
|
-
s ? /* @__PURE__ */
|
|
187
|
+
return /* @__PURE__ */ i("li", { className: "flex items-center gap-1.5", children: [
|
|
188
|
+
o > 0 && /* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[16px] text-on-surface-variant select-none", children: "chevron_right" }),
|
|
189
|
+
s ? /* @__PURE__ */ i(
|
|
188
190
|
"span",
|
|
189
191
|
{
|
|
190
192
|
"aria-current": "page",
|
|
191
193
|
className: "font-semibold text-on-surface flex items-center gap-1",
|
|
192
194
|
children: [
|
|
193
|
-
a.icon && /* @__PURE__ */
|
|
195
|
+
a.icon && /* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[18px] leading-none", children: a.icon }),
|
|
194
196
|
a.label
|
|
195
197
|
]
|
|
196
198
|
}
|
|
197
|
-
) : /* @__PURE__ */
|
|
199
|
+
) : /* @__PURE__ */ i(
|
|
198
200
|
"a",
|
|
199
201
|
{
|
|
200
202
|
href: a.href ?? "#",
|
|
201
203
|
className: "text-on-surface-variant hover:text-zeo-orange transition-colors flex items-center gap-1",
|
|
202
204
|
children: [
|
|
203
|
-
a.icon && /* @__PURE__ */
|
|
205
|
+
a.icon && /* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[18px] leading-none", children: a.icon }),
|
|
204
206
|
a.label
|
|
205
207
|
]
|
|
206
208
|
}
|
|
@@ -208,329 +210,329 @@ function qe({ items: e, className: t = "", ...r }) {
|
|
|
208
210
|
] }, o);
|
|
209
211
|
}) }) });
|
|
210
212
|
}
|
|
211
|
-
const
|
|
213
|
+
const _e = {
|
|
212
214
|
primary: "bg-zeo-orange text-white hover:bg-orange-700 active:bg-orange-800 focus:shadow-zeo-focus border-transparent",
|
|
213
|
-
secondary: "bg-
|
|
215
|
+
secondary: "bg-surface-container-lowest text-on-surface border-outline-variant hover:bg-surface-container-low active:bg-surface-container focus:shadow-zeo-focus",
|
|
214
216
|
ghost: "bg-transparent text-on-surface-variant border-transparent hover:bg-surface-container-low active:bg-surface-container focus:shadow-zeo-focus",
|
|
215
|
-
danger: "bg-
|
|
216
|
-
success: "bg-
|
|
217
|
-
},
|
|
217
|
+
danger: "bg-[#ba1a1a] text-white border-transparent hover:bg-red-700 active:bg-red-800 focus:shadow-[0_0_0_4px_rgba(186,26,26,0.15)]",
|
|
218
|
+
success: "bg-[#006c49] text-white border-transparent hover:bg-green-800 active:bg-green-900 focus:shadow-[0_0_0_4px_rgba(0,108,73,0.15)]"
|
|
219
|
+
}, Te = {
|
|
218
220
|
sm: "px-3 py-1.5 text-sm gap-1.5 h-8",
|
|
219
221
|
md: "px-4 py-2 text-sm gap-2 h-10",
|
|
220
222
|
lg: "px-5 py-2.5 text-base gap-2 h-11"
|
|
221
|
-
},
|
|
223
|
+
}, K = {
|
|
222
224
|
sm: "text-[16px]",
|
|
223
225
|
md: "text-[18px]",
|
|
224
226
|
lg: "text-[20px]"
|
|
225
|
-
},
|
|
227
|
+
}, Me = B(
|
|
226
228
|
({
|
|
227
229
|
variant: e = "primary",
|
|
228
|
-
size:
|
|
229
|
-
loading:
|
|
230
|
+
size: r = "md",
|
|
231
|
+
loading: n = !1,
|
|
230
232
|
iconLeft: a,
|
|
231
233
|
iconRight: o,
|
|
232
234
|
fullWidth: s = !1,
|
|
233
|
-
disabled:
|
|
235
|
+
disabled: l,
|
|
234
236
|
children: c,
|
|
235
|
-
className:
|
|
236
|
-
...
|
|
237
|
-
},
|
|
237
|
+
className: d = "",
|
|
238
|
+
...f
|
|
239
|
+
}, m) => /* @__PURE__ */ i(
|
|
238
240
|
"button",
|
|
239
241
|
{
|
|
240
|
-
ref:
|
|
241
|
-
disabled:
|
|
242
|
+
ref: m,
|
|
243
|
+
disabled: l || n,
|
|
242
244
|
className: [
|
|
243
245
|
"inline-flex items-center justify-center font-medium rounded border transition-all duration-200 select-none",
|
|
244
246
|
"focus:outline-none",
|
|
245
247
|
"disabled:opacity-50 disabled:cursor-not-allowed",
|
|
246
|
-
|
|
247
|
-
|
|
248
|
+
_e[e],
|
|
249
|
+
Te[r],
|
|
248
250
|
s ? "w-full" : "",
|
|
249
|
-
|
|
251
|
+
d
|
|
250
252
|
].filter(Boolean).join(" "),
|
|
251
|
-
...
|
|
253
|
+
...f,
|
|
252
254
|
children: [
|
|
253
|
-
|
|
255
|
+
n ? /* @__PURE__ */ t(
|
|
254
256
|
"span",
|
|
255
257
|
{
|
|
256
|
-
className: `material-symbols-outlined animate-spin ${
|
|
258
|
+
className: `material-symbols-outlined animate-spin ${K[r]}`,
|
|
257
259
|
children: "progress_activity"
|
|
258
260
|
}
|
|
259
|
-
) : a && /* @__PURE__ */
|
|
261
|
+
) : a && /* @__PURE__ */ t("span", { className: `material-symbols-outlined ${K[r]}`, children: a }),
|
|
260
262
|
c,
|
|
261
|
-
!
|
|
263
|
+
!n && o && /* @__PURE__ */ t("span", { className: `material-symbols-outlined ${K[r]}`, children: o })
|
|
262
264
|
]
|
|
263
265
|
}
|
|
264
266
|
)
|
|
265
267
|
);
|
|
266
|
-
|
|
267
|
-
function
|
|
268
|
-
return /* @__PURE__ */
|
|
268
|
+
Me.displayName = "Button";
|
|
269
|
+
function pt({ children: e, attached: r = !1, className: n = "", ...a }) {
|
|
270
|
+
return /* @__PURE__ */ t(
|
|
269
271
|
"div",
|
|
270
272
|
{
|
|
271
273
|
role: "group",
|
|
272
274
|
className: [
|
|
273
275
|
"inline-flex",
|
|
274
|
-
|
|
275
|
-
|
|
276
|
+
r ? "[&>button]:rounded-none [&>button:first-child]:rounded-l [&>button:last-child]:rounded-r [&>button:not(:first-child)]:-ml-px" : "gap-2",
|
|
277
|
+
n
|
|
276
278
|
].filter(Boolean).join(" "),
|
|
277
279
|
...a,
|
|
278
280
|
children: e
|
|
279
281
|
}
|
|
280
282
|
);
|
|
281
283
|
}
|
|
282
|
-
const
|
|
283
|
-
elevated: "bg-
|
|
284
|
-
outlined: "bg-
|
|
284
|
+
const Ie = {
|
|
285
|
+
elevated: "bg-surface-container-lowest shadow-theme-lg border border-surface-container-high",
|
|
286
|
+
outlined: "bg-surface-container-lowest border border-outline-variant",
|
|
285
287
|
filled: "bg-surface-container-low border border-transparent"
|
|
286
|
-
},
|
|
288
|
+
}, $e = {
|
|
287
289
|
none: "",
|
|
288
290
|
sm: "p-4",
|
|
289
291
|
md: "p-5",
|
|
290
292
|
lg: "p-6"
|
|
291
293
|
};
|
|
292
|
-
function
|
|
294
|
+
function ht({
|
|
293
295
|
variant: e = "elevated",
|
|
294
|
-
padding:
|
|
295
|
-
children:
|
|
296
|
+
padding: r = "md",
|
|
297
|
+
children: n,
|
|
296
298
|
className: a = "",
|
|
297
299
|
...o
|
|
298
300
|
}) {
|
|
299
|
-
return /* @__PURE__ */
|
|
301
|
+
return /* @__PURE__ */ t(
|
|
300
302
|
"div",
|
|
301
303
|
{
|
|
302
304
|
className: [
|
|
303
305
|
"rounded-xl overflow-hidden",
|
|
304
|
-
|
|
306
|
+
Ie[e],
|
|
305
307
|
a
|
|
306
308
|
].filter(Boolean).join(" "),
|
|
307
309
|
...o,
|
|
308
|
-
children: /* @__PURE__ */
|
|
310
|
+
children: /* @__PURE__ */ t("div", { className: $e[r], children: n })
|
|
309
311
|
}
|
|
310
312
|
);
|
|
311
313
|
}
|
|
312
|
-
function
|
|
314
|
+
function xt({
|
|
313
315
|
title: e,
|
|
314
|
-
subtitle:
|
|
315
|
-
action:
|
|
316
|
+
subtitle: r,
|
|
317
|
+
action: n,
|
|
316
318
|
icon: a,
|
|
317
319
|
className: o = "",
|
|
318
320
|
...s
|
|
319
321
|
}) {
|
|
320
|
-
return /* @__PURE__ */
|
|
322
|
+
return /* @__PURE__ */ i(
|
|
321
323
|
"div",
|
|
322
324
|
{
|
|
323
325
|
className: ["flex items-start justify-between gap-4 pb-4", o].filter(Boolean).join(" "),
|
|
324
326
|
...s,
|
|
325
327
|
children: [
|
|
326
|
-
/* @__PURE__ */
|
|
327
|
-
a && /* @__PURE__ */
|
|
328
|
-
/* @__PURE__ */
|
|
329
|
-
/* @__PURE__ */
|
|
330
|
-
|
|
328
|
+
/* @__PURE__ */ i("div", { className: "flex items-center gap-3 min-w-0", children: [
|
|
329
|
+
a && /* @__PURE__ */ t("span", { className: "material-symbols-outlined text-on-surface-variant text-[24px] shrink-0", children: a }),
|
|
330
|
+
/* @__PURE__ */ i("div", { className: "min-w-0", children: [
|
|
331
|
+
/* @__PURE__ */ t("h3", { className: "text-base font-semibold text-on-surface truncate", children: e }),
|
|
332
|
+
r && /* @__PURE__ */ t("p", { className: "text-sm text-on-surface-variant mt-0.5", children: r })
|
|
331
333
|
] })
|
|
332
334
|
] }),
|
|
333
|
-
|
|
335
|
+
n && /* @__PURE__ */ t("div", { className: "shrink-0", children: n })
|
|
334
336
|
]
|
|
335
337
|
}
|
|
336
338
|
);
|
|
337
339
|
}
|
|
338
|
-
function
|
|
339
|
-
return /* @__PURE__ */
|
|
340
|
+
function bt({ children: e, className: r = "", ...n }) {
|
|
341
|
+
return /* @__PURE__ */ t(
|
|
340
342
|
"div",
|
|
341
343
|
{
|
|
342
|
-
className: ["flex items-center justify-end gap-3 pt-4 border-t border-surface-container-high",
|
|
343
|
-
...
|
|
344
|
+
className: ["flex items-center justify-end gap-3 pt-4 border-t border-surface-container-high", r].filter(Boolean).join(" "),
|
|
345
|
+
...n,
|
|
344
346
|
children: e
|
|
345
347
|
}
|
|
346
348
|
);
|
|
347
349
|
}
|
|
348
|
-
const
|
|
349
|
-
function
|
|
350
|
-
const [s,
|
|
351
|
-
var
|
|
352
|
-
const
|
|
353
|
-
if (!
|
|
354
|
-
const
|
|
355
|
-
|
|
356
|
-
}, [
|
|
357
|
-
return
|
|
358
|
-
s &&
|
|
359
|
-
}, [s,
|
|
350
|
+
const $ = 8, ee = 4;
|
|
351
|
+
function gt({ trigger: e, items: r, align: n = "right", className: a = "", ...o }) {
|
|
352
|
+
const [s, l] = k(!1), [c, d] = k(null), f = M(null), m = M(null), p = j(() => {
|
|
353
|
+
var T;
|
|
354
|
+
const u = f.current;
|
|
355
|
+
if (!u) return;
|
|
356
|
+
const h = u.getBoundingClientRect(), x = (T = m.current) == null ? void 0 : T.getBoundingClientRect(), w = (x == null ? void 0 : x.width) ?? 180, b = (x == null ? void 0 : x.height) ?? 0, v = window.innerHeight - h.bottom, y = h.top, z = v < b + $ && y > v ? h.top - b - ee : h.bottom + ee, S = n === "right" ? h.right - w : h.left, R = window.innerWidth - w - $, F = Math.min(Math.max(S, $), Math.max(R, $));
|
|
357
|
+
d({ top: z, left: F });
|
|
358
|
+
}, [n]);
|
|
359
|
+
return xe(() => {
|
|
360
|
+
s && p();
|
|
361
|
+
}, [s, p]), C(() => {
|
|
360
362
|
if (!s) return;
|
|
361
|
-
const
|
|
362
|
-
return window.addEventListener("scroll",
|
|
363
|
-
window.removeEventListener("scroll",
|
|
363
|
+
const u = () => p();
|
|
364
|
+
return window.addEventListener("scroll", u, !0), window.addEventListener("resize", u), () => {
|
|
365
|
+
window.removeEventListener("scroll", u, !0), window.removeEventListener("resize", u);
|
|
364
366
|
};
|
|
365
|
-
}, [s,
|
|
366
|
-
const
|
|
367
|
+
}, [s, p]), C(() => {
|
|
368
|
+
const u = (h) => {
|
|
367
369
|
var v, y;
|
|
368
|
-
const
|
|
369
|
-
!w && !b &&
|
|
370
|
+
const x = h.target, w = (v = f.current) == null ? void 0 : v.contains(x), b = (y = m.current) == null ? void 0 : y.contains(x);
|
|
371
|
+
!w && !b && l(!1);
|
|
370
372
|
};
|
|
371
|
-
return document.addEventListener("mousedown",
|
|
372
|
-
}, []),
|
|
373
|
-
const
|
|
374
|
-
|
|
373
|
+
return document.addEventListener("mousedown", u), () => document.removeEventListener("mousedown", u);
|
|
374
|
+
}, []), C(() => {
|
|
375
|
+
const u = (h) => {
|
|
376
|
+
h.key === "Escape" && l(!1);
|
|
375
377
|
};
|
|
376
|
-
return document.addEventListener("keydown",
|
|
377
|
-
}, []), /* @__PURE__ */
|
|
378
|
-
/* @__PURE__ */
|
|
379
|
-
s &&
|
|
380
|
-
/* @__PURE__ */
|
|
378
|
+
return document.addEventListener("keydown", u), () => document.removeEventListener("keydown", u);
|
|
379
|
+
}, []), /* @__PURE__ */ i("div", { ref: f, className: ["relative inline-block", a].filter(Boolean).join(" "), ...o, children: [
|
|
380
|
+
/* @__PURE__ */ t("div", { onClick: () => l((u) => !u), children: e }),
|
|
381
|
+
s && we(
|
|
382
|
+
/* @__PURE__ */ t(
|
|
381
383
|
"div",
|
|
382
384
|
{
|
|
383
|
-
ref:
|
|
384
|
-
className: "fixed z-[100] min-w-[180px] bg-
|
|
385
|
+
ref: m,
|
|
386
|
+
className: "fixed z-[100] min-w-[180px] bg-surface-container-lowest border border-surface-container-high rounded-xl shadow-theme-lg py-1",
|
|
385
387
|
style: {
|
|
386
388
|
top: (c == null ? void 0 : c.top) ?? 0,
|
|
387
389
|
left: (c == null ? void 0 : c.left) ?? 0,
|
|
388
390
|
visibility: c ? "visible" : "hidden"
|
|
389
391
|
},
|
|
390
392
|
role: "menu",
|
|
391
|
-
children:
|
|
392
|
-
/* @__PURE__ */
|
|
393
|
+
children: r.map((u, h) => /* @__PURE__ */ i("div", { children: [
|
|
394
|
+
/* @__PURE__ */ i(
|
|
393
395
|
"button",
|
|
394
396
|
{
|
|
395
397
|
role: "menuitem",
|
|
396
|
-
disabled:
|
|
398
|
+
disabled: u.disabled,
|
|
397
399
|
onClick: () => {
|
|
398
|
-
var
|
|
399
|
-
|
|
400
|
+
var x;
|
|
401
|
+
u.disabled || ((x = u.onClick) == null || x.call(u), l(!1));
|
|
400
402
|
},
|
|
401
403
|
className: [
|
|
402
404
|
"w-full flex items-center gap-3 px-4 py-2.5 text-sm transition-colors text-left",
|
|
403
|
-
|
|
404
|
-
|
|
405
|
+
u.danger ? "text-error hover:bg-red-50 dark:hover:bg-error-container" : "text-on-surface hover:bg-surface-container-low",
|
|
406
|
+
u.disabled ? "opacity-40 cursor-not-allowed" : "cursor-pointer"
|
|
405
407
|
].filter(Boolean).join(" "),
|
|
406
408
|
children: [
|
|
407
|
-
|
|
408
|
-
|
|
409
|
+
u.icon && /* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[18px] opacity-70", children: u.icon }),
|
|
410
|
+
u.label
|
|
409
411
|
]
|
|
410
412
|
}
|
|
411
413
|
),
|
|
412
|
-
|
|
413
|
-
] },
|
|
414
|
+
u.dividerAfter && /* @__PURE__ */ t("div", { className: "my-1 border-t border-surface-container-high" })
|
|
415
|
+
] }, h))
|
|
414
416
|
}
|
|
415
417
|
),
|
|
416
418
|
document.body
|
|
417
419
|
)
|
|
418
420
|
] });
|
|
419
421
|
}
|
|
420
|
-
const
|
|
421
|
-
({ label: e, hint:
|
|
422
|
-
const
|
|
423
|
-
return /* @__PURE__ */
|
|
424
|
-
e && /* @__PURE__ */
|
|
425
|
-
/* @__PURE__ */
|
|
426
|
-
/* @__PURE__ */
|
|
422
|
+
const Ae = B(
|
|
423
|
+
({ label: e, hint: r, error: n, options: a, placeholder: o, disabled: s, className: l = "", id: c, ...d }, f) => {
|
|
424
|
+
const m = c ?? (e == null ? void 0 : e.toLowerCase().replace(/\s+/g, "-"));
|
|
425
|
+
return /* @__PURE__ */ i("div", { className: "flex flex-col gap-1.5", children: [
|
|
426
|
+
e && /* @__PURE__ */ t("label", { htmlFor: m, className: "text-sm font-medium text-on-surface", children: e }),
|
|
427
|
+
/* @__PURE__ */ i("div", { className: "relative", children: [
|
|
428
|
+
/* @__PURE__ */ i(
|
|
427
429
|
"select",
|
|
428
430
|
{
|
|
429
|
-
ref:
|
|
430
|
-
id:
|
|
431
|
+
ref: f,
|
|
432
|
+
id: m,
|
|
431
433
|
disabled: s,
|
|
432
434
|
className: [
|
|
433
|
-
"w-full appearance-none bg-
|
|
435
|
+
"w-full appearance-none bg-page border rounded px-3 py-2 text-sm pr-9 transition-all duration-200",
|
|
434
436
|
"text-on-surface focus:outline-none focus:border-zeo-orange focus:shadow-zeo-focus",
|
|
435
|
-
|
|
437
|
+
n ? "border-error" : "border-outline-variant",
|
|
436
438
|
"disabled:bg-surface-container-low disabled:cursor-not-allowed disabled:opacity-60",
|
|
437
|
-
|
|
439
|
+
l
|
|
438
440
|
].filter(Boolean).join(" "),
|
|
439
|
-
...
|
|
441
|
+
...d,
|
|
440
442
|
children: [
|
|
441
|
-
o && /* @__PURE__ */
|
|
442
|
-
a.map((
|
|
443
|
+
o && /* @__PURE__ */ t("option", { value: "", disabled: !0, children: o }),
|
|
444
|
+
a.map((p) => /* @__PURE__ */ t("option", { value: p.value, disabled: p.disabled, children: p.label }, p.value))
|
|
443
445
|
]
|
|
444
446
|
}
|
|
445
447
|
),
|
|
446
|
-
/* @__PURE__ */
|
|
448
|
+
/* @__PURE__ */ t("span", { className: "material-symbols-outlined absolute right-3 top-1/2 -translate-y-1/2 text-[18px] text-on-surface-variant pointer-events-none", children: "expand_more" })
|
|
447
449
|
] }),
|
|
448
|
-
|
|
449
|
-
/* @__PURE__ */
|
|
450
|
-
|
|
450
|
+
n && /* @__PURE__ */ i("p", { className: "text-xs text-error flex items-center gap-1", children: [
|
|
451
|
+
/* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[14px]", children: "error" }),
|
|
452
|
+
n
|
|
451
453
|
] }),
|
|
452
|
-
!
|
|
454
|
+
!n && r && /* @__PURE__ */ t("p", { className: "text-xs text-on-surface-variant", children: r })
|
|
453
455
|
] });
|
|
454
456
|
}
|
|
455
457
|
);
|
|
456
|
-
|
|
457
|
-
const
|
|
458
|
-
({ label: e, hint:
|
|
459
|
-
const
|
|
460
|
-
return /* @__PURE__ */
|
|
461
|
-
e && /* @__PURE__ */
|
|
462
|
-
/* @__PURE__ */
|
|
458
|
+
Ae.displayName = "Select";
|
|
459
|
+
const Ee = B(
|
|
460
|
+
({ label: e, hint: r, error: n, disabled: a, className: o = "", id: s, rows: l = 4, ...c }, d) => {
|
|
461
|
+
const f = s ?? (e == null ? void 0 : e.toLowerCase().replace(/\s+/g, "-"));
|
|
462
|
+
return /* @__PURE__ */ i("div", { className: "flex flex-col gap-1.5", children: [
|
|
463
|
+
e && /* @__PURE__ */ t("label", { htmlFor: f, className: "text-sm font-medium text-on-surface", children: e }),
|
|
464
|
+
/* @__PURE__ */ t(
|
|
463
465
|
"textarea",
|
|
464
466
|
{
|
|
465
|
-
ref:
|
|
466
|
-
id:
|
|
467
|
-
rows:
|
|
467
|
+
ref: d,
|
|
468
|
+
id: f,
|
|
469
|
+
rows: l,
|
|
468
470
|
disabled: a,
|
|
469
471
|
className: [
|
|
470
|
-
"w-full bg-
|
|
472
|
+
"w-full bg-page border rounded px-3 py-2 text-sm resize-y transition-all duration-200",
|
|
471
473
|
"text-on-surface placeholder:text-on-surface-variant",
|
|
472
474
|
"focus:outline-none focus:border-zeo-orange focus:shadow-zeo-focus",
|
|
473
|
-
|
|
475
|
+
n ? "border-error" : "border-outline-variant",
|
|
474
476
|
"disabled:bg-surface-container-low disabled:cursor-not-allowed disabled:opacity-60",
|
|
475
477
|
o
|
|
476
478
|
].filter(Boolean).join(" "),
|
|
477
479
|
...c
|
|
478
480
|
}
|
|
479
481
|
),
|
|
480
|
-
|
|
481
|
-
/* @__PURE__ */
|
|
482
|
-
|
|
482
|
+
n && /* @__PURE__ */ i("p", { className: "text-xs text-error flex items-center gap-1", children: [
|
|
483
|
+
/* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[14px]", children: "error" }),
|
|
484
|
+
n
|
|
483
485
|
] }),
|
|
484
|
-
!
|
|
486
|
+
!n && r && /* @__PURE__ */ t("p", { className: "text-xs text-on-surface-variant", children: r })
|
|
485
487
|
] });
|
|
486
488
|
}
|
|
487
489
|
);
|
|
488
|
-
|
|
489
|
-
const
|
|
490
|
+
Ee.displayName = "Textarea";
|
|
491
|
+
const Se = {
|
|
490
492
|
square: "rounded-[2px]",
|
|
491
493
|
rounded: "rounded-[4px]",
|
|
492
494
|
circle: "rounded-full"
|
|
493
|
-
},
|
|
494
|
-
({ label: e, description:
|
|
495
|
-
const
|
|
496
|
-
return /* @__PURE__ */
|
|
497
|
-
/* @__PURE__ */
|
|
495
|
+
}, Re = B(
|
|
496
|
+
({ label: e, description: r, error: n, disabled: a, className: o = "", id: s, shape: l = "square", color: c = "#FF6B00", ...d }, f) => {
|
|
497
|
+
const m = s ?? `checkbox-${e == null ? void 0 : e.toLowerCase().replace(/\s+/g, "-")}`;
|
|
498
|
+
return /* @__PURE__ */ i("div", { className: "flex flex-col gap-1", children: [
|
|
499
|
+
/* @__PURE__ */ i(
|
|
498
500
|
"label",
|
|
499
501
|
{
|
|
500
|
-
htmlFor:
|
|
502
|
+
htmlFor: m,
|
|
501
503
|
className: [
|
|
502
504
|
"flex items-start gap-3 cursor-pointer",
|
|
503
505
|
a ? "opacity-50 cursor-not-allowed" : ""
|
|
504
506
|
].filter(Boolean).join(" "),
|
|
505
507
|
children: [
|
|
506
|
-
/* @__PURE__ */
|
|
507
|
-
/* @__PURE__ */
|
|
508
|
+
/* @__PURE__ */ i("div", { className: "relative mt-0.5 shrink-0 w-4 h-4", children: [
|
|
509
|
+
/* @__PURE__ */ t(
|
|
508
510
|
"input",
|
|
509
511
|
{
|
|
510
|
-
ref:
|
|
512
|
+
ref: f,
|
|
511
513
|
type: "checkbox",
|
|
512
|
-
id:
|
|
514
|
+
id: m,
|
|
513
515
|
disabled: a,
|
|
514
516
|
className: [
|
|
515
517
|
"absolute inset-0 w-full h-full opacity-0 cursor-pointer peer disabled:cursor-not-allowed",
|
|
516
518
|
o
|
|
517
519
|
].filter(Boolean).join(" "),
|
|
518
|
-
...
|
|
520
|
+
...d
|
|
519
521
|
}
|
|
520
522
|
),
|
|
521
|
-
/* @__PURE__ */
|
|
523
|
+
/* @__PURE__ */ t(
|
|
522
524
|
"div",
|
|
523
525
|
{
|
|
524
526
|
className: [
|
|
525
527
|
"w-4 h-4 border-2 border-outline-variant transition-colors pointer-events-none",
|
|
526
|
-
"bg-
|
|
528
|
+
"bg-page peer-checked:bg-[var(--cb-color)] peer-checked:border-[var(--cb-color)]",
|
|
527
529
|
"peer-focus-visible:ring-2 peer-focus-visible:ring-[var(--cb-color)]/30 peer-focus-visible:ring-offset-0",
|
|
528
|
-
|
|
530
|
+
Se[l]
|
|
529
531
|
].filter(Boolean).join(" "),
|
|
530
532
|
style: { "--cb-color": c }
|
|
531
533
|
}
|
|
532
534
|
),
|
|
533
|
-
/* @__PURE__ */
|
|
535
|
+
/* @__PURE__ */ t(
|
|
534
536
|
"svg",
|
|
535
537
|
{
|
|
536
538
|
viewBox: "0 0 12 10",
|
|
@@ -539,7 +541,7 @@ const je = {
|
|
|
539
541
|
fill: "none",
|
|
540
542
|
"aria-hidden": "true",
|
|
541
543
|
className: "absolute inset-0 m-auto pointer-events-none opacity-0 peer-checked:opacity-100 transition-opacity",
|
|
542
|
-
children: /* @__PURE__ */
|
|
544
|
+
children: /* @__PURE__ */ t(
|
|
543
545
|
"polyline",
|
|
544
546
|
{
|
|
545
547
|
points: "1,5 4.5,8.5 11,1.5",
|
|
@@ -552,40 +554,40 @@ const je = {
|
|
|
552
554
|
}
|
|
553
555
|
)
|
|
554
556
|
] }),
|
|
555
|
-
e && /* @__PURE__ */
|
|
556
|
-
/* @__PURE__ */
|
|
557
|
-
|
|
557
|
+
e && /* @__PURE__ */ i("span", { className: "flex flex-col", children: [
|
|
558
|
+
/* @__PURE__ */ t("span", { className: "text-sm font-medium text-on-surface leading-tight", children: e }),
|
|
559
|
+
r && /* @__PURE__ */ t("span", { className: "text-xs text-on-surface-variant mt-0.5", children: r })
|
|
558
560
|
] })
|
|
559
561
|
]
|
|
560
562
|
}
|
|
561
563
|
),
|
|
562
|
-
|
|
563
|
-
/* @__PURE__ */
|
|
564
|
-
|
|
564
|
+
n && /* @__PURE__ */ i("p", { className: "text-xs text-error flex items-center gap-1 ml-7", children: [
|
|
565
|
+
/* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[14px]", children: "error" }),
|
|
566
|
+
n
|
|
565
567
|
] })
|
|
566
568
|
] });
|
|
567
569
|
}
|
|
568
570
|
);
|
|
569
|
-
|
|
570
|
-
const
|
|
571
|
-
({ label: e, description:
|
|
571
|
+
Re.displayName = "Checkbox";
|
|
572
|
+
const Fe = B(
|
|
573
|
+
({ label: e, description: r, disabled: n, className: a = "", id: o, ...s }, l) => {
|
|
572
574
|
const c = o ?? `radio-${e == null ? void 0 : e.toLowerCase().replace(/\s+/g, "-")}`;
|
|
573
|
-
return /* @__PURE__ */
|
|
575
|
+
return /* @__PURE__ */ i(
|
|
574
576
|
"label",
|
|
575
577
|
{
|
|
576
578
|
htmlFor: c,
|
|
577
579
|
className: [
|
|
578
580
|
"flex items-start gap-3 cursor-pointer",
|
|
579
|
-
|
|
581
|
+
n ? "opacity-50 cursor-not-allowed" : ""
|
|
580
582
|
].filter(Boolean).join(" "),
|
|
581
583
|
children: [
|
|
582
|
-
/* @__PURE__ */
|
|
584
|
+
/* @__PURE__ */ t(
|
|
583
585
|
"input",
|
|
584
586
|
{
|
|
585
|
-
ref:
|
|
587
|
+
ref: l,
|
|
586
588
|
type: "radio",
|
|
587
589
|
id: c,
|
|
588
|
-
disabled:
|
|
590
|
+
disabled: n,
|
|
589
591
|
className: [
|
|
590
592
|
"mt-0.5 w-4 h-4 border-outline-variant text-zeo-orange shrink-0",
|
|
591
593
|
"focus:ring-2 focus:ring-zeo-orange/30 focus:ring-offset-0",
|
|
@@ -595,218 +597,298 @@ const Be = N(
|
|
|
595
597
|
...s
|
|
596
598
|
}
|
|
597
599
|
),
|
|
598
|
-
e && /* @__PURE__ */
|
|
599
|
-
/* @__PURE__ */
|
|
600
|
-
|
|
600
|
+
e && /* @__PURE__ */ i("span", { className: "flex flex-col", children: [
|
|
601
|
+
/* @__PURE__ */ t("span", { className: "text-sm font-medium text-on-surface leading-tight", children: e }),
|
|
602
|
+
r && /* @__PURE__ */ t("span", { className: "text-xs text-on-surface-variant mt-0.5", children: r })
|
|
601
603
|
] })
|
|
602
604
|
]
|
|
603
605
|
}
|
|
604
606
|
);
|
|
605
607
|
}
|
|
606
608
|
);
|
|
607
|
-
|
|
608
|
-
const
|
|
609
|
-
({ label: e, description:
|
|
609
|
+
Fe.displayName = "Radio";
|
|
610
|
+
const Ve = B(
|
|
611
|
+
({ label: e, description: r, disabled: n, className: a = "", id: o, ...s }, l) => {
|
|
610
612
|
const c = o ?? `switch-${e == null ? void 0 : e.toLowerCase().replace(/\s+/g, "-")}`;
|
|
611
|
-
return /* @__PURE__ */
|
|
613
|
+
return /* @__PURE__ */ i(
|
|
612
614
|
"label",
|
|
613
615
|
{
|
|
614
616
|
htmlFor: c,
|
|
615
617
|
className: [
|
|
616
618
|
"flex items-start gap-3 cursor-pointer select-none",
|
|
617
|
-
|
|
619
|
+
n ? "opacity-50 cursor-not-allowed" : ""
|
|
618
620
|
].filter(Boolean).join(" "),
|
|
619
621
|
children: [
|
|
620
|
-
/* @__PURE__ */
|
|
621
|
-
/* @__PURE__ */
|
|
622
|
+
/* @__PURE__ */ i("div", { className: "relative mt-0.5 shrink-0", children: [
|
|
623
|
+
/* @__PURE__ */ t(
|
|
622
624
|
"input",
|
|
623
625
|
{
|
|
624
|
-
ref:
|
|
626
|
+
ref: l,
|
|
625
627
|
type: "checkbox",
|
|
626
628
|
id: c,
|
|
627
|
-
disabled:
|
|
629
|
+
disabled: n,
|
|
628
630
|
className: "sr-only peer",
|
|
629
631
|
...s
|
|
630
632
|
}
|
|
631
633
|
),
|
|
632
|
-
/* @__PURE__ */
|
|
633
|
-
/* @__PURE__ */
|
|
634
|
+
/* @__PURE__ */ t("div", { className: "w-10 h-6 bg-surface-container-high rounded-full peer-checked:bg-zeo-orange transition-colors duration-200 peer-focus:ring-2 peer-focus:ring-zeo-orange/30" }),
|
|
635
|
+
/* @__PURE__ */ t("div", { className: "absolute top-1 left-1 w-4 h-4 bg-white rounded-full shadow transition-transform duration-200 peer-checked:translate-x-4" })
|
|
634
636
|
] }),
|
|
635
|
-
e && /* @__PURE__ */
|
|
636
|
-
/* @__PURE__ */
|
|
637
|
-
|
|
637
|
+
e && /* @__PURE__ */ i("span", { className: "flex flex-col", children: [
|
|
638
|
+
/* @__PURE__ */ t("span", { className: "text-sm font-medium text-on-surface leading-tight", children: e }),
|
|
639
|
+
r && /* @__PURE__ */ t("span", { className: "text-xs text-on-surface-variant mt-0.5", children: r })
|
|
638
640
|
] })
|
|
639
641
|
]
|
|
640
642
|
}
|
|
641
643
|
);
|
|
642
644
|
}
|
|
643
645
|
);
|
|
644
|
-
|
|
645
|
-
|
|
646
|
+
Ve.displayName = "Switch";
|
|
647
|
+
function N({ name: e, size: r = 20, fill: n = !1, className: a = "", style: o, ...s }) {
|
|
648
|
+
return /* @__PURE__ */ t(
|
|
649
|
+
"span",
|
|
650
|
+
{
|
|
651
|
+
...s,
|
|
652
|
+
className: `material-symbols-outlined leading-none select-none ${a}`.trim(),
|
|
653
|
+
style: {
|
|
654
|
+
fontSize: r,
|
|
655
|
+
fontVariationSettings: `'FILL' ${n ? 1 : 0}, 'wght' 300, 'GRAD' 0, 'opsz' 24`,
|
|
656
|
+
...o
|
|
657
|
+
},
|
|
658
|
+
"aria-hidden": "true",
|
|
659
|
+
children: e
|
|
660
|
+
}
|
|
661
|
+
);
|
|
662
|
+
}
|
|
663
|
+
const De = ({ size: e = 24, className: r }) => /* @__PURE__ */ i(
|
|
664
|
+
"svg",
|
|
665
|
+
{
|
|
666
|
+
width: e,
|
|
667
|
+
height: e,
|
|
668
|
+
viewBox: "0 0 100 100",
|
|
669
|
+
fill: "none",
|
|
670
|
+
stroke: "currentColor",
|
|
671
|
+
strokeLinecap: "round",
|
|
672
|
+
strokeLinejoin: "round",
|
|
673
|
+
strokeWidth: 4,
|
|
674
|
+
className: r,
|
|
675
|
+
"aria-hidden": "true",
|
|
676
|
+
children: [
|
|
677
|
+
/* @__PURE__ */ t("path", { d: "M15 65 L40 50 H85 L60 65 Z" }),
|
|
678
|
+
/* @__PURE__ */ t("path", { d: "M15 65 V72 L60 72 V65" }),
|
|
679
|
+
/* @__PURE__ */ t("path", { d: "M60 72 L85 57 V50" }),
|
|
680
|
+
/* @__PURE__ */ t("path", { d: "M25 60 V35 H32 V56" }),
|
|
681
|
+
/* @__PURE__ */ t("path", { d: "M42 45 V20 H49 V41" }),
|
|
682
|
+
/* @__PURE__ */ t("path", { d: "M55 60 V35 H62 V56" }),
|
|
683
|
+
/* @__PURE__ */ t("path", { d: "M72 45 V20 H79 V41" })
|
|
684
|
+
]
|
|
685
|
+
}
|
|
686
|
+
), He = ({ size: e = 24, className: r }) => /* @__PURE__ */ i(
|
|
687
|
+
"svg",
|
|
688
|
+
{
|
|
689
|
+
width: e,
|
|
690
|
+
height: e,
|
|
691
|
+
viewBox: "0 0 100 100",
|
|
692
|
+
fill: "none",
|
|
693
|
+
stroke: "currentColor",
|
|
694
|
+
strokeLinecap: "round",
|
|
695
|
+
strokeLinejoin: "round",
|
|
696
|
+
strokeWidth: 4,
|
|
697
|
+
className: r,
|
|
698
|
+
"aria-hidden": "true",
|
|
699
|
+
children: [
|
|
700
|
+
/* @__PURE__ */ t("ellipse", { cx: "50", cy: "20", rx: "12", ry: "6" }),
|
|
701
|
+
/* @__PURE__ */ t("path", { d: "M38 20 V65 M62 20 V65" }),
|
|
702
|
+
/* @__PURE__ */ t("path", { d: "M50 25 V58" }),
|
|
703
|
+
/* @__PURE__ */ t("path", { d: "M38 65 L25 75 V85 L50 90 L75 85 V75 L62 65 Z" }),
|
|
704
|
+
/* @__PURE__ */ t("path", { d: "M50 75 V90" })
|
|
705
|
+
]
|
|
706
|
+
}
|
|
707
|
+
), Ke = ({ size: e = 24, className: r }) => /* @__PURE__ */ i(
|
|
708
|
+
"svg",
|
|
709
|
+
{
|
|
710
|
+
width: e,
|
|
711
|
+
height: e,
|
|
712
|
+
viewBox: "0 0 100 100",
|
|
713
|
+
fill: "none",
|
|
714
|
+
strokeLinecap: "round",
|
|
715
|
+
strokeLinejoin: "round",
|
|
716
|
+
className: r,
|
|
717
|
+
"aria-hidden": "true",
|
|
718
|
+
children: [
|
|
719
|
+
/* @__PURE__ */ t("path", { d: "M48 90 L45 25 L55 25 L52 90 Z", fill: "currentColor", stroke: "none" }),
|
|
720
|
+
/* @__PURE__ */ t("circle", { cx: "50", cy: "20", r: "5", fill: "currentColor", stroke: "none" }),
|
|
721
|
+
/* @__PURE__ */ t("path", { d: "M38 30 A20 20 0 0 0 38 10", stroke: "currentColor", strokeWidth: 3 }),
|
|
722
|
+
/* @__PURE__ */ t("path", { d: "M30 35 A28 28 0 0 0 30 5", stroke: "currentColor", strokeWidth: 3 }),
|
|
723
|
+
/* @__PURE__ */ t("path", { d: "M62 30 A20 20 0 0 1 62 10", stroke: "currentColor", strokeWidth: 3 }),
|
|
724
|
+
/* @__PURE__ */ t("path", { d: "M70 35 A28 28 0 0 1 70 5", stroke: "currentColor", strokeWidth: 3 })
|
|
725
|
+
]
|
|
726
|
+
}
|
|
727
|
+
), Ue = {
|
|
646
728
|
sm: "px-3 py-1.5 text-sm h-8",
|
|
647
729
|
md: "px-3 py-2 text-sm h-10",
|
|
648
730
|
lg: "px-4 py-2.5 text-base h-11"
|
|
649
|
-
},
|
|
731
|
+
}, te = {
|
|
650
732
|
sm: "text-[16px]",
|
|
651
733
|
md: "text-[18px]",
|
|
652
734
|
lg: "text-[20px]"
|
|
653
735
|
};
|
|
654
|
-
function
|
|
736
|
+
function We(e, r, n) {
|
|
655
737
|
if (e === "" || e === void 0 || e === null) return "";
|
|
656
|
-
const a = Number(e).toFixed(
|
|
657
|
-
return
|
|
738
|
+
const a = Number(e).toFixed(r);
|
|
739
|
+
return n ? `${a} ${n}` : a;
|
|
658
740
|
}
|
|
659
|
-
const
|
|
741
|
+
const Ge = B(
|
|
660
742
|
({
|
|
661
743
|
label: e,
|
|
662
|
-
hint:
|
|
663
|
-
error:
|
|
744
|
+
hint: r,
|
|
745
|
+
error: n,
|
|
664
746
|
inputSize: a = "md",
|
|
665
747
|
iconLeft: o,
|
|
666
748
|
iconRight: s,
|
|
667
|
-
onIconRightClick:
|
|
749
|
+
onIconRightClick: l,
|
|
668
750
|
disabled: c,
|
|
669
|
-
className:
|
|
670
|
-
id:
|
|
671
|
-
unit:
|
|
672
|
-
decimals:
|
|
673
|
-
onValueChange:
|
|
674
|
-
value:
|
|
675
|
-
defaultValue:
|
|
751
|
+
className: d = "",
|
|
752
|
+
id: f,
|
|
753
|
+
unit: m,
|
|
754
|
+
decimals: p,
|
|
755
|
+
onValueChange: u,
|
|
756
|
+
value: h,
|
|
757
|
+
defaultValue: x,
|
|
676
758
|
type: w,
|
|
677
759
|
step: b,
|
|
678
760
|
inputMode: v,
|
|
679
761
|
onChange: y,
|
|
680
|
-
onFocus:
|
|
681
|
-
onBlur:
|
|
682
|
-
...
|
|
683
|
-
},
|
|
684
|
-
const
|
|
685
|
-
typeof
|
|
686
|
-
), [
|
|
687
|
-
(
|
|
688
|
-
g && (
|
|
762
|
+
onFocus: _,
|
|
763
|
+
onBlur: z,
|
|
764
|
+
...S
|
|
765
|
+
}, R) => {
|
|
766
|
+
const F = be(), T = f ?? (e ? e.toLowerCase().replace(/\s+/g, "-") : F), g = m !== void 0, V = p ?? 0, D = g && h !== void 0, [de, ue] = k(
|
|
767
|
+
typeof x == "number" ? x : ""
|
|
768
|
+
), [Z, Q] = k(!1), [H, Y] = k(""), I = D ? h : de, fe = g ? Z ? H : We(I, V, m ?? "") : h, me = j(
|
|
769
|
+
(L) => {
|
|
770
|
+
g && (Q(!0), Y(I === "" ? "" : String(I))), _ == null || _(L);
|
|
689
771
|
},
|
|
690
|
-
[g,
|
|
691
|
-
),
|
|
692
|
-
(
|
|
772
|
+
[g, I, _]
|
|
773
|
+
), pe = j(
|
|
774
|
+
(L) => {
|
|
693
775
|
if (g) {
|
|
694
|
-
|
|
695
|
-
const
|
|
696
|
-
|
|
776
|
+
Q(!1);
|
|
777
|
+
const J = parseFloat(H.replace(",", ".")), X = isNaN(J) ? "" : J;
|
|
778
|
+
D || ue(X), u == null || u(X);
|
|
697
779
|
}
|
|
698
|
-
|
|
780
|
+
z == null || z(L);
|
|
699
781
|
},
|
|
700
|
-
[g,
|
|
701
|
-
),
|
|
702
|
-
(
|
|
703
|
-
g &&
|
|
782
|
+
[g, H, D, u, z]
|
|
783
|
+
), he = j(
|
|
784
|
+
(L) => {
|
|
785
|
+
g && Y(L.target.value), y == null || y(L);
|
|
704
786
|
},
|
|
705
787
|
[g, y]
|
|
706
788
|
);
|
|
707
|
-
return /* @__PURE__ */
|
|
708
|
-
e && /* @__PURE__ */
|
|
789
|
+
return /* @__PURE__ */ i("div", { className: "flex flex-col gap-1.5", children: [
|
|
790
|
+
e && /* @__PURE__ */ t(
|
|
709
791
|
"label",
|
|
710
792
|
{
|
|
711
|
-
htmlFor:
|
|
793
|
+
htmlFor: T,
|
|
712
794
|
className: "text-sm font-medium text-on-surface",
|
|
713
795
|
children: e
|
|
714
796
|
}
|
|
715
797
|
),
|
|
716
|
-
/* @__PURE__ */
|
|
717
|
-
o && /* @__PURE__ */
|
|
798
|
+
/* @__PURE__ */ i("div", { className: "relative flex items-center", children: [
|
|
799
|
+
o && /* @__PURE__ */ t(
|
|
718
800
|
"span",
|
|
719
801
|
{
|
|
720
|
-
className: `material-symbols-outlined absolute left-3 text-on-surface-variant pointer-events-none ${
|
|
802
|
+
className: `material-symbols-outlined absolute left-3 text-on-surface-variant pointer-events-none ${te[a]}`,
|
|
721
803
|
children: o
|
|
722
804
|
}
|
|
723
805
|
),
|
|
724
|
-
/* @__PURE__ */
|
|
806
|
+
/* @__PURE__ */ t(
|
|
725
807
|
"input",
|
|
726
808
|
{
|
|
727
|
-
ref:
|
|
728
|
-
id:
|
|
809
|
+
ref: R,
|
|
810
|
+
id: T,
|
|
729
811
|
disabled: c,
|
|
730
|
-
type: g ?
|
|
812
|
+
type: g ? Z ? "number" : "text" : w,
|
|
731
813
|
inputMode: g ? "decimal" : v,
|
|
732
|
-
value: g ?
|
|
733
|
-
defaultValue: g ? void 0 :
|
|
734
|
-
step: g ? b ?? (
|
|
735
|
-
onFocus:
|
|
736
|
-
onBlur:
|
|
737
|
-
onChange:
|
|
814
|
+
value: g ? fe : h,
|
|
815
|
+
defaultValue: g ? void 0 : x,
|
|
816
|
+
step: g ? b ?? (V > 0 ? Math.pow(10, -V) : 1) : b,
|
|
817
|
+
onFocus: me,
|
|
818
|
+
onBlur: pe,
|
|
819
|
+
onChange: he,
|
|
738
820
|
className: [
|
|
739
|
-
"w-full bg-
|
|
740
|
-
"text-on-surface placeholder:text-on-surface-variant",
|
|
821
|
+
"w-full bg-page border rounded transition-all duration-200",
|
|
822
|
+
"text-on-surface placeholder:text-on-surface-variant dark:placeholder:text-content-disabled",
|
|
741
823
|
"focus:outline-none focus:border-zeo-orange focus:shadow-zeo-focus",
|
|
742
|
-
|
|
824
|
+
n ? "border-error focus:border-error focus:shadow-[0_0_0_4px_rgba(186,26,26,0.15)]" : "border-outline-variant",
|
|
743
825
|
"disabled:bg-surface-container-low disabled:cursor-not-allowed disabled:opacity-60",
|
|
744
826
|
g ? "[appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none" : "",
|
|
745
|
-
|
|
827
|
+
Ue[a],
|
|
746
828
|
o ? "pl-9" : "",
|
|
747
829
|
s ? "pr-9" : "",
|
|
748
|
-
|
|
830
|
+
d
|
|
749
831
|
].filter(Boolean).join(" "),
|
|
750
|
-
...
|
|
832
|
+
...S
|
|
751
833
|
}
|
|
752
834
|
),
|
|
753
|
-
s && /* @__PURE__ */
|
|
835
|
+
s && /* @__PURE__ */ t(
|
|
754
836
|
"span",
|
|
755
837
|
{
|
|
756
838
|
className: [
|
|
757
839
|
"material-symbols-outlined absolute right-3 text-on-surface-variant",
|
|
758
|
-
|
|
759
|
-
|
|
840
|
+
te[a],
|
|
841
|
+
l ? "cursor-pointer hover:text-on-surface" : "pointer-events-none"
|
|
760
842
|
].filter(Boolean).join(" "),
|
|
761
|
-
onClick:
|
|
843
|
+
onClick: l,
|
|
762
844
|
children: s
|
|
763
845
|
}
|
|
764
846
|
)
|
|
765
847
|
] }),
|
|
766
|
-
|
|
767
|
-
/* @__PURE__ */
|
|
768
|
-
|
|
848
|
+
n && /* @__PURE__ */ i("p", { className: "text-xs text-error flex items-center gap-1", children: [
|
|
849
|
+
/* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[14px]", children: "error" }),
|
|
850
|
+
n
|
|
769
851
|
] }),
|
|
770
|
-
!
|
|
852
|
+
!n && r && /* @__PURE__ */ t("p", { className: "text-xs text-on-surface-variant", children: r })
|
|
771
853
|
] });
|
|
772
854
|
}
|
|
773
855
|
);
|
|
774
|
-
|
|
775
|
-
const
|
|
856
|
+
Ge.displayName = "Input";
|
|
857
|
+
const Oe = {
|
|
776
858
|
sm: "max-w-sm",
|
|
777
859
|
md: "max-w-md",
|
|
778
860
|
lg: "max-w-lg",
|
|
779
861
|
xl: "max-w-2xl",
|
|
780
862
|
full: "max-w-[calc(100vw-2rem)]"
|
|
781
863
|
};
|
|
782
|
-
function
|
|
783
|
-
return
|
|
864
|
+
function wt({ open: e, onClose: r, size: n = "md", children: a }) {
|
|
865
|
+
return C(() => {
|
|
784
866
|
if (!e) return;
|
|
785
867
|
const o = (s) => {
|
|
786
|
-
s.key === "Escape" &&
|
|
868
|
+
s.key === "Escape" && r();
|
|
787
869
|
};
|
|
788
870
|
return document.addEventListener("keydown", o), () => document.removeEventListener("keydown", o);
|
|
789
|
-
}, [e,
|
|
871
|
+
}, [e, r]), e ? /* @__PURE__ */ i(
|
|
790
872
|
"div",
|
|
791
873
|
{
|
|
792
874
|
className: "fixed inset-0 z-50 flex items-center justify-center p-4",
|
|
793
875
|
"aria-modal": "true",
|
|
794
876
|
role: "dialog",
|
|
795
877
|
children: [
|
|
796
|
-
/* @__PURE__ */
|
|
878
|
+
/* @__PURE__ */ t(
|
|
797
879
|
"div",
|
|
798
880
|
{
|
|
799
|
-
className: "absolute inset-0 bg-black/50 backdrop-blur-sm",
|
|
800
|
-
onClick:
|
|
881
|
+
className: "absolute inset-0 bg-black/50 dark:bg-scrim/60 backdrop-blur-sm",
|
|
882
|
+
onClick: r,
|
|
801
883
|
"aria-hidden": "true"
|
|
802
884
|
}
|
|
803
885
|
),
|
|
804
|
-
/* @__PURE__ */
|
|
886
|
+
/* @__PURE__ */ t(
|
|
805
887
|
"div",
|
|
806
888
|
{
|
|
807
889
|
className: [
|
|
808
|
-
"relative w-full bg-
|
|
809
|
-
|
|
890
|
+
"relative w-full bg-surface-container-lowest rounded-2xl shadow-theme-lg z-10 flex flex-col max-h-[90vh]",
|
|
891
|
+
Oe[n]
|
|
810
892
|
].filter(Boolean).join(" "),
|
|
811
893
|
children: a
|
|
812
894
|
}
|
|
@@ -815,120 +897,120 @@ function Xe({ open: e, onClose: t, size: r = "md", children: a }) {
|
|
|
815
897
|
}
|
|
816
898
|
) : null;
|
|
817
899
|
}
|
|
818
|
-
function
|
|
819
|
-
return /* @__PURE__ */
|
|
900
|
+
function vt({ title: e, subtitle: r, onClose: n, className: a = "", ...o }) {
|
|
901
|
+
return /* @__PURE__ */ i(
|
|
820
902
|
"div",
|
|
821
903
|
{
|
|
822
904
|
className: ["flex items-start justify-between gap-4 p-6 border-b border-surface-container-high", a].filter(Boolean).join(" "),
|
|
823
905
|
...o,
|
|
824
906
|
children: [
|
|
825
|
-
/* @__PURE__ */
|
|
826
|
-
/* @__PURE__ */
|
|
827
|
-
|
|
907
|
+
/* @__PURE__ */ i("div", { children: [
|
|
908
|
+
/* @__PURE__ */ t("h2", { className: "text-lg font-semibold text-on-surface", children: e }),
|
|
909
|
+
r && /* @__PURE__ */ t("p", { className: "text-sm text-on-surface-variant mt-0.5", children: r })
|
|
828
910
|
] }),
|
|
829
|
-
|
|
911
|
+
n && /* @__PURE__ */ t(
|
|
830
912
|
"button",
|
|
831
913
|
{
|
|
832
|
-
onClick:
|
|
914
|
+
onClick: n,
|
|
833
915
|
className: "p-1 text-on-surface-variant hover:text-on-surface hover:bg-surface-container-low rounded-lg transition-all -mt-1 -mr-1",
|
|
834
916
|
"aria-label": "Fechar modal",
|
|
835
|
-
children: /* @__PURE__ */
|
|
917
|
+
children: /* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[20px]", children: "close" })
|
|
836
918
|
}
|
|
837
919
|
)
|
|
838
920
|
]
|
|
839
921
|
}
|
|
840
922
|
);
|
|
841
923
|
}
|
|
842
|
-
function
|
|
843
|
-
return /* @__PURE__ */
|
|
924
|
+
function yt({ children: e, className: r = "", ...n }) {
|
|
925
|
+
return /* @__PURE__ */ t(
|
|
844
926
|
"div",
|
|
845
927
|
{
|
|
846
|
-
className: ["p-6 overflow-y-auto flex-1",
|
|
847
|
-
...
|
|
928
|
+
className: ["p-6 overflow-y-auto flex-1", r].filter(Boolean).join(" "),
|
|
929
|
+
...n,
|
|
848
930
|
children: e
|
|
849
931
|
}
|
|
850
932
|
);
|
|
851
933
|
}
|
|
852
|
-
function
|
|
853
|
-
return /* @__PURE__ */
|
|
934
|
+
function Nt({ children: e, className: r = "", ...n }) {
|
|
935
|
+
return /* @__PURE__ */ t(
|
|
854
936
|
"div",
|
|
855
937
|
{
|
|
856
938
|
className: [
|
|
857
939
|
"flex items-center justify-end gap-3 p-6 border-t border-surface-container-high",
|
|
858
|
-
|
|
940
|
+
r
|
|
859
941
|
].filter(Boolean).join(" "),
|
|
860
|
-
...
|
|
942
|
+
...n,
|
|
861
943
|
children: e
|
|
862
944
|
}
|
|
863
945
|
);
|
|
864
946
|
}
|
|
865
|
-
function
|
|
866
|
-
return
|
|
947
|
+
function qe(e, r) {
|
|
948
|
+
return r <= 7 ? Array.from({ length: r }, (n, a) => a + 1) : e <= 4 ? [1, 2, 3, 4, 5, "...", r] : e >= r - 3 ? [1, "...", r - 4, r - 3, r - 2, r - 1, r] : [1, "...", e - 1, e, e + 1, "...", r];
|
|
867
949
|
}
|
|
868
|
-
function
|
|
950
|
+
function kt({
|
|
869
951
|
currentPage: e,
|
|
870
|
-
totalPages:
|
|
871
|
-
totalItems:
|
|
952
|
+
totalPages: r,
|
|
953
|
+
totalItems: n,
|
|
872
954
|
itemsPerPage: a = 10,
|
|
873
955
|
onPageChange: o,
|
|
874
956
|
variant: s = "full",
|
|
875
|
-
className:
|
|
957
|
+
className: l = "",
|
|
876
958
|
...c
|
|
877
959
|
}) {
|
|
878
|
-
const
|
|
879
|
-
return /* @__PURE__ */
|
|
960
|
+
const d = qe(e, r), f = (e - 1) * a + 1, m = Math.min(e * a, n ?? e * a), p = "inline-flex items-center justify-center text-sm font-medium rounded transition-all duration-150 focus:outline-none focus:ring-2 focus:ring-zeo-orange/30 disabled:opacity-40 disabled:cursor-not-allowed select-none", u = `${p} w-9 h-9`, h = "bg-zeo-orange text-white", x = "text-on-surface-variant hover:bg-surface-container-low hover:text-on-surface", w = `${p} px-3 h-9 gap-1.5 border border-surface-container-high text-on-surface-variant hover:bg-surface-container-low hover:text-on-surface`;
|
|
961
|
+
return /* @__PURE__ */ i(
|
|
880
962
|
"div",
|
|
881
963
|
{
|
|
882
|
-
className: ["flex items-center justify-between gap-4 flex-wrap",
|
|
964
|
+
className: ["flex items-center justify-between gap-4 flex-wrap", l].filter(Boolean).join(" "),
|
|
883
965
|
...c,
|
|
884
966
|
children: [
|
|
885
|
-
s === "full" &&
|
|
967
|
+
s === "full" && n !== void 0 && /* @__PURE__ */ i("p", { className: "text-sm text-on-surface-variant", children: [
|
|
886
968
|
"Mostrando ",
|
|
887
|
-
/* @__PURE__ */
|
|
888
|
-
|
|
969
|
+
/* @__PURE__ */ i("strong", { children: [
|
|
970
|
+
f,
|
|
889
971
|
"–",
|
|
890
|
-
|
|
972
|
+
m
|
|
891
973
|
] }),
|
|
892
974
|
" de ",
|
|
893
|
-
/* @__PURE__ */
|
|
975
|
+
/* @__PURE__ */ t("strong", { children: n }),
|
|
894
976
|
" itens"
|
|
895
977
|
] }),
|
|
896
|
-
/* @__PURE__ */
|
|
897
|
-
/* @__PURE__ */
|
|
978
|
+
/* @__PURE__ */ i("div", { className: "flex items-center gap-1 ml-auto", children: [
|
|
979
|
+
/* @__PURE__ */ i(
|
|
898
980
|
"button",
|
|
899
981
|
{
|
|
900
982
|
onClick: () => o(e - 1),
|
|
901
983
|
disabled: e === 1,
|
|
902
984
|
"aria-label": "Página anterior",
|
|
903
|
-
className: s === "icon" ?
|
|
985
|
+
className: s === "icon" ? u + " " + x : w,
|
|
904
986
|
children: [
|
|
905
|
-
/* @__PURE__ */
|
|
987
|
+
/* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[18px]", children: "arrow_back" }),
|
|
906
988
|
s === "text" && "Anterior"
|
|
907
989
|
]
|
|
908
990
|
}
|
|
909
991
|
),
|
|
910
|
-
|
|
911
|
-
(b, v) => b === "..." ? /* @__PURE__ */
|
|
992
|
+
d.map(
|
|
993
|
+
(b, v) => b === "..." ? /* @__PURE__ */ t("span", { className: "w-9 text-center text-sm text-on-surface-variant select-none", children: "…" }, `ellipsis-${v}`) : /* @__PURE__ */ t(
|
|
912
994
|
"button",
|
|
913
995
|
{
|
|
914
996
|
onClick: () => o(b),
|
|
915
997
|
"aria-current": e === b ? "page" : void 0,
|
|
916
|
-
className: [
|
|
998
|
+
className: [u, e === b ? h : x].join(" "),
|
|
917
999
|
children: b
|
|
918
1000
|
},
|
|
919
1001
|
b
|
|
920
1002
|
)
|
|
921
1003
|
),
|
|
922
|
-
/* @__PURE__ */
|
|
1004
|
+
/* @__PURE__ */ i(
|
|
923
1005
|
"button",
|
|
924
1006
|
{
|
|
925
1007
|
onClick: () => o(e + 1),
|
|
926
|
-
disabled: e ===
|
|
1008
|
+
disabled: e === r,
|
|
927
1009
|
"aria-label": "Próxima página",
|
|
928
|
-
className: s === "icon" ?
|
|
1010
|
+
className: s === "icon" ? u + " " + x : w,
|
|
929
1011
|
children: [
|
|
930
1012
|
s === "text" && "Próxima",
|
|
931
|
-
/* @__PURE__ */
|
|
1013
|
+
/* @__PURE__ */ t("span", { className: "material-symbols-outlined text-[18px]", children: "arrow_forward" })
|
|
932
1014
|
]
|
|
933
1015
|
}
|
|
934
1016
|
)
|
|
@@ -937,143 +1019,638 @@ function et({
|
|
|
937
1019
|
}
|
|
938
1020
|
);
|
|
939
1021
|
}
|
|
940
|
-
const
|
|
1022
|
+
const Ze = {
|
|
941
1023
|
xs: "h-1",
|
|
942
1024
|
sm: "h-1.5",
|
|
943
1025
|
md: "h-2",
|
|
944
1026
|
lg: "h-3"
|
|
945
|
-
},
|
|
1027
|
+
}, Qe = {
|
|
946
1028
|
primary: "bg-zeo-orange",
|
|
947
1029
|
success: "bg-green-500",
|
|
948
1030
|
warning: "bg-amber-400",
|
|
949
1031
|
danger: "bg-red-500"
|
|
950
1032
|
};
|
|
951
|
-
function
|
|
1033
|
+
function jt({
|
|
952
1034
|
value: e,
|
|
953
|
-
max:
|
|
954
|
-
size:
|
|
1035
|
+
max: r = 100,
|
|
1036
|
+
size: n = "md",
|
|
955
1037
|
variant: a = "primary",
|
|
956
1038
|
label: o = "none",
|
|
957
1039
|
showPercent: s = !0,
|
|
958
|
-
title:
|
|
1040
|
+
title: l,
|
|
959
1041
|
className: c = "",
|
|
960
|
-
...
|
|
1042
|
+
...d
|
|
961
1043
|
}) {
|
|
962
|
-
const
|
|
963
|
-
return /* @__PURE__ */
|
|
964
|
-
(
|
|
965
|
-
|
|
966
|
-
o === "outside" && s && /* @__PURE__ */
|
|
1044
|
+
const f = Math.min(100, Math.max(0, e / r * 100)), m = `${Math.round(f)}%`;
|
|
1045
|
+
return /* @__PURE__ */ i("div", { className: ["flex flex-col gap-1.5", c].filter(Boolean).join(" "), ...d, children: [
|
|
1046
|
+
(l || o === "outside" && s) && /* @__PURE__ */ i("div", { className: "flex items-center justify-between gap-2", children: [
|
|
1047
|
+
l && /* @__PURE__ */ t("span", { className: "text-sm font-medium text-on-surface", children: l }),
|
|
1048
|
+
o === "outside" && s && /* @__PURE__ */ t("span", { className: "text-sm font-semibold text-on-surface", children: m })
|
|
967
1049
|
] }),
|
|
968
|
-
/* @__PURE__ */
|
|
1050
|
+
/* @__PURE__ */ t(
|
|
969
1051
|
"div",
|
|
970
1052
|
{
|
|
971
1053
|
role: "progressbar",
|
|
972
1054
|
"aria-valuenow": e,
|
|
973
1055
|
"aria-valuemin": 0,
|
|
974
|
-
"aria-valuemax":
|
|
975
|
-
className: ["relative w-full bg-surface-container-high rounded-full overflow-hidden",
|
|
976
|
-
children: /* @__PURE__ */
|
|
1056
|
+
"aria-valuemax": r,
|
|
1057
|
+
className: ["relative w-full bg-surface-container-high rounded-full overflow-hidden", Ze[n]].join(" "),
|
|
1058
|
+
children: /* @__PURE__ */ t(
|
|
977
1059
|
"div",
|
|
978
1060
|
{
|
|
979
1061
|
className: [
|
|
980
1062
|
"h-full rounded-full transition-all duration-500 flex items-center justify-end pr-1",
|
|
981
|
-
|
|
1063
|
+
Qe[a]
|
|
982
1064
|
].join(" "),
|
|
983
|
-
style: { width: `${
|
|
984
|
-
children: o === "inside" && s &&
|
|
1065
|
+
style: { width: `${f}%` },
|
|
1066
|
+
children: o === "inside" && s && f >= 20 && /* @__PURE__ */ t("span", { className: "text-[10px] font-bold text-white leading-none", children: m })
|
|
985
1067
|
}
|
|
986
1068
|
)
|
|
987
1069
|
}
|
|
988
1070
|
)
|
|
989
1071
|
] });
|
|
990
1072
|
}
|
|
991
|
-
const
|
|
1073
|
+
const re = (e, r) => typeof e == "function" ? e(r) : e;
|
|
1074
|
+
function Ct({
|
|
1075
|
+
sidebar: e,
|
|
1076
|
+
navbar: r,
|
|
1077
|
+
children: n,
|
|
1078
|
+
defaultExpanded: a = !1,
|
|
1079
|
+
isExpanded: o,
|
|
1080
|
+
onToggle: s
|
|
1081
|
+
}) {
|
|
1082
|
+
const [l, c] = k(a), d = o ?? l, f = j(() => {
|
|
1083
|
+
o === void 0 && c((p) => !p), s == null || s();
|
|
1084
|
+
}, [o, s]), m = { isExpanded: d, toggle: f };
|
|
1085
|
+
return /* @__PURE__ */ i("div", { className: "flex h-screen overflow-hidden", children: [
|
|
1086
|
+
re(e, m),
|
|
1087
|
+
/* @__PURE__ */ i(
|
|
1088
|
+
"div",
|
|
1089
|
+
{
|
|
1090
|
+
className: [
|
|
1091
|
+
"flex-1 flex flex-col overflow-hidden transition-[margin-left] duration-shell ease-shell",
|
|
1092
|
+
d ? "ml-sidebar-expanded" : "ml-sidebar-collapsed"
|
|
1093
|
+
].join(" "),
|
|
1094
|
+
children: [
|
|
1095
|
+
re(r, m),
|
|
1096
|
+
/* @__PURE__ */ t("main", { className: "flex-1 overflow-y-auto bg-surface-container dark:bg-canvas", children: n })
|
|
1097
|
+
]
|
|
1098
|
+
}
|
|
1099
|
+
)
|
|
1100
|
+
] });
|
|
1101
|
+
}
|
|
1102
|
+
const Ye = ({ href: e, className: r, children: n }) => /* @__PURE__ */ t("a", { href: e, className: r, children: n }), ae = "text-[10px] uppercase tracking-widest text-white/30 font-bold";
|
|
1103
|
+
function oe({ item: e, isActive: r, isExpanded: n, renderLink: a = Ye }) {
|
|
1104
|
+
const o = e.disabled || !e.href, s = !n || o && e.disabledReason, l = /* @__PURE__ */ i(
|
|
1105
|
+
"div",
|
|
1106
|
+
{
|
|
1107
|
+
className: [
|
|
1108
|
+
"group relative flex items-center gap-3 px-4 py-3 rounded-lg transition-colors duration-150",
|
|
1109
|
+
r ? "bg-primary-container/10 text-primary-container border-r-2 border-primary-container" : o ? "text-white/30 opacity-50 cursor-default" : "text-white/55 hover:bg-sidebar-hover hover:text-white cursor-pointer"
|
|
1110
|
+
].join(" "),
|
|
1111
|
+
children: [
|
|
1112
|
+
e.icon,
|
|
1113
|
+
/* @__PURE__ */ t(
|
|
1114
|
+
"span",
|
|
1115
|
+
{
|
|
1116
|
+
className: [
|
|
1117
|
+
"text-sm font-medium whitespace-nowrap overflow-hidden transition-opacity duration-shell",
|
|
1118
|
+
n ? "opacity-100" : "opacity-0 w-0"
|
|
1119
|
+
].join(" "),
|
|
1120
|
+
children: e.label
|
|
1121
|
+
}
|
|
1122
|
+
),
|
|
1123
|
+
/* @__PURE__ */ i(
|
|
1124
|
+
"div",
|
|
1125
|
+
{
|
|
1126
|
+
role: "tooltip",
|
|
1127
|
+
className: [
|
|
1128
|
+
"absolute left-full ml-3 px-3 py-2 bg-surface-container-lowest text-gray-700 dark:text-content-secondary text-sm font-medium",
|
|
1129
|
+
"rounded-lg shadow-theme-lg whitespace-nowrap z-[200] pointer-events-none",
|
|
1130
|
+
"invisible opacity-0 transition-all duration-150",
|
|
1131
|
+
s && "group-hover:visible group-hover:opacity-100"
|
|
1132
|
+
].filter(Boolean).join(" "),
|
|
1133
|
+
children: [
|
|
1134
|
+
o && e.disabledReason ? e.disabledReason : e.label,
|
|
1135
|
+
/* @__PURE__ */ t("div", { className: "absolute top-1/2 -left-1 -translate-y-1/2 w-2 h-2 bg-surface-container-lowest rotate-45" })
|
|
1136
|
+
]
|
|
1137
|
+
}
|
|
1138
|
+
)
|
|
1139
|
+
]
|
|
1140
|
+
}
|
|
1141
|
+
);
|
|
1142
|
+
return o ? /* @__PURE__ */ t("div", { children: l }) : a({ item: e, href: e.href, className: "block no-underline", children: l });
|
|
1143
|
+
}
|
|
1144
|
+
function Je({ section: e, index: r = 0, activeId: n, isExpanded: a, renderLink: o }) {
|
|
1145
|
+
return /* @__PURE__ */ i(ne, { children: [
|
|
1146
|
+
e.label && /* @__PURE__ */ t(
|
|
1147
|
+
"div",
|
|
1148
|
+
{
|
|
1149
|
+
className: [
|
|
1150
|
+
"overflow-hidden transition-all duration-shell px-3",
|
|
1151
|
+
a ? "h-6 opacity-100 mb-1" : "h-0 opacity-0",
|
|
1152
|
+
r > 0 ? "mt-4" : ""
|
|
1153
|
+
].join(" "),
|
|
1154
|
+
children: /* @__PURE__ */ t("span", { className: ae, children: e.label })
|
|
1155
|
+
}
|
|
1156
|
+
),
|
|
1157
|
+
e.items.map((s) => /* @__PURE__ */ t(
|
|
1158
|
+
oe,
|
|
1159
|
+
{
|
|
1160
|
+
item: s,
|
|
1161
|
+
isActive: s.id === n,
|
|
1162
|
+
isExpanded: a,
|
|
1163
|
+
renderLink: o
|
|
1164
|
+
},
|
|
1165
|
+
s.id
|
|
1166
|
+
))
|
|
1167
|
+
] });
|
|
1168
|
+
}
|
|
1169
|
+
function Bt({ sections: e, activeId: r, isExpanded: n, logo: a, renderLink: o }) {
|
|
1170
|
+
const s = e.filter((d) => d.placement !== "bottom"), l = e.filter((d) => d.placement === "bottom"), c = /* @__PURE__ */ t(
|
|
1171
|
+
"img",
|
|
1172
|
+
{
|
|
1173
|
+
src: a.src,
|
|
1174
|
+
alt: a.alt ?? "",
|
|
1175
|
+
className: [
|
|
1176
|
+
"flex-shrink-0",
|
|
1177
|
+
n ? "h-8 w-auto object-contain" : "w-10 h-10 object-cover object-left"
|
|
1178
|
+
].join(" ")
|
|
1179
|
+
}
|
|
1180
|
+
);
|
|
1181
|
+
return /* @__PURE__ */ i(
|
|
1182
|
+
"aside",
|
|
1183
|
+
{
|
|
1184
|
+
className: [
|
|
1185
|
+
"fixed left-0 top-0 h-screen bg-sidebar flex flex-col z-[100]",
|
|
1186
|
+
"transition-[width] duration-shell ease-shell",
|
|
1187
|
+
"shadow-[40px_0_40px_0_rgba(0,0,0,0.04)]",
|
|
1188
|
+
n ? "w-sidebar-expanded" : "w-sidebar-collapsed"
|
|
1189
|
+
].join(" "),
|
|
1190
|
+
children: [
|
|
1191
|
+
/* @__PURE__ */ t(
|
|
1192
|
+
"div",
|
|
1193
|
+
{
|
|
1194
|
+
className: [
|
|
1195
|
+
"h-[88px] flex items-center flex-shrink-0",
|
|
1196
|
+
n ? "px-6 justify-start" : "justify-center"
|
|
1197
|
+
].join(" "),
|
|
1198
|
+
children: a.href ? /* @__PURE__ */ t("a", { href: a.href, "aria-label": a.alt, className: "flex-shrink-0", children: c }) : c
|
|
1199
|
+
}
|
|
1200
|
+
),
|
|
1201
|
+
/* @__PURE__ */ t("nav", { className: "flex-1 flex flex-col py-2 px-3 gap-1", children: s.map((d, f) => /* @__PURE__ */ t(
|
|
1202
|
+
Je,
|
|
1203
|
+
{
|
|
1204
|
+
section: d,
|
|
1205
|
+
index: f,
|
|
1206
|
+
activeId: r,
|
|
1207
|
+
isExpanded: n,
|
|
1208
|
+
renderLink: o
|
|
1209
|
+
},
|
|
1210
|
+
d.id
|
|
1211
|
+
)) }),
|
|
1212
|
+
l.map((d) => /* @__PURE__ */ i("div", { className: "flex-shrink-0 pb-4", children: [
|
|
1213
|
+
d.label && /* @__PURE__ */ t(
|
|
1214
|
+
"div",
|
|
1215
|
+
{
|
|
1216
|
+
className: [
|
|
1217
|
+
"px-6 mb-2 overflow-hidden transition-all duration-shell",
|
|
1218
|
+
n ? "h-7 opacity-100" : "h-0 opacity-0"
|
|
1219
|
+
].join(" "),
|
|
1220
|
+
children: /* @__PURE__ */ t("span", { className: ae, children: d.label })
|
|
1221
|
+
}
|
|
1222
|
+
),
|
|
1223
|
+
/* @__PURE__ */ t("div", { className: "border-t border-white/[0.06] mb-2" }),
|
|
1224
|
+
/* @__PURE__ */ t("div", { className: "px-3", children: d.items.map((f) => /* @__PURE__ */ t(
|
|
1225
|
+
oe,
|
|
1226
|
+
{
|
|
1227
|
+
item: f,
|
|
1228
|
+
isActive: f.id === r,
|
|
1229
|
+
isExpanded: n,
|
|
1230
|
+
renderLink: o
|
|
1231
|
+
},
|
|
1232
|
+
f.id
|
|
1233
|
+
)) })
|
|
1234
|
+
] }, d.id))
|
|
1235
|
+
]
|
|
1236
|
+
}
|
|
1237
|
+
);
|
|
1238
|
+
}
|
|
1239
|
+
function zt({
|
|
1240
|
+
onToggleMenu: e,
|
|
1241
|
+
start: r,
|
|
1242
|
+
search: n,
|
|
1243
|
+
actions: a,
|
|
1244
|
+
userMenu: o,
|
|
1245
|
+
toggleMenuLabel: s = "Alternar menu"
|
|
1246
|
+
}) {
|
|
1247
|
+
return /* @__PURE__ */ i("header", { className: "h-navbar bg-surface-container-lowest dark:bg-page border-b border-surface-container-highest dark:border-line-section flex items-center justify-between px-6 sticky top-0 z-50 flex-shrink-0", children: [
|
|
1248
|
+
/* @__PURE__ */ i("div", { className: "flex items-center gap-4 flex-1 min-w-0", children: [
|
|
1249
|
+
/* @__PURE__ */ t(
|
|
1250
|
+
"button",
|
|
1251
|
+
{
|
|
1252
|
+
type: "button",
|
|
1253
|
+
onClick: e,
|
|
1254
|
+
"aria-label": s,
|
|
1255
|
+
className: "flex items-center justify-center p-2 rounded-full text-on-secondary-container hover:bg-surface-container-high transition-colors flex-shrink-0",
|
|
1256
|
+
children: /* @__PURE__ */ t(N, { name: "menu", size: 20 })
|
|
1257
|
+
}
|
|
1258
|
+
),
|
|
1259
|
+
r,
|
|
1260
|
+
n
|
|
1261
|
+
] }),
|
|
1262
|
+
(a || o) && /* @__PURE__ */ i("div", { className: "flex items-center gap-1 flex-shrink-0 ml-4", children: [
|
|
1263
|
+
a,
|
|
1264
|
+
a && o && /* @__PURE__ */ t("div", { className: "w-px h-6 bg-outline-variant opacity-30 mx-2 flex-shrink-0" }),
|
|
1265
|
+
o
|
|
1266
|
+
] })
|
|
1267
|
+
] });
|
|
1268
|
+
}
|
|
1269
|
+
function Lt({ module: e, project: r }) {
|
|
1270
|
+
return /* @__PURE__ */ i("div", { className: "flex items-baseline gap-2 min-w-0", children: [
|
|
1271
|
+
/* @__PURE__ */ t("span", { className: "text-title-md font-bold text-on-surface whitespace-nowrap", children: e }),
|
|
1272
|
+
r && /* @__PURE__ */ i(ne, { children: [
|
|
1273
|
+
/* @__PURE__ */ t("span", { className: "text-on-surface-variant", "aria-hidden": "true", children: "/" }),
|
|
1274
|
+
/* @__PURE__ */ t("span", { className: "text-body-md text-on-surface-variant truncate", children: r })
|
|
1275
|
+
] })
|
|
1276
|
+
] });
|
|
1277
|
+
}
|
|
1278
|
+
function _t({ value: e, onChange: r, placeholder: n, shortcutHint: a, focusShortcut: o = !1 }) {
|
|
1279
|
+
const s = M(null);
|
|
1280
|
+
return C(() => {
|
|
1281
|
+
if (!o) return;
|
|
1282
|
+
const l = (c) => {
|
|
1283
|
+
var d;
|
|
1284
|
+
(c.metaKey || c.ctrlKey) && c.key === "k" && (c.preventDefault(), (d = s.current) == null || d.focus());
|
|
1285
|
+
};
|
|
1286
|
+
return document.addEventListener("keydown", l), () => document.removeEventListener("keydown", l);
|
|
1287
|
+
}, [o]), /* @__PURE__ */ i("div", { className: "relative w-full max-w-md", children: [
|
|
1288
|
+
/* @__PURE__ */ t(
|
|
1289
|
+
N,
|
|
1290
|
+
{
|
|
1291
|
+
name: "search",
|
|
1292
|
+
size: 18,
|
|
1293
|
+
className: "absolute left-3 top-1/2 -translate-y-1/2 text-on-secondary-container pointer-events-none"
|
|
1294
|
+
}
|
|
1295
|
+
),
|
|
1296
|
+
/* @__PURE__ */ t(
|
|
1297
|
+
"input",
|
|
1298
|
+
{
|
|
1299
|
+
ref: s,
|
|
1300
|
+
value: e,
|
|
1301
|
+
onChange: (l) => r(l.target.value),
|
|
1302
|
+
placeholder: n,
|
|
1303
|
+
"aria-label": n,
|
|
1304
|
+
className: [
|
|
1305
|
+
"w-full h-9 pl-10 rounded-lg",
|
|
1306
|
+
a ? "pr-[90px]" : "pr-3",
|
|
1307
|
+
"border border-transparent bg-surface-container",
|
|
1308
|
+
"text-sm text-on-surface font-sans placeholder:text-on-surface-variant",
|
|
1309
|
+
"outline-none transition-all",
|
|
1310
|
+
"focus:border-primary-container focus:shadow-zeo-focus focus:bg-surface-container-lowest"
|
|
1311
|
+
].join(" ")
|
|
1312
|
+
}
|
|
1313
|
+
),
|
|
1314
|
+
a && /* @__PURE__ */ t("span", { className: "absolute right-3 top-1/2 -translate-y-1/2 text-xs text-on-surface-variant bg-surface-container-lowest border border-surface-container-highest rounded px-1 py-px whitespace-nowrap pointer-events-none", children: a })
|
|
1315
|
+
] });
|
|
1316
|
+
}
|
|
1317
|
+
function se({ icon: e, label: r, badge: n = !1, className: a = "", type: o = "button", ...s }) {
|
|
1318
|
+
return /* @__PURE__ */ i(
|
|
1319
|
+
"button",
|
|
1320
|
+
{
|
|
1321
|
+
...s,
|
|
1322
|
+
type: o,
|
|
1323
|
+
"aria-label": r,
|
|
1324
|
+
className: `relative flex items-center justify-center p-2 rounded-full text-on-secondary-container hover:bg-surface-container-high transition-colors ${a}`.trim(),
|
|
1325
|
+
children: [
|
|
1326
|
+
e,
|
|
1327
|
+
n && /* @__PURE__ */ t("span", { className: "absolute top-2 right-2 w-2 h-2 bg-error rounded-full" })
|
|
1328
|
+
]
|
|
1329
|
+
}
|
|
1330
|
+
);
|
|
1331
|
+
}
|
|
1332
|
+
function Tt({ hasUnread: e = !1, count: r = 0, onClick: n, label: a = "Notificações" }) {
|
|
1333
|
+
return /* @__PURE__ */ t(
|
|
1334
|
+
se,
|
|
1335
|
+
{
|
|
1336
|
+
icon: /* @__PURE__ */ t(N, { name: "notifications", size: 20 }),
|
|
1337
|
+
label: a,
|
|
1338
|
+
badge: e || r > 0,
|
|
1339
|
+
onClick: n
|
|
1340
|
+
}
|
|
1341
|
+
);
|
|
1342
|
+
}
|
|
1343
|
+
const Xe = {
|
|
1344
|
+
read: () => {
|
|
1345
|
+
try {
|
|
1346
|
+
const e = window.localStorage.getItem(U);
|
|
1347
|
+
return e === "dark" || e === "light" ? e : null;
|
|
1348
|
+
} catch {
|
|
1349
|
+
return null;
|
|
1350
|
+
}
|
|
1351
|
+
},
|
|
1352
|
+
write: (e) => {
|
|
1353
|
+
try {
|
|
1354
|
+
window.localStorage.setItem(U, e);
|
|
1355
|
+
} catch {
|
|
1356
|
+
return;
|
|
1357
|
+
}
|
|
1358
|
+
}
|
|
1359
|
+
}, Mt = `try{if(localStorage.getItem('${U}')==='dark')document.documentElement.setAttribute('${W}','dark')}catch(e){}`;
|
|
1360
|
+
function Pe(e, r = document.documentElement) {
|
|
1361
|
+
e === "dark" ? r.setAttribute(W, "dark") : r.removeAttribute(W);
|
|
1362
|
+
}
|
|
1363
|
+
const O = G(null);
|
|
1364
|
+
function It({
|
|
1365
|
+
children: e,
|
|
1366
|
+
defaultTheme: r = "light",
|
|
1367
|
+
storage: n = Xe
|
|
1368
|
+
}) {
|
|
1369
|
+
const [a, o] = k(() => n.read() ?? r);
|
|
1370
|
+
C(() => {
|
|
1371
|
+
Pe(a);
|
|
1372
|
+
}, [a]);
|
|
1373
|
+
const s = j(
|
|
1374
|
+
(d) => {
|
|
1375
|
+
n.write(d), o(d);
|
|
1376
|
+
},
|
|
1377
|
+
[n]
|
|
1378
|
+
), l = j(() => s(a === "dark" ? "light" : "dark"), [s, a]), c = ge(
|
|
1379
|
+
() => ({ theme: a, isDark: a === "dark", setTheme: s, toggleTheme: l }),
|
|
1380
|
+
[a, s, l]
|
|
1381
|
+
);
|
|
1382
|
+
return /* @__PURE__ */ t(O.Provider, { value: c, children: e });
|
|
1383
|
+
}
|
|
1384
|
+
function et() {
|
|
1385
|
+
return E(O);
|
|
1386
|
+
}
|
|
1387
|
+
function $t() {
|
|
1388
|
+
const e = E(O);
|
|
1389
|
+
if (!e) throw new Error("useTheme precisa estar dentro de um ThemeProvider");
|
|
1390
|
+
return e;
|
|
1391
|
+
}
|
|
1392
|
+
function ie(e, r, n) {
|
|
1393
|
+
C(() => {
|
|
1394
|
+
if (!r) return;
|
|
1395
|
+
const a = (s) => {
|
|
1396
|
+
s.key === "Escape" && n();
|
|
1397
|
+
}, o = (s) => {
|
|
1398
|
+
var l;
|
|
1399
|
+
(l = e.current) != null && l.contains(s.target) || n();
|
|
1400
|
+
};
|
|
1401
|
+
return document.addEventListener("keydown", a), document.addEventListener("mousedown", o), () => {
|
|
1402
|
+
document.removeEventListener("keydown", a), document.removeEventListener("mousedown", o);
|
|
1403
|
+
};
|
|
1404
|
+
}, [e, r, n]);
|
|
1405
|
+
}
|
|
1406
|
+
const tt = {
|
|
1407
|
+
myAccount: "Minha Conta",
|
|
1408
|
+
logout: "Sair",
|
|
1409
|
+
darkMode: "Modo escuro",
|
|
1410
|
+
user: "Usuário"
|
|
1411
|
+
};
|
|
1412
|
+
function At({ name: e, email: r, shortName: n, profilePicUrl: a, onMyAccount: o, onLogout: s, labels: l }) {
|
|
1413
|
+
const c = { ...tt, ...l }, [d, f] = k(!1), m = M(null), p = et(), u = j(() => f(!1), []);
|
|
1414
|
+
return ie(m, d, u), /* @__PURE__ */ i("div", { ref: m, className: "relative flex items-center", children: [
|
|
1415
|
+
/* @__PURE__ */ i(
|
|
1416
|
+
"button",
|
|
1417
|
+
{
|
|
1418
|
+
type: "button",
|
|
1419
|
+
onClick: () => f((h) => !h),
|
|
1420
|
+
"aria-haspopup": "true",
|
|
1421
|
+
"aria-expanded": d,
|
|
1422
|
+
className: "flex items-center gap-2 px-2 py-1 rounded-full border-none bg-transparent cursor-pointer text-on-surface-variant hover:bg-surface-container-low transition-colors",
|
|
1423
|
+
children: [
|
|
1424
|
+
n && /* @__PURE__ */ t("span", { className: "text-sm font-medium text-on-surface", children: n }),
|
|
1425
|
+
/* @__PURE__ */ t(P, { src: a, name: e, size: "sm", "aria-label": e || c.user }),
|
|
1426
|
+
/* @__PURE__ */ t("span", { className: `flex items-center transition-transform duration-200 ${d ? "rotate-180" : "rotate-0"}`, children: /* @__PURE__ */ t(N, { name: "expand_more", size: 13 }) })
|
|
1427
|
+
]
|
|
1428
|
+
}
|
|
1429
|
+
),
|
|
1430
|
+
d && /* @__PURE__ */ i(
|
|
1431
|
+
"div",
|
|
1432
|
+
{
|
|
1433
|
+
role: "menu",
|
|
1434
|
+
className: "absolute right-0 top-[calc(100%+8px)] min-w-[220px] bg-surface-container-lowest border border-surface-container-highest rounded-xl shadow-theme-lg z-[200] overflow-hidden",
|
|
1435
|
+
children: [
|
|
1436
|
+
/* @__PURE__ */ i("div", { className: "flex items-center gap-3 p-4", children: [
|
|
1437
|
+
/* @__PURE__ */ t(P, { src: a, name: e, size: "sm" }),
|
|
1438
|
+
/* @__PURE__ */ i("div", { className: "flex flex-col gap-0.5 min-w-0", children: [
|
|
1439
|
+
/* @__PURE__ */ t("span", { className: "text-sm font-bold text-on-surface whitespace-nowrap overflow-hidden text-ellipsis", children: e }),
|
|
1440
|
+
/* @__PURE__ */ t("span", { className: "text-xs text-on-surface-variant whitespace-nowrap overflow-hidden text-ellipsis", children: r })
|
|
1441
|
+
] })
|
|
1442
|
+
] }),
|
|
1443
|
+
/* @__PURE__ */ t("hr", { className: "m-0 border-t border-surface-container-highest" }),
|
|
1444
|
+
/* @__PURE__ */ i(
|
|
1445
|
+
"button",
|
|
1446
|
+
{
|
|
1447
|
+
type: "button",
|
|
1448
|
+
role: "menuitem",
|
|
1449
|
+
onClick: () => {
|
|
1450
|
+
u(), o();
|
|
1451
|
+
},
|
|
1452
|
+
className: "w-full flex items-center gap-3 px-4 py-2.5 border-none bg-transparent cursor-pointer text-left text-on-surface hover:bg-surface-container-low transition-colors",
|
|
1453
|
+
children: [
|
|
1454
|
+
/* @__PURE__ */ t(N, { name: "person", size: 15 }),
|
|
1455
|
+
/* @__PURE__ */ t("span", { className: "text-sm font-medium", children: c.myAccount })
|
|
1456
|
+
]
|
|
1457
|
+
}
|
|
1458
|
+
),
|
|
1459
|
+
p && /* @__PURE__ */ i(
|
|
1460
|
+
"button",
|
|
1461
|
+
{
|
|
1462
|
+
type: "button",
|
|
1463
|
+
role: "menuitemcheckbox",
|
|
1464
|
+
"aria-checked": p.isDark,
|
|
1465
|
+
onClick: p.toggleTheme,
|
|
1466
|
+
className: "w-full flex items-center gap-3 px-4 py-2.5 border-none bg-transparent cursor-pointer text-left text-on-surface hover:bg-surface-container-low transition-colors",
|
|
1467
|
+
children: [
|
|
1468
|
+
/* @__PURE__ */ t(N, { name: "dark_mode", size: 15 }),
|
|
1469
|
+
/* @__PURE__ */ t("span", { className: "flex-1 text-sm font-medium", children: c.darkMode }),
|
|
1470
|
+
/* @__PURE__ */ t(
|
|
1471
|
+
"span",
|
|
1472
|
+
{
|
|
1473
|
+
className: `relative w-7 h-4 shrink-0 rounded-full transition-colors duration-150 ${p.isDark ? "bg-zeo-orange" : "bg-line-strong"}`,
|
|
1474
|
+
children: /* @__PURE__ */ t(
|
|
1475
|
+
"span",
|
|
1476
|
+
{
|
|
1477
|
+
className: `absolute top-0.5 w-3 h-3 rounded-full bg-white transition-[left] duration-150 ${p.isDark ? "left-3.5" : "left-0.5"}`
|
|
1478
|
+
}
|
|
1479
|
+
)
|
|
1480
|
+
}
|
|
1481
|
+
)
|
|
1482
|
+
]
|
|
1483
|
+
}
|
|
1484
|
+
),
|
|
1485
|
+
/* @__PURE__ */ t("hr", { className: "m-0 border-t border-surface-container-highest" }),
|
|
1486
|
+
/* @__PURE__ */ i(
|
|
1487
|
+
"button",
|
|
1488
|
+
{
|
|
1489
|
+
type: "button",
|
|
1490
|
+
role: "menuitem",
|
|
1491
|
+
onClick: () => {
|
|
1492
|
+
u(), s();
|
|
1493
|
+
},
|
|
1494
|
+
className: "w-full flex items-center gap-3 px-4 py-2.5 border-none bg-transparent cursor-pointer text-left text-error hover:bg-error/5 transition-colors",
|
|
1495
|
+
children: [
|
|
1496
|
+
/* @__PURE__ */ t(N, { name: "logout", size: 15 }),
|
|
1497
|
+
/* @__PURE__ */ t("span", { className: "text-sm font-medium", children: c.logout })
|
|
1498
|
+
]
|
|
1499
|
+
}
|
|
1500
|
+
)
|
|
1501
|
+
]
|
|
1502
|
+
}
|
|
1503
|
+
)
|
|
1504
|
+
] });
|
|
1505
|
+
}
|
|
1506
|
+
const rt = {
|
|
1507
|
+
help: "Ajuda",
|
|
1508
|
+
documentation: "Documentação",
|
|
1509
|
+
faq: "F.A.Q.",
|
|
1510
|
+
changelog: "Changelog",
|
|
1511
|
+
contactUs: "Contate-nos"
|
|
1512
|
+
};
|
|
1513
|
+
function Et({ labels: e, hrefs: r }) {
|
|
1514
|
+
const n = { ...rt, ...e }, a = M(null), [o, s] = k(!1), l = j(() => s(!1), []);
|
|
1515
|
+
return ie(a, o, l), /* @__PURE__ */ i("div", { ref: a, className: "relative", children: [
|
|
1516
|
+
/* @__PURE__ */ t(
|
|
1517
|
+
se,
|
|
1518
|
+
{
|
|
1519
|
+
icon: /* @__PURE__ */ t(N, { name: "help", size: 20 }),
|
|
1520
|
+
label: n.help,
|
|
1521
|
+
onClick: () => s((c) => !c),
|
|
1522
|
+
"aria-haspopup": "true",
|
|
1523
|
+
"aria-expanded": o
|
|
1524
|
+
}
|
|
1525
|
+
),
|
|
1526
|
+
o && /* @__PURE__ */ i(
|
|
1527
|
+
"div",
|
|
1528
|
+
{
|
|
1529
|
+
role: "menu",
|
|
1530
|
+
className: "absolute right-0 top-[calc(100%+8px)] w-56 bg-surface-container-lowest border border-surface-container-highest rounded-xl shadow-theme-lg py-1 z-[200] overflow-hidden",
|
|
1531
|
+
children: [
|
|
1532
|
+
/* @__PURE__ */ t(A, { icon: "description", label: n.documentation, href: r == null ? void 0 : r.documentation }),
|
|
1533
|
+
/* @__PURE__ */ t(A, { icon: "help_outline", label: n.faq, href: r == null ? void 0 : r.faq }),
|
|
1534
|
+
/* @__PURE__ */ t(A, { icon: "assignment", label: n.changelog, href: r == null ? void 0 : r.changelog }),
|
|
1535
|
+
/* @__PURE__ */ t("div", { className: "my-1 border-t border-surface-container-highest" }),
|
|
1536
|
+
/* @__PURE__ */ t(A, { icon: "mail", label: n.contactUs, href: r == null ? void 0 : r.contactUs })
|
|
1537
|
+
]
|
|
1538
|
+
}
|
|
1539
|
+
)
|
|
1540
|
+
] });
|
|
1541
|
+
}
|
|
1542
|
+
function A({ icon: e, label: r, href: n = "#" }) {
|
|
1543
|
+
return /* @__PURE__ */ i(
|
|
1544
|
+
"a",
|
|
1545
|
+
{
|
|
1546
|
+
href: n,
|
|
1547
|
+
role: "menuitem",
|
|
1548
|
+
className: "flex items-center gap-3 px-4 py-2.5 text-sm font-medium text-on-surface-variant hover:bg-surface-container hover:text-on-surface transition-colors no-underline",
|
|
1549
|
+
children: [
|
|
1550
|
+
/* @__PURE__ */ t(N, { name: e, size: 18, className: "opacity-70" }),
|
|
1551
|
+
r
|
|
1552
|
+
]
|
|
1553
|
+
}
|
|
1554
|
+
);
|
|
1555
|
+
}
|
|
1556
|
+
const St = [
|
|
1557
|
+
{ id: "tower", status: "active", iconName: "cell_tower", labelKey: "modules.tower.title" },
|
|
1558
|
+
{ id: "antennas", status: "active", iconName: "settings_input_antenna", labelKey: "modules.antennas.title" },
|
|
1559
|
+
{ id: "rooftop", status: "active", iconName: "roofing", labelKey: "modules.rooftop.title" },
|
|
1560
|
+
{ id: "radier", status: "active", iconName: "layers", IconComponent: De, labelKey: "modules.radier.title" },
|
|
1561
|
+
{ id: "caisson_foundation", status: "coming_soon", iconName: "filter_alt", IconComponent: He, labelKey: "modules.caisson_foundation.title" },
|
|
1562
|
+
{ id: "pole", status: "coming_soon", iconName: "fence", IconComponent: Ke, labelKey: "modules.pole.title" },
|
|
1563
|
+
{ id: "dashboards", status: "coming_soon", iconName: "dashboard", labelKey: "modules.dashboards.title" }
|
|
1564
|
+
];
|
|
1565
|
+
function Rt(e, r, n) {
|
|
1566
|
+
return e.filter((a) => r.includes(a.id) || n.includes(a.id)).map((a) => ({ module: a, hasAccess: n.includes(a.id) }));
|
|
1567
|
+
}
|
|
1568
|
+
const nt = {
|
|
992
1569
|
xs: "w-3 h-3 border",
|
|
993
1570
|
sm: "w-4 h-4 border-2",
|
|
994
1571
|
md: "w-6 h-6 border-2",
|
|
995
1572
|
lg: "w-8 h-8 border-[3px]",
|
|
996
1573
|
xl: "w-12 h-12 border-4"
|
|
997
|
-
},
|
|
998
|
-
primary: "border-orange-200 border-t-zeo-orange",
|
|
1574
|
+
}, at = {
|
|
1575
|
+
primary: "border-orange-200 dark:border-zeo-orange/30 border-t-zeo-orange",
|
|
999
1576
|
secondary: "border-surface-container-high border-t-on-surface-variant",
|
|
1000
1577
|
white: "border-white/30 border-t-white"
|
|
1001
1578
|
};
|
|
1002
|
-
function
|
|
1579
|
+
function Ft({
|
|
1003
1580
|
size: e = "md",
|
|
1004
|
-
variant:
|
|
1005
|
-
label:
|
|
1581
|
+
variant: r = "primary",
|
|
1582
|
+
label: n = "Carregando...",
|
|
1006
1583
|
className: a = "",
|
|
1007
1584
|
...o
|
|
1008
1585
|
}) {
|
|
1009
|
-
return /* @__PURE__ */
|
|
1586
|
+
return /* @__PURE__ */ t(
|
|
1010
1587
|
"span",
|
|
1011
1588
|
{
|
|
1012
1589
|
role: "status",
|
|
1013
|
-
"aria-label":
|
|
1590
|
+
"aria-label": n,
|
|
1014
1591
|
className: [
|
|
1015
1592
|
"inline-block rounded-full animate-spin",
|
|
1016
|
-
|
|
1017
|
-
|
|
1593
|
+
nt[e],
|
|
1594
|
+
at[r],
|
|
1018
1595
|
a
|
|
1019
1596
|
].filter(Boolean).join(" "),
|
|
1020
1597
|
...o
|
|
1021
1598
|
}
|
|
1022
1599
|
);
|
|
1023
1600
|
}
|
|
1024
|
-
function
|
|
1025
|
-
return /* @__PURE__ */
|
|
1601
|
+
function Vt({ children: e, className: r = "", ...n }) {
|
|
1602
|
+
return /* @__PURE__ */ t(
|
|
1026
1603
|
"div",
|
|
1027
1604
|
{
|
|
1028
|
-
className: ["overflow-x-auto rounded-xl border border-surface-container-high shadow-sm",
|
|
1029
|
-
...
|
|
1030
|
-
children: /* @__PURE__ */
|
|
1605
|
+
className: ["overflow-x-auto rounded-xl border border-surface-container-high shadow-sm", r].filter(Boolean).join(" "),
|
|
1606
|
+
...n,
|
|
1607
|
+
children: /* @__PURE__ */ t("table", { className: "w-full text-sm", children: e })
|
|
1031
1608
|
}
|
|
1032
1609
|
);
|
|
1033
1610
|
}
|
|
1034
|
-
function
|
|
1035
|
-
return /* @__PURE__ */
|
|
1611
|
+
function Dt({ children: e, className: r = "", ...n }) {
|
|
1612
|
+
return /* @__PURE__ */ t(
|
|
1036
1613
|
"thead",
|
|
1037
1614
|
{
|
|
1038
|
-
className: ["bg-surface-container-low border-b border-surface-container-high",
|
|
1039
|
-
...
|
|
1615
|
+
className: ["bg-surface-container-low border-b border-surface-container-high", r].filter(Boolean).join(" "),
|
|
1616
|
+
...n,
|
|
1040
1617
|
children: e
|
|
1041
1618
|
}
|
|
1042
1619
|
);
|
|
1043
1620
|
}
|
|
1044
|
-
function
|
|
1045
|
-
return /* @__PURE__ */
|
|
1621
|
+
function Ht({ children: e, className: r = "", ...n }) {
|
|
1622
|
+
return /* @__PURE__ */ t(
|
|
1046
1623
|
"tbody",
|
|
1047
1624
|
{
|
|
1048
|
-
className: ["bg-
|
|
1049
|
-
...
|
|
1625
|
+
className: ["bg-surface-container-lowest divide-y divide-surface-container-high", r].filter(Boolean).join(" "),
|
|
1626
|
+
...n,
|
|
1050
1627
|
children: e
|
|
1051
1628
|
}
|
|
1052
1629
|
);
|
|
1053
1630
|
}
|
|
1054
|
-
function
|
|
1055
|
-
return /* @__PURE__ */
|
|
1631
|
+
function Kt({ selected: e = !1, children: r, className: n = "", ...a }) {
|
|
1632
|
+
return /* @__PURE__ */ t(
|
|
1056
1633
|
"tr",
|
|
1057
1634
|
{
|
|
1058
1635
|
className: [
|
|
1059
1636
|
"hover:bg-surface-container-low transition-colors",
|
|
1060
|
-
e ? "bg-orange-50/40" : "",
|
|
1061
|
-
|
|
1637
|
+
e ? "bg-orange-50/40 dark:bg-zeo-orange/[0.12]" : "",
|
|
1638
|
+
n
|
|
1062
1639
|
].filter(Boolean).join(" "),
|
|
1063
1640
|
...a,
|
|
1064
|
-
children:
|
|
1641
|
+
children: r
|
|
1065
1642
|
}
|
|
1066
1643
|
);
|
|
1067
1644
|
}
|
|
1068
|
-
function
|
|
1645
|
+
function Ut({
|
|
1069
1646
|
sortable: e = !1,
|
|
1070
|
-
sorted:
|
|
1071
|
-
onSort:
|
|
1647
|
+
sorted: r = !1,
|
|
1648
|
+
onSort: n,
|
|
1072
1649
|
children: a,
|
|
1073
1650
|
className: o = "",
|
|
1074
1651
|
...s
|
|
1075
1652
|
}) {
|
|
1076
|
-
return /* @__PURE__ */
|
|
1653
|
+
return /* @__PURE__ */ t(
|
|
1077
1654
|
"th",
|
|
1078
1655
|
{
|
|
1079
1656
|
className: [
|
|
@@ -1081,91 +1658,91 @@ function lt({
|
|
|
1081
1658
|
e ? "cursor-pointer hover:text-on-surface select-none" : "",
|
|
1082
1659
|
o
|
|
1083
1660
|
].filter(Boolean).join(" "),
|
|
1084
|
-
onClick: e ?
|
|
1661
|
+
onClick: e ? n : void 0,
|
|
1085
1662
|
...s,
|
|
1086
|
-
children: /* @__PURE__ */
|
|
1663
|
+
children: /* @__PURE__ */ i("span", { className: "inline-flex items-center gap-1", children: [
|
|
1087
1664
|
a,
|
|
1088
|
-
e && /* @__PURE__ */
|
|
1665
|
+
e && /* @__PURE__ */ t(
|
|
1089
1666
|
"span",
|
|
1090
1667
|
{
|
|
1091
|
-
className: `material-symbols-outlined text-[14px] ${
|
|
1092
|
-
children:
|
|
1668
|
+
className: `material-symbols-outlined text-[14px] ${r ? "text-zeo-orange" : "opacity-40"}`,
|
|
1669
|
+
children: r === "asc" ? "arrow_upward" : r === "desc" ? "arrow_downward" : "unfold_more"
|
|
1093
1670
|
}
|
|
1094
1671
|
)
|
|
1095
1672
|
] })
|
|
1096
1673
|
}
|
|
1097
1674
|
);
|
|
1098
1675
|
}
|
|
1099
|
-
function
|
|
1100
|
-
return /* @__PURE__ */
|
|
1676
|
+
function Wt({ muted: e = !1, mono: r = !1, children: n, className: a = "", ...o }) {
|
|
1677
|
+
return /* @__PURE__ */ t(
|
|
1101
1678
|
"td",
|
|
1102
1679
|
{
|
|
1103
1680
|
className: [
|
|
1104
1681
|
"px-4 py-3",
|
|
1105
1682
|
e ? "text-on-surface-variant" : "text-on-surface",
|
|
1106
|
-
|
|
1683
|
+
r ? "font-mono text-xs" : "",
|
|
1107
1684
|
a
|
|
1108
1685
|
].filter(Boolean).join(" "),
|
|
1109
1686
|
...o,
|
|
1110
|
-
children:
|
|
1687
|
+
children: n
|
|
1111
1688
|
}
|
|
1112
1689
|
);
|
|
1113
1690
|
}
|
|
1114
|
-
const
|
|
1115
|
-
function
|
|
1116
|
-
const e =
|
|
1691
|
+
const le = G(null);
|
|
1692
|
+
function q() {
|
|
1693
|
+
const e = E(le);
|
|
1117
1694
|
if (!e) throw new Error("Tab must be used inside Tabs");
|
|
1118
1695
|
return e;
|
|
1119
1696
|
}
|
|
1120
|
-
const
|
|
1121
|
-
function
|
|
1122
|
-
return /* @__PURE__ */
|
|
1697
|
+
const ce = G({ stretch: !1 });
|
|
1698
|
+
function Gt({ value: e, onChange: r, variant: n = "default", children: a }) {
|
|
1699
|
+
return /* @__PURE__ */ t(le.Provider, { value: { active: e, onChange: r, variant: n }, children: /* @__PURE__ */ t("div", { className: n === "vertical" ? "flex gap-6" : "flex flex-col gap-4", children: a }) });
|
|
1123
1700
|
}
|
|
1124
|
-
function
|
|
1125
|
-
const { variant: o } =
|
|
1126
|
-
default:
|
|
1701
|
+
function Ot({ children: e, className: r = "", stretch: n = !1, ...a }) {
|
|
1702
|
+
const { variant: o } = q(), s = {
|
|
1703
|
+
default: n ? "flex gap-1 bg-surface-container-low rounded-lg p-1 w-full" : "flex gap-1 bg-surface-container-low rounded-lg p-1 w-fit",
|
|
1127
1704
|
underline: "flex gap-0 border-b border-surface-container-high w-full",
|
|
1128
1705
|
vertical: "flex flex-col gap-1 bg-surface-container-low rounded-lg p-1 w-48 shrink-0 h-fit"
|
|
1129
1706
|
}[o];
|
|
1130
|
-
return /* @__PURE__ */
|
|
1707
|
+
return /* @__PURE__ */ t(ce.Provider, { value: { stretch: n }, children: /* @__PURE__ */ t(
|
|
1131
1708
|
"div",
|
|
1132
1709
|
{
|
|
1133
1710
|
role: "tablist",
|
|
1134
|
-
className: [s,
|
|
1711
|
+
className: [s, r].filter(Boolean).join(" "),
|
|
1135
1712
|
...a,
|
|
1136
1713
|
children: e
|
|
1137
1714
|
}
|
|
1138
1715
|
) });
|
|
1139
1716
|
}
|
|
1140
|
-
function
|
|
1141
|
-
const { active: s, onChange:
|
|
1142
|
-
default:
|
|
1143
|
-
underline:
|
|
1144
|
-
vertical:
|
|
1717
|
+
function qt({ value: e, label: r, icon: n, badge: a, disabled: o = !1 }) {
|
|
1718
|
+
const { active: s, onChange: l, variant: c } = q(), { stretch: d } = E(ce), f = s === e, m = "inline-flex items-center gap-2 font-medium text-sm transition-all duration-200 select-none focus:outline-none", p = "opacity-40 cursor-not-allowed pointer-events-none", u = d && c !== "vertical" ? "flex-1 justify-center" : "", h = {
|
|
1719
|
+
default: f ? "bg-white dark:bg-chip text-on-surface shadow-sm rounded-md px-4 py-2" : "text-on-surface-variant hover:text-on-surface rounded-md px-4 py-2",
|
|
1720
|
+
underline: f ? "text-zeo-orange border-b-2 border-zeo-orange px-4 py-2.5 -mb-px" : "text-on-surface-variant hover:text-on-surface border-b-2 border-transparent px-4 py-2.5 -mb-px",
|
|
1721
|
+
vertical: f ? "bg-white dark:bg-chip text-on-surface shadow-sm rounded-md px-4 py-2 w-full" : "text-on-surface-variant hover:text-on-surface rounded-md px-4 py-2 w-full"
|
|
1145
1722
|
}[c];
|
|
1146
|
-
return /* @__PURE__ */
|
|
1723
|
+
return /* @__PURE__ */ i(
|
|
1147
1724
|
"button",
|
|
1148
1725
|
{
|
|
1149
1726
|
role: "tab",
|
|
1150
|
-
"aria-selected":
|
|
1727
|
+
"aria-selected": f,
|
|
1151
1728
|
"aria-disabled": o,
|
|
1152
1729
|
disabled: o,
|
|
1153
|
-
onClick: () => !o &&
|
|
1154
|
-
className: [
|
|
1730
|
+
onClick: () => !o && l(e),
|
|
1731
|
+
className: [m, h, u, o ? p : ""].filter(Boolean).join(" "),
|
|
1155
1732
|
children: [
|
|
1156
|
-
|
|
1733
|
+
n && /* @__PURE__ */ t(
|
|
1157
1734
|
"span",
|
|
1158
1735
|
{
|
|
1159
1736
|
className: "material-symbols-outlined text-[18px]",
|
|
1160
|
-
style:
|
|
1161
|
-
children:
|
|
1737
|
+
style: f ? { fontVariationSettings: "'FILL' 1" } : void 0,
|
|
1738
|
+
children: n
|
|
1162
1739
|
}
|
|
1163
1740
|
),
|
|
1164
|
-
|
|
1165
|
-
a !== void 0 && /* @__PURE__ */
|
|
1741
|
+
r,
|
|
1742
|
+
a !== void 0 && /* @__PURE__ */ t(
|
|
1166
1743
|
"span",
|
|
1167
1744
|
{
|
|
1168
|
-
className: `text-[11px] font-semibold px-1.5 py-0.5 rounded-full leading-none ${
|
|
1745
|
+
className: `text-[11px] font-semibold px-1.5 py-0.5 rounded-full leading-none ${f ? "bg-zeo-orange text-white" : "bg-surface-container-high text-on-surface-variant"}`,
|
|
1169
1746
|
children: a
|
|
1170
1747
|
}
|
|
1171
1748
|
)
|
|
@@ -1173,18 +1750,18 @@ function ut({ value: e, label: t, icon: r, badge: a, disabled: o = !1 }) {
|
|
|
1173
1750
|
}
|
|
1174
1751
|
);
|
|
1175
1752
|
}
|
|
1176
|
-
function
|
|
1177
|
-
const { active: o } =
|
|
1178
|
-
return o !== e ? null : /* @__PURE__ */
|
|
1753
|
+
function Zt({ value: e, children: r, className: n = "", stretch: a = !1 }) {
|
|
1754
|
+
const { active: o } = q();
|
|
1755
|
+
return o !== e ? null : /* @__PURE__ */ t(
|
|
1179
1756
|
"div",
|
|
1180
1757
|
{
|
|
1181
1758
|
role: "tabpanel",
|
|
1182
|
-
className: [a ? "flex-1" : "",
|
|
1183
|
-
children:
|
|
1759
|
+
className: [a ? "flex-1" : "", n].filter(Boolean).join(" "),
|
|
1760
|
+
children: r
|
|
1184
1761
|
}
|
|
1185
1762
|
);
|
|
1186
1763
|
}
|
|
1187
|
-
const
|
|
1764
|
+
const ot = {
|
|
1188
1765
|
top: {
|
|
1189
1766
|
wrapper: "bottom-full left-1/2 -translate-x-1/2 mb-2",
|
|
1190
1767
|
arrow: "top-full left-1/2 -translate-x-1/2 border-t-4 border-x-4 border-x-transparent border-b-0"
|
|
@@ -1201,22 +1778,22 @@ const Se = {
|
|
|
1201
1778
|
wrapper: "left-full top-1/2 -translate-y-1/2 ml-2",
|
|
1202
1779
|
arrow: "right-full top-1/2 -translate-y-1/2 border-r-4 border-y-4 border-y-transparent border-l-0"
|
|
1203
1780
|
}
|
|
1204
|
-
},
|
|
1205
|
-
dark: { tooltip: "bg-
|
|
1206
|
-
light: { tooltip: "bg-
|
|
1781
|
+
}, st = {
|
|
1782
|
+
dark: { tooltip: "bg-tooltip text-white", arrow: "border-t-tooltip border-r-tooltip border-b-tooltip border-l-tooltip" },
|
|
1783
|
+
light: { tooltip: "bg-surface-container-lowest text-on-surface border border-surface-container-high shadow-theme-lg", arrow: "border-t-surface-container-lowest border-r-surface-container-lowest border-b-surface-container-lowest border-l-surface-container-lowest" }
|
|
1207
1784
|
};
|
|
1208
|
-
function
|
|
1785
|
+
function Qt({
|
|
1209
1786
|
content: e,
|
|
1210
|
-
position:
|
|
1211
|
-
variant:
|
|
1787
|
+
position: r = "top",
|
|
1788
|
+
variant: n = "dark",
|
|
1212
1789
|
children: a,
|
|
1213
1790
|
className: o = "",
|
|
1214
1791
|
...s
|
|
1215
1792
|
}) {
|
|
1216
|
-
const
|
|
1217
|
-
return /* @__PURE__ */
|
|
1793
|
+
const l = ot[r], c = st[n];
|
|
1794
|
+
return /* @__PURE__ */ i("div", { className: ["relative inline-flex group", o].filter(Boolean).join(" "), ...s, children: [
|
|
1218
1795
|
a,
|
|
1219
|
-
/* @__PURE__ */
|
|
1796
|
+
/* @__PURE__ */ i(
|
|
1220
1797
|
"div",
|
|
1221
1798
|
{
|
|
1222
1799
|
role: "tooltip",
|
|
@@ -1224,50 +1801,77 @@ function mt({
|
|
|
1224
1801
|
"absolute z-50 pointer-events-none",
|
|
1225
1802
|
"opacity-0 group-hover:opacity-100 transition-opacity duration-150",
|
|
1226
1803
|
"whitespace-nowrap text-xs font-medium px-2.5 py-1.5 rounded-lg",
|
|
1227
|
-
|
|
1804
|
+
l.wrapper,
|
|
1228
1805
|
c.tooltip
|
|
1229
1806
|
].join(" "),
|
|
1230
1807
|
children: [
|
|
1231
1808
|
e,
|
|
1232
|
-
/* @__PURE__ */
|
|
1809
|
+
/* @__PURE__ */ t("span", { className: ["absolute w-0 h-0", l.arrow, c.arrow].join(" ") })
|
|
1233
1810
|
]
|
|
1234
1811
|
}
|
|
1235
1812
|
)
|
|
1236
1813
|
] });
|
|
1237
1814
|
}
|
|
1238
1815
|
export {
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1816
|
+
ut as Alert,
|
|
1817
|
+
zt as AppNavbar,
|
|
1818
|
+
Ct as AppShellLayout,
|
|
1819
|
+
Bt as AppSidebar,
|
|
1820
|
+
P as Avatar,
|
|
1821
|
+
ft as Badge,
|
|
1822
|
+
mt as Breadcrumb,
|
|
1823
|
+
Me as Button,
|
|
1824
|
+
pt as ButtonGroup,
|
|
1825
|
+
ht as Card,
|
|
1826
|
+
bt as CardFooter,
|
|
1827
|
+
xt as CardHeader,
|
|
1828
|
+
Re as Checkbox,
|
|
1829
|
+
gt as Dropdown,
|
|
1830
|
+
Et as HelpMenu,
|
|
1831
|
+
N as Icon,
|
|
1832
|
+
Ge as Input,
|
|
1833
|
+
St as MODULE_CATALOG,
|
|
1834
|
+
wt as Modal,
|
|
1835
|
+
yt as ModalBody,
|
|
1836
|
+
Nt as ModalFooter,
|
|
1837
|
+
vt as ModalHeader,
|
|
1838
|
+
se as NavbarIconButton,
|
|
1839
|
+
_t as NavbarSearch,
|
|
1840
|
+
Lt as NavbarTitle,
|
|
1841
|
+
Tt as NotificationsBell,
|
|
1842
|
+
kt as Pagination,
|
|
1843
|
+
Ke as PosteIcon,
|
|
1844
|
+
jt as ProgressBar,
|
|
1845
|
+
De as RadierIcon,
|
|
1846
|
+
Fe as Radio,
|
|
1847
|
+
Ae as Select,
|
|
1848
|
+
oe as SidebarItem,
|
|
1849
|
+
Je as SidebarSection,
|
|
1850
|
+
Ft as Spinner,
|
|
1851
|
+
Ve as Switch,
|
|
1852
|
+
W as THEME_ATTRIBUTE,
|
|
1853
|
+
Mt as THEME_INIT_SCRIPT,
|
|
1854
|
+
U as THEME_STORAGE_KEY,
|
|
1855
|
+
qt as Tab,
|
|
1856
|
+
Ot as TabList,
|
|
1857
|
+
Zt as TabPanel,
|
|
1858
|
+
Vt as Table,
|
|
1859
|
+
Ht as TableBody,
|
|
1860
|
+
Wt as TableCell,
|
|
1861
|
+
Dt as TableHead,
|
|
1862
|
+
Ut as TableHeaderCell,
|
|
1863
|
+
Kt as TableRow,
|
|
1864
|
+
Gt as Tabs,
|
|
1865
|
+
Ee as Textarea,
|
|
1866
|
+
It as ThemeProvider,
|
|
1867
|
+
Qt as Tooltip,
|
|
1868
|
+
He as TubulaoIcon,
|
|
1869
|
+
At as UserMenu,
|
|
1870
|
+
Pe as applyTheme,
|
|
1871
|
+
Xt as colorTokens,
|
|
1872
|
+
Xe as localStorageThemeStorage,
|
|
1873
|
+
Rt as resolveModuleAccess,
|
|
1874
|
+
Pt as shadowTokens,
|
|
1875
|
+
ie as useDismiss,
|
|
1876
|
+
$t as useTheme
|
|
1273
1877
|
};
|