xertica-ui 2.7.0 → 2.9.6

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