xertica-ui 2.5.2 → 2.5.3

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.
@@ -0,0 +1,3305 @@
1
+ 'use strict';
2
+
3
+ const jsxRuntime = require('react/jsx-runtime');
4
+ const React = require('react');
5
+ const button = require('./button-0BlA47It.cjs');
6
+ const input = require('./input-ByYuOv8A.cjs');
7
+ const alertDialog = require('./alert-dialog-DhwPioBa.cjs');
8
+ const XerticaXLogo = require('./XerticaXLogo-qBPhwK3g.cjs');
9
+ const lucideReact = require('lucide-react');
10
+ const reactRouterDom = require('react-router-dom');
11
+ const sidebar = require('./sidebar-CQn_rwxP.cjs');
12
+ const skeleton = require('./skeleton-DjiHerJn.cjs');
13
+ const progress = require('./progress-Cqwxbqs1.cjs');
14
+ const LayoutContext = require('./LayoutContext-BEq_-n98.cjs');
15
+ const ThemeContext = require('./ThemeContext-CMD3z2Dz.cjs');
16
+ const reactQuery = require('@tanstack/react-query');
17
+ const reactI18next = require('react-i18next');
18
+ const FeatureCardSkeleton = require('./FeatureCardSkeleton-pTa0YNKP.cjs');
19
+ const xerticaAssistant = require('./xertica-assistant-BrF9jScR.cjs');
20
+ const i18n = require('i18next');
21
+ const richTextEditor = require('./rich-text-editor-DnSDglzW.cjs');
22
+ const select = require('./select-CH6v_KcQ.cjs');
23
+ const slider = require('./slider-B00b9SVK.cjs');
24
+ const sonner = require('sonner');
25
+ const zustand = require('zustand');
26
+
27
+ function ForgotPasswordPage() {
28
+ const navigate = reactRouterDom.useNavigate();
29
+ const [email, setEmail] = React.useState("");
30
+ const [isLoading, setIsLoading] = React.useState(false);
31
+ const handleSubmit = async (e) => {
32
+ e.preventDefault();
33
+ setIsLoading(true);
34
+ await new Promise((resolve) => setTimeout(resolve, 1500));
35
+ navigate("/verify-email", { state: { email } });
36
+ setIsLoading(false);
37
+ };
38
+ const handleSocialLogin = (_provider) => {
39
+ };
40
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-screen w-full flex overflow-y-auto", children: [
41
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "hidden lg:flex lg:flex-1 relative overflow-hidden", children: [
42
+ /* @__PURE__ */ jsxRuntime.jsx(
43
+ alertDialog.ImageWithFallback,
44
+ {
45
+ src: "https://images.unsplash.com/photo-1557804506-669a67965ba0?w=1200&h=800&fit=crop&auto=format",
46
+ alt: "Segurança e tecnologia",
47
+ className: "absolute inset-0 w-full h-full object-cover"
48
+ }
49
+ ),
50
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 bg-[image:var(--gradient-diagonal)] opacity-80" })
51
+ ] }),
52
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 flex items-center justify-center px-4 sm:px-6 lg:px-8 lg:flex-none lg:w-1/2 relative bg-muted", children: [
53
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute top-4 right-4 z-20", children: /* @__PURE__ */ jsxRuntime.jsx(XerticaXLogo.LanguageSelector, { variant: "minimal", showIcon: false }) }),
54
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 lg:hidden bg-[image:var(--gradient-diagonal)] opacity-10 dark:opacity-5" }),
55
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full max-w-sm space-y-6 relative z-10", children: [
56
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center", children: [
57
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center mb-4", children: /* @__PURE__ */ jsxRuntime.jsx(
58
+ XerticaXLogo.XerticaLogo,
59
+ {
60
+ className: "h-12 w-auto text-primary dark:text-foreground",
61
+ variant: "theme"
62
+ }
63
+ ) }),
64
+ /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-sm text-muted-foreground", children: "Recuperar senha" }),
65
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-2 text-muted-foreground", children: "Digite seu e-mail e enviaremos as instruções para redefinir sua senha" })
66
+ ] }),
67
+ /* @__PURE__ */ jsxRuntime.jsxs("form", { className: "space-y-6", onSubmit: handleSubmit, children: [
68
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "form-group space-y-2", children: [
69
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "email", className: "form-label", children: "E-mail" }),
70
+ /* @__PURE__ */ jsxRuntime.jsx(
71
+ input.Input,
72
+ {
73
+ id: "email",
74
+ name: "email",
75
+ type: "email",
76
+ required: true,
77
+ className: "w-full",
78
+ placeholder: "seu@email.com",
79
+ value: email,
80
+ onChange: (e) => setEmail(e.target.value)
81
+ }
82
+ )
83
+ ] }),
84
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
85
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { type: "submit", className: "w-full", disabled: isLoading, children: isLoading ? "Enviando..." : "Enviar instruções" }),
86
+ /* @__PURE__ */ jsxRuntime.jsxs(
87
+ button.Button,
88
+ {
89
+ type: "button",
90
+ onClick: () => navigate("/login"),
91
+ variant: "outline",
92
+ className: "w-full text-muted-foreground hover:text-foreground",
93
+ children: [
94
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowLeft, { className: "w-4 h-4 mr-2" }),
95
+ "Voltar para o login"
96
+ ]
97
+ }
98
+ )
99
+ ] })
100
+ ] }),
101
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
102
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 flex items-center", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full border-t border-border" }) }),
103
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative flex justify-center text-sm", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "bg-muted px-2 text-muted-foreground", children: "ou continue com" }) })
104
+ ] }),
105
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
106
+ /* @__PURE__ */ jsxRuntime.jsxs(
107
+ button.Button,
108
+ {
109
+ type: "button",
110
+ variant: "outline",
111
+ className: "w-full justify-center",
112
+ onClick: () => handleSocialLogin(),
113
+ children: [
114
+ /* @__PURE__ */ jsxRuntime.jsxs("svg", { className: "w-5 h-5 mr-2", viewBox: "0 0 48 48", xmlns: "http://www.w3.org/2000/svg", children: [
115
+ /* @__PURE__ */ jsxRuntime.jsx(
116
+ "path",
117
+ {
118
+ fill: "#EA4335",
119
+ d: "M24 9.5c3.54 0 6.71 1.22 9.21 3.6l6.85-6.85C35.9 2.38 30.47 0 24 0 14.62 0 6.51 5.38 2.56 13.22l7.98 6.19C12.43 13.72 17.74 9.5 24 9.5z"
120
+ }
121
+ ),
122
+ /* @__PURE__ */ jsxRuntime.jsx(
123
+ "path",
124
+ {
125
+ fill: "#4285F4",
126
+ d: "M46.98 24.55c0-1.57-.15-3.09-.38-4.55H24v9.02h12.94c-.58 2.96-2.26 5.48-4.78 7.18l7.73 6c4.51-4.18 7.09-10.36 7.09-17.65z"
127
+ }
128
+ ),
129
+ /* @__PURE__ */ jsxRuntime.jsx(
130
+ "path",
131
+ {
132
+ fill: "#FBBC05",
133
+ d: "M10.53 28.59c-.48-1.45-.76-2.99-.76-4.59s.27-3.14.76-4.59l-7.98-6.19C.92 16.46 0 20.12 0 24c0 3.88.92 7.54 2.56 10.78l7.97-6.19z"
134
+ }
135
+ ),
136
+ /* @__PURE__ */ jsxRuntime.jsx(
137
+ "path",
138
+ {
139
+ fill: "#34A853",
140
+ d: "M24 48c6.48 0 11.93-2.13 15.89-5.81l-7.73-6c-2.15 1.45-4.92 2.3-8.16 2.3-6.26 0-11.57-4.22-13.47-9.91l-7.98 6.19C6.51 42.62 14.62 48 24 48z"
141
+ }
142
+ ),
143
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "none", d: "M0 0h48v48H0z" })
144
+ ] }),
145
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Entrar com Google" })
146
+ ]
147
+ }
148
+ ),
149
+ /* @__PURE__ */ jsxRuntime.jsxs(
150
+ button.Button,
151
+ {
152
+ type: "button",
153
+ variant: "outline",
154
+ className: "w-full justify-center",
155
+ onClick: () => handleSocialLogin(),
156
+ children: [
157
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Lock, { className: "w-5 h-5 mr-2 text-[var(--chart-4)]" }),
158
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Entrar com MT Login" })
159
+ ]
160
+ }
161
+ ),
162
+ /* @__PURE__ */ jsxRuntime.jsx(
163
+ button.Button,
164
+ {
165
+ type: "button",
166
+ variant: "outline",
167
+ className: "w-full justify-center font-normal",
168
+ onClick: () => handleSocialLogin(),
169
+ children: /* @__PURE__ */ jsxRuntime.jsxs("span", { children: [
170
+ "Entrar com ",
171
+ /* @__PURE__ */ jsxRuntime.jsx("strong", { className: "font-semibold", children: "gov.br" })
172
+ ] })
173
+ }
174
+ )
175
+ ] })
176
+ ] })
177
+ ] })
178
+ ] });
179
+ }
180
+
181
+ const SIDEBAR_COLLAPSED_WIDTH = 80;
182
+
183
+ const t = (key, options) => i18n.t(key, options);
184
+ const MOCK_TEAM_MEMBERS = [
185
+ {
186
+ id: "1",
187
+ name: "Ana Silva",
188
+ email: "ana.silva@example.com",
189
+ role: "Developer",
190
+ status: "active"
191
+ },
192
+ {
193
+ id: "2",
194
+ name: "Bruno Costa",
195
+ email: "bruno.costa@example.com",
196
+ role: "Designer",
197
+ status: "active"
198
+ },
199
+ {
200
+ id: "3",
201
+ name: "Carla Oliveira",
202
+ email: "carla.oliveira@example.com",
203
+ role: "Manager",
204
+ status: "away"
205
+ },
206
+ {
207
+ id: "4",
208
+ name: "Diego Santos",
209
+ email: "diego.santos@example.com",
210
+ role: "Analyst",
211
+ status: "inactive"
212
+ }
213
+ ];
214
+ async function fetchTeamMembers() {
215
+ await new Promise((resolve) => setTimeout(resolve, 250));
216
+ return MOCK_TEAM_MEMBERS;
217
+ }
218
+ async function fetchFeatureCards() {
219
+ await new Promise((resolve) => setTimeout(resolve, 100));
220
+ return [
221
+ {
222
+ id: "template-cli",
223
+ title: t("home.templateCliTitle"),
224
+ description: t("home.templateCliDescription"),
225
+ badge: t("home.templateClibadge"),
226
+ href: "/template"
227
+ }
228
+ ];
229
+ }
230
+
231
+ function useTeamMembers() {
232
+ const { language } = ThemeContext.useLanguage();
233
+ return reactQuery.useQuery({
234
+ // Language is part of the key so each locale has its own cache slot.
235
+ queryKey: ["home", "team-members", language],
236
+ queryFn: fetchTeamMembers,
237
+ staleTime: 2 * 60 * 1e3
238
+ // 2 min
239
+ });
240
+ }
241
+
242
+ function useFeatureCards() {
243
+ const { language } = ThemeContext.useLanguage();
244
+ return reactQuery.useQuery({
245
+ // Language is part of the key so each locale has its own cache slot.
246
+ queryKey: ["home", "feature-cards", language],
247
+ queryFn: fetchFeatureCards,
248
+ staleTime: 10 * 60 * 1e3
249
+ // 10 min — feature list is fairly static
250
+ });
251
+ }
252
+
253
+ const useDashboardStore = zustand.create((set) => ({
254
+ // Filters
255
+ activeTab: "overview",
256
+ setActiveTab: (tab) => set({ activeTab: tab }),
257
+ // UI toggles
258
+ statsExpanded: true,
259
+ toggleStats: () => set((state) => ({ statsExpanded: !state.statsExpanded })),
260
+ // Showcase controls
261
+ progress: 45,
262
+ setProgress: (value) => set({ progress: value }),
263
+ sliderValue: [50],
264
+ setSliderValue: (value) => set({ sliderValue: value }),
265
+ switchEnabled: false,
266
+ toggleSwitch: () => set((state) => ({ switchEnabled: !state.switchEnabled }))
267
+ }));
268
+
269
+ function isDev() {
270
+ return false;
271
+ }
272
+ function SectionErrorFallback({ error, reset }) {
273
+ return /* @__PURE__ */ jsxRuntime.jsxs(
274
+ "div",
275
+ {
276
+ role: "alert",
277
+ className: "flex flex-col items-center justify-center gap-3 p-6 rounded-[var(--radius-lg)] border border-destructive/30 bg-destructive/5 text-center",
278
+ children: [
279
+ /* @__PURE__ */ jsxRuntime.jsxs(
280
+ "svg",
281
+ {
282
+ width: "24",
283
+ height: "24",
284
+ viewBox: "0 0 24 24",
285
+ fill: "none",
286
+ stroke: "currentColor",
287
+ strokeWidth: "2",
288
+ strokeLinecap: "round",
289
+ strokeLinejoin: "round",
290
+ className: "text-destructive shrink-0",
291
+ "aria-hidden": "true",
292
+ children: [
293
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: "12", cy: "12", r: "10" }),
294
+ /* @__PURE__ */ jsxRuntime.jsx("line", { x1: "12", y1: "8", x2: "12", y2: "12" }),
295
+ /* @__PURE__ */ jsxRuntime.jsx("line", { x1: "12", y1: "16", x2: "12.01", y2: "16" })
296
+ ]
297
+ }
298
+ ),
299
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
300
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium", children: "Não foi possível carregar este conteúdo" }),
301
+ isDev()
302
+ ] }),
303
+ /* @__PURE__ */ jsxRuntime.jsx(
304
+ "button",
305
+ {
306
+ onClick: reset,
307
+ className: "inline-flex items-center px-3 py-1.5 text-xs rounded-[var(--radius-button)] border border-border bg-background hover:bg-accent hover:text-accent-foreground transition-colors",
308
+ children: "Tentar novamente"
309
+ }
310
+ )
311
+ ]
312
+ }
313
+ );
314
+ }
315
+
316
+ class ErrorBoundary extends React.Component {
317
+ constructor(props) {
318
+ super(props);
319
+ this.state = { hasError: false, error: null };
320
+ this.reset = this.reset.bind(this);
321
+ }
322
+ static getDerivedStateFromError(error) {
323
+ return { hasError: true, error };
324
+ }
325
+ componentDidCatch(error, info) {
326
+ this.props.onError?.(error, info);
327
+ }
328
+ componentDidUpdate(prevProps) {
329
+ if (!this.state.hasError) return;
330
+ const { resetKeys } = this.props;
331
+ if (!resetKeys?.length) return;
332
+ const prevKeys = prevProps.resetKeys ?? [];
333
+ const changed = resetKeys.some((key, i) => key !== prevKeys[i]);
334
+ if (changed) this.reset();
335
+ }
336
+ reset() {
337
+ this.setState({ hasError: false, error: null });
338
+ }
339
+ render() {
340
+ const { hasError, error } = this.state;
341
+ const { children, fallback: Fallback } = this.props;
342
+ if (hasError && error) {
343
+ return /* @__PURE__ */ jsxRuntime.jsx(Fallback, { error, reset: this.reset });
344
+ }
345
+ return children;
346
+ }
347
+ }
348
+ function SectionErrorBoundary({ children, onError, resetKeys }) {
349
+ return /* @__PURE__ */ jsxRuntime.jsx(ErrorBoundary, { fallback: SectionErrorFallback, onError, resetKeys, children });
350
+ }
351
+
352
+ function HomeContent() {
353
+ const { t } = reactI18next.useTranslation();
354
+ const layout = LayoutContext.useOptionalLayout();
355
+ const sidebarExpanded = layout?.sidebarExpanded ?? false;
356
+ const sidebarWidth = layout?.sidebarWidth ?? 256;
357
+ const navigate = reactRouterDom.useNavigate();
358
+ const { data: featureCards = [], isLoading } = useFeatureCards();
359
+ return /* @__PURE__ */ jsxRuntime.jsxs(
360
+ "div",
361
+ {
362
+ style: {
363
+ paddingLeft: sidebarExpanded ? `${sidebarWidth}px` : SIDEBAR_COLLAPSED_WIDTH
364
+ },
365
+ className: "flex-1 flex flex-col overflow-hidden transition-all duration-300",
366
+ children: [
367
+ /* @__PURE__ */ jsxRuntime.jsx(
368
+ sidebar.Header,
369
+ {
370
+ showThemeToggle: true,
371
+ showLanguageSelector: true,
372
+ breadcrumbs: [{ label: t("nav.designSystem"), href: "/home" }, { label: t("nav.home") }],
373
+ renderLink: (href, props) => /* @__PURE__ */ jsxRuntime.jsx(reactRouterDom.Link, { to: href, ...props })
374
+ }
375
+ ),
376
+ /* @__PURE__ */ jsxRuntime.jsx("main", { className: "flex-1 overflow-hidden bg-muted", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-full", style: { overflowY: "auto", overflowX: "hidden" }, children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "p-5 sm:p-4 md:p-6", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "max-w-6xl mx-auto space-y-8", children: [
377
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.PageHeader, { title: t("home.welcome"), subtitle: t("home.subtitle") }),
378
+ /* @__PURE__ */ jsxRuntime.jsx(SectionErrorBoundary, { children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6", children: isLoading ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
379
+ /* @__PURE__ */ jsxRuntime.jsx(FeatureCardSkeleton.FeatureCardSkeleton, { showAction: true }),
380
+ /* @__PURE__ */ jsxRuntime.jsx(FeatureCardSkeleton.FeatureCardSkeleton, { showAction: true }),
381
+ /* @__PURE__ */ jsxRuntime.jsx(FeatureCardSkeleton.FeatureCardSkeleton, { showAction: true })
382
+ ] }) : featureCards.map((card) => /* @__PURE__ */ jsxRuntime.jsxs(
383
+ skeleton.Card,
384
+ {
385
+ className: "hover:shadow-xl transition-shadow duration-200 flex flex-col h-full",
386
+ children: [
387
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3", children: [
388
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "p-2 bg-[var(--chart-2)]/20 rounded-[var(--radius)]", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.FileText, { className: "w-6 h-6 text-[var(--chart-2)]" }) }),
389
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
390
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { className: "text-sm", children: t(`home.${card.id.replace(/-/g, "")}Title`, {
391
+ defaultValue: card.title
392
+ }) }),
393
+ card.badge && /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "default", className: "text-xs", children: t(`home.${card.id.replace(/-/g, "")}badge`, {
394
+ defaultValue: card.badge
395
+ }) })
396
+ ] })
397
+ ] }) }),
398
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { className: "flex-1", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: t(`home.${card.id.replace(/-/g, "")}Description`, {
399
+ defaultValue: card.description
400
+ }) }) }),
401
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardFooter, { children: /* @__PURE__ */ jsxRuntime.jsx(
402
+ button.Button,
403
+ {
404
+ variant: "outline",
405
+ className: "w-full",
406
+ onClick: () => navigate(card.href),
407
+ children: t("common.view")
408
+ }
409
+ ) })
410
+ ]
411
+ },
412
+ card.id
413
+ )) }) })
414
+ ] }) }) }) })
415
+ ]
416
+ }
417
+ );
418
+ }
419
+
420
+ const routes = [
421
+ { path: "/home", label: "Home", icon: lucideReact.Home },
422
+ { path: "/template", label: "Template", icon: lucideReact.FileText }
423
+ ];
424
+
425
+ const AuthContext = React.createContext(null);
426
+ function useAuth() {
427
+ const ctx = React.useContext(AuthContext);
428
+ if (!ctx) throw new Error("useAuth must be used within <AuthProvider>");
429
+ return ctx;
430
+ }
431
+
432
+ async function fetchAssistantConfig() {
433
+ await new Promise((resolve) => setTimeout(resolve, 150));
434
+ const t = (key) => i18n.t(key);
435
+ return {
436
+ suggestions: [
437
+ { id: "1", text: t("assistant.suggestions.whatCanIAsk") },
438
+ { id: "2", text: t("assistant.suggestions.whatDoYouDo") },
439
+ { id: "3", text: t("assistant.suggestions.whichProjects") },
440
+ { id: "4", text: t("assistant.suggestions.nextProject") }
441
+ ],
442
+ richSuggestions: [
443
+ { id: "rich-1", text: t("assistant.richSuggestions.viewPerformance") },
444
+ { id: "rich-2", text: t("assistant.richSuggestions.generateReport") },
445
+ { id: "rich-3", text: t("assistant.richSuggestions.createDocument") },
446
+ { id: "rich-4", text: t("assistant.richSuggestions.generatePodcast") }
447
+ ],
448
+ feedbackOptions: [
449
+ t("assistant.feedback.notWhatIWanted"),
450
+ t("assistant.feedback.incorrectInfo"),
451
+ t("assistant.feedback.incompleteAnswer")
452
+ ]
453
+ };
454
+ }
455
+ function getMockRichSuggestions() {
456
+ return [
457
+ { id: "rich-1", text: i18n.t("assistant.richSuggestions.viewPerformance") },
458
+ { id: "rich-2", text: i18n.t("assistant.richSuggestions.generateReport") },
459
+ { id: "rich-3", text: i18n.t("assistant.richSuggestions.createDocument") },
460
+ { id: "rich-4", text: i18n.t("assistant.richSuggestions.generatePodcast") }
461
+ ];
462
+ }
463
+ function getMockFeedbackOptions() {
464
+ return [
465
+ i18n.t("assistant.feedback.notWhatIWanted"),
466
+ i18n.t("assistant.feedback.incorrectInfo"),
467
+ i18n.t("assistant.feedback.incompleteAnswer")
468
+ ];
469
+ }
470
+
471
+ function useAssistantConfig() {
472
+ const { language } = ThemeContext.useLanguage();
473
+ return reactQuery.useQuery({
474
+ // Language is part of the key so each locale has its own cache slot.
475
+ queryKey: ["assistant", "config", language],
476
+ queryFn: fetchAssistantConfig,
477
+ staleTime: 30 * 60 * 1e3
478
+ // 30 min — config rarely changes
479
+ });
480
+ }
481
+
482
+ function HomePage() {
483
+ const { user, logout } = useAuth();
484
+ const layout = LayoutContext.useOptionalLayout();
485
+ const [localSidebarExpanded, setLocalSidebarExpanded] = React.useState(false);
486
+ const [localAssistantExpanded, setLocalAssistantExpanded] = React.useState(false);
487
+ const sidebarExpanded = layout?.sidebarExpanded ?? localSidebarExpanded;
488
+ const sidebarWidth = layout?.sidebarWidth ?? 280;
489
+ const assistenteExpanded = layout?.assistenteExpanded ?? localAssistantExpanded;
490
+ const toggleSidebar = layout?.toggleSidebar ?? (() => setLocalSidebarExpanded((value) => !value));
491
+ const toggleAssistente = layout?.toggleAssistente ?? (() => setLocalAssistantExpanded((value) => !value));
492
+ const location = reactRouterDom.useLocation();
493
+ const navigate = reactRouterDom.useNavigate();
494
+ const { data: assistantConfig } = useAssistantConfig();
495
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-screen flex bg-muted overflow-hidden relative", children: [
496
+ /* @__PURE__ */ jsxRuntime.jsx(
497
+ sidebar.Sidebar,
498
+ {
499
+ expanded: sidebarExpanded,
500
+ width: sidebarWidth,
501
+ onToggle: toggleSidebar,
502
+ user: {
503
+ ...user,
504
+ name: "Ariel Santos",
505
+ avatar: "https://github.com/shadcn.png"
506
+ },
507
+ onLogout: logout,
508
+ onSettingsClick: () => navigate("/settings"),
509
+ location,
510
+ navigate,
511
+ routes
512
+ }
513
+ ),
514
+ /* @__PURE__ */ jsxRuntime.jsx(HomeContent, {}),
515
+ /* @__PURE__ */ jsxRuntime.jsx(
516
+ xerticaAssistant.XerticaAssistant,
517
+ {
518
+ isExpanded: assistenteExpanded,
519
+ onToggle: toggleAssistente,
520
+ defaultTab: "chat",
521
+ demoMode: true,
522
+ responseGenerator: xerticaAssistant.gerarResposta,
523
+ suggestions: assistantConfig?.suggestions,
524
+ richSuggestions: assistantConfig?.richSuggestions ?? getMockRichSuggestions(),
525
+ feedbackOptions: assistantConfig?.feedbackOptions ?? getMockFeedbackOptions(),
526
+ onEvaluation: () => {
527
+ }
528
+ }
529
+ )
530
+ ] });
531
+ }
532
+
533
+ function LoginPage({ onLogin }) {
534
+ const navigate = reactRouterDom.useNavigate();
535
+ const { t } = reactI18next.useTranslation();
536
+ const [email, setEmail] = React.useState("");
537
+ const [password, setPassword] = React.useState("");
538
+ const [isLoading, setIsLoading] = React.useState(false);
539
+ const [error, setError] = React.useState("");
540
+ const handleSubmit = async (e) => {
541
+ e.preventDefault();
542
+ setError("");
543
+ setIsLoading(true);
544
+ await new Promise((resolve) => setTimeout(resolve, 1e3));
545
+ const success = onLogin(email, password);
546
+ if (!success) {
547
+ setError(t("login.errorFillFields"));
548
+ }
549
+ setIsLoading(false);
550
+ };
551
+ const handleSocialLogin = (_provider) => {
552
+ onLogin("social@user.com", "social-auth");
553
+ };
554
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-screen w-full flex overflow-y-auto", children: [
555
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "hidden lg:flex lg:flex-1 relative overflow-hidden", children: [
556
+ /* @__PURE__ */ jsxRuntime.jsx(
557
+ alertDialog.ImageWithFallback,
558
+ {
559
+ src: "https://images.unsplash.com/photo-1551434678-e076c223a692?w=1200&h=800&fit=crop&auto=format",
560
+ alt: t("login.heroImageAlt"),
561
+ className: "absolute inset-0 w-full h-full object-cover"
562
+ }
563
+ ),
564
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 bg-[image:var(--gradient-diagonal)] opacity-80" })
565
+ ] }),
566
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 flex items-center justify-center px-4 sm:px-6 lg:px-8 lg:flex-none lg:w-1/2 relative bg-muted", children: [
567
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute top-4 right-4 z-20", children: /* @__PURE__ */ jsxRuntime.jsx(XerticaXLogo.LanguageSelector, { variant: "minimal", showIcon: false }) }),
568
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 lg:hidden bg-[image:var(--gradient-diagonal)] opacity-10 dark:opacity-5" }),
569
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full max-w-sm space-y-6 relative z-10", children: [
570
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center", children: [
571
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center mb-4", children: /* @__PURE__ */ jsxRuntime.jsx(
572
+ XerticaXLogo.XerticaLogo,
573
+ {
574
+ className: "h-12 w-auto text-primary dark:text-foreground",
575
+ variant: "theme"
576
+ }
577
+ ) }),
578
+ /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-sm text-muted-foreground", children: t("login.heading") })
579
+ ] }),
580
+ /* @__PURE__ */ jsxRuntime.jsxs("form", { className: "space-y-6", onSubmit: handleSubmit, children: [
581
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
582
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "email", children: t("login.emailLabel") }),
583
+ /* @__PURE__ */ jsxRuntime.jsx(
584
+ input.Input,
585
+ {
586
+ id: "email",
587
+ name: "email",
588
+ type: "email",
589
+ required: true,
590
+ className: "w-full",
591
+ placeholder: t("login.emailPlaceholder"),
592
+ value: email,
593
+ onChange: (e) => setEmail(e.target.value)
594
+ }
595
+ )
596
+ ] }),
597
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
598
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "password", children: t("login.passwordLabel") }),
599
+ /* @__PURE__ */ jsxRuntime.jsx(
600
+ input.Input,
601
+ {
602
+ id: "password",
603
+ name: "password",
604
+ type: "password",
605
+ required: true,
606
+ className: "w-full",
607
+ placeholder: "••••••••",
608
+ value: password,
609
+ onChange: (e) => setPassword(e.target.value)
610
+ }
611
+ )
612
+ ] }),
613
+ error && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-destructive text-sm text-center", children: error }),
614
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { type: "submit", className: "w-full", disabled: isLoading, children: isLoading ? t("login.submitting") : t("login.submit") }),
615
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-center", children: /* @__PURE__ */ jsxRuntime.jsx(
616
+ "button",
617
+ {
618
+ type: "button",
619
+ onClick: () => navigate("/forgot-password"),
620
+ className: "text-sm text-primary hover:opacity-80 transition-colors",
621
+ children: t("login.forgotPassword")
622
+ }
623
+ ) })
624
+ ] }),
625
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
626
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 flex items-center", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full border-t border-border" }) }),
627
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative flex justify-center text-sm", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "bg-muted px-2 text-muted-foreground", children: t("login.orContinueWith") }) })
628
+ ] }),
629
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
630
+ /* @__PURE__ */ jsxRuntime.jsxs(
631
+ button.Button,
632
+ {
633
+ type: "button",
634
+ variant: "outline",
635
+ className: "w-full justify-center",
636
+ onClick: () => handleSocialLogin(),
637
+ children: [
638
+ /* @__PURE__ */ jsxRuntime.jsxs("svg", { className: "w-5 h-5 mr-2", viewBox: "0 0 48 48", xmlns: "http://www.w3.org/2000/svg", children: [
639
+ /* @__PURE__ */ jsxRuntime.jsx(
640
+ "path",
641
+ {
642
+ fill: "#EA4335",
643
+ d: "M24 9.5c3.54 0 6.71 1.22 9.21 3.6l6.85-6.85C35.9 2.38 30.47 0 24 0 14.62 0 6.51 5.38 2.56 13.22l7.98 6.19C12.43 13.72 17.74 9.5 24 9.5z"
644
+ }
645
+ ),
646
+ /* @__PURE__ */ jsxRuntime.jsx(
647
+ "path",
648
+ {
649
+ fill: "#4285F4",
650
+ d: "M46.98 24.55c0-1.57-.15-3.09-.38-4.55H24v9.02h12.94c-.58 2.96-2.26 5.48-4.78 7.18l7.73 6c4.51-4.18 7.09-10.36 7.09-17.65z"
651
+ }
652
+ ),
653
+ /* @__PURE__ */ jsxRuntime.jsx(
654
+ "path",
655
+ {
656
+ fill: "#FBBC05",
657
+ d: "M10.53 28.59c-.48-1.45-.76-2.99-.76-4.59s.27-3.14.76-4.59l-7.98-6.19C.92 16.46 0 20.12 0 24c0 3.88.92 7.54 2.56 10.78l7.97-6.19z"
658
+ }
659
+ ),
660
+ /* @__PURE__ */ jsxRuntime.jsx(
661
+ "path",
662
+ {
663
+ fill: "#34A853",
664
+ d: "M24 48c6.48 0 11.93-2.13 15.89-5.81l-7.73-6c-2.15 1.45-4.92 2.3-8.16 2.3-6.26 0-11.57-4.22-13.47-9.91l-7.98 6.19C6.51 42.62 14.62 48 24 48z"
665
+ }
666
+ ),
667
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "none", d: "M0 0h48v48H0z" })
668
+ ] }),
669
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: t("login.signInWithGoogle") })
670
+ ]
671
+ }
672
+ ),
673
+ /* @__PURE__ */ jsxRuntime.jsxs(
674
+ button.Button,
675
+ {
676
+ type: "button",
677
+ variant: "outline",
678
+ className: "w-full justify-center",
679
+ onClick: () => handleSocialLogin(),
680
+ children: [
681
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Lock, { className: "w-5 h-5 mr-2 text-[var(--chart-4)]" }),
682
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: t("login.signInWithMTLogin") })
683
+ ]
684
+ }
685
+ ),
686
+ /* @__PURE__ */ jsxRuntime.jsx(
687
+ button.Button,
688
+ {
689
+ type: "button",
690
+ variant: "outline",
691
+ className: "w-full justify-center font-normal",
692
+ onClick: () => handleSocialLogin(),
693
+ children: /* @__PURE__ */ jsxRuntime.jsx("span", { children: t("login.signInWithGovBr") })
694
+ }
695
+ )
696
+ ] })
697
+ ] })
698
+ ] })
699
+ ] });
700
+ }
701
+
702
+ function ResetPasswordPage() {
703
+ const navigate = reactRouterDom.useNavigate();
704
+ const { t } = reactI18next.useTranslation();
705
+ const [password, setPassword] = React.useState("");
706
+ const [confirmPassword, setConfirmPassword] = React.useState("");
707
+ const [isLoading, setIsLoading] = React.useState(false);
708
+ const [error, setError] = React.useState("");
709
+ const [passwordStrength, setPasswordStrength] = React.useState(
710
+ null
711
+ );
712
+ const checkPasswordStrength = (pwd) => {
713
+ if (pwd.length === 0) {
714
+ setPasswordStrength(null);
715
+ return;
716
+ }
717
+ if (pwd.length < 6) {
718
+ setPasswordStrength("weak");
719
+ } else if (pwd.length < 10) {
720
+ setPasswordStrength("medium");
721
+ } else {
722
+ setPasswordStrength("strong");
723
+ }
724
+ };
725
+ const handlePasswordChange = (value) => {
726
+ setPassword(value);
727
+ checkPasswordStrength(value);
728
+ setError("");
729
+ };
730
+ const handleSubmit = async (e) => {
731
+ e.preventDefault();
732
+ setError("");
733
+ if (password.length < 6) {
734
+ setError(t("resetPassword.errorMinLength"));
735
+ return;
736
+ }
737
+ if (password !== confirmPassword) {
738
+ setError(t("resetPassword.errorMismatch"));
739
+ return;
740
+ }
741
+ setIsLoading(true);
742
+ await new Promise((resolve) => setTimeout(resolve, 1500));
743
+ navigate("/login", { state: { resetSuccess: true } });
744
+ setIsLoading(false);
745
+ };
746
+ const getStrengthColor = () => {
747
+ switch (passwordStrength) {
748
+ case "weak":
749
+ return "text-destructive";
750
+ case "medium":
751
+ return "text-[var(--chart-3)]";
752
+ case "strong":
753
+ return "text-[var(--chart-2)]";
754
+ default:
755
+ return "text-muted-foreground";
756
+ }
757
+ };
758
+ const getStrengthText = () => {
759
+ switch (passwordStrength) {
760
+ case "weak":
761
+ return t("resetPassword.strengthWeak");
762
+ case "medium":
763
+ return t("resetPassword.strengthMedium");
764
+ case "strong":
765
+ return t("resetPassword.strengthStrong");
766
+ default:
767
+ return "";
768
+ }
769
+ };
770
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-screen w-full flex overflow-y-auto", children: [
771
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "hidden lg:flex lg:flex-1 relative overflow-hidden", children: [
772
+ /* @__PURE__ */ jsxRuntime.jsx(
773
+ alertDialog.ImageWithFallback,
774
+ {
775
+ src: "https://images.unsplash.com/photo-1555949963-aa79dcee981c?w=1200&h=800&fit=crop&auto=format",
776
+ alt: t("resetPassword.heroImageAlt"),
777
+ className: "absolute inset-0 w-full h-full object-cover"
778
+ }
779
+ ),
780
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 bg-[image:var(--gradient-diagonal)] opacity-80" })
781
+ ] }),
782
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 flex items-center justify-center px-4 sm:px-6 lg:px-8 lg:flex-none lg:w-1/2 relative bg-muted", children: [
783
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute top-4 right-4 z-20", children: /* @__PURE__ */ jsxRuntime.jsx(XerticaXLogo.LanguageSelector, { variant: "minimal", showIcon: false }) }),
784
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 lg:hidden bg-[image:var(--gradient-diagonal)] opacity-10 dark:opacity-5" }),
785
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full max-w-sm space-y-6 relative z-10", children: [
786
+ /* @__PURE__ */ jsxRuntime.jsxs(
787
+ "button",
788
+ {
789
+ onClick: () => navigate("/login"),
790
+ className: "flex items-center gap-2 text-muted-foreground hover:text-foreground transition-colors",
791
+ children: [
792
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowLeft, { className: "w-4 h-4" }),
793
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-small", children: t("resetPassword.backToLogin") })
794
+ ]
795
+ }
796
+ ),
797
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center", children: [
798
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center mb-4", children: /* @__PURE__ */ jsxRuntime.jsx(
799
+ XerticaXLogo.XerticaLogo,
800
+ {
801
+ className: "h-12 w-auto text-primary dark:text-foreground",
802
+ variant: "theme"
803
+ }
804
+ ) }),
805
+ /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-sm text-muted-foreground", children: t("resetPassword.heading") }),
806
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-2 text-muted-foreground", children: t("resetPassword.subheading") })
807
+ ] }),
808
+ /* @__PURE__ */ jsxRuntime.jsxs("form", { className: "space-y-6", onSubmit: handleSubmit, children: [
809
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
810
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "password", children: t("resetPassword.newPasswordLabel") }),
811
+ /* @__PURE__ */ jsxRuntime.jsx(
812
+ input.Input,
813
+ {
814
+ id: "password",
815
+ name: "password",
816
+ type: "password",
817
+ required: true,
818
+ className: "w-full",
819
+ placeholder: "••••••••",
820
+ value: password,
821
+ onChange: (e) => handlePasswordChange(e.target.value)
822
+ }
823
+ ),
824
+ passwordStrength && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
825
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 h-1 bg-muted rounded-full overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsx(
826
+ "div",
827
+ {
828
+ className: `h-full transition-all duration-300 ${passwordStrength === "weak" ? "w-1/3 bg-destructive" : passwordStrength === "medium" ? "w-2/3 bg-[var(--chart-3)]" : "w-full bg-[var(--chart-2)]"}`
829
+ }
830
+ ) }),
831
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: `text-small ${getStrengthColor()}`, children: getStrengthText() })
832
+ ] })
833
+ ] }),
834
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
835
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "confirmPassword", children: t("resetPassword.confirmPasswordLabel") }),
836
+ /* @__PURE__ */ jsxRuntime.jsx(
837
+ input.Input,
838
+ {
839
+ id: "confirmPassword",
840
+ name: "confirmPassword",
841
+ type: "password",
842
+ required: true,
843
+ className: "w-full",
844
+ placeholder: "••••••••",
845
+ value: confirmPassword,
846
+ onChange: (e) => {
847
+ setConfirmPassword(e.target.value);
848
+ setError("");
849
+ }
850
+ }
851
+ )
852
+ ] }),
853
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-accent rounded-[var(--radius)] p-4 space-y-2", children: [
854
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm", children: t("resetPassword.requirements") }),
855
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
856
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
857
+ /* @__PURE__ */ jsxRuntime.jsx(
858
+ lucideReact.CheckCircle2,
859
+ {
860
+ className: `w-4 h-4 ${password.length >= 6 ? "text-[var(--chart-2)]" : "text-muted-foreground"}`
861
+ }
862
+ ),
863
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-muted-foreground", children: t("resetPassword.requirementMinChars") })
864
+ ] }),
865
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
866
+ /* @__PURE__ */ jsxRuntime.jsx(
867
+ lucideReact.CheckCircle2,
868
+ {
869
+ className: `w-4 h-4 ${password === confirmPassword && password.length > 0 ? "text-[var(--chart-2)]" : "text-muted-foreground"}`
870
+ }
871
+ ),
872
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-muted-foreground", children: t("resetPassword.requirementMatch") })
873
+ ] })
874
+ ] })
875
+ ] }),
876
+ error && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 text-destructive bg-destructive/10 rounded-[var(--radius)] p-3", children: [
877
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.AlertCircle, { className: "w-4 h-4 flex-shrink-0" }),
878
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: error })
879
+ ] }),
880
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { type: "submit", className: "w-full", disabled: isLoading, children: isLoading ? t("resetPassword.submitting") : t("resetPassword.submit") })
881
+ ] })
882
+ ] })
883
+ ] })
884
+ ] });
885
+ }
886
+
887
+ function createLucideIconSvg(iconName) {
888
+ const iconPaths = {
889
+ utensils: '<path d="M3 2v7c0 1.1.9 2 2 2h4a2 2 0 0 0 2-2V2"></path><path d="M7 2v20"></path><path d="M21 15V2v0a5 5 0 0 0-5 5v6c0 1.1.9 2 2 2h3Zm0 0v7"></path>',
890
+ hotel: '<path d="M18 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2Z"></path><path d="M8 6h8"></path><path d="M8 10h8"></path><path d="M8 14h8"></path><path d="M8 18h8"></path>',
891
+ landmark: '<path d="m3 21 18-18"></path><path d="M9 15V6h6v9"></path><path d="M12 3v3"></path><path d="M3 15h18"></path><path d="M6 21v-6"></path><path d="M18 21v-6"></path>',
892
+ shopping: '<path d="M6 2 3 6v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6l-3-4Z"></path><path d="M3 6h18"></path><path d="M16 10a4 4 0 0 1-8 0"></path>',
893
+ coffee: '<path d="M17 8h1a4 4 0 1 1 0 8h-1"></path><path d="M3 8h14v9a4 4 0 0 1-4 4H7a4 4 0 0 1-4-4Z"></path><line x1="6" x2="6" y1="2" y2="4"></line><line x1="10" x2="10" y1="2" y2="4"></line><line x1="14" x2="14" y1="2" y2="4"></line>'
894
+ };
895
+ const path = iconPaths[iconName] || "";
896
+ return `<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round">${path}</svg>`;
897
+ }
898
+ const markerGroups = {
899
+ restaurant: {
900
+ id: "restaurant",
901
+ name: "Restaurantes",
902
+ color: "var(--destructive)",
903
+ // red
904
+ iconColor: "#FFFFFF",
905
+ // white para contraste
906
+ iconName: "utensils",
907
+ icon: lucideReact.Utensils
908
+ },
909
+ hotel: {
910
+ id: "hotel",
911
+ name: "Hotéis",
912
+ color: "var(--info)",
913
+ // blue
914
+ iconColor: "#FFFFFF",
915
+ iconName: "hotel",
916
+ icon: lucideReact.Hotel
917
+ },
918
+ landmark: {
919
+ id: "landmark",
920
+ name: "Pontos Turísticos",
921
+ color: "var(--success)",
922
+ // green
923
+ iconColor: "#FFFFFF",
924
+ iconName: "landmark",
925
+ icon: lucideReact.Landmark
926
+ },
927
+ shopping: {
928
+ id: "shopping",
929
+ name: "Compras",
930
+ color: "var(--warning)",
931
+ // orange
932
+ iconColor: "#FFFFFF",
933
+ iconName: "shopping",
934
+ icon: lucideReact.ShoppingBag
935
+ },
936
+ cafe: {
937
+ id: "cafe",
938
+ name: "Cafeterias",
939
+ color: "var(--primary)",
940
+ // purple
941
+ iconColor: "#FFFFFF",
942
+ iconName: "coffee",
943
+ icon: lucideReact.Coffee
944
+ }
945
+ };
946
+ const sampleLocations = [
947
+ // Restaurantes
948
+ {
949
+ position: { lat: -23.5505, lng: -46.6333 },
950
+ title: "Restaurante Italiano",
951
+ info: "Melhor pizza da cidade",
952
+ group: "restaurant"
953
+ },
954
+ {
955
+ position: { lat: -23.5485, lng: -46.635 },
956
+ title: "Sushi Bar",
957
+ info: "Comida japonesa autêntica",
958
+ group: "restaurant"
959
+ },
960
+ {
961
+ position: { lat: -23.552, lng: -46.631 },
962
+ title: "Churrascaria Premium",
963
+ info: "Rodízio tradicional brasileiro",
964
+ group: "restaurant"
965
+ },
966
+ // Hotéis
967
+ {
968
+ position: { lat: -23.5475, lng: -46.6361 },
969
+ title: "Hotel Luxo",
970
+ info: "5 estrelas - Vista panorâmica",
971
+ group: "hotel"
972
+ },
973
+ {
974
+ position: { lat: -23.553, lng: -46.634 },
975
+ title: "Hotel Boutique",
976
+ info: "Design moderno e aconchegante",
977
+ group: "hotel"
978
+ },
979
+ // Pontos Turísticos
980
+ {
981
+ position: { lat: -23.5613, lng: -46.6563 },
982
+ title: "Parque Ibirapuera",
983
+ info: "Maior parque urbano da cidade",
984
+ group: "landmark"
985
+ },
986
+ {
987
+ position: { lat: -23.5558, lng: -46.6396 },
988
+ title: "MASP",
989
+ info: "Museu de Arte de São Paulo",
990
+ group: "landmark"
991
+ },
992
+ {
993
+ position: { lat: -23.5489, lng: -46.6388 },
994
+ title: "Avenida Paulista",
995
+ info: "Centro financeiro e cultural",
996
+ group: "landmark"
997
+ },
998
+ // Shopping
999
+ {
1000
+ position: { lat: -23.5465, lng: -46.64 },
1001
+ title: "Shopping Center",
1002
+ info: "Mais de 300 lojas",
1003
+ group: "shopping"
1004
+ },
1005
+ {
1006
+ position: { lat: -23.554, lng: -46.638 },
1007
+ title: "Galeria de Arte",
1008
+ info: "Arte contemporânea e design",
1009
+ group: "shopping"
1010
+ },
1011
+ // Cafeterias
1012
+ {
1013
+ position: { lat: -23.5495, lng: -46.6345 },
1014
+ title: "Café Artesanal",
1015
+ info: "Café especial e brunch",
1016
+ group: "cafe"
1017
+ },
1018
+ {
1019
+ position: { lat: -23.551, lng: -46.637 },
1020
+ title: "Coffee House",
1021
+ info: "Café gourmet e wi-fi",
1022
+ group: "cafe"
1023
+ },
1024
+ {
1025
+ position: { lat: -23.5525, lng: -46.6355 },
1026
+ title: "Café Cultural",
1027
+ info: "Livros e café",
1028
+ group: "cafe"
1029
+ }
1030
+ ];
1031
+ function FilterableMapExample({ apiKey }) {
1032
+ const [activeFilters, setActiveFilters] = React.useState(
1033
+ new Set(Object.keys(markerGroups))
1034
+ );
1035
+ const [showFilters, setShowFilters] = React.useState(true);
1036
+ const filteredLocations = React.useMemo(() => {
1037
+ return sampleLocations.filter((location) => activeFilters.has(location.group));
1038
+ }, [activeFilters]);
1039
+ const toggleFilter = (groupId) => {
1040
+ setActiveFilters((prev) => {
1041
+ const newFilters = new Set(prev);
1042
+ if (newFilters.has(groupId)) {
1043
+ newFilters.delete(groupId);
1044
+ } else {
1045
+ newFilters.add(groupId);
1046
+ }
1047
+ return newFilters;
1048
+ });
1049
+ };
1050
+ const toggleAll = () => {
1051
+ if (activeFilters.size === Object.keys(markerGroups).length) {
1052
+ setActiveFilters(/* @__PURE__ */ new Set());
1053
+ } else {
1054
+ setActiveFilters(new Set(Object.keys(markerGroups)));
1055
+ }
1056
+ };
1057
+ const markersWithCustomization = filteredLocations.map((location) => ({
1058
+ ...location,
1059
+ customColor: markerGroups[location.group].color,
1060
+ iconSvg: createLucideIconSvg(markerGroups[location.group].iconName),
1061
+ iconColor: markerGroups[location.group].iconColor
1062
+ }));
1063
+ const getGroupCount = (groupId) => {
1064
+ return sampleLocations.filter((loc) => loc.group === groupId).length;
1065
+ };
1066
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4", children: [
1067
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
1068
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
1069
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.MapPin, { className: "w-5 h-5 text-primary" }),
1070
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { children: "Filtro por Categorias" })
1071
+ ] }),
1072
+ /* @__PURE__ */ jsxRuntime.jsxs(progress.Badge, { variant: "secondary", children: [
1073
+ filteredLocations.length,
1074
+ " de ",
1075
+ sampleLocations.length,
1076
+ " locais"
1077
+ ] })
1078
+ ] }),
1079
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: "Use os filtros compactos no canto superior esquerdo do mapa para visualizar marcadores por categoria" }),
1080
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
1081
+ /* @__PURE__ */ jsxRuntime.jsx(
1082
+ alertDialog.Map,
1083
+ {
1084
+ center: { lat: -23.5505, lng: -46.6333 },
1085
+ zoom: 14,
1086
+ markers: markersWithCustomization,
1087
+ height: "500px",
1088
+ zoomControl: true,
1089
+ fullscreenControl: true,
1090
+ apiKey
1091
+ }
1092
+ ),
1093
+ /* @__PURE__ */ jsxRuntime.jsx(
1094
+ "div",
1095
+ {
1096
+ className: button.cn(
1097
+ "absolute top-4 left-4 z-10 transition-all duration-300",
1098
+ showFilters ? "translate-x-0" : "-translate-x-full"
1099
+ ),
1100
+ children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-2.5 rounded-lg shadow-[var(--shadow-elevation-sm)] bg-card border border-border max-w-[220px]", children: [
1101
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between mb-2 gap-2", children: [
1102
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-1.5", children: [
1103
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Filter, { className: "w-3.5 h-3.5 text-foreground" }),
1104
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-foreground", children: "Filtros" })
1105
+ ] }),
1106
+ /* @__PURE__ */ jsxRuntime.jsx(
1107
+ button.Button,
1108
+ {
1109
+ size: "sm",
1110
+ variant: "ghost",
1111
+ onClick: () => setShowFilters(false),
1112
+ className: "h-5 w-5 p-0",
1113
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "w-3 h-3" })
1114
+ }
1115
+ )
1116
+ ] }),
1117
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1.5", children: [
1118
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2 py-0.5", children: [
1119
+ /* @__PURE__ */ jsxRuntime.jsx(
1120
+ alertDialog.Checkbox,
1121
+ {
1122
+ id: "filter-all",
1123
+ checked: activeFilters.size === Object.keys(markerGroups).length,
1124
+ onCheckedChange: toggleAll
1125
+ }
1126
+ ),
1127
+ /* @__PURE__ */ jsxRuntime.jsxs(
1128
+ alertDialog.Label,
1129
+ {
1130
+ htmlFor: "filter-all",
1131
+ className: "flex items-center gap-1.5 cursor-pointer text-sm",
1132
+ children: [
1133
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.MapPin, { className: "w-3.5 h-3.5" }),
1134
+ "Todos",
1135
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "secondary", className: "text-xs h-4 px-1", children: sampleLocations.length })
1136
+ ]
1137
+ }
1138
+ )
1139
+ ] }),
1140
+ Object.entries(markerGroups).map(([id, group]) => {
1141
+ const groupId = id;
1142
+ const Icon = group.icon;
1143
+ const isActive = activeFilters.has(groupId);
1144
+ const count = getGroupCount(groupId);
1145
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2 py-0.5", children: [
1146
+ /* @__PURE__ */ jsxRuntime.jsx(
1147
+ alertDialog.Checkbox,
1148
+ {
1149
+ id: `filter-${id}`,
1150
+ checked: isActive,
1151
+ onCheckedChange: () => toggleFilter(groupId)
1152
+ }
1153
+ ),
1154
+ /* @__PURE__ */ jsxRuntime.jsxs(
1155
+ alertDialog.Label,
1156
+ {
1157
+ htmlFor: `filter-${id}`,
1158
+ className: "flex items-center gap-1.5 cursor-pointer text-sm",
1159
+ children: [
1160
+ /* @__PURE__ */ jsxRuntime.jsx(Icon, { className: "w-3.5 h-3.5", style: { color: group.color } }),
1161
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: isActive ? "text-foreground" : "text-muted-foreground", children: group.name }),
1162
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "outline", className: "text-xs h-4 px-1", children: count })
1163
+ ]
1164
+ }
1165
+ )
1166
+ ] }, id);
1167
+ })
1168
+ ] })
1169
+ ] })
1170
+ }
1171
+ ),
1172
+ !showFilters && /* @__PURE__ */ jsxRuntime.jsxs(
1173
+ button.Button,
1174
+ {
1175
+ size: "sm",
1176
+ onClick: () => setShowFilters(true),
1177
+ className: "absolute top-4 left-4 z-10 h-8 bg-primary text-primary-foreground",
1178
+ children: [
1179
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Filter, { className: "w-3.5 h-3.5 mr-1.5" }),
1180
+ "Filtros"
1181
+ ]
1182
+ }
1183
+ )
1184
+ ] }),
1185
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap gap-3 justify-center pt-2 border-t border-border", children: Object.entries(markerGroups).map(([id, group]) => {
1186
+ const Icon = group.icon;
1187
+ const count = getGroupCount(id);
1188
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 px-3 py-1 rounded-lg bg-muted", children: [
1189
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-3 h-3 rounded-full", style: { backgroundColor: group.color } }),
1190
+ /* @__PURE__ */ jsxRuntime.jsx(Icon, { className: "w-4 h-4", style: { color: group.color } }),
1191
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", style: { color: "var(--foreground)" }, children: group.name }),
1192
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "secondary", className: "text-xs h-5", children: count })
1193
+ ] }, id);
1194
+ }) }),
1195
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 md:grid-cols-4 gap-3", children: [
1196
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center p-3 rounded-lg bg-muted", children: [
1197
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: "Total de Locais" }),
1198
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-2xl text-foreground", children: sampleLocations.length })
1199
+ ] }),
1200
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center p-3 rounded-lg bg-muted", children: [
1201
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: "Visíveis" }),
1202
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-2xl text-primary", children: filteredLocations.length })
1203
+ ] }),
1204
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center p-3 rounded-lg bg-muted", children: [
1205
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: "Categorias" }),
1206
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-2xl text-foreground", children: Object.keys(markerGroups).length })
1207
+ ] }),
1208
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center p-3 rounded-lg bg-muted", children: [
1209
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: "Filtros Ativos" }),
1210
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-2xl text-chart-2", children: activeFilters.size })
1211
+ ] })
1212
+ ] })
1213
+ ] });
1214
+ }
1215
+
1216
+ function DrawingMapExample({ apiKey }) {
1217
+ const [mapInstance, setMapInstance] = React.useState(null);
1218
+ const [selectedMode, setSelectedMode] = React.useState(null);
1219
+ const [shapes, setShapes] = React.useState([]);
1220
+ const [showSaveDialog, setShowSaveDialog] = React.useState(false);
1221
+ const [savedData, setSavedData] = React.useState("");
1222
+ const [isDrawingPolygon, setIsDrawingPolygon] = React.useState(false);
1223
+ const tempPolylineRef = React.useRef(null);
1224
+ const polygonPathRef = React.useRef([]);
1225
+ const mapListenersRef = React.useRef([]);
1226
+ const colors = {
1227
+ fill: "#2C275B",
1228
+ // Primary do CSS
1229
+ stroke: "#2C275B",
1230
+ fillOpacity: 0.2,
1231
+ strokeWeight: 2,
1232
+ editable: true,
1233
+ draggable: true
1234
+ };
1235
+ const addMarker = React.useCallback(
1236
+ (position) => {
1237
+ if (!mapInstance) return;
1238
+ const marker = new google.maps.marker.AdvancedMarkerElement({
1239
+ position,
1240
+ map: mapInstance,
1241
+ gmpDraggable: true,
1242
+ // Propriedade correta para AdvancedMarkerElement
1243
+ title: "Marcador"
1244
+ });
1245
+ marker.addListener("dragend", () => {
1246
+ sonner.toast.info("Posição do marcador atualizada");
1247
+ });
1248
+ const newShape = { type: "marker", overlay: marker };
1249
+ setShapes((prev) => [...prev, newShape]);
1250
+ sonner.toast.success("Marcador adicionado");
1251
+ },
1252
+ [mapInstance]
1253
+ );
1254
+ const addCircle = React.useCallback(
1255
+ (center) => {
1256
+ if (!mapInstance) return;
1257
+ const circle = new google.maps.Circle({
1258
+ map: mapInstance,
1259
+ center,
1260
+ radius: 500,
1261
+ fillColor: colors.fill,
1262
+ fillOpacity: colors.fillOpacity,
1263
+ strokeColor: colors.stroke,
1264
+ strokeWeight: colors.strokeWeight,
1265
+ editable: true,
1266
+ draggable: true
1267
+ });
1268
+ const newShape = { type: "circle", overlay: circle };
1269
+ setShapes((prev) => [...prev, newShape]);
1270
+ sonner.toast.success("Círculo adicionado");
1271
+ },
1272
+ [mapInstance, colors]
1273
+ );
1274
+ const addRectangle = React.useCallback(
1275
+ (center) => {
1276
+ if (!mapInstance) return;
1277
+ const offset = 5e-3;
1278
+ const bounds = {
1279
+ north: center.lat() + offset,
1280
+ south: center.lat() - offset,
1281
+ east: center.lng() + offset,
1282
+ west: center.lng() - offset
1283
+ };
1284
+ const rectangle = new google.maps.Rectangle({
1285
+ map: mapInstance,
1286
+ bounds,
1287
+ fillColor: colors.fill,
1288
+ fillOpacity: colors.fillOpacity,
1289
+ strokeColor: colors.stroke,
1290
+ strokeWeight: colors.strokeWeight,
1291
+ editable: true,
1292
+ draggable: true
1293
+ });
1294
+ const newShape = { type: "rectangle", overlay: rectangle };
1295
+ setShapes((prev) => [...prev, newShape]);
1296
+ sonner.toast.success("Retângulo adicionado");
1297
+ },
1298
+ [mapInstance, colors]
1299
+ );
1300
+ const cancelPolygonDrawing = React.useCallback(() => {
1301
+ if (tempPolylineRef.current) {
1302
+ tempPolylineRef.current.setMap(null);
1303
+ tempPolylineRef.current = null;
1304
+ }
1305
+ polygonPathRef.current = [];
1306
+ setIsDrawingPolygon(false);
1307
+ }, []);
1308
+ const finishPolygon = React.useCallback(() => {
1309
+ if (!mapInstance || polygonPathRef.current.length < 3) {
1310
+ if (polygonPathRef.current.length < 3 && polygonPathRef.current.length > 0) {
1311
+ sonner.toast.error("Polígono precisa de pelo menos 3 pontos.");
1312
+ }
1313
+ return;
1314
+ }
1315
+ const polygon = new google.maps.Polygon({
1316
+ map: mapInstance,
1317
+ paths: polygonPathRef.current,
1318
+ fillColor: colors.fill,
1319
+ fillOpacity: colors.fillOpacity,
1320
+ strokeColor: colors.stroke,
1321
+ strokeWeight: colors.strokeWeight,
1322
+ editable: true,
1323
+ draggable: true
1324
+ });
1325
+ const newShape = { type: "polygon", overlay: polygon };
1326
+ setShapes((prev) => [...prev, newShape]);
1327
+ cancelPolygonDrawing();
1328
+ sonner.toast.success("Polígono criado com sucesso!");
1329
+ }, [mapInstance, colors, cancelPolygonDrawing]);
1330
+ const addPolygonPoint = React.useCallback(
1331
+ (point) => {
1332
+ if (!mapInstance) return;
1333
+ if (!isDrawingPolygon) {
1334
+ setIsDrawingPolygon(true);
1335
+ polygonPathRef.current = [point];
1336
+ tempPolylineRef.current = new google.maps.Polyline({
1337
+ map: mapInstance,
1338
+ path: polygonPathRef.current,
1339
+ strokeColor: colors.stroke,
1340
+ strokeOpacity: 0.8,
1341
+ strokeWeight: 2,
1342
+ geodesic: true,
1343
+ clickable: false
1344
+ // Importante: não capturar cliques para não atrapalhar o mapa
1345
+ });
1346
+ sonner.toast.info("Clique para adicionar pontos. Duplo clique ou botão check para fechar.", {
1347
+ duration: 4e3
1348
+ });
1349
+ } else {
1350
+ polygonPathRef.current.push(point);
1351
+ tempPolylineRef.current?.setPath(polygonPathRef.current);
1352
+ }
1353
+ },
1354
+ [mapInstance, isDrawingPolygon, colors]
1355
+ );
1356
+ const clearListeners = () => {
1357
+ mapListenersRef.current.forEach((listener) => google.maps.event.removeListener(listener));
1358
+ mapListenersRef.current = [];
1359
+ };
1360
+ React.useEffect(() => {
1361
+ if (!mapInstance) return;
1362
+ clearListeners();
1363
+ if (!selectedMode) {
1364
+ mapInstance.setOptions({ draggableCursor: "grab", clickableIcons: true });
1365
+ return;
1366
+ }
1367
+ mapInstance.setOptions({
1368
+ draggableCursor: "crosshair",
1369
+ clickableIcons: false
1370
+ });
1371
+ const clickListener = mapInstance.addListener("click", (e) => {
1372
+ if (!e.latLng) return;
1373
+ switch (selectedMode) {
1374
+ case "marker":
1375
+ addMarker(e.latLng);
1376
+ break;
1377
+ case "circle":
1378
+ addCircle(e.latLng);
1379
+ break;
1380
+ case "rectangle":
1381
+ addRectangle(e.latLng);
1382
+ break;
1383
+ case "polygon":
1384
+ addPolygonPoint(e.latLng);
1385
+ break;
1386
+ }
1387
+ });
1388
+ mapListenersRef.current.push(clickListener);
1389
+ if (selectedMode === "polygon") {
1390
+ const dblClickListener = mapInstance.addListener("dblclick", (e) => {
1391
+ if (e.domEvent) e.domEvent.stopPropagation();
1392
+ finishPolygon();
1393
+ });
1394
+ mapListenersRef.current.push(dblClickListener);
1395
+ }
1396
+ return () => {
1397
+ clearListeners();
1398
+ };
1399
+ }, [
1400
+ mapInstance,
1401
+ selectedMode,
1402
+ addMarker,
1403
+ addCircle,
1404
+ addRectangle,
1405
+ addPolygonPoint,
1406
+ finishPolygon
1407
+ ]);
1408
+ const handleModeChange = (mode) => {
1409
+ if (isDrawingPolygon) {
1410
+ cancelPolygonDrawing();
1411
+ }
1412
+ setSelectedMode(mode);
1413
+ };
1414
+ const clearAll = () => {
1415
+ shapes.forEach((shape) => {
1416
+ if ("setMap" in shape.overlay) shape.overlay.setMap(null);
1417
+ else shape.overlay.map = null;
1418
+ });
1419
+ setShapes([]);
1420
+ if (isDrawingPolygon) cancelPolygonDrawing();
1421
+ sonner.toast.info("Mapa limpo");
1422
+ };
1423
+ const undoLast = () => {
1424
+ if (isDrawingPolygon) {
1425
+ if (polygonPathRef.current.length > 0) {
1426
+ polygonPathRef.current.pop();
1427
+ tempPolylineRef.current?.setPath(polygonPathRef.current);
1428
+ if (polygonPathRef.current.length === 0) {
1429
+ cancelPolygonDrawing();
1430
+ }
1431
+ }
1432
+ return;
1433
+ }
1434
+ if (shapes.length === 0) return;
1435
+ const lastShape = shapes[shapes.length - 1];
1436
+ if ("setMap" in lastShape.overlay) lastShape.overlay.setMap(null);
1437
+ else lastShape.overlay.map = null;
1438
+ setShapes((prev) => prev.slice(0, prev.length - 1));
1439
+ };
1440
+ const handleSave = () => {
1441
+ if (shapes.length === 0) {
1442
+ sonner.toast.error("Adicione desenhos ao mapa antes de salvar.");
1443
+ return;
1444
+ }
1445
+ const exportData = shapes.map((s) => {
1446
+ let data = {};
1447
+ if (s.type === "marker") {
1448
+ const marker = s.overlay;
1449
+ const pos = marker.position;
1450
+ if (pos) {
1451
+ const lat = typeof pos.lat === "function" ? pos.lat() : pos.lat;
1452
+ const lng = typeof pos.lng === "function" ? pos.lng() : pos.lng;
1453
+ data = { lat, lng };
1454
+ }
1455
+ } else if (s.type === "circle") {
1456
+ const circle = s.overlay;
1457
+ data = {
1458
+ center: { lat: circle.getCenter()?.lat(), lng: circle.getCenter()?.lng() },
1459
+ radius: circle.getRadius()
1460
+ };
1461
+ } else if (s.type === "rectangle") {
1462
+ const rect = s.overlay;
1463
+ const bounds = rect.getBounds();
1464
+ data = {
1465
+ north: bounds?.getNorthEast().lat(),
1466
+ south: bounds?.getSouthWest().lat(),
1467
+ east: bounds?.getNorthEast().lng(),
1468
+ west: bounds?.getSouthWest().lng()
1469
+ };
1470
+ } else if (s.type === "polygon") {
1471
+ const poly = s.overlay;
1472
+ const path = poly.getPath();
1473
+ data = path.getArray().map((coord) => ({ lat: coord.lat(), lng: coord.lng() }));
1474
+ }
1475
+ return { type: s.type, data };
1476
+ });
1477
+ setSavedData(JSON.stringify(exportData, null, 2));
1478
+ setShowSaveDialog(true);
1479
+ };
1480
+ const ToolButton = ({
1481
+ active,
1482
+ onClick,
1483
+ icon: Icon,
1484
+ label
1485
+ }) => /* @__PURE__ */ jsxRuntime.jsxs(
1486
+ button.Button,
1487
+ {
1488
+ variant: active ? "default" : "ghost",
1489
+ className: `w-full justify-start gap-3 ${active ? "bg-primary text-primary-foreground" : "text-muted-foreground hover:text-foreground"}`,
1490
+ onClick,
1491
+ children: [
1492
+ /* @__PURE__ */ jsxRuntime.jsx(Icon, { className: "h-4 w-4" }),
1493
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm font-medium", children: label })
1494
+ ]
1495
+ }
1496
+ );
1497
+ return /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { className: "h-full border-0 shadow-none md:border md:shadow-sm", children: [
1498
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardHeader, { className: "border-b bg-muted/20 pb-4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
1499
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
1500
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: "Ferramentas de Desenho" }),
1501
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { className: "mt-1", children: "Crie geometrias personalizadas no mapa" })
1502
+ ] }),
1503
+ /* @__PURE__ */ jsxRuntime.jsxs(progress.Badge, { variant: "outline", className: "h-6", children: [
1504
+ shapes.length,
1505
+ " ",
1506
+ shapes.length === 1 ? "elemento" : "elementos"
1507
+ ] })
1508
+ ] }) }),
1509
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { className: "p-0 flex flex-col md:flex-row h-[600px] bg-background", children: [
1510
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full md:w-64 border-b md:border-b-0 md:border-r bg-muted/10 flex flex-col", children: [
1511
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.ScrollArea, { className: "flex-1", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-4 space-y-6", children: [
1512
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
1513
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "text-xs font-semibold text-muted-foreground uppercase tracking-wider px-2", children: "Ferramentas" }),
1514
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
1515
+ /* @__PURE__ */ jsxRuntime.jsx(
1516
+ ToolButton,
1517
+ {
1518
+ active: selectedMode === null,
1519
+ onClick: () => handleModeChange(null),
1520
+ icon: lucideReact.MousePointer2,
1521
+ label: "Navegar"
1522
+ }
1523
+ ),
1524
+ /* @__PURE__ */ jsxRuntime.jsx(
1525
+ ToolButton,
1526
+ {
1527
+ active: selectedMode === "marker",
1528
+ onClick: () => handleModeChange("marker"),
1529
+ icon: lucideReact.MapPin,
1530
+ label: "Marcador"
1531
+ }
1532
+ ),
1533
+ /* @__PURE__ */ jsxRuntime.jsx(
1534
+ ToolButton,
1535
+ {
1536
+ active: selectedMode === "circle",
1537
+ onClick: () => handleModeChange("circle"),
1538
+ icon: lucideReact.Circle,
1539
+ label: "Círculo"
1540
+ }
1541
+ ),
1542
+ /* @__PURE__ */ jsxRuntime.jsx(
1543
+ ToolButton,
1544
+ {
1545
+ active: selectedMode === "rectangle",
1546
+ onClick: () => handleModeChange("rectangle"),
1547
+ icon: lucideReact.Square,
1548
+ label: "Retângulo"
1549
+ }
1550
+ ),
1551
+ /* @__PURE__ */ jsxRuntime.jsx(
1552
+ ToolButton,
1553
+ {
1554
+ active: selectedMode === "polygon",
1555
+ onClick: () => handleModeChange("polygon"),
1556
+ icon: lucideReact.Hexagon,
1557
+ label: "Polígono"
1558
+ }
1559
+ )
1560
+ ] })
1561
+ ] }),
1562
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
1563
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
1564
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "text-xs font-semibold text-muted-foreground uppercase tracking-wider px-2", children: "Ações" }),
1565
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-2", children: [
1566
+ /* @__PURE__ */ jsxRuntime.jsxs(
1567
+ button.Button,
1568
+ {
1569
+ variant: "outline",
1570
+ onClick: undoLast,
1571
+ disabled: shapes.length === 0 && !isDrawingPolygon,
1572
+ className: "w-full",
1573
+ title: "Desfazer último",
1574
+ "aria-label": "Desfazer último",
1575
+ children: [
1576
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Undo, { className: "h-4 w-4 mr-2" }),
1577
+ "Desfazer"
1578
+ ]
1579
+ }
1580
+ ),
1581
+ /* @__PURE__ */ jsxRuntime.jsxs(
1582
+ button.Button,
1583
+ {
1584
+ variant: "destructive",
1585
+ onClick: clearAll,
1586
+ disabled: shapes.length === 0 && !isDrawingPolygon,
1587
+ className: "w-full bg-destructive/10 text-destructive hover:bg-destructive hover:text-destructive-foreground border-0 shadow-none",
1588
+ children: [
1589
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Trash2, { className: "h-4 w-4 mr-2" }),
1590
+ "Limpar"
1591
+ ]
1592
+ }
1593
+ )
1594
+ ] }),
1595
+ /* @__PURE__ */ jsxRuntime.jsxs(
1596
+ button.Button,
1597
+ {
1598
+ variant: "default",
1599
+ onClick: handleSave,
1600
+ disabled: shapes.length === 0,
1601
+ className: "w-full mt-2",
1602
+ children: [
1603
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Save, { className: "h-4 w-4 mr-2" }),
1604
+ "Salvar GeoJSON"
1605
+ ]
1606
+ }
1607
+ )
1608
+ ] })
1609
+ ] }) }),
1610
+ isDrawingPolygon && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-4 bg-primary/5 border-t border-primary/10", children: [
1611
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 mb-2 text-primary text-xs font-medium", children: [
1612
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "relative flex h-2 w-2", children: [
1613
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "animate-ping absolute inline-flex h-full w-full rounded-full bg-primary opacity-75" }),
1614
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "relative inline-flex rounded-full h-2 w-2 bg-primary" })
1615
+ ] }),
1616
+ "Desenhando Polígono..."
1617
+ ] }),
1618
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-2", children: [
1619
+ /* @__PURE__ */ jsxRuntime.jsxs(
1620
+ button.Button,
1621
+ {
1622
+ size: "sm",
1623
+ className: "w-full bg-green-600 hover:bg-green-700 text-white",
1624
+ onClick: finishPolygon,
1625
+ children: [
1626
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Check, { className: "h-3 w-3 mr-1" }),
1627
+ " Concluir"
1628
+ ]
1629
+ }
1630
+ ),
1631
+ /* @__PURE__ */ jsxRuntime.jsxs(
1632
+ button.Button,
1633
+ {
1634
+ size: "sm",
1635
+ variant: "outline",
1636
+ className: "w-full",
1637
+ onClick: cancelPolygonDrawing,
1638
+ children: [
1639
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "h-3 w-3 mr-1" }),
1640
+ " Cancelar"
1641
+ ]
1642
+ }
1643
+ )
1644
+ ] })
1645
+ ] })
1646
+ ] }),
1647
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 relative bg-muted/5 min-h-[400px]", children: [
1648
+ /* @__PURE__ */ jsxRuntime.jsx(
1649
+ alertDialog.Map,
1650
+ {
1651
+ className: "h-full w-full rounded-none md:rounded-br-lg",
1652
+ center: { lat: -23.5505, lng: -46.6333 },
1653
+ zoom: 13,
1654
+ height: "100%",
1655
+ mapContainerClassName: "h-full w-full rounded-none md:rounded-br-lg",
1656
+ disableDefaultUI: true,
1657
+ zoomControl: true,
1658
+ onMapLoad: setMapInstance,
1659
+ apiKey
1660
+ }
1661
+ ),
1662
+ selectedMode && !isDrawingPolygon && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "absolute bottom-6 left-1/2 -translate-x-1/2 bg-background/90 backdrop-blur border px-4 py-2 rounded-full shadow-sm text-xs font-medium text-muted-foreground pointer-events-none z-10", children: [
1663
+ selectedMode === "marker" && "Clique no mapa para adicionar um marcador",
1664
+ selectedMode === "circle" && "Clique no mapa para definir o centro do círculo",
1665
+ selectedMode === "rectangle" && "Clique no mapa para criar um retângulo",
1666
+ selectedMode === "polygon" && "Clique sequencialmente para desenhar a área"
1667
+ ] })
1668
+ ] }),
1669
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.Dialog, { open: showSaveDialog, onOpenChange: setShowSaveDialog, children: /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.DialogContent, { className: "max-w-md", children: [
1670
+ /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.DialogHeader, { children: [
1671
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.DialogTitle, { children: "Dados Geográficos (GeoJSON)" }),
1672
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.DialogDescription, { children: "Copie os dados das formas desenhadas abaixo." })
1673
+ ] }),
1674
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative mt-2", children: /* @__PURE__ */ jsxRuntime.jsx(
1675
+ "pre",
1676
+ {
1677
+ className: "p-4 rounded-lg bg-muted overflow-auto max-h-[300px] text-xs font-mono",
1678
+ "data-custom-scrollbar": true,
1679
+ children: savedData
1680
+ }
1681
+ ) }),
1682
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-end mt-4", children: /* @__PURE__ */ jsxRuntime.jsx(button.Button, { onClick: () => setShowSaveDialog(false), children: "Fechar" }) })
1683
+ ] }) })
1684
+ ] })
1685
+ ] });
1686
+ }
1687
+
1688
+ function MapShowcase() {
1689
+ const [activeTab, setActiveTab] = React.useState("simple");
1690
+ const [isTransitioning, setIsTransitioning] = React.useState(false);
1691
+ const [apiKey, setApiKey] = React.useState("");
1692
+ const [inputApiKey, setInputApiKey] = React.useState("");
1693
+ const [showTraffic, setShowTraffic] = React.useState(false);
1694
+ const [showTransit, setShowTransit] = React.useState(false);
1695
+ const [showBicycling, setShowBicycling] = React.useState(false);
1696
+ const [showZoomControl, setShowZoomControl] = React.useState(true);
1697
+ const [showMapTypeControl, setShowMapTypeControl] = React.useState(false);
1698
+ const [showStreetViewControl, setShowStreetViewControl] = React.useState(false);
1699
+ const [showFullscreenControl, setShowFullscreenControl] = React.useState(true);
1700
+ const handleTabChange = (value) => {
1701
+ if (value === activeTab) return;
1702
+ setIsTransitioning(true);
1703
+ setTimeout(() => {
1704
+ setActiveTab(value);
1705
+ setIsTransitioning(false);
1706
+ }, 50);
1707
+ };
1708
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-8", children: [
1709
+ /* @__PURE__ */ jsxRuntime.jsx(
1710
+ alertDialog.PageHeader,
1711
+ {
1712
+ title: "Mapas",
1713
+ subtitle: "Biblioteca de componentes de mapa para visualização de dados geoespaciais. Utiliza a API do Google Maps com estilização personalizada do Xertica UI.",
1714
+ actions: /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { children: "Design System" })
1715
+ }
1716
+ ),
1717
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1718
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
1719
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: "Configuração da API Key" }),
1720
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: "Insira sua Google Maps API Key para renderizar os mapas abaixo." })
1721
+ ] }),
1722
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex w-full max-w-md items-center space-x-2", children: [
1723
+ /* @__PURE__ */ jsxRuntime.jsx(
1724
+ input.Input,
1725
+ {
1726
+ type: "password",
1727
+ placeholder: "Cole sua Google Maps API Key aqui",
1728
+ "aria-label": "Google Maps API Key",
1729
+ value: inputApiKey,
1730
+ onChange: (e) => setInputApiKey(e.target.value),
1731
+ className: "max-w-md h-10"
1732
+ }
1733
+ ),
1734
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { onClick: () => setApiKey(inputApiKey), children: "Salvar" })
1735
+ ] }) })
1736
+ ] }),
1737
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.Tabs, { value: activeTab, onValueChange: handleTabChange, className: "w-full", children: [
1738
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.TabsList, { className: "grid w-full grid-cols-4 mb-8", children: [
1739
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsTrigger, { value: "simple", children: "Mapas Simples" }),
1740
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsTrigger, { value: "markers", children: "Marcadores" }),
1741
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsTrigger, { value: "controls", children: "Controles" }),
1742
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.TabsTrigger, { value: "drawing", className: "flex items-center gap-2", children: [
1743
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Pencil, { className: "w-3 h-3" }),
1744
+ " Desenho"
1745
+ ] })
1746
+ ] }),
1747
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsContent, { value: "simple", className: "space-y-8", children: !isTransitioning && activeTab === "simple" && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
1748
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1749
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
1750
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: "Mapa Padrão" }),
1751
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: "Configuração básica do mapa centralizado em uma coordenada específica." })
1752
+ ] }),
1753
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(
1754
+ alertDialog.Map,
1755
+ {
1756
+ center: { lat: -23.5505, lng: -46.6333 },
1757
+ zoom: 13,
1758
+ height: "400px",
1759
+ apiKey
1760
+ }
1761
+ ) })
1762
+ ] }),
1763
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1764
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
1765
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: "Camadas (Layers)" }),
1766
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: "Sobreposição de informações como tráfego, transporte público e ciclovias." })
1767
+ ] }),
1768
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { className: "space-y-4", children: [
1769
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap gap-6 p-4 border rounded-lg bg-muted/50", children: [
1770
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
1771
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Switch, { id: "traffic", checked: showTraffic, onCheckedChange: setShowTraffic }),
1772
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.Label, { htmlFor: "traffic", className: "flex items-center gap-2", children: [
1773
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Layers, { className: "w-4 h-4" }),
1774
+ " Trânsito"
1775
+ ] })
1776
+ ] }),
1777
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
1778
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Switch, { id: "transit", checked: showTransit, onCheckedChange: setShowTransit }),
1779
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.Label, { htmlFor: "transit", className: "flex items-center gap-2", children: [
1780
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Layers, { className: "w-4 h-4" }),
1781
+ " Transporte"
1782
+ ] })
1783
+ ] }),
1784
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
1785
+ /* @__PURE__ */ jsxRuntime.jsx(
1786
+ alertDialog.Switch,
1787
+ {
1788
+ id: "bicycling",
1789
+ checked: showBicycling,
1790
+ onCheckedChange: setShowBicycling
1791
+ }
1792
+ ),
1793
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.Label, { htmlFor: "bicycling", className: "flex items-center gap-2", children: [
1794
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Layers, { className: "w-4 h-4" }),
1795
+ " Ciclovias"
1796
+ ] })
1797
+ ] })
1798
+ ] }),
1799
+ /* @__PURE__ */ jsxRuntime.jsx(
1800
+ alertDialog.Map,
1801
+ {
1802
+ center: { lat: -23.5505, lng: -46.6333 },
1803
+ zoom: 12,
1804
+ height: "500px",
1805
+ layers: {
1806
+ traffic: showTraffic,
1807
+ transit: showTransit,
1808
+ bicycling: showBicycling
1809
+ },
1810
+ apiKey
1811
+ }
1812
+ )
1813
+ ] })
1814
+ ] }),
1815
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid md:grid-cols-3 gap-4", children: [
1816
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1817
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardHeader, { className: "p-4 pb-2", children: /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { className: "text-sm", children: "São Paulo" }) }),
1818
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { className: "p-4 pt-0", children: /* @__PURE__ */ jsxRuntime.jsx(
1819
+ alertDialog.Map,
1820
+ {
1821
+ center: { lat: -23.5505, lng: -46.6333 },
1822
+ zoom: 11,
1823
+ height: "200px",
1824
+ disableDefaultUI: true,
1825
+ apiKey
1826
+ }
1827
+ ) })
1828
+ ] }),
1829
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1830
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardHeader, { className: "p-4 pb-2", children: /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { className: "text-sm", children: "Rio de Janeiro" }) }),
1831
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { className: "p-4 pt-0", children: /* @__PURE__ */ jsxRuntime.jsx(
1832
+ alertDialog.Map,
1833
+ {
1834
+ center: { lat: -22.9068, lng: -43.1729 },
1835
+ zoom: 11,
1836
+ height: "200px",
1837
+ disableDefaultUI: true,
1838
+ apiKey
1839
+ }
1840
+ ) })
1841
+ ] }),
1842
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1843
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardHeader, { className: "p-4 pb-2", children: /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { className: "text-sm", children: "New York" }) }),
1844
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { className: "p-4 pt-0", children: /* @__PURE__ */ jsxRuntime.jsx(
1845
+ alertDialog.Map,
1846
+ {
1847
+ center: { lat: 40.7128, lng: -74.006 },
1848
+ zoom: 11,
1849
+ height: "200px",
1850
+ disableDefaultUI: true,
1851
+ apiKey
1852
+ }
1853
+ ) })
1854
+ ] })
1855
+ ] })
1856
+ ] }) }),
1857
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsContent, { value: "markers", className: "space-y-8", children: !isTransitioning && activeTab === "markers" && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
1858
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1859
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
1860
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: "Marcadores e Pins" }),
1861
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: "Exemplos de marcadores personalizados com diferentes cores e informações." })
1862
+ ] }),
1863
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(
1864
+ alertDialog.Map,
1865
+ {
1866
+ center: { lat: -23.5505, lng: -46.6333 },
1867
+ zoom: 13,
1868
+ height: "500px",
1869
+ apiKey,
1870
+ markers: [
1871
+ {
1872
+ position: { lat: -23.5505, lng: -46.6333 },
1873
+ title: "Principal",
1874
+ info: "Marcador padrão",
1875
+ customColor: "#4F46E5"
1876
+ },
1877
+ {
1878
+ position: { lat: -23.54, lng: -46.64 },
1879
+ title: "Secundário",
1880
+ info: "Marcador de alerta",
1881
+ customColor: "#EF4444",
1882
+ icon: "!"
1883
+ },
1884
+ {
1885
+ position: { lat: -23.56, lng: -46.62 },
1886
+ title: "Loja",
1887
+ info: "Ponto de venda",
1888
+ customColor: "#10B981",
1889
+ icon: "S"
1890
+ }
1891
+ ]
1892
+ }
1893
+ ) })
1894
+ ] }),
1895
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1896
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
1897
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: "Marcador com Ações" }),
1898
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: "Marcador interativo que exibe conteúdo rico (texto, imagem, botões) ao ser clicado." })
1899
+ ] }),
1900
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(
1901
+ alertDialog.Map,
1902
+ {
1903
+ center: { lat: -23.5505, lng: -46.6333 },
1904
+ zoom: 13,
1905
+ height: "500px",
1906
+ apiKey,
1907
+ markers: [
1908
+ {
1909
+ position: { lat: -23.5505, lng: -46.6333 },
1910
+ label: "🏢",
1911
+ richContent: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-4 max-w-[260px]", children: [
1912
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between mb-2", children: [
1913
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-semibold text-base", children: "Xertica HQ" }),
1914
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "outline", className: "text-[10px] h-5", children: "Open" })
1915
+ ] }),
1916
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full h-32 bg-muted rounded-md mb-3 overflow-hidden relative", children: [
1917
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 bg-[image:var(--gradient-diagonal)] opacity-80" }),
1918
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 flex items-center justify-center text-white font-medium", children: "Office View" })
1919
+ ] }),
1920
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground mb-3 leading-relaxed", children: "Sede principal em São Paulo. Espaço moderno para reuniões e eventos." }),
1921
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-2", children: [
1922
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { size: "sm", className: "w-full h-8 text-xs shadow-sm", children: "Navegar" }),
1923
+ /* @__PURE__ */ jsxRuntime.jsx(
1924
+ button.Button,
1925
+ {
1926
+ size: "sm",
1927
+ variant: "outline",
1928
+ className: "w-full h-8 text-xs bg-background",
1929
+ children: "Detalhes"
1930
+ }
1931
+ )
1932
+ ] })
1933
+ ] })
1934
+ }
1935
+ ]
1936
+ }
1937
+ ) })
1938
+ ] }),
1939
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1940
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
1941
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: "Áreas e Zonas" }),
1942
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: "Delimitação de áreas geográficas usando círculos e polígonos." })
1943
+ ] }),
1944
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(
1945
+ alertDialog.Map,
1946
+ {
1947
+ center: { lat: -23.5505, lng: -46.6333 },
1948
+ zoom: 12,
1949
+ height: "500px",
1950
+ apiKey,
1951
+ markers: [
1952
+ {
1953
+ position: { lat: -23.5505, lng: -46.6333 },
1954
+ title: "Centro da Zona",
1955
+ info: "Raio de 3km",
1956
+ customColor: "#6366F1"
1957
+ }
1958
+ ],
1959
+ circle: {
1960
+ center: { lat: -23.5505, lng: -46.6333 },
1961
+ radius: 3e3,
1962
+ fillColor: "#6366F1",
1963
+ strokeColor: "#4F46E5"
1964
+ },
1965
+ polygon: {
1966
+ paths: [
1967
+ [
1968
+ { lat: -23.52, lng: -46.6 },
1969
+ { lat: -23.52, lng: -46.66 },
1970
+ { lat: -23.58, lng: -46.66 },
1971
+ { lat: -23.58, lng: -46.6 }
1972
+ ]
1973
+ ],
1974
+ fillColor: "#10B981",
1975
+ strokeColor: "#059669"
1976
+ }
1977
+ }
1978
+ ) })
1979
+ ] })
1980
+ ] }) }),
1981
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsContent, { value: "controls", className: "space-y-8", children: !isTransitioning && activeTab === "controls" && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
1982
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
1983
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
1984
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: "Controles do Mapa" }),
1985
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: "Personalize a interface do mapa ativando ou desativando controles nativos." })
1986
+ ] }),
1987
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { className: "space-y-4", children: [
1988
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 md:grid-cols-4 gap-4 p-4 border rounded-lg bg-muted/50", children: [
1989
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
1990
+ /* @__PURE__ */ jsxRuntime.jsx(
1991
+ alertDialog.Checkbox,
1992
+ {
1993
+ id: "zoom",
1994
+ checked: showZoomControl,
1995
+ onCheckedChange: (c) => setShowZoomControl(!!c)
1996
+ }
1997
+ ),
1998
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "zoom", children: "Zoom Control" })
1999
+ ] }),
2000
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2001
+ /* @__PURE__ */ jsxRuntime.jsx(
2002
+ alertDialog.Checkbox,
2003
+ {
2004
+ id: "maptype",
2005
+ checked: showMapTypeControl,
2006
+ onCheckedChange: (c) => setShowMapTypeControl(!!c)
2007
+ }
2008
+ ),
2009
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "maptype", children: "Map Type" })
2010
+ ] }),
2011
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2012
+ /* @__PURE__ */ jsxRuntime.jsx(
2013
+ alertDialog.Checkbox,
2014
+ {
2015
+ id: "streetview",
2016
+ checked: showStreetViewControl,
2017
+ onCheckedChange: (c) => setShowStreetViewControl(!!c)
2018
+ }
2019
+ ),
2020
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "streetview", children: "Street View" })
2021
+ ] }),
2022
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2023
+ /* @__PURE__ */ jsxRuntime.jsx(
2024
+ alertDialog.Checkbox,
2025
+ {
2026
+ id: "fullscreen",
2027
+ checked: showFullscreenControl,
2028
+ onCheckedChange: (c) => setShowFullscreenControl(!!c)
2029
+ }
2030
+ ),
2031
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "fullscreen", children: "Fullscreen" })
2032
+ ] })
2033
+ ] }),
2034
+ /* @__PURE__ */ jsxRuntime.jsx(
2035
+ alertDialog.Map,
2036
+ {
2037
+ center: { lat: -23.5505, lng: -46.6333 },
2038
+ zoom: 13,
2039
+ height: "400px",
2040
+ apiKey,
2041
+ zoomControl: showZoomControl,
2042
+ mapTypeControl: showMapTypeControl,
2043
+ streetViewControl: showStreetViewControl,
2044
+ fullscreenControl: showFullscreenControl
2045
+ }
2046
+ )
2047
+ ] })
2048
+ ] }),
2049
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2050
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2051
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: "Filtros Interativos" }),
2052
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: "Exemplo avançado de mapa com controles customizados para filtragem de marcadores." })
2053
+ ] }),
2054
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(FilterableMapExample, { apiKey }) })
2055
+ ] })
2056
+ ] }) }),
2057
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsContent, { value: "drawing", className: "space-y-8", children: !isTransitioning && activeTab === "drawing" && /* @__PURE__ */ jsxRuntime.jsx(DrawingMapExample, { apiKey }) })
2058
+ ] }),
2059
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid md:grid-cols-3 gap-6 pt-8 border-t", children: [
2060
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2061
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-semibold text-sm", children: "Documentação" }),
2062
+ /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-xs text-muted-foreground", children: [
2063
+ "Verifique ",
2064
+ /* @__PURE__ */ jsxRuntime.jsx("code", { children: "MAP_SETUP.md" }),
2065
+ " para configuração inicial e requisitos de API."
2066
+ ] })
2067
+ ] }),
2068
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2069
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-semibold text-sm", children: "Performance" }),
2070
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-muted-foreground", children: "Utiliza carregamento assíncrono e AdvancedMarkerElement para melhor desempenho." })
2071
+ ] }),
2072
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2073
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-semibold text-sm", children: "Design System" }),
2074
+ /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-xs text-muted-foreground", children: [
2075
+ "Componentes seguem estritamente as variáveis de tokens do ",
2076
+ /* @__PURE__ */ jsxRuntime.jsx("code", { children: "globals.css" }),
2077
+ "."
2078
+ ] })
2079
+ ] })
2080
+ ] })
2081
+ ] });
2082
+ }
2083
+
2084
+ function TemplateContent() {
2085
+ const { t } = reactI18next.useTranslation();
2086
+ const layout = LayoutContext.useOptionalLayout();
2087
+ const { disableDarkMode } = ThemeContext.useTheme();
2088
+ const [localSidebarExpanded, setLocalSidebarExpanded] = React.useState(false);
2089
+ const [localSidebarWidth, setLocalSidebarWidth] = React.useState(280);
2090
+ const sidebarExpanded = layout?.sidebarExpanded ?? localSidebarExpanded;
2091
+ const sidebarWidth = layout?.sidebarWidth ?? localSidebarWidth;
2092
+ const setSidebarWidth = layout?.setSidebarWidth ?? setLocalSidebarWidth;
2093
+ layout?.toggleSidebar ?? (() => setLocalSidebarExpanded((value) => !value));
2094
+ reactRouterDom.useNavigate();
2095
+ const { data: teamMembers = [], isLoading: teamLoading } = useTeamMembers();
2096
+ const progress$1 = useDashboardStore((s) => s.progress);
2097
+ const setProgress = useDashboardStore((s) => s.setProgress);
2098
+ const sliderValue = useDashboardStore((s) => s.sliderValue);
2099
+ const setSliderValue = useDashboardStore((s) => s.setSliderValue);
2100
+ const switchEnabled = useDashboardStore((s) => s.switchEnabled);
2101
+ const toggleSwitch = useDashboardStore((s) => s.toggleSwitch);
2102
+ const [showSidebarUser, setShowSidebarUser] = React.useState(true);
2103
+ const [showSidebarSettings, setShowSidebarSettings] = React.useState(true);
2104
+ const [showSidebarLogout, setShowSidebarLogout] = React.useState(true);
2105
+ const [showHeaderActions, setShowHeaderActions] = React.useState(true);
2106
+ const [showHeaderBreadcrumbs, setShowHeaderBreadcrumbs] = React.useState(true);
2107
+ const handleFormSubmit = (e) => {
2108
+ e.preventDefault();
2109
+ sonner.toast.success(t("templates.formSubmitSuccess"));
2110
+ };
2111
+ return /* @__PURE__ */ jsxRuntime.jsxs(
2112
+ "div",
2113
+ {
2114
+ className: "flex-1 flex flex-col overflow-hidden transition-all duration-300",
2115
+ style: {
2116
+ paddingLeft: sidebarExpanded ? `${sidebarWidth}px` : "80px"
2117
+ },
2118
+ children: [
2119
+ /* @__PURE__ */ jsxRuntime.jsx(
2120
+ sidebar.Header,
2121
+ {
2122
+ showThemeToggle: true,
2123
+ showLanguageSelector: true,
2124
+ breadcrumbs: [
2125
+ { label: t("nav.designSystem"), href: "/home", icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Home, { className: "w-4 h-4" }) },
2126
+ { label: t("templates.breadcrumb") }
2127
+ ],
2128
+ renderLink: (href, props) => /* @__PURE__ */ jsxRuntime.jsx(reactRouterDom.Link, { to: href, ...props })
2129
+ }
2130
+ ),
2131
+ /* @__PURE__ */ jsxRuntime.jsx("main", { className: "flex-1 overflow-hidden bg-muted", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-full", style: { overflowY: "auto", overflowX: "hidden" }, children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "p-5 sm:p-4 md:p-6", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "max-w-6xl mx-auto space-y-8", children: [
2132
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.PageHeader, { title: t("templates.title"), subtitle: t("templates.subtitle") }),
2133
+ /* @__PURE__ */ jsxRuntime.jsxs("section", { children: [
2134
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-4", children: t("templates.headerWithBreadcrumbs.sectionTitle") }),
2135
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2136
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2137
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.headerWithBreadcrumbs.cardTitle") }),
2138
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.headerWithBreadcrumbs.cardDescription") })
2139
+ ] }),
2140
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { className: "p-0 border-t bg-background overflow-hidden rounded-b-[var(--radius-lg)]", children: [
2141
+ /* @__PURE__ */ jsxRuntime.jsx(
2142
+ sidebar.Header,
2143
+ {
2144
+ className: "border-b",
2145
+ breadcrumbs: [
2146
+ {
2147
+ label: t("templates.headerWithBreadcrumbs.breadcrumbs.dashboard"),
2148
+ href: "#",
2149
+ icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Home, { className: "w-4 h-4" })
2150
+ },
2151
+ {
2152
+ label: t("templates.headerWithBreadcrumbs.breadcrumbs.settings"),
2153
+ href: "#",
2154
+ icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Settings, { className: "w-4 h-4" })
2155
+ },
2156
+ {
2157
+ label: t("templates.headerWithBreadcrumbs.breadcrumbs.users"),
2158
+ href: "#",
2159
+ icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Users, { className: "w-4 h-4" })
2160
+ },
2161
+ { label: t("templates.headerWithBreadcrumbs.breadcrumbs.accessProfile") }
2162
+ ],
2163
+ showLanguageSelector: true,
2164
+ showThemeToggle: true
2165
+ }
2166
+ ),
2167
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-6 min-h-[200px]", children: [
2168
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "text-lg font-semibold mb-2", children: t("templates.headerWithBreadcrumbs.exampleContentTitle") }),
2169
+ /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-muted-foreground", children: [
2170
+ t("templates.headerWithBreadcrumbs.exampleContentDescriptionPart1"),
2171
+ /* @__PURE__ */ jsxRuntime.jsx("strong", { children: "Header" }),
2172
+ t("templates.headerWithBreadcrumbs.exampleContentDescriptionPart2")
2173
+ ] })
2174
+ ] })
2175
+ ] })
2176
+ ] })
2177
+ ] }),
2178
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, { className: "my-8" }),
2179
+ /* @__PURE__ */ jsxRuntime.jsxs("section", { children: [
2180
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-4", children: t("templates.sections.alerts") }),
2181
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid gap-4 md:grid-cols-2", children: [
2182
+ /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.Alert, { variant: "info", children: [
2183
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.AlertTitle, { children: t("templates.alerts.infoTitle") }),
2184
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.AlertDescription, { children: t("templates.alerts.infoDescription") })
2185
+ ] }),
2186
+ /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.Alert, { variant: "destructive", children: [
2187
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.AlertTitle, { children: t("templates.alerts.errorTitle") }),
2188
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.AlertDescription, { children: t("templates.alerts.errorDescription") })
2189
+ ] }),
2190
+ /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.Alert, { variant: "success", children: [
2191
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.AlertTitle, { children: t("templates.alerts.successTitle") }),
2192
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.AlertDescription, { children: t("templates.alerts.successDescription") })
2193
+ ] }),
2194
+ /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.Alert, { variant: "warning", children: [
2195
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.AlertTitle, { children: t("templates.alerts.warningTitle") }),
2196
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.AlertDescription, { children: t("templates.alerts.warningDescription") })
2197
+ ] })
2198
+ ] })
2199
+ ] }),
2200
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, { className: "my-8" }),
2201
+ /* @__PURE__ */ jsxRuntime.jsxs("section", { children: [
2202
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-4", children: t("templates.sections.cardsAndTabs") }),
2203
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.Tabs, { defaultValue: "overview", className: "w-full", children: [
2204
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.TabsList, { className: "grid w-full grid-cols-4", children: [
2205
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsTrigger, { value: "overview", children: t("templates.tabs.overview") }),
2206
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsTrigger, { value: "forms", children: t("templates.tabs.forms") }),
2207
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsTrigger, { value: "data", children: t("templates.tabs.data") }),
2208
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsTrigger, { value: "settings", children: t("templates.tabs.settings") })
2209
+ ] }),
2210
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.TabsContent, { value: "overview", className: "space-y-4", children: [
2211
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid gap-4 md:grid-cols-3", children: [
2212
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2213
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2214
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("stats.totalUsers") }),
2215
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("stats.last30Days") })
2216
+ ] }),
2217
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-foreground", children: [
2218
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "[font-size:var(--text-stats)] [font-weight:var(--font-weight-bold)]", children: "1,234" }),
2219
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "default", className: "ml-2", children: "+12%" })
2220
+ ] }) })
2221
+ ] }),
2222
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2223
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2224
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("stats.totalRevenue") }),
2225
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("stats.currentMonth") })
2226
+ ] }),
2227
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-foreground", children: [
2228
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "[font-size:var(--text-stats)] [font-weight:var(--font-weight-bold)]", children: "$ 45.2k" }),
2229
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "secondary", className: "ml-2", children: "+8%" })
2230
+ ] }) })
2231
+ ] }),
2232
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2233
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2234
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("stats.conversionRate") }),
2235
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("stats.currentWeek") })
2236
+ ] }),
2237
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-foreground", children: [
2238
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "[font-size:var(--text-stats)] [font-weight:var(--font-weight-bold)]", children: "3.2%" }),
2239
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "outline", className: "ml-2", children: "-2%" })
2240
+ ] }) })
2241
+ ] })
2242
+ ] }),
2243
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2244
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2245
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.overview.progressTitle") }),
2246
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.overview.progressDescription") })
2247
+ ] }),
2248
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { className: "space-y-6", children: [
2249
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2250
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
2251
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { children: t("templates.overview.projectProgress") }),
2252
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "[font-size:var(--text-small)] text-muted-foreground", children: [
2253
+ progress$1,
2254
+ "%"
2255
+ ] })
2256
+ ] }),
2257
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Progress, { value: progress$1, className: "w-full" }),
2258
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-2", children: [
2259
+ /* @__PURE__ */ jsxRuntime.jsx(
2260
+ button.Button,
2261
+ {
2262
+ size: "sm",
2263
+ onClick: () => setProgress(Math.max(0, progress$1 - 10)),
2264
+ children: "-10%"
2265
+ }
2266
+ ),
2267
+ /* @__PURE__ */ jsxRuntime.jsx(
2268
+ button.Button,
2269
+ {
2270
+ size: "sm",
2271
+ onClick: () => setProgress(Math.min(100, progress$1 + 10)),
2272
+ children: "+10%"
2273
+ }
2274
+ )
2275
+ ] })
2276
+ ] }),
2277
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
2278
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2279
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
2280
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { children: t("templates.overview.volume") }),
2281
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "[font-size:var(--text-small)] text-muted-foreground", children: [
2282
+ sliderValue[0],
2283
+ "%"
2284
+ ] })
2285
+ ] }),
2286
+ /* @__PURE__ */ jsxRuntime.jsx(
2287
+ slider.Slider,
2288
+ {
2289
+ value: sliderValue,
2290
+ onValueChange: setSliderValue,
2291
+ min: 0,
2292
+ max: 100,
2293
+ step: 1,
2294
+ className: "w-full",
2295
+ "aria-label": t("templates.overview.volume")
2296
+ }
2297
+ )
2298
+ ] })
2299
+ ] })
2300
+ ] })
2301
+ ] }),
2302
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsContent, { value: "forms", className: "space-y-4", children: /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2303
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2304
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.forms.registrationTitle") }),
2305
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.forms.registrationDescription") })
2306
+ ] }),
2307
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsxs("form", { onSubmit: handleFormSubmit, className: "space-y-4", children: [
2308
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid gap-4 md:grid-cols-2", children: [
2309
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2310
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "firstName", children: t("templates.forms.firstName") }),
2311
+ /* @__PURE__ */ jsxRuntime.jsx(
2312
+ input.Input,
2313
+ {
2314
+ id: "firstName",
2315
+ placeholder: t("templates.forms.firstNamePlaceholder")
2316
+ }
2317
+ )
2318
+ ] }),
2319
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2320
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "lastName", children: t("templates.forms.lastName") }),
2321
+ /* @__PURE__ */ jsxRuntime.jsx(
2322
+ input.Input,
2323
+ {
2324
+ id: "lastName",
2325
+ placeholder: t("templates.forms.lastNamePlaceholder")
2326
+ }
2327
+ )
2328
+ ] })
2329
+ ] }),
2330
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2331
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "email", children: t("templates.forms.email") }),
2332
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
2333
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Mail, { className: "absolute left-3 top-3 h-4 w-4 text-muted-foreground" }),
2334
+ /* @__PURE__ */ jsxRuntime.jsx(
2335
+ input.Input,
2336
+ {
2337
+ id: "email",
2338
+ type: "email",
2339
+ placeholder: t("templates.forms.emailPlaceholder"),
2340
+ className: "pl-10"
2341
+ }
2342
+ )
2343
+ ] })
2344
+ ] }),
2345
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2346
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "phone", children: t("templates.forms.phone") }),
2347
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
2348
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Phone, { className: "absolute left-3 top-3 h-4 w-4 text-muted-foreground" }),
2349
+ /* @__PURE__ */ jsxRuntime.jsx(
2350
+ input.Input,
2351
+ {
2352
+ id: "phone",
2353
+ type: "tel",
2354
+ placeholder: t("templates.forms.phonePlaceholder"),
2355
+ className: "pl-10"
2356
+ }
2357
+ )
2358
+ ] })
2359
+ ] }),
2360
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2361
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "role", children: t("templates.forms.role") }),
2362
+ /* @__PURE__ */ jsxRuntime.jsxs(select.Select, { children: [
2363
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectTrigger, { id: "role", children: /* @__PURE__ */ jsxRuntime.jsx(select.SelectValue, { placeholder: t("templates.forms.rolePlaceholder") }) }),
2364
+ /* @__PURE__ */ jsxRuntime.jsxs(select.SelectContent, { children: [
2365
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "developer", children: t("templates.forms.roles.developer") }),
2366
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "designer", children: t("templates.forms.roles.designer") }),
2367
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "manager", children: t("templates.forms.roles.manager") }),
2368
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "analyst", children: t("templates.forms.roles.analyst") })
2369
+ ] })
2370
+ ] })
2371
+ ] }),
2372
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
2373
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "bio", children: t("templates.forms.bio") }),
2374
+ /* @__PURE__ */ jsxRuntime.jsx(
2375
+ richTextEditor.Textarea,
2376
+ {
2377
+ id: "bio",
2378
+ placeholder: t("templates.forms.bioPlaceholder"),
2379
+ rows: 4
2380
+ }
2381
+ )
2382
+ ] }),
2383
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
2384
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4", children: [
2385
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { children: t("templates.forms.preferences") }),
2386
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
2387
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2388
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Checkbox, { id: "newsletter" }),
2389
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "newsletter", className: "font-normal", children: t("templates.forms.newsletter") })
2390
+ ] }),
2391
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2392
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Checkbox, { id: "notifications" }),
2393
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "notifications", className: "font-normal", children: t("templates.forms.pushNotifications") })
2394
+ ] }),
2395
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2396
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Checkbox, { id: "updates" }),
2397
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "updates", className: "font-normal", children: t("templates.forms.featureUpdates") })
2398
+ ] })
2399
+ ] }),
2400
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
2401
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
2402
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { children: t("templates.forms.accountType") }),
2403
+ /* @__PURE__ */ jsxRuntime.jsxs(
2404
+ alertDialog.RadioGroup,
2405
+ {
2406
+ defaultValue: "personal",
2407
+ "aria-label": t("templates.forms.accountType"),
2408
+ children: [
2409
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2410
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.RadioGroupItem, { value: "personal", id: "personal" }),
2411
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "personal", className: "font-normal", children: t("templates.forms.accountPersonal") })
2412
+ ] }),
2413
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2414
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.RadioGroupItem, { value: "business", id: "business" }),
2415
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "business", className: "font-normal", children: t("templates.forms.accountBusiness") })
2416
+ ] }),
2417
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2418
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.RadioGroupItem, { value: "enterprise", id: "enterprise" }),
2419
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "enterprise", className: "font-normal", children: t("templates.forms.accountEnterprise") })
2420
+ ] })
2421
+ ]
2422
+ }
2423
+ )
2424
+ ] })
2425
+ ] })
2426
+ ] }) }),
2427
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardFooter, { className: "flex justify-between", children: [
2428
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "outline", children: t("templates.forms.cancel") }),
2429
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { onClick: handleFormSubmit, children: t("templates.forms.createAccount") })
2430
+ ] })
2431
+ ] }) }),
2432
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsContent, { value: "data", className: "space-y-4", children: /* @__PURE__ */ jsxRuntime.jsx(SectionErrorBoundary, { children: /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2433
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2434
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.data.title") }),
2435
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.data.description") })
2436
+ ] }),
2437
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { children: [
2438
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mb-4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
2439
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Search, { className: "absolute left-3 top-3 h-4 w-4 text-muted-foreground" }),
2440
+ /* @__PURE__ */ jsxRuntime.jsx(
2441
+ input.Input,
2442
+ {
2443
+ placeholder: t("templates.data.searchPlaceholder"),
2444
+ "aria-label": t("templates.data.searchPlaceholder"),
2445
+ className: "pl-10"
2446
+ }
2447
+ )
2448
+ ] }) }),
2449
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "rounded-[var(--radius-lg)] border border-border overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.Table, { children: [
2450
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableHeader, { children: /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.TableRow, { children: [
2451
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableHead, { children: t("team.name") }),
2452
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableHead, { children: t("team.email") }),
2453
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableHead, { children: t("team.role") }),
2454
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableHead, { children: t("team.status") }),
2455
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableHead, { className: "text-right", children: t("team.actions") })
2456
+ ] }) }),
2457
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableBody, { children: teamLoading ? /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: Array.from({ length: 5 }).map((_, i) => /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.TableRow, { children: [
2458
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
2459
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.Skeleton, { className: "size-8 rounded-full shrink-0" }),
2460
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.Skeleton, { className: "h-3.5 w-28" })
2461
+ ] }) }),
2462
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { children: /* @__PURE__ */ jsxRuntime.jsx(skeleton.Skeleton, { className: "h-3.5 w-36" }) }),
2463
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { children: /* @__PURE__ */ jsxRuntime.jsx(skeleton.Skeleton, { className: "h-3.5 w-20" }) }),
2464
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { children: /* @__PURE__ */ jsxRuntime.jsx(skeleton.Skeleton, { className: "h-5 w-16 rounded-full" }) }),
2465
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { className: "text-right", children: /* @__PURE__ */ jsxRuntime.jsx(skeleton.Skeleton, { className: "h-7 w-14 ml-auto" }) })
2466
+ ] }, i)) }) : teamMembers.map((member) => /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.TableRow, { children: [
2467
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { children: member.name }),
2468
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { children: member.email }),
2469
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { children: t(`team.roles.${member.role}`) }),
2470
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { children: /* @__PURE__ */ jsxRuntime.jsx(
2471
+ progress.Badge,
2472
+ {
2473
+ variant: member.status === "active" ? "default" : member.status === "away" ? "secondary" : "outline",
2474
+ children: t(`common.${member.status}`)
2475
+ }
2476
+ ) }),
2477
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.TableCell, { className: "text-right", children: /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "ghost", size: "sm", children: t("common.edit") }) })
2478
+ ] }, member.id)) })
2479
+ ] }) })
2480
+ ] }),
2481
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardFooter, { className: "flex justify-between items-center", children: [
2482
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: t("team.showing", {
2483
+ count: teamMembers.length,
2484
+ total: teamMembers.length
2485
+ }) }),
2486
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-2", children: [
2487
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "outline", size: "sm", children: t("common.previous") }),
2488
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "outline", size: "sm", children: t("common.next") })
2489
+ ] })
2490
+ ] })
2491
+ ] }) }) }),
2492
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsContent, { value: "settings", className: "space-y-4", children: /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2493
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2494
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.settings.title") }),
2495
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.settings.description") })
2496
+ ] }),
2497
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { className: "space-y-6", children: [
2498
+ !disableDarkMode && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
2499
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
2500
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
2501
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "dark-mode", children: t("templates.settings.darkMode") }),
2502
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: t("templates.settings.darkModeDescription") })
2503
+ ] }),
2504
+ /* @__PURE__ */ jsxRuntime.jsx(
2505
+ alertDialog.Switch,
2506
+ {
2507
+ id: "dark-mode",
2508
+ checked: switchEnabled,
2509
+ onCheckedChange: toggleSwitch
2510
+ }
2511
+ )
2512
+ ] }),
2513
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {})
2514
+ ] }),
2515
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
2516
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
2517
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "email-notifications", children: t("templates.settings.emailNotifications") }),
2518
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: t("templates.settings.emailNotificationsDescription") })
2519
+ ] }),
2520
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Switch, { id: "email-notifications", defaultChecked: true })
2521
+ ] }),
2522
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
2523
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
2524
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
2525
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "push-notifications", children: t("templates.settings.pushNotifications") }),
2526
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: t("templates.settings.pushNotificationsDescription") })
2527
+ ] }),
2528
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Switch, { id: "push-notifications" })
2529
+ ] }),
2530
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
2531
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
2532
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { children: t("templates.settings.language") }),
2533
+ /* @__PURE__ */ jsxRuntime.jsxs(select.Select, { defaultValue: "pt-br", children: [
2534
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectTrigger, { "aria-label": t("templates.settings.language"), children: /* @__PURE__ */ jsxRuntime.jsx(select.SelectValue, {}) }),
2535
+ /* @__PURE__ */ jsxRuntime.jsxs(select.SelectContent, { children: [
2536
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "pt-br", children: t("templates.settings.languages.ptBR") }),
2537
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "en", children: t("templates.settings.languages.en") }),
2538
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "es", children: t("templates.settings.languages.es") })
2539
+ ] })
2540
+ ] })
2541
+ ] }),
2542
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
2543
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
2544
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { children: t("templates.settings.timezone") }),
2545
+ /* @__PURE__ */ jsxRuntime.jsxs(select.Select, { defaultValue: "america-sao-paulo", children: [
2546
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectTrigger, { "aria-label": t("templates.settings.timezone"), children: /* @__PURE__ */ jsxRuntime.jsx(select.SelectValue, {}) }),
2547
+ /* @__PURE__ */ jsxRuntime.jsxs(select.SelectContent, { children: [
2548
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "america-sao-paulo", children: t("templates.settings.timezones.saoPaulo") }),
2549
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "america-new-york", children: t("templates.settings.timezones.newYork") }),
2550
+ /* @__PURE__ */ jsxRuntime.jsx(select.SelectItem, { value: "europe-london", children: t("templates.settings.timezones.london") })
2551
+ ] })
2552
+ ] })
2553
+ ] })
2554
+ ] }),
2555
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardFooter, { className: "flex justify-between", children: [
2556
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "outline", children: t("templates.settings.restoreDefaults") }),
2557
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { children: t("templates.settings.saveChanges") })
2558
+ ] })
2559
+ ] }) })
2560
+ ] })
2561
+ ] }),
2562
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, { className: "my-8" }),
2563
+ /* @__PURE__ */ jsxRuntime.jsxs("section", { children: [
2564
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-4", children: t("templates.sections.buttons") }),
2565
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2566
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2567
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.buttons.title") }),
2568
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.buttons.description") })
2569
+ ] }),
2570
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { className: "space-y-6", children: [
2571
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
2572
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { children: t("templates.buttons.variants") }),
2573
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap gap-3", children: [
2574
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "default", children: "Default" }),
2575
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "secondary", children: "Secondary" }),
2576
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "outline", children: "Outline" }),
2577
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "ghost", children: "Ghost" }),
2578
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "link", children: "Link" }),
2579
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "destructive", children: "Destructive" })
2580
+ ] })
2581
+ ] }),
2582
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
2583
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
2584
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { children: t("templates.buttons.sizes") }),
2585
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap items-center gap-3", children: [
2586
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { size: "sm", children: "Small" }),
2587
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { size: "default", children: "Default" }),
2588
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { size: "lg", children: "Large" }),
2589
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { size: "icon", "aria-label": t("nav.settings"), children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Settings, { className: "h-4 w-4" }) })
2590
+ ] })
2591
+ ] }),
2592
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
2593
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
2594
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { children: t("templates.buttons.withIcons") }),
2595
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap gap-3", children: [
2596
+ /* @__PURE__ */ jsxRuntime.jsxs(button.Button, { children: [
2597
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.User, { className: "mr-2 h-4 w-4" }),
2598
+ t("templates.buttons.profile")
2599
+ ] }),
2600
+ /* @__PURE__ */ jsxRuntime.jsxs(button.Button, { variant: "secondary", children: [
2601
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Mail, { className: "mr-2 h-4 w-4" }),
2602
+ t("templates.buttons.messages")
2603
+ ] }),
2604
+ /* @__PURE__ */ jsxRuntime.jsxs(button.Button, { variant: "outline", children: [
2605
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Calendar, { className: "mr-2 h-4 w-4" }),
2606
+ t("templates.buttons.schedule")
2607
+ ] })
2608
+ ] })
2609
+ ] }),
2610
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, {}),
2611
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
2612
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { children: t("templates.buttons.states") }),
2613
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap gap-3", children: [
2614
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { disabled: true, children: t("templates.buttons.disabled") }),
2615
+ /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "outline", disabled: true, children: t("templates.buttons.outlineDisabled") })
2616
+ ] })
2617
+ ] })
2618
+ ] })
2619
+ ] })
2620
+ ] }),
2621
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, { className: "my-8" }),
2622
+ /* @__PURE__ */ jsxRuntime.jsxs("section", { children: [
2623
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-4", children: t("templates.sections.badges") }),
2624
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2625
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2626
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.badges.title") }),
2627
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.badges.description") })
2628
+ ] }),
2629
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap gap-3", children: [
2630
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "default", children: "Default" }),
2631
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "secondary", children: "Secondary" }),
2632
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "outline", children: "Outline" }),
2633
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { variant: "destructive", children: "Destructive" }),
2634
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { className: "bg-success text-success-foreground", children: "Success" }),
2635
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { className: "bg-warning text-warning-foreground", children: "Warning" }),
2636
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { className: "bg-info text-info-foreground", children: "Info" })
2637
+ ] }) })
2638
+ ] })
2639
+ ] }),
2640
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, { className: "my-8" }),
2641
+ /* @__PURE__ */ jsxRuntime.jsxs("section", { children: [
2642
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-4", children: t("templates.sections.dialogs") }),
2643
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid gap-4 md:grid-cols-2", children: [
2644
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2645
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2646
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.dialogs.dialogTitle") }),
2647
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.dialogs.dialogDescription") })
2648
+ ] }),
2649
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { className: "flex justify-center py-6", children: /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.Dialog, { children: [
2650
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.DialogTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "outline", children: t("templates.dialogs.editProfile") }) }),
2651
+ /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.DialogContent, { className: "sm:max-w-[425px]", children: [
2652
+ /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.DialogHeader, { children: [
2653
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.DialogTitle, { children: t("templates.dialogs.editProfile") }),
2654
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.DialogDescription, { children: t("templates.dialogs.editProfileDescription") })
2655
+ ] }),
2656
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid gap-4 py-4", children: [
2657
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-4 items-center gap-4", children: [
2658
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "name", className: "text-right", children: t("templates.dialogs.name") }),
2659
+ /* @__PURE__ */ jsxRuntime.jsx(input.Input, { id: "name", defaultValue: "John Doe", className: "col-span-3" })
2660
+ ] }),
2661
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-4 items-center gap-4", children: [
2662
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "username", className: "text-right", children: t("templates.dialogs.username") }),
2663
+ /* @__PURE__ */ jsxRuntime.jsx(input.Input, { id: "username", defaultValue: "@johndoe", className: "col-span-3" })
2664
+ ] })
2665
+ ] }),
2666
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.DialogFooter, { children: /* @__PURE__ */ jsxRuntime.jsx(button.Button, { type: "submit", children: t("templates.dialogs.update") }) })
2667
+ ] })
2668
+ ] }) })
2669
+ ] }),
2670
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2671
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2672
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.dialogs.alertDialogTitle") }),
2673
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.dialogs.alertDialogDescription") })
2674
+ ] }),
2675
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { className: "flex justify-center py-6", children: /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.AlertDialog, { children: [
2676
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.AlertDialogTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "destructive", children: t("templates.dialogs.deleteAccount") }) }),
2677
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.AlertDialogContent, { className: "sm:max-w-[425px]", children: [
2678
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.AlertDialogHeader, { children: [
2679
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.AlertDialogTitle, { children: t("templates.dialogs.areYouSure") }),
2680
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.AlertDialogDescription, { children: t("templates.dialogs.deleteWarning") })
2681
+ ] }),
2682
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.AlertDialogFooter, { children: [
2683
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.AlertDialogCancel, { children: t("templates.dialogs.cancel") }),
2684
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.AlertDialogAction, { className: "bg-destructive text-destructive-foreground hover:bg-destructive/90", children: t("templates.dialogs.continue") })
2685
+ ] })
2686
+ ] })
2687
+ ] }) })
2688
+ ] })
2689
+ ] })
2690
+ ] }),
2691
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, { className: "my-8" }),
2692
+ /* @__PURE__ */ jsxRuntime.jsx("section", { children: /* @__PURE__ */ jsxRuntime.jsx(MapShowcase, {}) }),
2693
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, { className: "my-8" }),
2694
+ /* @__PURE__ */ jsxRuntime.jsxs("section", { children: [
2695
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-4", children: t("templates.headerVariations.sectionTitle") }),
2696
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2697
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2698
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.headerVariations.cardTitle") }),
2699
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.headerVariations.cardDescription") })
2700
+ ] }),
2701
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { className: "space-y-6", children: [
2702
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-4 border rounded-[var(--radius-lg)] bg-muted/30", children: [
2703
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "text-sm font-semibold mb-4", children: t("templates.headerVariations.visibleElements") }),
2704
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 gap-6", children: [
2705
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2706
+ /* @__PURE__ */ jsxRuntime.jsx(
2707
+ alertDialog.Switch,
2708
+ {
2709
+ id: "header-actions",
2710
+ checked: showHeaderActions,
2711
+ onCheckedChange: setShowHeaderActions
2712
+ }
2713
+ ),
2714
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "header-actions", className: "cursor-pointer", children: t("templates.headerVariations.actionButtons") })
2715
+ ] }),
2716
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2717
+ /* @__PURE__ */ jsxRuntime.jsx(
2718
+ alertDialog.Switch,
2719
+ {
2720
+ id: "header-bread",
2721
+ checked: showHeaderBreadcrumbs,
2722
+ onCheckedChange: setShowHeaderBreadcrumbs
2723
+ }
2724
+ ),
2725
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "header-bread", className: "cursor-pointer", children: t("templates.headerVariations.breadcrumbsLabel") })
2726
+ ] })
2727
+ ] })
2728
+ ] }),
2729
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative border rounded-[var(--radius-lg)] bg-muted/10 overflow-hidden shadow-inner", children: [
2730
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "p-4 bg-background/50 border-b text-xs font-mono text-muted-foreground", children: t("templates.headerVariations.preview") }),
2731
+ /* @__PURE__ */ jsxRuntime.jsx(
2732
+ sidebar.Header,
2733
+ {
2734
+ title: !showHeaderBreadcrumbs ? t("templates.headerVariations.currentPage") : void 0,
2735
+ breadcrumbs: showHeaderBreadcrumbs ? [
2736
+ {
2737
+ label: t("templates.headerVariations.breadcrumbBrand"),
2738
+ href: "#",
2739
+ icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Home, { className: "w-4 h-4" })
2740
+ },
2741
+ {
2742
+ label: t("templates.headerVariations.breadcrumbSettings"),
2743
+ href: "#"
2744
+ },
2745
+ { label: t("templates.headerVariations.breadcrumbProfile") }
2746
+ ] : void 0,
2747
+ actions: showHeaderActions ? [
2748
+ {
2749
+ id: "notify",
2750
+ icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Bell, { className: "w-5 h-5" }),
2751
+ onClick: () => sonner.toast(t("templates.headerVariations.notificationsOpenedToast"))
2752
+ },
2753
+ {
2754
+ id: "mail",
2755
+ label: t("templates.headerVariations.messagesLabel"),
2756
+ icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Mail, { className: "w-5 h-5" }),
2757
+ onClick: () => sonner.toast(t("templates.headerVariations.messagesOpenedToast"))
2758
+ }
2759
+ ] : void 0
2760
+ }
2761
+ ),
2762
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-32 flex items-center justify-center text-muted-foreground text-sm italic", children: t("templates.headerVariations.contentArea") })
2763
+ ] })
2764
+ ] })
2765
+ ] })
2766
+ ] }),
2767
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, { className: "my-8" }),
2768
+ /* @__PURE__ */ jsxRuntime.jsxs("section", { children: [
2769
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-4", children: t("templates.sections.sidebarVariations") }),
2770
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { children: [
2771
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
2772
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.sidebar.title") }),
2773
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.sidebar.description") })
2774
+ ] }),
2775
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.Tabs, { defaultValue: "assistant", className: "w-full", children: [
2776
+ /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.TabsList, { className: "mb-4", children: [
2777
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsTrigger, { value: "assistant", children: t("templates.sidebar.assistantMode") }),
2778
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsTrigger, { value: "default", children: t("templates.sidebar.defaultMode") })
2779
+ ] }),
2780
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-6 p-4 border rounded-[var(--radius-lg)] bg-muted/30", children: [
2781
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "text-sm font-semibold mb-4", children: t("templates.sidebarControls.footerSettings") }),
2782
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap gap-6 mt-2", children: [
2783
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2784
+ /* @__PURE__ */ jsxRuntime.jsx(
2785
+ alertDialog.Switch,
2786
+ {
2787
+ id: "show-user",
2788
+ checked: showSidebarUser,
2789
+ onCheckedChange: setShowSidebarUser
2790
+ }
2791
+ ),
2792
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "show-user", className: "cursor-pointer", children: t("templates.sidebarControls.userProfile") })
2793
+ ] }),
2794
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2795
+ /* @__PURE__ */ jsxRuntime.jsx(
2796
+ alertDialog.Switch,
2797
+ {
2798
+ id: "show-settings",
2799
+ checked: showSidebarSettings,
2800
+ onCheckedChange: setShowSidebarSettings
2801
+ }
2802
+ ),
2803
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "show-settings", className: "cursor-pointer", children: t("templates.sidebarControls.settings") })
2804
+ ] }),
2805
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-2", children: [
2806
+ /* @__PURE__ */ jsxRuntime.jsx(
2807
+ alertDialog.Switch,
2808
+ {
2809
+ id: "show-logout",
2810
+ checked: showSidebarLogout,
2811
+ onCheckedChange: setShowSidebarLogout
2812
+ }
2813
+ ),
2814
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Label, { htmlFor: "show-logout", className: "cursor-pointer", children: t("templates.sidebarControls.logoutButton") })
2815
+ ] })
2816
+ ] }),
2817
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mt-6 pt-6 border-t", children: [
2818
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between mb-4", children: [
2819
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "text-sm font-semibold", children: t("templates.sidebarControls.sidebarWidthDesktop") }),
2820
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-xs font-mono bg-muted px-2 py-1 rounded", children: [
2821
+ sidebarWidth,
2822
+ "px"
2823
+ ] })
2824
+ ] }),
2825
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-4", children: [
2826
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs text-muted-foreground w-12 text-right", children: "240px" }),
2827
+ /* @__PURE__ */ jsxRuntime.jsx(
2828
+ slider.Slider,
2829
+ {
2830
+ value: [sidebarWidth],
2831
+ onValueChange: (val) => setSidebarWidth(val[0]),
2832
+ min: 240,
2833
+ max: 450,
2834
+ step: 10,
2835
+ className: "flex-1",
2836
+ "aria-label": t("templates.sidebarControls.sidebarWidthAriaLabel")
2837
+ }
2838
+ ),
2839
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs text-muted-foreground w-12", children: "450px" })
2840
+ ] })
2841
+ ] })
2842
+ ] }),
2843
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsContent, { value: "assistant", children: /* @__PURE__ */ jsxRuntime.jsxs(
2844
+ "div",
2845
+ {
2846
+ className: "relative h-[600px] border rounded-[var(--radius-lg)] bg-muted/20 overflow-hidden",
2847
+ style: { transform: "translateZ(0)" },
2848
+ children: [
2849
+ /* @__PURE__ */ jsxRuntime.jsx(
2850
+ sidebar.Sidebar,
2851
+ {
2852
+ expanded: true,
2853
+ width: sidebarWidth,
2854
+ onToggle: () => {
2855
+ },
2856
+ user: { email: "admin@xertica.com" },
2857
+ onLogout: () => sonner.toast(t("templates.sidebar.logoutToast")),
2858
+ location: { pathname: "/assistant/current" },
2859
+ navigate: () => {
2860
+ },
2861
+ variant: "assistant",
2862
+ search: {
2863
+ show: true,
2864
+ placeholder: t("templates.sidebar.searchTopicsPlaceholder"),
2865
+ filter: {
2866
+ show: true,
2867
+ content: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-2 space-y-2", children: [
2868
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-xs font-semibold uppercase text-muted-foreground px-2", children: t("templates.sidebarControls.filterByStatus") }),
2869
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap gap-2 p-1", children: [
2870
+ /* @__PURE__ */ jsxRuntime.jsx(progress.Badge, { className: "bg-sidebar-foreground/20 text-sidebar-foreground border-none cursor-pointer hover:bg-sidebar-foreground/30", children: t("templates.sidebarControls.filterActive") }),
2871
+ /* @__PURE__ */ jsxRuntime.jsx(
2872
+ progress.Badge,
2873
+ {
2874
+ variant: "outline",
2875
+ className: "text-sidebar-foreground/70 border-sidebar-foreground/20 cursor-pointer hover:bg-sidebar-foreground/10",
2876
+ children: t("templates.sidebarControls.filterArchived")
2877
+ }
2878
+ ),
2879
+ /* @__PURE__ */ jsxRuntime.jsx(
2880
+ progress.Badge,
2881
+ {
2882
+ variant: "outline",
2883
+ className: "text-sidebar-foreground/70 border-sidebar-foreground/20 cursor-pointer hover:bg-sidebar-foreground/10",
2884
+ children: t("templates.sidebarControls.filterPending")
2885
+ }
2886
+ )
2887
+ ] })
2888
+ ] })
2889
+ }
2890
+ },
2891
+ fixedArea: {
2892
+ show: true,
2893
+ content: /* @__PURE__ */ jsxRuntime.jsxs(button.Button, { className: "w-full bg-sidebar-primary hover:bg-sidebar-primary/90 text-sidebar-primary-foreground shadow-lg font-bold border-none transition-all duration-300 transform hover:scale-[1.02] active:scale-[0.98]", children: [
2894
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { className: "w-4 h-4 mr-2" }),
2895
+ t("templates.sidebar.newConversation")
2896
+ ] })
2897
+ },
2898
+ navigationGroups: [
2899
+ {
2900
+ id: "recent",
2901
+ label: t("templates.sidebar.recent"),
2902
+ icon: lucideReact.Clock,
2903
+ items: [
2904
+ {
2905
+ path: "/assistant/refatoracao",
2906
+ label: t("templates.sidebar.items.sidebarRefactor"),
2907
+ description: t(
2908
+ "templates.sidebar.items.sidebarRefactorDescription"
2909
+ ),
2910
+ actions: [
2911
+ {
2912
+ label: t("templates.sidebar.actions.rename"),
2913
+ icon: lucideReact.FileEdit,
2914
+ onClick: () => sonner.toast(t("templates.sidebar.actions.renameToast"))
2915
+ },
2916
+ {
2917
+ label: t("templates.sidebar.actions.move"),
2918
+ icon: lucideReact.ArrowRightLeft,
2919
+ children: [
2920
+ {
2921
+ label: t("templates.sidebar.actions.moveActive"),
2922
+ onClick: () => sonner.toast(t("templates.sidebar.actions.moveActiveToast"))
2923
+ },
2924
+ {
2925
+ label: t("templates.sidebar.actions.moveMonitoring"),
2926
+ onClick: () => sonner.toast(
2927
+ t("templates.sidebar.actions.moveMonitoringToast")
2928
+ )
2929
+ },
2930
+ {
2931
+ label: t("templates.sidebar.actions.moveArchive"),
2932
+ onClick: () => sonner.toast(
2933
+ t("templates.sidebar.actions.moveArchiveToast")
2934
+ )
2935
+ }
2936
+ ]
2937
+ },
2938
+ {
2939
+ label: t("templates.sidebar.actions.clear"),
2940
+ icon: lucideReact.Trash2,
2941
+ onClick: () => sonner.toast(t("templates.sidebar.actions.clearToast")),
2942
+ variant: "destructive"
2943
+ }
2944
+ ]
2945
+ }
2946
+ ]
2947
+ },
2948
+ {
2949
+ id: "projects",
2950
+ label: t("templates.sidebar.constructionMonitoring"),
2951
+ icon: lucideReact.Map,
2952
+ actions: [
2953
+ {
2954
+ label: t("templates.sidebar.actions.newCategory"),
2955
+ icon: lucideReact.Plus,
2956
+ onClick: () => sonner.toast(t("templates.sidebar.actions.newCategoryToast"))
2957
+ },
2958
+ {
2959
+ label: t("templates.sidebar.actions.archiveGroup"),
2960
+ icon: lucideReact.Archive,
2961
+ onClick: () => sonner.toast(t("templates.sidebar.actions.archiveGroupToast"))
2962
+ }
2963
+ ],
2964
+ items: [
2965
+ {
2966
+ path: "/assistant/br163",
2967
+ label: t("templates.sidebar.items.br163Restoration"),
2968
+ icon: () => /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-2 h-2 rounded-full bg-yellow-500" }),
2969
+ description: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1.5 min-w-[160px]", children: [
2970
+ /* @__PURE__ */ jsxRuntime.jsx(
2971
+ progress.Progress,
2972
+ {
2973
+ value: 67,
2974
+ className: "h-1.5 bg-sidebar-foreground/10"
2975
+ }
2976
+ ),
2977
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between items-center text-[10px] text-sidebar-foreground/60", children: [
2978
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: t("templates.sidebar.items.br163Location") }),
2979
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: "67%" })
2980
+ ] })
2981
+ ] })
2982
+ }
2983
+ ]
2984
+ }
2985
+ ],
2986
+ footer: {
2987
+ showUser: showSidebarUser,
2988
+ showSettings: showSidebarSettings,
2989
+ showLogout: showSidebarLogout
2990
+ }
2991
+ }
2992
+ ),
2993
+ /* @__PURE__ */ jsxRuntime.jsx(
2994
+ "div",
2995
+ {
2996
+ className: "absolute inset-y-0 right-0 p-8 flex items-center justify-center transition-all duration-300",
2997
+ style: { left: `${sidebarWidth}px` },
2998
+ children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-center", children: t("templates.sidebar.assistantContent") })
2999
+ }
3000
+ )
3001
+ ]
3002
+ }
3003
+ ) }),
3004
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.TabsContent, { value: "default", children: /* @__PURE__ */ jsxRuntime.jsxs(
3005
+ "div",
3006
+ {
3007
+ className: "relative h-[600px] border rounded-[var(--radius-lg)] bg-muted/20 overflow-hidden",
3008
+ style: { transform: "translateZ(0)" },
3009
+ children: [
3010
+ /* @__PURE__ */ jsxRuntime.jsx(
3011
+ sidebar.Sidebar,
3012
+ {
3013
+ expanded: true,
3014
+ width: sidebarWidth,
3015
+ onToggle: () => {
3016
+ },
3017
+ user: {
3018
+ name: "Ariel Santos",
3019
+ email: "admin@xertica.com",
3020
+ avatar: "https://github.com/shadcn.png"
3021
+ },
3022
+ onLogout: () => sonner.toast(t("templates.sidebar.logoutToast")),
3023
+ onSettingsClick: () => sonner.toast(t("templates.sidebar.settingsClickedToast")),
3024
+ location: { pathname: "/home" },
3025
+ navigate: () => {
3026
+ },
3027
+ variant: "default",
3028
+ routes: [
3029
+ {
3030
+ path: "/home",
3031
+ label: t("templates.sidebar.routes.home"),
3032
+ icon: lucideReact.Home
3033
+ },
3034
+ {
3035
+ path: "/dashboard",
3036
+ label: t("templates.sidebar.routes.dashboard"),
3037
+ icon: lucideReact.Users
3038
+ },
3039
+ {
3040
+ path: "/settings",
3041
+ label: t("templates.sidebar.routes.settings"),
3042
+ icon: lucideReact.Settings
3043
+ }
3044
+ ],
3045
+ footer: {
3046
+ showUser: showSidebarUser,
3047
+ showSettings: showSidebarSettings,
3048
+ showLogout: showSidebarLogout
3049
+ }
3050
+ }
3051
+ ),
3052
+ /* @__PURE__ */ jsxRuntime.jsx(
3053
+ "div",
3054
+ {
3055
+ className: "absolute inset-y-0 right-0 p-8 flex items-center justify-center transition-all duration-300",
3056
+ style: { left: `${sidebarWidth}px` },
3057
+ children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-center", children: t("templates.sidebar.defaultContent") })
3058
+ }
3059
+ )
3060
+ ]
3061
+ }
3062
+ ) })
3063
+ ] }) })
3064
+ ] })
3065
+ ] }),
3066
+ /* @__PURE__ */ jsxRuntime.jsx(alertDialog.Separator, { className: "my-8" }),
3067
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.Card, { className: "mt-8", children: [
3068
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardHeader, { children: [
3069
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardTitle, { children: t("templates.footer.title") }),
3070
+ /* @__PURE__ */ jsxRuntime.jsx(skeleton.CardDescription, { children: t("templates.footer.subtitle") })
3071
+ ] }),
3072
+ /* @__PURE__ */ jsxRuntime.jsxs(skeleton.CardContent, { className: "space-y-4", children: [
3073
+ /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-muted-foreground", children: [
3074
+ t("templates.footer.descriptionPart1"),
3075
+ /* @__PURE__ */ jsxRuntime.jsx("code", { className: "bg-muted px-2 py-1 rounded-[var(--radius-sm)] [font-size:var(--text-small)]", children: "xertica-ui" }),
3076
+ t("templates.footer.descriptionPart2")
3077
+ ] }),
3078
+ /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.Alert, { variant: "info", children: [
3079
+ /* @__PURE__ */ jsxRuntime.jsx(richTextEditor.AlertTitle, { children: t("templates.footer.tipTitle") }),
3080
+ /* @__PURE__ */ jsxRuntime.jsxs(richTextEditor.AlertDescription, { children: [
3081
+ t("templates.footer.tipDescriptionPart1"),
3082
+ /* @__PURE__ */ jsxRuntime.jsx("code", { className: "bg-muted px-1 rounded", children: "styles/xertica/tokens.css" }),
3083
+ t("templates.footer.tipDescriptionPart2")
3084
+ ] })
3085
+ ] })
3086
+ ] })
3087
+ ] })
3088
+ ] }) }) }) })
3089
+ ]
3090
+ }
3091
+ );
3092
+ }
3093
+
3094
+ function TemplatePage() {
3095
+ const { user, logout } = useAuth();
3096
+ const layout = LayoutContext.useOptionalLayout();
3097
+ const [localSidebarExpanded, setLocalSidebarExpanded] = React.useState(false);
3098
+ const [localAssistantExpanded, setLocalAssistantExpanded] = React.useState(false);
3099
+ const sidebarExpanded = layout?.sidebarExpanded ?? localSidebarExpanded;
3100
+ const sidebarWidth = layout?.sidebarWidth ?? 280;
3101
+ const assistenteExpanded = layout?.assistenteExpanded ?? localAssistantExpanded;
3102
+ const toggleSidebar = layout?.toggleSidebar ?? (() => setLocalSidebarExpanded((value) => !value));
3103
+ const toggleAssistente = layout?.toggleAssistente ?? (() => setLocalAssistantExpanded((value) => !value));
3104
+ const location = reactRouterDom.useLocation();
3105
+ const navigate = reactRouterDom.useNavigate();
3106
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-screen flex bg-muted overflow-hidden relative", children: [
3107
+ /* @__PURE__ */ jsxRuntime.jsx(
3108
+ sidebar.Sidebar,
3109
+ {
3110
+ expanded: sidebarExpanded,
3111
+ width: sidebarWidth,
3112
+ onToggle: toggleSidebar,
3113
+ user: {
3114
+ ...user,
3115
+ name: "Ariel Santos",
3116
+ avatar: "https://github.com/shadcn.png"
3117
+ },
3118
+ onLogout: logout,
3119
+ onSettingsClick: () => navigate("/settings"),
3120
+ location,
3121
+ navigate,
3122
+ routes
3123
+ }
3124
+ ),
3125
+ /* @__PURE__ */ jsxRuntime.jsx(TemplateContent, {}),
3126
+ /* @__PURE__ */ jsxRuntime.jsx(
3127
+ xerticaAssistant.XerticaAssistant,
3128
+ {
3129
+ isExpanded: assistenteExpanded,
3130
+ onToggle: toggleAssistente,
3131
+ onEvaluation: () => {
3132
+ }
3133
+ }
3134
+ )
3135
+ ] });
3136
+ }
3137
+
3138
+ function VerifyEmailPage() {
3139
+ const navigate = reactRouterDom.useNavigate();
3140
+ const location = reactRouterDom.useLocation();
3141
+ const { t } = reactI18next.useTranslation();
3142
+ const email = location.state?.email || "your@email.com";
3143
+ const [isResending, setIsResending] = React.useState(false);
3144
+ const [resendSuccess, setResendSuccess] = React.useState(false);
3145
+ const handleResend = async () => {
3146
+ setIsResending(true);
3147
+ setResendSuccess(false);
3148
+ await new Promise((resolve) => setTimeout(resolve, 1500));
3149
+ setIsResending(false);
3150
+ setResendSuccess(true);
3151
+ setTimeout(() => setResendSuccess(false), 3e3);
3152
+ };
3153
+ const handleSocialLogin = (_provider) => {
3154
+ };
3155
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-screen w-full flex overflow-y-auto", children: [
3156
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "hidden lg:flex lg:flex-1 relative overflow-hidden", children: [
3157
+ /* @__PURE__ */ jsxRuntime.jsx(
3158
+ alertDialog.ImageWithFallback,
3159
+ {
3160
+ src: "https://images.unsplash.com/photo-1563986768609-322da13575f3?w=1200&h=800&fit=crop&auto=format",
3161
+ alt: t("verifyEmail.heroImageAlt"),
3162
+ className: "absolute inset-0 w-full h-full object-cover"
3163
+ }
3164
+ ),
3165
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 bg-[image:var(--gradient-diagonal)] opacity-80" })
3166
+ ] }),
3167
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 flex items-center justify-center px-4 sm:px-6 lg:px-8 lg:flex-none lg:w-1/2 relative bg-muted", children: [
3168
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute top-4 right-4 z-20", children: /* @__PURE__ */ jsxRuntime.jsx(XerticaXLogo.LanguageSelector, { variant: "minimal", showIcon: false }) }),
3169
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 lg:hidden bg-[image:var(--gradient-diagonal)] opacity-10 dark:opacity-5" }),
3170
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full max-w-sm space-y-6 relative z-10", children: [
3171
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center", children: [
3172
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center mb-4", children: /* @__PURE__ */ jsxRuntime.jsx(
3173
+ XerticaXLogo.XerticaLogo,
3174
+ {
3175
+ className: "h-12 w-auto text-primary dark:text-foreground",
3176
+ variant: "theme"
3177
+ }
3178
+ ) }),
3179
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center mb-4", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "p-4 bg-primary/10 rounded-[var(--radius)]", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Mail, { className: "w-12 h-12 text-primary" }) }) }),
3180
+ /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-sm text-muted-foreground", children: t("verifyEmail.heading") }),
3181
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-2 text-muted-foreground", children: t("verifyEmail.instructionsSent") }),
3182
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-1 text-primary", children: email })
3183
+ ] }),
3184
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-accent rounded-[var(--radius)] p-4 space-y-3", children: [
3185
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: t("verifyEmail.instructions") }),
3186
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-2 text-muted-foreground", children: [
3187
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.CheckCircle2, { className: "w-4 h-4 mt-0.5 flex-shrink-0 text-[var(--chart-2)]" }),
3188
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: t("verifyEmail.checkSpam") })
3189
+ ] })
3190
+ ] }),
3191
+ resendSuccess && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-[var(--chart-2)]/10 border border-[var(--chart-2)]/20 rounded-[var(--radius)] p-3 flex items-center gap-2", children: [
3192
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.CheckCircle2, { className: "w-5 h-5 text-[var(--chart-2)] flex-shrink-0" }),
3193
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-[var(--chart-2)]", children: t("verifyEmail.resentSuccess") })
3194
+ ] }),
3195
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
3196
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-center text-muted-foreground", children: t("verifyEmail.notReceived") }),
3197
+ /* @__PURE__ */ jsxRuntime.jsx(
3198
+ button.Button,
3199
+ {
3200
+ variant: "outline",
3201
+ className: "w-full",
3202
+ onClick: handleResend,
3203
+ disabled: isResending,
3204
+ children: isResending ? t("verifyEmail.resending") : t("verifyEmail.resend")
3205
+ }
3206
+ ),
3207
+ /* @__PURE__ */ jsxRuntime.jsxs(
3208
+ button.Button,
3209
+ {
3210
+ type: "button",
3211
+ onClick: () => navigate("/login"),
3212
+ variant: "outline",
3213
+ className: "w-full text-muted-foreground hover:text-foreground",
3214
+ children: [
3215
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowLeft, { className: "w-4 h-4 mr-2" }),
3216
+ t("verifyEmail.backToLogin")
3217
+ ]
3218
+ }
3219
+ )
3220
+ ] }),
3221
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
3222
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 flex items-center", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full border-t border-border" }) }),
3223
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative flex justify-center text-sm", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "bg-muted px-2 text-muted-foreground", children: t("login.orContinueWith") }) })
3224
+ ] }),
3225
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
3226
+ /* @__PURE__ */ jsxRuntime.jsxs(
3227
+ button.Button,
3228
+ {
3229
+ type: "button",
3230
+ variant: "outline",
3231
+ className: "w-full justify-center",
3232
+ onClick: () => handleSocialLogin(),
3233
+ children: [
3234
+ /* @__PURE__ */ jsxRuntime.jsxs("svg", { className: "w-5 h-5 mr-2", viewBox: "0 0 48 48", xmlns: "http://www.w3.org/2000/svg", children: [
3235
+ /* @__PURE__ */ jsxRuntime.jsx(
3236
+ "path",
3237
+ {
3238
+ fill: "#EA4335",
3239
+ d: "M24 9.5c3.54 0 6.71 1.22 9.21 3.6l6.85-6.85C35.9 2.38 30.47 0 24 0 14.62 0 6.51 5.38 2.56 13.22l7.98 6.19C12.43 13.72 17.74 9.5 24 9.5z"
3240
+ }
3241
+ ),
3242
+ /* @__PURE__ */ jsxRuntime.jsx(
3243
+ "path",
3244
+ {
3245
+ fill: "#4285F4",
3246
+ d: "M46.98 24.55c0-1.57-.15-3.09-.38-4.55H24v9.02h12.94c-.58 2.96-2.26 5.48-4.78 7.18l7.73 6c4.51-4.18 7.09-10.36 7.09-17.65z"
3247
+ }
3248
+ ),
3249
+ /* @__PURE__ */ jsxRuntime.jsx(
3250
+ "path",
3251
+ {
3252
+ fill: "#FBBC05",
3253
+ d: "M10.53 28.59c-.48-1.45-.76-2.99-.76-4.59s.27-3.14.76-4.59l-7.98-6.19C.92 16.46 0 20.12 0 24c0 3.88.92 7.54 2.56 10.78l7.97-6.19z"
3254
+ }
3255
+ ),
3256
+ /* @__PURE__ */ jsxRuntime.jsx(
3257
+ "path",
3258
+ {
3259
+ fill: "#34A853",
3260
+ d: "M24 48c6.48 0 11.93-2.13 15.89-5.81l-7.73-6c-2.15 1.45-4.92 2.3-8.16 2.3-6.26 0-11.57-4.22-13.47-9.91l-7.98 6.19C6.51 42.62 14.62 48 24 48z"
3261
+ }
3262
+ ),
3263
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "none", d: "M0 0h48v48H0z" })
3264
+ ] }),
3265
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: t("login.signInWithGoogle") })
3266
+ ]
3267
+ }
3268
+ ),
3269
+ /* @__PURE__ */ jsxRuntime.jsxs(
3270
+ button.Button,
3271
+ {
3272
+ type: "button",
3273
+ variant: "outline",
3274
+ className: "w-full justify-center",
3275
+ onClick: () => handleSocialLogin(),
3276
+ children: [
3277
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Lock, { className: "w-5 h-5 mr-2 text-[var(--chart-4)]" }),
3278
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: t("login.signInWithMTLogin") })
3279
+ ]
3280
+ }
3281
+ ),
3282
+ /* @__PURE__ */ jsxRuntime.jsx(
3283
+ button.Button,
3284
+ {
3285
+ type: "button",
3286
+ variant: "outline",
3287
+ className: "w-full justify-center font-normal",
3288
+ onClick: () => handleSocialLogin(),
3289
+ children: /* @__PURE__ */ jsxRuntime.jsx("span", { children: t("login.signInWithGovBr") })
3290
+ }
3291
+ )
3292
+ ] })
3293
+ ] })
3294
+ ] })
3295
+ ] });
3296
+ }
3297
+
3298
+ exports.ForgotPasswordPage = ForgotPasswordPage;
3299
+ exports.HomeContent = HomeContent;
3300
+ exports.HomePage = HomePage;
3301
+ exports.LoginPage = LoginPage;
3302
+ exports.ResetPasswordPage = ResetPasswordPage;
3303
+ exports.TemplateContent = TemplateContent;
3304
+ exports.TemplatePage = TemplatePage;
3305
+ exports.VerifyEmailPage = VerifyEmailPage;