xertica-ui 2.5.3 → 2.7.0

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