@giddaa-housing/ui 0.1.0 → 1.1.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 (315) hide show
  1. package/README.md +18 -6
  2. package/css/base.css +37 -0
  3. package/css/components.css +135 -0
  4. package/css/generated/shared.css +1 -0
  5. package/css/giddaa.css +402 -0
  6. package/css/preset.css +77 -0
  7. package/css/styles.css +2 -0
  8. package/css/theme.css +255 -0
  9. package/dist/accordion.d.ts +9 -10
  10. package/dist/accordion.js +41 -117
  11. package/dist/activity-timeline.d.ts +29 -0
  12. package/dist/activity-timeline.js +97 -0
  13. package/dist/alert.d.ts +8 -9
  14. package/dist/alert.js +53 -141
  15. package/dist/auth-layout.d.ts +23 -0
  16. package/dist/auth-layout.js +153 -0
  17. package/dist/avatar.d.ts +6 -6
  18. package/dist/avatar.js +40 -142
  19. package/dist/badge.d.ts +12 -13
  20. package/dist/badge.js +66 -114
  21. package/dist/bar-chart.d.ts +136 -114
  22. package/dist/bar-chart.js +244 -297
  23. package/dist/breadcrumb.d.ts +5 -5
  24. package/dist/breadcrumb.js +56 -148
  25. package/dist/bullet-chart.d.ts +33 -33
  26. package/dist/bullet-chart.js +123 -183
  27. package/dist/button-BZIeyUw6.d.ts +17 -0
  28. package/dist/button-group.d.ts +13 -16
  29. package/dist/button-group.js +38 -163
  30. package/dist/button.d.ts +2 -19
  31. package/dist/button.js +90 -142
  32. package/dist/calendar.d.ts +6 -6
  33. package/dist/calendar.js +134 -288
  34. package/dist/card.d.ts +14 -16
  35. package/dist/card.js +58 -174
  36. package/dist/carousel.d.ts +34 -35
  37. package/dist/carousel.js +319 -378
  38. package/dist/chart.d.ts +58 -59
  39. package/dist/chart.js +350 -466
  40. package/dist/checkbox.d.ts +10 -12
  41. package/dist/checkbox.js +84 -84
  42. package/dist/cn-BI_4DMBf.js +23 -0
  43. package/dist/collapsible.d.ts +7 -8
  44. package/dist/collapsible.js +23 -77
  45. package/dist/combobox.d.ts +10 -10
  46. package/dist/combobox.js +220 -696
  47. package/dist/cta.d.ts +64 -0
  48. package/dist/cta.js +192 -0
  49. package/dist/currency-selector.d.ts +41 -0
  50. package/dist/currency-selector.js +114 -0
  51. package/dist/data-table.d.ts +164 -0
  52. package/dist/data-table.js +673 -0
  53. package/dist/date-picker.d.ts +27 -20
  54. package/dist/date-picker.js +122 -520
  55. package/dist/details-card.d.ts +19 -0
  56. package/dist/details-card.js +118 -0
  57. package/dist/dialog.d.ts +13 -14
  58. package/dist/dialog.js +117 -320
  59. package/dist/dropdown-menu.d.ts +14 -14
  60. package/dist/dropdown-menu.js +170 -365
  61. package/dist/dropzone.d.ts +55 -55
  62. package/dist/dropzone.js +328 -467
  63. package/dist/editorial-card.d.ts +27 -0
  64. package/dist/editorial-card.js +144 -0
  65. package/dist/empty-state.d.ts +8 -9
  66. package/dist/empty-state.js +48 -135
  67. package/dist/field.d.ts +23 -25
  68. package/dist/field.js +111 -327
  69. package/dist/filter.d.ts +118 -0
  70. package/dist/filter.js +775 -0
  71. package/dist/footer.d.ts +40 -0
  72. package/dist/footer.js +227 -0
  73. package/dist/funnel-chart.d.ts +38 -41
  74. package/dist/funnel-chart.js +168 -563
  75. package/dist/gallery-indicator.d.ts +17 -0
  76. package/dist/gallery-indicator.js +75 -0
  77. package/dist/heatmap-chart.d.ts +95 -0
  78. package/dist/heatmap-chart.js +197 -0
  79. package/dist/infotip.d.ts +10 -0
  80. package/dist/infotip.js +40 -0
  81. package/dist/input-CfoEJ8A6.d.ts +12 -0
  82. package/dist/input-group.d.ts +16 -19
  83. package/dist/input-group.js +92 -372
  84. package/dist/input-size-context-C-SFx9sx.d.ts +10 -0
  85. package/dist/input-size-context.d.ts +2 -11
  86. package/dist/input-size-context.js +14 -20
  87. package/dist/input.d.ts +2 -13
  88. package/dist/input.js +23 -79
  89. package/dist/item.d.ts +7 -8
  90. package/dist/item.js +22 -89
  91. package/dist/kpi-card.d.ts +18 -20
  92. package/dist/kpi-card.js +84 -232
  93. package/dist/label.d.ts +6 -6
  94. package/dist/label.js +39 -66
  95. package/dist/line-chart.d.ts +88 -89
  96. package/dist/line-chart.js +143 -262
  97. package/dist/logo.d.ts +4 -4
  98. package/dist/logo.js +87 -141
  99. package/dist/map-indicator.d.ts +13 -0
  100. package/dist/map-indicator.js +83 -0
  101. package/dist/match.d.ts +15 -0
  102. package/dist/match.js +68 -0
  103. package/dist/media-gallery-hero.d.ts +58 -0
  104. package/dist/media-gallery-hero.js +201 -0
  105. package/dist/media-player.d.ts +60 -0
  106. package/dist/media-player.js +919 -0
  107. package/dist/multi-step-form.d.ts +56 -0
  108. package/dist/multi-step-form.js +342 -0
  109. package/dist/number-input.d.ts +34 -34
  110. package/dist/number-input.js +62 -413
  111. package/dist/page-header.d.ts +10 -11
  112. package/dist/page-header.js +34 -107
  113. package/dist/pagination.d.ts +17 -20
  114. package/dist/pagination.js +132 -341
  115. package/dist/password-input.d.ts +5 -12
  116. package/dist/password-input.js +32 -354
  117. package/dist/phone-input.d.ts +19 -19
  118. package/dist/phone-input.js +232 -561
  119. package/dist/photo-gallery.d.ts +20 -20
  120. package/dist/photo-gallery.js +314 -746
  121. package/dist/picker-lzgmsNfG.js +32 -0
  122. package/dist/pie-chart.d.ts +60 -60
  123. package/dist/pie-chart.js +141 -184
  124. package/dist/popover.d.ts +9 -9
  125. package/dist/popover.js +60 -156
  126. package/dist/price-tag.d.ts +34 -0
  127. package/dist/price-tag.js +118 -0
  128. package/dist/progress.d.ts +18 -16
  129. package/dist/progress.js +156 -300
  130. package/dist/property-listing-card.d.ts +29 -0
  131. package/dist/property-listing-card.js +117 -0
  132. package/dist/radar-chart.d.ts +108 -0
  133. package/dist/radar-chart.js +172 -0
  134. package/dist/radio-group.d.ts +11 -13
  135. package/dist/radio-group.js +47 -96
  136. package/dist/review-block.d.ts +18 -0
  137. package/dist/review-block.js +154 -0
  138. package/dist/rich-text-editor.d.ts +30 -14
  139. package/dist/rich-text-editor.js +594 -979
  140. package/dist/scatter-chart.d.ts +140 -0
  141. package/dist/scatter-chart.js +248 -0
  142. package/dist/search-input.d.ts +8 -15
  143. package/dist/search-input.js +58 -408
  144. package/dist/select.d.ts +8 -8
  145. package/dist/select.js +131 -291
  146. package/dist/separator.d.ts +8 -9
  147. package/dist/separator.js +31 -70
  148. package/dist/sheet.d.ts +11 -11
  149. package/dist/sheet.js +84 -262
  150. package/dist/sidebar.d.ts +32 -37
  151. package/dist/sidebar.js +380 -1055
  152. package/dist/size-context-D4mYvcg8.d.ts +10 -0
  153. package/dist/size-context.d.ts +2 -11
  154. package/dist/size-context.js +14 -18
  155. package/dist/skeleton.d.ts +4 -5
  156. package/dist/skeleton.js +9 -45
  157. package/dist/slider.d.ts +27 -0
  158. package/dist/slider.js +81 -0
  159. package/dist/sparkline.d.ts +43 -46
  160. package/dist/sparkline.js +223 -561
  161. package/dist/stepper.d.ts +23 -24
  162. package/dist/stepper.js +149 -276
  163. package/dist/styles.css +9995 -2
  164. package/dist/switch.d.ts +10 -12
  165. package/dist/switch.js +49 -106
  166. package/dist/table-card.d.ts +35 -0
  167. package/dist/table-card.js +125 -0
  168. package/dist/table.d.ts +18 -14
  169. package/dist/table.js +114 -182
  170. package/dist/tabs.d.ts +23 -15
  171. package/dist/tabs.js +62 -149
  172. package/dist/tag.d.ts +22 -23
  173. package/dist/tag.js +104 -156
  174. package/dist/testimonial-block.d.ts +33 -0
  175. package/dist/testimonial-block.js +208 -0
  176. package/dist/textarea-IS_D8pXf.d.ts +11 -0
  177. package/dist/textarea.d.ts +2 -12
  178. package/dist/textarea.js +20 -74
  179. package/dist/time-picker.d.ts +11 -11
  180. package/dist/time-picker.js +247 -464
  181. package/dist/toast.d.ts +16 -18
  182. package/dist/toast.js +154 -310
  183. package/dist/tooltip.d.ts +9 -10
  184. package/dist/tooltip.js +33 -91
  185. package/dist/tree-map.d.ts +54 -57
  186. package/dist/tree-map.js +231 -646
  187. package/dist/use-uncontrolled-CLfM1XbB.js +21 -0
  188. package/dist/waterfall-chart.d.ts +126 -0
  189. package/dist/waterfall-chart.js +480 -0
  190. package/package.json +123 -34
  191. package/dist/accordion.js.map +0 -1
  192. package/dist/alert.js.map +0 -1
  193. package/dist/avatar.js.map +0 -1
  194. package/dist/badge.js.map +0 -1
  195. package/dist/bar-chart.js.map +0 -1
  196. package/dist/base.css +0 -32
  197. package/dist/breadcrumb.js.map +0 -1
  198. package/dist/bullet-chart.js.map +0 -1
  199. package/dist/button-group.js.map +0 -1
  200. package/dist/button.js.map +0 -1
  201. package/dist/calendar.js.map +0 -1
  202. package/dist/card.js.map +0 -1
  203. package/dist/carousel.js.map +0 -1
  204. package/dist/chart.js.map +0 -1
  205. package/dist/checkbox.js.map +0 -1
  206. package/dist/collapsible.js.map +0 -1
  207. package/dist/combobox.js.map +0 -1
  208. package/dist/date-picker.js.map +0 -1
  209. package/dist/dialog.js.map +0 -1
  210. package/dist/dropdown-menu.js.map +0 -1
  211. package/dist/dropzone.js.map +0 -1
  212. package/dist/empty-state.js.map +0 -1
  213. package/dist/field.js.map +0 -1
  214. package/dist/files/red-hat-display-latin-300-italic.woff +0 -0
  215. package/dist/files/red-hat-display-latin-300-italic.woff2 +0 -0
  216. package/dist/files/red-hat-display-latin-300-normal.woff +0 -0
  217. package/dist/files/red-hat-display-latin-300-normal.woff2 +0 -0
  218. package/dist/files/red-hat-display-latin-400-italic.woff +0 -0
  219. package/dist/files/red-hat-display-latin-400-italic.woff2 +0 -0
  220. package/dist/files/red-hat-display-latin-400-normal.woff +0 -0
  221. package/dist/files/red-hat-display-latin-400-normal.woff2 +0 -0
  222. package/dist/files/red-hat-display-latin-500-italic.woff +0 -0
  223. package/dist/files/red-hat-display-latin-500-italic.woff2 +0 -0
  224. package/dist/files/red-hat-display-latin-500-normal.woff +0 -0
  225. package/dist/files/red-hat-display-latin-500-normal.woff2 +0 -0
  226. package/dist/files/red-hat-display-latin-600-italic.woff +0 -0
  227. package/dist/files/red-hat-display-latin-600-italic.woff2 +0 -0
  228. package/dist/files/red-hat-display-latin-600-normal.woff +0 -0
  229. package/dist/files/red-hat-display-latin-600-normal.woff2 +0 -0
  230. package/dist/files/red-hat-display-latin-700-italic.woff +0 -0
  231. package/dist/files/red-hat-display-latin-700-italic.woff2 +0 -0
  232. package/dist/files/red-hat-display-latin-700-normal.woff +0 -0
  233. package/dist/files/red-hat-display-latin-700-normal.woff2 +0 -0
  234. package/dist/files/red-hat-display-latin-800-italic.woff +0 -0
  235. package/dist/files/red-hat-display-latin-800-italic.woff2 +0 -0
  236. package/dist/files/red-hat-display-latin-800-normal.woff +0 -0
  237. package/dist/files/red-hat-display-latin-800-normal.woff2 +0 -0
  238. package/dist/files/red-hat-display-latin-900-italic.woff +0 -0
  239. package/dist/files/red-hat-display-latin-900-italic.woff2 +0 -0
  240. package/dist/files/red-hat-display-latin-900-normal.woff +0 -0
  241. package/dist/files/red-hat-display-latin-900-normal.woff2 +0 -0
  242. package/dist/files/red-hat-display-latin-ext-300-italic.woff +0 -0
  243. package/dist/files/red-hat-display-latin-ext-300-italic.woff2 +0 -0
  244. package/dist/files/red-hat-display-latin-ext-300-normal.woff +0 -0
  245. package/dist/files/red-hat-display-latin-ext-300-normal.woff2 +0 -0
  246. package/dist/files/red-hat-display-latin-ext-400-italic.woff +0 -0
  247. package/dist/files/red-hat-display-latin-ext-400-italic.woff2 +0 -0
  248. package/dist/files/red-hat-display-latin-ext-400-normal.woff +0 -0
  249. package/dist/files/red-hat-display-latin-ext-400-normal.woff2 +0 -0
  250. package/dist/files/red-hat-display-latin-ext-500-italic.woff +0 -0
  251. package/dist/files/red-hat-display-latin-ext-500-italic.woff2 +0 -0
  252. package/dist/files/red-hat-display-latin-ext-500-normal.woff +0 -0
  253. package/dist/files/red-hat-display-latin-ext-500-normal.woff2 +0 -0
  254. package/dist/files/red-hat-display-latin-ext-600-italic.woff +0 -0
  255. package/dist/files/red-hat-display-latin-ext-600-italic.woff2 +0 -0
  256. package/dist/files/red-hat-display-latin-ext-600-normal.woff +0 -0
  257. package/dist/files/red-hat-display-latin-ext-600-normal.woff2 +0 -0
  258. package/dist/files/red-hat-display-latin-ext-700-italic.woff +0 -0
  259. package/dist/files/red-hat-display-latin-ext-700-italic.woff2 +0 -0
  260. package/dist/files/red-hat-display-latin-ext-700-normal.woff +0 -0
  261. package/dist/files/red-hat-display-latin-ext-700-normal.woff2 +0 -0
  262. package/dist/files/red-hat-display-latin-ext-800-italic.woff +0 -0
  263. package/dist/files/red-hat-display-latin-ext-800-italic.woff2 +0 -0
  264. package/dist/files/red-hat-display-latin-ext-800-normal.woff +0 -0
  265. package/dist/files/red-hat-display-latin-ext-800-normal.woff2 +0 -0
  266. package/dist/files/red-hat-display-latin-ext-900-italic.woff +0 -0
  267. package/dist/files/red-hat-display-latin-ext-900-italic.woff2 +0 -0
  268. package/dist/files/red-hat-display-latin-ext-900-normal.woff +0 -0
  269. package/dist/files/red-hat-display-latin-ext-900-normal.woff2 +0 -0
  270. package/dist/funnel-chart.js.map +0 -1
  271. package/dist/index.d.ts +0 -87
  272. package/dist/index.js +0 -10448
  273. package/dist/index.js.map +0 -1
  274. package/dist/input-group.js.map +0 -1
  275. package/dist/input-size-context.js.map +0 -1
  276. package/dist/input.js.map +0 -1
  277. package/dist/item.js.map +0 -1
  278. package/dist/kpi-card.js.map +0 -1
  279. package/dist/label.js.map +0 -1
  280. package/dist/line-chart.js.map +0 -1
  281. package/dist/logo.js.map +0 -1
  282. package/dist/number-input.js.map +0 -1
  283. package/dist/page-header.js.map +0 -1
  284. package/dist/pagination.js.map +0 -1
  285. package/dist/password-input.js.map +0 -1
  286. package/dist/phone-input.js.map +0 -1
  287. package/dist/photo-gallery.js.map +0 -1
  288. package/dist/pie-chart.js.map +0 -1
  289. package/dist/popover.js.map +0 -1
  290. package/dist/progress.js.map +0 -1
  291. package/dist/radio-group.js.map +0 -1
  292. package/dist/red-hat-display.css +0 -2
  293. package/dist/rich-text-editor.js.map +0 -1
  294. package/dist/search-input.js.map +0 -1
  295. package/dist/select.js.map +0 -1
  296. package/dist/separator.js.map +0 -1
  297. package/dist/sheet.js.map +0 -1
  298. package/dist/sidebar.js.map +0 -1
  299. package/dist/size-context.js.map +0 -1
  300. package/dist/skeleton.js.map +0 -1
  301. package/dist/sparkline.js.map +0 -1
  302. package/dist/stepper.js.map +0 -1
  303. package/dist/switch.js.map +0 -1
  304. package/dist/tab-list.d.ts +0 -38
  305. package/dist/tab-list.js +0 -394
  306. package/dist/tab-list.js.map +0 -1
  307. package/dist/table.js.map +0 -1
  308. package/dist/tabs.js.map +0 -1
  309. package/dist/tag.js.map +0 -1
  310. package/dist/textarea.js.map +0 -1
  311. package/dist/theme/giddaa.css +0 -2
  312. package/dist/time-picker.js.map +0 -1
  313. package/dist/toast.js.map +0 -1
  314. package/dist/tooltip.js.map +0 -1
  315. package/dist/tree-map.js.map +0 -1
package/dist/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/components/ui/accordion.tsx","../src/lib/cn.ts","../src/components/ui/alert.tsx","../src/components/ui/avatar.tsx","../src/components/ui/badge.tsx","../src/components/ui/size-context.tsx","../src/components/ui/chart.tsx","../src/components/ui/bar-chart.tsx","../src/components/ui/breadcrumb.tsx","../src/components/ui/bullet-chart.tsx","../src/components/ui/button.tsx","../src/components/ui/button-group.tsx","../src/components/ui/separator.tsx","../src/components/ui/calendar.tsx","../src/components/ui/card.tsx","../src/components/ui/carousel.tsx","../src/components/ui/checkbox.tsx","../src/components/ui/collapsible.tsx","../src/components/ui/combobox.tsx","../src/components/ui/input-group.tsx","../src/components/ui/input.tsx","../src/components/ui/input-size-context.tsx","../src/components/ui/textarea.tsx","../src/components/ui/date-picker.tsx","../src/components/ui/popover.tsx","../src/components/ui/dialog.tsx","../src/components/ui/dropdown-menu.tsx","../src/components/ui/dropzone.tsx","../src/lib/use-file-picker.ts","../src/components/ui/empty-state.tsx","../src/components/ui/field.tsx","../src/components/ui/label.tsx","../src/components/ui/funnel-chart.tsx","../src/components/ui/item.tsx","../src/components/ui/kpi-card.tsx","../src/components/ui/skeleton.tsx","../src/components/ui/line-chart.tsx","../src/components/ui/number-input.tsx","../src/components/ui/page-header.tsx","../src/components/ui/pagination.tsx","../src/components/ui/password-input.tsx","../src/components/ui/phone-input.tsx","../src/components/ui/photo-gallery.tsx","../src/components/ui/pie-chart.tsx","../src/components/ui/progress.tsx","../src/components/ui/radio-group.tsx","../src/components/ui/rich-text-editor.tsx","../src/components/ui/search-input.tsx","../src/components/ui/select.tsx","../src/components/ui/sheet.tsx","../src/components/ui/sidebar.tsx","../src/lib/use-mobile.ts","../src/lib/use-uncontrolled.ts","../src/components/ui/tooltip.tsx","../src/components/ui/sparkline.tsx","../src/components/ui/stepper.tsx","../src/components/ui/switch.tsx","../src/components/ui/tab-list.tsx","../src/components/ui/tabs.tsx","../src/components/ui/table.tsx","../src/components/ui/tag.tsx","../src/components/ui/time-picker.tsx","../src/components/ui/toast.tsx","../src/components/ui/tree-map.tsx"],"sourcesContent":["import { Accordion as AccordionPrimitive } from \"@base-ui/react/accordion\";\nimport { ChevronRightIcon } from \"lucide-react\";\n\nimport { cn } from \"../../lib/cn\";\n\nfunction Accordion({\n\tclassName,\n\tvariant = \"surface\",\n\t...props\n}: AccordionPrimitive.Root.Props & { variant?: \"surface\" | \"ghost\" }) {\n\treturn (\n\t\t<AccordionPrimitive.Root\n\t\t\tdata-slot=\"accordion\"\n\t\t\tdata-variant={variant}\n\t\t\tclassName={cn(\"group/accordion flex w-full flex-col gap-3\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AccordionItem({ className, ...props }: AccordionPrimitive.Item.Props) {\n\treturn (\n\t\t<AccordionPrimitive.Item\n\t\t\tdata-slot=\"accordion-item\"\n\t\t\tclassName={cn(\n\t\t\t\t\"rounded-xl border border-line-subtle text-fg-primary transition-[background-color,border-color,box-shadow] group-data-[variant=surface]/accordion:bg-surface\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AccordionTrigger({\n\tclassName,\n\tchildren,\n\t...props\n}: AccordionPrimitive.Trigger.Props) {\n\treturn (\n\t\t<AccordionPrimitive.Header data-slot=\"accordion-header\" className=\"flex\">\n\t\t\t<AccordionPrimitive.Trigger\n\t\t\t\tdata-slot=\"accordion-trigger\"\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"group/accordion-trigger flex w-full items-center gap-3 px-4 sm:px-5 py-5.5 aria-expanded:pb-2 text-left text-gdt-md font-semibold text-fg-primary outline-none transition-[padding] aria-disabled:pointer-events-none aria-disabled:opacity-50\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t<ChevronRightIcon\n\t\t\t\t\tdata-slot=\"accordion-trigger-icon\"\n\t\t\t\t\tclassName=\"pointer-events-none size-5 shrink-0 text-fg-primary transition-transform duration-200 ease-out group-aria-expanded/accordion-trigger:rotate-90\"\n\t\t\t\t/>\n\t\t\t\t{children}\n\t\t\t</AccordionPrimitive.Trigger>\n\t\t</AccordionPrimitive.Header>\n\t);\n}\n\nfunction AccordionContent({\n\tclassName,\n\tchildren,\n\t...props\n}: AccordionPrimitive.Panel.Props) {\n\treturn (\n\t\t<AccordionPrimitive.Panel\n\t\t\tdata-slot=\"accordion-content\"\n\t\t\tclassName=\"overflow-hidden h-(--accordion-panel-height) transition-[height] ease-out data-ending-style:h-0 data-starting-style:h-0\"\n\t\t\t{...props}\n\t\t>\n\t\t\t<div\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\" pl-12 sm:pl-13 pr-4 sm:pr-5 pt-0 pb-4 sm:pb-5.5 text-fg-secondary text-gdt-md [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</div>\n\t\t</AccordionPrimitive.Panel>\n\t);\n}\n\nexport { Accordion, AccordionItem, AccordionTrigger, AccordionContent };\n","import { type ClassValue, clsx } from \"clsx\";\nimport { extendTailwindMerge } from \"tailwind-merge\";\n\nconst twMerge = extendTailwindMerge({\n\textend: {\n\t\tclassGroups: {\n\t\t\t\"font-size\": [\n\t\t\t\t{\n\t\t\t\t\ttext: [\n\t\t\t\t\t\t\"gdt-display\",\n\t\t\t\t\t\t\"gdt-h1\",\n\t\t\t\t\t\t\"gdt-h2\",\n\t\t\t\t\t\t\"gdt-h3\",\n\t\t\t\t\t\t\"gdt-h4\",\n\t\t\t\t\t\t\"gdt-h5\",\n\t\t\t\t\t\t\"gdt-xl\",\n\t\t\t\t\t\t\"gdt-lg\",\n\t\t\t\t\t\t\"gdt-md\",\n\t\t\t\t\t\t\"gdt-sm\",\n\t\t\t\t\t\t\"gdt-xs\",\n\t\t\t\t\t\t\"gdt-subtext\",\n\t\t\t\t\t\t\"gdt-capitalized\",\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t],\n\t\t},\n\t},\n});\n\nexport function cn(...inputs: ClassValue[]) {\n\treturn twMerge(clsx(inputs));\n}\n","import { cva, type VariantProps } from \"class-variance-authority\";\nimport { X } from \"lucide-react\";\nimport type * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\n\nconst alertVariants = cva(\n\t\"grid w-full grid-cols-[0_minmax(0,1fr)_auto] items-start gap-y-1 rounded-xl border-2 px-4 py-3.5 text-gdt-sm transition-[background-color,border-color,color,box-shadow] has-[>svg]:grid-cols-[1.25rem_minmax(0,1fr)_auto] has-[>svg]:gap-x-3 [&>svg]:col-start-1 [&>svg]:row-span-2 [&>svg]:mt-0.5 [&>svg]:size-5 [&>svg]:text-current\",\n\t{\n\t\tvariants: {\n\t\t\tvariant: {\n\t\t\t\tsuccess:\n\t\t\t\t\t\"border-status-success bg-surface-brand-subtle text-status-success\",\n\t\t\t\tinfo: \"border-status-info bg-surface text-status-info\",\n\t\t\t\twarning:\n\t\t\t\t\t\"border-status-warning bg-surface-accent-subtle text-status-warning\",\n\t\t\t\terror:\n\t\t\t\t\t\"border-status-danger bg-surface-danger-subtle text-status-danger\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tvariant: \"info\",\n\t\t},\n\t},\n);\n\ntype AlertVariant = NonNullable<VariantProps<typeof alertVariants>[\"variant\"]>;\n\ntype AlertProps = React.ComponentProps<\"div\"> &\n\tVariantProps<typeof alertVariants> & {\n\t\tliveRegion?: \"polite\" | \"assertive\" | \"off\";\n\t};\n\nfunction Alert({\n\tclassName,\n\tvariant = \"info\",\n\tliveRegion,\n\trole,\n\t...props\n}: AlertProps) {\n\tconst resolvedVariant: AlertVariant = variant ?? \"info\";\n\tconst resolvedRole =\n\t\trole ?? (liveRegion === \"off\" ? undefined : getAlertRole(resolvedVariant));\n\tconst resolvedLiveRegion =\n\t\tliveRegion === \"off\"\n\t\t\t? undefined\n\t\t\t: (liveRegion ?? (resolvedVariant === \"error\" ? \"assertive\" : \"polite\"));\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"alert\"\n\t\t\tdata-variant={resolvedVariant}\n\t\t\trole={resolvedRole}\n\t\t\taria-live={resolvedLiveRegion}\n\t\t\tclassName={cn(alertVariants({ variant: resolvedVariant }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AlertTitle({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"alert-title\"\n\t\t\tclassName={cn(\n\t\t\t\t\"col-start-2 row-start-1 font-extrabold text-fg-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AlertDescription({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"alert-description\"\n\t\t\tclassName={cn(\n\t\t\t\t\"col-start-2 row-start-2 text-fg-secondary [&_p]:leading-relaxed\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AlertActions({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"alert-actions\"\n\t\t\tclassName={cn(\n\t\t\t\t\"col-start-2 row-start-3 mt-2 flex shrink-0 items-center gap-2 justify-self-start sm:col-start-3 sm:row-span-2 sm:row-start-1 sm:mt-[-0.125rem] sm:justify-self-end\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AlertClose({\n\tclassName,\n\ttype = \"button\",\n\tchildren,\n\t\"aria-label\": ariaLabel = \"Dismiss alert\",\n\t...props\n}: React.ComponentProps<\"button\">) {\n\treturn (\n\t\t<button\n\t\t\tdata-slot=\"alert-close\"\n\t\t\ttype={type}\n\t\t\tclassName={cn(\n\t\t\t\t\"inline-flex size-8 shrink-0 cursor-pointer items-center justify-center rounded-full border-0 bg-transparent p-0 text-fg-secondary transition-[background-color,color,box-shadow] hover:bg-surface-raised hover:text-fg-primary focus-visible:border-line-focus focus-visible:outline-none focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)]\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\taria-label={ariaLabel}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children ?? <X className=\"size-4\" aria-hidden=\"true\" />}\n\t\t</button>\n\t);\n}\n\nfunction getAlertRole(variant: AlertVariant) {\n\treturn variant === \"error\" ? \"alert\" : \"status\";\n}\n\nexport {\n\tAlert,\n\tAlertActions,\n\tAlertClose,\n\tAlertDescription,\n\tAlertTitle,\n\talertVariants,\n};\nexport type { AlertProps, AlertVariant };\n","\"use client\";\n\nimport { Avatar as AvatarPrimitive } from \"@base-ui/react/avatar\";\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\n\ntype AvatarSize = \"sm\" | \"md\" | \"lg\";\n\nfunction Avatar({\n\tclassName,\n\tsize = \"md\",\n\t...props\n}: AvatarPrimitive.Root.Props & {\n\tsize?: AvatarSize;\n}) {\n\treturn (\n\t\t<AvatarPrimitive.Root\n\t\t\tdata-slot=\"avatar\"\n\t\t\tdata-size={size}\n\t\t\tclassName={cn(\n\t\t\t\t\"group/avatar relative flex shrink-0 rounded-full select-none bg-surface-brand\",\n\t\t\t\tsize === \"sm\" && \"size-8\",\n\t\t\t\tsize === \"md\" && \"size-10\",\n\t\t\t\tsize === \"lg\" && \"size-14\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AvatarImage({ className, ...props }: AvatarPrimitive.Image.Props) {\n\treturn (\n\t\t<AvatarPrimitive.Image\n\t\t\tdata-slot=\"avatar-image\"\n\t\t\tclassName={cn(\n\t\t\t\t\"aspect-square size-full rounded-full object-cover\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AvatarFallback({\n\tclassName,\n\t...props\n}: AvatarPrimitive.Fallback.Props) {\n\treturn (\n\t\t<AvatarPrimitive.Fallback\n\t\t\tdata-slot=\"avatar-fallback\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex size-full items-center justify-center rounded-full\",\n\t\t\t\t\"bg-surface-brand-subtle text-fg-brand font-semibold\",\n\t\t\t\t\"group-data-[size=sm]/avatar:text-xs\",\n\t\t\t\t\"group-data-[size=md]/avatar:text-sm\",\n\t\t\t\t\"group-data-[size=lg]/avatar:text-base\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AvatarStatus({ className, ...props }: React.ComponentProps<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\tdata-slot=\"avatar-status\"\n\t\t\tclassName={cn(\n\t\t\t\t\"absolute right-0 bottom-0 z-10 rounded-full bg-status-success ring-2 ring-canvas\",\n\t\t\t\t\"group-data-[size=sm]/avatar:size-2\",\n\t\t\t\t\"group-data-[size=md]/avatar:size-2.5\",\n\t\t\t\t\"group-data-[size=lg]/avatar:size-3.5\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AvatarGroup({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"avatar-group\"\n\t\t\tclassName={cn(\n\t\t\t\t\"group/avatar-group flex -space-x-3\",\n\t\t\t\t\"*:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-canvas\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction AvatarGroupCount({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"avatar-group-count\"\n\t\t\tclassName={cn(\n\t\t\t\t\"relative flex shrink-0 items-center justify-center rounded-full\",\n\t\t\t\t\"bg-action-tertiary text-fg-secondary text-xs font-semibold\",\n\t\t\t\t\"ring-2 ring-canvas\",\n\t\t\t\t\"size-10\",\n\t\t\t\t\"group-has-data-[size=sm]/avatar-group:size-8\",\n\t\t\t\t\"group-has-data-[size=lg]/avatar-group:size-14\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tAvatar,\n\tAvatarImage,\n\tAvatarFallback,\n\tAvatarGroup,\n\tAvatarGroupCount,\n\tAvatarStatus,\n\tAvatarStatus as AvatarBadge,\n};\n","import { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\n\nimport { cn } from \"../../lib/cn\";\nimport { useComponentSize } from \"./size-context\";\n\nconst badgeVariants = cva(\n\t\"group/badge inline-flex w-fit shrink-0 items-center justify-center overflow-hidden border font-bold leading-none whitespace-nowrap transition-[background-color,border-color,color,box-shadow] outline-none focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] aria-invalid:border-line-danger aria-invalid:text-fg-danger [&>svg]:pointer-events-none [&>svg]:shrink-0 [&>svg]:text-current\",\n\t{\n\t\tvariants: {\n\t\t\tvariant: {\n\t\t\t\tdefault: \"border-line bg-surface-raised text-fg-secondary\",\n\t\t\t\tinfo: \"border-status-info/40 bg-surface-info-subtle text-status-info\",\n\t\t\t\tsuccess:\n\t\t\t\t\t\"border-status-success/40 bg-surface-brand-subtle text-status-success\",\n\t\t\t\twarning:\n\t\t\t\t\t\"border-status-warning/40 bg-surface-accent-subtle text-status-warning\",\n\t\t\t\tdanger:\n\t\t\t\t\t\"border-line-danger bg-surface-danger-subtle text-status-danger\",\n\t\t\t\tsecondary:\n\t\t\t\t\t\"border-status-info/40 bg-surface-info-subtle text-status-info\",\n\t\t\t\tdestructive:\n\t\t\t\t\t\"border-line-danger bg-surface-danger-subtle text-status-danger\",\n\t\t\t\toutline: \"border-line bg-transparent text-fg-secondary\",\n\t\t\t},\n\t\t\tsize: {\n\t\t\t\tsm: \"gap-1 px-2.5 py-1 text-gdt-xs has-data-[icon=inline-start]:pl-2 has-data-[icon=inline-end]:pr-2 [&>svg]:size-3\",\n\t\t\t\tmd: \"gap-1.5 px-3 py-1.5 text-gdt-sm has-data-[icon=inline-start]:pl-2.5 has-data-[icon=inline-end]:pr-2.5 [&>svg]:size-3.5\",\n\t\t\t\tlg: \"gap-2 px-4 py-2 text-gdt-md has-data-[icon=inline-start]:pl-3.5 has-data-[icon=inline-end]:pr-3.5 [&>svg]:size-4\",\n\t\t\t},\n\t\t\tshape: {\n\t\t\t\tround: \"rounded-4xl\",\n\t\t\t\tbox: \"rounded-lg\",\n\t\t\t},\n\t\t\tborder: {\n\t\t\t\ttrue: \"\",\n\t\t\t\tfalse: \"border-transparent\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tvariant: \"default\",\n\t\t\tsize: \"md\",\n\t\t\tshape: \"round\",\n\t\t\tborder: true,\n\t\t},\n\t},\n);\n\nfunction Badge({\n\tclassName,\n\tvariant = \"default\",\n\tsize,\n\tshape = \"round\",\n\tborder = true,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"span\"> & VariantProps<typeof badgeVariants>) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn useRender({\n\t\tdefaultTagName: \"span\",\n\t\tprops: mergeProps<\"span\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\tbadgeVariants({ variant, size: resolvedSize, shape, border }),\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tslot: \"badge\",\n\t\t\tvariant,\n\t\t\tsize: resolvedSize,\n\t\t\tshape,\n\t\t\tborder,\n\t\t},\n\t});\n}\n\nexport { Badge, badgeVariants };\n","\"use client\";\n\nimport { createContext, type ReactNode, useContext } from \"react\";\n\ntype ComponentSize = \"sm\" | \"md\" | \"lg\";\n\nconst SizeContext = createContext<ComponentSize | undefined>(undefined);\n\nfunction SizeProvider({\n\tchildren,\n\tsize,\n}: {\n\tchildren: ReactNode;\n\tsize?: ComponentSize | null;\n}) {\n\tif (!size) {\n\t\treturn <>{children}</>;\n\t}\n\n\treturn <SizeContext.Provider value={size}>{children}</SizeContext.Provider>;\n}\n\nfunction useComponentSize(\n\tsize?: ComponentSize | null,\n\tfallback: ComponentSize = \"md\",\n) {\n\tconst inheritedSize = useContext(SizeContext);\n\treturn size ?? inheritedSize ?? fallback;\n}\n\nexport { SizeProvider, useComponentSize, type ComponentSize };\n","\"use client\";\n\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport * as React from \"react\";\nimport type { TooltipValueType } from \"recharts\";\nimport * as RechartsPrimitive from \"recharts\";\nimport { cn } from \"../../lib/cn\";\nimport {\n\ttype ComponentSize,\n\tSizeProvider,\n\tuseComponentSize,\n} from \"./size-context\";\n\n/**\n * Markers use `--color-surface-brand` as a placeholder. Giddaa has no\n * categorical chart palette yet — add `chart-1`…`chart-N` tokens and bind each\n * series (its legend marker and tooltip dot) to its own colour once they exist.\n * Until then any series without an explicit colour paints brand-green.\n */\nconst SERIES_COLOR_PLACEHOLDER = \"var(--color-surface-brand)\";\n\n/** How a precise value is formatted in the tooltip and which prefix/suffix it carries. */\nexport type ChartValueType = \"number\" | \"percentage\" | \"currency\";\n\nfunction formatChartValue(\n\tvalue: TooltipValueType | undefined,\n\ttype: ChartValueType,\n) {\n\tif (Array.isArray(value)) {\n\t\treturn value.join(\", \");\n\t}\n\n\tif (typeof value !== \"number\") {\n\t\treturn value == null ? \"\" : String(value);\n\t}\n\n\tswitch (type) {\n\t\tcase \"currency\":\n\t\t\treturn `₦${value.toLocaleString(\"en-NG\")}`;\n\t\tcase \"percentage\":\n\t\t\treturn `${value.toLocaleString(\"en-NG\", {\n\t\t\t\tminimumFractionDigits: 1,\n\t\t\t\tmaximumFractionDigits: 1,\n\t\t\t})}%`;\n\t\tdefault:\n\t\t\treturn value.toLocaleString(\"en-NG\");\n\t}\n}\n\n// Format: { THEME_NAME: CSS_SELECTOR }\nconst THEMES = { light: \"\", dark: \".dark\" } as const;\n\nconst INITIAL_DIMENSION = { width: 320, height: 200 } as const;\ntype TooltipNameType = number | string;\n\nexport type ChartConfig = Record<\n\tstring,\n\t{\n\t\tlabel?: React.ReactNode;\n\t\ticon?: React.ComponentType;\n\t} & (\n\t\t| { color?: string; theme?: never }\n\t\t| { color?: never; theme: Record<keyof typeof THEMES, string> }\n\t)\n>;\n\ntype ChartContextProps = {\n\tconfig: ChartConfig;\n};\n\nconst ChartContext = React.createContext<ChartContextProps | null>(null);\n\nfunction useChart() {\n\tconst context = React.useContext(ChartContext);\n\n\tif (!context) {\n\t\tthrow new Error(\"useChart must be used within a <ChartContainer />\");\n\t}\n\n\treturn context;\n}\n\n/**\n * Shared chart frame — the chrome that surrounds the plot of any chart type\n * (bar, line, area, pie). These are presentational, domain-free, and size-aware:\n * a `size` flows through `SizeProvider` so the plot and its labels can scale\n * with the card. Compose them with the plot primitives:\n *\n * <ChartCard size=\"md\">\n * <ChartHeader>\n * <ChartTitle>Revenue Overview</ChartTitle>\n * <ChartDescription>Monthly revenue · Jan–Jul</ChartDescription>\n * </ChartHeader>\n * <ChartContainer config={config}>{/* recharts plot *\\/}</ChartContainer>\n * </ChartCard>\n */\nconst chartCardVariants = cva(\n\t\"flex w-full min-w-0 flex-col rounded-2xl border border-line-subtle bg-surface-raised text-fg-primary shadow-1\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"gap-3 p-4\",\n\t\t\t\tmd: \"gap-4 p-5\",\n\t\t\t\tlg: \"gap-5 p-6\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: { size: \"md\" },\n\t},\n);\n\nfunction ChartCard({\n\tclassName,\n\tsize,\n\tchildren,\n\t...props\n}: React.ComponentProps<\"section\"> & { size?: ComponentSize }) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn (\n\t\t<SizeProvider size={resolvedSize}>\n\t\t\t<section\n\t\t\t\tdata-slot=\"chart-card\"\n\t\t\t\tclassName={cn(chartCardVariants({ size: resolvedSize }), className)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</section>\n\t\t</SizeProvider>\n\t);\n}\n\nfunction ChartHeader({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"chart-header\"\n\t\t\tclassName={cn(\"flex min-w-0 flex-col gap-1\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst chartTitleVariants = cva(\"min-w-0 font-bold text-fg-primary\", {\n\tvariants: {\n\t\tsize: {\n\t\t\tsm: \"text-gdt-md\",\n\t\t\tmd: \"text-gdt-lg\",\n\t\t\tlg: \"text-gdt-h5\",\n\t\t},\n\t},\n\tdefaultVariants: { size: \"md\" },\n});\n\nfunction ChartTitle({\n\tclassName,\n\tsize,\n\t...props\n}: React.ComponentProps<\"h3\"> & { size?: ComponentSize }) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn (\n\t\t<h3\n\t\t\tdata-slot=\"chart-title\"\n\t\t\tclassName={cn(chartTitleVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst chartDescriptionVariants = cva(\"min-w-0 font-normal text-fg-secondary\", {\n\tvariants: {\n\t\tsize: {\n\t\t\tsm: \"text-gdt-xs\",\n\t\t\tmd: \"text-gdt-sm\",\n\t\t\tlg: \"text-gdt-sm\",\n\t\t},\n\t},\n\tdefaultVariants: { size: \"md\" },\n});\n\nfunction ChartDescription({\n\tclassName,\n\tsize,\n\t...props\n}: React.ComponentProps<\"p\"> & { size?: ComponentSize }) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn (\n\t\t<p\n\t\t\tdata-slot=\"chart-description\"\n\t\t\tclassName={cn(\n\t\t\t\tchartDescriptionVariants({ size: resolvedSize }),\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ChartContainer({\n\tid,\n\tclassName,\n\tchildren,\n\tconfig,\n\tinitialDimension = INITIAL_DIMENSION,\n\t...props\n}: React.ComponentProps<\"div\"> & {\n\tconfig: ChartConfig;\n\tchildren: React.ComponentProps<\n\t\ttypeof RechartsPrimitive.ResponsiveContainer\n\t>[\"children\"];\n\tinitialDimension?: {\n\t\twidth: number;\n\t\theight: number;\n\t};\n}) {\n\tconst uniqueId = React.useId();\n\tconst chartId = `chart-${id ?? uniqueId.replace(/:/g, \"\")}`;\n\n\treturn (\n\t\t<ChartContext.Provider value={{ config }}>\n\t\t\t<div\n\t\t\t\tdata-slot=\"chart\"\n\t\t\t\tdata-chart={chartId}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t<ChartStyle id={chartId} config={config} />\n\t\t\t\t<RechartsPrimitive.ResponsiveContainer\n\t\t\t\t\tinitialDimension={initialDimension}\n\t\t\t\t>\n\t\t\t\t\t{children}\n\t\t\t\t</RechartsPrimitive.ResponsiveContainer>\n\t\t\t</div>\n\t\t</ChartContext.Provider>\n\t);\n}\n\nconst ChartStyle = ({ id, config }: { id: string; config: ChartConfig }) => {\n\tconst colorConfig = Object.entries(config).filter(\n\t\t([, config]) => config.theme ?? config.color,\n\t);\n\n\tif (!colorConfig.length) {\n\t\treturn null;\n\t}\n\n\tconst styleContent = Object.entries(THEMES)\n\t\t.map(\n\t\t\t([theme, prefix]) => `\n${prefix} [data-chart=${id}] {\n${colorConfig\n\t.map(([key, itemConfig]) => {\n\t\tconst color =\n\t\t\titemConfig.theme?.[theme as keyof typeof itemConfig.theme] ??\n\t\t\titemConfig.color;\n\t\treturn color ? ` --color-${key}: ${color};` : null;\n\t})\n\t.join(\"\\n\")}\n}\n`,\n\t\t)\n\t\t.join(\"\\n\");\n\n\treturn <style>{styleContent}</style>;\n};\n\nconst ChartTooltip = RechartsPrimitive.Tooltip;\n\n/**\n * Hover tooltip for a chart data point. It surfaces a single precise value with\n * type-appropriate formatting — grouped integers, percentages, or ₦-prefixed\n * currency — sitting on an elevated overlay (bg-surface-overlay, Shadow-2,\n * 1px border-subtle) so users can read exact figures without leaving the chart.\n *\n * Anatomy: series dot · metric label · hero value · period caption.\n */\nconst chartTooltipVariants = cva(\n\t\"flex flex-col bg-surface-overlay border border-line-subtle shadow-2\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\txs: \"gap-0.5 rounded-md p-2\",\n\t\t\t\tsm: \"gap-0.5 rounded-md p-2.5\",\n\t\t\t\tmd: \"gap-1 rounded-lg p-3\",\n\t\t\t\tlg: \"gap-1 rounded-xl p-3.5\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst chartTooltipDotVariants = cva(\"shrink-0 rounded-full\", {\n\tvariants: {\n\t\tsize: {\n\t\t\txs: \"size-1.5\",\n\t\t\tsm: \"size-2\",\n\t\t\tmd: \"size-2.5\",\n\t\t\tlg: \"size-2.5\",\n\t\t},\n\t},\n\tdefaultVariants: {\n\t\tsize: \"md\",\n\t},\n});\n\nconst chartTooltipLabelVariants = cva(\"font-medium text-fg-secondary\", {\n\tvariants: {\n\t\tsize: {\n\t\t\txs: \"text-gdt-xs\",\n\t\t\tsm: \"text-gdt-xs\",\n\t\t\tmd: \"text-gdt-sm\",\n\t\t\tlg: \"text-gdt-sm\",\n\t\t},\n\t},\n\tdefaultVariants: { size: \"md\" },\n});\n\nconst chartTooltipValueVariants = cva(\n\t\"font-extrabold text-fg-primary tabular-nums\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\txs: \"text-gdt-sm\",\n\t\t\t\tsm: \"text-gdt-md\",\n\t\t\t\tmd: \"text-gdt-lg\",\n\t\t\t\tlg: \"text-gdt-xl\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: { size: \"md\" },\n\t},\n);\n\nfunction ChartTooltipContent({\n\tactive,\n\tpayload,\n\tclassName,\n\thideIndicator = false,\n\tlabel,\n\tlabelFormatter,\n\tformatter,\n\tcolor,\n\tnameKey,\n\tvalueType = \"number\",\n\tsize = \"md\",\n}: React.ComponentProps<typeof RechartsPrimitive.Tooltip> &\n\tReact.ComponentProps<\"div\"> & {\n\t\thideIndicator?: boolean;\n\t\tnameKey?: string;\n\t\tvalueType?: ChartValueType;\n\t} & VariantProps<typeof chartTooltipVariants> &\n\tOmit<\n\t\tRechartsPrimitive.DefaultTooltipContentProps<\n\t\t\tTooltipValueType,\n\t\t\tTooltipNameType\n\t\t>,\n\t\t\"accessibilityLayer\"\n\t>) {\n\tconst { config } = useChart();\n\n\tif (!active || !payload?.length) {\n\t\treturn null;\n\t}\n\n\tconst [item] = payload.filter((entry) => entry.type !== \"none\");\n\n\tif (!item) {\n\t\treturn null;\n\t}\n\n\tconst key = `${nameKey ?? item.name ?? item.dataKey ?? \"value\"}`;\n\tconst itemConfig = getPayloadConfigFromPayload(config, item, key);\n\tconst dotColor =\n\t\tcolor ?? item.payload?.fill ?? item.color ?? SERIES_COLOR_PLACEHOLDER;\n\n\t// Metric label — the short name of the series being read, e.g. \"Total Revenue\".\n\tconst metricLabel = itemConfig?.label ?? item.name;\n\t// Hero value — the precise, formatted figure, the visual focus of the tooltip.\n\tconst heroValue = formatter\n\t\t? formatter(item.value, item.name ?? \"\", item, 0, item.payload)\n\t\t: formatChartValue(item.value, valueType);\n\t// Period caption — the time context for the value, e.g. \"March 2026\".\n\tconst periodCaption = labelFormatter\n\t\t? labelFormatter(label, payload)\n\t\t: ((typeof label === \"string\" ? config[label]?.label : null) ?? label);\n\n\treturn (\n\t\t<div className={cn(chartTooltipVariants({ size }), className)}>\n\t\t\t{metricLabel != null && (\n\t\t\t\t<div className=\"flex items-center gap-1.5 [&>svg]:size-3 [&>svg]:shrink-0\">\n\t\t\t\t\t{!hideIndicator &&\n\t\t\t\t\t\t(itemConfig?.icon ? (\n\t\t\t\t\t\t\t<itemConfig.icon />\n\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\t\t\tclassName={cn(chartTooltipDotVariants({ size }))}\n\t\t\t\t\t\t\t\tstyle={{ backgroundColor: dotColor }}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t))}\n\t\t\t\t\t<span className={cn(chartTooltipLabelVariants({ size }))}>\n\t\t\t\t\t\t{metricLabel}\n\t\t\t\t\t</span>\n\t\t\t\t</div>\n\t\t\t)}\n\t\t\t<p className={cn(chartTooltipValueVariants({ size }))}>{heroValue}</p>\n\t\t\t{periodCaption != null && periodCaption !== \"\" && (\n\t\t\t\t<p className=\"text-gdt-xs text-fg-caption-placeholder\">\n\t\t\t\t\t{periodCaption}\n\t\t\t\t</p>\n\t\t\t)}\n\t\t</div>\n\t);\n}\n\nconst ChartLegend = RechartsPrimitive.Legend;\n\n/** Marker shape that ties a legend item to its series. */\ntype ChartLegendMarker = \"dot\" | \"square\" | \"line\";\n\nconst chartLegendItemVariants = cva(\n\t\"group/legend-item flex items-center rounded-md leading-none text-fg-primary transition-colors [&>svg]:shrink-0\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"gap-1.5 px-2 py-1 text-gdt-xs [&>svg]:size-3\",\n\t\t\t\tmd: \"gap-2 px-2.5 py-1.5 text-gdt-sm [&>svg]:size-3.5\",\n\t\t\t},\n\t\t\tinteractive: {\n\t\t\t\ttrue: \"cursor-pointer outline-none hover:bg-surface-raised focus-visible:bg-surface-raised\",\n\t\t\t\tfalse: \"\",\n\t\t\t},\n\t\t\tinactive: {\n\t\t\t\ttrue: \"text-fg-caption-placeholder line-through\",\n\t\t\t\tfalse: \"\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t\tinteractive: false,\n\t\t\tinactive: false,\n\t\t},\n\t},\n);\n\nconst chartLegendMarkerSizeVariants = cva(\"shrink-0\", {\n\tvariants: {\n\t\tmarker: {\n\t\t\tdot: \"rounded-full\",\n\t\t\tsquare: \"rounded-[2px]\",\n\t\t\tline: \"rounded-full\",\n\t\t},\n\t\tsize: {\n\t\t\tsm: \"\",\n\t\t\tmd: \"\",\n\t\t},\n\t},\n\tcompoundVariants: [\n\t\t{ marker: [\"dot\", \"square\"], size: \"sm\", className: \"size-2\" },\n\t\t{ marker: [\"dot\", \"square\"], size: \"md\", className: \"size-2.5\" },\n\t\t{ marker: \"line\", size: \"sm\", className: \"h-[3px] w-3\" },\n\t\t{ marker: \"line\", size: \"md\", className: \"h-[3px] w-3.5\" },\n\t],\n\tdefaultVariants: { marker: \"dot\", size: \"md\" },\n});\n\n/**\n * A shared legend for all chart types. Each item pairs a series marker with a\n * label and can be toggled to hide or show its series — the inactive state mutes\n * the marker and strikes through the label. Items compose into horizontal rows\n * or vertical columns, in two sizes, with dot, square, or line markers.\n *\n * Toggling: pass `onToggle` to make items interactive. Inactive items are read\n * from each payload entry's `inactive` flag (recharts sets this when wired) or\n * the controlled `inactiveKeys` set.\n */\nfunction ChartLegendContent({\n\tclassName,\n\thideIcon = false,\n\tpayload,\n\tverticalAlign = \"bottom\",\n\tnameKey,\n\tmarker = \"dot\",\n\tsize = \"md\",\n\torientation = \"horizontal\",\n\tinactiveKeys,\n\tonToggle,\n}: React.ComponentProps<\"div\"> & {\n\thideIcon?: boolean;\n\tnameKey?: string;\n\tmarker?: ChartLegendMarker;\n\tsize?: \"sm\" | \"md\";\n\torientation?: \"horizontal\" | \"vertical\";\n\tinactiveKeys?: Iterable<string>;\n\tonToggle?: (key: string) => void;\n} & RechartsPrimitive.DefaultLegendContentProps) {\n\tconst { config } = useChart();\n\n\tif (!payload?.length) {\n\t\treturn null;\n\t}\n\n\tconst inactiveSet = inactiveKeys ? new Set(inactiveKeys) : undefined;\n\tconst interactive = Boolean(onToggle);\n\n\treturn (\n\t\t<div\n\t\t\tclassName={cn(\n\t\t\t\t\"flex\",\n\t\t\t\torientation === \"vertical\"\n\t\t\t\t\t? \"flex-col items-start gap-0.5\"\n\t\t\t\t\t: \"flex-row flex-wrap items-center justify-center gap-x-1 gap-y-0.5\",\n\t\t\t\tverticalAlign === \"top\" ? \"pb-3\" : \"pt-3\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t>\n\t\t\t{payload\n\t\t\t\t.filter((item) => item.type !== \"none\")\n\t\t\t\t.map((item, index) => {\n\t\t\t\t\tconst key = `${nameKey ?? item.dataKey ?? \"value\"}`;\n\t\t\t\t\tconst itemKey = `${item.dataKey ?? item.value ?? index}`;\n\t\t\t\t\tconst itemConfig = getPayloadConfigFromPayload(config, item, key);\n\t\t\t\t\tconst inactive =\n\t\t\t\t\t\t(inactiveSet?.has(key) ?? false) || Boolean(item.inactive);\n\t\t\t\t\tconst markerColor = inactive\n\t\t\t\t\t\t? \"var(--color-fg-caption-placeholder)\"\n\t\t\t\t\t\t: (item.color ?? SERIES_COLOR_PLACEHOLDER);\n\n\t\t\t\t\tconst content = (\n\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t{itemConfig?.icon && !hideIcon ? (\n\t\t\t\t\t\t\t\t<itemConfig.icon />\n\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\t\tchartLegendMarkerSizeVariants({ marker, size }),\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\tstyle={{ backgroundColor: markerColor }}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t{itemConfig?.label ?? item.value}\n\t\t\t\t\t\t</>\n\t\t\t\t\t);\n\n\t\t\t\t\tif (interactive) {\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\tkey={itemKey}\n\t\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\t\taria-pressed={!inactive}\n\t\t\t\t\t\t\t\tonClick={() => onToggle?.(key)}\n\t\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\tchartLegendItemVariants({ size, interactive, inactive }),\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{content}\n\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\n\t\t\t\t\treturn (\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tkey={itemKey}\n\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\tchartLegendItemVariants({ size, interactive, inactive }),\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{content}\n\t\t\t\t\t\t</div>\n\t\t\t\t\t);\n\t\t\t\t})}\n\t\t</div>\n\t);\n}\n\n/** The size-scaled layout numbers a cartesian chart needs to build axis props. */\ntype CartesianAxisLayout = {\n\ttickMargin: number;\n\ttickFontSize: number;\n\tyAxisWidth: number;\n};\n\n/**\n * Shared `<XAxis>`/`<YAxis>` props — the giddaa cartesian-axis defaults (no tick\n * or axis lines, a size-scaled tick font, and a reserved value-axis width) that\n * every bar and line chart would otherwise repeat per axis. Spread the result\n * onto the recharts axis, then add the chart-specific props (`dataKey`,\n * `domain`, `ticks`, a `width`/`type` override, …):\n *\n * const chart = useBarChartLayout();\n * <XAxis dataKey=\"month\" {...chart.xAxis} />\n * <YAxis domain={[0, 120]} {...chart.yAxis} />\n */\nfunction cartesianAxisProps(layout: CartesianAxisLayout) {\n\tconst tick = { fontSize: layout.tickFontSize };\n\treturn {\n\t\txAxis: {\n\t\t\ttickLine: false,\n\t\t\taxisLine: false,\n\t\t\ttickMargin: layout.tickMargin,\n\t\t\ttick,\n\t\t},\n\t\tyAxis: {\n\t\t\ttickLine: false,\n\t\t\taxisLine: false,\n\t\t\twidth: layout.yAxisWidth,\n\t\t\ttick,\n\t\t},\n\t} as const;\n}\n\nfunction getPayloadConfigFromPayload(\n\tconfig: ChartConfig,\n\tpayload: unknown,\n\tkey: string,\n) {\n\tif (typeof payload !== \"object\" || payload === null) {\n\t\treturn undefined;\n\t}\n\n\tconst payloadPayload =\n\t\t\"payload\" in payload &&\n\t\ttypeof payload.payload === \"object\" &&\n\t\tpayload.payload !== null\n\t\t\t? payload.payload\n\t\t\t: undefined;\n\n\tlet configLabelKey: string = key;\n\n\tif (\n\t\tkey in payload &&\n\t\ttypeof payload[key as keyof typeof payload] === \"string\"\n\t) {\n\t\tconfigLabelKey = payload[key as keyof typeof payload] as string;\n\t} else if (\n\t\tpayloadPayload &&\n\t\tkey in payloadPayload &&\n\t\ttypeof payloadPayload[key as keyof typeof payloadPayload] === \"string\"\n\t) {\n\t\tconfigLabelKey = payloadPayload[\n\t\t\tkey as keyof typeof payloadPayload\n\t\t] as string;\n\t}\n\n\treturn configLabelKey in config ? config[configLabelKey] : config[key];\n}\n\nexport {\n\tcartesianAxisProps,\n\tChartCard,\n\tChartContainer,\n\tChartDescription,\n\tChartHeader,\n\tChartLegend,\n\tChartLegendContent,\n\tChartStyle,\n\tChartTitle,\n\tChartTooltip,\n\tChartTooltipContent,\n};\nexport type { CartesianAxisLayout };\n","\"use client\";\n\nimport type * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { cartesianAxisProps } from \"./chart\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\n/**\n * Bar charts are composed from recharts plot primitives directly — recharts\n * identifies `Bar`, `XAxis`, `YAxis`, `CartesianGrid`, and `LabelList` by\n * component identity, so they cannot be wrapped without breaking the chart.\n * This module supplies the giddaa-specific defaults that would otherwise be\n * copy-pasted into every bar chart: per-size layout numbers and a value-label\n * renderer. Pair them with the shared frame and overlays from `./chart`.\n *\n * @example\n * const chart = useBarChartLayout();\n * <ChartCard size=\"md\">\n * <ChartHeader>\n * <ChartTitle>Revenue Overview</ChartTitle>\n * <ChartDescription>Monthly revenue · Jan–Jul</ChartDescription>\n * </ChartHeader>\n * <ChartContainer config={config} {...chart.container}>\n * <BarChart data={data} {...chart.chart}>\n * <CartesianGrid vertical={false} stroke=\"var(--color-line-subtle)\" />\n * <XAxis dataKey=\"month\" {...chart.xAxis} />\n * <YAxis {...chart.yAxis} />\n * <ChartLegend verticalAlign=\"top\" content={<ChartLegendContent />} />\n * <ChartTooltip content={<ChartTooltipContent />} />\n * <Bar dataKey=\"revenue\" fill=\"var(--color-revenue)\" {...chart.bar}>\n * <LabelList dataKey=\"revenue\" content={<BarValueLabel />} />\n * </Bar>\n * </BarChart>\n * </ChartContainer>\n * </ChartCard>\n */\n\ntype BarChartLayout = {\n\t/** Plot height in px. Width stays fluid via the ResponsiveContainer. */\n\theight: number;\n\t/** Outer margin — top leaves room for value labels above the tallest bar. */\n\tmargin: { top: number; right: number; bottom: number; left: number };\n\t/** Cap on bar thickness so a few categories don't render slab-wide bars. */\n\tmaxBarSize: number;\n\t/** Gap between categories (groups), as a percentage of the band. */\n\tbarCategoryGap: string;\n\t/** Gap between bars within a group (grouped layout). */\n\tbarGap: number;\n\t/** Corner radius for a bar. */\n\tbarRadius: number;\n\t/** Axis tick label font size. */\n\ttickFontSize: number;\n\t/** Value label (on-bar number) font size. */\n\tvalueFontSize: number;\n\t/** Reserved width for the value axis. */\n\tyAxisWidth: number;\n\t/** Space between an axis and its tick labels. */\n\ttickMargin: number;\n};\n\nconst BAR_CHART_LAYOUT: Record<ComponentSize, BarChartLayout> = {\n\tsm: {\n\t\theight: 180,\n\t\tmargin: { top: 20, right: 8, bottom: 0, left: 0 },\n\t\tmaxBarSize: 22,\n\t\tbarCategoryGap: \"8%\",\n\t\tbarGap: 4,\n\t\tbarRadius: 4,\n\t\ttickFontSize: 10,\n\t\tvalueFontSize: 10,\n\t\tyAxisWidth: 28,\n\t\ttickMargin: 6,\n\t},\n\tmd: {\n\t\theight: 220,\n\t\tmargin: { top: 24, right: 12, bottom: 0, left: 0 },\n\t\tmaxBarSize: 28,\n\t\tbarCategoryGap: \"8%\",\n\t\tbarGap: 6,\n\t\tbarRadius: 6,\n\t\ttickFontSize: 11,\n\t\tvalueFontSize: 11,\n\t\tyAxisWidth: 32,\n\t\ttickMargin: 8,\n\t},\n\tlg: {\n\t\theight: 280,\n\t\tmargin: { top: 28, right: 16, bottom: 0, left: 0 },\n\t\tmaxBarSize: 36,\n\t\tbarCategoryGap: \"8%\",\n\t\tbarGap: 8,\n\t\tbarRadius: 8,\n\t\ttickFontSize: 12,\n\t\tvalueFontSize: 12,\n\t\tyAxisWidth: 36,\n\t\ttickMargin: 10,\n\t},\n};\n\n/**\n * Resolve the bar-chart layout for an explicit or inherited component size. The\n * returned object groups the giddaa defaults by the recharts component they\n * belong to — spread each onto its element, then pass the data-specific props\n * (`config`, `data`, `dataKey`, `fill`, …) directly afterwards to add or\n * override anything:\n *\n * const chart = useBarChartLayout(size);\n * <ChartContainer config={config} {...chart.container}>\n * <BarChart data={data} {...chart.chart}>\n * <XAxis dataKey=\"month\" {...chart.xAxis} />\n * <YAxis {...chart.yAxis} />\n * <Bar dataKey=\"revenue\" fill=\"var(--color-revenue)\" {...chart.bar} />\n */\nfunction useBarChartLayout(size?: ComponentSize) {\n\tconst layout = BAR_CHART_LAYOUT[useComponentSize(size)];\n\tconst axes = cartesianAxisProps(layout);\n\n\treturn {\n\t\tcontainer: {\n\t\t\tclassName: \"aspect-auto w-full\",\n\t\t\tstyle: { height: layout.height },\n\t\t},\n\t\tchart: {\n\t\t\taccessibilityLayer: true,\n\t\t\tmargin: layout.margin,\n\t\t\tbarCategoryGap: layout.barCategoryGap,\n\t\t\tbarGap: layout.barGap,\n\t\t},\n\t\txAxis: axes.xAxis,\n\t\tyAxis: axes.yAxis,\n\t\tbar: {\n\t\t\tradius: [layout.barRadius, layout.barRadius, 0, 0] as [\n\t\t\t\tnumber,\n\t\t\t\tnumber,\n\t\t\t\tnumber,\n\t\t\t\tnumber,\n\t\t\t],\n\t\t\tmaxBarSize: layout.maxBarSize,\n\t\t},\n\t};\n}\n\n/**\n * Renderer for recharts `<LabelList content={<BarValueLabel />} />`. recharts\n * injects the bar geometry (`x`, `y`, `width`, `height`, `value`); the rest are\n * caller props. For a vertical bar the label sits above the bar; for a\n * horizontal bar (`orientation=\"horizontal\"`) it sits to the right of the bar.\n */\ntype BarValueLabelProps = {\n\t/** Bar layout direction — drives where the label is placed. */\n\torientation?: \"vertical\" | \"horizontal\";\n\t/** Override the on-bar font size (defaults to the size-scaled value). */\n\tfontSize?: number;\n\t/** Format the raw value before display, e.g. `(v) => `₦${v}``. */\n\tformatter?: (value: React.ReactNode) => React.ReactNode;\n\tclassName?: string;\n\t// Injected by recharts at render time.\n\tx?: string | number;\n\ty?: string | number;\n\twidth?: string | number;\n\theight?: string | number;\n\tvalue?: React.ReactNode;\n};\n\nfunction BarValueLabel({\n\torientation = \"vertical\",\n\tfontSize,\n\tformatter,\n\tclassName,\n\tx,\n\ty,\n\twidth,\n\theight,\n\tvalue,\n}: BarValueLabelProps) {\n\tconst valueFontSize = BAR_CHART_LAYOUT[useComponentSize()].valueFontSize;\n\n\tif (value == null || x == null || y == null || width == null) {\n\t\treturn null;\n\t}\n\n\tconst numX = Number(x);\n\tconst numY = Number(y);\n\tconst numWidth = Number(width);\n\tconst numHeight = Number(height ?? 0);\n\tconst gap = 6;\n\n\tconst isHorizontal = orientation === \"horizontal\";\n\tconst labelX = isHorizontal ? numX + numWidth + gap : numX + numWidth / 2;\n\tconst labelY = isHorizontal ? numY + numHeight / 2 : numY - gap;\n\n\treturn (\n\t\t<text\n\t\t\tx={labelX}\n\t\t\ty={labelY}\n\t\t\ttextAnchor={isHorizontal ? \"start\" : \"middle\"}\n\t\t\tdominantBaseline={isHorizontal ? \"central\" : \"auto\"}\n\t\t\tclassName={cn(\"fill-fg-primary font-semibold tabular-nums\", className)}\n\t\t\tstyle={{ fontSize: fontSize ?? valueFontSize }}\n\t\t>\n\t\t\t{formatter ? formatter(value) : value}\n\t\t</text>\n\t);\n}\n\nexport { BAR_CHART_LAYOUT, BarValueLabel, useBarChartLayout };\nexport type { BarChartLayout, BarValueLabelProps };\n","import { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { ChevronRightIcon, MoreHorizontalIcon } from \"lucide-react\";\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\n\nfunction Breadcrumb({ className, ...props }: React.ComponentProps<\"nav\">) {\n\treturn (\n\t\t<nav\n\t\t\taria-label=\"breadcrumb\"\n\t\t\tdata-slot=\"breadcrumb\"\n\t\t\tclassName={cn(\"min-w-0\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction BreadcrumbList({ className, ...props }: React.ComponentProps<\"ol\">) {\n\treturn (\n\t\t<ol\n\t\t\tdata-slot=\"breadcrumb-list\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex flex-wrap items-center gap-2 wrap-break-word text-gdt-sm text-fg-secondary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction BreadcrumbItem({ className, ...props }: React.ComponentProps<\"li\">) {\n\treturn (\n\t\t<li\n\t\t\tdata-slot=\"breadcrumb-item\"\n\t\t\tclassName={cn(\"inline-flex min-w-0 items-center gap-2\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction BreadcrumbLink({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"a\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"a\",\n\t\tprops: mergeProps<\"a\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"inline-flex min-w-0 items-center rounded-sm text-gdt-sm font-normal text-fg-secondary transition-colors hover:text-fg-primary focus-visible:outline-none focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)]\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tslot: \"breadcrumb-link\",\n\t\t},\n\t});\n}\n\nfunction BreadcrumbPage({ className, ...props }: React.ComponentProps<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\tdata-slot=\"breadcrumb-page\"\n\t\t\taria-current=\"page\"\n\t\t\tclassName={cn(\n\t\t\t\t\"inline-flex min-w-0 items-center text-gdt-sm font-semibold text-fg-brand\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction BreadcrumbSeparator({\n\tchildren,\n\tclassName,\n\t...props\n}: React.ComponentProps<\"li\">) {\n\treturn (\n\t\t<li\n\t\t\tdata-slot=\"breadcrumb-separator\"\n\t\t\trole=\"presentation\"\n\t\t\taria-hidden=\"true\"\n\t\t\tclassName={cn(\n\t\t\t\t\"inline-flex shrink-0 items-center text-fg-caption-placeholder [&>svg]:size-4 [&>svg]:shrink-0\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children ?? <ChevronRightIcon className=\"cn-rtl-flip\" />}\n\t\t</li>\n\t);\n}\n\nfunction BreadcrumbEllipsis({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\tdata-slot=\"breadcrumb-ellipsis\"\n\t\t\trole=\"presentation\"\n\t\t\taria-hidden=\"true\"\n\t\t\tclassName={cn(\n\t\t\t\t\"inline-flex items-center justify-center text-fg-caption-placeholder [&>svg]:size-4 [&>svg]:shrink-0\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<MoreHorizontalIcon />\n\t\t\t<span className=\"sr-only\">More</span>\n\t\t</span>\n\t);\n}\n\nexport {\n\tBreadcrumb,\n\tBreadcrumbList,\n\tBreadcrumbItem,\n\tBreadcrumbLink,\n\tBreadcrumbPage,\n\tBreadcrumbSeparator,\n\tBreadcrumbEllipsis,\n};\n","\"use client\";\n\nimport type * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\n/**\n * A bullet chart — a compact linear gauge for KPI-vs-goal reporting where a full\n * bar chart would be excessive. It encodes three things on one horizontal track:\n * a **measure** bar (the actualized value), a **target** marker (the forecast to\n * beat), and qualitative **range** bands (poor · satisfactory · good context\n * zones) along a quantitative axis.\n *\n * This is just the gauge — no card, title, or value display — so it composes\n * into whatever surrounds it (a `ChartCard`, a `KpiCard`, a table cell). Unlike\n * the other charts in this folder it is not built on recharts (recharts has no\n * bullet/linear-gauge primitive); it is a few positioned bands, a centered bar,\n * and a tick. It stays size-aware via the shared `SizeProvider` and reuses the\n * brand colour tokens.\n *\n * Status colour signals whether the actual cleared the forecast: `auto` paints\n * the measure bar `status-success` when `value >= target` (OnTrack) and\n * `status-warning` when it falls short (Behind); pass `status` to override.\n *\n * Tokens:\n * - Measure bar — OnTrack `var(--color-status-success)`, Behind\n * `var(--color-status-warning)`\n * - Target marker — `var(--color-fg-primary)`\n * - Range bands — progressively darker `stone` shades (poor → good); the base\n * track is the lightest shade\n * - Axis ticks — `var(--color-fg-caption-placeholder)`\n *\n * @example\n * <BulletChart\n * value={108}\n * target={100}\n * max={120}\n * ranges={[60, 90]}\n * ticks={[0, 60, 120]}\n * valueFormatter={(v) => `₦${v}M`}\n * />\n *\n * @example\n * // Composed under a heading the consumer owns\n * <div className=\"flex flex-col gap-4\">\n * <div className=\"flex items-start justify-between\">\n * <div>\n * <h3 className=\"font-bold\">Revenue</h3>\n * <p className=\"text-fg-secondary\">Actual vs ₦100M forecast</p>\n * </div>\n * <span className=\"text-gdt-h3 font-extrabold\">₦108M</span>\n * </div>\n * <BulletChart value={108} target={100} max={120} ranges={[60, 90]} />\n * </div>\n */\n\n/** Bullet sizes line up with the three shared `ComponentSize` values. */\ntype BulletChartSize = ComponentSize;\n\n/** Measure-bar sentiment — `auto` derives it from `value` vs `target`. */\ntype BulletChartStatus = \"auto\" | \"success\" | \"warning\";\n\ntype BulletChartLayout = {\n\t/** Thickness of the range-band track (the pill) in px. */\n\ttrackHeight: number;\n\t/** Thickness of the centered measure bar in px. */\n\tmeasureHeight: number;\n\t/** Height of the target marker in px — taller than the bar, inside the track. */\n\tmarkerHeight: number;\n\t/** Target marker thickness in px. */\n\tmarkerWidth: number;\n\t/** Axis tick label class. */\n\ttickClass: string;\n};\n\nconst BULLET_CHART_LAYOUT: Record<BulletChartSize, BulletChartLayout> = {\n\tsm: {\n\t\ttrackHeight: 26,\n\t\tmeasureHeight: 11,\n\t\tmarkerHeight: 20,\n\t\tmarkerWidth: 3,\n\t\ttickClass: \"text-gdt-xs\",\n\t},\n\tmd: {\n\t\ttrackHeight: 34,\n\t\tmeasureHeight: 15,\n\t\tmarkerHeight: 26,\n\t\tmarkerWidth: 4,\n\t\ttickClass: \"text-gdt-sm\",\n\t},\n\tlg: {\n\t\ttrackHeight: 44,\n\t\tmeasureHeight: 19,\n\t\tmarkerHeight: 34,\n\t\tmarkerWidth: 5,\n\t\ttickClass: \"text-gdt-sm\",\n\t},\n};\n\n/**\n * Range-band shades, ordered poor → good. The base track is the lightest shade,\n * so the first (poorest) zone blends into it and each higher zone darkens —\n * giving the gauge its qualitative context without competing with the bar.\n */\nconst BULLET_RANGE_PALETTE = [\n\t\"var(--color-stone-200)\",\n\t\"var(--color-stone-300)\",\n\t\"var(--color-stone-400)\",\n] as const;\n\nconst STATUS_COLOR: Record<Exclude<BulletChartStatus, \"auto\">, string> = {\n\tsuccess: \"var(--color-status-success)\",\n\twarning: \"var(--color-status-warning)\",\n};\n\n/** Clamp a value into [min, max] and express it as a 0–100 track percentage. */\nfunction toPercent(value: number, min: number, max: number) {\n\tif (max <= min) return 0;\n\tconst ratio = (value - min) / (max - min);\n\treturn Math.min(Math.max(ratio, 0), 1) * 100;\n}\n\ntype BulletChartProps = Omit<React.ComponentProps<\"div\">, \"children\"> & {\n\t/** The realized (actualized) value — drives the measure bar length. */\n\tvalue: number;\n\t/** The goal to beat — drives the target marker and the auto status colour. */\n\ttarget: number;\n\t/** Axis start. Default 0. */\n\tmin?: number;\n\t/** Axis end. Default the largest of `value`, `target`, and the top range. */\n\tmax?: number;\n\t/** Internal thresholds dividing [min, max] into qualitative zones, ascending. */\n\tranges?: number[];\n\t/** Axis tick values. Default `[min, midpoint, max]`. Pass `[]` to hide. */\n\tticks?: number[];\n\t/** Measure-bar sentiment. Default `auto` (success when `value >= target`). */\n\tstatus?: BulletChartStatus;\n\t/** Explicit size; otherwise inherited from the nearest `SizeProvider`. */\n\tsize?: BulletChartSize;\n\t/** Format the tick labels (and the aria summary). Default grouped integer. */\n\tvalueFormatter?: (value: number) => string;\n};\n\nfunction BulletChart({\n\tvalue,\n\ttarget,\n\tmin = 0,\n\tmax,\n\tranges,\n\tticks,\n\tstatus = \"auto\",\n\tsize,\n\tvalueFormatter = (v) => v.toLocaleString(\"en-NG\"),\n\tclassName,\n\t...props\n}: BulletChartProps) {\n\tconst layout = BULLET_CHART_LAYOUT[useComponentSize(size)];\n\n\tconst topRange = ranges?.length ? Math.max(...ranges) : 0;\n\tconst resolvedMax = max ?? (Math.max(value, target, topRange) || 1);\n\tconst resolvedTicks = ticks ?? [min, (min + resolvedMax) / 2, resolvedMax];\n\n\tconst resolvedStatus =\n\t\tstatus === \"auto\" ? (value >= target ? \"success\" : \"warning\") : status;\n\tconst measureColor = STATUS_COLOR[resolvedStatus];\n\n\t// Zones are the spans between consecutive thresholds (and the axis bounds).\n\tconst thresholds = [\n\t\tmin,\n\t\t...(ranges ?? [])\n\t\t\t.filter((r) => r > min && r < resolvedMax)\n\t\t\t.sort((a, b) => a - b),\n\t\tresolvedMax,\n\t];\n\tconst zones = thresholds.slice(0, -1).map((from, i) => ({\n\t\tfrom,\n\t\tto: thresholds[i + 1],\n\t\tcolor: BULLET_RANGE_PALETTE[Math.min(i, BULLET_RANGE_PALETTE.length - 1)],\n\t}));\n\n\tconst ariaLabel =\n\t\t(props[\"aria-label\"] as string | undefined) ??\n\t\t`${valueFormatter(value)} of ${valueFormatter(target)} target — ${\n\t\t\tresolvedStatus === \"success\" ? \"on track\" : \"behind\"\n\t\t}`;\n\n\treturn (\n\t\t<div\n\t\t\t{...props}\n\t\t\trole=\"img\"\n\t\t\taria-label={ariaLabel}\n\t\t\tclassName={cn(\"flex w-full flex-col gap-2\", className)}\n\t\t>\n\t\t\t<div className=\"relative w-full\" style={{ height: layout.trackHeight }}>\n\t\t\t\t{/* Range bands — the lightest shade is the full-width base track,\n\t\t\t\t darker zones layer on top, all clipped to the pill. */}\n\t\t\t\t<div\n\t\t\t\t\tclassName=\"absolute inset-0 overflow-hidden rounded-full\"\n\t\t\t\t\tstyle={{ backgroundColor: BULLET_RANGE_PALETTE[0] }}\n\t\t\t\t>\n\t\t\t\t\t{zones.map((zone) => (\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tkey={zone.from}\n\t\t\t\t\t\t\tclassName=\"absolute inset-y-0\"\n\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\tleft: `${toPercent(zone.from, min, resolvedMax)}%`,\n\t\t\t\t\t\t\t\twidth: `${\n\t\t\t\t\t\t\t\t\ttoPercent(zone.to, min, resolvedMax) -\n\t\t\t\t\t\t\t\t\ttoPercent(zone.from, min, resolvedMax)\n\t\t\t\t\t\t\t\t}%`,\n\t\t\t\t\t\t\t\tbackgroundColor: zone.color,\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t/>\n\t\t\t\t\t))}\n\t\t\t\t</div>\n\n\t\t\t\t{/* Measure / actual bar — centered, thinner than the track. */}\n\t\t\t\t<div\n\t\t\t\t\tclassName=\"absolute left-0 top-1/2 rounded-full\"\n\t\t\t\t\tstyle={{\n\t\t\t\t\t\theight: layout.measureHeight,\n\t\t\t\t\t\twidth: `${toPercent(value, min, resolvedMax)}%`,\n\t\t\t\t\t\tbackgroundColor: measureColor,\n\t\t\t\t\t\ttransform: \"translateY(-50%)\",\n\t\t\t\t\t}}\n\t\t\t\t/>\n\n\t\t\t\t{/* Target / forecast marker — taller than the bar, inside the track. */}\n\t\t\t\t<div\n\t\t\t\t\tclassName=\"absolute top-1/2 rounded-full bg-fg-primary\"\n\t\t\t\t\tstyle={{\n\t\t\t\t\t\theight: layout.markerHeight,\n\t\t\t\t\t\twidth: layout.markerWidth,\n\t\t\t\t\t\tleft: `${toPercent(target, min, resolvedMax)}%`,\n\t\t\t\t\t\ttransform: \"translate(-50%, -50%)\",\n\t\t\t\t\t}}\n\t\t\t\t/>\n\t\t\t</div>\n\n\t\t\t{resolvedTicks.length > 0 && (\n\t\t\t\t<div className=\"relative h-4 w-full\">\n\t\t\t\t\t{resolvedTicks.map((tick) => {\n\t\t\t\t\t\tconst pct = toPercent(tick, min, resolvedMax);\n\t\t\t\t\t\tconst transform =\n\t\t\t\t\t\t\tpct <= 0\n\t\t\t\t\t\t\t\t? \"translateX(0)\"\n\t\t\t\t\t\t\t\t: pct >= 100\n\t\t\t\t\t\t\t\t\t? \"translateX(-100%)\"\n\t\t\t\t\t\t\t\t\t: \"translateX(-50%)\";\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\tkey={tick}\n\t\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\t\"absolute top-0 whitespace-nowrap tabular-nums text-fg-caption-placeholder\",\n\t\t\t\t\t\t\t\t\tlayout.tickClass,\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\tstyle={{ left: `${pct}%`, transform }}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{valueFormatter(tick)}\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t);\n\t\t\t\t\t})}\n\t\t\t\t</div>\n\t\t\t)}\n\t\t</div>\n\t);\n}\n\nexport { BULLET_CHART_LAYOUT, BULLET_RANGE_PALETTE, BulletChart };\nexport type {\n\tBulletChartLayout,\n\tBulletChartProps,\n\tBulletChartSize,\n\tBulletChartStatus,\n};\n","import { Button as ButtonPrimitive } from \"@base-ui/react/button\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { Loader } from \"lucide-react\";\nimport type * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { useComponentSize } from \"./size-context\";\n\nconst buttonVariants = cva(\n\t\"group/button inline-flex shrink-0 items-center justify-center rounded-full bg-clip-padding whitespace-nowrap font-bold transition-[background-color,color,border-color,box-shadow,transform] outline-none select-none focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 aria-invalid:border-line-danger aria-invalid:ring-3 aria-invalid:ring-destructive/20 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n\t{\n\t\tvariants: {\n\t\t\tvariant: {\n\t\t\t\tprimary:\n\t\t\t\t\t\"bg-action-primary text-fg-on-brand hover:bg-action-primary-hover active:bg-action-primary-pressed\",\n\t\t\t\t\"primary-outline\":\n\t\t\t\t\t\"border-2 border-action-primary bg-transparent text-fg-brand hover:bg-surface-brand-subtle active:bg-surface-brand-subtle data-focused:bg-surface-brand-subtle data-pressed:bg-surface-brand-subtle\",\n\t\t\t\tsecondary:\n\t\t\t\t\t\"bg-surface-brand-subtle text-fg-brand hover:bg-action-primary-hover hover:text-fg-on-brand active:bg-action-primary-pressed active:text-fg-on-brand data-focused:bg-action-primary-hover data-pressed:bg-action-primary-pressed data-focused:text-fg-on-brand data-pressed:text-fg-on-brand\",\n\t\t\t\t\"secondary-outline\":\n\t\t\t\t\t\"border-2 border-action-secondary bg-transparent text-fg-brand hover:bg-surface-brand-subtle active:bg-surface-brand-subtle data-focused:bg-surface-brand-subtle data-pressed:bg-surface-brand-subtle\",\n\t\t\t\ttertiary:\n\t\t\t\t\t\"bg-action-tertiary text-fg-primary hover:bg-action-tertiary-hover active:bg-action-tertiary-pressed data-focused:bg-action-tertiary-hover data-pressed:bg-action-tertiary-pressed\",\n\t\t\t\t\"tertiary-outline\":\n\t\t\t\t\t\"border border-line-strong bg-transparent text-fg-primary hover:bg-surface active:bg-surface-raised data-focused:bg-surface data-pressed:bg-surface-raised\",\n\t\t\t\tghost:\n\t\t\t\t\t\"bg-transparent text-fg-primary hover:bg-surface active:bg-surface-raised data-focused:bg-surface data-pressed:bg-surface-raised\",\n\t\t\t\tdanger:\n\t\t\t\t\t\"bg-action-danger text-fg-on-brand hover:bg-action-danger-hover active:bg-action-danger-pressed data-focused:bg-action-danger-hover data-pressed:bg-action-danger-pressed\",\n\t\t\t\t\"glass-overlay\": \"bg-surface-glass-overlay-button text-fg-on-brand\",\n\t\t\t\t\"link-brand\":\n\t\t\t\t\t\"border-transparent bg-transparent px-0 text-fg-brand hover:underline active:underline active:opacity-70\",\n\t\t\t\t\"link-neutral\":\n\t\t\t\t\t\"border-transparent bg-transparent px-0 text-fg-secondary hover:underline active:underline active:opacity-70\",\n\t\t\t},\n\t\t\tsize: {\n\t\t\t\tsm: \"h-8 gap-2 px-3.5 text-gdt-xs has-data-[icon=inline-end]:pr-3 has-data-[icon=inline-start]:pl-3 [&_svg:not([class*='size-'])]:size-3.5\",\n\t\t\t\tmd: \"h-10 gap-2 px-4.5 text-gdt-sm has-data-[icon=inline-end]:pr-4 has-data-[icon=inline-start]:pl-4\",\n\t\t\t\tlg: \"h-12.5 gap-2.5 px-5.5 text-gdt-md has-data-[icon=inline-end]:pr-5 has-data-[icon=inline-start]:pl-5 [&_svg:not([class*='size-'])]:size-4.5\",\n\t\t\t\txl: \"h-14 gap-3 px-6.5 text-gdt-lg has-data-[icon=inline-end]:pr-6 has-data-[icon=inline-start]:pl-6 [&_svg:not([class*='size-'])]:size-5\",\n\t\t\t\ticon: \"size-10\",\n\t\t\t\t\"icon-xs\": \"size-6 text-gdt-xs [&_svg:not([class*='size-'])]:size-3\",\n\t\t\t\t\"icon-sm\": \"size-8 text-gdt-sm [&_svg:not([class*='size-'])]:size-3.5\",\n\t\t\t\t\"icon-lg\":\n\t\t\t\t\t\"size-12.5 text-gdt-md [&_svg:not([class*='size-'])]:size-4.5\",\n\t\t\t\t\"icon-xl\": \"size-14 text-gdt-lg [&_svg:not([class*='size-'])]:size-5\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tvariant: \"primary\",\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\ntype ButtonSize = NonNullable<VariantProps<typeof buttonVariants>[\"size\"]>;\n\nfunction Button({\n\tclassName,\n\tvariant = \"primary\",\n\tsize,\n\tisLoading = false,\n\tchildren,\n\tdisabled = false,\n\t...props\n}: ButtonPrimitive.Props &\n\tVariantProps<typeof buttonVariants> & { isLoading?: boolean }) {\n\tconst inheritedSize = useComponentSize();\n\tconst resolvedSize = size ?? inheritedSize;\n\tconst _disabled = disabled || isLoading;\n\treturn (\n\t\t<ButtonPrimitive\n\t\t\tdata-slot=\"button\"\n\t\t\tclassName={cn(buttonVariants({ variant, size: resolvedSize, className }))}\n\t\t\tdisabled={_disabled}\n\t\t\t{...props}\n\t\t>\n\t\t\t{isLoading && <Loader className=\"size-4 animate-spin\" />} {children}\n\t\t</ButtonPrimitive>\n\t);\n}\n\ntype ButtonLinkProps = Omit<React.ComponentProps<\"a\">, \"href\"> &\n\tVariantProps<typeof buttonVariants> & {\n\t\tdisabled?: boolean;\n\t\thref: string;\n\t};\n\nfunction ButtonLink({\n\tclassName,\n\thref,\n\tvariant = \"primary\",\n\tsize,\n\tdisabled = false,\n\tonClick,\n\t...props\n}: ButtonLinkProps) {\n\tconst inheritedSize = useComponentSize();\n\tconst resolvedSize: ButtonSize = size ?? inheritedSize;\n\n\treturn (\n\t\t<a\n\t\t\tdata-slot=\"button-link\"\n\t\t\thref={href}\n\t\t\taria-disabled={disabled}\n\t\t\ttabIndex={disabled ? -1 : props.tabIndex}\n\t\t\tclassName={cn(buttonVariants({ variant, size: resolvedSize, className }))}\n\t\t\tonClick={(event) => {\n\t\t\t\tif (disabled) {\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tonClick?.(event);\n\t\t\t}}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Button, ButtonLink, buttonVariants };\n","import { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { cn } from \"../../lib/cn\";\nimport { Separator } from \"./separator\";\nimport {\n\ttype ComponentSize,\n\tSizeProvider,\n\tuseComponentSize,\n} from \"./size-context\";\n\nconst buttonGroupVariants = cva(\n\t\"flex w-fit items-stretch *:focus-visible:relative *:focus-visible:z-10 has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-lg [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1\",\n\t{\n\t\tvariants: {\n\t\t\torientation: {\n\t\t\t\thorizontal:\n\t\t\t\t\t\"*:data-slot:rounded-r-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-r-full! [&>[data-slot]~[data-slot]]:rounded-l-none [&>[data-slot]~[data-slot]]:border-l-0\",\n\t\t\t\tvertical:\n\t\t\t\t\t\"flex-col *:data-slot:rounded-b-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-b-full! [&>[data-slot]~[data-slot]]:rounded-t-none [&>[data-slot]~[data-slot]]:border-t-0\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\torientation: \"horizontal\",\n\t\t},\n\t},\n);\n\nfunction ButtonGroup({\n\tclassName,\n\torientation,\n\t...props\n}: React.ComponentProps<\"div\"> &\n\tVariantProps<typeof buttonGroupVariants> & { size?: ComponentSize }) {\n\tconst size = useComponentSize();\n\n\treturn (\n\t\t<SizeProvider size={size}>\n\t\t\t{/* biome-ignore lint/a11y/useSemanticElements: this primitive groups composite controls without forcing fieldset semantics. */}\n\t\t\t<div\n\t\t\t\trole=\"group\"\n\t\t\t\tdata-slot=\"button-group\"\n\t\t\t\tdata-orientation={orientation}\n\t\t\t\tclassName={cn(buttonGroupVariants({ orientation }), className)}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t</SizeProvider>\n\t);\n}\n\nfunction ButtonGroupText({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"div\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"div\",\n\t\tprops: mergeProps<\"div\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"flex items-center gap-2 rounded-lg border bg-muted px-2.5 text-sm font-medium [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tslot: \"button-group-text\",\n\t\t},\n\t});\n}\n\nfunction ButtonGroupSeparator({\n\tclassName,\n\torientation = \"vertical\",\n\t...props\n}: React.ComponentProps<typeof Separator>) {\n\treturn (\n\t\t<Separator\n\t\t\tdata-slot=\"button-group-separator\"\n\t\t\torientation={orientation}\n\t\t\tclassName={cn(\n\t\t\t\t\"relative self-stretch bg-input data-horizontal:mx-px data-horizontal:w-auto data-vertical:my-px data-vertical:h-auto\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tButtonGroup,\n\tButtonGroupSeparator,\n\tButtonGroupText,\n\tbuttonGroupVariants,\n};\n","\"use client\";\n\nimport { Separator as SeparatorPrimitive } from \"@base-ui/react/separator\";\nimport { cn } from \"../../lib/cn\";\n\nfunction Separator({\n\tclassName,\n\torientation = \"horizontal\",\n\tdashed = false,\n\tshade = \"feint\",\n\tthickness = \"default\",\n\t...props\n}: SeparatorPrimitive.Props & {\n\tdashed?: boolean;\n\tshade?: \"feint\" | \"deep\";\n\tthickness?: \"hairline\" | \"default\" | \"thick\" | \"extra-thick\";\n}) {\n\treturn (\n\t\t<SeparatorPrimitive\n\t\t\tdata-slot=\"separator\"\n\t\t\torientation={orientation}\n\t\t\tclassName={cn(\n\t\t\t\t\"shrink-0 data-horizontal:h-0 data-horizontal:w-full data-vertical:w-0 data-vertical:self-stretch\",\n\t\t\t\t// style\n\t\t\t\tdashed ? \"border-dashed\" : \"border-solid\",\n\t\t\t\t// shade\n\t\t\t\tshade === \"feint\" && \"border-line-subtle\",\n\t\t\t\tshade === \"deep\" && \"border-line\",\n\t\t\t\t// thickness\n\t\t\t\tthickness === \"hairline\" &&\n\t\t\t\t\t\"data-horizontal:border-t-[0.5px] data-vertical:border-l-[0.5px]\",\n\t\t\t\tthickness === \"default\" &&\n\t\t\t\t\t\"data-horizontal:border-t data-vertical:border-l\",\n\t\t\t\tthickness === \"thick\" &&\n\t\t\t\t\t\"data-horizontal:border-t-2 data-vertical:border-l-2\",\n\t\t\t\tthickness === \"extra-thick\" &&\n\t\t\t\t\t\"data-horizontal:border-t-[3px] data-vertical:border-l-[3px]\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Separator };\n","\"use client\";\n\nimport { ChevronLeftIcon, ChevronRightIcon } from \"lucide-react\";\nimport * as React from \"react\";\nimport {\n\ttype DayButton,\n\tDayPicker,\n\tgetDefaultClassNames,\n\ttype Locale,\n} from \"react-day-picker\";\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\n\nfunction Calendar({\n\tclassName,\n\tclassNames,\n\tshowOutsideDays = false,\n\tweekStartsOn = 1,\n\tlocale,\n\tformatters,\n\tcomponents,\n\t...props\n}: React.ComponentProps<typeof DayPicker>) {\n\tconst defaultClassNames = getDefaultClassNames();\n\n\treturn (\n\t\t<DayPicker\n\t\t\tshowOutsideDays={showOutsideDays}\n\t\t\tweekStartsOn={weekStartsOn}\n\t\t\tclassName={cn(\n\t\t\t\t\"group/calendar bg-transparent p-4 [--cell-radius:var(--radius-md)] [--cell-height:36px] [--cell-width:40px]\",\n\t\t\t\tString.raw`rtl:**:[.rdp-button\\_next>svg]:rotate-180`,\n\t\t\t\tString.raw`rtl:**:[.rdp-button\\_previous>svg]:rotate-180`,\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tlocale={locale}\n\t\t\tformatters={{\n\t\t\t\tformatWeekdayName: (date) =>\n\t\t\t\t\tdate.toLocaleString(locale?.code, { weekday: \"narrow\" }),\n\t\t\t\t...formatters,\n\t\t\t}}\n\t\t\tclassNames={{\n\t\t\t\troot: cn(\"w-fit\", defaultClassNames.root),\n\t\t\t\tmonths: cn(\n\t\t\t\t\t\"relative flex flex-col gap-4 md:flex-row\",\n\t\t\t\t\tdefaultClassNames.months,\n\t\t\t\t),\n\t\t\t\tmonth: cn(\"flex w-full flex-col gap-4\", defaultClassNames.month),\n\t\t\t\tnav: cn(\n\t\t\t\t\t\"absolute inset-x-0 top-0 flex w-full items-center justify-between gap-1\",\n\t\t\t\t\tdefaultClassNames.nav,\n\t\t\t\t),\n\t\t\t\tbutton_previous: cn(\n\t\t\t\t\t\"flex size-7 items-center justify-center rounded-(--cell-radius) text-fg-secondary transition-colors outline-none select-none hover:bg-surface focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] aria-disabled:opacity-40\",\n\t\t\t\t\tdefaultClassNames.button_previous,\n\t\t\t\t),\n\t\t\t\tbutton_next: cn(\n\t\t\t\t\t\"flex size-7 items-center justify-center rounded-(--cell-radius) text-fg-secondary transition-colors outline-none select-none hover:bg-surface focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] aria-disabled:opacity-40\",\n\t\t\t\t\tdefaultClassNames.button_next,\n\t\t\t\t),\n\t\t\t\tmonth_caption: cn(\n\t\t\t\t\t\"flex h-(--cell-height) w-full items-center justify-center px-(--cell-width)\",\n\t\t\t\t\tdefaultClassNames.month_caption,\n\t\t\t\t),\n\t\t\t\tcaption_label: cn(\n\t\t\t\t\t\"text-gdt-sm font-medium text-fg-primary select-none\",\n\t\t\t\t\tdefaultClassNames.caption_label,\n\t\t\t\t),\n\t\t\t\ttable: \"w-full border-collapse\",\n\t\t\t\tweekdays: cn(\"flex\", defaultClassNames.weekdays),\n\t\t\t\tweekday: cn(\n\t\t\t\t\t\"flex-1 text-gdt-xs font-normal text-fg-secondary select-none\",\n\t\t\t\t\tdefaultClassNames.weekday,\n\t\t\t\t),\n\t\t\t\tweek: cn(\"mt-1 flex w-full\", defaultClassNames.week),\n\t\t\t\tday: cn(\n\t\t\t\t\t\"group/day relative aspect-square h-full w-full p-0 text-center select-none\",\n\t\t\t\t\tdefaultClassNames.day,\n\t\t\t\t),\n\t\t\t\trange_start: cn(\n\t\t\t\t\t\"rounded-l-full bg-surface-brand-subtle\",\n\t\t\t\t\tdefaultClassNames.range_start,\n\t\t\t\t),\n\t\t\t\trange_middle: cn(\n\t\t\t\t\t\"rounded-none bg-surface-brand-subtle\",\n\t\t\t\t\tdefaultClassNames.range_middle,\n\t\t\t\t),\n\t\t\t\trange_end: cn(\n\t\t\t\t\t\"rounded-r-full bg-surface-brand-subtle\",\n\t\t\t\t\tdefaultClassNames.range_end,\n\t\t\t\t),\n\t\t\t\ttoday: cn(\n\t\t\t\t\t\"rounded-full h-(--cell-height) w-(--cell-width) flex items-center justify-center bg-surface-brand-subtle p-0\",\n\t\t\t\t\tdefaultClassNames.today,\n\t\t\t\t),\n\t\t\t\toutside: cn(\n\t\t\t\t\t\"text-fg-caption-placeholder aria-selected:text-fg-caption-placeholder\",\n\t\t\t\t\tdefaultClassNames.outside,\n\t\t\t\t),\n\t\t\t\tdisabled: cn(\n\t\t\t\t\t\"text-fg-caption-placeholder opacity-50\",\n\t\t\t\t\tdefaultClassNames.disabled,\n\t\t\t\t),\n\t\t\t\thidden: cn(\"invisible\", defaultClassNames.hidden),\n\t\t\t\t...classNames,\n\t\t\t}}\n\t\t\tcomponents={{\n\t\t\t\tRoot: ({ className, rootRef, ...props }) => {\n\t\t\t\t\treturn (\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tdata-slot=\"calendar\"\n\t\t\t\t\t\t\tref={rootRef}\n\t\t\t\t\t\t\tclassName={cn(className)}\n\t\t\t\t\t\t\t{...props}\n\t\t\t\t\t\t/>\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\tChevron: ({ className, orientation, ...props }) => {\n\t\t\t\t\tif (orientation === \"right\") {\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t<ChevronRightIcon\n\t\t\t\t\t\t\t\tclassName={cn(\"size-4\", className)}\n\t\t\t\t\t\t\t\t{...props}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\n\t\t\t\t\treturn (\n\t\t\t\t\t\t<ChevronLeftIcon className={cn(\"size-4\", className)} {...props} />\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\tDayButton: ({ ...props }) => (\n\t\t\t\t\t<CalendarDayButton locale={locale} {...props} />\n\t\t\t\t),\n\t\t\t\tWeekNumber: ({ children, ...props }) => {\n\t\t\t\t\treturn (\n\t\t\t\t\t\t<td {...props}>\n\t\t\t\t\t\t\t<div className=\"flex h-(--cell-height) w-(--cell-width) items-center justify-center text-center\">\n\t\t\t\t\t\t\t\t{children}\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\t...components,\n\t\t\t}}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction CalendarDayButton({\n\tclassName,\n\tday,\n\tmodifiers,\n\tlocale,\n\t...props\n}: React.ComponentProps<typeof DayButton> & { locale?: Partial<Locale> }) {\n\tconst defaultClassNames = getDefaultClassNames();\n\n\tconst ref = React.useRef<HTMLButtonElement>(null);\n\tReact.useEffect(() => {\n\t\tif (modifiers.focused) ref.current?.focus();\n\t}, [modifiers.focused]);\n\n\tconst isEndpoint =\n\t\t(modifiers.selected &&\n\t\t\t!modifiers.range_start &&\n\t\t\t!modifiers.range_end &&\n\t\t\t!modifiers.range_middle) ||\n\t\tmodifiers.range_start ||\n\t\tmodifiers.range_end;\n\n\treturn (\n\t\t<Button\n\t\t\tref={ref}\n\t\t\tvariant=\"ghost\"\n\t\t\tsize=\"icon\"\n\t\t\tdata-day={day.date.toLocaleDateString(locale?.code)}\n\t\t\tdata-selected-single={\n\t\t\t\tmodifiers.selected &&\n\t\t\t\t!modifiers.range_start &&\n\t\t\t\t!modifiers.range_end &&\n\t\t\t\t!modifiers.range_middle\n\t\t\t}\n\t\t\tdata-range-start={modifiers.range_start}\n\t\t\tdata-range-end={modifiers.range_end}\n\t\t\tdata-range-middle={modifiers.range_middle}\n\t\t\tclassName={cn(\n\t\t\t\t\"relative isolate z-10 flex aspect-square size-auto w-full min-w-(--cell-width) h-(--cell-height) items-center justify-center rounded-full border-0 text-gdt-sm font-normal leading-none\",\n\t\t\t\t// Selected single + range endpoints: filled brand circle.\n\t\t\t\t\"data-[range-end=true]:bg-action-primary data-[range-end=true]:text-fg-on-brand data-[range-end=true]:hover:bg-action-primary-hover data-[range-end=true]:hover:text-fg-on-brand\",\n\t\t\t\t\"data-[range-start=true]:bg-action-primary data-[range-start=true]:text-fg-on-brand data-[range-start=true]:hover:bg-action-primary-hover data-[range-start=true]:hover:text-fg-on-brand\",\n\t\t\t\t\"data-[selected-single=true]:bg-action-primary data-[selected-single=true]:text-fg-on-brand data-[selected-single=true]:hover:bg-action-primary-hover data-[selected-single=true]:hover:text-fg-on-brand\",\n\t\t\t\t// In-range days: brand wash carried by the cell, brand text on the button.\n\t\t\t\t\"data-[range-middle=true]:rounded-none data-[range-middle=true]:bg-transparent data-[range-middle=true]:text-fg-brand data-[range-middle=true]:hover:bg-transparent\",\n\t\t\t\tisEndpoint && \"font-medium\",\n\t\t\t\t\"group-data-[focused=true]/day:border-line-focus group-data-[focused=true]/day:shadow-[0px_0px_0px_2px_var(--color-line-focus)]\",\n\t\t\t\tdefaultClassNames.day,\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Calendar, CalendarDayButton };\n","import { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\n\nimport { cn } from \"../../lib/cn\";\n\nconst cardVariants = cva(\n\t\"group/card relative flex w-full min-w-0 flex-col gap-5 rounded-2xl border border-line-subtle bg-canvas py-gdt-xl text-fg-primary shadow-1 transition-[background-color,border-color,box-shadow,transform] outline-none has-[[data-slot=card-action]:hover]:shadow-2 has-[[data-slot=card-action]:focus-visible]:border-line-focus has-[[data-slot=card-action]:focus-visible]inset-ring-1 has-[[data-slot=card-action]:focus-visible]:ring-line-focus has-[[data-slot=card-action]:active]:border-line-subtle has-[[data-slot=card-action]:active]:bg-surface has-[[data-slot=card-action]:active]:shadow-none!\",\n\t{\n\t\tvariants: {\n\t\t\tselected: {\n\t\t\t\ttrue: \"border-line-focus bg-surface-brand-subtle inset-ring-1 inset-ring-line-focus has-[[data-slot=card-action]:hover]:border-line-focus has-[[data-slot=card-action]:hover]:bg-surface-brand-subtle has-[[data-slot=card-action]:hover]:inset-ring-1 has-[[data-slot=card-action]:active]:border-line-focus has-[[data-slot=card-action]:active]:bg-surface-brand-subtle has-[[data-slot=card-action]:active]:inset-ring-1 has-[[data-slot=card-action]:active]:inset-ring-line-focus\",\n\t\t\t\tfalse: \"\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tselected: false,\n\t\t},\n\t},\n);\n\ntype CardProps = useRender.ComponentProps<\"article\"> &\n\tVariantProps<typeof cardVariants>;\n\nfunction Card({ className, render, selected = false, ...props }: CardProps) {\n\treturn useRender({\n\t\tdefaultTagName: \"article\",\n\t\tprops: mergeProps<\"article\">(\n\t\t\t{\n\t\t\t\tclassName: cn(cardVariants({ selected }), className),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tselected,\n\t\t\tslot: \"card\",\n\t\t},\n\t});\n}\n\nfunction CardTitle({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"h3\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"h3\",\n\t\tprops: mergeProps<\"h3\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\"text-gdt-h5 text-fg-primary\", className),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction CardHeader({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"div\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"div\",\n\t\tprops: mergeProps<\"div\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\"flex min-w-0 flex-col gap-gdt-sm px-gdt-xl\", className),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction CardDescription({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"p\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"p\",\n\t\tprops: mergeProps<\"p\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\"text-gdt-sm font-normal text-fg-primary\", className),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction CardContent({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"div\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"div\",\n\t\tprops: mergeProps<\"div\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"min-w-0 px-gdt-xl text-gdt-sm text-fg-primary\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction CardFooter({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"div\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"div\",\n\t\tprops: mergeProps<\"div\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"flex min-w-0 px-gdt-xl flex-wrap items-center justify-end gap-gdt-sm\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction CardAction({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"button\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"button\",\n\t\tprops: mergeProps<\"button\">(\n\t\t\t{\n\t\t\t\t// @ts-expect-error — data-* attrs are valid but not in mergeProps generic\n\t\t\t\t\"data-slot\": \"card-action\",\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"cursor-pointer focus-visible:outline-none before:absolute before:inset-0 before:content-['']\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\n/**\n * Card is always a semantic container (article). Use CardAction to make the\n * whole card interactive — it stretches a ::before pseudo-element over the\n * entire card area while keeping the markup accessible.\n *\n * CardAction defaults to `button` but accepts any interactive element via\n * the `render` prop (e.g. `render={<a href=\"...\" />}` or\n * `render={<label htmlFor=\"my-checkbox\" />}`).\n *\n * Other interactive elements inside the card (e.g. footer buttons) must have\n * `className=\"relative\"` so they stack above CardAction's pseudo-element.\n *\n * <Card>\n * <CardAction render={<a href=\"/path\" />} />\n * <CardHeader>\n * <CardTitle>Card Title</CardTitle>\n * <CardDescription>\n * Body content area for descriptive text, supporting copy, or other\n * inline content as needed.\n * </CardDescription>\n * </CardHeader>\n * <CardContent>{...}</CardContent>\n * <CardFooter>\n * <Button variant=\"tertiary\" size=\"sm\" className=\"relative\">Cancel</Button>\n * <Button size=\"sm\" className=\"relative\">Confirm</Button>\n * </CardFooter>\n * </Card>\n */\nexport {\n\tCard,\n\tCardAction,\n\tCardContent,\n\tCardDescription,\n\tCardFooter,\n\tCardHeader,\n\tCardTitle,\n\tcardVariants,\n};\nexport type { CardProps };\n","\"use client\";\n\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport useEmblaCarousel, {\n\ttype UseEmblaCarouselType,\n} from \"embla-carousel-react\";\nimport { ChevronLeftIcon, ChevronRightIcon } from \"lucide-react\";\nimport * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\ntype CarouselApi = UseEmblaCarouselType[1];\ntype UseCarouselParameters = Parameters<typeof useEmblaCarousel>;\ntype CarouselOptions = UseCarouselParameters[0];\ntype CarouselPlugin = UseCarouselParameters[1];\n\n/**\n * Shared glassmorphic treatment for every overlay surface in the carousel\n * (navigation arrows + indicator). Dark glass at 35% over a 16px backdrop\n * blur with a near-invisible 18% light border that lifts the chrome off the\n * imagery. Always dark, in both themes — see `--color-surface-glass-overlay-button`.\n */\nconst glassChrome =\n\t\"border border-fg-on-brand/[0.18] bg-surface-glass-overlay-button backdrop-blur-[16px]\";\n\nconst carouselVariants = cva(\n\t\"relative overflow-hidden rounded-2xl bg-surface-brand-subtle\",\n\t{\n\t\tvariants: {\n\t\t\timageSize: {\n\t\t\t\tsm: \"w-[320px] max-w-full aspect-[320/220]\",\n\t\t\t\tmd: \"w-[520px] max-w-full aspect-[520/340]\",\n\t\t\t\tlg: \"w-[800px] max-w-full aspect-[800/500]\",\n\t\t\t\tfull: \"w-full\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\timageSize: \"md\",\n\t\t},\n\t},\n);\n\ntype CarouselContextProps = {\n\tcarouselRef: ReturnType<typeof useEmblaCarousel>[0];\n\tapi: CarouselApi;\n\torientation: \"horizontal\" | \"vertical\";\n\tsize: ComponentSize;\n\tscrollPrev: () => void;\n\tscrollNext: () => void;\n\tscrollTo: (index: number) => void;\n\tcanScrollPrev: boolean;\n\tcanScrollNext: boolean;\n\tselectedIndex: number;\n\tscrollSnaps: number[];\n};\n\nconst CarouselContext = React.createContext<CarouselContextProps | null>(null);\n\nfunction useCarousel() {\n\tconst context = React.useContext(CarouselContext);\n\n\tif (!context) {\n\t\tthrow new Error(\"useCarousel must be used within a <Carousel />\");\n\t}\n\n\treturn context;\n}\n\ntype CarouselProps = {\n\topts?: CarouselOptions;\n\tplugins?: CarouselPlugin;\n\torientation?: \"horizontal\" | \"vertical\";\n\t/** Scales the chrome (arrows + indicator) without touching the image. */\n\tsize?: ComponentSize;\n\tsetApi?: (api: CarouselApi) => void;\n};\n\nfunction Carousel({\n\torientation = \"horizontal\",\n\topts,\n\tsetApi,\n\tplugins,\n\tsize,\n\timageSize,\n\tclassName,\n\tchildren,\n\t...props\n}: React.ComponentProps<\"div\"> &\n\tCarouselProps &\n\tVariantProps<typeof carouselVariants>) {\n\tconst resolvedSize = useComponentSize(size);\n\tconst [carouselRef, api] = useEmblaCarousel(\n\t\t{\n\t\t\t...opts,\n\t\t\taxis: orientation === \"horizontal\" ? \"x\" : \"y\",\n\t\t},\n\t\tplugins,\n\t);\n\tconst [canScrollPrev, setCanScrollPrev] = React.useState(false);\n\tconst [canScrollNext, setCanScrollNext] = React.useState(false);\n\tconst [selectedIndex, setSelectedIndex] = React.useState(0);\n\tconst [scrollSnaps, setScrollSnaps] = React.useState<number[]>([]);\n\n\tconst onSelect = React.useCallback((api: CarouselApi) => {\n\t\tif (!api) return;\n\t\tsetCanScrollPrev(api.canScrollPrev());\n\t\tsetCanScrollNext(api.canScrollNext());\n\t\tsetSelectedIndex(api.selectedScrollSnap());\n\t}, []);\n\n\tconst onReInit = React.useCallback(\n\t\t(api: CarouselApi) => {\n\t\t\tif (!api) return;\n\t\t\tsetScrollSnaps(api.scrollSnapList());\n\t\t\tonSelect(api);\n\t\t},\n\t\t[onSelect],\n\t);\n\n\tconst scrollPrev = React.useCallback(() => {\n\t\tapi?.scrollPrev();\n\t}, [api]);\n\n\tconst scrollNext = React.useCallback(() => {\n\t\tapi?.scrollNext();\n\t}, [api]);\n\n\tconst scrollTo = React.useCallback(\n\t\t(index: number) => {\n\t\t\tapi?.scrollTo(index);\n\t\t},\n\t\t[api],\n\t);\n\n\tconst handleKeyDown = React.useCallback(\n\t\t(event: React.KeyboardEvent<HTMLDivElement>) => {\n\t\t\tif (event.key === \"ArrowLeft\") {\n\t\t\t\tevent.preventDefault();\n\t\t\t\tscrollPrev();\n\t\t\t} else if (event.key === \"ArrowRight\") {\n\t\t\t\tevent.preventDefault();\n\t\t\t\tscrollNext();\n\t\t\t}\n\t\t},\n\t\t[scrollPrev, scrollNext],\n\t);\n\n\tReact.useEffect(() => {\n\t\tif (!api || !setApi) return;\n\t\tsetApi(api);\n\t}, [api, setApi]);\n\n\tReact.useEffect(() => {\n\t\tif (!api) return;\n\t\tonReInit(api);\n\t\tapi.on(\"reInit\", onReInit);\n\t\tapi.on(\"select\", onSelect);\n\n\t\treturn () => {\n\t\t\tapi?.off(\"reInit\", onReInit);\n\t\t\tapi?.off(\"select\", onSelect);\n\t\t};\n\t}, [api, onReInit, onSelect]);\n\n\treturn (\n\t\t<CarouselContext.Provider\n\t\t\tvalue={{\n\t\t\t\tcarouselRef,\n\t\t\t\tapi,\n\t\t\t\torientation,\n\t\t\t\tsize: resolvedSize,\n\t\t\t\tscrollPrev,\n\t\t\t\tscrollNext,\n\t\t\t\tscrollTo,\n\t\t\t\tcanScrollPrev,\n\t\t\t\tcanScrollNext,\n\t\t\t\tselectedIndex,\n\t\t\t\tscrollSnaps,\n\t\t\t}}\n\t\t>\n\t\t\t{/* biome-ignore lint/a11y/useSemanticElements: the W3C carousel pattern is a region with aria-roledescription, not a generic landmark element. */}\n\t\t\t<div\n\t\t\t\tonKeyDownCapture={handleKeyDown}\n\t\t\t\tclassName={cn(carouselVariants({ imageSize }), className)}\n\t\t\t\trole=\"region\"\n\t\t\t\taria-roledescription=\"carousel\"\n\t\t\t\tdata-slot=\"carousel\"\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</div>\n\t\t</CarouselContext.Provider>\n\t);\n}\n\nfunction CarouselContent({ className, ...props }: React.ComponentProps<\"div\">) {\n\tconst { carouselRef, orientation } = useCarousel();\n\n\treturn (\n\t\t<div\n\t\t\tref={carouselRef}\n\t\t\tclassName=\"h-full overflow-hidden\"\n\t\t\tdata-slot=\"carousel-content\"\n\t\t>\n\t\t\t<div\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"flex h-full\",\n\t\t\t\t\torientation === \"horizontal\" ? \"\" : \"flex-col\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t</div>\n\t);\n}\n\nfunction CarouselItem({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t// biome-ignore lint/a11y/useSemanticElements: a carousel slide is a role=\"group\" with aria-roledescription per the W3C pattern, not a fieldset.\n\t\t<div\n\t\t\trole=\"group\"\n\t\t\taria-roledescription=\"slide\"\n\t\t\tdata-slot=\"carousel-item\"\n\t\t\tclassName={cn(\"min-w-0 shrink-0 grow-0 basis-full\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst arrowVariants = cva(\n\tcn(\n\t\t\"absolute top-1/2 z-10 grid -translate-y-1/2 place-items-center rounded-full text-fg-on-brand/95 shadow-1 transition-[transform,opacity] outline-none\",\n\t\tglassChrome,\n\t\t\"hover:scale-105 focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] active:scale-95 disabled:pointer-events-none disabled:opacity-40\",\n\t),\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"size-8 [&_svg]:size-4\",\n\t\t\t\tmd: \"size-10 [&_svg]:size-[18px]\",\n\t\t\t\tlg: \"size-12 [&_svg]:size-5\",\n\t\t\t},\n\t\t\tside: {\n\t\t\t\tprev: \"\",\n\t\t\t\tnext: \"\",\n\t\t\t},\n\t\t},\n\t\tcompoundVariants: [\n\t\t\t{ size: \"sm\", side: \"prev\", className: \"left-3\" },\n\t\t\t{ size: \"sm\", side: \"next\", className: \"right-3\" },\n\t\t\t{ size: \"md\", side: \"prev\", className: \"left-4\" },\n\t\t\t{ size: \"md\", side: \"next\", className: \"right-4\" },\n\t\t\t{ size: \"lg\", side: \"prev\", className: \"left-5\" },\n\t\t\t{ size: \"lg\", side: \"next\", className: \"right-5\" },\n\t\t],\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t\tside: \"prev\",\n\t\t},\n\t},\n);\n\nfunction CarouselPrevious({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"button\">) {\n\tconst { size, scrollPrev, canScrollPrev } = useCarousel();\n\n\treturn (\n\t\t<button\n\t\t\ttype=\"button\"\n\t\t\tdata-slot=\"carousel-previous\"\n\t\t\tclassName={cn(arrowVariants({ size, side: \"prev\" }), className)}\n\t\t\tdisabled={!canScrollPrev}\n\t\t\tonClick={scrollPrev}\n\t\t\t{...props}\n\t\t>\n\t\t\t<ChevronLeftIcon className=\"cn-rtl-flip\" />\n\t\t\t<span className=\"sr-only\">Previous slide</span>\n\t\t</button>\n\t);\n}\n\nfunction CarouselNext({ className, ...props }: React.ComponentProps<\"button\">) {\n\tconst { size, scrollNext, canScrollNext } = useCarousel();\n\n\treturn (\n\t\t<button\n\t\t\ttype=\"button\"\n\t\t\tdata-slot=\"carousel-next\"\n\t\t\tclassName={cn(arrowVariants({ size, side: \"next\" }), className)}\n\t\t\tdisabled={!canScrollNext}\n\t\t\tonClick={scrollNext}\n\t\t\t{...props}\n\t\t>\n\t\t\t<ChevronRightIcon className=\"cn-rtl-flip\" />\n\t\t\t<span className=\"sr-only\">Next slide</span>\n\t\t</button>\n\t);\n}\n\n/**\n * Past this many items the indicator switches from \"show every dot\" to the\n * Airbnb-style windowed mode: at most `MANY_WINDOW` dots, the active one kept\n * near the centre, and dots at a clipped edge faded down to imply more beyond.\n */\nconst MANY_THRESHOLD = 5;\nconst MANY_WINDOW = 5;\n\ntype IndicatorDot = {\n\t/** Index into the full list of slides. */\n\tindex: number;\n\t/** True for the outermost dot on a side that has hidden slides beyond it. */\n\tfaded: boolean;\n};\n\n/**\n * Returns the dots to render plus the window start, so the determinate and\n * windowed (\"many\") cases share one render path. The dot strip is always the\n * full list; `start` drives the translate that slides it under the viewport.\n */\nfunction getIndicatorWindow(count: number, selected: number) {\n\tif (count < MANY_THRESHOLD) {\n\t\tconst dots: IndicatorDot[] = Array.from({ length: count }, (_, index) => ({\n\t\t\tindex,\n\t\t\tfaded: false,\n\t\t}));\n\t\treturn { dots, start: 0, visible: count };\n\t}\n\n\tconst half = Math.floor(MANY_WINDOW / 2);\n\tconst start = Math.max(0, Math.min(selected - half, count - MANY_WINDOW));\n\tconst end = start + MANY_WINDOW - 1;\n\tconst overflowLeft = start > 0;\n\tconst overflowRight = end < count - 1;\n\n\tconst dots: IndicatorDot[] = Array.from({ length: count }, (_, index) => ({\n\t\tindex,\n\t\tfaded:\n\t\t\t(overflowLeft && index === start) || (overflowRight && index === end),\n\t}));\n\n\treturn { dots, start, visible: MANY_WINDOW };\n}\n\n/** Dot diameter, gap, and pill padding per size — in px to keep them crisp. */\nconst INDICATOR_SIZES: Record<\n\tComponentSize,\n\t{ dot: number; gap: number; padX: number; padY: number }\n> = {\n\tsm: { dot: 5, gap: 4, padX: 8, padY: 4 },\n\tmd: { dot: 7, gap: 5, padX: 10, padY: 5 },\n\tlg: { dot: 9, gap: 6, padX: 12, padY: 6 },\n};\n\n/** Distance of the indicator from the bottom edge, per size (12/18/24px). */\nconst INDICATOR_OFFSET: Record<ComponentSize, string> = {\n\tsm: \"bottom-3\",\n\tmd: \"bottom-[18px]\",\n\tlg: \"bottom-6\",\n};\n\ntype CarouselIndicatorProps = Omit<\n\tReact.ComponentProps<\"div\">,\n\t\"children\" | \"onSelect\"\n> & {\n\t/** Override the live count (e.g. for static design previews). */\n\tcount?: number;\n\t/** Override the live selected index. */\n\tselected?: number;\n\t/** Override the inherited carousel size. */\n\tsize?: ComponentSize;\n\t/** Jump to a slide when a dot is activated. Defaults to the carousel API. */\n\tonSelect?: (index: number) => void;\n};\n\nfunction CarouselIndicator({\n\tclassName,\n\tcount: countProp,\n\tselected: selectedProp,\n\tsize: sizeProp,\n\tonSelect,\n\t...props\n}: CarouselIndicatorProps) {\n\t// Read context loosely so the indicator can also stand alone (previews,\n\t// docs) by passing `count`/`selected` directly.\n\tconst ctx = React.useContext(CarouselContext);\n\tconst inheritedSize = useComponentSize(sizeProp);\n\n\tconst size = sizeProp ?? ctx?.size ?? inheritedSize;\n\tconst count = countProp ?? ctx?.scrollSnaps.length ?? 0;\n\tconst selected = selectedProp ?? ctx?.selectedIndex ?? 0;\n\tconst handleSelect = onSelect ?? ctx?.scrollTo;\n\n\tif (count <= 1) return null;\n\n\tconst { dot, gap, padX, padY } = INDICATOR_SIZES[size];\n\tconst { dots, start, visible } = getIndicatorWindow(count, selected);\n\tconst step = dot + gap;\n\t// Viewport width clips the strip to exactly `visible` dots; the strip then\n\t// translates by `start` steps so the windowed dots line up under it.\n\tconst viewportWidth = visible * step - gap;\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"carousel-indicator\"\n\t\t\tclassName={cn(\n\t\t\t\t\"absolute left-1/2 z-10 flex -translate-x-1/2 items-center justify-center rounded-full\",\n\t\t\t\tINDICATOR_OFFSET[size],\n\t\t\t\tglassChrome,\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tstyle={{ padding: `${padY}px ${padX}px` }}\n\t\t\trole=\"tablist\"\n\t\t\taria-label=\"Slide indicators\"\n\t\t\t{...props}\n\t\t>\n\t\t\t<div className=\"overflow-hidden\" style={{ width: viewportWidth }}>\n\t\t\t\t<div\n\t\t\t\t\tclassName=\"flex items-center transition-transform duration-300 ease-out\"\n\t\t\t\t\tstyle={{ gap, transform: `translateX(${-start * step}px)` }}\n\t\t\t\t>\n\t\t\t\t\t{dots.map(({ index, faded }) => {\n\t\t\t\t\t\tconst isActive = index === selected;\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\tkey={index}\n\t\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\t\trole=\"tab\"\n\t\t\t\t\t\t\t\taria-selected={isActive}\n\t\t\t\t\t\t\t\taria-label={`Go to slide ${index + 1}`}\n\t\t\t\t\t\t\t\tonClick={() => handleSelect?.(index)}\n\t\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\t\"shrink-0 rounded-full bg-fg-on-brand transition-[transform,opacity] duration-300 ease-out\",\n\t\t\t\t\t\t\t\t\thandleSelect ? \"cursor-pointer\" : \"cursor-default\",\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\twidth: dot,\n\t\t\t\t\t\t\t\t\theight: dot,\n\t\t\t\t\t\t\t\t\topacity: faded ? 0.3 : isActive ? 1 : 0.55,\n\t\t\t\t\t\t\t\t\ttransform: faded ? \"scale(0.6)\" : \"scale(1)\",\n\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t);\n\t\t\t\t\t})}\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</div>\n\t);\n}\n\nexport {\n\ttype CarouselApi,\n\tCarousel,\n\tCarouselContent,\n\tCarouselItem,\n\tCarouselPrevious,\n\tCarouselNext,\n\tCarouselIndicator,\n\tuseCarousel,\n};\n","\"use client\";\n\nimport { Checkbox as CheckboxPrimitive } from \"@base-ui/react/checkbox\";\nimport { CheckboxGroup } from \"@base-ui/react/checkbox-group\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { CheckIcon } from \"lucide-react\";\n\nimport { cn } from \"../../lib/cn\";\nimport { useComponentSize } from \"./size-context\";\n\nconst checkboxVariants = cva(\n\t\"peer group/checkbox relative flex shrink-0 items-center justify-center rounded-sm border bg-canvas text-transparent outline-none transition-[background-color,border-color,box-shadow,color] after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] aria-invalid:border-line-danger aria-invalid:ring-3 aria-invalid:ring-destructive/20 border-line data-unchecked:hover:border-line-focus data-unchecked:hover:bg-surface-brand-subtle data-checked:border-action-primary data-checked:bg-action-primary data-checked:text-fg-on-brand data-disabled:cursor-not-allowed data-disabled:border-line-subtle data-disabled:bg-surface data-disabled:text-fg-caption-placeholder size-5 [--checkbox-icon-size:0.75rem] group-data-[size=sm]/field:size-4 group-data-[size=sm]/field:[--checkbox-icon-size:0.625rem] group-data-[size=md]/field:size-5 group-data-[size=md]/field:[--checkbox-icon-size:0.75rem] group-data-[size=lg]/field:size-6 group-data-[size=lg]/field:[--checkbox-icon-size:0.875rem]\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"size-4 [--checkbox-icon-size:0.625rem]\",\n\t\t\t\tmd: \"size-5 [--checkbox-icon-size:0.75rem]\",\n\t\t\t\tlg: \"size-6 [--checkbox-icon-size:0.875rem]\",\n\t\t\t},\n\t\t},\n\t},\n);\n\ntype CheckboxSize = NonNullable<VariantProps<typeof checkboxVariants>[\"size\"]>;\ntype CheckboxProps = CheckboxPrimitive.Root.Props & {\n\tsize?: CheckboxSize;\n};\n\n/**\n * Compose with the shared field primitives for label and helper text.\n *\n * ```tsx\n * <Field orientation=\"horizontal\" size=\"sm\">\n * <Checkbox id=\"terms\" />\n * <FieldContent>\n * <FieldLabel htmlFor=\"terms\">Checkbox label</FieldLabel>\n * <FieldDescription>Helper description text.</FieldDescription>\n * </FieldContent>\n * </Field>\n * ```\n *\n * Group multiple checkboxes with the field set primitives.\n *\n * ```tsx\n * <FieldSet>\n * <FieldLegend variant=\"label\">Show these items on the desktop:</FieldLegend>\n * <FieldDescription>\n * Select the items you want to show on the desktop.\n * </FieldDescription>\n * <FieldGroup className=\"gap-3\">\n * <Field orientation=\"horizontal\">\n * <Checkbox id=\"desktop-hard-disks\" name=\"desktop-hard-disks\" defaultChecked />\n * <FieldLabel htmlFor=\"desktop-hard-disks\" className=\"font-normal\">\n * Hard disks\n * </FieldLabel>\n * </Field>\n * <Field orientation=\"horizontal\">\n * <Checkbox\n * id=\"desktop-external-disks\"\n * name=\"desktop-external-disks\"\n * defaultChecked\n * />\n * <FieldLabel htmlFor=\"desktop-external-disks\" className=\"font-normal\">\n * External disks\n * </FieldLabel>\n * </Field>\n * <Field orientation=\"horizontal\">\n * <Checkbox id=\"desktop-cds-dvds-ipods\" name=\"desktop-cds-dvds-ipods\" />\n * <FieldLabel htmlFor=\"desktop-cds-dvds-ipods\" className=\"font-normal\">\n * CDs, DVDs, and iPods\n * </FieldLabel>\n * </Field>\n * <Field orientation=\"horizontal\">\n * <Checkbox\n * id=\"desktop-connected-servers\"\n * name=\"desktop-connected-servers\"\n * />\n * <FieldLabel htmlFor=\"desktop-connected-servers\" className=\"font-normal\">\n * Connected servers\n * </FieldLabel>\n * </Field>\n * </FieldGroup>\n * </FieldSet>\n * ```\n */\nfunction Checkbox({ className, size, ...props }: CheckboxProps) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn (\n\t\t<CheckboxPrimitive.Root\n\t\t\tdata-slot=\"checkbox\"\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(checkboxVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<CheckboxPrimitive.Indicator\n\t\t\t\tdata-slot=\"checkbox-indicator\"\n\t\t\t\tclassName=\"grid place-content-center text-current transition-none [&>svg]:size-(--checkbox-icon-size)\"\n\t\t\t>\n\t\t\t\t<CheckIcon />\n\t\t\t</CheckboxPrimitive.Indicator>\n\t\t</CheckboxPrimitive.Root>\n\t);\n}\n\nexport { Checkbox, CheckboxGroup, checkboxVariants };\n","\"use client\";\n\nimport { Collapsible as CollapsiblePrimitive } from \"@base-ui/react/collapsible\";\nimport { cn } from \"../../lib/cn\";\n\nfunction Collapsible({ className, ...props }: CollapsiblePrimitive.Root.Props) {\n\treturn (\n\t\t<CollapsiblePrimitive.Root\n\t\t\tdata-slot=\"collapsible\"\n\t\t\tclassName={cn(\"group/collapsible\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction CollapsibleTrigger({\n\tclassName,\n\t...props\n}: CollapsiblePrimitive.Trigger.Props) {\n\treturn (\n\t\t<CollapsiblePrimitive.Trigger\n\t\t\tdata-slot=\"collapsible-trigger\"\n\t\t\tclassName={cn(\"group/collapsible-trigger\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction CollapsibleContent({\n\tclassName,\n\t...props\n}: CollapsiblePrimitive.Panel.Props) {\n\treturn (\n\t\t<CollapsiblePrimitive.Panel\n\t\t\tdata-slot=\"collapsible-content\"\n\t\t\tclassName={cn(\n\t\t\t\t\"h-(--collapsible-panel-height) overflow-hidden transition-[height] duration-150 ease-out data-ending-style:h-0 data-starting-style:h-0 [&[hidden]:not([hidden='until-found'])]:hidden\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Collapsible, CollapsibleTrigger, CollapsibleContent };\n","\"use client\";\n\nimport { Combobox as ComboboxPrimitive } from \"@base-ui/react\";\nimport { cva } from \"class-variance-authority\";\nimport { CheckIcon, ChevronDownIcon, XIcon } from \"lucide-react\";\nimport * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\nimport {\n\tInputGroup,\n\tInputGroupAddon,\n\tInputGroupButton,\n\tInputGroupInput,\n} from \"./input-group\";\nimport {\n\ttype ComponentSize,\n\tSizeProvider,\n\tuseComponentSize,\n} from \"./size-context\";\n\nconst ComboboxSelectionContext = React.createContext({ multiple: false });\n\ntype ComboboxSize = ComponentSize;\n\nfunction Combobox<Value, Multiple extends boolean | undefined = false>({\n\tmultiple,\n\tchildren,\n\tsize,\n\t...props\n}: ComboboxPrimitive.Root.Props<Value, Multiple> & {\n\tsize?: ComboboxSize;\n}) {\n\treturn (\n\t\t<SizeProvider size={size}>\n\t\t\t<ComboboxSelectionContext.Provider\n\t\t\t\tvalue={{ multiple: multiple === true }}\n\t\t\t>\n\t\t\t\t<ComboboxPrimitive.Root multiple={multiple} {...props}>\n\t\t\t\t\t{children}\n\t\t\t\t</ComboboxPrimitive.Root>\n\t\t\t</ComboboxSelectionContext.Provider>\n\t\t</SizeProvider>\n\t);\n}\n\nconst comboboxTriggerVariants = cva(\n\t\"group/combobox-trigger flex w-fit min-w-0 items-center justify-between rounded-full border border-line bg-canvas text-left font-normal whitespace-nowrap text-fg-primary shadow-none outline-none transition-[background-color,border-color,border-radius,box-shadow,color] select-none hover:border-line-strong focus-visible:border-line-focus focus-visible:inset-ring-1 focus-visible:inset-ring-line-focus data-focused:border-line-focus data-focused:inset-ring-1 data-focused:inset-ring-line-focus data-popup-open:rounded-2xl data-popup-open:border-line-focus data-popup-open:inset-ring-1 data-popup-open:inset-ring-line-focus disabled:pointer-events-none disabled:cursor-not-allowed disabled:border-line-subtle disabled:bg-surface disabled:text-fg-caption-placeholder data-disabled:pointer-events-none data-disabled:cursor-not-allowed data-disabled:border-line-subtle data-disabled:bg-surface data-disabled:text-fg-caption-placeholder data-placeholder:text-fg-caption-placeholder aria-invalid:border-line-danger aria-invalid:text-fg-danger aria-invalid:shadow-none data-[invalid=true]:border-line-danger data-[invalid=true]:text-fg-danger *:data-[slot=combobox-value]:line-clamp-1 *:data-[slot=combobox-value]:flex *:data-[slot=combobox-value]:min-w-0 *:data-[slot=combobox-value]:items-center *:data-[slot=combobox-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"h-8 gap-2 px-3 text-gdt-xs [&_svg:not([class*='size-'])]:size-3.5\",\n\t\t\t\tmd: \"h-10 gap-2 px-3.5 text-gdt-sm [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\tlg: \"h-12 gap-2.5 px-4 pr-5 text-gdt-md [&_svg:not([class*='size-'])]:size-4.5\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxInputVariants = cva(\n\t\"w-auto has-data-popup-open:rounded-2xl has-data-popup-open:border-line-focus has-data-popup-open:inset-ring-1 has-data-popup-open:inset-ring-line-focus\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"\",\n\t\t\t\tmd: \"\",\n\t\t\t\tlg: \"\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxContentVariants = cva(\n\t\"relative isolate z-50 max-h-(--available-height) w-(--anchor-width) max-w-(--available-width) min-w-[calc(var(--anchor-width))] origin-(--transform-origin) overflow-hidden border border-line-subtle bg-canvas text-fg-primary shadow-(--elevation-e1-shadow) duration-100 data-[chips=true]:min-w-(--anchor-width) data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 *:data-[slot=input-group]:mb-1 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"rounded-lg p-1\",\n\t\t\t\tmd: \"rounded-xl p-1.5\",\n\t\t\t\tlg: \"rounded-[18px] p-2\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxItemVariants = cva(\n\t\"group/combobox-item relative flex w-full cursor-pointer items-center font-normal text-fg-primary outline-none select-none data-highlighted:bg-surface data-disabled:pointer-events-none data-disabled:text-fg-caption-placeholder [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"gap-1.5 rounded-md px-3 py-1.5 text-gdt-xs\",\n\t\t\t\tmd: \"gap-2 rounded-md px-4 py-2 text-gdt-sm\",\n\t\t\t\tlg: \"gap-2.5 rounded-md px-4 py-2.5 text-gdt-md\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxChipsVariants = cva(\n\t\"flex flex-wrap items-center gap-1 rounded-full border border-line bg-canvas bg-clip-padding text-fg-primary transition-[background-color,border-color,box-shadow,color] focus-within:border-line-focus focus-within:inset-ring-1 focus-within:inset-ring-line-focus has-aria-invalid:border-line-danger has-aria-invalid:text-fg-danger has-aria-invalid:shadow-none has-data-[slot=combobox-chip]:px-1 has-data-popup-open:rounded-2xl has-data-popup-open:border-line-focus has-data-popup-open:inset-ring-1 has-data-popup-open:inset-ring-line-focus\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"min-h-8 px-2.5 py-1 text-gdt-xs\",\n\t\t\t\tmd: \"min-h-10 px-3 py-1.5 text-gdt-sm\",\n\t\t\t\tlg: \"min-h-12 px-4 py-2 text-gdt-md\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxChipVariants = cva(\n\t\"flex w-fit items-center justify-center gap-1 rounded-sm bg-surface font-medium whitespace-nowrap text-fg-primary has-disabled:pointer-events-none has-disabled:cursor-not-allowed has-disabled:opacity-50 has-data-[slot=combobox-chip-remove]:pr-0\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"h-5 px-1.5 text-gdt-xs\",\n\t\t\t\tmd: \"h-[calc(--spacing(5.25))] px-1.5 text-gdt-xs\",\n\t\t\t\tlg: \"h-6 px-2 text-gdt-sm\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nfunction ComboboxValue({ ...props }: ComboboxPrimitive.Value.Props) {\n\treturn <ComboboxPrimitive.Value data-slot=\"combobox-value\" {...props} />;\n}\n\nfunction ComboboxTrigger({\n\tclassName,\n\tchildren,\n\t...props\n}: ComboboxPrimitive.Trigger.Props) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Trigger\n\t\t\tdata-slot=\"combobox-trigger\"\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(comboboxTriggerVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t\t<ComboboxPrimitive.Icon\n\t\t\t\trender={\n\t\t\t\t\t<ChevronDownIcon className=\"text-line-strong transition-transform group-data-disabled/combobox-trigger:text-fg-caption-placeholder group-data-popup-open/combobox-trigger:rotate-180\" />\n\t\t\t\t}\n\t\t\t/>\n\t\t</ComboboxPrimitive.Trigger>\n\t);\n}\n\nfunction ComboboxClear({ className, ...props }: ComboboxPrimitive.Clear.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Clear\n\t\t\tdata-slot=\"combobox-clear\"\n\t\t\tclassName={cn(className)}\n\t\t\t{...props}\n\t\t\trender={\n\t\t\t\t<InputGroupButton variant=\"ghost\" size=\"icon-xs\">\n\t\t\t\t\t<XIcon className=\"pointer-events-none\" />\n\t\t\t\t</InputGroupButton>\n\t\t\t}\n\t\t/>\n\t);\n}\n\nfunction ComboboxInput({\n\tclassName,\n\tchildren,\n\tdisabled = false,\n\tshowTrigger = true,\n\tshowClear = false,\n\t...props\n}: ComboboxPrimitive.Input.Props & {\n\tshowTrigger?: boolean;\n\tshowClear?: boolean;\n}) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<InputGroup\n\t\t\tclassName={cn(comboboxInputVariants({ size: resolvedSize }), className)}\n\t\t>\n\t\t\t<ComboboxPrimitive.Input\n\t\t\t\trender={<InputGroupInput disabled={disabled} />}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t\t<InputGroupAddon align=\"inline-end\">\n\t\t\t\t{showTrigger && (\n\t\t\t\t\t<InputGroupButton\n\t\t\t\t\t\tsize=\"icon-xs\"\n\t\t\t\t\t\tvariant=\"ghost\"\n\t\t\t\t\t\trender={<ComboboxTrigger />}\n\t\t\t\t\t\tdata-slot=\"input-group-button\"\n\t\t\t\t\t\tclassName=\"h-6 border-0 bg-transparent p-0 shadow-none inset-ring-0 group-has-data-[slot=combobox-clear]/input-group:hidden hover:border-transparent focus-visible:border-transparent focus-visible:inset-ring-0 data-popup-open:border-transparent data-popup-open:bg-transparent data-popup-open:inset-ring-0 data-pressed:bg-transparent\"\n\t\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\t/>\n\t\t\t\t)}\n\t\t\t\t{showClear && <ComboboxClear disabled={disabled} />}\n\t\t\t</InputGroupAddon>\n\t\t\t{children}\n\t\t</InputGroup>\n\t);\n}\n\nfunction ComboboxContent({\n\tclassName,\n\tside = \"bottom\",\n\tsideOffset = 6,\n\talign = \"start\",\n\talignOffset = 0,\n\tanchor,\n\t...props\n}: ComboboxPrimitive.Popup.Props &\n\tPick<\n\t\tComboboxPrimitive.Positioner.Props,\n\t\t\"side\" | \"align\" | \"sideOffset\" | \"alignOffset\" | \"anchor\"\n\t>) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Portal>\n\t\t\t<ComboboxPrimitive.Positioner\n\t\t\t\tside={side}\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t\talign={align}\n\t\t\t\talignOffset={alignOffset}\n\t\t\t\tanchor={anchor}\n\t\t\t\tclassName=\"isolate z-50\"\n\t\t\t>\n\t\t\t\t<ComboboxPrimitive.Popup\n\t\t\t\t\tdata-slot=\"combobox-content\"\n\t\t\t\t\tdata-chips={!!anchor}\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"group/combobox-content\",\n\t\t\t\t\t\tcomboboxContentVariants({ size: resolvedSize }),\n\t\t\t\t\t\tclassName,\n\t\t\t\t\t)}\n\t\t\t\t\t{...props}\n\t\t\t\t/>\n\t\t\t</ComboboxPrimitive.Positioner>\n\t\t</ComboboxPrimitive.Portal>\n\t);\n}\n\nfunction ComboboxList({ className, ...props }: ComboboxPrimitive.List.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.List\n\t\t\tdata-slot=\"combobox-list\"\n\t\t\tclassName={cn(\n\t\t\t\t\"no-scrollbar max-h-(--available-height) space-y-0.5 scroll-py-1 overflow-y-auto overscroll-contain data-empty:p-0\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxItem({\n\tclassName,\n\tchildren,\n\t...props\n}: ComboboxPrimitive.Item.Props) {\n\tconst { multiple } = React.useContext(ComboboxSelectionContext);\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Item\n\t\t\tdata-slot=\"combobox-item\"\n\t\t\tclassName={cn(\n\t\t\t\tcomboboxItemVariants({ size: resolvedSize }),\n\t\t\t\t!multiple &&\n\t\t\t\t\t\"data-selected:bg-surface-brand-subtle data-selected:font-medium data-selected:text-fg-brand\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{multiple ? (\n\t\t\t\t<ComboboxPrimitive.ItemIndicator\n\t\t\t\t\tkeepMounted\n\t\t\t\t\tclassName=\"flex size-5 shrink-0 items-center justify-center rounded-sm border border-line bg-canvas text-transparent transition-[background-color,border-color,color] group-data-selected/combobox-item:border-action-primary group-data-selected/combobox-item:bg-action-primary group-data-selected/combobox-item:text-fg-on-brand group-data-disabled/combobox-item:border-line-subtle group-data-disabled/combobox-item:bg-surface group-data-disabled/combobox-item:text-fg-caption-placeholder [&>svg]:size-3\"\n\t\t\t\t>\n\t\t\t\t\t<CheckIcon />\n\t\t\t\t</ComboboxPrimitive.ItemIndicator>\n\t\t\t) : null}\n\t\t\t<span className=\"flex min-w-0 flex-1 shrink-0 gap-2 whitespace-nowrap\">\n\t\t\t\t{children}\n\t\t\t</span>\n\t\t</ComboboxPrimitive.Item>\n\t);\n}\n\nfunction ComboboxGroup({ className, ...props }: ComboboxPrimitive.Group.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Group\n\t\t\tdata-slot=\"combobox-group\"\n\t\t\tclassName={cn(\"scroll-my-1 space-y-0.5\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxLabel({\n\tclassName,\n\t...props\n}: ComboboxPrimitive.GroupLabel.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.GroupLabel\n\t\t\tdata-slot=\"combobox-label\"\n\t\t\tclassName={cn(\"px-3 py-1 text-gdt-xs text-fg-secondary\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxCollection({ ...props }: ComboboxPrimitive.Collection.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Collection data-slot=\"combobox-collection\" {...props} />\n\t);\n}\n\nfunction ComboboxEmpty({ className, ...props }: ComboboxPrimitive.Empty.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Empty\n\t\t\tdata-slot=\"combobox-empty\"\n\t\t\tclassName={cn(\n\t\t\t\t\"hidden w-full justify-center py-2 text-center text-gdt-sm text-fg-secondary group-data-empty/combobox-content:flex\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxSeparator({\n\tclassName,\n\t...props\n}: ComboboxPrimitive.Separator.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Separator\n\t\t\tdata-slot=\"combobox-separator\"\n\t\t\tclassName={cn(\"pointer-events-none my-1 h-px bg-line-subtle\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxChips({\n\tclassName,\n\t...props\n}: React.ComponentPropsWithRef<typeof ComboboxPrimitive.Chips> &\n\tComboboxPrimitive.Chips.Props) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Chips\n\t\t\tdata-slot=\"combobox-chips\"\n\t\t\tclassName={cn(comboboxChipsVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxChip({\n\tclassName,\n\tchildren,\n\tshowRemove = true,\n\t...props\n}: ComboboxPrimitive.Chip.Props & {\n\tshowRemove?: boolean;\n}) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Chip\n\t\t\tdata-slot=\"combobox-chip\"\n\t\t\tclassName={cn(comboboxChipVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t\t{showRemove && (\n\t\t\t\t<ComboboxPrimitive.ChipRemove\n\t\t\t\t\tclassName=\"-ml-1 opacity-50 hover:opacity-100\"\n\t\t\t\t\tdata-slot=\"combobox-chip-remove\"\n\t\t\t\t\trender={\n\t\t\t\t\t\t<Button variant=\"ghost\" size=\"icon-xs\">\n\t\t\t\t\t\t\t<XIcon className=\"pointer-events-none\" />\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t}\n\t\t\t\t/>\n\t\t\t)}\n\t\t</ComboboxPrimitive.Chip>\n\t);\n}\n\nfunction ComboboxChipsInput({\n\tclassName,\n\t...props\n}: ComboboxPrimitive.Input.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Input\n\t\t\tdata-slot=\"combobox-chip-input\"\n\t\t\tclassName={cn(\n\t\t\t\t\"min-w-16 flex-1 bg-transparent text-fg-primary outline-none placeholder:text-fg-muted\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction useComboboxAnchor() {\n\treturn React.useRef<HTMLDivElement | null>(null);\n}\n\nexport {\n\tCombobox,\n\tComboboxInput,\n\tComboboxContent,\n\tComboboxList,\n\tComboboxItem,\n\tComboboxGroup,\n\tComboboxLabel,\n\tComboboxCollection,\n\tComboboxEmpty,\n\tComboboxSeparator,\n\tComboboxChips,\n\tComboboxChip,\n\tComboboxChipsInput,\n\tComboboxTrigger,\n\ttype ComboboxSize,\n\tComboboxValue,\n\tuseComboboxAnchor,\n};\n","\"use client\";\n\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\nimport { Input, type InputSize } from \"./input\";\nimport { InputSizeProvider } from \"./input-size-context\";\nimport {\n\ttype ComponentSize,\n\tSizeProvider,\n\tuseComponentSize,\n} from \"./size-context\";\nimport { Textarea, type TextareaSize } from \"./textarea\";\n\nconst inputGroupVariants = cva(\n\t\"group/input-group relative flex w-full min-w-0 items-center rounded-full has-[textarea]:rounded-xl has-data-[align=block-end]:rounded-xl has-data-[align=block-start]:rounded-xl border border-line bg-canvas transition-[background-color,border-color,box-shadow,color] outline-none in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0 has-disabled:border-line-subtle has-disabled:bg-surface has-disabled:text-fg-muted focus-within:border-line-focus focus-within:inset-ring-1 inset-ring-line-focus has-[[data-slot][aria-invalid=true]]:border-line-danger has-[[data-slot][aria-invalid=true]]:inset-shadow-none has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>textarea]:h-auto has-[>[data-align=block-end]]:[&>input]:pt-3 has-[>[data-align=block-start]]:[&>input]:pb-3 has-[>[data-align=inline-start]]:[&>[data-slot=input-group-control]]:group-data-[size=sm]/input-group:pl-2 has-[>[data-align=inline-start]]:[&>[data-slot=input-group-control]]:group-data-[size=md]/input-group:pl-2.5 has-[>[data-align=inline-start]]:[&>[data-slot=input-group-control]]:group-data-[size=lg]/input-group:pl-3 has-[>[data-align=inline-start]]:[&>[data-slot=input-group-control]]:group-data-[size=xl]/input-group:pl-3 has-[>[data-align=inline-end]]:[&>[data-slot=input-group-control]]:group-data-[size=sm]/input-group:pr-2 has-[>[data-align=inline-end]]:[&>[data-slot=input-group-control]]:group-data-[size=md]/input-group:pr-2.5 has-[>[data-align=inline-end]]:[&>[data-slot=input-group-control]]:group-data-[size=lg]/input-group:pr-3 has-[>[data-align=inline-end]]:[&>[data-slot=input-group-control]]:group-data-[size=xl]/input-group:pr-3\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"h-8\",\n\t\t\t\tmd: \"h-10\",\n\t\t\t\tlg: \"h-12\",\n\t\t\t\txl: \"h-14\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nfunction InputGroup({\n\tclassName,\n\tsize,\n\t...props\n}: React.ComponentProps<\"div\"> & { size?: InputSize }) {\n\tconst inheritedSize = useComponentSize();\n\tconst resolvedSize = size ?? inheritedSize;\n\tconst componentSize: ComponentSize | undefined =\n\t\tresolvedSize === \"xl\" ? undefined : resolvedSize;\n\n\treturn (\n\t\t<SizeProvider size={componentSize}>\n\t\t\t<InputSizeProvider size={resolvedSize}>\n\t\t\t\t{/* biome-ignore lint/a11y/useSemanticElements: this primitive groups composite controls without forcing fieldset semantics. */}\n\t\t\t\t<div\n\t\t\t\t\tdata-slot=\"input-group\"\n\t\t\t\t\tdata-size={resolvedSize}\n\t\t\t\t\trole=\"group\"\n\t\t\t\t\tclassName={cn(inputGroupVariants({ size: resolvedSize }), className)}\n\t\t\t\t\t{...props}\n\t\t\t\t/>\n\t\t\t</InputSizeProvider>\n\t\t</SizeProvider>\n\t);\n}\n\nconst inputGroupAddonVariants = cva(\n\t\"flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-gdt-sm font-normal text-fg-secondary select-none group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-[calc(var(--radius)-5px)] group-data-[size=lg]/input-group:[&>svg:not([class*='size-'])]:size-4.5 group-data-[size=xl]/input-group:[&>svg:not([class*='size-'])]:size-5 [&>svg:not([class*='size-'])]:size-4\",\n\t{\n\t\tvariants: {\n\t\t\talign: {\n\t\t\t\t\"inline-start\":\n\t\t\t\t\t\"order-first group-data-[size=sm]/input-group:pl-3 group-data-[size=md]/input-group:pl-3.5 group-data-[size=lg]/input-group:pl-4 group-data-[size=xl]/input-group:pl-4.5 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]\",\n\t\t\t\t\"inline-end\":\n\t\t\t\t\t\"order-last group-data-[size=sm]/input-group:pr-3 group-data-[size=md]/input-group:pr-3.5 group-data-[size=lg]/input-group:pr-4 group-data-[size=xl]/input-group:pr-4.5 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]\",\n\t\t\t\t\"block-start\":\n\t\t\t\t\t\"order-first w-full justify-start px-3 group-data-[size=md]/input-group:px-3.5 group-data-[size=lg]/input-group:px-4 group-data-[size=xl]/input-group:px-4.5 pt-2 group-has-[>input]/input-group:pt-2 [.border-b]:pb-2\",\n\t\t\t\t\"block-end\":\n\t\t\t\t\t\"order-last w-full justify-start px-3 group-data-[size=md]/input-group:px-3.5 group-data-[size=lg]/input-group:px-4 group-data-[size=xl]/input-group:px-4.5 pb-2 group-has-[>input]/input-group:pb-2 [.border-t]:pt-2\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\talign: \"inline-start\",\n\t\t},\n\t},\n);\n\nfunction InputGroupAddon({\n\tclassName,\n\talign = \"inline-start\",\n\t...props\n}: React.ComponentProps<\"div\"> & VariantProps<typeof inputGroupAddonVariants>) {\n\treturn (\n\t\t// biome-ignore lint/a11y/useSemanticElements: addon is a structural wrapper for grouped input affordances.\n\t\t// biome-ignore lint/a11y/useKeyWithClickEvents: click only forwards focus to the sibling input and is not a standalone action target.\n\t\t<div\n\t\t\trole=\"group\"\n\t\t\tdata-slot=\"input-group-addon\"\n\t\t\tdata-align={align}\n\t\t\tclassName={cn(inputGroupAddonVariants({ align }), className)}\n\t\t\tonClick={(e) => {\n\t\t\t\tif ((e.target as HTMLElement).closest(\"button\")) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\te.currentTarget.parentElement?.querySelector(\"input\")?.focus();\n\t\t\t}}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst inputGroupButtonVariants = cva(\n\t\"flex items-center gap-2 text-sm shadow-none rounded-full\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\txs: \"h-6 gap-1 px-1.5 [&>svg:not([class*='size-'])]:size-3.5\",\n\t\t\t\tsm: \"\",\n\t\t\t\t\"icon-xs\": \"size-6 p-0 has-[>svg]:p-0\",\n\t\t\t\t\"icon-sm\": \"size-8 p-0 has-[>svg]:p-0\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"xs\",\n\t\t},\n\t},\n);\n\nfunction InputGroupButton({\n\tclassName,\n\ttype = \"button\",\n\tvariant = \"ghost\",\n\tsize = \"xs\",\n\t...props\n}: Omit<React.ComponentProps<typeof Button>, \"size\" | \"type\"> &\n\tVariantProps<typeof inputGroupButtonVariants> & {\n\t\ttype?: \"button\" | \"submit\" | \"reset\";\n\t}) {\n\treturn (\n\t\t<Button\n\t\t\ttype={type}\n\t\t\tdata-size={size}\n\t\t\tvariant={variant}\n\t\t\tclassName={cn(inputGroupButtonVariants({ size }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction InputGroupText({ className, ...props }: React.ComponentProps<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\tclassName={cn(\n\t\t\t\t\"flex items-center gap-2 text-gdt-sm text-fg-secondary [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction InputGroupInput({\n\tclassName,\n\tsize,\n\t...props\n}: Omit<React.ComponentProps<\"input\">, \"size\"> & { size?: InputSize }) {\n\treturn (\n\t\t<Input\n\t\t\tdata-slot=\"input-group-control\"\n\t\t\tsize={size}\n\t\t\tclassName={cn(\n\t\t\t\t\"flex-1 rounded-none border-0 bg-transparent shadow-none inset-shadow-none inset-ring-0 focus:border-transparent focus:shadow-none focus:inset-shadow-none focus-visible:border-transparent focus-visible:shadow-none focus-visible:ring-0 focus-visible:inset-ring-0 focus-visible:inset-shadow-none disabled:bg-transparent aria-invalid:ring-0 aria-invalid:inset-ring-0 dark:bg-transparent dark:disabled:bg-transparent\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction InputGroupTextarea({\n\tclassName,\n\tsize,\n\t...props\n}: Omit<React.ComponentProps<\"textarea\">, \"size\"> & { size?: TextareaSize }) {\n\treturn (\n\t\t<Textarea\n\t\t\tdata-slot=\"input-group-control\"\n\t\t\tsize={size}\n\t\t\tclassName={cn(\n\t\t\t\t\"flex-1 resize-none rounded-none border-0 bg-transparent shadow-none inset-shadow-none inset-ring-0 focus:border-transparent focus:shadow-none focus:inset-shadow-none focus-visible:border-transparent focus-visible:shadow-none focus-visible:ring-0 focus-visible:inset-ring-0 focus-visible:inset-shadow-none disabled:bg-transparent aria-invalid:ring-0 aria-invalid:inset-ring-0 dark:bg-transparent dark:disabled:bg-transparent\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tInputGroup,\n\tInputGroupAddon,\n\tInputGroupButton,\n\tInputGroupText,\n\tInputGroupInput,\n\tInputGroupTextarea,\n};\n","import { Input as InputPrimitive } from \"@base-ui/react/input\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport {\n\ttype InputComponentSize,\n\tuseInputComponentSize,\n} from \"./input-size-context\";\n\nconst inputVariants = cva(\n\t\"flex w-full min-w-0 rounded-full border border-line bg-canvas text-fg-primary transition-[background-color,border-color,box-shadow,color] outline-none file:inline-flex file:border-0 file:bg-transparent file:font-normal file:text-fg-primary placeholder:text-fg-muted hover:border-line-strong focus-visible:border-line-focus focus-visible:inset-ring-1 inset-ring-line-focus disabled:pointer-events-none disabled:cursor-not-allowed disabled:border-line-subtle disabled:bg-surface disabled:text-fg-muted disabled:placeholder:text-fg-muted aria-invalid:border-line-danger aria-invalid:text-fg-danger aria-invalid:placeholder:text-fg-danger aria-invalid:shadow-none\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"h-8 px-3 text-gdt-xs font-normal file:text-gdt-xs\",\n\t\t\t\tmd: \"h-10 px-3.5 text-gdt-sm font-normal file:text-gdt-sm\",\n\t\t\t\tlg: \"h-12 px-4 text-gdt-md font-normal file:text-gdt-md\",\n\t\t\t\txl: \"h-14 px-4.5 text-gdt-lg font-normal file:text-gdt-lg\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\ntype InputProps = Omit<React.ComponentProps<\"input\">, \"size\"> &\n\tVariantProps<typeof inputVariants>;\n\ntype InputSize = InputComponentSize;\n\nfunction Input({ className, size, type, ...props }: InputProps) {\n\tconst resolvedSize = useInputComponentSize(size);\n\n\treturn (\n\t\t<InputPrimitive\n\t\t\ttype={type}\n\t\t\tdata-slot=\"input\"\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(inputVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Input, inputVariants, type InputSize };\n","\"use client\";\n\nimport { createContext, type ReactNode, useContext } from \"react\";\n\ntype InputComponentSize = \"sm\" | \"md\" | \"lg\" | \"xl\";\n\nconst InputSizeContext = createContext<InputComponentSize | undefined>(\n\tundefined,\n);\n\nfunction InputSizeProvider({\n\tchildren,\n\tsize,\n}: {\n\tchildren: ReactNode;\n\tsize?: InputComponentSize | null;\n}) {\n\tif (!size) {\n\t\treturn <>{children}</>;\n\t}\n\n\treturn (\n\t\t<InputSizeContext.Provider value={size}>\n\t\t\t{children}\n\t\t</InputSizeContext.Provider>\n\t);\n}\n\nfunction useInputComponentSize(\n\tsize?: InputComponentSize | null,\n\tfallback: InputComponentSize = \"md\",\n) {\n\tconst inheritedSize = useContext(InputSizeContext);\n\treturn size ?? inheritedSize ?? fallback;\n}\n\nexport { InputSizeProvider, useInputComponentSize, type InputComponentSize };\n","import { cva, type VariantProps } from \"class-variance-authority\";\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport { useComponentSize } from \"./size-context\";\n\nconst textareaVariants = cva(\n\t\"flex field-sizing-content w-full min-w-0 resize-y rounded-xl border border-line bg-canvas text-fg-primary transition-[background-color,border-color,box-shadow,color] outline-none placeholder:text-fg-caption-placeholder hover:border-line-strong focus-visible:border-line-focus focus-visible:inset-ring-1 inset-ring-line-focus disabled:pointer-events-none disabled:cursor-not-allowed disabled:border-line-subtle disabled:bg-surface disabled:text-fg-caption-placeholder disabled:placeholder:text-fg-caption-placeholder aria-invalid:border-line-danger aria-invalid:text-fg-danger aria-invalid:placeholder:text-fg-danger aria-invalid:shadow-none\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"min-h-22 px-3 py-2 text-gdt-xs\",\n\t\t\t\tmd: \"min-h-26 px-3.5 py-2.5 text-gdt-sm\",\n\t\t\t\tlg: \"min-h-31 px-4 py-3 text-gdt-md\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\ntype TextareaProps = Omit<React.ComponentProps<\"textarea\">, \"size\"> &\n\tVariantProps<typeof textareaVariants>;\n\ntype TextareaSize = NonNullable<VariantProps<typeof textareaVariants>[\"size\"]>;\n\nfunction Textarea({ className, size, ...props }: TextareaProps) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn (\n\t\t<textarea\n\t\t\tdata-slot=\"textarea\"\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(textareaVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Textarea, textareaVariants, type TextareaSize };\n","\"use client\";\n\nimport { CalendarIcon } from \"lucide-react\";\nimport * as React from \"react\";\nimport type { DateRange } from \"react-day-picker\";\n\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\nimport { Calendar } from \"./calendar\";\nimport { Popover, PopoverContent, PopoverTrigger } from \"./popover\";\n\nconst MONTHS = [\n\t\"January\",\n\t\"February\",\n\t\"March\",\n\t\"April\",\n\t\"May\",\n\t\"June\",\n\t\"July\",\n\t\"August\",\n\t\"September\",\n\t\"October\",\n\t\"November\",\n\t\"December\",\n];\n\nfunction formatDate(date: Date): string {\n\tconst day = date.getDate().toString().padStart(2, \"0\");\n\treturn `${day} ${MONTHS[date.getMonth()]} ${date.getFullYear()}`;\n}\n\n// ─── Shared sub-components ────────────────────────────────────────────────────\n\ninterface PickerTriggerProps {\n\tdisplayValue: string;\n\tplaceholder: string;\n\tdisabled: boolean;\n\topen: boolean;\n\tclassName?: string;\n}\n\nfunction PickerTrigger({\n\tdisplayValue,\n\tplaceholder,\n\tdisabled,\n\topen,\n\tclassName,\n}: PickerTriggerProps) {\n\treturn (\n\t\t<PopoverTrigger\n\t\t\tdisabled={disabled}\n\t\t\tclassName={cn(\n\t\t\t\t\"flex h-10 w-full items-center justify-between rounded-full border px-3.5 text-gdt-sm transition-[border-color,box-shadow] outline-none\",\n\t\t\t\tdisabled\n\t\t\t\t\t? \"cursor-not-allowed border-line-subtle bg-surface text-fg-caption-placeholder\"\n\t\t\t\t\t: open\n\t\t\t\t\t\t? \"border-line-focus bg-canvas text-fg-primary inset-ring-1 inset-ring-line-focus\"\n\t\t\t\t\t\t: \"border-line bg-canvas text-fg-primary hover:border-line-strong\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t>\n\t\t\t<span\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"min-w-0 truncate\",\n\t\t\t\t\t!displayValue && \"text-fg-caption-placeholder\",\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t{displayValue || placeholder}\n\t\t\t</span>\n\t\t\t<CalendarIcon\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"ml-2 size-4 shrink-0\",\n\t\t\t\t\tdisabled ? \"text-fg-caption-placeholder\" : \"text-fg-secondary\",\n\t\t\t\t)}\n\t\t\t/>\n\t\t</PopoverTrigger>\n\t);\n}\n\ninterface PickerFooterProps {\n\tonClear: () => void;\n\tonApply: () => void;\n}\n\nfunction PickerFooter({ onClear, onApply }: PickerFooterProps) {\n\treturn (\n\t\t<div className=\"flex items-center justify-end gap-2 border-t border-line-subtle px-4 py-3\">\n\t\t\t<Button variant=\"tertiary-outline\" size=\"sm\" onClick={onClear}>\n\t\t\t\tClear\n\t\t\t</Button>\n\t\t\t<Button size=\"sm\" onClick={onApply}>\n\t\t\t\tApply\n\t\t\t</Button>\n\t\t</div>\n\t);\n}\n\nconst PANEL_CLASSES =\n\t\"min-w-(--anchor-width) gap-0 overflow-hidden rounded-2xl flex flex-col items-center p-0\";\n\n// ─── DatePicker ───────────────────────────────────────────────────────────────\n\ninterface DatePickerProps {\n\tvalue?: Date;\n\tonChange?: (date: Date | undefined) => void;\n\tdisabled?: boolean;\n\tplaceholder?: string;\n\tclassName?: string;\n}\n\nfunction DatePicker({\n\tvalue,\n\tonChange,\n\tdisabled = false,\n\tplaceholder = \"Select date\",\n\tclassName,\n}: DatePickerProps) {\n\tconst [open, setOpen] = React.useState(false);\n\tconst [pending, setPending] = React.useState<Date | undefined>(value);\n\n\tfunction handleOpenChange(next: boolean) {\n\t\tif (next) setPending(value);\n\t\tsetOpen(next);\n\t}\n\n\treturn (\n\t\t<Popover open={open} onOpenChange={handleOpenChange}>\n\t\t\t<PickerTrigger\n\t\t\t\tdisplayValue={value ? formatDate(value) : \"\"}\n\t\t\t\tplaceholder={placeholder}\n\t\t\t\tdisabled={disabled}\n\t\t\t\topen={open}\n\t\t\t\tclassName={className}\n\t\t\t/>\n\t\t\t<PopoverContent\n\t\t\t\tshowArrow={false}\n\t\t\t\talign=\"start\"\n\t\t\t\tside=\"bottom\"\n\t\t\t\tclassName={PANEL_CLASSES}\n\t\t\t>\n\t\t\t\t<div>\n\t\t\t\t\t<Calendar mode=\"single\" selected={pending} onSelect={setPending} />\n\t\t\t\t\t<PickerFooter\n\t\t\t\t\t\tonClear={() => {\n\t\t\t\t\t\t\tsetPending(undefined);\n\t\t\t\t\t\t\tonChange?.(undefined);\n\t\t\t\t\t\t\tsetOpen(false);\n\t\t\t\t\t\t}}\n\t\t\t\t\t\tonApply={() => {\n\t\t\t\t\t\t\tonChange?.(pending);\n\t\t\t\t\t\t\tsetOpen(false);\n\t\t\t\t\t\t}}\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\t\t\t</PopoverContent>\n\t\t</Popover>\n\t);\n}\n\n// ─── DateRangePicker ──────────────────────────────────────────────────────────\n\ninterface DateRangePickerProps {\n\tvalue?: DateRange;\n\tonChange?: (range: DateRange | undefined) => void;\n\tdisabled?: boolean;\n\tplaceholder?: string;\n\tclassName?: string;\n}\n\nfunction DateRangePicker({\n\tvalue,\n\tonChange,\n\tdisabled = false,\n\tplaceholder = \"Select date range\",\n\tclassName,\n}: DateRangePickerProps) {\n\tconst [open, setOpen] = React.useState(false);\n\tconst [pending, setPending] = React.useState<DateRange | undefined>(value);\n\n\tfunction handleOpenChange(next: boolean) {\n\t\tif (next) setPending(value);\n\t\tsetOpen(next);\n\t}\n\n\tconst displayValue = (() => {\n\t\tif (value?.from && value?.to)\n\t\t\treturn `${formatDate(value.from)} — ${formatDate(value.to)}`;\n\t\tif (value?.from) return formatDate(value.from);\n\t\treturn \"\";\n\t})();\n\n\treturn (\n\t\t<Popover open={open} onOpenChange={handleOpenChange}>\n\t\t\t<PickerTrigger\n\t\t\t\tdisplayValue={displayValue}\n\t\t\t\tplaceholder={placeholder}\n\t\t\t\tdisabled={disabled}\n\t\t\t\topen={open}\n\t\t\t\tclassName={className}\n\t\t\t/>\n\t\t\t<PopoverContent\n\t\t\t\tshowArrow={false}\n\t\t\t\talign=\"start\"\n\t\t\t\tclassName={cn(PANEL_CLASSES, \"w-auto\")}\n\t\t\t>\n\t\t\t\t<Calendar mode=\"range\" selected={pending} onSelect={setPending} />\n\t\t\t\t<PickerFooter\n\t\t\t\t\tonClear={() => {\n\t\t\t\t\t\tsetPending(undefined);\n\t\t\t\t\t\tonChange?.(undefined);\n\t\t\t\t\t\tsetOpen(false);\n\t\t\t\t\t}}\n\t\t\t\t\tonApply={() => {\n\t\t\t\t\t\tonChange?.(pending);\n\t\t\t\t\t\tsetOpen(false);\n\t\t\t\t\t}}\n\t\t\t\t/>\n\t\t\t</PopoverContent>\n\t\t</Popover>\n\t);\n}\n\nexport { DatePicker, DateRangePicker };\nexport type { DatePickerProps, DateRangePickerProps, DateRange };\n","\"use client\";\n\nimport { Popover as PopoverPrimitive } from \"@base-ui/react/popover\";\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport { type ComponentSize, SizeProvider } from \"./size-context\";\n\nfunction Popover({ ...props }: PopoverPrimitive.Root.Props) {\n\treturn <PopoverPrimitive.Root data-slot=\"popover\" {...props} />;\n}\n\nfunction PopoverTrigger({ ...props }: PopoverPrimitive.Trigger.Props) {\n\treturn <PopoverPrimitive.Trigger data-slot=\"popover-trigger\" {...props} />;\n}\n\ntype PopoverContentProps = PopoverPrimitive.Popup.Props &\n\tPick<\n\t\tPopoverPrimitive.Positioner.Props,\n\t\t\"align\" | \"alignOffset\" | \"side\" | \"sideOffset\"\n\t> & {\n\t\tshowArrow?: boolean;\n\t\tsize?: ComponentSize;\n\t};\n\nfunction PopoverContent({\n\tclassName,\n\talign = \"center\",\n\talignOffset = 0,\n\tside = \"bottom\",\n\tsideOffset = 6,\n\tshowArrow = true,\n\tsize = \"md\",\n\tchildren,\n\t...props\n}: PopoverContentProps) {\n\treturn (\n\t\t<PopoverPrimitive.Portal>\n\t\t\t<PopoverPrimitive.Positioner\n\t\t\t\talign={align}\n\t\t\t\talignOffset={alignOffset}\n\t\t\t\tside={side}\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t\tclassName=\"isolate z-50\"\n\t\t\t>\n\t\t\t\t<PopoverPrimitive.Popup\n\t\t\t\t\tdata-slot=\"popover-content\"\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"z-50 relative flex w-72 max-w-[calc(100vw-2rem)] origin-(--transform-origin) flex-col rounded-lg border-0 bg-surface-overlay py-4 text-gdt-sm text-fg-primary shadow-2 outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 has-[&_[data-slot=popover-footer]]:pb-0\",\n\t\t\t\t\t\tclassName,\n\t\t\t\t\t)}\n\t\t\t\t\t{...props}\n\t\t\t\t>\n\t\t\t\t\t<SizeProvider size={size}>{children}</SizeProvider>\n\t\t\t\t\t{showArrow ? (\n\t\t\t\t\t\t<PopoverPrimitive.Arrow className=\"relative block w-3 h-1.5 overflow-clip data-[side=bottom]:top-[-6px] data-[side=left]:right-[-9px] data-[side=left]:rotate-90 data-[side=right]:left-[-9px] data-[side=right]:-rotate-90 data-[side=top]:bottom-[-6px] data-[side=top]:rotate-180 before:content-[''] before:absolute before:bottom-0 before:left-1/2 before:w-[calc(6px*sqrt(2))] before:h-[calc(6px*sqrt(2))] before:bg-surface-overlay before:border before:border-line before:[transform:translate(-50%,50%)_rotate(45deg)]\" />\n\t\t\t\t\t) : null}\n\t\t\t\t</PopoverPrimitive.Popup>\n\t\t\t</PopoverPrimitive.Positioner>\n\t\t</PopoverPrimitive.Portal>\n\t);\n}\n\nfunction PopoverHeader({\n\tclassName,\n\tborder,\n\t...props\n}: React.ComponentProps<\"div\"> & { border?: boolean }) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"popover-header\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex flex-col gap-0.5 px-4\",\n\t\t\t\tborder && \"border-b border-line-subtle pb-3\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PopoverBody({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"popover-body\"\n\t\t\tclassName={cn(\"px-4 py-2\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PopoverFooter({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"popover-footer\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex flex-row items-center gap-2 px-4 border-t border-line-subtle pt-3\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PopoverTitle({ className, ...props }: PopoverPrimitive.Title.Props) {\n\treturn (\n\t\t<PopoverPrimitive.Title\n\t\t\tdata-slot=\"popover-title\"\n\t\t\tclassName={cn(\"text-gdt-sm font-semibold text-fg-primary\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PopoverDescription({\n\tclassName,\n\t...props\n}: PopoverPrimitive.Description.Props) {\n\treturn (\n\t\t<PopoverPrimitive.Description\n\t\t\tdata-slot=\"popover-description\"\n\t\t\tclassName={cn(\"text-gdt-xs font-normal text-fg-secondary\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tPopover,\n\tPopoverContent,\n\tPopoverDescription,\n\tPopoverHeader,\n\tPopoverTitle,\n\tPopoverTrigger,\n\tPopoverBody,\n\tPopoverFooter,\n};\n","\"use client\";\n\nimport { Dialog as DialogPrimitive } from \"@base-ui/react/dialog\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { XIcon } from \"lucide-react\";\nimport type * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\nimport { SizeProvider, useComponentSize } from \"./size-context\";\n\nfunction Dialog({ ...props }: DialogPrimitive.Root.Props) {\n\treturn <DialogPrimitive.Root data-slot=\"dialog\" {...props} />;\n}\n\nfunction DialogTrigger({ ...props }: DialogPrimitive.Trigger.Props) {\n\treturn <DialogPrimitive.Trigger data-slot=\"dialog-trigger\" {...props} />;\n}\n\nfunction DialogPortal({ ...props }: DialogPrimitive.Portal.Props) {\n\treturn <DialogPrimitive.Portal data-slot=\"dialog-portal\" {...props} />;\n}\n\nfunction DialogClose({ ...props }: DialogPrimitive.Close.Props) {\n\treturn <DialogPrimitive.Close data-slot=\"dialog-close\" {...props} />;\n}\n\nfunction DialogOverlay({\n\tclassName,\n\t...props\n}: DialogPrimitive.Backdrop.Props) {\n\treturn (\n\t\t<DialogPrimitive.Backdrop\n\t\t\tdata-slot=\"dialog-overlay\"\n\t\t\tclassName={cn(\n\t\t\t\t\"fixed inset-0 z-50 bg-black/55 transition-opacity duration-150 data-closed:opacity-0 data-open:opacity-100 supports-backdrop-filter:backdrop-blur-xl\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst dialogContentVariants = cva(\n\t\"group/dialog-content fixed top-1/2 left-1/2 z-50 flex max-h-[calc(100dvh-5rem)] w-full max-w-[calc(100vw-2rem)] -translate-x-1/2 -translate-y-1/2 flex-col gap-4 overflow-visible rounded-2xl border border-line-subtle bg-surface-overlay bg-clip-padding p-(--dialog-padding) text-fg-primary shadow-(--elevation-e2-shadow) outline-none [--dialog-padding:1.25rem] transition-[opacity,transform] duration-200 ease-in-out data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"sm:w-90 sm:[--dialog-padding:1.5rem]\",\n\t\t\t\tmd: \"sm:w-105 sm:[--dialog-padding:1.5rem]\",\n\t\t\t\tlg: \"sm:w-120 sm:[--dialog-padding:2rem]\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst dialogIconVariants = cva(\n\t\"flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tauto: \"group-data-[size=sm]/dialog-content:size-10 group-data-[size=sm]/dialog-content:rounded-md group-data-[size=sm]/dialog-content:[&_svg:not([class*='size-'])]:size-6 group-data-[size=md]/dialog-content:size-12 group-data-[size=md]/dialog-content:rounded-[10px] group-data-[size=md]/dialog-content:[&_svg:not([class*='size-'])]:size-8 group-data-[size=lg]/dialog-content:size-14 group-data-[size=lg]/dialog-content:rounded-lg group-data-[size=lg]/dialog-content:[&_svg:not([class*='size-'])]:size-10\",\n\t\t\t\tsm: \"size-10 rounded-md [&_svg:not([class*='size-'])]:size-6\",\n\t\t\t\tmd: \"size-12 rounded-[10px] [&_svg:not([class*='size-'])]:size-8\",\n\t\t\t\tlg: \"size-14 rounded-lg [&_svg:not([class*='size-'])]:size-10\",\n\t\t\t},\n\t\t\ttone: {\n\t\t\t\tbrand: \"bg-surface-brand-subtle text-fg-brand\",\n\t\t\t\tdanger: \"bg-surface-danger-subtle text-status-danger\",\n\t\t\t\tneutral: \"bg-surface-raised text-fg-primary\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"auto\",\n\t\t\ttone: \"brand\",\n\t\t},\n\t},\n);\n\ntype DialogContentProps = DialogPrimitive.Popup.Props &\n\tVariantProps<typeof dialogContentVariants> & {\n\t\tshowCloseButton?: boolean;\n\t};\n\nfunction DialogContent({\n\tclassName,\n\tchildren,\n\tsize,\n\tshowCloseButton = true,\n\t...props\n}: DialogContentProps) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn (\n\t\t<DialogPortal>\n\t\t\t<DialogOverlay />\n\t\t\t<SizeProvider size={resolvedSize}>\n\t\t\t\t<DialogPrimitive.Popup\n\t\t\t\t\tdata-slot=\"dialog-content\"\n\t\t\t\t\tdata-size={resolvedSize}\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\tdialogContentVariants({ size: resolvedSize }),\n\t\t\t\t\t\tclassName,\n\t\t\t\t\t)}\n\t\t\t\t\t{...props}\n\t\t\t\t>\n\t\t\t\t\t{children}\n\t\t\t\t\t{showCloseButton && (\n\t\t\t\t\t\t<DialogPrimitive.Close\n\t\t\t\t\t\t\tdata-slot=\"dialog-close\"\n\t\t\t\t\t\t\trender={\n\t\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\t\tvariant=\"tertiary\"\n\t\t\t\t\t\t\t\t\tclassName=\"absolute -top-10 right-0 z-10\"\n\t\t\t\t\t\t\t\t\tsize=\"icon-sm\"\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<XIcon />\n\t\t\t\t\t\t\t\t\t<span className=\"sr-only\">Close</span>\n\t\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t\t</DialogPrimitive.Popup>\n\t\t\t</SizeProvider>\n\t\t</DialogPortal>\n\t);\n}\n\nfunction DialogIcon({\n\tclassName,\n\tsize,\n\ttone,\n\t...props\n}: React.ComponentProps<\"div\"> & VariantProps<typeof dialogIconVariants>) {\n\tconst inheritedSize = useComponentSize();\n\tconst resolvedSize = !size || size === \"auto\" ? inheritedSize : size;\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"dialog-icon\"\n\t\t\tclassName={cn(\n\t\t\t\tdialogIconVariants({ size: resolvedSize, tone }),\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DialogHeader({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"dialog-header\"\n\t\t\tclassName={cn(\"flex flex-col gap-3\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DialogFooter({\n\tclassName,\n\tshowCloseButton = false,\n\tchildren,\n\t...props\n}: React.ComponentProps<\"div\"> & {\n\tshowCloseButton?: boolean;\n}) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"dialog-footer\"\n\t\t\tclassName={cn(\n\t\t\t\t\"mt-2 flex flex-col-reverse gap-2 sm:flex-row sm:justify-end `**:data-[slot=button-link]:w-full **:data-[slot=button]:w-full sm:**:data-[slot=button-link]:w-auto sm:**:data-[slot=button]:w-auto\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t\t{showCloseButton && (\n\t\t\t\t<DialogPrimitive.Close\n\t\t\t\t\trender={<Button variant=\"tertiary-outline\">Close</Button>}\n\t\t\t\t/>\n\t\t\t)}\n\t\t</div>\n\t);\n}\n\nfunction DialogTitle({ className, ...props }: DialogPrimitive.Title.Props) {\n\treturn (\n\t\t<DialogPrimitive.Title\n\t\t\tdata-slot=\"dialog-title\"\n\t\t\tclassName={cn(\n\t\t\t\t\"text-gdt-h5 font-extrabold tracking-tight text-fg-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DialogDescription({\n\tclassName,\n\t...props\n}: DialogPrimitive.Description.Props) {\n\treturn (\n\t\t<DialogPrimitive.Description\n\t\t\tdata-slot=\"dialog-description\"\n\t\t\tclassName={cn(\n\t\t\t\t\"text-gdt-sm text-fg-secondary *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-fg-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tDialog,\n\tDialogClose,\n\tDialogContent,\n\tDialogDescription,\n\tDialogFooter,\n\tDialogHeader,\n\tDialogIcon,\n\tDialogOverlay,\n\tDialogPortal,\n\tDialogTitle,\n\tDialogTrigger,\n\tdialogContentVariants,\n\tdialogIconVariants,\n};\n","\"use client\";\n\nimport { Menu as MenuPrimitive } from \"@base-ui/react/menu\";\nimport { cva } from \"class-variance-authority\";\nimport { CheckIcon, ChevronRightIcon } from \"lucide-react\";\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport {\n\ttype ComponentSize,\n\tSizeProvider,\n\tuseComponentSize,\n} from \"./size-context\";\n\ntype DropdownMenuSize = ComponentSize;\n\nfunction DropdownMenu({\n\tchildren,\n\tsize,\n\t...props\n}: MenuPrimitive.Root.Props & {\n\tsize?: DropdownMenuSize;\n}) {\n\treturn (\n\t\t<SizeProvider size={size}>\n\t\t\t<MenuPrimitive.Root data-slot=\"dropdown-menu\" {...props}>\n\t\t\t\t{children}\n\t\t\t</MenuPrimitive.Root>\n\t\t</SizeProvider>\n\t);\n}\n\nfunction DropdownMenuPortal({ ...props }: MenuPrimitive.Portal.Props) {\n\treturn <MenuPrimitive.Portal data-slot=\"dropdown-menu-portal\" {...props} />;\n}\n\nfunction DropdownMenuTrigger({ ...props }: MenuPrimitive.Trigger.Props) {\n\treturn <MenuPrimitive.Trigger data-slot=\"dropdown-menu-trigger\" {...props} />;\n}\n\nconst dropdownMenuContentVariants = cva(\n\t\"relative isolate z-50 max-h-(--available-height) w-(--anchor-width) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto border border-line-subtle bg-canvas text-fg-primary shadow-(--elevation-e1-shadow) duration-100 outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:overflow-hidden data-closed:fade-out-0 data-closed:zoom-out-95\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"rounded-lg p-1\",\n\t\t\t\tmd: \"rounded-xl p-1.5\",\n\t\t\t\tlg: \"rounded-[18px] p-2\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst dropdownMenuItemVariants = cva(\n\t\"group/dropdown-menu-item relative flex w-full cursor-pointer items-center font-normal text-fg-primary outline-none transition-colors select-none focus:bg-surface focus:text-fg-primary data-highlighted:bg-surface data-highlighted:text-fg-primary data-[variant=destructive]:text-fg-danger data-[variant=destructive]:focus:bg-surface-danger-subtle data-[variant=destructive]:focus:text-fg-danger data-[variant=destructive]:data-highlighted:bg-surface-danger-subtle data-[variant=destructive]:data-highlighted:text-fg-danger data-disabled:pointer-events-none data-disabled:text-fg-caption-placeholder data-disabled:opacity-100 [&_svg]:pointer-events-none [&_svg]:shrink-0 data-[variant=destructive]:[&_svg]:text-fg-danger\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"gap-1.5 rounded-md px-3 py-1.5 text-gdt-xs [&_svg:not([class*='size-'])]:size-3.5\",\n\t\t\t\tmd: \"gap-2 rounded-md px-4 py-2 text-gdt-sm [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\tlg: \"gap-2.5 rounded-md px-4 py-2.5 text-gdt-md [&_svg:not([class*='size-'])]:size-4.5\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst dropdownMenuLabelVariants = cva(\n\t\"font-medium text-fg-secondary data-inset:pl-8\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"px-3 py-1 text-gdt-xs\",\n\t\t\t\tmd: \"px-3 py-1 text-gdt-xs\",\n\t\t\t\tlg: \"px-4 py-1.5 text-gdt-sm\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nfunction DropdownMenuContent({\n\talign = \"start\",\n\talignOffset = 0,\n\tside = \"bottom\",\n\tsideOffset = 6,\n\tclassName,\n\t...props\n}: MenuPrimitive.Popup.Props &\n\tPick<\n\t\tMenuPrimitive.Positioner.Props,\n\t\t\"align\" | \"alignOffset\" | \"side\" | \"sideOffset\"\n\t>) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<MenuPrimitive.Portal>\n\t\t\t<MenuPrimitive.Positioner\n\t\t\t\tclassName=\"isolate z-50 outline-none\"\n\t\t\t\talign={align}\n\t\t\t\talignOffset={alignOffset}\n\t\t\t\tside={side}\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t>\n\t\t\t\t<MenuPrimitive.Popup\n\t\t\t\t\tdata-slot=\"dropdown-menu-content\"\n\t\t\t\t\tdata-size={resolvedSize}\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\tdropdownMenuContentVariants({ size: resolvedSize }),\n\t\t\t\t\t\tclassName,\n\t\t\t\t\t)}\n\t\t\t\t\t{...props}\n\t\t\t\t/>\n\t\t\t</MenuPrimitive.Positioner>\n\t\t</MenuPrimitive.Portal>\n\t);\n}\n\nfunction DropdownMenuGroup({ className, ...props }: MenuPrimitive.Group.Props) {\n\treturn (\n\t\t<MenuPrimitive.Group\n\t\t\tdata-slot=\"dropdown-menu-group\"\n\t\t\tclassName={cn(\"scroll-my-1 space-y-0.5\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DropdownMenuLabel({\n\tclassName,\n\tinset,\n\t...props\n}: MenuPrimitive.GroupLabel.Props & {\n\tinset?: boolean;\n}) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<MenuPrimitive.GroupLabel\n\t\t\tdata-slot=\"dropdown-menu-label\"\n\t\t\tdata-inset={inset}\n\t\t\tclassName={cn(\n\t\t\t\tdropdownMenuLabelVariants({ size: resolvedSize }),\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DropdownMenuItem({\n\tclassName,\n\tinset,\n\tvariant = \"default\",\n\t...props\n}: MenuPrimitive.Item.Props & {\n\tinset?: boolean;\n\tvariant?: \"default\" | \"destructive\";\n}) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<MenuPrimitive.Item\n\t\t\tdata-slot=\"dropdown-menu-item\"\n\t\t\tdata-inset={inset}\n\t\t\tdata-size={resolvedSize}\n\t\t\tdata-variant={variant}\n\t\t\tclassName={cn(\n\t\t\t\tdropdownMenuItemVariants({ size: resolvedSize }),\n\t\t\t\t\"data-inset:pl-8\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DropdownMenuSub({ ...props }: MenuPrimitive.SubmenuRoot.Props) {\n\treturn <MenuPrimitive.SubmenuRoot data-slot=\"dropdown-menu-sub\" {...props} />;\n}\n\nfunction DropdownMenuSubTrigger({\n\tclassName,\n\tinset,\n\tchildren,\n\t...props\n}: MenuPrimitive.SubmenuTrigger.Props & {\n\tinset?: boolean;\n}) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<MenuPrimitive.SubmenuTrigger\n\t\t\tdata-slot=\"dropdown-menu-sub-trigger\"\n\t\t\tdata-inset={inset}\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(\n\t\t\t\tdropdownMenuItemVariants({ size: resolvedSize }),\n\t\t\t\t\"data-inset:pl-8 data-open:bg-surface data-open:text-fg-primary data-popup-open:bg-surface data-popup-open:text-fg-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t\t<ChevronRightIcon className=\"cn-rtl-flip ml-auto\" />\n\t\t</MenuPrimitive.SubmenuTrigger>\n\t);\n}\n\nfunction DropdownMenuSubContent({\n\talign = \"start\",\n\talignOffset = -3,\n\tside = \"right\",\n\tsideOffset = 4,\n\tclassName,\n\t...props\n}: React.ComponentProps<typeof DropdownMenuContent>) {\n\treturn (\n\t\t<DropdownMenuContent\n\t\t\tdata-slot=\"dropdown-menu-sub-content\"\n\t\t\tclassName={cn(\n\t\t\t\t\"w-auto min-w-28 shadow-(--elevation-e2-shadow)\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\talign={align}\n\t\t\talignOffset={alignOffset}\n\t\t\tside={side}\n\t\t\tsideOffset={sideOffset}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DropdownMenuCheckboxItem({\n\tclassName,\n\tchildren,\n\tchecked,\n\tinset,\n\t...props\n}: MenuPrimitive.CheckboxItem.Props & {\n\tinset?: boolean;\n}) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<MenuPrimitive.CheckboxItem\n\t\t\tdata-slot=\"dropdown-menu-checkbox-item\"\n\t\t\tdata-inset={inset}\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(\n\t\t\t\tdropdownMenuItemVariants({ size: resolvedSize }),\n\t\t\t\t\"pr-10 data-inset:pl-8\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tchecked={checked}\n\t\t\t{...props}\n\t\t>\n\t\t\t<span\n\t\t\t\tclassName=\"pointer-events-none absolute right-3 flex items-center justify-center text-fg-brand\"\n\t\t\t\tdata-slot=\"dropdown-menu-checkbox-item-indicator\"\n\t\t\t>\n\t\t\t\t<MenuPrimitive.CheckboxItemIndicator>\n\t\t\t\t\t<CheckIcon />\n\t\t\t\t</MenuPrimitive.CheckboxItemIndicator>\n\t\t\t</span>\n\t\t\t{children}\n\t\t</MenuPrimitive.CheckboxItem>\n\t);\n}\n\nfunction DropdownMenuRadioGroup({ ...props }: MenuPrimitive.RadioGroup.Props) {\n\treturn (\n\t\t<MenuPrimitive.RadioGroup\n\t\t\tdata-slot=\"dropdown-menu-radio-group\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DropdownMenuRadioItem({\n\tclassName,\n\tchildren,\n\tinset,\n\t...props\n}: MenuPrimitive.RadioItem.Props & {\n\tinset?: boolean;\n}) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<MenuPrimitive.RadioItem\n\t\t\tdata-slot=\"dropdown-menu-radio-item\"\n\t\t\tdata-inset={inset}\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(\n\t\t\t\tdropdownMenuItemVariants({ size: resolvedSize }),\n\t\t\t\t\"pr-10 data-inset:pl-8\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<span\n\t\t\t\tclassName=\"pointer-events-none absolute right-3 flex items-center justify-center text-fg-brand\"\n\t\t\t\tdata-slot=\"dropdown-menu-radio-item-indicator\"\n\t\t\t>\n\t\t\t\t<MenuPrimitive.RadioItemIndicator>\n\t\t\t\t\t<CheckIcon />\n\t\t\t\t</MenuPrimitive.RadioItemIndicator>\n\t\t\t</span>\n\t\t\t{children}\n\t\t</MenuPrimitive.RadioItem>\n\t);\n}\n\nfunction DropdownMenuSeparator({\n\tclassName,\n\t...props\n}: MenuPrimitive.Separator.Props) {\n\treturn (\n\t\t<MenuPrimitive.Separator\n\t\t\tdata-slot=\"dropdown-menu-separator\"\n\t\t\tclassName={cn(\"pointer-events-none my-1 h-px bg-line-subtle\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DropdownMenuShortcut({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\tdata-slot=\"dropdown-menu-shortcut\"\n\t\t\tclassName={cn(\n\t\t\t\t\"ml-auto text-gdt-xs tracking-widest text-fg-secondary group-focus/dropdown-menu-item:text-fg-primary group-data-highlighted/dropdown-menu-item:text-fg-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tDropdownMenu,\n\tDropdownMenuPortal,\n\tDropdownMenuTrigger,\n\tDropdownMenuContent,\n\tDropdownMenuGroup,\n\tDropdownMenuLabel,\n\tDropdownMenuItem,\n\tDropdownMenuCheckboxItem,\n\tDropdownMenuRadioGroup,\n\tDropdownMenuRadioItem,\n\tDropdownMenuSeparator,\n\tDropdownMenuShortcut,\n\tDropdownMenuSub,\n\tDropdownMenuSubTrigger,\n\tDropdownMenuSubContent,\n\ttype DropdownMenuSize,\n};\n","\"use client\";\n\nimport { UploadCloud } from \"lucide-react\";\nimport {\n\ttype ComponentProps,\n\tcreateContext,\n\ttype KeyboardEvent,\n\ttype ReactNode,\n\tuse,\n} from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport {\n\ttype UseFilePickerOptions,\n\ttype UseFilePickerReturn,\n\tuseFilePicker,\n} from \"../../lib/use-file-picker\";\n\n// ─────────────────────────────────────────────────────────────────────────────\n// Context\n// ─────────────────────────────────────────────────────────────────────────────\n\ntype DropzoneContextValue = Pick<\n\tUseFilePickerReturn,\n\t| \"isDragging\"\n\t| \"openFileDialog\"\n\t| \"getInputProps\"\n\t| \"handleDragEnter\"\n\t| \"handleDragLeave\"\n\t| \"handleDragOver\"\n\t| \"handleDrop\"\n> & { isDisabled: boolean };\n\nconst DropzoneContext = createContext<DropzoneContextValue | null>(null);\n\nfunction useDropzoneContext(): DropzoneContextValue {\n\tconst ctx = use(DropzoneContext);\n\tif (!ctx) {\n\t\tthrow new Error(\n\t\t\t\"Dropzone compound components must be rendered inside <Dropzone>.\",\n\t\t);\n\t}\n\treturn ctx;\n}\n\n// ─────────────────────────────────────────────────────────────────────────────\n// Root\n// ─────────────────────────────────────────────────────────────────────────────\n\ninterface DropzoneProps extends UseFilePickerOptions {\n\tchildren?: ReactNode;\n\tclassName?: string;\n}\n\n/**\n * Context provider that owns the `useFilePicker` instance.\n * Wrap `<DropzoneArea>` and `<DropzoneInput>` (plus any content helpers)\n * inside this component.\n *\n * @example\n * ```tsx\n * <Dropzone accept=\"image/*\" multiple maxFiles={5} onFilesAccepted={handleFiles}>\n * <DropzoneArea>\n * <DropzoneIcon />\n * <DropzoneTitle>Choose a file or drag & drop</DropzoneTitle>\n * <DropzoneDescription>JPEG, PNG – up to 2 MB</DropzoneDescription>\n * <DropzoneTrigger />\n * </DropzoneArea>\n * <DropzoneInput />\n * </Dropzone>\n * ```\n */\nfunction Dropzone({\n\tchildren,\n\tclassName,\n\tdisabled,\n\t...options\n}: DropzoneProps) {\n\tconst {\n\t\tisDragging,\n\t\topenFileDialog,\n\t\tgetInputProps,\n\t\thandleDragEnter,\n\t\thandleDragLeave,\n\t\thandleDragOver,\n\t\thandleDrop,\n\t} = useFilePicker({ ...options, disabled });\n\n\treturn (\n\t\t<DropzoneContext.Provider\n\t\t\tvalue={{\n\t\t\t\tisDragging,\n\t\t\t\tisDisabled: disabled ?? false,\n\t\t\t\topenFileDialog,\n\t\t\t\tgetInputProps,\n\t\t\t\thandleDragEnter,\n\t\t\t\thandleDragLeave,\n\t\t\t\thandleDragOver,\n\t\t\t\thandleDrop,\n\t\t\t}}\n\t\t>\n\t\t\t<div data-slot=\"dropzone\" className={cn(\"relative\", className)}>\n\t\t\t\t{children}\n\t\t\t</div>\n\t\t</DropzoneContext.Provider>\n\t);\n}\n\n// ─────────────────────────────────────────────────────────────────────────────\n// Area (the interactive drop target)\n// ─────────────────────────────────────────────────────────────────────────────\n\ninterface DropzoneAreaProps\n\textends Omit<ComponentProps<\"div\">, \"onClick\" | \"onKeyDown\"> {\n\t/**\n\t * Accessible label for the drop zone.\n\t * Defaults to a sensible description.\n\t */\n\tlabel?: string;\n}\n\n/**\n * The visual, interactive drop zone.\n *\n * - Behaves as a `button` (role, tabIndex, Enter/Space keyboard support).\n * - Announces drag-state changes to screen readers via a live region.\n * - Applies design-token-based styles and reacts to `data-dragging` /\n * `data-disabled` for visual feedback.\n */\nfunction DropzoneArea({\n\tchildren,\n\tclassName,\n\tlabel = \"Upload files. Click to browse, or drag and drop files here.\",\n\t...props\n}: DropzoneAreaProps) {\n\tconst {\n\t\tisDragging,\n\t\tisDisabled,\n\t\topenFileDialog,\n\t\thandleDragEnter,\n\t\thandleDragLeave,\n\t\thandleDragOver,\n\t\thandleDrop,\n\t} = useDropzoneContext();\n\n\tfunction handleKeyDown(e: KeyboardEvent<HTMLDivElement>) {\n\t\tif (e.key === \"Enter\" || e.key === \" \") {\n\t\t\te.preventDefault();\n\t\t\topenFileDialog();\n\t\t}\n\t}\n\n\treturn (\n\t\t// biome-ignore lint/a11y/useSemanticElements: The dropzone contains block-level compound content and owns drag events.\n\t\t<div\n\t\t\tdata-slot=\"dropzone-area\"\n\t\t\t// Data attributes drive all variant styles – no runtime class toggling.\n\t\t\tdata-dragging={isDragging ? \"true\" : undefined}\n\t\t\tdata-disabled={isDisabled ? \"true\" : undefined}\n\t\t\t// Accessibility ──────────────────────────────────────────────────────\n\t\t\trole=\"button\"\n\t\t\ttabIndex={isDisabled ? -1 : 0}\n\t\t\taria-label={label}\n\t\t\taria-disabled={isDisabled}\n\t\t\t// Interaction ────────────────────────────────────────────────────────\n\t\t\tonClick={isDisabled ? undefined : openFileDialog}\n\t\t\tonKeyDown={isDisabled ? undefined : handleKeyDown}\n\t\t\tonDragEnter={isDisabled ? undefined : handleDragEnter}\n\t\t\tonDragLeave={isDisabled ? undefined : handleDragLeave}\n\t\t\tonDragOver={isDisabled ? undefined : handleDragOver}\n\t\t\tonDrop={isDisabled ? undefined : handleDrop}\n\t\t\t// Styles ─────────────────────────────────────────────────────────────\n\t\t\tclassName={cn(\n\t\t\t\t// Layout & base\n\t\t\t\t\"flex min-h-48 w-full cursor-pointer flex-col items-center justify-center rounded-xl border p-8 text-center transition-colors duration-150 select-none\",\n\t\t\t\t// Default colours (design tokens)\n\t\t\t\t\"border-line bg-surface-brand-subtle\",\n\t\t\t\t// Focus ring – matches other interactive controls in the system\n\t\t\t\t\"focus-visible:outline-none focus-visible:ring-3 focus-visible:ring-ring/20 focus-visible:border-ring\",\n\t\t\t\t// Dragging variant\n\t\t\t\t\"data-[dragging=true]:border-dashed data-[dragging=true]:border-line-focus data-[dragging=true]:bg-surface-brand/10\",\n\t\t\t\t// Disabled variant\n\t\t\t\t\"data-[disabled=true]:cursor-not-allowed data-[disabled=true]:opacity-50\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\n\t\t\t{/* Live region: announces drag-state changes to screen-reader users */}\n\t\t\t<span className=\"sr-only\" aria-live=\"polite\" aria-atomic=\"true\">\n\t\t\t\t{isDragging ? \"Drop files to upload.\" : \"\"}\n\t\t\t</span>\n\t\t</div>\n\t);\n}\n\n// ─────────────────────────────────────────────────────────────────────────────\n// Input (visually hidden but present in the a11y tree)\n// ─────────────────────────────────────────────────────────────────────────────\n\ntype DropzoneInputProps = Omit<ComponentProps<\"input\">, \"type\">;\n\n/**\n * The hidden `<input type=\"file\">` that backs the drop zone.\n * Rendered off-screen (not `display:none`) so it remains accessible.\n * Place it as a sibling to `<DropzoneArea>` inside `<Dropzone>`.\n */\nfunction DropzoneInput({ className, ...props }: DropzoneInputProps) {\n\tconst { getInputProps } = useDropzoneContext();\n\treturn (\n\t\t<input\n\t\t\t{...getInputProps({\n\t\t\t\t// sr-only keeps it in the a11y tree without being visible\n\t\t\t\tclassName: cn(\"sr-only\", className),\n\t\t\t\t// Prevent it from receiving keyboard focus independently\n\t\t\t\ttabIndex: -1,\n\t\t\t\t...props,\n\t\t\t})}\n\t\t/>\n\t);\n}\n\n// ─────────────────────────────────────────────────────────────────────────────\n// Content helpers\n// ─────────────────────────────────────────────────────────────────────────────\n\ntype DropzoneStateLabelProps = {\n\tchildren?: ReactNode;\n\tdisabledLabel?: ReactNode;\n\tdraggingLabel?: ReactNode;\n\tidleLabel?: ReactNode;\n};\n\ntype DropzoneTextProps = Omit<ComponentProps<\"p\">, \"children\"> &\n\tDropzoneStateLabelProps;\n\nfunction useDropzoneStateLabel({\n\tchildren,\n\tdisabledLabel,\n\tdraggingLabel,\n\tidleLabel,\n}: DropzoneStateLabelProps) {\n\tconst { isDragging, isDisabled } = useDropzoneContext();\n\n\tif (isDisabled && disabledLabel !== undefined) {\n\t\treturn disabledLabel;\n\t}\n\n\tif (isDragging && draggingLabel !== undefined) {\n\t\treturn draggingLabel;\n\t}\n\n\treturn idleLabel ?? children;\n}\n\n/**\n * A centred, brand-coloured icon container pre-populated with an upload cloud\n * icon. Pass `children` to swap the icon.\n */\nfunction DropzoneIcon({\n\tclassName,\n\tchildren,\n\t...props\n}: ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"dropzone-icon\"\n\t\t\taria-hidden=\"true\"\n\t\t\tclassName={cn(\n\t\t\t\t\"mb-4 flex size-11 shrink-0 items-center justify-center rounded-full\",\n\t\t\t\t// Solid brand fill with an inset ring for depth\n\t\t\t\t\"bg-surface-brand text-fg-on-brand ring-1 ring-inset ring-white/10\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children ?? <UploadCloud className=\"size-5\" />}\n\t\t</div>\n\t);\n}\n\n/**\n * Primary heading text inside the drop zone.\n */\nfunction DropzoneTitle({\n\tclassName,\n\tchildren,\n\tdisabledLabel,\n\tdraggingLabel,\n\tidleLabel,\n\t...props\n}: DropzoneTextProps) {\n\tconst label = useDropzoneStateLabel({\n\t\tchildren,\n\t\tdisabledLabel,\n\t\tdraggingLabel,\n\t\tidleLabel,\n\t});\n\n\treturn (\n\t\t<p\n\t\t\tdata-slot=\"dropzone-title\"\n\t\t\tclassName={cn(\n\t\t\t\t\"text-lg font-semibold leading-snug text-fg-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{label}\n\t\t</p>\n\t);\n}\n\n/**\n * Secondary descriptive text inside the drop zone (file-type hints, size\n * limits, etc.).\n */\nfunction DropzoneDescription({\n\tclassName,\n\tchildren,\n\tdisabledLabel,\n\tdraggingLabel,\n\tidleLabel,\n\t...props\n}: DropzoneTextProps) {\n\tconst label = useDropzoneStateLabel({\n\t\tchildren,\n\t\tdisabledLabel,\n\t\tdraggingLabel,\n\t\tidleLabel,\n\t});\n\n\treturn (\n\t\t<p\n\t\t\tdata-slot=\"dropzone-description\"\n\t\t\tclassName={cn(\"mt-1 text-sm text-fg-muted\", className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{label}\n\t\t</p>\n\t);\n}\n\n/**\n * A decorative \"Browse File\" pill that visually suggests the click action.\n *\n * This element is `aria-hidden` because the surrounding `<DropzoneArea>`\n * already exposes a labelled `button` role to assistive technologies.\n * The pill is purely a visual affordance.\n */\nfunction DropzoneTrigger({\n\tclassName,\n\tchildren = \"Browse File\",\n\t...props\n}: ComponentProps<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\tdata-slot=\"dropzone-trigger\"\n\t\t\taria-hidden=\"true\"\n\t\t\tclassName={cn(\n\t\t\t\t\"mt-5 inline-flex h-8 shrink-0 items-center justify-center rounded-lg px-4\",\n\t\t\t\t\"bg-primary text-sm font-medium text-primary-foreground\",\n\t\t\t\t\"transition-colors duration-150\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t</span>\n\t);\n}\n\n// ─────────────────────────────────────────────────────────────────────────────\n// Exports\n// ─────────────────────────────────────────────────────────────────────────────\n\nexport {\n\tDropzone,\n\tDropzoneArea,\n\tDropzoneDescription,\n\tDropzoneIcon,\n\tDropzoneInput,\n\tDropzoneTitle,\n\tDropzoneTrigger,\n\tuseDropzoneContext,\n};\n","import {\n\ttype ChangeEvent,\n\ttype ComponentPropsWithoutRef,\n\ttype DragEvent,\n\ttype Ref,\n\ttype RefObject,\n\tuseCallback,\n\tuseRef,\n\tuseState,\n} from \"react\";\n\ntype FilePickerErrorCode =\n\t| \"file-invalid-type\"\n\t| \"file-too-large\"\n\t| \"too-many-files\";\n\ntype FilePickerError = {\n\tcode: FilePickerErrorCode;\n\tmessage: string;\n};\n\ntype FileRejection = {\n\tfile: File;\n\terrors: FilePickerError[];\n};\n\ntype FilePickerResult = {\n\tacceptedFiles: File[];\n\trejectedFiles: FileRejection[];\n};\n\ntype UseFilePickerOptions = {\n\taccept?: string;\n\tdisabled?: boolean;\n\tmaxFiles?: number;\n\tmaxSize?: number;\n\tmultiple?: boolean;\n\tonFilesAccepted?: (files: File[]) => void;\n\tonFilesChange?: (result: FilePickerResult) => void;\n\tonFilesRejected?: (rejectedFiles: FileRejection[]) => void;\n};\n\ntype FilePickerInputProps = Omit<\n\tComponentPropsWithoutRef<\"input\">,\n\t\"type\" | \"accept\" | \"multiple\"\n> & {\n\taccept?: string;\n\tmultiple?: boolean;\n\tref?: Ref<HTMLInputElement>;\n};\n\ntype UseFilePickerReturn = {\n\tgetInputProps: (props?: FilePickerInputProps) => FilePickerInputProps & {\n\t\ttype: \"file\";\n\t\tref: Ref<HTMLInputElement>;\n\t};\n\thandleDragEnter: (event: DragEvent<HTMLElement>) => void;\n\thandleDragLeave: (event: DragEvent<HTMLElement>) => void;\n\thandleDragOver: (event: DragEvent<HTMLElement>) => void;\n\thandleDrop: (event: DragEvent<HTMLElement>) => void;\n\thandleFileChange: (event: ChangeEvent<HTMLInputElement>) => void;\n\tinputRef: RefObject<HTMLInputElement | null>;\n\tisDragging: boolean;\n\topenFileDialog: () => void;\n\tpickFiles: (files: FileList | File[]) => FilePickerResult;\n};\n\nfunction useFilePicker({\n\taccept = \"*\",\n\tdisabled = false,\n\tmaxFiles = Number.POSITIVE_INFINITY,\n\tmaxSize = Number.POSITIVE_INFINITY,\n\tmultiple = false,\n\tonFilesAccepted,\n\tonFilesChange,\n\tonFilesRejected,\n}: UseFilePickerOptions = {}): UseFilePickerReturn {\n\tconst inputRef = useRef<HTMLInputElement>(null);\n\tconst dragDepthRef = useRef(0);\n\tconst [isDragging, setIsDragging] = useState(false);\n\n\tconst pickFiles = useCallback(\n\t\t(files: FileList | File[]): FilePickerResult => {\n\t\t\tconst incomingFiles = Array.from(files);\n\t\t\tconst limit = multiple ? maxFiles : 1;\n\t\t\tconst acceptedFiles: File[] = [];\n\t\t\tconst rejectedFiles: FileRejection[] = [];\n\n\t\t\tif (incomingFiles.length === 0 || disabled) {\n\t\t\t\treturn { acceptedFiles, rejectedFiles };\n\t\t\t}\n\n\t\t\tfor (const [index, file] of incomingFiles.entries()) {\n\t\t\t\tconst errors: FilePickerError[] = [];\n\n\t\t\t\tif (index >= limit) {\n\t\t\t\t\terrors.push({\n\t\t\t\t\t\tcode: \"too-many-files\",\n\t\t\t\t\t\tmessage: multiple\n\t\t\t\t\t\t\t? `You can only select up to ${limit} files.`\n\t\t\t\t\t\t\t: \"You can only select one file.\",\n\t\t\t\t\t});\n\t\t\t\t} else {\n\t\t\t\t\terrors.push(...validateFile(file, { accept, maxSize }));\n\t\t\t\t}\n\n\t\t\t\tif (errors.length > 0) {\n\t\t\t\t\trejectedFiles.push({ file, errors });\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tacceptedFiles.push(file);\n\t\t\t}\n\n\t\t\tconst result = { acceptedFiles, rejectedFiles };\n\n\t\t\tif (acceptedFiles.length > 0) {\n\t\t\t\tonFilesAccepted?.(acceptedFiles);\n\t\t\t}\n\n\t\t\tif (rejectedFiles.length > 0) {\n\t\t\t\tonFilesRejected?.(rejectedFiles);\n\t\t\t}\n\n\t\t\tonFilesChange?.(result);\n\n\t\t\tif (inputRef.current) {\n\t\t\t\tinputRef.current.value = \"\";\n\t\t\t}\n\n\t\t\treturn result;\n\t\t},\n\t\t[\n\t\t\taccept,\n\t\t\tdisabled,\n\t\t\tmaxFiles,\n\t\t\tmaxSize,\n\t\t\tmultiple,\n\t\t\tonFilesAccepted,\n\t\t\tonFilesChange,\n\t\t\tonFilesRejected,\n\t\t],\n\t);\n\n\tconst handleFileChange = useCallback(\n\t\t(event: ChangeEvent<HTMLInputElement>) => {\n\t\t\tif (event.target.files) {\n\t\t\t\tpickFiles(event.target.files);\n\t\t\t}\n\t\t},\n\t\t[pickFiles],\n\t);\n\n\tconst openFileDialog = useCallback(() => {\n\t\tif (disabled) return;\n\t\tinputRef.current?.click();\n\t}, [disabled]);\n\n\tconst handleDragEnter = useCallback(\n\t\t(event: DragEvent<HTMLElement>) => {\n\t\t\tevent.preventDefault();\n\t\t\tevent.stopPropagation();\n\n\t\t\tif (disabled) return;\n\n\t\t\tdragDepthRef.current += 1;\n\t\t\tsetIsDragging(true);\n\t\t},\n\t\t[disabled],\n\t);\n\n\tconst handleDragLeave = useCallback(\n\t\t(event: DragEvent<HTMLElement>) => {\n\t\t\tevent.preventDefault();\n\t\t\tevent.stopPropagation();\n\n\t\t\tif (disabled) return;\n\n\t\t\tdragDepthRef.current = Math.max(0, dragDepthRef.current - 1);\n\t\t\tif (dragDepthRef.current === 0) {\n\t\t\t\tsetIsDragging(false);\n\t\t\t}\n\t\t},\n\t\t[disabled],\n\t);\n\n\tconst handleDragOver = useCallback((event: DragEvent<HTMLElement>) => {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\t}, []);\n\n\tconst handleDrop = useCallback(\n\t\t(event: DragEvent<HTMLElement>) => {\n\t\t\tevent.preventDefault();\n\t\t\tevent.stopPropagation();\n\n\t\t\tdragDepthRef.current = 0;\n\t\t\tsetIsDragging(false);\n\n\t\t\tif (event.dataTransfer.files.length > 0) {\n\t\t\t\tpickFiles(event.dataTransfer.files);\n\t\t\t}\n\t\t},\n\t\t[pickFiles],\n\t);\n\n\tconst getInputProps = useCallback(\n\t\t(props: FilePickerInputProps = {}) => {\n\t\t\tconst { onChange, ref, ...inputProps } = props;\n\n\t\t\treturn {\n\t\t\t\t...inputProps,\n\t\t\t\ttype: \"file\" as const,\n\t\t\t\taccept: inputProps.accept ?? accept,\n\t\t\t\tdisabled: inputProps.disabled ?? disabled,\n\t\t\t\tmultiple: inputProps.multiple ?? multiple,\n\t\t\t\tref: (node: HTMLInputElement | null) => {\n\t\t\t\t\tinputRef.current = node;\n\t\t\t\t\tassignRef(ref, node);\n\t\t\t\t},\n\t\t\t\tonChange: (event: ChangeEvent<HTMLInputElement>) => {\n\t\t\t\t\tonChange?.(event);\n\t\t\t\t\tif (!event.defaultPrevented) {\n\t\t\t\t\t\thandleFileChange(event);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t\t[accept, disabled, handleFileChange, multiple],\n\t);\n\n\treturn {\n\t\tgetInputProps,\n\t\thandleDragEnter,\n\t\thandleDragLeave,\n\t\thandleDragOver,\n\t\thandleDrop,\n\t\thandleFileChange,\n\t\tinputRef,\n\t\tisDragging,\n\t\topenFileDialog,\n\t\tpickFiles,\n\t};\n}\n\nfunction validateFile(\n\tfile: File,\n\toptions: Pick<UseFilePickerOptions, \"accept\" | \"maxSize\"> = {},\n): FilePickerError[] {\n\tconst { accept = \"*\", maxSize = Number.POSITIVE_INFINITY } = options;\n\tconst errors: FilePickerError[] = [];\n\n\tif (file.size > maxSize) {\n\t\terrors.push({\n\t\t\tcode: \"file-too-large\",\n\t\t\tmessage: `File \"${file.name}\" exceeds the maximum size of ${formatBytes(maxSize)}.`,\n\t\t});\n\t}\n\n\tif (!isAcceptedFile(file, accept)) {\n\t\terrors.push({\n\t\t\tcode: \"file-invalid-type\",\n\t\t\tmessage: `File \"${file.name}\" is not an accepted file type.`,\n\t\t});\n\t}\n\n\treturn errors;\n}\n\nfunction isAcceptedFile(file: File, accept = \"*\") {\n\tif (accept === \"*\" || accept.trim() === \"\") return true;\n\n\tconst acceptedTypes = accept\n\t\t.split(\",\")\n\t\t.map((type) => type.trim().toLowerCase())\n\t\t.filter(Boolean);\n\n\tif (acceptedTypes.length === 0) return true;\n\n\tconst fileType = file.type.toLowerCase();\n\tconst fileExtension = getFileExtension(file.name);\n\n\treturn acceptedTypes.some((acceptedType) => {\n\t\tif (acceptedType.startsWith(\".\")) {\n\t\t\treturn fileExtension === acceptedType;\n\t\t}\n\n\t\tif (acceptedType.endsWith(\"/*\")) {\n\t\t\treturn fileType.startsWith(acceptedType.slice(0, -1));\n\t\t}\n\n\t\treturn fileType === acceptedType;\n\t});\n}\n\nfunction formatBytes(bytes: number, decimals = 2): string {\n\tif (bytes === 0) return \"0 Bytes\";\n\tif (!Number.isFinite(bytes)) return \"unlimited\";\n\n\tconst unit = 1024;\n\tconst precision = Math.max(0, decimals);\n\tconst sizes = [\"Bytes\", \"KB\", \"MB\", \"GB\", \"TB\", \"PB\"];\n\tconst sizeIndex = Math.min(\n\t\tMath.floor(Math.log(bytes) / Math.log(unit)),\n\t\tsizes.length - 1,\n\t);\n\n\treturn `${Number.parseFloat((bytes / unit ** sizeIndex).toFixed(precision))} ${sizes[sizeIndex]}`;\n}\n\nfunction getFileExtension(fileName: string) {\n\tconst extension = fileName.toLowerCase().split(\".\").pop();\n\treturn extension && extension !== fileName.toLowerCase()\n\t\t? `.${extension}`\n\t\t: \"\";\n}\n\nfunction assignRef<T>(ref: Ref<T> | undefined, value: T | null) {\n\tif (!ref) return;\n\n\tif (typeof ref === \"function\") {\n\t\tref(value);\n\t\treturn;\n\t}\n\n\tref.current = value;\n}\n\nexport { formatBytes, isAcceptedFile, useFilePicker, validateFile };\nexport type {\n\tFilePickerError,\n\tFilePickerErrorCode,\n\tFilePickerInputProps,\n\tFilePickerResult,\n\tFileRejection,\n\tUseFilePickerOptions,\n\tUseFilePickerReturn,\n};\n","import { cva, type VariantProps } from \"class-variance-authority\";\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\n\nfunction Empty({\n\tclassName,\n\tvariant = \"default\",\n\t...props\n}: React.ComponentProps<\"div\"> & {\n\tvariant?: \"filled\" | \"outline\" | \"default\";\n}) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"empty\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex w-full min-w-0 flex-1 flex-col items-center justify-center gap-gdt-xl rounded-2xl p-gdt-2xl text-center text-balance\",\n\t\t\t\tvariant === \"filled\" && \"bg-surface-raised border border-line-subtle\",\n\t\t\t\tvariant === \"outline\" && \"border border-line\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction EmptyHeader({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"empty-header\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex w-full max-w-95 flex-col items-center gap-gdt-sm\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst emptyMediaVariants = cva(\n\t\"mb-gdt-sm flex shrink-0 items-center justify-center text-fg-brand [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n\t{\n\t\tvariants: {\n\t\t\tvariant: {\n\t\t\t\tdefault: \"bg-transparent\",\n\t\t\t\ticon: \"size-24 rounded-full bg-surface-brand-subtle [&_svg:not([class*='size-'])]:size-10\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tvariant: \"default\",\n\t\t},\n\t},\n);\n\nfunction EmptyMedia({\n\tclassName,\n\tvariant = \"default\",\n\t...props\n}: React.ComponentProps<\"div\"> & VariantProps<typeof emptyMediaVariants>) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"empty-media\"\n\t\t\tdata-variant={variant}\n\t\t\tclassName={cn(emptyMediaVariants({ variant, className }))}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction EmptyTitle({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"empty-title\"\n\t\t\tclassName={cn(\n\t\t\t\t\"text-gdt-h4 font-extrabold tracking-tight text-fg-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction EmptyDescription({ className, ...props }: React.ComponentProps<\"p\">) {\n\treturn (\n\t\t<p\n\t\t\tdata-slot=\"empty-description\"\n\t\t\tclassName={cn(\n\t\t\t\t\"max-w-95 text-gdt-md font-normal text-fg-secondary [&>a]:font-semibold [&>a]:text-fg-brand [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-fg-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction EmptyContent({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"empty-content\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex w-full max-w-95 min-w-0 flex-col items-center justify-center gap-gdt-sm text-gdt-sm text-balance sm:flex-row [&_[data-slot=button]]:w-full sm:[&_[data-slot=button]]:w-auto\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tEmpty,\n\tEmptyHeader,\n\tEmptyTitle,\n\tEmptyDescription,\n\tEmptyContent,\n\tEmptyMedia,\n};\n","\"use client\";\n\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { useMemo } from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { Label } from \"./label\";\nimport { Separator } from \"./separator\";\nimport { SizeProvider, useComponentSize } from \"./size-context\";\n\nfunction FieldSet({ className, ...props }: React.ComponentProps<\"fieldset\">) {\n\treturn (\n\t\t<fieldset\n\t\t\tdata-slot=\"field-set\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex flex-col gap-4 has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction FieldLegend({\n\tclassName,\n\tvariant = \"legend\",\n\t...props\n}: React.ComponentProps<\"legend\"> & { variant?: \"legend\" | \"label\" }) {\n\treturn (\n\t\t<legend\n\t\t\tdata-slot=\"field-legend\"\n\t\t\tdata-variant={variant}\n\t\t\tclassName={cn(\n\t\t\t\t\"text-fg-primary data-[variant=label]:text-gdt-sm data-[variant=label]:font-semibold data-[variant=legend]:text-gdt-md data-[variant=legend]:font-medium\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction FieldGroup({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"field-group\"\n\t\t\tclassName={cn(\n\t\t\t\t\"group/field-group @container/field-group flex w-full flex-col gap-6 data-[slot=checkbox-group]:gap-3 *:data-[slot=field-group]:gap-4\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst fieldVariants = cva(\"group/field flex w-full\", {\n\tvariants: {\n\t\torientation: {\n\t\t\tvertical: \"flex-col *:w-full [&>.sr-only]:w-auto\",\n\t\t\thorizontal:\n\t\t\t\t\"flex-row items-center has-[>[data-slot=field-content]]:items-start *:data-[slot=field-label]:flex-auto has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio],[role=switch]]:mt-px data-[size=sm]:gap-1.5 data-[size=md]:gap-2.5 data-[size=lg]:gap-3\",\n\t\t\tresponsive:\n\t\t\t\t\"flex-col *:w-full @md/field-group:flex-row @md/field-group:items-center @md/field-group:*:w-auto @md/field-group:has-[>[data-slot=field-content]]:items-start @md/field-group:*:data-[slot=field-label]:flex-auto [&>.sr-only]:w-auto @md/field-group:has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio],[role=switch]]:mt-px\",\n\t\t},\n\t\tsize: {\n\t\t\tsm: \"gap-1\",\n\t\t\tmd: \"gap-1.5\",\n\t\t\tlg: \"gap-2\",\n\t\t},\n\t},\n\tdefaultVariants: {\n\t\torientation: \"vertical\",\n\t\tsize: \"md\",\n\t},\n});\n\nfunction Field({\n\tclassName,\n\torientation = \"vertical\",\n\tsize,\n\t...props\n}: React.ComponentProps<\"div\"> & VariantProps<typeof fieldVariants>) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn (\n\t\t<SizeProvider size={resolvedSize}>\n\t\t\t{/* biome-ignore lint/a11y/useSemanticElements: this wrapper is reused for non-fieldset control layouts and needs div semantics. */}\n\t\t\t<div\n\t\t\t\trole=\"group\"\n\t\t\t\tdata-slot=\"field\"\n\t\t\t\tdata-orientation={orientation}\n\t\t\t\tdata-size={resolvedSize}\n\t\t\t\tclassName={cn(\n\t\t\t\t\tfieldVariants({ orientation, size: resolvedSize }),\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t</SizeProvider>\n\t);\n}\n\nfunction FieldContent({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"field-content\"\n\t\t\tclassName={cn(\n\t\t\t\t\"group/field-content flex flex-1 flex-col leading-snug group-data-[size=sm]/field:gap-0.5 group-data-[size=md]/field:gap-0.5 group-data-[size=lg]/field:gap-1\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction FieldLabel({\n\tclassName,\n\t...props\n}: React.ComponentProps<typeof Label>) {\n\treturn (\n\t\t<Label\n\t\t\tdata-slot=\"field-label\"\n\t\t\tclassName={cn(\n\t\t\t\t\"group/field-label peer/field-label flex w-fit gap-1 leading-snug font-semibold text-fg-primary group-data-[size=sm]/field:text-gdt-xs group-data-[size=md]/field:text-gdt-sm group-data-[size=lg]/field:text-gdt-md group-data-[disabled=true]/field:opacity-50 has-data-checked:border-primary/30 has-data-checked:bg-primary/5 has-[>[data-slot=field]]:rounded-lg has-[>[data-slot=field]]:border *:data-[slot=field]:p-2.5 dark:has-data-checked:border-primary/20 dark:has-data-checked:bg-primary/10\",\n\t\t\t\t\"has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col has-[>[data-slot=field]]:gap-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction FieldTitle({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"field-label\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex w-fit items-center gap-2 font-semibold text-fg-primary group-data-[size=sm]/field:text-gdt-xs group-data-[size=md]/field:text-gdt-sm group-data-[size=lg]/field:text-gdt-md group-data-[disabled=true]/field:opacity-50\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction FieldDescription({ className, ...props }: React.ComponentProps<\"p\">) {\n\treturn (\n\t\t<p\n\t\t\tdata-slot=\"field-description\"\n\t\t\tclassName={cn(\n\t\t\t\t\"text-left font-normal text-fg-secondary group-data-[size=sm]/field:text-gdt-subtext group-data-[size=md]/field:text-gdt-xs group-data-[size=lg]/field:text-gdt-sm group-has-data-horizontal/field:text-balance [[data-variant=legend]+&]:-mt-1.5\",\n\t\t\t\t\"last:mt-0 nth-last-2:-mt-1\",\n\t\t\t\t\"[&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction FieldSeparator({\n\tchildren,\n\tclassName,\n\t...props\n}: React.ComponentProps<\"div\"> & {\n\tchildren?: React.ReactNode;\n}) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"field-separator\"\n\t\t\tdata-content={!!children}\n\t\t\tclassName={cn(\n\t\t\t\t\"relative -my-2 h-5 text-sm group-data-[variant=outline]/field-group:-mb-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<Separator className=\"absolute inset-0 top-1/2\" />\n\t\t\t{children && (\n\t\t\t\t<span\n\t\t\t\t\tclassName=\"relative mx-auto block w-fit bg-background px-2 text-muted-foreground\"\n\t\t\t\t\tdata-slot=\"field-separator-content\"\n\t\t\t\t>\n\t\t\t\t\t{children}\n\t\t\t\t</span>\n\t\t\t)}\n\t\t</div>\n\t);\n}\n\nfunction FieldError({\n\tclassName,\n\tchildren,\n\terrors,\n\t...props\n}: React.ComponentProps<\"div\"> & {\n\terrors?: Array<{ message?: string } | undefined>;\n}) {\n\tconst content = useMemo(() => {\n\t\tif (children) {\n\t\t\treturn children;\n\t\t}\n\n\t\tif (!errors?.length) {\n\t\t\treturn null;\n\t\t}\n\n\t\tconst uniqueErrors = [\n\t\t\t...new Map(errors.map((error) => [error?.message, error])).values(),\n\t\t];\n\n\t\tif (uniqueErrors?.length === 1) {\n\t\t\treturn uniqueErrors[0]?.message;\n\t\t}\n\n\t\treturn (\n\t\t\t<ul className=\"ml-4 flex list-disc flex-col gap-1\">\n\t\t\t\t{uniqueErrors.map(\n\t\t\t\t\t(error) =>\n\t\t\t\t\t\terror?.message && <li key={error.message}>{error.message}</li>,\n\t\t\t\t)}\n\t\t\t</ul>\n\t\t);\n\t}, [children, errors]);\n\n\tif (!content) {\n\t\treturn null;\n\t}\n\n\treturn (\n\t\t<div\n\t\t\trole=\"alert\"\n\t\t\tdata-slot=\"field-error\"\n\t\t\tclassName={cn(\"text-gdt-xs font-normal text-fg-danger\", className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{content}\n\t\t</div>\n\t);\n}\n\nexport {\n\tField,\n\tFieldLabel,\n\tFieldDescription,\n\tFieldError,\n\tFieldGroup,\n\tFieldLegend,\n\tFieldSeparator,\n\tFieldSet,\n\tFieldContent,\n\tFieldTitle,\n};\n","\"use client\";\n\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\n\nfunction Label({\n\tclassName,\n\tchildren,\n\twithAsterisk = false,\n\tshowOptionalText = false,\n\t...props\n}: React.ComponentProps<\"label\"> & {\n\twithAsterisk?: boolean;\n\tshowOptionalText?: boolean;\n}) {\n\tconst labelClassName = cn(\n\t\t\"flex w-fit max-w-full items-center gap-1 text-gdt-sm leading-none font-semibold text-fg-primary select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50\",\n\t\tclassName,\n\t);\n\n\tif (withAsterisk) {\n\t\treturn (\n\t\t\t// biome-ignore lint/a11y/noLabelWithoutControl: association is supplied by callers through htmlFor or nesting patterns.\n\t\t\t<label data-slot=\"label\" className={labelClassName} {...props}>\n\t\t\t\t<div className=\"inline-flex\">{children}</div>\n\t\t\t\t{withAsterisk && (\n\t\t\t\t\t<span className=\"inline-flex shrink-0 text-fg-danger\">*</span>\n\t\t\t\t)}\n\t\t\t\t{showOptionalText && (\n\t\t\t\t\t<span className=\"text-gdt-xs font-normal italic\">(optional)</span>\n\t\t\t\t)}\n\t\t\t</label>\n\t\t);\n\t}\n\n\treturn (\n\t\t// biome-ignore lint/a11y/noLabelWithoutControl: association is supplied by callers through htmlFor or nesting patterns.\n\t\t<label data-slot=\"label\" className={labelClassName} {...props}>\n\t\t\t<div>\n\t\t\t\t{children}{\" \"}\n\t\t\t\t{showOptionalText && (\n\t\t\t\t\t<span className=\"text-gdt-xs font-normal italic\">(optional)</span>\n\t\t\t\t)}\n\t\t\t</div>\n\t\t</label>\n\t);\n}\n\nexport { Label };\n","\"use client\";\n\nimport { cva } from \"class-variance-authority\";\nimport type * as React from \"react\";\nimport {\n\tBar,\n\tBarChart,\n\tFunnel,\n\tFunnelChart as RechartsFunnelChart,\n\tXAxis,\n\tYAxis,\n} from \"recharts\";\nimport { cn } from \"../../lib/cn\";\nimport {\n\tChartCard,\n\ttype ChartConfig,\n\tChartContainer,\n\tChartDescription,\n\tChartHeader,\n\tChartTitle,\n\tChartTooltip,\n\tChartTooltipContent,\n\ttype ChartValueType,\n} from \"./chart\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\n/**\n * A staged conversion chart for drop-off analytics. Two renderings share one\n * component — `funnel` draws connected, edge-sharing trapezoids (recharts\n * `FunnelChart`) that narrow top-down; `bars` draws flush, left-aligned tracks\n * (recharts `BarChart`, vertical layout) over a faint 100 % reference, using\n * recharts' built-in `Bar` `background`. Both read top-down as the audience\n * drops off, and both reuse the same stage data, palette, value-label column,\n * legend, frame, and tooltip — only the inner plot differs (the same split as\n * `Sparkline`). Per the chart architecture the recharts primitives are rendered\n * directly here, never wrapped.\n *\n * @example\n * <FunnelChart\n * data={[\n * { label: \"Applied\", value: 1000 },\n * { label: \"Pre-qualified\", value: 720 },\n * { label: \"Closed\", value: 110 },\n * ]}\n * title=\"Application drop-off\"\n * description=\"V3 analytics · last 30 days\"\n * tooltip\n * />\n */\n\n/** Funnel sizes line up with the three shared `ComponentSize` values. */\ntype FunnelChartSize = ComponentSize;\n\n/** Plot rendering — connected trapezoids or flush-stacked bars. */\ntype FunnelChartType = \"funnel\" | \"bars\";\n\n/** Where the colour-key legend sits relative to the plot. */\ntype FunnelLegendPlacement = \"right\" | \"bottom\";\n\ntype FunnelStage = {\n\t/** Stage name, e.g. \"Applied\". */\n\tlabel: string;\n\t/** Absolute count reaching this stage. */\n\tvalue: number;\n\t/** Segment colour; defaults to the palette in stage order. */\n\tfill?: string;\n};\n\n/**\n * Stage palette, ordered top-of-funnel → bottom: forest → brass → moss → clay →\n * stone. Giddaa has no `chart-1`…`chart-N` tokens yet, so these map to the brand\n * scales; assign by order, or override per stage with `fill`.\n */\nconst FUNNEL_CHART_PALETTE = [\n\t\"var(--color-forest-700)\",\n\t\"var(--color-brass-500)\",\n\t\"var(--color-moss-600)\",\n\t\"var(--color-clay-500)\",\n\t\"var(--color-stone-500)\",\n] as const;\n\ntype FunnelChartLayout = {\n\t/** Plot box height in px. */\n\theight: number;\n\t/** Plot box width in px — the funnel/bars column; labels + legend flow after. */\n\twidth: number;\n\t/** Corner radius for the `bars` rendering. */\n\tbarRadius: number;\n\t/** Bar thickness cap for the `bars` rendering. */\n\tbarMaxSize: number;\n};\n\nconst FUNNEL_CHART_LAYOUT: Record<FunnelChartSize, FunnelChartLayout> = {\n\tsm: { height: 150, width: 150, barRadius: 3, barMaxSize: 14 },\n\tmd: { height: 200, width: 220, barRadius: 4, barMaxSize: 18 },\n\tlg: { height: 264, width: 288, barRadius: 5, barMaxSize: 22 },\n};\n\n/** Vertical stage list — value-label column and the right-hand legend share it. */\nconst funnelStageListVariants = cva(\"flex min-w-0 flex-col\", {\n\tvariants: {\n\t\tsize: {\n\t\t\tsm: \"gap-2 text-gdt-xs\",\n\t\t\tmd: \"gap-3 text-gdt-sm\",\n\t\t\tlg: \"gap-3.5 text-gdt-sm\",\n\t\t},\n\t},\n\tdefaultVariants: { size: \"md\" },\n});\n\nconst funnelLegendDotVariants = cva(\"shrink-0 rounded-full\", {\n\tvariants: {\n\t\tsize: { sm: \"size-2\", md: \"size-2.5\", lg: \"size-3\" },\n\t},\n\tdefaultVariants: { size: \"md\" },\n});\n\ntype FunnelChartProps = Omit<\n\tReact.ComponentProps<typeof ChartCard>,\n\t\"size\" | \"children\"\n> & {\n\t/** Stages in funnel order — the widest (top) stage first. */\n\tdata: FunnelStage[];\n\t/** Plot rendering. Defaults to `funnel`. */\n\ttype?: FunnelChartType;\n\t/** Explicit size; otherwise inherited from the nearest `SizeProvider`. */\n\tsize?: FunnelChartSize;\n\t/** Chart heading. Omit to hide the title. */\n\ttitle?: React.ReactNode;\n\t/** Supporting metadata (period, source). Omit to hide the description. */\n\tdescription?: React.ReactNode;\n\t/** Enable the hover value tooltip. Default false. */\n\ttooltip?: boolean;\n\t/** Legend placement — a right column or a wrapped bottom row. Default right. */\n\tlegend?: FunnelLegendPlacement;\n\t/** Format the absolute count in the value label and tooltip. */\n\tvalueFormatter?: (value: number) => string;\n\t/** Value formatting for the tooltip. Defaults to `number`. */\n\tvalueType?: ChartValueType;\n};\n\nfunction FunnelChart({\n\tdata,\n\ttype = \"funnel\",\n\tsize,\n\ttitle,\n\tdescription,\n\ttooltip = false,\n\tlegend = \"right\",\n\tvalueFormatter = (value) => value.toLocaleString(\"en-NG\"),\n\tvalueType = \"number\",\n\tclassName,\n\t...props\n}: FunnelChartProps) {\n\tconst resolvedSize = useComponentSize(size);\n\tconst layout = FUNNEL_CHART_LAYOUT[resolvedSize];\n\n\tconst stages = data.map((stage, i) => ({\n\t\t...stage,\n\t\tfill: stage.fill ?? FUNNEL_CHART_PALETTE[i % FUNNEL_CHART_PALETTE.length],\n\t}));\n\t// Top stage is the funnel's 100 % reference — every share is relative to it.\n\tconst top = stages[0]?.value || 1;\n\n\tconst config = Object.fromEntries(\n\t\tstages.map((stage) => [\n\t\t\tstage.label,\n\t\t\t{ label: stage.label, color: stage.fill },\n\t\t]),\n\t) satisfies ChartConfig;\n\n\tconst tooltipNode = tooltip ? (\n\t\t<ChartTooltip\n\t\t\tcursor={false}\n\t\t\tcontent={<ChartTooltipContent nameKey=\"label\" valueType={valueType} />}\n\t\t/>\n\t) : null;\n\n\t// Per-segment colour comes from each datum's `fill` — recharts reads it\n\t// directly, so no (deprecated) `<Cell>` children are needed.\n\tconst chartNode =\n\t\ttype === \"bars\" ? (\n\t\t\t<BarChart\n\t\t\t\taccessibilityLayer\n\t\t\t\tlayout=\"vertical\"\n\t\t\t\tdata={stages}\n\t\t\t\tmargin={{ top: 0, right: 0, bottom: 0, left: 0 }}\n\t\t\t\tbarCategoryGap=\"0%\"\n\t\t\t>\n\t\t\t\t{tooltipNode}\n\t\t\t\t<XAxis type=\"number\" domain={[0, top]} hide />\n\t\t\t\t<YAxis type=\"category\" dataKey=\"label\" hide />\n\t\t\t\t<Bar\n\t\t\t\t\tdataKey=\"value\"\n\t\t\t\t\tradius={layout.barRadius}\n\t\t\t\t\tcolor=\"var(--color-line-subtle)\"\n\t\t\t\t\tisAnimationActive={false}\n\t\t\t\t/>\n\t\t\t</BarChart>\n\t\t) : (\n\t\t\t<RechartsFunnelChart margin={{ top: 0, right: 0, bottom: 0, left: 0 }}>\n\t\t\t\t{tooltipNode}\n\t\t\t\t<Funnel\n\t\t\t\t\tdata={stages}\n\t\t\t\t\tdataKey=\"value\"\n\t\t\t\t\tnameKey=\"label\"\n\t\t\t\t\tisAnimationActive={false}\n\t\t\t\t/>\n\t\t\t</RechartsFunnelChart>\n\t\t);\n\n\tconst valueLabels = (\n\t\t<ul className={cn(funnelStageListVariants({ size: resolvedSize }))}>\n\t\t\t{stages.map((stage) => (\n\t\t\t\t<li\n\t\t\t\t\tkey={stage.label}\n\t\t\t\t\tclassName=\"whitespace-nowrap tabular-nums text-fg-primary\"\n\t\t\t\t>\n\t\t\t\t\t{valueFormatter(stage.value)} ·{\" \"}\n\t\t\t\t\t{Math.round((stage.value / top) * 100)}%\n\t\t\t\t</li>\n\t\t\t))}\n\t\t</ul>\n\t);\n\n\tconst legendNode = (\n\t\t<ul\n\t\t\tclassName={cn(\n\t\t\t\tlegend === \"right\"\n\t\t\t\t\t? funnelStageListVariants({ size: resolvedSize })\n\t\t\t\t\t: cn(\n\t\t\t\t\t\t\t\"flex flex-row flex-wrap items-center gap-x-4 gap-y-2\",\n\t\t\t\t\t\t\tresolvedSize === \"sm\" ? \"text-gdt-xs\" : \"text-gdt-sm\",\n\t\t\t\t\t\t),\n\t\t\t)}\n\t\t>\n\t\t\t{stages.map((stage) => (\n\t\t\t\t<li\n\t\t\t\t\tkey={stage.label}\n\t\t\t\t\tclassName=\"flex items-center gap-2 text-fg-primary\"\n\t\t\t\t>\n\t\t\t\t\t<span\n\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\tclassName={cn(funnelLegendDotVariants({ size: resolvedSize }))}\n\t\t\t\t\t\tstyle={{ backgroundColor: stage.fill }}\n\t\t\t\t\t/>\n\t\t\t\t\t<span className=\"min-w-0 truncate\">{stage.label}</span>\n\t\t\t\t</li>\n\t\t\t))}\n\t\t</ul>\n\t);\n\n\treturn (\n\t\t<ChartCard size={resolvedSize} className={className} {...props}>\n\t\t\t{(title != null || description != null) && (\n\t\t\t\t<ChartHeader>\n\t\t\t\t\t{title != null && <ChartTitle>{title}</ChartTitle>}\n\t\t\t\t\t{description != null && (\n\t\t\t\t\t\t<ChartDescription>{description}</ChartDescription>\n\t\t\t\t\t)}\n\t\t\t\t</ChartHeader>\n\t\t\t)}\n\t\t\t<div className=\"flex flex-col gap-4\">\n\t\t\t\t<div className=\"flex flex-wrap items-center gap-x-6 gap-y-4\">\n\t\t\t\t\t<ChartContainer\n\t\t\t\t\t\tconfig={config}\n\t\t\t\t\t\tclassName=\"aspect-auto shrink-0\"\n\t\t\t\t\t\tstyle={{ width: layout.width, height: layout.height }}\n\t\t\t\t\t>\n\t\t\t\t\t\t{chartNode}\n\t\t\t\t\t</ChartContainer>\n\t\t\t\t\t{valueLabels}\n\t\t\t\t\t{legend === \"right\" && legendNode}\n\t\t\t\t</div>\n\t\t\t\t{legend === \"bottom\" && legendNode}\n\t\t\t</div>\n\t\t</ChartCard>\n\t);\n}\n\nexport { FUNNEL_CHART_LAYOUT, FUNNEL_CHART_PALETTE, FunnelChart };\nexport type {\n\tFunnelChartLayout,\n\tFunnelChartProps,\n\tFunnelChartSize,\n\tFunnelChartType,\n\tFunnelLegendPlacement,\n\tFunnelStage,\n};\n","import { mergeProps, useRender } from \"@base-ui/react\";\nimport { cn } from \"../../lib/cn\";\n\nfunction Item({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"div\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"div\",\n\t\tprops: mergeProps<\"div\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\"flex flex-col gap-1\", className),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction ItemLabel({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"div\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"div\",\n\t\tprops: mergeProps<\"div\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\"text-gdt-sm text-fg-secondary\", className),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction ItemValue({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"div\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"div\",\n\t\tprops: mergeProps<\"div\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"text-gdt-sm font-semibold text-fg-primary [a]:text-fg-brand [&_a]:text-fg-brand\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nexport { Item, ItemLabel, ItemValue };\n","import { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { ArrowDown, ArrowUp, ArrowUpRight } from \"lucide-react\";\nimport { cn } from \"../../lib/cn\";\nimport { Skeleton } from \"./skeleton\";\n\nfunction KpiCard({\n\tclassName,\n\tloading = false,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"article\"> & { loading?: boolean }) {\n\treturn useRender({\n\t\tdefaultTagName: \"article\",\n\t\tprops: mergeProps<\"article\">(\n\t\t\t{\n\t\t\t\t\"aria-busy\": loading || undefined,\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"group/kpi-card relative flex w-full min-w-0 flex-col gap-4 rounded-xl p-5 text-fg-primary transition-[background-color,border-color,box-shadow,transform] outline-none border border-line-subtle shadow-1\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tslot: \"kpi-card\",\n\t\t\tloading,\n\t\t},\n\t});\n}\n\nfunction KpiCardTitle({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"h3\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"h3\",\n\t\tprops: mergeProps<\"h3\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"min-w-0 pr-gdt-xl text-gdt-sm font-semibold capitalized text-fg-secondary\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction KpiCardLinkOutIcon({\n\tchildren,\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"span\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"span\",\n\t\tprops: mergeProps<\"span\">(\n\t\t\t{\n\t\t\t\t\"aria-hidden\": true,\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"pointer-events-none absolute right-gdt-md top-gdt-md inline-flex size-4 shrink-0 items-center justify-center text-fg-secondary [&>svg]:size-4 [&>svg]:shrink-0\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t\tchildren: children ?? <ArrowUpRight aria-hidden=\"true\" />,\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction KpiCardValue({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"p\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"p\",\n\t\tprops: mergeProps<\"p\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"text-gdt-h3 font-extrabold text-fg-primary group-aria-busy/kpi-card:hidden\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction KpiCardValueSkeleton({\n\tclassName,\n\t...props\n}: React.ComponentProps<typeof Skeleton>) {\n\treturn (\n\t\t<Skeleton\n\t\t\tclassName={cn(\n\t\t\t\t\"hidden h-8 mt-2 md:mt-3 w-24 rounded-md group-aria-busy/kpi-card:block\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst kpiCardTrendVariants = cva(\n\t\"flex min-w-0 items-center gap-1.5 text-gdt-capitalized\",\n\t{\n\t\tvariants: {\n\t\t\tdirection: {\n\t\t\t\tup: \"text-status-success\",\n\t\t\t\tdown: \"text-status-danger\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tdirection: \"up\",\n\t\t},\n\t},\n);\n\ntype KpiCardTrendProps = useRender.ComponentProps<\"p\"> &\n\tVariantProps<typeof kpiCardTrendVariants> & {\n\t\tshowIcon?: boolean;\n\t};\n\nfunction KpiCardTrend({\n\tchildren,\n\tclassName,\n\tdirection = \"up\",\n\trender,\n\tshowIcon = true,\n\t...props\n}: KpiCardTrendProps) {\n\tconst Icon = direction === \"down\" ? ArrowDown : ArrowUp;\n\n\treturn useRender({\n\t\tdefaultTagName: \"p\",\n\t\tprops: mergeProps<\"p\">(\n\t\t\t{\n\t\t\t\tclassName: cn(kpiCardTrendVariants({ direction }), className),\n\t\t\t\tchildren: (\n\t\t\t\t\t<>\n\t\t\t\t\t\t{showIcon ? (\n\t\t\t\t\t\t\t<Icon aria-hidden=\"true\" className=\"size-3 shrink-0\" />\n\t\t\t\t\t\t) : null}\n\t\t\t\t\t\t{children}\n\t\t\t\t\t</>\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tdirection,\n\t\t\tshowIcon,\n\t\t\tslot: \"kpi-card-trend\",\n\t\t},\n\t});\n}\n\nfunction KpiCardTrendValue({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"span\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"span\",\n\t\tprops: mergeProps<\"span\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\"text-gdt-sm text-current font-semibold\", className),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\nfunction KpiCardTrendCaption({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"span\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"span\",\n\t\tprops: mergeProps<\"span\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"min-w-0 truncate text-gdt-xs text-fg-secondary font-normal\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t});\n}\n\n/**\n * Composition examples:\n *\n * <KpiCard>\n * <KpiCardTitle>Total Revenue</KpiCardTitle>\n * <KpiCardValue>$1.25M</KpiCardValue>\n * <KpiCardTrend>\n * <KpiCardTrendValue>+12.5%</KpiCardTrendValue>\n * <KpiCardTrendCaption>vs last month</KpiCardTrendCaption>\n * </KpiCardTrend>\n * </KpiCard>\n *\n * <KpiCard interactive render={<a href=\"/reports\" aria-label=\"View revenue report\" />}>\n * <KpiCardLinkOutIcon />\n * <KpiCardTitle>Total Revenue</KpiCardTitle>\n * <KpiCardValue>$1.25M</KpiCardValue>\n * </KpiCard>\n *\n * <KpiCard loading>\n * <KpiCardTitle>Total Revenue</KpiCardTitle>\n * <KpiCardValue>$1.25M</KpiCardValue>\n * <KpiCardValueSkeleton />\n * </KpiCard>\n */\nexport {\n\tKpiCard,\n\tKpiCardLinkOutIcon,\n\tKpiCardTitle,\n\tKpiCardTrend,\n\tKpiCardTrendCaption,\n\tKpiCardTrendValue,\n\tKpiCardValue,\n\tKpiCardValueSkeleton,\n\tkpiCardTrendVariants,\n};\n","import { cn } from \"../../lib/cn\";\n\nfunction Skeleton({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"skeleton\"\n\t\t\tclassName={cn(\"animate-pulse rounded-md bg-line\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Skeleton };\n","\"use client\";\n\nimport { cartesianAxisProps } from \"./chart\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\n/**\n * Line charts are composed from recharts plot primitives directly — recharts\n * identifies `Line`, `Area`, `XAxis`, `YAxis`, and `CartesianGrid` by component\n * identity and cannot be wrapped. This module supplies giddaa-specific defaults\n * that would otherwise be copy-pasted into every line chart: per-size layout\n * numbers. Pair them with the shared frame and overlays from `./chart`.\n *\n * Five sizes (sm → huge) extend the three `ComponentSize` values used elsewhere.\n * xl and huge must be passed explicitly — they cannot be inherited from\n * `SizeProvider` since `ComponentSize` only carries sm/md/lg.\n *\n * Tokens:\n * - Primary series stroke + dots + area fill: `var(--color-surface-brand)`\n * - Comparison series: `var(--color-surface-accent)`\n * - Gridlines: `var(--color-line-subtle)`\n * - Area wash: primary series colour at 15 % opacity (`fillOpacity={0.15}`)\n * - Active-dot ring: `var(--color-surface-raised)` stroke (matches card bg)\n *\n * @example\n * const chart = useLineChartLayout();\n * <ChartCard size=\"md\">\n * <ChartHeader>\n * <ChartTitle>Revenue Overview</ChartTitle>\n * <ChartDescription>Monthly revenue · Jan–Jul</ChartDescription>\n * </ChartHeader>\n * <ChartContainer config={config} {...chart.container}>\n * <AreaChart data={data} {...chart.chart}>\n * <CartesianGrid vertical={false} stroke=\"var(--color-line-subtle)\" />\n * <XAxis dataKey=\"month\" {...chart.xAxis} />\n * <YAxis {...chart.yAxis} />\n * <ChartLegend verticalAlign=\"top\" content={<ChartLegendContent marker=\"line\" />} />\n * <ChartTooltip content={<ChartTooltipContent />} />\n * <Area dataKey=\"revenue\" {...chart.area(\"var(--color-revenue)\")} />\n * </AreaChart>\n * </ChartContainer>\n * </ChartCard>\n */\n\n/** Five sizes for line charts — extends ComponentSize with xl and huge. */\ntype LineChartSize = \"sm\" | \"md\" | \"lg\" | \"xl\" | \"huge\";\n\ntype LineChartLayout = {\n\t/** Plot height in px. Width stays fluid via ResponsiveContainer. */\n\theight: number;\n\t/** Outer margin. Top leaves room above the highest data point. */\n\tmargin: { top: number; right: number; bottom: number; left: number };\n\t/** Line stroke width in px. */\n\tstrokeWidth: number;\n\t/** Radius of the resting data-point dot. */\n\tdotRadius: number;\n\t/** Radius of the active (hover) dot. */\n\tactiveDotRadius: number;\n\t/** Axis tick label font size. */\n\ttickFontSize: number;\n\t/** Reserved width for the value (Y) axis. */\n\tyAxisWidth: number;\n\t/** Space between an axis and its tick labels. */\n\ttickMargin: number;\n};\n\nconst LINE_CHART_LAYOUT: Record<LineChartSize, LineChartLayout> = {\n\tsm: {\n\t\theight: 64,\n\t\tmargin: { top: 6, right: 6, bottom: 0, left: 0 },\n\t\tstrokeWidth: 2,\n\t\tdotRadius: 2.5,\n\t\tactiveDotRadius: 4,\n\t\ttickFontSize: 9,\n\t\tyAxisWidth: 22,\n\t\ttickMargin: 3,\n\t},\n\tmd: {\n\t\theight: 88,\n\t\tmargin: { top: 8, right: 8, bottom: 0, left: 0 },\n\t\tstrokeWidth: 2,\n\t\tdotRadius: 3,\n\t\tactiveDotRadius: 4.5,\n\t\ttickFontSize: 10,\n\t\tyAxisWidth: 24,\n\t\ttickMargin: 4,\n\t},\n\tlg: {\n\t\theight: 108,\n\t\tmargin: { top: 10, right: 10, bottom: 0, left: 0 },\n\t\tstrokeWidth: 2,\n\t\tdotRadius: 3.5,\n\t\tactiveDotRadius: 5,\n\t\ttickFontSize: 11,\n\t\tyAxisWidth: 26,\n\t\ttickMargin: 5,\n\t},\n\txl: {\n\t\theight: 132,\n\t\tmargin: { top: 12, right: 12, bottom: 0, left: 0 },\n\t\tstrokeWidth: 2,\n\t\tdotRadius: 4,\n\t\tactiveDotRadius: 5.5,\n\t\ttickFontSize: 11,\n\t\tyAxisWidth: 28,\n\t\ttickMargin: 6,\n\t},\n\thuge: {\n\t\theight: 164,\n\t\tmargin: { top: 14, right: 14, bottom: 0, left: 0 },\n\t\tstrokeWidth: 2,\n\t\tdotRadius: 4.5,\n\t\tactiveDotRadius: 6,\n\t\ttickFontSize: 12,\n\t\tyAxisWidth: 30,\n\t\ttickMargin: 7,\n\t},\n};\n\n/** Map the 5 line-chart sizes to the 3 ComponentSize values for ChartCard. */\nfunction toComponentSize(size: LineChartSize): ComponentSize {\n\tif (size === \"xl\" || size === \"huge\") return \"lg\";\n\treturn size as ComponentSize;\n}\n\n/**\n * Build the colour-bound props for a `<Line>`/`<Area>` series at a given size:\n * the rounded stroke geometry plus the resting and active dots, all painted in\n * `color`. `area` adds the 15 %-opacity wash beneath the stroke.\n */\nfunction seriesProps(layout: LineChartLayout, color: string) {\n\treturn {\n\t\ttype: \"linear\" as const,\n\t\tstroke: color,\n\t\tstrokeWidth: layout.strokeWidth,\n\t\tstrokeLinejoin: \"round\" as const,\n\t\tstrokeLinecap: \"round\" as const,\n\t\tdot: { r: layout.dotRadius, fill: color, strokeWidth: 0 },\n\t\tactiveDot: {\n\t\t\tr: layout.activeDotRadius,\n\t\t\tfill: color,\n\t\t\tstroke: \"var(--color-surface-raised)\",\n\t\t\tstrokeWidth: 2,\n\t\t},\n\t};\n}\n\n/**\n * Resolve the line-chart layout for an explicit or inherited component size. The\n * returned object groups the giddaa defaults by the recharts component they\n * belong to. `line(color)`/`area(color)` return the full series props for a\n * given colour — spread each onto its element, then pass the data-specific props\n * (`config`, `data`, `dataKey`, …) directly afterwards to add or override:\n *\n * const chart = useLineChartLayout(size);\n * <ChartContainer config={config} {...chart.container}>\n * <AreaChart data={data} {...chart.chart}>\n * <XAxis dataKey=\"month\" {...chart.xAxis} />\n * <YAxis {...chart.yAxis} />\n * <Area dataKey=\"revenue\" {...chart.area(\"var(--color-revenue)\")} />\n */\nfunction useLineChartLayout(size?: LineChartSize) {\n\tconst inheritedSize = useComponentSize() as LineChartSize;\n\tconst resolved: LineChartSize = size ?? inheritedSize;\n\tconst layout = LINE_CHART_LAYOUT[resolved] ?? LINE_CHART_LAYOUT.md;\n\tconst axes = cartesianAxisProps(layout);\n\n\treturn {\n\t\tcontainer: {\n\t\t\tclassName: \"aspect-auto w-full\",\n\t\t\tstyle: { height: layout.height },\n\t\t},\n\t\tchart: {\n\t\t\taccessibilityLayer: true,\n\t\t\tmargin: layout.margin,\n\t\t},\n\t\txAxis: axes.xAxis,\n\t\tyAxis: axes.yAxis,\n\t\tline: (color: string) => seriesProps(layout, color),\n\t\tarea: (color: string) => ({\n\t\t\t...seriesProps(layout, color),\n\t\t\tfill: color,\n\t\t\tfillOpacity: 0.15,\n\t\t}),\n\t};\n}\n\nexport { LINE_CHART_LAYOUT, toComponentSize, useLineChartLayout };\nexport type { LineChartLayout, LineChartSize };\n","import {\n\tNumberField,\n\ttype NumberFieldRootProps,\n} from \"@base-ui/react/number-field\";\nimport { MinusIcon, PlusIcon } from \"lucide-react\";\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport {\n\tInputGroup,\n\tInputGroupAddon,\n\tInputGroupButton,\n\tInputGroupInput,\n} from \"./input-group\";\nimport {\n\ttype ComponentSize,\n\tSizeProvider,\n\tuseComponentSize,\n} from \"./size-context\";\n\nconst numberInputFormatPresets = {\n\tcompact: {\n\t\tcompactDisplay: \"short\",\n\t\tnotation: \"compact\",\n\t},\n\tcurrencyNgn: {\n\t\tcurrency: \"NGN\",\n\t\tcurrencyDisplay: \"narrowSymbol\",\n\t\tstyle: \"currency\",\n\t},\n\tdecimal: {\n\t\tuseGrouping: true,\n\t},\n\tinteger: {\n\t\tmaximumFractionDigits: 0,\n\t\tuseGrouping: true,\n\t},\n\tpercent: {\n\t\tstyle: \"percent\",\n\t},\n\tplain: {\n\t\tuseGrouping: false,\n\t},\n} satisfies Record<string, Intl.NumberFormatOptions>;\n\ntype NumberInputFormatPreset = keyof typeof numberInputFormatPresets;\n\ntype NumberInputProps = Omit<NumberFieldRootProps, \"format\"> & {\n\tchildren?: React.ReactNode;\n\tformat?: Intl.NumberFormatOptions;\n\tformatPreset?: NumberInputFormatPreset;\n\tplaceholder?: string;\n\tsize?: ComponentSize;\n\tthousandSeparator?: boolean;\n};\n\nfunction NumberInput({\n\tchildren,\n\tformat,\n\tformatPreset,\n\tplaceholder,\n\tsize,\n\tthousandSeparator,\n\t...props\n}: NumberInputProps) {\n\tconst resolvedSize = useComponentSize(size);\n\tconst resolvedFormat =\n\t\tformat ??\n\t\t(formatPreset ? numberInputFormatPresets[formatPreset] : undefined) ??\n\t\t(thousandSeparator ? numberInputFormatPresets.decimal : undefined);\n\n\treturn (\n\t\t<SizeProvider size={resolvedSize}>\n\t\t\t<NumberField.Root format={resolvedFormat} {...props}>\n\t\t\t\t<NumberField.Group render={<InputGroup />}>\n\t\t\t\t\t<NumberField.Input\n\t\t\t\t\t\tplaceholder={placeholder}\n\t\t\t\t\t\trender={<InputGroupInput />}\n\t\t\t\t\t/>\n\t\t\t\t\t{children}\n\t\t\t\t</NumberField.Group>\n\t\t\t</NumberField.Root>\n\t\t</SizeProvider>\n\t);\n}\n\nfunction NumberInputControl() {\n\tconst size = useComponentSize();\n\treturn (\n\t\t<InputGroupAddon\n\t\t\talign=\"inline-end\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex gap-0 flex-col h-[calc(100%-2px)] w-10 overflow-hidden rounded-r-full p-0! pr-1.5!\",\n\t\t\t\tsize === \"lg\" && \"w-12\",\n\t\t\t)}\n\t\t>\n\t\t\t<NumberField.Increment\n\t\t\t\tclassName=\"w-full flex-1 rounded-none rounded-tr-full\"\n\t\t\t\trender={<InputGroupButton variant=\"tertiary\" />}\n\t\t\t>\n\t\t\t\t<PlusIcon\n\t\t\t\t\tclassName={cn(\"size-1.5\", {\n\t\t\t\t\t\t\"size-3\": size === \"md\",\n\t\t\t\t\t\t\"size-3.5\": size === \"lg\",\n\t\t\t\t\t})}\n\t\t\t\t/>\n\t\t\t</NumberField.Increment>\n\t\t\t<NumberField.Decrement\n\t\t\t\tclassName=\"w-full flex-1 rounded-none rounded-br-full\"\n\t\t\t\trender={<InputGroupButton variant=\"tertiary\" />}\n\t\t\t>\n\t\t\t\t<MinusIcon\n\t\t\t\t\tclassName={cn(\"size-1.5\", {\n\t\t\t\t\t\t\"size-3\": size === \"md\",\n\t\t\t\t\t\t\"size-3.5\": size === \"lg\",\n\t\t\t\t\t})}\n\t\t\t\t/>\n\t\t\t</NumberField.Decrement>\n\t\t</InputGroupAddon>\n\t);\n}\n\nexport {\n\tNumberInput,\n\tNumberInputControl,\n\tnumberInputFormatPresets,\n\ttype NumberInputFormatPreset,\n};\n","import { cn } from \"../../lib/cn\";\n\nfunction DashboardHeader({\n\tborder,\n\tclassName,\n\t...props\n}: React.ComponentProps<\"div\"> & {\n\tborder?: boolean;\n}) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"dashboard-header\"\n\t\t\tclassName={cn(\"flex flex-col gap-4\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DashboardHeaderGroup({\n\tclassName,\n\torientation = \"vertical\",\n\t...props\n}: React.ComponentProps<\"div\"> & { orientation?: \"horizontal\" | \"vertical\" }) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"dashboard-header-group\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex\",\n\t\t\t\torientation === \"horizontal\"\n\t\t\t\t\t? \"gap-4 md:gap-6 md:flex-row md:items-center\"\n\t\t\t\t\t: \"flex-col gap-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DashboardHeaderTitle({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"h1\">) {\n\treturn (\n\t\t<h1\n\t\t\tdata-slot=\"dashboard-header-title\"\n\t\t\tclassName={cn(\"text-gdt-h3\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DashboardHeaderDescription({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"p\">) {\n\treturn (\n\t\t<p\n\t\t\tdata-slot=\"dashboard-header-description\"\n\t\t\tclassName={cn(\"text-gdt-sm text-fg-secondary\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction DashboardHeaderActions({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"dashboard-header-actions\"\n\t\t\tclassName={cn(\"flex flex-wrap items-center gap-2 md:gap-3\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\n// function DashboardHeaderBreadcrumbs({}) {}\n\nexport {\n\tDashboardHeader,\n\tDashboardHeaderGroup,\n\tDashboardHeaderTitle,\n\tDashboardHeaderDescription,\n\tDashboardHeaderActions,\n};\n","import { cva } from \"class-variance-authority\";\nimport {\n\tChevronLeftIcon,\n\tChevronRightIcon,\n\tMoreHorizontalIcon,\n} from \"lucide-react\";\nimport type * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { Button, ButtonLink } from \"./button\";\n\nfunction Pagination({ className, ...props }: React.ComponentProps<\"nav\">) {\n\treturn (\n\t\t<nav\n\t\t\taria-label=\"pagination\"\n\t\t\tdata-slot=\"pagination\"\n\t\t\tclassName={cn(\"mx-auto flex w-full justify-center\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PaginationContent({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"ul\">) {\n\treturn (\n\t\t<ul\n\t\t\tdata-slot=\"pagination-content\"\n\t\t\tclassName={cn(\"flex flex-wrap items-center gap-2\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PaginationItem({ ...props }: React.ComponentProps<\"li\">) {\n\treturn <li data-slot=\"pagination-item\" {...props} />;\n}\n\nconst paginationTriggerVariants = cva(\n\t\"rounded-md font-medium shadow-none transition-[background-color,border-color,color] focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)]\",\n\t{\n\t\tvariants: {\n\t\t\tappearance: {\n\t\t\t\tpage: \"px-0\",\n\t\t\t\ticon: \"border border-line bg-transparent px-0 hover:border-line-strong\",\n\t\t\t\tcontrol: \"border border-line bg-transparent hover:border-line-strong\",\n\t\t\t},\n\t\t\tisActive: {\n\t\t\t\ttrue: \"\",\n\t\t\t\tfalse: \"\",\n\t\t\t},\n\t\t},\n\t\tcompoundVariants: [\n\t\t\t{\n\t\t\t\tappearance: \"page\",\n\t\t\t\tisActive: true,\n\t\t\t\tclassName:\n\t\t\t\t\t\"bg-action-primary text-fg-on-brand hover:bg-action-primary-hover active:bg-action-primary-pressed\",\n\t\t\t},\n\t\t\t{\n\t\t\t\tappearance: \"page\",\n\t\t\t\tisActive: false,\n\t\t\t\tclassName:\n\t\t\t\t\t\"bg-transparent text-fg-primary hover:bg-surface active:bg-surface-raised\",\n\t\t\t},\n\t\t\t{\n\t\t\t\tappearance: \"icon\",\n\t\t\t\tisActive: false,\n\t\t\t\tclassName: \"text-fg-primary hover:bg-surface active:bg-surface-raised\",\n\t\t\t},\n\t\t\t{\n\t\t\t\tappearance: \"control\",\n\t\t\t\tisActive: false,\n\t\t\t\tclassName: \"text-fg-primary hover:bg-surface active:bg-surface-raised\",\n\t\t\t},\n\t\t],\n\t\tdefaultVariants: {\n\t\t\tappearance: \"page\",\n\t\t\tisActive: false,\n\t\t},\n\t},\n);\n\ntype PaginationTriggerAppearance = \"page\" | \"icon\" | \"control\";\n\ntype PaginationLinkProps = {\n\tisActive?: boolean;\n\tappearance?: PaginationTriggerAppearance;\n\tpage: number;\n\tgetHref?: (page: number) => string;\n\thref?: string;\n} & Omit<React.ComponentProps<typeof ButtonLink>, \"href\" | \"size\" | \"variant\">;\n\nfunction PaginationLink({\n\tclassName,\n\tappearance = \"page\",\n\tgetHref,\n\thref,\n\tisActive,\n\tpage,\n\t...props\n}: PaginationLinkProps) {\n\tconst resolvedHref = href ?? getHref?.(page) ?? `?page=${page}`;\n\n\treturn (\n\t\t<ButtonLink\n\t\t\thref={resolvedHref}\n\t\t\tvariant={isActive && appearance === \"page\" ? \"primary\" : \"ghost\"}\n\t\t\tsize={appearance === \"control\" ? \"sm\" : \"icon-sm\"}\n\t\t\tclassName={cn(\n\t\t\t\tpaginationTriggerVariants({\n\t\t\t\t\tappearance,\n\t\t\t\t\tisActive: Boolean(isActive),\n\t\t\t\t}),\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\taria-current={isActive ? \"page\" : undefined}\n\t\t\tdata-slot=\"pagination-link\"\n\t\t\tdata-active={isActive}\n\t\t\tdata-appearance={appearance}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\ntype PaginationButtonProps = {\n\tisActive?: boolean;\n\tappearance?: PaginationTriggerAppearance;\n\tpage: number;\n} & Omit<React.ComponentProps<typeof Button>, \"size\" | \"type\" | \"variant\">;\n\nfunction PaginationButton({\n\tclassName,\n\tappearance = \"page\",\n\tisActive,\n\tpage,\n\t...props\n}: PaginationButtonProps) {\n\treturn (\n\t\t<Button\n\t\t\ttype=\"button\"\n\t\t\tvariant={isActive && appearance === \"page\" ? \"primary\" : \"ghost\"}\n\t\t\tsize={appearance === \"control\" ? \"sm\" : \"icon-sm\"}\n\t\t\tclassName={cn(\n\t\t\t\tpaginationTriggerVariants({\n\t\t\t\t\tappearance,\n\t\t\t\t\tisActive: Boolean(isActive),\n\t\t\t\t}),\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\taria-current={isActive ? \"page\" : undefined}\n\t\t\tdata-slot=\"pagination-button\"\n\t\t\tdata-active={isActive}\n\t\t\tdata-appearance={appearance}\n\t\t\tdata-page={page}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PaginationPrevious({\n\tclassName,\n\tshowLabel = true,\n\ttext = \"Previous\",\n\t...props\n}: React.ComponentProps<typeof PaginationLink> & {\n\tshowLabel?: boolean;\n\ttext?: string;\n}) {\n\treturn (\n\t\t<PaginationLink\n\t\t\taria-label=\"Go to previous page\"\n\t\t\tappearance={showLabel ? \"control\" : \"icon\"}\n\t\t\tclassName={cn(showLabel ? \"pl-1.5!\" : \"\", className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<ChevronLeftIcon data-icon=\"inline-start\" className=\"cn-rtl-flip\" />\n\t\t\t{showLabel ? <span className=\"hidden sm:block\">{text}</span> : null}\n\t\t</PaginationLink>\n\t);\n}\n\nfunction PaginationNext({\n\tclassName,\n\tshowLabel = true,\n\ttext = \"Next\",\n\t...props\n}: React.ComponentProps<typeof PaginationLink> & {\n\tshowLabel?: boolean;\n\ttext?: string;\n}) {\n\treturn (\n\t\t<PaginationLink\n\t\t\taria-label=\"Go to next page\"\n\t\t\tappearance={showLabel ? \"control\" : \"icon\"}\n\t\t\tclassName={cn(showLabel ? \"pr-1.5!\" : \"\", className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{showLabel ? <span className=\"hidden sm:block\">{text}</span> : null}\n\t\t\t<ChevronRightIcon data-icon=\"inline-end\" className=\"cn-rtl-flip\" />\n\t\t</PaginationLink>\n\t);\n}\n\nfunction PaginationEllipsis({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\taria-hidden\n\t\t\tdata-slot=\"pagination-ellipsis\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex size-8 items-center justify-center text-fg-secondary [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<MoreHorizontalIcon />\n\t\t\t<span className=\"sr-only\">More pages</span>\n\t\t</span>\n\t);\n}\n\nexport {\n\tPagination,\n\tPaginationContent,\n\tPaginationEllipsis,\n\tPaginationItem,\n\tPaginationButton,\n\tPaginationLink,\n\tPaginationNext,\n\tPaginationPrevious,\n};\n","import { Eye, EyeOff } from \"lucide-react\";\nimport * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport {\n\tInputGroup,\n\tInputGroupAddon,\n\tInputGroupButton,\n\tInputGroupInput,\n} from \"./input-group\";\n\nexport function PasswordInput({\n\tclassName,\n\tsize,\n\tdisabled,\n\treadOnly,\n\tautoComplete = \"current-password\",\n\t...props\n}: Omit<React.ComponentProps<typeof InputGroupInput>, \"type\">) {\n\tconst [showPassword, setShowPassword] = React.useState(false);\n\tconst inputType = showPassword ? \"text\" : \"password\";\n\n\treturn (\n\t\t<InputGroup size={size} className={cn(className)}>\n\t\t\t<InputGroupInput\n\t\t\t\ttype={inputType}\n\t\t\t\tautoComplete={autoComplete}\n\t\t\t\tdisabled={disabled}\n\t\t\t\treadOnly={readOnly}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t\t<InputGroupAddon align=\"inline-end\">\n\t\t\t\t<InputGroupButton\n\t\t\t\t\taria-label={showPassword ? \"Hide password\" : \"Show password\"}\n\t\t\t\t\taria-pressed={showPassword}\n\t\t\t\t\tdisabled={disabled || readOnly}\n\t\t\t\t\tsize=\"icon-xs\"\n\t\t\t\t\tonClick={() => setShowPassword((value) => !value)}\n\t\t\t\t\tonMouseDown={(event) => event.preventDefault()}\n\t\t\t\t>\n\t\t\t\t\t{showPassword ? (\n\t\t\t\t\t\t<EyeOff className=\"size-4\" />\n\t\t\t\t\t) : (\n\t\t\t\t\t\t<Eye className=\"size-4\" />\n\t\t\t\t\t)}\n\t\t\t\t</InputGroupButton>\n\t\t\t</InputGroupAddon>\n\t\t</InputGroup>\n\t);\n}\n","\"use client\";\n\nimport {\n\tAsYouType,\n\ttype CountryCode,\n\tgetCountries,\n\tgetCountryCallingCode,\n\tparsePhoneNumber,\n} from \"libphonenumber-js\";\nimport { CheckIcon, ChevronDownIcon, SearchIcon } from \"lucide-react\";\nimport * as React from \"react\";\nimport flags from \"react-phone-number-input/flags\";\n\nimport { cn } from \"../../lib/cn\";\nimport { InputGroup, InputGroupAddon, InputGroupInput } from \"./input-group\";\nimport { Popover, PopoverContent, PopoverTrigger } from \"./popover\";\nimport { Separator } from \"./separator\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\n// ─── Country data ─────────────────────────────────────────────────────────────\n\nconst regionNames =\n\ttypeof Intl !== \"undefined\" && \"DisplayNames\" in Intl\n\t\t? new Intl.DisplayNames([\"en\"], { type: \"region\" })\n\t\t: undefined;\n\ninterface CountryEntry {\n\tcode: CountryCode;\n\tname: string;\n\tcalling: string;\n}\n\nconst COUNTRIES: CountryEntry[] = getCountries()\n\t.map((code) => ({\n\t\tcode,\n\t\tname: regionNames?.of(code) ?? code,\n\t\tcalling: getCountryCallingCode(code),\n\t}))\n\t.sort((a, b) => a.name.localeCompare(b.name));\n\nfunction getNationalDigits(value: string): string {\n\treturn value.replace(/\\D/g, \"\");\n}\n\nfunction formatNational(digits: string, country: CountryCode): string {\n\tif (!digits) return \"\";\n\treturn new AsYouType(country).input(digits);\n}\n\nfunction toE164(digits: string, country: CountryCode): string | undefined {\n\tif (!digits) return undefined;\n\treturn `+${getCountryCallingCode(country)}${digits}`;\n}\n\nfunction parseValue(value: string | undefined): {\n\tcountry?: CountryCode;\n\tdigits: string;\n} {\n\tif (!value) return { digits: \"\" };\n\ttry {\n\t\tconst parsed = parsePhoneNumber(value);\n\t\tif (parsed?.nationalNumber) {\n\t\t\treturn { country: parsed.country, digits: parsed.nationalNumber };\n\t\t}\n\t} catch {\n\t\t// fall through to empty\n\t}\n\treturn { digits: \"\" };\n}\n\n// ─── Flag ─────────────────────────────────────────────────────────────────────\n\nconst flagSizeVariants: Record<ComponentSize, string> = {\n\tsm: \"h-3 w-[18px]\",\n\tmd: \"h-3.5 w-5\",\n\tlg: \"h-4 w-6\",\n};\n\nfunction CountryFlag({\n\tcountry,\n\tsize,\n\tclassName,\n}: {\n\tcountry: CountryCode;\n\tsize: ComponentSize;\n\tclassName?: string;\n}) {\n\tconst Flag = flags[country];\n\n\treturn (\n\t\t<span\n\t\t\tclassName={cn(\n\t\t\t\t\"inline-flex shrink-0 items-center justify-center overflow-hidden rounded-[3px] bg-surface-raised [&>svg]:h-full [&>svg]:w-full [&>svg]:object-cover\",\n\t\t\t\tflagSizeVariants[size],\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t>\n\t\t\t{Flag ? (\n\t\t\t\t<Flag title={country} />\n\t\t\t) : (\n\t\t\t\t<span className=\"text-gdt-xs text-fg-secondary\">{country}</span>\n\t\t\t)}\n\t\t</span>\n\t);\n}\n\n// ─── Country selector ─────────────────────────────────────────────────────────\n\nfunction CountrySelect({\n\tcountry,\n\tsize,\n\tdisabled,\n\tonSelect,\n}: {\n\tcountry: CountryCode;\n\tsize: ComponentSize;\n\tdisabled?: boolean;\n\tonSelect: (country: CountryCode) => void;\n}) {\n\tconst [open, setOpen] = React.useState(false);\n\tconst [query, setQuery] = React.useState(\"\");\n\tconst searchRef = React.useRef<HTMLInputElement>(null);\n\n\t// Move focus to the search field once the list has opened.\n\tReact.useEffect(() => {\n\t\tif (!open) return;\n\t\tconst frame = requestAnimationFrame(() => searchRef.current?.focus());\n\t\treturn () => cancelAnimationFrame(frame);\n\t}, [open]);\n\n\tconst filtered = React.useMemo(() => {\n\t\tconst q = query.trim().toLowerCase();\n\t\tif (!q) return COUNTRIES;\n\t\tconst normalized = q.replace(/^\\+/, \"\");\n\t\treturn COUNTRIES.filter(\n\t\t\t(entry) =>\n\t\t\t\tentry.name.toLowerCase().includes(q) ||\n\t\t\t\tentry.calling.includes(normalized) ||\n\t\t\t\tentry.code.toLowerCase().includes(q),\n\t\t);\n\t}, [query]);\n\n\tfunction handleOpenChange(next: boolean) {\n\t\tsetOpen(next);\n\t\tif (!next) setQuery(\"\");\n\t}\n\n\treturn (\n\t\t<Popover open={open} onOpenChange={handleOpenChange}>\n\t\t\t<PopoverTrigger\n\t\t\t\tdisabled={disabled}\n\t\t\t\tdata-slot=\"phone-country-trigger\"\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"flex shrink-0 items-center gap-1.5 rounded-full font-normal text-fg-primary outline-none transition-colors select-none\",\n\t\t\t\t\t\"focus-visible:text-fg-brand disabled:cursor-not-allowed disabled:text-fg-caption-placeholder\",\n\t\t\t\t\tsize === \"sm\" && \"text-gdt-xs\",\n\t\t\t\t\tsize === \"md\" && \"text-gdt-sm\",\n\t\t\t\t\tsize === \"lg\" && \"text-gdt-md\",\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t<CountryFlag country={country} size={size} />\n\t\t\t\t<span>+{getCountryCallingCode(country)}</span>\n\t\t\t\t<ChevronDownIcon\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"text-fg-secondary transition-transform\",\n\t\t\t\t\t\topen && \"rotate-180\",\n\t\t\t\t\t\tsize === \"lg\" ? \"size-4\" : \"size-3.5\",\n\t\t\t\t\t)}\n\t\t\t\t/>\n\t\t\t</PopoverTrigger>\n\t\t\t<PopoverContent\n\t\t\t\tshowArrow={false}\n\t\t\t\talign=\"start\"\n\t\t\t\talignOffset={0}\n\t\t\t\tsideOffset={10}\n\t\t\t\tclassName=\"w-72 gap-0 overflow-hidden p-0\"\n\t\t\t>\n\t\t\t\t<div className=\"flex items-center gap-2 border-b border-line-subtle px-3.5 py-2.5\">\n\t\t\t\t\t<SearchIcon className=\"size-4 shrink-0 text-fg-secondary\" />\n\t\t\t\t\t<input\n\t\t\t\t\t\tref={searchRef}\n\t\t\t\t\t\tvalue={query}\n\t\t\t\t\t\tonChange={(event) => setQuery(event.target.value)}\n\t\t\t\t\t\tplaceholder=\"Search country\"\n\t\t\t\t\t\tclassName=\"w-full bg-transparent text-gdt-sm text-fg-primary outline-none placeholder:text-fg-caption-placeholder\"\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\t\t\t\t<div className=\"no-scrollbar max-h-64 overflow-y-auto py-1.5\">\n\t\t\t\t\t{filtered.length === 0 ? (\n\t\t\t\t\t\t<p className=\"px-3.5 py-6 text-center text-gdt-sm text-fg-secondary\">\n\t\t\t\t\t\t\tNo country found\n\t\t\t\t\t\t</p>\n\t\t\t\t\t) : (\n\t\t\t\t\t\tfiltered.map((entry) => {\n\t\t\t\t\t\t\tconst selected = entry.code === country;\n\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\t\tkey={entry.code}\n\t\t\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\t\t\t\tonSelect(entry.code);\n\t\t\t\t\t\t\t\t\t\thandleOpenChange(false);\n\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\t\t\"flex w-full items-center gap-2.5 px-3.5 py-2 text-left text-gdt-sm outline-none transition-colors hover:bg-surface focus-visible:bg-surface\",\n\t\t\t\t\t\t\t\t\t\tselected ? \"font-medium text-fg-brand\" : \"text-fg-primary\",\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<CountryFlag country={entry.code} size=\"md\" />\n\t\t\t\t\t\t\t\t\t<span className=\"min-w-0 flex-1 truncate\">{entry.name}</span>\n\t\t\t\t\t\t\t\t\t<span className=\"shrink-0 text-fg-secondary\">\n\t\t\t\t\t\t\t\t\t\t+{entry.calling}\n\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t{selected && (\n\t\t\t\t\t\t\t\t\t\t<CheckIcon className=\"size-4 shrink-0 text-fg-brand\" />\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t})\n\t\t\t\t\t)}\n\t\t\t\t</div>\n\t\t\t</PopoverContent>\n\t\t</Popover>\n\t);\n}\n\n// ─── PhoneInput ───────────────────────────────────────────────────────────────\n\ninterface PhoneInputProps {\n\tvalue?: string;\n\tonChange?: (value: string | undefined) => void;\n\tdefaultCountry?: CountryCode;\n\tsize?: ComponentSize;\n\tdisabled?: boolean;\n\treadOnly?: boolean;\n\tplaceholder?: string;\n\tclassName?: string;\n\tid?: string;\n\tname?: string;\n\t\"aria-invalid\"?: boolean;\n}\n\nfunction PhoneInput({\n\tvalue,\n\tonChange,\n\tdefaultCountry = \"NG\",\n\tsize,\n\tdisabled = false,\n\treadOnly = false,\n\tplaceholder = \"(0000) 000-0000\",\n\tclassName,\n\tid,\n\tname,\n\t\"aria-invalid\": ariaInvalid,\n}: PhoneInputProps) {\n\tconst resolvedSize = useComponentSize(size);\n\n\t// biome-ignore lint/correctness/useExhaustiveDependencies: seed once from the initial value; later updates flow through the sync effect below.\n\tconst initial = React.useMemo(() => parseValue(value), []);\n\tconst [country, setCountry] = React.useState<CountryCode>(\n\t\tinitial.country ?? defaultCountry,\n\t);\n\tconst [national, setNational] = React.useState(() =>\n\t\tformatNational(initial.digits, initial.country ?? defaultCountry),\n\t);\n\n\t// Keep internal state in sync when `value` is changed from outside.\n\t// biome-ignore lint/correctness/useExhaustiveDependencies: only re-sync when the external `value` changes, not on internal edits.\n\tReact.useEffect(() => {\n\t\tconst currentDigits = getNationalDigits(national);\n\t\tif (toE164(currentDigits, country) === value) return;\n\n\t\tconst next = parseValue(value);\n\t\tconst nextCountry = next.country ?? country;\n\t\tsetCountry(nextCountry);\n\t\tsetNational(formatNational(next.digits, nextCountry));\n\t}, [value]);\n\n\tfunction emit(digits: string, nextCountry: CountryCode) {\n\t\tonChange?.(toE164(digits, nextCountry));\n\t}\n\n\tfunction handleInputChange(event: React.ChangeEvent<HTMLInputElement>) {\n\t\tconst digits = getNationalDigits(event.target.value);\n\t\tsetNational(formatNational(digits, country));\n\t\temit(digits, country);\n\t}\n\n\tfunction handleCountrySelect(nextCountry: CountryCode) {\n\t\tconst digits = getNationalDigits(national);\n\t\tsetCountry(nextCountry);\n\t\tsetNational(formatNational(digits, nextCountry));\n\t\temit(digits, nextCountry);\n\t}\n\n\tconst dividerStateClasses = cn(\n\t\t\"group-hover/input-group:bg-line-strong\",\n\t\t\"group-focus-within/input-group:bg-line-focus\",\n\t\t\"group-has-[[aria-invalid=true]]/input-group:bg-line-danger\",\n\t\t\"group-has-disabled/input-group:bg-line-subtle\",\n\t);\n\n\treturn (\n\t\t<InputGroup size={resolvedSize} className={className}>\n\t\t\t<InputGroupAddon align=\"inline-start\" className=\"gap-2\">\n\t\t\t\t<CountrySelect\n\t\t\t\t\tcountry={country}\n\t\t\t\t\tsize={resolvedSize}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonSelect={handleCountrySelect}\n\t\t\t\t/>\n\t\t\t\t<Separator\n\t\t\t\t\torientation=\"vertical\"\n\t\t\t\t\tshade=\"deep\"\n\t\t\t\t\tclassName={cn(\"self-stretch transition-colors\", dividerStateClasses)}\n\t\t\t\t/>\n\t\t\t</InputGroupAddon>\n\t\t\t<InputGroupInput\n\t\t\t\tid={id}\n\t\t\t\tname={name}\n\t\t\t\ttype=\"tel\"\n\t\t\t\tinputMode=\"tel\"\n\t\t\t\tautoComplete=\"tel\"\n\t\t\t\tvalue={national}\n\t\t\t\tonChange={handleInputChange}\n\t\t\t\tplaceholder={placeholder}\n\t\t\t\tdisabled={disabled}\n\t\t\t\treadOnly={readOnly}\n\t\t\t\taria-invalid={ariaInvalid || undefined}\n\t\t\t\tclassName=\"pl-0\"\n\t\t\t/>\n\t\t</InputGroup>\n\t);\n}\n\nexport { PhoneInput };\nexport type { PhoneInputProps, CountryCode };\n","\"use client\";\n\nimport { Dialog as DialogPrimitive } from \"@base-ui/react/dialog\";\nimport {\n\tChevronLeftIcon,\n\tChevronRightIcon,\n\tFullscreen,\n\tXIcon,\n} from \"lucide-react\";\nimport type { SVGProps } from \"react\";\nimport * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\nimport {\n\tCarousel,\n\ttype CarouselApi,\n\tCarouselContent,\n\tCarouselItem,\n} from \"./carousel\";\n\n/**\n * A single property photo. `src` is optional so the gallery can render a\n * \"Property Image\" placeholder in previews / while imagery is still loading.\n */\ntype PhotoGalleryImage = {\n\tsrc?: string;\n\talt?: string;\n};\n\n/**\n * Wires an Embla carousel to a controlled/uncontrolled active index. Returns\n * the `setApi` to hand to {@link Carousel} plus the live index and navigation\n * helpers. Both surfaces share this so the inline carousel and the fullscreen\n * viewer can stand alone — or stay in sync by sharing `index`/`onIndexChange`.\n */\nfunction useGalleryCarousel(\n\tindex: number | undefined,\n\tonIndexChange: ((index: number) => void) | undefined,\n) {\n\tconst [api, setApi] = React.useState<CarouselApi>();\n\tconst [selectedIndex, setSelectedIndex] = React.useState(index ?? 0);\n\tconst initialIndexRef = React.useRef(index ?? 0);\n\n\t// Keep the change callback in a ref so subscribing doesn't depend on a\n\t// caller passing a stable function identity.\n\tconst onIndexChangeRef = React.useRef(onIndexChange);\n\tReact.useEffect(() => {\n\t\tonIndexChangeRef.current = onIndexChange;\n\t});\n\n\tReact.useEffect(() => {\n\t\tif (!api) return;\n\t\tconst onSelect = () => {\n\t\t\tconst next = api.selectedScrollSnap();\n\t\t\tsetSelectedIndex(next);\n\t\t\tonIndexChangeRef.current?.(next);\n\t\t};\n\t\tonSelect();\n\t\tapi.on(\"select\", onSelect).on(\"reInit\", onSelect);\n\t\treturn () => {\n\t\t\tapi.off(\"select\", onSelect).off(\"reInit\", onSelect);\n\t\t};\n\t}, [api]);\n\n\t// Controlled mode: follow the index the parent hands down.\n\tReact.useEffect(() => {\n\t\tif (api && index !== undefined && index !== api.selectedScrollSnap()) {\n\t\t\tapi.scrollTo(index, false);\n\t\t}\n\t}, [api, index]);\n\n\tconst scrollTo = React.useCallback(\n\t\t(i: number) => api?.scrollTo(i, false),\n\t\t[api],\n\t);\n\tconst scrollPrev = React.useCallback(() => api?.scrollPrev(false), [api]);\n\tconst scrollNext = React.useCallback(() => api?.scrollNext(false), [api]);\n\n\treturn {\n\t\tsetApi,\n\t\tselectedIndex,\n\t\tinitialIndex: initialIndexRef.current,\n\t\tscrollTo,\n\t\tscrollPrev,\n\t\tscrollNext,\n\t};\n}\n\n/* -------------------------------------------------------------------------- */\n/* Shared chrome */\n/* -------------------------------------------------------------------------- */\n\n/**\n * The image surface. Fills its slide; falls back to a centred placeholder\n * label when `src` is missing. `cover` for the listing crop, `contain` for the\n * fullscreen viewer so the whole photo stays visible.\n */\nfunction GalleryFrame({\n\timage,\n\tfit = \"cover\",\n\tclassName,\n}: {\n\timage: PhotoGalleryImage | undefined;\n\tfit?: \"cover\" | \"contain\";\n\tclassName?: string;\n}) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"photo-gallery-frame\"\n\t\t\tclassName={cn(\n\t\t\t\t\"relative flex size-full items-center justify-center overflow-hidden\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t>\n\t\t\t{image?.src ? (\n\t\t\t\t<img\n\t\t\t\t\tsrc={image.src}\n\t\t\t\t\talt={image.alt ?? \"Property image\"}\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"size-full\",\n\t\t\t\t\t\tfit === \"contain\" ? \"object-contain\" : \"object-cover\",\n\t\t\t\t\t)}\n\t\t\t\t\tdraggable={false}\n\t\t\t\t/>\n\t\t\t) : (\n\t\t\t\t<span className=\"text-gdt-sm font-medium text-fg-caption-placeholder\">\n\t\t\t\t\tProperty Image\n\t\t\t\t</span>\n\t\t\t)}\n\t\t</div>\n\t);\n}\n\nconst Images = (props: SVGProps<SVGSVGElement>) => (\n\t<svg\n\t\taria-hidden=\"true\"\n\t\txmlns=\"http://www.w3.org/2000/svg\"\n\t\twidth={15}\n\t\theight={16}\n\t\tviewBox=\"0 0 15 16\"\n\t\tfill=\"none\"\n\t\t{...props}\n\t>\n\t\t<path\n\t\t\tfill=\"currentColor\"\n\t\t\td=\"M6.72 14.332c-.705 0-1.38-.3-1.878-.83a2.935 2.935 0 0 1-.779-2.003V2.012l-3.02.738c-.36.102-.667.353-.853.697a1.587 1.587 0 0 0-.143 1.136l2.589 10.309c.083.318.261.598.507.798.246.2.546.309.856.31.115 0 .233-.015.349-.048l6.3-1.62H6.72ZM8.125 6c.69 0 1.25-.597 1.25-1.333 0-.735-.56-1.333-1.25-1.333s-1.25.598-1.25 1.333c0 .736.56 1.333 1.25 1.333Z\"\n\t\t/>\n\t\t<path\n\t\t\tfill=\"currentColor\"\n\t\t\td=\"M15 2a2.07 2.07 0 0 0-.55-1.414A1.818 1.818 0 0 0 13.126 0h-6.25C6.376 0 5.9.21 5.547.586A2.07 2.07 0 0 0 4.998 2v9.332c0 .53.198 1.04.55 1.414.352.375.829.586 1.326.586h6.25c.498 0 .975-.21 1.327-.586.351-.375.549-.883.549-1.414V2Zm-8.126-.667h6.25c.166 0 .325.07.443.195A.69.69 0 0 1 13.75 2v4.292l-.475-.507a1.094 1.094 0 0 0-.356-.253 1.037 1.037 0 0 0-.839 0 1.094 1.094 0 0 0-.355.253L8.749 8.96l-.787-.84a1.094 1.094 0 0 0-.356-.254 1.037 1.037 0 0 0-.839 0 1.094 1.094 0 0 0-.355.254l-.163.173V2a.69.69 0 0 1 .183-.472.606.606 0 0 1 .442-.195Z\"\n\t\t/>\n\t</svg>\n);\n\n/** Pill overlay showing `current / total`. Hidden when there is one image. */\nfunction GalleryCounter({\n\tcurrent,\n\ttotal,\n\tclassName,\n}: {\n\tcurrent: number;\n\ttotal: number;\n\tclassName?: string;\n}) {\n\tif (total <= 1) return null;\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"photo-gallery-counter\"\n\t\t\tclassName={cn(\n\t\t\t\t\"pointer-events-none absolute z-10 inline-flex items-center gap-1.5 rounded-full border border-line bg-surface-overlay px-2.5 py-1 text-gdt-xs font-bold text-fg-primary shadow-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t>\n\t\t\t<Images aria-hidden=\"true\" className=\"size-3.5\" />\n\t\t\t<span>\n\t\t\t\t{current} / {total}\n\t\t\t</span>\n\t\t</div>\n\t);\n}\n\nfunction GalleryButton({\n\tclassName,\n\tvariant = \"ghost\",\n\t...rest\n}: React.ComponentProps<typeof Button>) {\n\treturn (\n\t\t<Button\n\t\t\tsize=\"icon\"\n\t\t\tclassName={cn(\n\t\t\t\t\"border border-line bg-surface-overlay text-fg-primary shadow-2 transition-[background-color] outline-none hover:bg-surface-raised focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] size-9 sm:size-11\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tvariant={variant}\n\t\t\t{...rest}\n\t\t/>\n\t);\n}\n\n/** Circular floating navigation button. Always present; the track loops. */\nfunction GalleryArrow({\n\tside,\n\tonClick,\n\tclassName,\n}: {\n\tside: \"prev\" | \"next\";\n\tonClick: () => void;\n\tclassName?: string;\n}) {\n\tconst Icon = side === \"prev\" ? ChevronLeftIcon : ChevronRightIcon;\n\treturn (\n\t\t<GalleryButton\n\t\t\ttype=\"button\"\n\t\t\tdata-slot={`photo-gallery-${side}`}\n\t\t\taria-label={side === \"prev\" ? \"Previous photo\" : \"Next photo\"}\n\t\t\tonClick={(event) => {\n\t\t\t\tevent.stopPropagation();\n\t\t\t\tonClick();\n\t\t\t}}\n\t\t\tclassName={cn(\n\t\t\t\t\"absolute top-1/2 z-10 grid -translate-y-1/2 place-items-center active:not-aria-[haspopup]:-translate-y-1/2\",\n\t\t\t\tside === \"prev\" ? \"left-2 sm:left-4\" : \"right-2 sm:right-4\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t>\n\t\t\t<Icon className=\"cn-rtl-flip size-4 sm:size-5\" />\n\t\t</GalleryButton>\n\t);\n}\n\n/**\n * Equal-sized thumbnail strip. `cols` are sized via CSS vars so exactly N fill\n * the width (5 on mobile, more on web); extras overflow and scroll. The active\n * thumb gets a 2px focus stroke and is kept in view as the index changes.\n */\nfunction GalleryThumbnails({\n\timages,\n\tselectedIndex,\n\tonSelect,\n\tcolsClassName,\n\tclassName,\n\tactiveVariant = \"focus\",\n}: {\n\timages: PhotoGalleryImage[];\n\tselectedIndex: number;\n\tonSelect: (index: number) => void;\n\tcolsClassName: string;\n\tclassName?: string;\n\tactiveVariant?: \"focus\" | \"subtle\";\n}) {\n\tconst containerRef = React.useRef<HTMLDivElement>(null);\n\n\tReact.useEffect(() => {\n\t\tconst active = containerRef.current?.children[selectedIndex];\n\t\tactive?.scrollIntoView({\n\t\t\tbehavior: \"smooth\",\n\t\t\tinline: \"center\",\n\t\t\tblock: \"nearest\",\n\t\t});\n\t}, [selectedIndex]);\n\n\tif (images.length <= 1) return null;\n\n\treturn (\n\t\t<div\n\t\t\tref={containerRef}\n\t\t\tdata-slot=\"photo-gallery-thumbnails\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex gap-2 overflow-x-auto [--gallery-gap:0.5rem] scrollbar-none [&::-webkit-scrollbar]:hidden\",\n\t\t\t\tcolsClassName,\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t>\n\t\t\t{images.map((image, index) => {\n\t\t\t\tconst isActive = index === selectedIndex;\n\t\t\t\treturn (\n\t\t\t\t\t<button\n\t\t\t\t\t\t// biome-ignore lint/suspicious/noArrayIndexKey: photos are a fixed, ordered list that never reorders, so the index is the stable identity.\n\t\t\t\t\t\tkey={index}\n\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\taria-label={`View photo ${index + 1}`}\n\t\t\t\t\t\taria-current={isActive}\n\t\t\t\t\t\tonClick={() => onSelect(index)}\n\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\twidth:\n\t\t\t\t\t\t\t\t\"calc((100% - (var(--gallery-cols) - 1) * var(--gallery-gap)) / var(--gallery-cols))\",\n\t\t\t\t\t\t}}\n\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\"relative aspect-4/3 shrink-0 overflow-hidden rounded-lg border-2 bg-surface-raised transition-[border-color,opacity] outline-none focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)]\",\n\t\t\t\t\t\t\tactiveVariant === \"subtle\" &&\n\t\t\t\t\t\t\t\t\"focus-visible:border-line-subtle focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-subtle)]\",\n\t\t\t\t\t\t\tisActive\n\t\t\t\t\t\t\t\t? activeVariant === \"subtle\"\n\t\t\t\t\t\t\t\t\t? \"border-line-subtle\"\n\t\t\t\t\t\t\t\t\t: \"border-line-focus\"\n\t\t\t\t\t\t\t\t: \"border-transparent opacity-80 hover:opacity-100\",\n\t\t\t\t\t\t)}\n\t\t\t\t\t>\n\t\t\t\t\t\t{image.src ? (\n\t\t\t\t\t\t\t<img\n\t\t\t\t\t\t\t\tsrc={image.src}\n\t\t\t\t\t\t\t\talt={image.alt ?? `Property image ${index + 1}`}\n\t\t\t\t\t\t\t\tclassName=\"size-full object-cover\"\n\t\t\t\t\t\t\t\tdraggable={false}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t) : null}\n\t\t\t\t\t</button>\n\t\t\t\t);\n\t\t\t})}\n\t\t</div>\n\t);\n}\n\n/* -------------------------------------------------------------------------- */\n/* Inline carousel */\n/* -------------------------------------------------------------------------- */\n\ntype PhotoGalleryProps = Omit<React.ComponentProps<\"div\">, \"onClick\"> & {\n\timages: PhotoGalleryImage[];\n\t/** Controlled active index. Omit to let the gallery manage it internally. */\n\tindex?: number;\n\tonIndexChange?: (index: number) => void;\n\t/** Called when the hero image is activated — wire this to open fullscreen. */\n\tonImageClick?: (index: number) => void;\n};\n\n/**\n * Inline property gallery: a swipeable hero image (drag / touch / ← →) with a\n * counter pill, navigation arrows, and a thumbnail strip below. Built on\n * {@link Carousel}. Standalone — pass `onImageClick` to open it into a\n * {@link PhotoGalleryFullscreen} viewer, but neither surface needs the other.\n */\nfunction PhotoGallery({\n\timages,\n\tindex,\n\tonIndexChange,\n\tonImageClick,\n\tclassName,\n\t...props\n}: PhotoGalleryProps) {\n\tconst {\n\t\tsetApi,\n\t\tselectedIndex,\n\t\tinitialIndex,\n\t\tscrollTo,\n\t\tscrollPrev,\n\t\tscrollNext,\n\t} = useGalleryCarousel(index, onIndexChange);\n\tconst hasMany = images.length > 1;\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"photo-gallery\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex w-full flex-col gap-3 rounded-2xl border border-line bg-surface p-3\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<Carousel\n\t\t\t\timageSize=\"full\"\n\t\t\t\tsetApi={setApi}\n\t\t\t\topts={{ loop: true, startIndex: initialIndex, watchDrag: hasMany }}\n\t\t\t\tclassName=\"aspect-video rounded-xl bg-surface-raised\"\n\t\t\t>\n\t\t\t\t<CarouselContent>\n\t\t\t\t\t{images.map((image, i) => (\n\t\t\t\t\t\t<CarouselItem\n\t\t\t\t\t\t\t// biome-ignore lint/suspicious/noArrayIndexKey: photos are a fixed, ordered list that never reorders, so the index is the stable identity.\n\t\t\t\t\t\t\tkey={i}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<GalleryFrame image={image} />\n\t\t\t\t\t\t</CarouselItem>\n\t\t\t\t\t))}\n\t\t\t\t</CarouselContent>\n\t\t\t\t{onImageClick && (\n\t\t\t\t\t<GalleryButton\n\t\t\t\t\t\tclassName=\"absolute bottom-2 right-2 sm:bottom-4 sm:right-4\"\n\t\t\t\t\t\tonClick={() => onImageClick(selectedIndex)}\n\t\t\t\t\t>\n\t\t\t\t\t\t<Fullscreen className=\"size-4 md:size-5\" />\n\t\t\t\t\t</GalleryButton>\n\t\t\t\t)}\n\n\t\t\t\t<GalleryCounter\n\t\t\t\t\tcurrent={selectedIndex + 1}\n\t\t\t\t\ttotal={images.length}\n\t\t\t\t\tclassName=\"top-2 right-2 sm:top-4 md:right-4\"\n\t\t\t\t/>\n\t\t\t\t{hasMany && (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<GalleryArrow side=\"prev\" onClick={scrollPrev} />\n\t\t\t\t\t\t<GalleryArrow side=\"next\" onClick={scrollNext} />\n\t\t\t\t\t</>\n\t\t\t\t)}\n\t\t\t</Carousel>\n\n\t\t\t<GalleryThumbnails\n\t\t\t\timages={images}\n\t\t\t\tselectedIndex={selectedIndex}\n\t\t\t\tonSelect={scrollTo}\n\t\t\t\tcolsClassName=\"[--gallery-cols:5] sm:[--gallery-cols:8]\"\n\t\t\t/>\n\t\t</div>\n\t);\n}\n\n/* -------------------------------------------------------------------------- */\n/* Fullscreen viewer */\n/* -------------------------------------------------------------------------- */\n\ntype PhotoGalleryFullscreenProps = {\n\timages: PhotoGalleryImage[];\n\topen: boolean;\n\tonOpenChange: (open: boolean) => void;\n\t/** Controlled active index. Omit to let the viewer manage it internally. */\n\tindex?: number;\n\tonIndexChange?: (index: number) => void;\n};\n\n/**\n * Fullscreen lightbox: takes over the viewport over a `bg-canvas` surface for\n * distraction-free browsing. Swipeable (drag / touch) with ← → key navigation\n * and ESC to close. Built on {@link Carousel}; controlled via `open` /\n * `onOpenChange` and usable without the inline gallery.\n */\nfunction PhotoGalleryFullscreen({\n\timages,\n\topen,\n\tonOpenChange,\n\tindex,\n\tonIndexChange,\n}: PhotoGalleryFullscreenProps) {\n\tconst {\n\t\tsetApi,\n\t\tselectedIndex,\n\t\tinitialIndex,\n\t\tscrollTo,\n\t\tscrollPrev,\n\t\tscrollNext,\n\t} = useGalleryCarousel(index, onIndexChange);\n\tconst hasMany = images.length > 1;\n\n\tconst handleKeyDown = (event: React.KeyboardEvent<HTMLDivElement>) => {\n\t\t// The carousel handles arrows in the capture phase when it holds focus;\n\t\t// skip so focus inside the track doesn't navigate twice.\n\t\tif (event.defaultPrevented) return;\n\t\tif (event.key === \"ArrowLeft\") {\n\t\t\tevent.preventDefault();\n\t\t\tscrollPrev();\n\t\t} else if (event.key === \"ArrowRight\") {\n\t\t\tevent.preventDefault();\n\t\t\tscrollNext();\n\t\t}\n\t};\n\n\treturn (\n\t\t<DialogPrimitive.Root open={open} onOpenChange={onOpenChange}>\n\t\t\t<DialogPrimitive.Portal>\n\t\t\t\t<DialogPrimitive.Backdrop\n\t\t\t\t\tdata-slot=\"photo-gallery-fullscreen-backdrop\"\n\t\t\t\t\tclassName=\"fixed inset-0 z-50 bg-black/50 transition-opacity duration-150 data-closed:opacity-0 data-open:opacity-100\"\n\t\t\t\t/>\n\t\t\t\t<DialogPrimitive.Popup\n\t\t\t\t\tdata-slot=\"photo-gallery-fullscreen\"\n\t\t\t\t\tonKeyDown={handleKeyDown}\n\t\t\t\t\tclassName=\"fixed inset-0 z-50 flex flex-col gap-4 p-4 sm:p-6 xl:p-8 outline-none transition-opacity duration-150 data-closed:opacity-0 data-open:opacity-100\"\n\t\t\t\t>\n\t\t\t\t\t<DialogPrimitive.Title className=\"sr-only\">\n\t\t\t\t\t\tPhoto Gallery\n\t\t\t\t\t</DialogPrimitive.Title>\n\n\t\t\t\t\t<div className=\"w-full flex items-center justify-between\">\n\t\t\t\t\t\t<GalleryCounter\n\t\t\t\t\t\t\tcurrent={selectedIndex + 1}\n\t\t\t\t\t\t\ttotal={images.length}\n\t\t\t\t\t\t\tclassName=\"static\"\n\t\t\t\t\t\t/>\n\t\t\t\t\t\t<DialogPrimitive.Close\n\t\t\t\t\t\t\tdata-slot=\"photo-gallery-fullscreen-close\"\n\t\t\t\t\t\t\taria-label=\"Close gallery\"\n\t\t\t\t\t\t\trender={<GalleryButton />}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<XIcon className=\"size-4 sm:size-5\" />\n\t\t\t\t\t\t</DialogPrimitive.Close>\n\t\t\t\t\t</div>\n\n\t\t\t\t\t<Carousel\n\t\t\t\t\t\timageSize=\"full\"\n\t\t\t\t\t\tsetApi={setApi}\n\t\t\t\t\t\topts={{ loop: true, startIndex: initialIndex, watchDrag: hasMany }}\n\t\t\t\t\t\tclassName=\"flex-1 w-full rounded-xl bg-transparent\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<CarouselContent className=\"items-center\">\n\t\t\t\t\t\t\t{images.map((image, i) => (\n\t\t\t\t\t\t\t\t<CarouselItem\n\t\t\t\t\t\t\t\t\t// biome-ignore lint/suspicious/noArrayIndexKey: photos are a fixed, ordered list that never reorders, so the index is the stable identity.\n\t\t\t\t\t\t\t\t\tkey={i}\n\t\t\t\t\t\t\t\t\tclassName=\"h-full\"\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<GalleryFrame image={image} fit=\"contain\" />\n\t\t\t\t\t\t\t\t</CarouselItem>\n\t\t\t\t\t\t\t))}\n\t\t\t\t\t\t</CarouselContent>\n\t\t\t\t\t\t{hasMany && (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t<GalleryArrow\n\t\t\t\t\t\t\t\t\tside=\"prev\"\n\t\t\t\t\t\t\t\t\tonClick={scrollPrev}\n\t\t\t\t\t\t\t\t\tclassName=\"left-0!\"\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t<GalleryArrow\n\t\t\t\t\t\t\t\t\tside=\"next\"\n\t\t\t\t\t\t\t\t\tonClick={scrollNext}\n\t\t\t\t\t\t\t\t\tclassName=\"right-0!\"\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</Carousel>\n\n\t\t\t\t\t{hasMany && (\n\t\t\t\t\t\t<div className=\"flex flex-col gap-3\">\n\t\t\t\t\t\t\t<p className=\"hidden text-center text-gdt-xs text-fg-secondary sm:block\">\n\t\t\t\t\t\t\t\t← → to navigate · ESC to close\n\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t\t<GalleryThumbnails\n\t\t\t\t\t\t\t\timages={images}\n\t\t\t\t\t\t\t\tselectedIndex={selectedIndex}\n\t\t\t\t\t\t\t\tonSelect={scrollTo}\n\t\t\t\t\t\t\t\tcolsClassName=\"[--gallery-cols:5] sm:[--gallery-cols:10]\"\n\t\t\t\t\t\t\t\tclassName=\"mx-auto w-full max-w-3xl\"\n\t\t\t\t\t\t\t\tactiveVariant=\"subtle\"\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t)}\n\t\t\t\t</DialogPrimitive.Popup>\n\t\t\t</DialogPrimitive.Portal>\n\t\t</DialogPrimitive.Root>\n\t);\n}\n\nexport {\n\ttype PhotoGalleryImage,\n\ttype PhotoGalleryProps,\n\ttype PhotoGalleryFullscreenProps,\n\tPhotoGallery,\n\tPhotoGalleryFullscreen,\n};\n","\"use client\";\n\nimport { cva } from \"class-variance-authority\";\nimport type * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\n/**\n * Pie / donut charts are composed from recharts plot primitives directly —\n * recharts identifies `PieChart`, `Pie`, and `Cell` by component identity, so\n * they cannot be wrapped. This module supplies the giddaa-specific pieces that\n * would otherwise be copy-pasted: per-size layout numbers, a categorical\n * palette, the donut center label, and the rich legend (dot · name · value ·\n * percentage). Pair them with the shared frame from `./chart`.\n *\n * A donut keeps an open center for a total label (`innerRadius` > 0); a pie\n * fills the circle (`innerRadius={0}`). Both read the same layout.\n *\n * @example\n * const chart = usePieChartLayout({ size: \"md\", type: \"donut\" });\n * <ChartCard size=\"md\">\n * <div className=\"flex items-center gap-4\">\n * <ChartContainer config={config} {...chart.container}>\n * <PieChart>\n * <Pie data={data} dataKey=\"value\" nameKey=\"label\" {...chart.pie}>\n * {data.map((d) => <Cell key={d.label} fill={d.color} />)}\n * <Label content={<PieCenterLabel total=\"₦1.1M\" caption=\"Total spend\" />} />\n * </Pie>\n * </PieChart>\n * </ChartContainer>\n * <PieChartLegend items={legendItems} />\n * </div>\n * </ChartCard>\n */\n\n/** Pie sizes line up with the three shared `ComponentSize` values. */\ntype PieChartSize = ComponentSize;\n\ntype PieChartLayout = {\n\t/** Square plot box in px (width = height); width is NOT parent-driven here. */\n\tsize: number;\n\t/** Donut hole radius in px. Pass `0` to the `Pie` for a filled pie. */\n\tinnerRadius: number;\n\t/** Outer ring radius in px. */\n\touterRadius: number;\n\t/** Gap between segments, in degrees. */\n\tpaddingAngle: number;\n\t/** Corner radius of each segment. */\n\tcornerRadius: number;\n\t/** Center total font size. */\n\ttotalFontSize: number;\n\t/** Center caption font size. */\n\tcaptionFontSize: number;\n};\n\nconst PIE_CHART_LAYOUT: Record<PieChartSize, PieChartLayout> = {\n\tsm: {\n\t\tsize: 132,\n\t\tinnerRadius: 42,\n\t\touterRadius: 64,\n\t\tpaddingAngle: 2,\n\t\tcornerRadius: 0,\n\t\ttotalFontSize: 18,\n\t\tcaptionFontSize: 9,\n\t},\n\tmd: {\n\t\tsize: 176,\n\t\tinnerRadius: 56,\n\t\touterRadius: 84,\n\t\tpaddingAngle: 2,\n\t\tcornerRadius: 0,\n\t\ttotalFontSize: 24,\n\t\tcaptionFontSize: 11,\n\t},\n\tlg: {\n\t\tsize: 224,\n\t\tinnerRadius: 72,\n\t\touterRadius: 108,\n\t\tpaddingAngle: 2,\n\t\tcornerRadius: 0,\n\t\ttotalFontSize: 30,\n\t\tcaptionFontSize: 12,\n\t},\n};\n\n/**\n * Categorical palette for pie/donut segments, ordered by share. Giddaa has no\n * `chart-1`…`chart-N` tokens yet, so these map to the brand scales: forest →\n * brass → moss → clay → stone. Assign by index, or override per `Cell`.\n */\nconst PIE_CHART_PALETTE = [\n\t\"var(--color-forest-700)\",\n\t\"var(--color-brass-500)\",\n\t\"var(--color-moss-600)\",\n\t\"var(--color-clay-500)\",\n\t\"var(--color-stone-500)\",\n] as const;\n\n/**\n * Resolve the pie-chart layout for an explicit or inherited component size and\n * chart `type`. The returned object groups the giddaa defaults by the recharts\n * component they belong to — spread `container` onto `ChartContainer` and `pie`\n * onto `Pie`, then pass the data-specific props (`data`, `dataKey`, `nameKey`)\n * directly afterwards. `type=\"pie\"` collapses the donut hole (`innerRadius` 0).\n */\nfunction usePieChartLayout({\n\tsize,\n\ttype = \"donut\",\n}: {\n\tsize?: PieChartSize;\n\ttype?: \"donut\" | \"pie\";\n} = {}) {\n\tconst layout = PIE_CHART_LAYOUT[useComponentSize(size)];\n\n\treturn {\n\t\tcontainer: {\n\t\t\tclassName: \"aspect-square shrink-0\",\n\t\t\tstyle: { width: layout.size, height: layout.size },\n\t\t},\n\t\tpie: {\n\t\t\tinnerRadius: type === \"pie\" ? 0 : layout.innerRadius,\n\t\t\touterRadius: layout.outerRadius,\n\t\t\tpaddingAngle: type === \"pie\" ? 0 : layout.paddingAngle,\n\t\t\tcornerRadius: layout.cornerRadius,\n\t\t\tstrokeWidth: 0,\n\t\t},\n\t\tlabel: {\n\t\t\ttotalFontSize: layout.totalFontSize,\n\t\t\tcaptionFontSize: layout.captionFontSize,\n\t\t},\n\t};\n}\n\n/**\n * Center label for a donut — the hero total over a short caption. Pass it to\n * recharts as `<Label content={<PieCenterLabel total=… caption=… />} />` inside\n * the `Pie`; recharts injects the `viewBox` carrying the polar center (cx/cy).\n */\ntype PieCenterLabelProps = {\n\t/** Hero figure — pre-formatted, e.g. \"₦1.1M\". */\n\ttotal: React.ReactNode;\n\t/** Short label describing what the total represents, e.g. \"Total spend\". */\n\tcaption?: React.ReactNode;\n\t/** Explicit size; otherwise inherited from the nearest `SizeProvider`. */\n\tsize?: PieChartSize;\n\t// Injected by recharts at render time.\n\tviewBox?: { cx?: number; cy?: number };\n};\n\nfunction PieCenterLabel({\n\ttotal,\n\tcaption,\n\tsize,\n\tviewBox,\n}: PieCenterLabelProps) {\n\tconst { label } = usePieChartLayout({ size });\n\n\tif (!viewBox || viewBox.cx == null || viewBox.cy == null) {\n\t\treturn null;\n\t}\n\n\tconst { cx, cy } = viewBox;\n\tconst captionY = cy + label.totalFontSize * 0.72;\n\n\treturn (\n\t\t<text x={cx} y={cy} textAnchor=\"middle\" dominantBaseline=\"central\">\n\t\t\t<tspan\n\t\t\t\tx={cx}\n\t\t\t\ty={caption == null ? cy : cy - label.captionFontSize * 0.5}\n\t\t\t\tclassName=\"fill-fg-primary font-extrabold tabular-nums\"\n\t\t\t\tstyle={{ fontSize: label.totalFontSize }}\n\t\t\t>\n\t\t\t\t{total}\n\t\t\t</tspan>\n\t\t\t{caption != null && (\n\t\t\t\t<tspan\n\t\t\t\t\tx={cx}\n\t\t\t\t\ty={captionY}\n\t\t\t\t\tclassName=\"fill-fg-secondary font-medium\"\n\t\t\t\t\tstyle={{ fontSize: label.captionFontSize }}\n\t\t\t\t>\n\t\t\t\t\t{caption}\n\t\t\t\t</tspan>\n\t\t\t)}\n\t\t</text>\n\t);\n}\n\n/**\n * Rich legend for pie/donut charts. Unlike the shared `ChartLegendContent`\n * (marker + label only), each row pairs a colour dot with the category name, its\n * value, and its share — laid out as aligned columns so the figures read like a\n * mini table. Values and percentages are pre-formatted by the caller.\n */\ntype PieLegendItem = {\n\t/** Category name, e.g. \"Housing\". */\n\tlabel: string;\n\t/** Segment colour — should match the matching `Cell` fill. */\n\tcolor: string;\n\t/** Pre-formatted value, e.g. \"₦420k\". */\n\tvalue: React.ReactNode;\n\t/** Pre-formatted share, e.g. \"38%\". */\n\tpercentage: React.ReactNode;\n};\n\nconst pieLegendVariants = cva(\"flex min-w-0 flex-col\", {\n\tvariants: {\n\t\tsize: {\n\t\t\tsm: \"gap-1.5 text-gdt-xs\",\n\t\t\tmd: \"gap-2 text-gdt-sm\",\n\t\t\tlg: \"gap-2.5 text-gdt-sm\",\n\t\t},\n\t},\n\tdefaultVariants: { size: \"md\" },\n});\n\nconst pieLegendDotVariants = cva(\"shrink-0 rounded-full\", {\n\tvariants: {\n\t\tsize: { sm: \"size-2\", md: \"size-2.5\", lg: \"size-3\" },\n\t},\n\tdefaultVariants: { size: \"md\" },\n});\n\nfunction PieChartLegend({\n\titems,\n\tsize,\n\tclassName,\n\t...props\n}: React.ComponentProps<\"ul\"> & {\n\titems: PieLegendItem[];\n\tsize?: PieChartSize;\n}) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn (\n\t\t<ul\n\t\t\tclassName={cn(pieLegendVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{items.map((item) => (\n\t\t\t\t<li key={item.label} className=\"flex items-center gap-2.5\">\n\t\t\t\t\t<span\n\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\tclassName={cn(pieLegendDotVariants({ size: resolvedSize }))}\n\t\t\t\t\t\tstyle={{ backgroundColor: item.color }}\n\t\t\t\t\t/>\n\t\t\t\t\t<span className=\"min-w-0 flex-1 truncate text-fg-primary\">\n\t\t\t\t\t\t{item.label}\n\t\t\t\t\t</span>\n\t\t\t\t\t<span className=\"shrink-0 tabular-nums text-fg-secondary\">\n\t\t\t\t\t\t{item.value}\n\t\t\t\t\t</span>\n\t\t\t\t\t<span className=\"w-9 shrink-0 text-right font-bold tabular-nums text-fg-primary\">\n\t\t\t\t\t\t{item.percentage}\n\t\t\t\t\t</span>\n\t\t\t\t</li>\n\t\t\t))}\n\t\t</ul>\n\t);\n}\n\nexport {\n\tPIE_CHART_LAYOUT,\n\tPIE_CHART_PALETTE,\n\tPieCenterLabel,\n\tPieChartLegend,\n\tusePieChartLayout,\n};\nexport type {\n\tPieChartLayout,\n\tPieChartSize,\n\tPieCenterLabelProps,\n\tPieLegendItem,\n};\n","\"use client\";\n\nimport { Progress as ProgressPrimitive } from \"@base-ui/react/progress\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport {\n\ttype ComponentSize,\n\tSizeProvider,\n\tuseComponentSize,\n} from \"./size-context\";\n\nconst progressVariants = cva(\n\t\"group/progress flex w-full flex-wrap items-center\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"gap-x-2 gap-y-1.5\",\n\t\t\t\tmd: \"gap-x-3 gap-y-2\",\n\t\t\t\tlg: \"gap-x-4 gap-y-2.5\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst circularProgressVariants = cva(\n\t\"relative grid place-items-center text-fg-on-brand\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"text-[9px]\",\n\t\t\t\tmd: \"text-[10px]\",\n\t\t\t\tlg: \"text-gdt-xs\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst circularProgressLabelVariants = cva(\n\t\"relative z-10 font-medium tabular-nums leading-none\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"text-[9px]\",\n\t\t\t\tmd: \"text-[10px]\",\n\t\t\t\tlg: \"text-gdt-xs\",\n\t\t\t},\n\t\t\toverlay: {\n\t\t\t\ttrue: \"grid place-items-center rounded-full bg-black/65 text-white shadow-sm backdrop-blur-[1px]\",\n\t\t\t\tfalse: \"\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t\toverlay: false,\n\t\t},\n\t},\n);\n\nconst circularProgressSizes: Record<\n\tComponentSize,\n\t{ pixelSize: number; strokeWidth: number }\n> = {\n\tsm: { pixelSize: 40, strokeWidth: 3 },\n\tmd: { pixelSize: 48, strokeWidth: 4 },\n\tlg: { pixelSize: 56, strokeWidth: 5 },\n};\n\ntype ProgressProps = ProgressPrimitive.Root.Props &\n\tVariantProps<typeof progressVariants> & {\n\t\tdisabled?: boolean;\n\t};\n\ntype ProgressSize = NonNullable<VariantProps<typeof progressVariants>[\"size\"]>;\n\ntype CircularProgressProps = Omit<React.ComponentProps<\"div\">, \"children\"> &\n\tVariantProps<typeof circularProgressVariants> & {\n\t\tvalue: number;\n\t\tlabelOverlay?: boolean;\n\t};\n\nfunction Progress({\n\tclassName,\n\tchildren,\n\tvalue,\n\tsize,\n\tdisabled = false,\n\t...props\n}: ProgressProps) {\n\tconst resolvedSize = useComponentSize(size);\n\tconst hasCustomTrack = React.Children.toArray(children).some(\n\t\t(child) => React.isValidElement(child) && child.type === ProgressTrack,\n\t);\n\n\treturn (\n\t\t<SizeProvider size={resolvedSize}>\n\t\t\t<ProgressPrimitive.Root\n\t\t\t\tvalue={value}\n\t\t\t\taria-disabled={disabled || undefined}\n\t\t\t\tdata-disabled={disabled}\n\t\t\t\tdata-size={resolvedSize}\n\t\t\t\tdata-slot=\"progress\"\n\t\t\t\tclassName={cn(progressVariants({ size: resolvedSize }), className)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t\t{!hasCustomTrack && (\n\t\t\t\t\t<ProgressTrack>\n\t\t\t\t\t\t<ProgressIndicator />\n\t\t\t\t\t</ProgressTrack>\n\t\t\t\t)}\n\t\t\t</ProgressPrimitive.Root>\n\t\t</SizeProvider>\n\t);\n}\n\nfunction ProgressTrack({ className, ...props }: ProgressPrimitive.Track.Props) {\n\treturn (\n\t\t<ProgressPrimitive.Track\n\t\t\tclassName={cn(\n\t\t\t\t\"order-3 relative flex basis-full items-center overflow-hidden rounded-full bg-surface-raised\",\n\t\t\t\t\"group-data-[size=sm]/progress:h-1 group-data-[size=md]/progress:h-1.5 group-data-[size=lg]/progress:h-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tdata-slot=\"progress-track\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ProgressIndicator({\n\tclassName,\n\t...props\n}: ProgressPrimitive.Indicator.Props) {\n\treturn (\n\t\t<ProgressPrimitive.Indicator\n\t\t\tdata-slot=\"progress-indicator\"\n\t\t\tclassName={cn(\n\t\t\t\t\"h-full rounded-full bg-action-primary transition-[width,transform,background-color] duration-300 ease-out group-data-[disabled=true]/progress:bg-line-strong\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ProgressLabel({ className, ...props }: ProgressPrimitive.Label.Props) {\n\treturn (\n\t\t<ProgressPrimitive.Label\n\t\t\tclassName={cn(\n\t\t\t\t\"order-1 min-w-0 text-fg-primary font-semibold leading-snug group-data-[disabled=true]/progress:text-fg-caption-placeholder\",\n\t\t\t\t\"group-data-[size=sm]/progress:text-gdt-xs group-data-[size=md]/progress:text-gdt-sm group-data-[size=lg]/progress:text-gdt-md\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tdata-slot=\"progress-label\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ProgressValue({ className, ...props }: ProgressPrimitive.Value.Props) {\n\treturn (\n\t\t<ProgressPrimitive.Value\n\t\t\tclassName={cn(\n\t\t\t\t\"order-2 ml-auto shrink-0 tabular-nums text-fg-secondary leading-snug group-data-[disabled=true]/progress:text-fg-caption-placeholder\",\n\t\t\t\t\"group-data-[size=sm]/progress:text-gdt-xs group-data-[size=md]/progress:text-gdt-sm group-data-[size=lg]/progress:text-gdt-md\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tdata-slot=\"progress-value\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ProgressCaption({ className, ...props }: React.ComponentProps<\"p\">) {\n\treturn (\n\t\t<p\n\t\t\tclassName={cn(\n\t\t\t\t\"order-4 basis-full text-fg-secondary leading-snug group-data-[disabled=true]/progress:text-fg-caption-placeholder\",\n\t\t\t\t\"group-data-[size=sm]/progress:text-gdt-subtext group-data-[size=md]/progress:text-gdt-xs group-data-[size=lg]/progress:text-gdt-sm\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tdata-slot=\"progress-caption\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction CircularProgress({\n\tclassName,\n\tstyle,\n\tvalue,\n\tsize,\n\tlabelOverlay = false,\n\t...props\n}: CircularProgressProps) {\n\tconst resolvedSize = useComponentSize(size);\n\tconst normalizedValue = Number.isFinite(value) ? value : 0;\n\tconst progress = Math.min(100, Math.max(0, Math.round(normalizedValue)));\n\tconst { pixelSize, strokeWidth } = circularProgressSizes[resolvedSize];\n\tconst radius = (pixelSize - strokeWidth * 2) / 2;\n\tconst labelSize = pixelSize - strokeWidth * 3;\n\tconst circumference = 2 * Math.PI * radius;\n\tconst strokeDashoffset = circumference - (progress / 100) * circumference;\n\n\treturn (\n\t\t<div\n\t\t\trole=\"progressbar\"\n\t\t\taria-valuemin={0}\n\t\t\taria-valuemax={100}\n\t\t\taria-valuenow={progress}\n\t\t\taria-valuetext={`${progress}%`}\n\t\t\tdata-slot=\"circular-progress\"\n\t\t\tclassName={cn(\n\t\t\t\tcircularProgressVariants({ size: resolvedSize }),\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tstyle={{ width: pixelSize, height: pixelSize, ...style }}\n\t\t\t{...props}\n\t\t>\n\t\t\t<svg\n\t\t\t\taria-hidden=\"true\"\n\t\t\t\tclassName=\"absolute inset-0 -rotate-90 transform\"\n\t\t\t\tfocusable=\"false\"\n\t\t\t\twidth={pixelSize}\n\t\t\t\theight={pixelSize}\n\t\t\t\tviewBox={`0 0 ${pixelSize} ${pixelSize}`}\n\t\t\t\tfill=\"none\"\n\t\t\t\tstroke=\"currentColor\"\n\t\t\t>\n\t\t\t\t<circle\n\t\t\t\t\tclassName=\"text-primary/25\"\n\t\t\t\t\tstrokeWidth={strokeWidth}\n\t\t\t\t\tcx={pixelSize / 2}\n\t\t\t\t\tcy={pixelSize / 2}\n\t\t\t\t\tr={radius}\n\t\t\t\t/>\n\t\t\t\t<circle\n\t\t\t\t\tclassName=\"text-surface-brand transition-[stroke-dashoffset] duration-300 ease-linear\"\n\t\t\t\t\tstrokeWidth={strokeWidth}\n\t\t\t\t\tstrokeLinecap=\"round\"\n\t\t\t\t\tstrokeDasharray={circumference}\n\t\t\t\t\tstrokeDashoffset={strokeDashoffset}\n\t\t\t\t\tcx={pixelSize / 2}\n\t\t\t\t\tcy={pixelSize / 2}\n\t\t\t\t\tr={radius}\n\t\t\t\t/>\n\t\t\t</svg>\n\n\t\t\t<span\n\t\t\t\tclassName={cn(\n\t\t\t\t\tcircularProgressLabelVariants({\n\t\t\t\t\t\tsize: resolvedSize,\n\t\t\t\t\t\toverlay: labelOverlay,\n\t\t\t\t\t}),\n\t\t\t\t)}\n\t\t\t\tstyle={\n\t\t\t\t\tlabelOverlay ? { width: labelSize, height: labelSize } : undefined\n\t\t\t\t}\n\t\t\t>\n\t\t\t\t{progress}%\n\t\t\t</span>\n\t\t</div>\n\t);\n}\n\n/**\n * Composition example\n *\n * <Progress value={60} size=\"md\">\n * <ProgressLabel>Progress</ProgressLabel>\n * <ProgressValue>{(formatted) => formatted}</ProgressValue>\n * <ProgressCaption>\n *\t Uploading 3 files... Please don't close the window.\n * </ProgressCaption>\n * </Progress>\n */\n\nexport {\n\tCircularProgress,\n\tProgress,\n\tProgressTrack,\n\tProgressIndicator,\n\tProgressLabel,\n\tProgressValue,\n\tProgressCaption,\n\tcircularProgressVariants,\n\tprogressVariants,\n\ttype CircularProgressProps,\n\ttype ProgressProps,\n\ttype ProgressSize,\n};\n","\"use client\";\n\nimport { Radio as RadioPrimitive } from \"@base-ui/react/radio\";\nimport { RadioGroup as RadioGroupPrimitive } from \"@base-ui/react/radio-group\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\n\nimport { cn } from \"../../lib/cn\";\nimport { useComponentSize } from \"./size-context\";\n\nfunction RadioGroup({ className, ...props }: RadioGroupPrimitive.Props) {\n\treturn (\n\t\t<RadioGroupPrimitive\n\t\t\tdata-slot=\"radio-group\"\n\t\t\tclassName={cn(\"grid w-full gap-2\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst radioVariants = cva(\n\t\"group/radio-group-item peer relative flex aspect-square shrink-0 rounded-full border bg-transparent text-transparent outline-none transition-[background-color,border-color,box-shadow,color] after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] aria-invalid:border-line-danger aria-invalid:ring-3 aria-invalid:ring-destructive/20 border-line-strong data-checked:border-action-primary data-disabled:cursor-not-allowed data-disabled:border-line-subtle data-disabled:bg-surface data-disabled:text-fg-caption-placeholder size-5 [--radio-dot-size:0.75rem] group-data-[size=sm]/field:size-4 group-data-[size=sm]/field:[--radio-dot-size:0.625rem] group-data-[size=md]/field:size-5 group-data-[size=md]/field:[--radio-dot-size:0.75rem] group-data-[size=lg]/field:size-6 group-data-[size=lg]/field:[--radio-dot-size:0.875rem]\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"size-4 [--radio-dot-size:0.625rem]\",\n\t\t\t\tmd: \"size-5 [--radio-dot-size:0.75rem]\",\n\t\t\t\tlg: \"size-6 [--radio-dot-size:0.875rem]\",\n\t\t\t},\n\t\t},\n\t},\n);\n\ntype RadioGroupItemSize = NonNullable<\n\tVariantProps<typeof radioVariants>[\"size\"]\n>;\ntype RadioGroupItemProps<Value = unknown> = RadioPrimitive.Root.Props<Value> & {\n\tsize?: RadioGroupItemSize;\n};\n\n/**\n * Compose each radio item with the shared field primitives.\n *\n * ```tsx\n * <RadioGroup defaultValue=\"option-1\">\n * <Field orientation=\"horizontal\" size=\"md\">\n * <RadioGroupItem id=\"option-1\" value=\"option-1\" />\n * <FieldContent>\n * <FieldLabel htmlFor=\"option-1\">Radio label</FieldLabel>\n * <FieldDescription>Optional helper description for context.</FieldDescription>\n * </FieldContent>\n * </Field>\n * </RadioGroup>\n * ```\n */\nfunction RadioGroupItem<Value = unknown>({\n\tclassName,\n\tsize,\n\t...props\n}: RadioGroupItemProps<Value>) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn (\n\t\t<RadioPrimitive.Root\n\t\t\tdata-slot=\"radio-group-item\"\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(radioVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<RadioPrimitive.Indicator\n\t\t\t\tdata-slot=\"radio-group-indicator\"\n\t\t\t\tclassName=\"flex size-full items-center justify-center\"\n\t\t\t>\n\t\t\t\t<span className=\"absolute top-1/2 left-1/2 size-(--radio-dot-size) -translate-x-1/2 -translate-y-1/2 rounded-full bg-current\" />\n\t\t\t</RadioPrimitive.Indicator>\n\t\t</RadioPrimitive.Root>\n\t);\n}\n\nexport { RadioGroup, RadioGroupItem, radioVariants };\n","\"use client\";\n\nimport { Color } from \"@tiptap/extension-color\";\nimport { Image } from \"@tiptap/extension-image\";\nimport { Placeholder } from \"@tiptap/extension-placeholder\";\nimport { TextAlign } from \"@tiptap/extension-text-align\";\nimport { TextStyle } from \"@tiptap/extension-text-style\";\nimport { EditorContent, useEditor, useEditorState } from \"@tiptap/react\";\nimport { StarterKit } from \"@tiptap/starter-kit\";\nimport {\n\tAlignCenter,\n\tAlignJustify,\n\tAlignLeft,\n\tAlignRight,\n\tBaseline,\n\tBold,\n\tChevronDown,\n\tCode2,\n\tImageIcon,\n\tItalic,\n\tLink2,\n\tList,\n\tListOrdered,\n\tQuote,\n\tRedo2,\n\tUnderline,\n\tUndo2,\n} from \"lucide-react\";\nimport * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\nimport {\n\tDropdownMenu,\n\tDropdownMenuContent,\n\tDropdownMenuRadioGroup,\n\tDropdownMenuRadioItem,\n\tDropdownMenuTrigger,\n} from \"./dropdown-menu\";\nimport { Input } from \"./input\";\nimport { Popover, PopoverContent, PopoverTrigger } from \"./popover\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\n// ─── Size configuration ───────────────────────────────────────────────────────\n// Toolbar density, text scale and padding step together across the three sizes.\n\ninterface SizeTokens {\n\twidth: string;\n\tcontent: string;\n\tcontentPad: string;\n\ttext: string;\n\ticon: string;\n\tbutton: string;\n\ttoolbarPad: string;\n\ttoolbarGap: string;\n\tdivider: string;\n}\n\nconst SIZES: Record<ComponentSize, SizeTokens> = {\n\tsm: {\n\t\twidth: \"max-w-[420px]\",\n\t\tcontent: \"min-h-[140px]\",\n\t\tcontentPad: \"px-4 py-3\",\n\t\ttext: \"text-gdt-xs\",\n\t\ticon: \"[&_svg:not([class*='size-'])]:size-3.5\",\n\t\tbutton: \"h-7 min-w-7 px-1\",\n\t\ttoolbarPad: \"px-2 py-1.5\",\n\t\ttoolbarGap: \"gap-0.5\",\n\t\tdivider: \"h-4\",\n\t},\n\tmd: {\n\t\twidth: \"max-w-[520px]\",\n\t\tcontent: \"min-h-[172px]\",\n\t\tcontentPad: \"px-5 py-4\",\n\t\ttext: \"text-gdt-sm\",\n\t\ticon: \"[&_svg:not([class*='size-'])]:size-4\",\n\t\tbutton: \"h-8 min-w-8 px-1.5\",\n\t\ttoolbarPad: \"px-2.5 py-2\",\n\t\ttoolbarGap: \"gap-0.5\",\n\t\tdivider: \"h-5\",\n\t},\n\tlg: {\n\t\twidth: \"max-w-[600px]\",\n\t\tcontent: \"min-h-[206px]\",\n\t\tcontentPad: \"px-6 py-5\",\n\t\ttext: \"text-gdt-md\",\n\t\ticon: \"[&_svg:not([class*='size-'])]:size-[18px]\",\n\t\tbutton: \"h-9 min-w-9 px-2\",\n\t\ttoolbarPad: \"px-3 py-2.5\",\n\t\ttoolbarGap: \"gap-1\",\n\t\tdivider: \"h-6\",\n\t},\n};\n\n// Text-colour swatches. The first entry clears any applied colour.\nconst TEXT_COLORS = [\n\t{ label: \"Default\", value: \"\" },\n\t{ label: \"Forest\", value: \"#2f5a2c\" },\n\t{ label: \"Brass\", value: \"#b8861a\" },\n\t{ label: \"Clay\", value: \"#b2542b\" },\n\t{ label: \"Moss\", value: \"#4e4d29\" },\n\t{ label: \"Stone\", value: \"#5c5648\" },\n\t{ label: \"Ink\", value: \"#1f1c18\" },\n] as const;\n\nconst BLOCK_OPTIONS = [\n\t{ value: \"paragraph\", label: \"Normal\" },\n\t{ value: \"h1\", label: \"Heading 1\" },\n\t{ value: \"h2\", label: \"Heading 2\" },\n\t{ value: \"h3\", label: \"Heading 3\" },\n] as const;\n\ntype BlockValue = (typeof BLOCK_OPTIONS)[number][\"value\"];\ntype AlignValue = \"left\" | \"center\" | \"right\" | \"justify\";\n\n// ─── Shared toolbar primitives ──────────────────────────────────────────────────\n\nfunction toolbarControlClass(tokens: SizeTokens, active?: boolean) {\n\treturn cn(\n\t\t\"inline-flex shrink-0 cursor-pointer items-center justify-center rounded-md font-medium text-fg-secondary outline-none transition-colors select-none\",\n\t\t\"hover:bg-action-tertiary-hover hover:text-fg-primary\",\n\t\t\"focus-visible:ring-2 focus-visible:ring-line-focus\",\n\t\t\"disabled:pointer-events-none disabled:opacity-40 data-disabled:pointer-events-none data-disabled:opacity-40\",\n\t\ttokens.button,\n\t\ttokens.icon,\n\t\ttokens.text,\n\t\tactive &&\n\t\t\t\"bg-action-primary text-fg-on-brand hover:bg-action-primary-hover hover:text-fg-on-brand\",\n\t);\n}\n\ninterface ToolbarButtonProps {\n\ttokens: SizeTokens;\n\tlabel: string;\n\tactive?: boolean;\n\tdisabled?: boolean;\n\tonClick: () => void;\n\tchildren: React.ReactNode;\n}\n\nfunction ToolbarButton({\n\ttokens,\n\tlabel,\n\tactive,\n\tdisabled,\n\tonClick,\n\tchildren,\n}: ToolbarButtonProps) {\n\treturn (\n\t\t<button\n\t\t\ttype=\"button\"\n\t\t\taria-label={label}\n\t\t\ttitle={label}\n\t\t\taria-pressed={active}\n\t\t\tdisabled={disabled}\n\t\t\t// Keep the editor selection intact when interacting with the toolbar.\n\t\t\tonMouseDown={(event) => event.preventDefault()}\n\t\t\tonClick={onClick}\n\t\t\tclassName={toolbarControlClass(tokens, active)}\n\t\t>\n\t\t\t{children}\n\t\t</button>\n\t);\n}\n\nfunction ToolbarDivider({ tokens }: { tokens: SizeTokens }) {\n\treturn (\n\t\t<span\n\t\t\taria-hidden=\"true\"\n\t\t\tclassName={cn(\"mx-1 w-px shrink-0 self-center bg-line\", tokens.divider)}\n\t\t/>\n\t);\n}\n\n// ─── Block / heading select ──────────────────────────────────────────────────────\n\nfunction BlockControl({\n\ttokens,\n\tvalue,\n\tdisabled,\n\tonChange,\n}: {\n\ttokens: SizeTokens;\n\tvalue: BlockValue;\n\tdisabled?: boolean;\n\tonChange: (value: BlockValue) => void;\n}) {\n\tconst current = BLOCK_OPTIONS.find((option) => option.value === value);\n\n\treturn (\n\t\t<DropdownMenu>\n\t\t\t<DropdownMenuTrigger\n\t\t\t\tdisabled={disabled}\n\t\t\t\tonMouseDown={(event) => event.preventDefault()}\n\t\t\t\tclassName={cn(\n\t\t\t\t\ttoolbarControlClass(tokens),\n\t\t\t\t\t\"w-auto justify-between gap-1 px-2\",\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t<span className=\"whitespace-nowrap\">{current?.label ?? \"Normal\"}</span>\n\t\t\t\t<ChevronDown className=\"size-3.5 opacity-70\" />\n\t\t\t</DropdownMenuTrigger>\n\t\t\t<DropdownMenuContent className=\"min-w-40\">\n\t\t\t\t<DropdownMenuRadioGroup\n\t\t\t\t\tvalue={value}\n\t\t\t\t\tonValueChange={(next) => onChange(next as BlockValue)}\n\t\t\t\t>\n\t\t\t\t\t{BLOCK_OPTIONS.map((option) => (\n\t\t\t\t\t\t<DropdownMenuRadioItem key={option.value} value={option.value}>\n\t\t\t\t\t\t\t{option.label}\n\t\t\t\t\t\t</DropdownMenuRadioItem>\n\t\t\t\t\t))}\n\t\t\t\t</DropdownMenuRadioGroup>\n\t\t\t</DropdownMenuContent>\n\t\t</DropdownMenu>\n\t);\n}\n\n// ─── Text-colour popover ─────────────────────────────────────────────────────────\n\nfunction ColorControl({\n\ttokens,\n\tvalue,\n\tdisabled,\n\tonChange,\n}: {\n\ttokens: SizeTokens;\n\tvalue: string;\n\tdisabled?: boolean;\n\tonChange: (value: string) => void;\n}) {\n\tconst [open, setOpen] = React.useState(false);\n\tconst active = value !== \"\";\n\n\treturn (\n\t\t<Popover open={open} onOpenChange={setOpen}>\n\t\t\t<PopoverTrigger\n\t\t\t\tdisabled={disabled}\n\t\t\t\taria-label=\"Text colour\"\n\t\t\t\ttitle=\"Text colour\"\n\t\t\t\tonMouseDown={(event) => event.preventDefault()}\n\t\t\t\tclassName={toolbarControlClass(tokens, false)}\n\t\t\t>\n\t\t\t\t<span className=\"relative inline-flex flex-col items-center\">\n\t\t\t\t\t<Baseline className={active ? \"text-fg-brand\" : undefined} />\n\t\t\t\t\t<span\n\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\tclassName=\"mt-px h-0.5 w-3 rounded-full\"\n\t\t\t\t\t\tstyle={{ backgroundColor: active ? value : \"currentColor\" }}\n\t\t\t\t\t/>\n\t\t\t\t</span>\n\t\t\t</PopoverTrigger>\n\t\t\t<PopoverContent\n\t\t\t\tshowArrow={false}\n\t\t\t\talign=\"start\"\n\t\t\t\tsideOffset={8}\n\t\t\t\tclassName=\"w-auto py-3\"\n\t\t\t>\n\t\t\t\t<div className=\"grid grid-cols-4 gap-2 px-4\">\n\t\t\t\t\t{TEXT_COLORS.map((color) => {\n\t\t\t\t\t\tconst isSelected = color.value === value;\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\tkey={color.label}\n\t\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\t\ttitle={color.label}\n\t\t\t\t\t\t\t\taria-label={color.label}\n\t\t\t\t\t\t\t\taria-pressed={isSelected}\n\t\t\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\t\t\tonChange(color.value);\n\t\t\t\t\t\t\t\t\tsetOpen(false);\n\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\t\"flex size-7 items-center justify-center rounded-full border transition-[box-shadow,border-color] outline-none\",\n\t\t\t\t\t\t\t\t\t\"hover:border-line-strong focus-visible:ring-2 focus-visible:ring-line-focus\",\n\t\t\t\t\t\t\t\t\tisSelected\n\t\t\t\t\t\t\t\t\t\t? \"border-line-focus ring-2 ring-line-focus/40\"\n\t\t\t\t\t\t\t\t\t\t: \"border-line\",\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\t\t\"flex size-5 items-center justify-center rounded-full text-gdt-xs font-bold\",\n\t\t\t\t\t\t\t\t\t\tcolor.value === \"\" && \"text-fg-secondary\",\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\tstyle={\n\t\t\t\t\t\t\t\t\t\tcolor.value\n\t\t\t\t\t\t\t\t\t\t\t? { backgroundColor: color.value, color: \"#fff\" }\n\t\t\t\t\t\t\t\t\t\t\t: undefined\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\tA\n\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t);\n\t\t\t\t\t})}\n\t\t\t\t</div>\n\t\t\t</PopoverContent>\n\t\t</Popover>\n\t);\n}\n\n// ─── Link popover ────────────────────────────────────────────────────────────────\n\nfunction LinkControl({\n\ttokens,\n\tactive,\n\tcurrentHref,\n\tdisabled,\n\tonApply,\n\tonRemove,\n}: {\n\ttokens: SizeTokens;\n\tactive: boolean;\n\tcurrentHref: string;\n\tdisabled?: boolean;\n\tonApply: (href: string) => void;\n\tonRemove: () => void;\n}) {\n\tconst [open, setOpen] = React.useState(false);\n\tconst [href, setHref] = React.useState(\"\");\n\n\tfunction handleOpenChange(next: boolean) {\n\t\tif (next) setHref(currentHref);\n\t\tsetOpen(next);\n\t}\n\n\tfunction handleSubmit(event: React.FormEvent) {\n\t\tevent.preventDefault();\n\t\tconst trimmed = href.trim();\n\t\tif (trimmed) onApply(trimmed);\n\t\telse onRemove();\n\t\tsetOpen(false);\n\t}\n\n\treturn (\n\t\t<Popover open={open} onOpenChange={handleOpenChange}>\n\t\t\t<PopoverTrigger\n\t\t\t\tdisabled={disabled}\n\t\t\t\taria-label=\"Insert link\"\n\t\t\t\ttitle=\"Insert link\"\n\t\t\t\taria-pressed={active}\n\t\t\t\tonMouseDown={(event) => event.preventDefault()}\n\t\t\t\tclassName={toolbarControlClass(tokens, active)}\n\t\t\t>\n\t\t\t\t<Link2 />\n\t\t\t</PopoverTrigger>\n\t\t\t<PopoverContent showArrow={false} align=\"start\" sideOffset={8}>\n\t\t\t\t<form className=\"flex flex-col gap-3 px-4\" onSubmit={handleSubmit}>\n\t\t\t\t\t<Input\n\t\t\t\t\t\tautoFocus\n\t\t\t\t\t\tsize=\"sm\"\n\t\t\t\t\t\ttype=\"url\"\n\t\t\t\t\t\tplaceholder=\"https://example.com\"\n\t\t\t\t\t\tvalue={href}\n\t\t\t\t\t\tonChange={(event) => setHref(event.target.value)}\n\t\t\t\t\t/>\n\t\t\t\t\t<div className=\"flex items-center justify-between gap-2\">\n\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\tvariant=\"tertiary-outline\"\n\t\t\t\t\t\t\tsize=\"sm\"\n\t\t\t\t\t\t\tdisabled={!active}\n\t\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\t\tonRemove();\n\t\t\t\t\t\t\t\tsetOpen(false);\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\tRemove\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t<Button type=\"submit\" size=\"sm\">\n\t\t\t\t\t\t\tApply\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t</div>\n\t\t\t\t</form>\n\t\t\t</PopoverContent>\n\t\t</Popover>\n\t);\n}\n\n// ─── Alignment dropdown ──────────────────────────────────────────────────────────\n\nconst ALIGN_OPTIONS = [\n\t{ value: \"left\", label: \"Left\", Icon: AlignLeft },\n\t{ value: \"center\", label: \"Center\", Icon: AlignCenter },\n\t{ value: \"right\", label: \"Right\", Icon: AlignRight },\n\t{ value: \"justify\", label: \"Justify\", Icon: AlignJustify },\n] as const;\n\nfunction AlignControl({\n\ttokens,\n\tvalue,\n\tdisabled,\n\tonChange,\n}: {\n\ttokens: SizeTokens;\n\tvalue: AlignValue;\n\tdisabled?: boolean;\n\tonChange: (value: AlignValue) => void;\n}) {\n\tconst current = ALIGN_OPTIONS.find((option) => option.value === value);\n\tconst Icon = current?.Icon ?? AlignLeft;\n\n\treturn (\n\t\t<DropdownMenu>\n\t\t\t<DropdownMenuTrigger\n\t\t\t\tdisabled={disabled}\n\t\t\t\taria-label=\"Text alignment\"\n\t\t\t\ttitle=\"Text alignment\"\n\t\t\t\tonMouseDown={(event) => event.preventDefault()}\n\t\t\t\tclassName={toolbarControlClass(tokens, value !== \"left\")}\n\t\t\t>\n\t\t\t\t<Icon />\n\t\t\t</DropdownMenuTrigger>\n\t\t\t<DropdownMenuContent className=\"min-w-36\">\n\t\t\t\t<DropdownMenuRadioGroup\n\t\t\t\t\tvalue={value}\n\t\t\t\t\tonValueChange={(next) => onChange(next as AlignValue)}\n\t\t\t\t>\n\t\t\t\t\t{ALIGN_OPTIONS.map(\n\t\t\t\t\t\t({ value: optionValue, label, Icon: OptionIcon }) => (\n\t\t\t\t\t\t\t<DropdownMenuRadioItem key={optionValue} value={optionValue}>\n\t\t\t\t\t\t\t\t<OptionIcon />\n\t\t\t\t\t\t\t\t{label}\n\t\t\t\t\t\t\t</DropdownMenuRadioItem>\n\t\t\t\t\t\t),\n\t\t\t\t\t)}\n\t\t\t\t</DropdownMenuRadioGroup>\n\t\t\t</DropdownMenuContent>\n\t\t</DropdownMenu>\n\t);\n}\n\n// ─── RichTextEditor ──────────────────────────────────────────────────────────────\n\ninterface RichTextEditorProps {\n\tvalue?: string;\n\tdefaultValue?: string;\n\tonChange?: (html: string) => void;\n\tsize?: ComponentSize;\n\tplaceholder?: string;\n\tdisabled?: boolean;\n\tclassName?: string;\n\t\"aria-label\"?: string;\n}\n\nconst EMPTY_STATE = {\n\tblock: \"paragraph\" as BlockValue,\n\talign: \"left\" as AlignValue,\n\tcolor: \"\",\n\tlinkHref: \"\",\n\tisBold: false,\n\tisItalic: false,\n\tisUnderline: false,\n\tisBulletList: false,\n\tisOrderedList: false,\n\tisBlockquote: false,\n\tisCodeBlock: false,\n\tisLink: false,\n\tcanUndo: false,\n\tcanRedo: false,\n};\n\nfunction RichTextEditor({\n\tvalue,\n\tdefaultValue,\n\tonChange,\n\tsize,\n\tplaceholder = \"Start writing, or paste your content here. Format text and add lists, links, and images using the toolbar above.\",\n\tdisabled = false,\n\tclassName,\n\t\"aria-label\": ariaLabel = \"Rich text editor\",\n}: RichTextEditorProps) {\n\tconst resolvedSize = useComponentSize(size);\n\tconst tokens = SIZES[resolvedSize];\n\tconst [focused, setFocused] = React.useState(false);\n\n\tconst editor = useEditor({\n\t\timmediatelyRender: false,\n\t\teditable: !disabled,\n\t\tcontent: value ?? defaultValue ?? \"\",\n\t\textensions: [\n\t\t\tStarterKit.configure({\n\t\t\t\tlink: {\n\t\t\t\t\topenOnClick: false,\n\t\t\t\t\tHTMLAttributes: { rel: \"noopener noreferrer nofollow\" },\n\t\t\t\t},\n\t\t\t}),\n\t\t\tTextStyle,\n\t\t\tColor,\n\t\t\tTextAlign.configure({ types: [\"heading\", \"paragraph\"] }),\n\t\t\tImage.configure({ inline: false, allowBase64: true }),\n\t\t\tPlaceholder.configure({ placeholder }),\n\t\t],\n\t\teditorProps: {\n\t\t\tattributes: {\n\t\t\t\t\"aria-label\": ariaLabel,\n\t\t\t\trole: \"textbox\",\n\t\t\t\t\"aria-multiline\": \"true\",\n\t\t\t\tclass: cn(\"tiptap focus:outline-none\", tokens.text),\n\t\t\t},\n\t\t},\n\t\tonFocus: () => setFocused(true),\n\t\tonBlur: () => setFocused(false),\n\t\tonUpdate: ({ editor: instance }) => onChange?.(instance.getHTML()),\n\t});\n\n\t// Keep editability in sync with the disabled prop.\n\tReact.useEffect(() => {\n\t\teditor?.setEditable(!disabled);\n\t}, [editor, disabled]);\n\n\t// Sync external (controlled) value changes without disturbing the cursor.\n\tReact.useEffect(() => {\n\t\tif (!editor || value === undefined) return;\n\t\tif (value !== editor.getHTML()) {\n\t\t\teditor.commands.setContent(value, { emitUpdate: false });\n\t\t}\n\t}, [editor, value]);\n\n\tconst state = useEditorState({\n\t\teditor,\n\t\tselector: ({ editor: instance }) => {\n\t\t\tif (!instance) return EMPTY_STATE;\n\t\t\tconst block: BlockValue = instance.isActive(\"heading\", { level: 1 })\n\t\t\t\t? \"h1\"\n\t\t\t\t: instance.isActive(\"heading\", { level: 2 })\n\t\t\t\t\t? \"h2\"\n\t\t\t\t\t: instance.isActive(\"heading\", { level: 3 })\n\t\t\t\t\t\t? \"h3\"\n\t\t\t\t\t\t: \"paragraph\";\n\t\t\tconst align: AlignValue = instance.isActive({ textAlign: \"center\" })\n\t\t\t\t? \"center\"\n\t\t\t\t: instance.isActive({ textAlign: \"right\" })\n\t\t\t\t\t? \"right\"\n\t\t\t\t\t: instance.isActive({ textAlign: \"justify\" })\n\t\t\t\t\t\t? \"justify\"\n\t\t\t\t\t\t: \"left\";\n\t\t\treturn {\n\t\t\t\tblock,\n\t\t\t\talign,\n\t\t\t\tcolor: (instance.getAttributes(\"textStyle\").color as string) ?? \"\",\n\t\t\t\tlinkHref: (instance.getAttributes(\"link\").href as string) ?? \"\",\n\t\t\t\tisBold: instance.isActive(\"bold\"),\n\t\t\t\tisItalic: instance.isActive(\"italic\"),\n\t\t\t\tisUnderline: instance.isActive(\"underline\"),\n\t\t\t\tisBulletList: instance.isActive(\"bulletList\"),\n\t\t\t\tisOrderedList: instance.isActive(\"orderedList\"),\n\t\t\t\tisBlockquote: instance.isActive(\"blockquote\"),\n\t\t\t\tisCodeBlock: instance.isActive(\"codeBlock\"),\n\t\t\t\tisLink: instance.isActive(\"link\"),\n\t\t\t\tcanUndo: instance.can().undo(),\n\t\t\t\tcanRedo: instance.can().redo(),\n\t\t\t};\n\t\t},\n\t});\n\n\tconst s = state ?? EMPTY_STATE;\n\n\tfunction setBlock(next: BlockValue) {\n\t\tif (!editor) return;\n\t\tconst chain = editor.chain().focus();\n\t\tif (next === \"paragraph\") chain.setParagraph().run();\n\t\telse chain.toggleHeading({ level: Number(next[1]) as 1 | 2 | 3 }).run();\n\t}\n\n\tfunction setAlign(next: AlignValue) {\n\t\teditor?.chain().focus().setTextAlign(next).run();\n\t}\n\n\tfunction setColor(next: string) {\n\t\tif (!editor) return;\n\t\tif (next) editor.chain().focus().setColor(next).run();\n\t\telse editor.chain().focus().unsetColor().run();\n\t}\n\n\tfunction applyLink(href: string) {\n\t\teditor?.chain().focus().extendMarkRange(\"link\").setLink({ href }).run();\n\t}\n\n\tfunction removeLink() {\n\t\teditor?.chain().focus().extendMarkRange(\"link\").unsetLink().run();\n\t}\n\n\tfunction insertImage() {\n\t\tconst url = window.prompt(\"Image URL\");\n\t\tif (url) editor?.chain().focus().setImage({ src: url }).run();\n\t}\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"rich-text-editor\"\n\t\t\tdata-disabled={disabled || undefined}\n\t\t\tdata-focused={focused || undefined}\n\t\t\tclassName={cn(\n\t\t\t\t\"group/editor flex w-full flex-col overflow-hidden rounded-2xl border bg-surface text-fg-primary shadow-1 transition-[border-color,box-shadow]\",\n\t\t\t\tdisabled\n\t\t\t\t\t? \"border-line-subtle opacity-60\"\n\t\t\t\t\t: focused\n\t\t\t\t\t\t? \"border-line-focus ring-2 ring-line-focus/35\"\n\t\t\t\t\t\t: \"border-line hover:border-line-strong\",\n\t\t\t\ttokens.width,\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t>\n\t\t\t{/* Toolbar — raised strip holding all formatting controls */}\n\t\t\t<div\n\t\t\t\trole=\"toolbar\"\n\t\t\t\taria-label=\"Formatting\"\n\t\t\t\taria-orientation=\"horizontal\"\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"flex flex-wrap items-center bg-surface-raised\",\n\t\t\t\t\ttokens.toolbarPad,\n\t\t\t\t\ttokens.toolbarGap,\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t<BlockControl\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tvalue={s.block}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonChange={setBlock}\n\t\t\t\t/>\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Bold\"\n\t\t\t\t\tactive={s.isBold}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonClick={() => editor?.chain().focus().toggleBold().run()}\n\t\t\t\t>\n\t\t\t\t\t<Bold />\n\t\t\t\t</ToolbarButton>\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Italic\"\n\t\t\t\t\tactive={s.isItalic}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonClick={() => editor?.chain().focus().toggleItalic().run()}\n\t\t\t\t>\n\t\t\t\t\t<Italic />\n\t\t\t\t</ToolbarButton>\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Underline\"\n\t\t\t\t\tactive={s.isUnderline}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonClick={() => editor?.chain().focus().toggleUnderline().run()}\n\t\t\t\t>\n\t\t\t\t\t<Underline />\n\t\t\t\t</ToolbarButton>\n\t\t\t\t<ColorControl\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tvalue={s.color}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonChange={setColor}\n\t\t\t\t/>\n\n\t\t\t\t<ToolbarDivider tokens={tokens} />\n\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Numbered list\"\n\t\t\t\t\tactive={s.isOrderedList}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonClick={() => editor?.chain().focus().toggleOrderedList().run()}\n\t\t\t\t>\n\t\t\t\t\t<ListOrdered />\n\t\t\t\t</ToolbarButton>\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Bullet list\"\n\t\t\t\t\tactive={s.isBulletList}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonClick={() => editor?.chain().focus().toggleBulletList().run()}\n\t\t\t\t>\n\t\t\t\t\t<List />\n\t\t\t\t</ToolbarButton>\n\t\t\t\t<AlignControl\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tvalue={s.align}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonChange={setAlign}\n\t\t\t\t/>\n\n\t\t\t\t<ToolbarDivider tokens={tokens} />\n\n\t\t\t\t<LinkControl\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tactive={s.isLink}\n\t\t\t\t\tcurrentHref={s.linkHref}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonApply={applyLink}\n\t\t\t\t\tonRemove={removeLink}\n\t\t\t\t/>\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Quote\"\n\t\t\t\t\tactive={s.isBlockquote}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonClick={() => editor?.chain().focus().toggleBlockquote().run()}\n\t\t\t\t>\n\t\t\t\t\t<Quote />\n\t\t\t\t</ToolbarButton>\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Code block\"\n\t\t\t\t\tactive={s.isCodeBlock}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonClick={() => editor?.chain().focus().toggleCodeBlock().run()}\n\t\t\t\t>\n\t\t\t\t\t<Code2 />\n\t\t\t\t</ToolbarButton>\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Insert image\"\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\tonClick={insertImage}\n\t\t\t\t>\n\t\t\t\t\t<ImageIcon />\n\t\t\t\t</ToolbarButton>\n\n\t\t\t\t<ToolbarDivider tokens={tokens} />\n\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Undo\"\n\t\t\t\t\tdisabled={disabled || !s.canUndo}\n\t\t\t\t\tonClick={() => editor?.chain().focus().undo().run()}\n\t\t\t\t>\n\t\t\t\t\t<Undo2 />\n\t\t\t\t</ToolbarButton>\n\t\t\t\t<ToolbarButton\n\t\t\t\t\ttokens={tokens}\n\t\t\t\t\tlabel=\"Redo\"\n\t\t\t\t\tdisabled={disabled || !s.canRedo}\n\t\t\t\t\tonClick={() => editor?.chain().focus().redo().run()}\n\t\t\t\t>\n\t\t\t\t\t<Redo2 />\n\t\t\t\t</ToolbarButton>\n\t\t\t</div>\n\n\t\t\t{/* Divider — border-subtle line separating the toolbar from the content */}\n\t\t\t<div className=\"h-px w-full shrink-0 bg-line-subtle\" />\n\n\t\t\t{/* Content area — editable surface */}\n\t\t\t<EditorContent\n\t\t\t\teditor={editor}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"gdt-rich-text min-w-0 flex-1 overflow-y-auto\",\n\t\t\t\t\ttokens.content,\n\t\t\t\t\ttokens.contentPad,\n\t\t\t\t)}\n\t\t\t/>\n\t\t</div>\n\t);\n}\n\nexport { RichTextEditor };\nexport type { RichTextEditorProps };\n","import { Search, X } from \"lucide-react\";\nimport * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport {\n\tInputGroup,\n\tInputGroupAddon,\n\tInputGroupButton,\n\tInputGroupInput,\n} from \"./input-group\";\n\ntype SearchInputVariant = \"dashboard\" | \"app\";\n\ntype SearchInputProps = React.ComponentProps<typeof InputGroupInput> & {\n\twrapperClassName?: string;\n\tonClear?: () => void;\n\tvariant?: SearchInputVariant;\n};\n\nfunction hasValue(value: React.ComponentProps<\"input\">[\"value\"]) {\n\tif (Array.isArray(value)) {\n\t\treturn value.length > 0;\n\t}\n\n\treturn value !== undefined && value !== null && String(value).length > 0;\n}\n\nexport const SearchInput = React.forwardRef<HTMLInputElement, SearchInputProps>(\n\tfunction SearchInput(\n\t\t{\n\t\t\tclassName,\n\t\t\tsize,\n\t\t\tvalue,\n\t\t\tdefaultValue,\n\t\t\twrapperClassName,\n\t\t\tonChange,\n\t\t\tonClear,\n\t\t\tdisabled,\n\t\t\treadOnly,\n\t\t\tvariant = \"dashboard\",\n\t\t\t...props\n\t\t},\n\t\tref,\n\t) {\n\t\tconst inputRef = React.useRef<HTMLInputElement>(null);\n\t\tconst [hasUncontrolledValue, setHasUncontrolledValue] = React.useState(() =>\n\t\t\thasValue(defaultValue),\n\t\t);\n\t\tconst isControlled = value !== undefined;\n\t\tconst showClearButton = isControlled\n\t\t\t? hasValue(value)\n\t\t\t: hasUncontrolledValue;\n\n\t\tReact.useImperativeHandle(ref, () => inputRef.current as HTMLInputElement);\n\n\t\tfunction handleChange(event: React.ChangeEvent<HTMLInputElement>) {\n\t\t\tif (!isControlled) {\n\t\t\t\tsetHasUncontrolledValue(hasValue(event.currentTarget.value));\n\t\t\t}\n\n\t\t\tonChange?.(event);\n\t\t}\n\n\t\tfunction handleClear() {\n\t\t\tconst input = inputRef.current;\n\n\t\t\tif (!input) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst valueSetter = Object.getOwnPropertyDescriptor(\n\t\t\t\twindow.HTMLInputElement.prototype,\n\t\t\t\t\"value\",\n\t\t\t)?.set;\n\n\t\t\tif (valueSetter) {\n\t\t\t\tvalueSetter.call(input, \"\");\n\t\t\t} else {\n\t\t\t\tinput.value = \"\";\n\t\t\t}\n\t\t\tsetHasUncontrolledValue(false);\n\t\t\tinput.dispatchEvent(new Event(\"input\", { bubbles: true }));\n\t\t\tinput.focus();\n\t\t\tonClear?.();\n\t\t}\n\n\t\treturn (\n\t\t\t<InputGroup\n\t\t\t\tsize={size}\n\t\t\t\tclassName={cn(\n\t\t\t\t\tvariant === \"app\" && \"shadow-4 focus-within:shadow-none\",\n\t\t\t\t\twrapperClassName,\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t<InputGroupInput\n\t\t\t\t\tref={inputRef}\n\t\t\t\t\tsize={size}\n\t\t\t\t\tvalue={value}\n\t\t\t\t\tdefaultValue={defaultValue}\n\t\t\t\t\tclassName={className}\n\t\t\t\t\t{...props}\n\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\treadOnly={readOnly}\n\t\t\t\t\tonChange={handleChange}\n\t\t\t\t/>\n\t\t\t\t<InputGroupAddon>\n\t\t\t\t\t<Search />\n\t\t\t\t</InputGroupAddon>\n\t\t\t\t{showClearButton ? (\n\t\t\t\t\t<InputGroupAddon align=\"inline-end\">\n\t\t\t\t\t\t<InputGroupButton\n\t\t\t\t\t\t\taria-label=\"Clear search\"\n\t\t\t\t\t\t\tdisabled={disabled || readOnly}\n\t\t\t\t\t\t\tonClick={handleClear}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<X className=\"size-3\" />\n\t\t\t\t\t\t</InputGroupButton>\n\t\t\t\t\t</InputGroupAddon>\n\t\t\t\t) : null}\n\t\t\t</InputGroup>\n\t\t);\n\t},\n);\n","\"use client\";\n\nimport { Select as SelectPrimitive } from \"@base-ui/react/select\";\nimport { cva } from \"class-variance-authority\";\nimport { CheckIcon, ChevronDownIcon, ChevronUpIcon } from \"lucide-react\";\nimport * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport {\n\ttype ComponentSize,\n\tSizeProvider,\n\tuseComponentSize,\n} from \"./size-context\";\n\nconst SelectSelectionContext = React.createContext({ multiple: false });\n\ntype SelectSize = ComponentSize;\n\nfunction Select<Value, Multiple extends boolean | undefined = false>({\n\tmultiple,\n\tchildren,\n\tsize,\n\t...props\n}: SelectPrimitive.Root.Props<Value, Multiple> & {\n\tsize?: SelectSize;\n}) {\n\treturn (\n\t\t<SizeProvider size={size}>\n\t\t\t<SelectSelectionContext.Provider value={{ multiple: multiple === true }}>\n\t\t\t\t<SelectPrimitive.Root multiple={multiple} {...props}>\n\t\t\t\t\t{children}\n\t\t\t\t</SelectPrimitive.Root>\n\t\t\t</SelectSelectionContext.Provider>\n\t\t</SizeProvider>\n\t);\n}\n\nconst selectTriggerVariants = cva(\n\t\"group/select-trigger flex w-fit min-w-0 items-center justify-between rounded-full border border-line bg-canvas text-left font-normal whitespace-nowrap text-fg-primary shadow-none outline-none transition-[background-color,border-color,border-radius,box-shadow,color] select-none hover:border-line-strong focus-visible:border-line-focus focus-visible:inset-ring-1 focus-visible:inset-ring-line-focus data-focused:border-line-focus data-focused:inset-ring-1 data-focused:inset-ring-line-focus data-popup-open:rounded-2xl data-popup-open:border-line-focus data-popup-open:inset-ring-1 data-popup-open:inset-ring-line-focus disabled:pointer-events-none disabled:cursor-not-allowed disabled:border-line-subtle disabled:bg-surface disabled:text-fg-caption-placeholder data-disabled:pointer-events-none data-disabled:cursor-not-allowed data-disabled:border-line-subtle data-disabled:bg-surface data-disabled:text-fg-caption-placeholder data-placeholder:text-fg-caption-placeholder aria-invalid:border-line-danger aria-invalid:text-fg-danger aria-invalid:shadow-none data-[invalid=true]:border-line-danger data-[invalid=true]:text-fg-danger *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:min-w-0 *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"h-8 gap-2 px-3 text-gdt-xs [&_svg:not([class*='size-'])]:size-3.5\",\n\t\t\t\tmd: \"h-10 gap-2 px-3.5 text-gdt-sm [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\tlg: \"h-12 gap-2.5 px-4 pr-5 text-gdt-md [&_svg:not([class*='size-'])]:size-4.5\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst selectContentVariants = cva(\n\t\"relative isolate z-50 max-h-(--available-height) w-(--anchor-width) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto border border-line-subtle bg-canvas text-fg-primary shadow-(--elevation-e1-shadow) duration-100 data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"rounded-lg p-1\",\n\t\t\t\tmd: \"rounded-xl p-1.5\",\n\t\t\t\tlg: \"rounded-[18px] p-2\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst selectItemVariants = cva(\n\t\"group/select-item relative flex w-full cursor-pointer items-center font-normal text-fg-primary outline-none select-none data-highlighted:bg-surface data-disabled:pointer-events-none data-disabled:text-fg-caption-placeholder [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"gap-1.5 rounded-md px-3 py-1.5 text-gdt-xs\",\n\t\t\t\tmd: \"gap-2 rounded-md px-4 py-2 text-gdt-sm\",\n\t\t\t\tlg: \"gap-2.5 rounded-md px-4 py-2.5 text-gdt-md\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nfunction SelectGroup({ className, ...props }: SelectPrimitive.Group.Props) {\n\treturn (\n\t\t<SelectPrimitive.Group\n\t\t\tdata-slot=\"select-group\"\n\t\t\tclassName={cn(\"scroll-my-1 space-y-0.5\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SelectValue({ className, ...props }: SelectPrimitive.Value.Props) {\n\treturn (\n\t\t<SelectPrimitive.Value\n\t\t\tdata-slot=\"select-value\"\n\t\t\tclassName={cn(\"flex min-w-0 flex-1 text-left\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SelectTrigger({\n\tclassName,\n\tchildren,\n\tunstyled,\n\t...props\n}: SelectPrimitive.Trigger.Props & { unstyled?: boolean }) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<SelectPrimitive.Trigger\n\t\t\tdata-slot=\"select-trigger\"\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(\n\t\t\t\t!unstyled && selectTriggerVariants({ size: resolvedSize }),\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t\t<SelectPrimitive.Icon\n\t\t\t\trender={\n\t\t\t\t\t<ChevronDownIcon className=\"text-line-strong transition-transform group-data-disabled/select-trigger:text-fg-caption-placeholder data-popup-open:rotate-180\" />\n\t\t\t\t}\n\t\t\t/>\n\t\t</SelectPrimitive.Trigger>\n\t);\n}\n\nfunction SelectContent({\n\tclassName,\n\tchildren,\n\tside = \"bottom\",\n\tsideOffset = 8,\n\talign = \"center\",\n\talignOffset = 0,\n\talignItemWithTrigger = false,\n\t...props\n}: SelectPrimitive.Popup.Props &\n\tPick<\n\t\tSelectPrimitive.Positioner.Props,\n\t\t\"align\" | \"alignOffset\" | \"side\" | \"sideOffset\" | \"alignItemWithTrigger\"\n\t>) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<SelectPrimitive.Portal>\n\t\t\t<SelectPrimitive.Positioner\n\t\t\t\tside={side}\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t\talign={align}\n\t\t\t\talignOffset={alignOffset}\n\t\t\t\talignItemWithTrigger={alignItemWithTrigger}\n\t\t\t\tclassName=\"isolate z-50\"\n\t\t\t>\n\t\t\t\t<SelectPrimitive.Popup\n\t\t\t\t\tdata-slot=\"select-content\"\n\t\t\t\t\tdata-align-trigger={alignItemWithTrigger}\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\tselectContentVariants({ size: resolvedSize }),\n\t\t\t\t\t\tclassName,\n\t\t\t\t\t)}\n\t\t\t\t\t{...props}\n\t\t\t\t>\n\t\t\t\t\t<SelectScrollUpButton />\n\t\t\t\t\t<SelectPrimitive.List className=\"space-y-0.5\">\n\t\t\t\t\t\t{children}\n\t\t\t\t\t</SelectPrimitive.List>\n\t\t\t\t\t<SelectScrollDownButton />\n\t\t\t\t</SelectPrimitive.Popup>\n\t\t\t</SelectPrimitive.Positioner>\n\t\t</SelectPrimitive.Portal>\n\t);\n}\n\nfunction SelectLabel({\n\tclassName,\n\t...props\n}: SelectPrimitive.GroupLabel.Props) {\n\treturn (\n\t\t<SelectPrimitive.GroupLabel\n\t\t\tdata-slot=\"select-label\"\n\t\t\tclassName={cn(\"px-3 py-1 text-gdt-xs text-fg-secondary\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SelectItem({\n\tclassName,\n\tchildren,\n\t...props\n}: SelectPrimitive.Item.Props) {\n\tconst { multiple } = React.useContext(SelectSelectionContext);\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<SelectPrimitive.Item\n\t\t\tdata-slot=\"select-item\"\n\t\t\tclassName={cn(\n\t\t\t\tselectItemVariants({ size: resolvedSize }),\n\t\t\t\t!multiple &&\n\t\t\t\t\t\"data-selected:bg-surface-brand-subtle data-selected:font-medium data-selected:text-fg-brand\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{multiple ? (\n\t\t\t\t<SelectPrimitive.ItemIndicator\n\t\t\t\t\tkeepMounted\n\t\t\t\t\tclassName=\"flex size-5 shrink-0 items-center justify-center rounded-sm border border-line bg-canvas text-transparent transition-[background-color,border-color,color] group-data-selected/select-item:border-action-primary group-data-selected/select-item:bg-action-primary group-data-selected/select-item:text-fg-on-brand group-data-disabled/select-item:border-line-subtle group-data-disabled/select-item:bg-surface group-data-disabled/select-item:text-fg-caption-placeholder [&>svg]:size-3\"\n\t\t\t\t>\n\t\t\t\t\t<CheckIcon />\n\t\t\t\t</SelectPrimitive.ItemIndicator>\n\t\t\t) : null}\n\t\t\t<SelectPrimitive.ItemText className=\"flex min-w-0 flex-1 shrink-0 gap-2 whitespace-nowrap\">\n\t\t\t\t{children}\n\t\t\t</SelectPrimitive.ItemText>\n\t\t</SelectPrimitive.Item>\n\t);\n}\n\nfunction SelectSeparator({\n\tclassName,\n\t...props\n}: SelectPrimitive.Separator.Props) {\n\treturn (\n\t\t<SelectPrimitive.Separator\n\t\t\tdata-slot=\"select-separator\"\n\t\t\tclassName={cn(\"pointer-events-none my-1 h-px bg-line-subtle\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SelectScrollUpButton({\n\tclassName,\n\t...props\n}: React.ComponentProps<typeof SelectPrimitive.ScrollUpArrow>) {\n\treturn (\n\t\t<SelectPrimitive.ScrollUpArrow\n\t\t\tdata-slot=\"select-scroll-up-button\"\n\t\t\tclassName={cn(\n\t\t\t\t\"sticky top-0 z-10 flex h-7 w-full cursor-default items-center justify-center bg-canvas text-fg-secondary [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<ChevronUpIcon />\n\t\t</SelectPrimitive.ScrollUpArrow>\n\t);\n}\n\nfunction SelectScrollDownButton({\n\tclassName,\n\t...props\n}: React.ComponentProps<typeof SelectPrimitive.ScrollDownArrow>) {\n\treturn (\n\t\t<SelectPrimitive.ScrollDownArrow\n\t\t\tdata-slot=\"select-scroll-down-button\"\n\t\t\tclassName={cn(\n\t\t\t\t\"sticky bottom-0 z-10 flex h-7 w-full cursor-default items-center justify-center bg-canvas text-fg-secondary [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<ChevronDownIcon />\n\t\t</SelectPrimitive.ScrollDownArrow>\n\t);\n}\n\nexport {\n\tSelect,\n\tSelectContent,\n\tSelectGroup,\n\tSelectItem,\n\tSelectLabel,\n\tSelectScrollDownButton,\n\tSelectScrollUpButton,\n\tSelectSeparator,\n\tSelectTrigger,\n\ttype SelectSize,\n\tSelectValue,\n};\n","\"use client\";\n\nimport { Dialog as SheetPrimitive } from \"@base-ui/react/dialog\";\nimport { cva } from \"class-variance-authority\";\nimport { XIcon } from \"lucide-react\";\nimport type * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\nimport { type ComponentSize, SizeProvider } from \"./size-context\";\n\ntype SheetSide = \"top\" | \"right\" | \"bottom\" | \"left\";\n\nfunction Sheet({ ...props }: SheetPrimitive.Root.Props) {\n\treturn <SheetPrimitive.Root data-slot=\"sheet\" {...props} />;\n}\n\nfunction SheetTrigger({ ...props }: SheetPrimitive.Trigger.Props) {\n\treturn <SheetPrimitive.Trigger data-slot=\"sheet-trigger\" {...props} />;\n}\n\nfunction SheetClose({ ...props }: SheetPrimitive.Close.Props) {\n\treturn <SheetPrimitive.Close data-slot=\"sheet-close\" {...props} />;\n}\n\nfunction SheetPortal({ ...props }: SheetPrimitive.Portal.Props) {\n\treturn <SheetPrimitive.Portal data-slot=\"sheet-portal\" {...props} />;\n}\n\nfunction SheetOverlay({ className, ...props }: SheetPrimitive.Backdrop.Props) {\n\treturn (\n\t\t<SheetPrimitive.Backdrop\n\t\t\tdata-slot=\"sheet-overlay\"\n\t\t\tclassName={cn(\n\t\t\t\t\"fixed inset-0 z-50 bg-black/55 transition-opacity duration-150 data-ending-style:opacity-0 data-starting-style:opacity-0 supports-backdrop-filter:backdrop-blur-xl\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst sheetContentVariants = cva(\n\t\"group/sheet-content fixed z-50 flex flex-col gap-0 overflow-visible rounded-2xl border border-line-subtle bg-surface-overlay bg-clip-padding text-fg-primary shadow-(--elevation-e2-shadow) transition duration-200 ease-in-out data-ending-style:opacity-0 data-starting-style:opacity-0 [--sheet-padding-x:1rem] [--sheet-padding-top:1rem] data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:w-full data-[side=bottom]:rounded-b-none data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:w-full data-[side=top]:rounded-t-none data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:rounded-l-none data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:rounded-r-none data-[side=bottom]:data-ending-style:translate-y-[2.5rem] data-[side=bottom]:data-starting-style:translate-y-[2.5rem] data-[side=left]:data-ending-style:translate-x-[-2.5rem] data-[side=left]:data-starting-style:translate-x-[-2.5rem] data-[side=right]:data-ending-style:translate-x-[2.5rem] data-[side=right]:data-starting-style:translate-x-[2.5rem] data-[side=top]:data-ending-style:translate-y-[-2.5rem] data-[side=top]:data-starting-style:translate-y-[-2.5rem] px-(--sheet-padding-x) **:data-[slot=tabs]:has-data-[variant=underline]:-mx-(--sheet-padding-x) **:has-data-[variant=underline]:*:px-(--sheet-padding-x)\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"sm:[--sheet-padding-top:1.5rem] sm:[--sheet-padding-x:1.5rem] w-90 max-w-[calc(100vw-2.5rem)] [--sheet-title:var(--text-gdt-h5)]\",\n\t\t\t\tmd: \"sm:[--sheet-padding-top:1.5rem] sm:[--sheet-padding-x:2rem] xl:[--sheet-padding-x:2.5rem] w-120 max-w-[calc(100vw-2.5rem)] [--sheet-title:var(--text-gdt-h4)]\",\n\t\t\t\tlg: \"sm:[--sheet-padding-top:1.5rem] sm:[--sheet-padding-x:2rem] xl:[--sheet-padding-x:2.5rem] w-160 max-w-[calc(100vw-2.5rem)] [--sheet-title:var(--text-gdt-h3)]\",\n\t\t\t\tfullscreen:\n\t\t\t\t\t\"sm:[--sheet-padding-top:2rem] sm:[--sheet-padding-x:2.5rem] xl:[--sheet-padding-x:5rem] [--sheet-title:var(--text-gdt-h2)] h-[calc(100lvh-3.5rem)] rounded:xl sm:rounded-2xl\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\ntype SheetContentProps = SheetPrimitive.Popup.Props & {\n\tside?: SheetSide;\n\tshowCloseButton?: boolean;\n} & (\n\t\t| {\n\t\t\t\tside: \"top\" | \"bottom\";\n\t\t\t\tsize?: \"fullscreen\";\n\t\t }\n\t\t| {\n\t\t\t\tside?: \"left\" | \"right\";\n\t\t\t\tsize?: \"sm\" | \"md\" | \"lg\";\n\t\t }\n\t);\n\nfunction SheetContent({\n\tclassName,\n\tchildren,\n\tside = \"left\",\n\tsize = \"md\",\n\tshowCloseButton = true,\n\t...props\n}: SheetContentProps) {\n\tconst resolvedSize =\n\t\tside === \"top\" || side === \"bottom\"\n\t\t\t? \"fullscreen\"\n\t\t\t: size !== \"fullscreen\"\n\t\t\t\t? size\n\t\t\t\t: \"md\";\n\tconst contentSize: ComponentSize =\n\t\tresolvedSize === \"fullscreen\" ? \"lg\" : resolvedSize;\n\n\treturn (\n\t\t<SheetPortal>\n\t\t\t<SheetOverlay />\n\t\t\t<SizeProvider size={contentSize}>\n\t\t\t\t<SheetPrimitive.Popup\n\t\t\t\t\tdata-slot=\"sheet-content\"\n\t\t\t\t\tdata-side={side}\n\t\t\t\t\tdata-size={resolvedSize}\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\tsheetContentVariants({ size: resolvedSize }),\n\t\t\t\t\t\tclassName,\n\t\t\t\t\t)}\n\t\t\t\t\t{...props}\n\t\t\t\t>\n\t\t\t\t\t{children}\n\t\t\t\t\t{showCloseButton && (\n\t\t\t\t\t\t<SheetPrimitive.Close\n\t\t\t\t\t\t\tdata-slot=\"sheet-close\"\n\t\t\t\t\t\t\trender={\n\t\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\t\tvariant=\"ghost\"\n\t\t\t\t\t\t\t\t\tclassName=\"absolute z-10 size-8 border border-line bg-surface p-0 text-fg-primary shadow-(--elevation-e1-shadow) hover:bg-surface-raised group-data-[side=bottom]/sheet-content:-top-10 group-data-[side=bottom]/sheet-content:right-4 group-data-[side=top]/sheet-content:-bottom-10 group-data-[side=top]/sheet-content:right-4 group-data-[side=left]/sheet-content:-right-10 group-data-[side=left]/sheet-content:top-4 group-data-[side=right]/sheet-content:-left-10 group-data-[side=right]/sheet-content:top-4\"\n\t\t\t\t\t\t\t\t\tsize=\"icon-sm\"\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<XIcon />\n\t\t\t\t\t\t\t\t\t<span className=\"sr-only\">Close</span>\n\t\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t\t</SheetPrimitive.Popup>\n\t\t\t</SizeProvider>\n\t\t</SheetPortal>\n\t);\n}\n\nfunction SheetHeader({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"sheet-header\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex flex-col gap-1 -mx-(--sheet-padding-x) px-(--sheet-padding-x) pt-(--sheet-padding-top) pb-4 border-b border-line-subtle group-has-[[data-slot=tabs-list][data-variant=underline]]/sheet-content:border-b-0 group-has-[[data-slot=tabs-list][data-variant=underline]]/sheet-content:pb-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SheetFooter({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"sheet-footer\"\n\t\t\tclassName={cn(\n\t\t\t\t\"mt-auto flex items-center justify-end gap-2 border-t border-line-subtle -mx-(--sheet-padding-x) px-(--sheet-padding-x) py-4\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SheetTitle({ className, ...props }: SheetPrimitive.Title.Props) {\n\treturn (\n\t\t<SheetPrimitive.Title\n\t\t\tdata-slot=\"sheet-title\"\n\t\t\tclassName={cn(\n\t\t\t\t\"font-extrabold text-fg-primary tracking-tight group-data-[size=fullscreen]/sheet-content:text-gdt-h2 group-data-[size=lg]/sheet-content:text-gdt-h3 group-data-[size=md]/sheet-content:text-gdt-h4 group-data-[size=sm]/sheet-content:text-gdt-h5\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SheetDescription({\n\tclassName,\n\t...props\n}: SheetPrimitive.Description.Props) {\n\treturn (\n\t\t<SheetPrimitive.Description\n\t\t\tdata-slot=\"sheet-description\"\n\t\t\tclassName={cn(\n\t\t\t\t\"text-fg-secondary group-data-[size=fullscreen]/sheet-content:text-gdt-lg group-data-[size=lg]/sheet-content:text-gdt-md group-data-[size=md]/sheet-content:text-gdt-sm group-data-[size=sm]/sheet-content:text-gdt-xs\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tSheet,\n\tSheetTrigger,\n\tSheetClose,\n\tSheetContent,\n\tSheetHeader,\n\tSheetFooter,\n\tSheetTitle,\n\tSheetDescription,\n};\n","\"use client\";\n\nimport { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { Menu } from \"lucide-react\";\nimport * as React from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { useIsMobile } from \"../../lib/use-mobile\";\nimport { useUncontrolled } from \"../../lib/use-uncontrolled\";\nimport { Button } from \"./button\";\nimport { Input } from \"./input\";\nimport { Separator } from \"./separator\";\nimport {\n\tSheet,\n\tSheetContent,\n\tSheetDescription,\n\tSheetHeader,\n\tSheetTitle,\n} from \"./sheet\";\nimport { Skeleton } from \"./skeleton\";\nimport { Tooltip, TooltipContent, TooltipTrigger } from \"./tooltip\";\n\nconst SIDEBAR_LS_KEY = \"sidebar_state\";\nconst SIDEBAR_WIDTH = \"17.5rem\";\nconst SIDEBAR_WIDTH_MOBILE = \"17.5rem\";\nconst SIDEBAR_WIDTH_ICON = \"4.5rem\";\nconst SIDEBAR_KEYBOARD_SHORTCUT = \"b\";\n\ntype SidebarContextProps = {\n\tstate: \"expanded\" | \"collapsed\";\n\topen: boolean;\n\tsetOpen: (open: boolean) => void;\n\topenMobile: boolean;\n\tsetOpenMobile: (open: boolean) => void;\n\tisMobile: boolean;\n\ttoggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext<SidebarContextProps | null>(null);\n\nfunction useSidebar() {\n\tconst context = React.useContext(SidebarContext);\n\tif (!context) {\n\t\tthrow new Error(\"useSidebar must be used within a SidebarProvider.\");\n\t}\n\n\treturn context;\n}\n\nfunction SidebarProvider({\n\tdefaultOpen = true,\n\topen: openProp,\n\tonOpenChange: setOpenProp,\n\tclassName,\n\tstyle,\n\tchildren,\n\t...props\n}: React.ComponentProps<\"div\"> & {\n\tdefaultOpen?: boolean;\n\topen?: boolean;\n\tonOpenChange?: (open: boolean) => void;\n}) {\n\tconst isMobile = useIsMobile();\n\tconst [openMobile, setOpenMobile] = React.useState(false);\n\n\tconst [open, setOpen] = useUncontrolled({\n\t\tvalue: openProp,\n\t\tonChange: (open) => {\n\t\t\tsetOpenProp?.(open);\n\t\t\tif (typeof window !== \"undefined\") {\n\t\t\t\twindow.localStorage.setItem(SIDEBAR_LS_KEY, String(open));\n\t\t\t}\n\t\t},\n\t\tdefaultValue: defaultOpen,\n\t});\n\n\tReact.useEffect(() => {\n\t\tif (openProp !== undefined) return;\n\n\t\tconst storedOpen = window.localStorage.getItem(SIDEBAR_LS_KEY);\n\t\tif (storedOpen !== null) {\n\t\t\tsetOpen(storedOpen !== \"false\");\n\t\t}\n\t}, [openProp, setOpen]);\n\n\t// Helper to toggle the sidebar.\n\tconst toggleSidebar = React.useCallback(() => {\n\t\treturn isMobile ? setOpenMobile((open) => !open) : setOpen(!open);\n\t}, [isMobile, open, setOpen]);\n\n\t// Adds a keyboard shortcut to toggle the sidebar.\n\tReact.useEffect(() => {\n\t\tconst handleKeyDown = (event: KeyboardEvent) => {\n\t\t\tif (\n\t\t\t\tevent.key === SIDEBAR_KEYBOARD_SHORTCUT &&\n\t\t\t\t(event.metaKey || event.ctrlKey)\n\t\t\t) {\n\t\t\t\tevent.preventDefault();\n\t\t\t\ttoggleSidebar();\n\t\t\t}\n\t\t};\n\n\t\twindow.addEventListener(\"keydown\", handleKeyDown);\n\t\treturn () => window.removeEventListener(\"keydown\", handleKeyDown);\n\t}, [toggleSidebar]);\n\n\t// We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n\t// This makes it easier to style the sidebar with Tailwind classes.\n\tconst state = open ? \"expanded\" : \"collapsed\";\n\n\tconst contextValue = React.useMemo<SidebarContextProps>(\n\t\t() => ({\n\t\t\tstate,\n\t\t\topen,\n\t\t\tsetOpen,\n\t\t\tisMobile,\n\t\t\topenMobile,\n\t\t\tsetOpenMobile,\n\t\t\ttoggleSidebar,\n\t\t}),\n\t\t[state, open, setOpen, isMobile, openMobile, toggleSidebar],\n\t);\n\n\treturn (\n\t\t<SidebarContext.Provider value={contextValue}>\n\t\t\t<div\n\t\t\t\tdata-slot=\"sidebar-wrapper\"\n\t\t\t\tstyle={\n\t\t\t\t\t{\n\t\t\t\t\t\t\"--layout-nav-width\": SIDEBAR_WIDTH,\n\t\t\t\t\t\t\"--layout-nav-width-icon\": SIDEBAR_WIDTH_ICON,\n\t\t\t\t\t\t...style,\n\t\t\t\t\t} as React.CSSProperties\n\t\t\t\t}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"group/sidebar-wrapper flex min-h-svh w-full has-data-[variant=inset]:bg-surface\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</div>\n\t\t</SidebarContext.Provider>\n\t);\n}\n\nfunction Sidebar({\n\tside = \"left\",\n\tvariant = \"sidebar\",\n\tcollapsible = \"offcanvas\",\n\tclassName,\n\tchildren,\n\tdir,\n\t...props\n}: React.ComponentProps<\"div\"> & {\n\tside?: \"left\" | \"right\";\n\tvariant?: \"sidebar\" | \"floating\" | \"inset\";\n\tcollapsible?: \"offcanvas\" | \"icon\" | \"none\";\n}) {\n\tconst { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n\tif (collapsible === \"none\") {\n\t\treturn (\n\t\t\t<div\n\t\t\t\tdata-slot=\"sidebar\"\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"flex h-full w-(--layout-nav-width) flex-col bg-surface text-fg-secondary\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</div>\n\t\t);\n\t}\n\n\tif (isMobile) {\n\t\treturn (\n\t\t\t<Sheet open={openMobile} onOpenChange={setOpenMobile} {...props}>\n\t\t\t\t<SheetContent\n\t\t\t\t\tdir={dir}\n\t\t\t\t\tdata-sidebar=\"sidebar\"\n\t\t\t\t\tdata-slot=\"sidebar\"\n\t\t\t\t\tdata-mobile=\"true\"\n\t\t\t\t\tclassName=\"min-w-10/12 w-(--layout-nav-width) max-w-screen border-none bg-surface p-0 text-fg-secondary [&>button]:hidden\"\n\t\t\t\t\tstyle={\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\"--layout-nav-width\": SIDEBAR_WIDTH_MOBILE,\n\t\t\t\t\t\t} as React.CSSProperties\n\t\t\t\t\t}\n\t\t\t\t\tside={\"right\"}\n\t\t\t\t>\n\t\t\t\t\t<SheetHeader className=\"sr-only\">\n\t\t\t\t\t\t<SheetTitle>Sidebar</SheetTitle>\n\t\t\t\t\t\t<SheetDescription>Displays the mobile sidebar.</SheetDescription>\n\t\t\t\t\t</SheetHeader>\n\t\t\t\t\t<div className=\"flex h-full w-full flex-col\">{children}</div>\n\t\t\t\t</SheetContent>\n\t\t\t</Sheet>\n\t\t);\n\t}\n\n\treturn (\n\t\t<div\n\t\t\tclassName=\"group peer hidden text-fg-secondary lg:block\"\n\t\t\tdata-state={state}\n\t\t\tdata-collapsible={state === \"collapsed\" ? collapsible : \"\"}\n\t\t\tdata-variant={variant}\n\t\t\tdata-side={side}\n\t\t\tdata-slot=\"sidebar\"\n\t\t>\n\t\t\t{/* This is what handles the sidebar gap on desktop */}\n\t\t\t<div\n\t\t\t\tdata-slot=\"sidebar-gap\"\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"relative w-(--layout-nav-width) bg-transparent transition-[width] duration-200 ease-linear\",\n\t\t\t\t\t\"group-data-[collapsible=offcanvas]:w-0\",\n\t\t\t\t\t\"group-data-[side=right]:rotate-180\",\n\t\t\t\t\tvariant === \"floating\" || variant === \"inset\"\n\t\t\t\t\t\t? \"group-data-[collapsible=icon]:w-[calc(var(--layout-nav-width-icon)+(--spacing(4)))]\"\n\t\t\t\t\t\t: \"group-data-[collapsible=icon]:w-(--layout-nav-width-icon)\",\n\t\t\t\t)}\n\t\t\t/>\n\t\t\t<div\n\t\t\t\tdata-slot=\"sidebar-container\"\n\t\t\t\tdata-side={side}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"fixed inset-y-0 z-10 hidden h-svh w-(--layout-nav-width) transition-[left,right,width] duration-200 ease-linear data-[side=left]:left-0 data-[side=left]:group-data-[collapsible=offcanvas]:left-[calc(var(--layout-nav-width)*-1)] data-[side=right]:right-0 data-[side=right]:group-data-[collapsible=offcanvas]:right-[calc(var(--layout-nav-width)*-1)] lg:flex\",\n\t\t\t\t\t// Adjust the padding for floating and inset variants.\n\t\t\t\t\tvariant === \"floating\" || variant === \"inset\"\n\t\t\t\t\t\t? \"p-2 group-data-[collapsible=icon]:w-[calc(var(--layout-nav-width-icon)+(--spacing(4))+2px)]\"\n\t\t\t\t\t\t: \"group-data-[collapsible=icon]:w-(--layout-nav-width-icon) group-data-[side=left]:border-r group-data-[side=left]:border-r-line-subtle group-data-[side=right]:border-l group-data-[side=right]:border-l-line-subtle\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t<div\n\t\t\t\t\tdata-sidebar=\"sidebar\"\n\t\t\t\t\tdata-slot=\"sidebar-inner\"\n\t\t\t\t\tclassName=\"flex size-full flex-col bg-surface group-data-[variant=floating]:rounded-xl group-data-[variant=floating]:border group-data-[variant=floating]:border-line-subtle group-data-[variant=floating]:shadow-[var(--elevation-e1-shadow)]\"\n\t\t\t\t>\n\t\t\t\t\t{children}\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</div>\n\t);\n}\n\nfunction SidebarTrigger({\n\tclassName,\n\tonClick,\n\t...props\n}: React.ComponentProps<typeof Button>) {\n\tconst { toggleSidebar } = useSidebar();\n\n\treturn (\n\t\t<Button\n\t\t\tdata-sidebar=\"trigger\"\n\t\t\tdata-slot=\"sidebar-trigger\"\n\t\t\tvariant=\"ghost\"\n\t\t\tsize=\"icon-sm\"\n\t\t\tclassName={cn(className)}\n\t\t\tonClick={(event) => {\n\t\t\t\tonClick?.(event);\n\t\t\t\ttoggleSidebar();\n\t\t\t}}\n\t\t\t{...props}\n\t\t>\n\t\t\t<Menu className=\"cn-rtl-flip\" />\n\t\t\t<span className=\"sr-only\">Toggle Sidebar</span>\n\t\t</Button>\n\t);\n}\n\nfunction SidebarRail({ className, ...props }: React.ComponentProps<\"button\">) {\n\tconst { toggleSidebar } = useSidebar();\n\n\treturn (\n\t\t<button\n\t\t\tdata-sidebar=\"rail\"\n\t\t\tdata-slot=\"sidebar-rail\"\n\t\t\taria-label=\"Toggle Sidebar\"\n\t\t\ttabIndex={-1}\n\t\t\tonClick={toggleSidebar}\n\t\t\ttitle=\"Toggle Sidebar\"\n\t\t\tclassName={cn(\n\t\t\t\t\"absolute inset-y-0 z-20 hidden w-4 transition-all ease-linear group-data-[side=left]:-right-4 group-data-[side=right]:left-0 after:absolute after:inset-y-0 after:start-1/2 after:w-[2px] hover:after:bg-line-subtle sm:flex ltr:-translate-x-1/2 rtl:-translate-x-1/2\",\n\t\t\t\t\"in-data-[side=left]:cursor-w-resize in-data-[side=right]:cursor-e-resize\",\n\t\t\t\t\"[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize\",\n\t\t\t\t\"group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full hover:group-data-[collapsible=offcanvas]:bg-surface\",\n\t\t\t\t\"[[data-side=left][data-collapsible=offcanvas]_&]:-right-2\",\n\t\t\t\t\"[[data-side=right][data-collapsible=offcanvas]_&]:-left-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarInset({ className, ...props }: React.ComponentProps<\"main\">) {\n\treturn (\n\t\t<main\n\t\t\tdata-slot=\"sidebar-inset\"\n\t\t\tclassName={cn(\n\t\t\t\t\"relative flex min-w-0 flex-1 flex-col bg-canvas lg:peer-data-[variant=inset]:m-2 lg:peer-data-[variant=inset]:ml-0 lg:peer-data-[variant=inset]:rounded-xl lg:peer-data-[variant=inset]:border lg:peer-data-[variant=inset]:border-line-subtle lg:peer-data-[variant=inset]:shadow-[var(--elevation-e1-shadow)] lg:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarInput({\n\tclassName,\n\t...props\n}: React.ComponentProps<typeof Input>) {\n\treturn (\n\t\t<Input\n\t\t\tdata-slot=\"sidebar-input\"\n\t\t\tdata-sidebar=\"input\"\n\t\t\tclassName={cn(\"h-8 w-full bg-canvas shadow-none\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarHeader({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"sidebar-header\"\n\t\t\tdata-sidebar=\"header\"\n\t\t\tclassName={cn(\"flex flex-col gap-2 p-2\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarFooter({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"sidebar-footer\"\n\t\t\tdata-sidebar=\"footer\"\n\t\t\tclassName={cn(\"flex flex-col gap-2 p-2\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarSeparator({\n\tclassName,\n\t...props\n}: React.ComponentProps<typeof Separator>) {\n\treturn (\n\t\t<Separator\n\t\t\tdata-slot=\"sidebar-separator\"\n\t\t\tdata-sidebar=\"separator\"\n\t\t\tclassName={cn(\"mx-2 w-auto bg-line-subtle\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarContent({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"sidebar-content\"\n\t\t\tdata-sidebar=\"content\"\n\t\t\tclassName={cn(\n\t\t\t\t\"no-scrollbar flex min-h-0 flex-1 flex-col gap-0 overflow-auto group-data-[collapsible=icon]:overflow-hidden\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarGroup({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"sidebar-group\"\n\t\t\tdata-sidebar=\"group\"\n\t\t\tclassName={cn(\"relative flex w-full min-w-0 flex-col p-2\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarGroupLabel({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"div\"> & React.ComponentProps<\"div\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"div\",\n\t\tprops: mergeProps<\"div\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-fg-muted outline-hidden transition-[margin,opacity] duration-200 ease-linear group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0 focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] [&>svg]:size-4 [&>svg]:shrink-0\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tslot: \"sidebar-group-label\",\n\t\t\tsidebar: \"group-label\",\n\t\t},\n\t});\n}\n\nfunction SidebarGroupAction({\n\tclassName,\n\trender,\n\t...props\n}: useRender.ComponentProps<\"button\"> & React.ComponentProps<\"button\">) {\n\treturn useRender({\n\t\tdefaultTagName: \"button\",\n\t\tprops: mergeProps<\"button\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"absolute top-3.5 right-3 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-fg-secondary outline-hidden transition-transform group-data-[collapsible=icon]:hidden after:absolute after:-inset-2 hover:bg-surface-raised hover:text-fg-primary focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] lg:after:hidden [&>svg]:size-4 [&>svg]:shrink-0\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tslot: \"sidebar-group-action\",\n\t\t\tsidebar: \"group-action\",\n\t\t},\n\t});\n}\n\nfunction SidebarGroupContent({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"sidebar-group-content\"\n\t\t\tdata-sidebar=\"group-content\"\n\t\t\tclassName={cn(\"w-full text-sm\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarMenu({ className, ...props }: React.ComponentProps<\"ul\">) {\n\treturn (\n\t\t<ul\n\t\t\tdata-slot=\"sidebar-menu\"\n\t\t\tdata-sidebar=\"menu\"\n\t\t\tclassName={cn(\"flex w-full min-w-0 flex-col gap-0\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarMenuItem({ className, ...props }: React.ComponentProps<\"li\">) {\n\treturn (\n\t\t<li\n\t\t\tdata-slot=\"sidebar-menu-item\"\n\t\t\tdata-sidebar=\"menu-item\"\n\t\t\tclassName={cn(\"group/menu-item relative\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst sidebarMenuButtonVariants = cva(\n\t\"peer/menu-button group/menu-button flex w-full items-center gap-3 overflow-hidden rounded-[10px] px-3 py-3 text-left text-gdt-sm font-semibold text-fg-secondary outline-hidden transition-[width,height,padding,gap,color,background-color] group-has-data-[sidebar=menu-action]/menu-item:pr-8 group-data-[collapsible=icon]:justify-center group-data-[collapsible=icon]:gap-0 group-data-[collapsible=icon]:px-2! group-data-[collapsible=icon]:[&>span]:max-w-0 group-data-[collapsible=icon]:[&>span]:opacity-0 hover:bg-surface-raised hover:text-fg-primary focus-visible:inset-ring-1 inset-ring-line-focus active:bg-surface-raised active:text-fg-primary disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-open:hover:bg-surface-raised data-open:hover:text-fg-primary data-active:bg-surface-brand-subtle data-active:font-medium data-active:text-fg-brand [&_svg]:size-4 [&_svg]:shrink-0 [&_svg]:text-current [&>span]:min-w-0 [&>span]:truncate\",\n\t{\n\t\tvariants: {\n\t\t\tvariant: {\n\t\t\t\tdefault: \"\",\n\t\t\t\toutline:\n\t\t\t\t\t\"bg-canvas text-fg-primary shadow-[inset_0_0_0_1px_var(--color-line-subtle)] hover:bg-surface-raised hover:text-fg-primary\",\n\t\t\t},\n\t\t\tsize: {\n\t\t\t\tmd: \"h-12\",\n\t\t\t\tsm: \"h-9 text-xs\",\n\t\t\t\tlg: \"h-12 group-data-[collapsible=icon]:size-12 group-data-[collapsible=icon]:p-3! [&_svg]:size-5\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tvariant: \"default\",\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nfunction SidebarMenuButton({\n\trender,\n\tisActive = false,\n\tvariant = \"default\",\n\tsize = \"md\",\n\ttooltip,\n\tclassName,\n\t...props\n}: useRender.ComponentProps<\"button\"> &\n\tReact.ComponentProps<\"button\"> & {\n\t\tisActive?: boolean;\n\t\ttooltip?: string | React.ComponentProps<typeof TooltipContent>;\n\t} & VariantProps<typeof sidebarMenuButtonVariants>) {\n\tconst { isMobile, state } = useSidebar();\n\tconst comp = useRender({\n\t\tdefaultTagName: \"button\",\n\t\tprops: mergeProps<\"button\">(\n\t\t\t{\n\t\t\t\tclassName: cn(sidebarMenuButtonVariants({ variant, size }), className),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender: !tooltip ? render : <TooltipTrigger render={render} />,\n\t\tstate: {\n\t\t\tslot: \"sidebar-menu-button\",\n\t\t\tsidebar: \"menu-button\",\n\t\t\tsize,\n\t\t\tactive: isActive,\n\t\t},\n\t});\n\n\tif (!tooltip) {\n\t\treturn comp;\n\t}\n\n\tif (typeof tooltip === \"string\") {\n\t\ttooltip = {\n\t\t\tchildren: tooltip,\n\t\t};\n\t}\n\n\treturn (\n\t\t<Tooltip>\n\t\t\t{comp}\n\t\t\t<TooltipContent\n\t\t\t\tside=\"right\"\n\t\t\t\talign=\"center\"\n\t\t\t\thidden={state !== \"collapsed\" || isMobile}\n\t\t\t\t{...tooltip}\n\t\t\t/>\n\t\t</Tooltip>\n\t);\n}\n\nfunction SidebarMenuAction({\n\tclassName,\n\trender,\n\tshowOnHover = false,\n\t...props\n}: useRender.ComponentProps<\"button\"> &\n\tReact.ComponentProps<\"button\"> & {\n\t\tshowOnHover?: boolean;\n\t}) {\n\treturn useRender({\n\t\tdefaultTagName: \"button\",\n\t\tprops: mergeProps<\"button\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-fg-secondary outline-hidden transition-transform group-data-[collapsible=icon]:hidden peer-hover/menu-button:text-fg-primary peer-data-[size=default]/menu-button:top-1.5 peer-data-[size=lg]/menu-button:top-2.5 peer-data-[size=sm]/menu-button:top-1 after:absolute after:-inset-2 hover:bg-surface-raised hover:text-fg-primary focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] lg:after:hidden [&>svg]:size-4 [&>svg]:shrink-0\",\n\t\t\t\t\tshowOnHover &&\n\t\t\t\t\t\t\"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 peer-data-active/menu-button:text-fg-brand aria-expanded:opacity-100 lg:opacity-0\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tslot: \"sidebar-menu-action\",\n\t\t\tsidebar: \"menu-action\",\n\t\t},\n\t});\n}\n\nfunction SidebarMenuBadge({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"sidebar-menu-badge\"\n\t\t\tdata-sidebar=\"menu-badge\"\n\t\t\tclassName={cn(\n\t\t\t\t\"pointer-events-none absolute right-4 flex h-5 min-w-5 items-center justify-center rounded-full bg-surface-brand px-1 text-gdt-subtext font-bold leading-none text-fg-on-brand tabular-nums select-none group-data-[collapsible=icon]:hidden peer-data-[size=default]/menu-button:top-2.5 peer-data-[size=lg]/menu-button:top-4 peer-data-[size=sm]/menu-button:top-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarMenuSkeleton({\n\tclassName,\n\tshowIcon = false,\n\t...props\n}: React.ComponentProps<\"div\"> & {\n\tshowIcon?: boolean;\n}) {\n\t// Random width between 50 to 90%.\n\tconst [width] = React.useState(() => {\n\t\treturn `${Math.floor(Math.random() * 40) + 50}%`;\n\t});\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"sidebar-menu-skeleton\"\n\t\t\tdata-sidebar=\"menu-skeleton\"\n\t\t\tclassName={cn(\"flex h-8 items-center gap-2 rounded-md px-2\", className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{showIcon && (\n\t\t\t\t<Skeleton\n\t\t\t\t\tclassName=\"size-4 rounded-md\"\n\t\t\t\t\tdata-sidebar=\"menu-skeleton-icon\"\n\t\t\t\t/>\n\t\t\t)}\n\t\t\t<Skeleton\n\t\t\t\tclassName=\"h-4 max-w-(--skeleton-width) flex-1\"\n\t\t\t\tdata-sidebar=\"menu-skeleton-text\"\n\t\t\t\tstyle={\n\t\t\t\t\t{\n\t\t\t\t\t\t\"--skeleton-width\": width,\n\t\t\t\t\t} as React.CSSProperties\n\t\t\t\t}\n\t\t\t/>\n\t\t</div>\n\t);\n}\n\nfunction SidebarMenuSub({ className, ...props }: React.ComponentProps<\"ul\">) {\n\treturn (\n\t\t<ul\n\t\t\tdata-slot=\"sidebar-menu-sub\"\n\t\t\tdata-sidebar=\"menu-sub\"\n\t\t\tclassName={cn(\n\t\t\t\t\"mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-line-subtle px-2.5 py-0.5 group-data-[collapsible=icon]:hidden\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarMenuSubItem({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"li\">) {\n\treturn (\n\t\t<li\n\t\t\tdata-slot=\"sidebar-menu-sub-item\"\n\t\t\tdata-sidebar=\"menu-sub-item\"\n\t\t\tclassName={cn(\"group/menu-sub-item relative\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction SidebarMenuSubButton({\n\trender,\n\tsize = \"md\",\n\tisActive = false,\n\tclassName,\n\t...props\n}: useRender.ComponentProps<\"a\"> &\n\tReact.ComponentProps<\"a\"> & {\n\t\tsize?: \"sm\" | \"md\";\n\t\tisActive?: boolean;\n\t}) {\n\treturn useRender({\n\t\tdefaultTagName: \"a\",\n\t\tprops: mergeProps<\"a\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\t\"flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-fg-secondary outline-hidden group-data-[collapsible=icon]:hidden hover:bg-surface-raised hover:text-fg-primary focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] active:bg-surface-raised active:text-fg-primary disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[size=md]:text-sm data-[size=sm]:text-xs data-active:bg-surface-brand-subtle data-active:text-fg-brand [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-fg-muted\",\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tslot: \"sidebar-menu-sub-button\",\n\t\t\tsidebar: \"menu-sub-button\",\n\t\t\tsize,\n\t\t\tactive: isActive,\n\t\t},\n\t});\n}\n\nexport {\n\tSidebar,\n\tSidebarContent,\n\tSidebarFooter,\n\tSidebarGroup,\n\tSidebarGroupAction,\n\tSidebarGroupContent,\n\tSidebarGroupLabel,\n\tSidebarHeader,\n\tSidebarInput,\n\tSidebarInset,\n\tSidebarMenu,\n\tSidebarMenuAction,\n\tSidebarMenuBadge,\n\tSidebarMenuButton,\n\tSidebarMenuItem,\n\tSidebarMenuSkeleton,\n\tSidebarMenuSub,\n\tSidebarMenuSubButton,\n\tSidebarMenuSubItem,\n\tSidebarProvider,\n\tSidebarRail,\n\tSidebarSeparator,\n\tSidebarTrigger,\n\tuseSidebar,\n};\n","import * as React from \"react\";\n\nconst DEFAULT_MOBILE_BREAKPOINT = 1024;\n\nfunction useIsMobile(breakpoint = DEFAULT_MOBILE_BREAKPOINT) {\n\tconst [isMobile, setIsMobile] = React.useState(false);\n\n\tReact.useEffect(() => {\n\t\tconst mediaQuery = window.matchMedia(`(max-width: ${breakpoint - 1}px)`);\n\t\tconst update = () => setIsMobile(window.innerWidth < breakpoint);\n\n\t\tupdate();\n\t\tmediaQuery.addEventListener(\"change\", update);\n\n\t\treturn () => mediaQuery.removeEventListener(\"change\", update);\n\t}, [breakpoint]);\n\n\treturn isMobile;\n}\n\nexport { DEFAULT_MOBILE_BREAKPOINT, useIsMobile };\n","import { useState } from \"react\";\n\ninterface UseUncontrolledOptions<T> {\n\tvalue?: T;\n\tdefaultValue?: T;\n\tfinalValue?: T;\n\tonChange?: (value: T, ...payload: unknown[]) => void;\n}\n\ntype UseUncontrolledReturnValue<T> = [\n\tT,\n\t(value: T, ...payload: unknown[]) => void,\n\tboolean,\n];\n\nfunction useUncontrolled<T>({\n\tvalue,\n\tdefaultValue,\n\tfinalValue,\n\tonChange = () => {},\n}: UseUncontrolledOptions<T>): UseUncontrolledReturnValue<T> {\n\tconst [uncontrolledValue, setUncontrolledValue] = useState(\n\t\tdefaultValue !== undefined ? defaultValue : finalValue,\n\t);\n\n\tconst handleUncontrolledChange = (nextValue: T, ...payload: unknown[]) => {\n\t\tsetUncontrolledValue(nextValue);\n\t\tonChange?.(nextValue, ...payload);\n\t};\n\n\tif (value !== undefined) {\n\t\treturn [value as T, onChange, true];\n\t}\n\n\treturn [uncontrolledValue as T, handleUncontrolledChange, false];\n}\n\nexport { useUncontrolled };\nexport type { UseUncontrolledOptions, UseUncontrolledReturnValue };\n","\"use client\";\n\nimport { Popover as PopoverPrimitive } from \"@base-ui/react/popover\";\nimport { cn } from \"../../lib/cn\";\n\nfunction Tooltip({ ...props }: PopoverPrimitive.Root.Props) {\n\treturn <PopoverPrimitive.Root data-slot=\"tooltip\" {...props} />;\n}\n\nfunction TooltipTrigger({\n\t...props\n}: Omit<PopoverPrimitive.Trigger.Props, \"openOnHover\">) {\n\treturn (\n\t\t<PopoverPrimitive.Trigger\n\t\t\tnativeButton={false}\n\t\t\tdata-slot=\"tooltip-trigger\"\n\t\t\topenOnHover={true}\n\t\t\tdelay={100}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\ntype TooltipContentProps = PopoverPrimitive.Popup.Props &\n\tPick<\n\t\tPopoverPrimitive.Positioner.Props,\n\t\t\"align\" | \"alignOffset\" | \"side\" | \"sideOffset\"\n\t> & {\n\t\tshowArrow?: boolean;\n\t};\n\nfunction TooltipContent({\n\tclassName,\n\tside = \"top\",\n\tsideOffset = 6,\n\talign = \"center\",\n\talignOffset = 0,\n\tshowArrow = true,\n\tchildren,\n\t...props\n}: TooltipContentProps) {\n\treturn (\n\t\t<PopoverPrimitive.Portal>\n\t\t\t<PopoverPrimitive.Positioner\n\t\t\t\talign={align}\n\t\t\t\talignOffset={alignOffset}\n\t\t\t\tside={side}\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t\tclassName=\"isolate z-50\"\n\t\t\t>\n\t\t\t\t<PopoverPrimitive.Popup\n\t\t\t\t\tdata-slot=\"tooltip-content\"\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"z-50 relative inline-flex w-fit max-w-xs origin-(--transform-origin) items-center gap-1.5 rounded-[6px] border border-line bg-surface-overlay px-3 py-2 text-gdt-sm font-medium text-fg-primary shadow-2 duration-100 has-data-[slot=kbd]:pr-1.5 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95\",\n\t\t\t\t\t\tclassName,\n\t\t\t\t\t)}\n\t\t\t\t\t{...props}\n\t\t\t\t>\n\t\t\t\t\t{children}\n\t\t\t\t\t{showArrow ? (\n\t\t\t\t\t\t<PopoverPrimitive.Arrow className=\"relative block w-3 h-1.5 overflow-clip data-[side=bottom]:top-[-6px] data-[side=left]:right-[-9px] data-[side=left]:rotate-90 data-[side=right]:left-[-9px] data-[side=right]:-rotate-90 data-[side=top]:bottom-[-6px] data-[side=top]:rotate-180 before:content-[''] before:absolute before:bottom-0 before:left-1/2 before:w-[calc(6px*sqrt(2))] before:h-[calc(6px*sqrt(2))] before:bg-surface-overlay before:border before:border-line before:[transform:translate(-50%,50%)_rotate(45deg)]\" />\n\t\t\t\t\t) : null}\n\t\t\t\t</PopoverPrimitive.Popup>\n\t\t\t</PopoverPrimitive.Positioner>\n\t\t</PopoverPrimitive.Portal>\n\t);\n}\n\nexport { Tooltip, TooltipTrigger, TooltipContent };\n","\"use client\";\n\nimport type * as React from \"react\";\nimport {\n\tArea,\n\tAreaChart,\n\tBar,\n\tBarChart,\n\tLine,\n\tLineChart,\n\tXAxis,\n} from \"recharts\";\nimport { cn } from \"../../lib/cn\";\nimport {\n\ttype ChartConfig,\n\tChartContainer,\n\tChartTooltip,\n\tChartTooltipContent,\n\ttype ChartValueType,\n} from \"./chart\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\n/**\n * Small inline trend lines for KPI cards and dense tables — no axes, no\n * gridlines. Composed from recharts plot primitives (`Line`/`Area`/`Bar`) so it\n * shares one charting engine with `line-chart`/`bar-chart` and gets hover\n * tooltips for free via the shared `ChartTooltip`/`ChartTooltipContent`.\n *\n * Sizing follows the same convention as the other charts: `size` sets the height\n * (plus stroke/dot scale) and the width is parent-driven — the component is\n * `w-full`, so constrain it with a wrapper (the SPARKLINE_LAYOUT widths are the\n * recommended container sizes) or let it fill a KPI card.\n *\n * Sentiment colour is driven by the data direction — `status-success` for an\n * upward series, `status-danger` for downward, `text-secondary` for flat — and\n * can be overridden with `trend`. The area fill reuses the line colour at 14 %.\n *\n * Tokens:\n * - Stroke / fill — up: `var(--color-status-success)`, down:\n * `var(--color-status-danger)`, flat: `var(--color-fg-secondary)` (fed through\n * `ChartConfig` as `--color-value`)\n * - Area fill: the same colour at `0.14` opacity\n * - End-point dot ring: `var(--color-surface)` (separates the dot from the line)\n *\n * @example\n * // KPI card trend — colour follows the metric's sentiment automatically\n * <Sparkline data={[40, 44, 42, 55, 58, 62, 70]} type=\"area\" />\n *\n * @example\n * // Interactive — hover tooltip with currency formatting and month captions\n * <Sparkline data={values} tooltip label=\"Revenue\" valueType=\"currency\" labels={months} />\n *\n * @example\n * // Dense table cell — fixed-width wrapper, bar render, no marker\n * <span className=\"inline-block w-[72px]\">\n * <Sparkline data={values} type=\"bar\" size=\"sm\" showMarker={false} />\n * </span>\n */\n\n/** Sparkline sizes line up with the three shared `ComponentSize` values. */\ntype SparklineSize = ComponentSize;\n\n/** Render style for the series. */\ntype SparklineType = \"line\" | \"bar\" | \"area\";\n\n/** Sentiment of the series — drives the stroke/fill colour. */\ntype SparklineTrend = \"up\" | \"down\" | \"flat\";\n\ntype SparklineLayout = {\n\t/** Recommended container width in px (width is parent-driven). */\n\twidth: number;\n\t/** Plot height in px. */\n\theight: number;\n\t/** Line/area stroke width in px. */\n\tstrokeWidth: number;\n\t/** Radius of the end-point dot. */\n\tdotRadius: number;\n\t/** Outer margin — keeps the stroke, peaks, and end dot from clipping. */\n\tmargin: { top: number; right: number; bottom: number; left: number };\n\t/** Corner radius for bars. */\n\tbarRadius: number;\n\t/** Cap on bar thickness so stretched sparklines keep thin bars. */\n\tmaxBarSize: number;\n};\n\nconst SPARKLINE_LAYOUT: Record<SparklineSize, SparklineLayout> = {\n\tsm: {\n\t\twidth: 72,\n\t\theight: 24,\n\t\tstrokeWidth: 1.5,\n\t\tdotRadius: 2,\n\t\tmargin: { top: 4, right: 4, bottom: 2, left: 2 },\n\t\tbarRadius: 1,\n\t\tmaxBarSize: 6,\n\t},\n\tmd: {\n\t\twidth: 104,\n\t\theight: 32,\n\t\tstrokeWidth: 2,\n\t\tdotRadius: 2.5,\n\t\tmargin: { top: 5, right: 5, bottom: 2, left: 2 },\n\t\tbarRadius: 2,\n\t\tmaxBarSize: 8,\n\t},\n\tlg: {\n\t\twidth: 144,\n\t\theight: 44,\n\t\tstrokeWidth: 2,\n\t\tdotRadius: 3,\n\t\tmargin: { top: 6, right: 6, bottom: 3, left: 3 },\n\t\tbarRadius: 2,\n\t\tmaxBarSize: 10,\n\t},\n};\n\nconst TREND_COLOR: Record<SparklineTrend, string> = {\n\tup: \"var(--color-status-success)\",\n\tdown: \"var(--color-status-danger)\",\n\tflat: \"var(--color-fg-secondary)\",\n};\n\n/**\n * Derive sentiment from the series: compare the last value to the first and\n * read flat when the change is a small fraction of the overall range.\n */\nfunction resolveTrend(data: number[]): SparklineTrend {\n\tif (data.length < 2) return \"flat\";\n\tconst first = data[0];\n\tconst last = data[data.length - 1];\n\tconst min = Math.min(...data);\n\tconst max = Math.max(...data);\n\tconst range = max - min || 1;\n\tconst delta = last - first;\n\tif (Math.abs(delta) / range < 0.05) return \"flat\";\n\treturn delta > 0 ? \"up\" : \"down\";\n}\n\n/**\n * Custom dot passed to recharts as `dot={<SparklineEndDot ... />}`. recharts\n * clones it for every point, injecting `cx`/`cy`/`index`; we only paint the\n * latest point so the series carries a single end-point marker.\n */\nfunction SparklineEndDot({\n\tcx,\n\tcy,\n\tindex,\n\tlastIndex,\n\tradius,\n}: {\n\tcx?: number;\n\tcy?: number;\n\tindex?: number;\n\tlastIndex?: number;\n\tradius?: number;\n}) {\n\tif (cx == null || cy == null || index !== lastIndex) {\n\t\treturn null;\n\t}\n\treturn (\n\t\t<circle\n\t\t\tcx={cx}\n\t\t\tcy={cy}\n\t\t\tr={radius}\n\t\t\tfill=\"var(--color-value)\"\n\t\t\tstroke=\"var(--color-surface)\"\n\t\t\tstrokeWidth={2}\n\t\t/>\n\t);\n}\n\n/**\n * Bars do not support `dot`, so the marker is rendered as part of a custom bar\n * shape. Only the latest bar receives the end-point marker.\n */\nfunction SparklineBarShape({\n\tx,\n\ty,\n\twidth,\n\theight,\n\tindex,\n\tvalue,\n\tlastIndex,\n\tradius,\n\tdotRadius,\n}: {\n\tx?: number;\n\ty?: number;\n\twidth?: number;\n\theight?: number;\n\tindex?: number;\n\tvalue?: number;\n\tlastIndex?: number;\n\tradius: number;\n\tdotRadius: number;\n}) {\n\tif (x == null || y == null || width == null || height == null) {\n\t\treturn null;\n\t}\n\n\tconst markerY = typeof value === \"number\" && value < 0 ? y + height : y;\n\n\treturn (\n\t\t<g>\n\t\t\t<rect\n\t\t\t\tx={x}\n\t\t\t\ty={y}\n\t\t\t\twidth={width}\n\t\t\t\theight={height}\n\t\t\t\trx={radius}\n\t\t\t\try={radius}\n\t\t\t\tfill=\"var(--color-value)\"\n\t\t\t/>\n\t\t\t{index === lastIndex ? (\n\t\t\t\t<circle\n\t\t\t\t\tcx={x + width / 2}\n\t\t\t\t\tcy={markerY}\n\t\t\t\t\tr={dotRadius}\n\t\t\t\t\tfill=\"var(--color-value)\"\n\t\t\t\t\tstroke=\"var(--color-surface)\"\n\t\t\t\t\tstrokeWidth={2}\n\t\t\t\t/>\n\t\t\t) : null}\n\t\t</g>\n\t);\n}\n\ntype SparklineDatum = { x: string; value: number };\n\ntype SparklineProps = Omit<\n\tReact.ComponentProps<typeof ChartContainer>,\n\t\"config\" | \"children\"\n> & {\n\t/** The series to plot. Needs at least two points to draw a trend. */\n\tdata: number[];\n\t/** Render style. Defaults to `line`. */\n\ttype?: SparklineType;\n\t/** Explicit size; otherwise inherited from the nearest `SizeProvider`. */\n\tsize?: SparklineSize;\n\t/** Override the auto-detected sentiment colour. */\n\ttrend?: SparklineTrend;\n\t/** Show the filled marker on the latest value. Default true. */\n\tshowMarker?: boolean;\n\t/** Enable the hover tooltip. Default false. */\n\ttooltip?: boolean;\n\t/** Series name shown in the tooltip, e.g. \"Revenue\". */\n\tlabel?: string;\n\t/** Per-point captions for the tooltip (e.g. months). Indexed by data point. */\n\tlabels?: string[];\n\t/** Value formatting for the tooltip. Defaults to `number`. */\n\tvalueType?: ChartValueType;\n};\n\nfunction Sparkline({\n\tdata,\n\ttype = \"line\",\n\tsize,\n\ttrend,\n\tshowMarker = true,\n\ttooltip = false,\n\tlabel = \"Value\",\n\tlabels,\n\tvalueType = \"number\",\n\tclassName,\n\tstyle,\n\t...props\n}: SparklineProps) {\n\tconst layout = SPARKLINE_LAYOUT[useComponentSize(size)];\n\tconst resolvedTrend = trend ?? resolveTrend(data);\n\tconst color = TREND_COLOR[resolvedTrend];\n\n\tconst chartData: SparklineDatum[] = data.map((value, i) => ({\n\t\tx: labels?.[i] ?? `${i + 1}`,\n\t\tvalue,\n\t}));\n\tconst lastIndex = data.length - 1;\n\n\tconst config = {\n\t\tvalue: { label, color },\n\t} satisfies ChartConfig;\n\n\tconst showDot = showMarker && data.length >= 2;\n\tconst endDot = showDot ? (\n\t\t<SparklineEndDot lastIndex={lastIndex} radius={layout.dotRadius} />\n\t) : (\n\t\tfalse\n\t);\n\tconst barShape = showDot ? (\n\t\t<SparklineBarShape\n\t\t\tlastIndex={lastIndex}\n\t\t\tradius={layout.barRadius}\n\t\t\tdotRadius={layout.dotRadius}\n\t\t/>\n\t) : undefined;\n\tconst activeDot = tooltip\n\t\t? {\n\t\t\t\tr: layout.dotRadius + 0.5,\n\t\t\t\tfill: \"var(--color-value)\",\n\t\t\t\tstroke: \"var(--color-surface)\",\n\t\t\t\tstrokeWidth: 2,\n\t\t\t}\n\t\t: false;\n\n\tconst tooltipNode = tooltip ? (\n\t\t<ChartTooltip\n\t\t\tcursor={false}\n\t\t\tcontent={<ChartTooltipContent size=\"xs\" valueType={valueType} />}\n\t\t/>\n\t) : null;\n\n\tconst ariaLabel =\n\t\t(props[\"aria-label\"] as string | undefined) ??\n\t\t`${label} sparkline, trend ${resolvedTrend}`;\n\n\tif (data.length < 2) {\n\t\treturn (\n\t\t\t<div\n\t\t\t\t{...props}\n\t\t\t\taria-label={ariaLabel}\n\t\t\t\trole=\"img\"\n\t\t\t\tclassName={cn(\"w-full\", className)}\n\t\t\t\tstyle={{ height: layout.height, ...style }}\n\t\t\t/>\n\t\t);\n\t}\n\n\treturn (\n\t\t<ChartContainer\n\t\t\t{...props}\n\t\t\taria-label={ariaLabel}\n\t\t\trole=\"img\"\n\t\t\tconfig={config}\n\t\t\tclassName={cn(\"aspect-auto w-full\", className)}\n\t\t\tstyle={{ height: layout.height, ...style }}\n\t\t>\n\t\t\t{type === \"bar\" ? (\n\t\t\t\t<BarChart accessibilityLayer data={chartData} margin={layout.margin}>\n\t\t\t\t\t{tooltipNode}\n\t\t\t\t\t<Bar\n\t\t\t\t\t\tdataKey=\"value\"\n\t\t\t\t\t\tfill=\"var(--color-value)\"\n\t\t\t\t\t\tradius={layout.barRadius}\n\t\t\t\t\t\tmaxBarSize={layout.maxBarSize}\n\t\t\t\t\t\tshape={barShape}\n\t\t\t\t\t\tisAnimationActive={false}\n\t\t\t\t\t/>\n\t\t\t\t</BarChart>\n\t\t\t) : type === \"area\" ? (\n\t\t\t\t<AreaChart accessibilityLayer data={chartData} margin={layout.margin}>\n\t\t\t\t\t{tooltip ? <XAxis dataKey=\"x\" hide /> : null}\n\t\t\t\t\t{tooltipNode}\n\t\t\t\t\t<Area\n\t\t\t\t\t\ttype=\"monotone\"\n\t\t\t\t\t\tdataKey=\"value\"\n\t\t\t\t\t\tstroke=\"var(--color-value)\"\n\t\t\t\t\t\tstrokeWidth={layout.strokeWidth}\n\t\t\t\t\t\tstrokeLinejoin=\"round\"\n\t\t\t\t\t\tstrokeLinecap=\"round\"\n\t\t\t\t\t\tfill=\"var(--color-value)\"\n\t\t\t\t\t\tfillOpacity={0.14}\n\t\t\t\t\t\tdot={endDot}\n\t\t\t\t\t\tactiveDot={activeDot}\n\t\t\t\t\t\tisAnimationActive={false}\n\t\t\t\t\t/>\n\t\t\t\t</AreaChart>\n\t\t\t) : (\n\t\t\t\t<LineChart accessibilityLayer data={chartData} margin={layout.margin}>\n\t\t\t\t\t{tooltip ? <XAxis dataKey=\"x\" hide /> : null}\n\t\t\t\t\t{tooltipNode}\n\t\t\t\t\t<Line\n\t\t\t\t\t\ttype=\"monotone\"\n\t\t\t\t\t\tdataKey=\"value\"\n\t\t\t\t\t\tstroke=\"var(--color-value)\"\n\t\t\t\t\t\tstrokeWidth={layout.strokeWidth}\n\t\t\t\t\t\tstrokeLinejoin=\"round\"\n\t\t\t\t\t\tstrokeLinecap=\"round\"\n\t\t\t\t\t\tdot={endDot}\n\t\t\t\t\t\tactiveDot={activeDot}\n\t\t\t\t\t\tisAnimationActive={false}\n\t\t\t\t\t/>\n\t\t\t\t</LineChart>\n\t\t\t)}\n\t\t</ChartContainer>\n\t);\n}\n\nexport { Sparkline, SPARKLINE_LAYOUT };\nexport type { SparklineProps, SparklineSize, SparklineTrend, SparklineType };\n","import { cva, type VariantProps } from \"class-variance-authority\";\nimport { CheckIcon } from \"lucide-react\";\nimport * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\n\ntype StepperOrientation = \"horizontal\" | \"vertical\";\ntype StepperState = \"complete\" | \"active\" | \"upcoming\";\n\ntype StepperContextValue = {\n\torientation: StepperOrientation;\n\t/** Active step number (1-based). Steps derive their state from this. */\n\tvalue?: number;\n};\n\nconst StepperContext = React.createContext<StepperContextValue | null>(null);\n\nfunction useStepper() {\n\tconst context = React.useContext(StepperContext);\n\n\tif (!context) {\n\t\tthrow new Error(\"Stepper parts must be used within a <Stepper />\");\n\t}\n\n\treturn context;\n}\n\ntype StepperItemContextValue = {\n\tstate: StepperState;\n\t/** 1-based position of this step in the stepper. */\n\tstep: number;\n};\n\nconst StepperItemContext = React.createContext<StepperItemContextValue | null>(\n\tnull,\n);\n\nfunction useStepperItem() {\n\tconst context = React.useContext(StepperItemContext);\n\n\tif (!context) {\n\t\tthrow new Error(\"Stepper item parts must be used within a <StepperItem />\");\n\t}\n\n\treturn context;\n}\n\nfunction resolveState(\n\tstep: number,\n\tvalue: number | undefined,\n\toverride: StepperState | undefined,\n): StepperState {\n\tif (override) return override;\n\tif (value == null) return \"upcoming\";\n\tif (step < value) return \"complete\";\n\tif (step === value) return \"active\";\n\treturn \"upcoming\";\n}\n\ntype StepperProps = React.ComponentProps<\"div\"> & {\n\torientation?: StepperOrientation;\n\t/** Active step number (1-based). Items without an explicit `state` derive theirs from this. */\n\tvalue?: number;\n};\n\nfunction Stepper({\n\torientation = \"horizontal\",\n\tvalue,\n\tclassName,\n\tchildren,\n\t...props\n}: StepperProps) {\n\tconst items = React.Children.toArray(children).filter(React.isValidElement);\n\n\tconst contextValue = React.useMemo<StepperContextValue>(\n\t\t() => ({ orientation, value }),\n\t\t[orientation, value],\n\t);\n\n\treturn (\n\t\t<StepperContext.Provider value={contextValue}>\n\t\t\t<div\n\t\t\t\tdata-slot=\"stepper\"\n\t\t\t\tdata-orientation={orientation}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"flex\",\n\t\t\t\t\torientation === \"horizontal\" ? \"flex-row\" : \"flex-col\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{items.map((child, index) => {\n\t\t\t\t\tif (!React.isValidElement<StepperItemProps>(child)) return child;\n\n\t\t\t\t\treturn React.cloneElement(child, {\n\t\t\t\t\t\tstep: child.props.step ?? index + 1,\n\t\t\t\t\t\tlast: child.props.last ?? index === items.length - 1,\n\t\t\t\t\t});\n\t\t\t\t})}\n\t\t\t</div>\n\t\t</StepperContext.Provider>\n\t);\n}\n\ntype StepperItemProps = Omit<React.ComponentProps<\"div\">, \"children\"> & {\n\t/** Force a specific state instead of deriving it from the stepper `value`. */\n\tstate?: StepperState;\n\t/** 1-based position. Injected by `Stepper`; only set this to override. */\n\tstep?: number;\n\t/** Whether this is the last item (hides its connector). Injected by `Stepper`. */\n\tlast?: boolean;\n\t/** Custom indicator node. Defaults to a numbered circle / checkmark. */\n\tindicator?: React.ReactNode;\n\tchildren?: React.ReactNode;\n};\n\nfunction StepperItem({\n\tstate: stateOverride,\n\tstep = 1,\n\tlast = false,\n\tindicator,\n\tclassName,\n\tchildren,\n\t...props\n}: StepperItemProps) {\n\tconst { orientation, value } = useStepper();\n\tconst state = resolveState(step, value, stateOverride);\n\n\tconst itemContext = React.useMemo<StepperItemContextValue>(\n\t\t() => ({ state, step }),\n\t\t[state, step],\n\t);\n\n\treturn (\n\t\t<StepperItemContext.Provider value={itemContext}>\n\t\t\t<div\n\t\t\t\tdata-slot=\"stepper-item\"\n\t\t\t\tdata-state={state}\n\t\t\t\tdata-orientation={orientation}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"group/stepper-item flex min-w-0\",\n\t\t\t\t\torientation === \"horizontal\"\n\t\t\t\t\t\t? \"flex-1 flex-col gap-3 last:flex-none\"\n\t\t\t\t\t\t: \"flex-row items-stretch gap-3\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t<div\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"flex\",\n\t\t\t\t\t\torientation === \"horizontal\"\n\t\t\t\t\t\t\t? \"items-center\"\n\t\t\t\t\t\t\t: \"flex-col items-center\",\n\t\t\t\t\t)}\n\t\t\t\t>\n\t\t\t\t\t{indicator ?? <StepperIndicator />}\n\t\t\t\t\t{!last && <StepperSeparator />}\n\t\t\t\t</div>\n\n\t\t\t\t{children != null && (\n\t\t\t\t\t<div\n\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\"flex min-w-0 flex-col gap-1\",\n\t\t\t\t\t\t\torientation === \"horizontal\"\n\t\t\t\t\t\t\t\t? \"pr-4\"\n\t\t\t\t\t\t\t\t: cn(\"pt-1\", !last && \"pb-8\"),\n\t\t\t\t\t\t)}\n\t\t\t\t\t>\n\t\t\t\t\t\t{children}\n\t\t\t\t\t</div>\n\t\t\t\t)}\n\t\t\t</div>\n\t\t</StepperItemContext.Provider>\n\t);\n}\n\nconst indicatorVariants = cva(\n\t\"relative flex size-7 shrink-0 items-center justify-center rounded-full text-gdt-sm font-semibold transition-colors sm:size-9\",\n\t{\n\t\tvariants: {\n\t\t\tstate: {\n\t\t\t\tcomplete:\n\t\t\t\t\t\"border border-transparent bg-action-primary text-fg-on-brand\",\n\t\t\t\tactive: \"border-2 border-line-focus bg-canvas text-fg-brand\",\n\t\t\t\tupcoming: \"border border-line bg-surface text-fg-secondary\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tstate: \"upcoming\",\n\t\t},\n\t},\n);\n\ntype StepperIndicatorProps = Omit<React.ComponentProps<\"div\">, \"children\"> &\n\tVariantProps<typeof indicatorVariants> & {\n\t\t/** Override the rendered glyph. Defaults to the step number / checkmark. */\n\t\tchildren?: React.ReactNode;\n\t};\n\nfunction StepperIndicator({\n\tclassName,\n\tstate: stateProp,\n\tchildren,\n\t...props\n}: StepperIndicatorProps) {\n\tconst { state, step } = useStepperItem();\n\tconst resolved = stateProp ?? state;\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"stepper-indicator\"\n\t\t\tdata-state={resolved}\n\t\t\tclassName={cn(indicatorVariants({ state: resolved }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children ??\n\t\t\t\t(resolved === \"complete\" ? (\n\t\t\t\t\t<CheckIcon className=\"size-4 sm:size-4.5\" strokeWidth={2.5} />\n\t\t\t\t) : (\n\t\t\t\t\tstep\n\t\t\t\t))}\n\t\t</div>\n\t);\n}\n\nconst separatorVariants = cva(\"shrink-0 rounded-full transition-colors\", {\n\tvariants: {\n\t\tstate: {\n\t\t\tcomplete: \"bg-action-primary\",\n\t\t\tactive: \"bg-line\",\n\t\t\tupcoming: \"bg-line\",\n\t\t},\n\t\torientation: {\n\t\t\thorizontal: \"h-0.5 flex-1\",\n\t\t\tvertical: \"w-0.5 flex-1 min-h-8\",\n\t\t},\n\t},\n\tdefaultVariants: {\n\t\tstate: \"upcoming\",\n\t\torientation: \"horizontal\",\n\t},\n});\n\nfunction StepperSeparator({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"div\">) {\n\tconst { orientation } = useStepper();\n\tconst { state } = useStepperItem();\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"stepper-separator\"\n\t\t\taria-hidden=\"true\"\n\t\t\tclassName={cn(separatorVariants({ state, orientation }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst titleVariants = cva(\"text-gdt-sm font-bold\", {\n\tvariants: {\n\t\tstate: {\n\t\t\tcomplete: \"text-fg-primary\",\n\t\t\tactive: \"text-fg-brand\",\n\t\t\tupcoming: \"text-fg-secondary\",\n\t\t},\n\t},\n\tdefaultVariants: {\n\t\tstate: \"upcoming\",\n\t},\n});\n\nfunction StepperTitle({ className, ...props }: React.ComponentProps<\"p\">) {\n\tconst { state } = useStepperItem();\n\n\treturn (\n\t\t<p\n\t\t\tdata-slot=\"stepper-title\"\n\t\t\tclassName={cn(titleVariants({ state }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst descriptionVariants = cva(\"text-gdt-sm\", {\n\tvariants: {\n\t\tstate: {\n\t\t\tcomplete: \"text-fg-secondary\",\n\t\t\tactive: \"text-fg-secondary\",\n\t\t\tupcoming: \"text-fg-caption-placeholder\",\n\t\t},\n\t},\n\tdefaultVariants: {\n\t\tstate: \"upcoming\",\n\t},\n});\n\nfunction StepperDescription({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"p\">) {\n\tconst { state } = useStepperItem();\n\n\treturn (\n\t\t<p\n\t\t\tdata-slot=\"stepper-description\"\n\t\t\tclassName={cn(descriptionVariants({ state }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\ntype StepperMetaProps = Omit<React.ComponentProps<\"div\">, \"children\"> & {\n\tdate?: React.ReactNode;\n\ttime?: React.ReactNode;\n};\n\n/** Date / timestamp caption pair. Placeholder colour regardless of state. */\nfunction StepperMeta({ date, time, className, ...props }: StepperMetaProps) {\n\tif (date == null && time == null) return null;\n\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"stepper-meta\"\n\t\t\tclassName={cn(\n\t\t\t\t\"flex flex-wrap items-center gap-x-2 gap-y-0.5 text-gdt-xs text-fg-caption-placeholder\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{date != null && <span>{date}</span>}\n\t\t\t{time != null && <span>{time}</span>}\n\t\t</div>\n\t);\n}\n\nexport {\n\tStepper,\n\tStepperItem,\n\tStepperIndicator,\n\tStepperSeparator,\n\tStepperTitle,\n\tStepperDescription,\n\tStepperMeta,\n\ttype StepperOrientation,\n\ttype StepperState,\n};\n","\"use client\";\n\nimport { Switch as SwitchPrimitive } from \"@base-ui/react/switch\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\n\nimport { cn } from \"../../lib/cn\";\nimport { useComponentSize } from \"./size-context\";\n\nconst switchVariants = cva(\n\t\"peer group/switch relative inline-flex shrink-0 items-center rounded-full border bg-clip-padding p-0.5 transition-[background-color,border-color,box-shadow,opacity] outline-none after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] aria-invalid:border-line-danger aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-checked:border-action-primary data-checked:bg-action-primary data-unchecked:border-line data-unchecked:bg-transparent data-[loading=true]:border-action-primary data-[loading=true]:bg-action-primary data-disabled:border-line-subtle! data-disabled:bg-transparent! data-disabled:cursor-not-allowed data-disabled:opacity-60 h-6 w-10 [--switch-spinner-size:0.75rem] [--switch-thumb-size:18px] [--switch-track-width:2.5rem] group-data-[size=sm]/field:h-5 group-data-[size=sm]/field:w-8 group-data-[size=sm]/field:[--switch-spinner-size:0.625rem] group-data-[size=sm]/field:[--switch-thumb-size:14px] group-data-[size=sm]/field:[--switch-track-width:2rem] group-data-[size=md]/field:h-6 group-data-[size=md]/field:w-10 group-data-[size=md]/field:[--switch-spinner-size:0.75rem] group-data-[size=md]/field:[--switch-thumb-size:18px] group-data-[size=md]/field:[--switch-track-width:2.5rem] group-data-[size=lg]/field:h-7 group-data-[size=lg]/field:w-12 group-data-[size=lg]/field:[--switch-spinner-size:0.875rem] group-data-[size=lg]/field:[--switch-thumb-size:22px] group-data-[size=lg]/field:[--switch-track-width:3rem]\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"h-5 w-8 [--switch-spinner-size:0.625rem] [--switch-thumb-size:14px] [--switch-track-width:2rem]\",\n\t\t\t\tmd: \"h-6 w-10 [--switch-spinner-size:0.75rem] [--switch-thumb-size:18px] [--switch-track-width:2.5rem]\",\n\t\t\t\tlg: \"h-7 w-12 [--switch-spinner-size:0.875rem] [--switch-thumb-size:22px] [--switch-track-width:3rem]\",\n\t\t\t},\n\t\t},\n\t},\n);\n\ntype SwitchSize = NonNullable<VariantProps<typeof switchVariants>[\"size\"]>;\ntype SwitchProps = Omit<SwitchPrimitive.Root.Props, \"children\"> & {\n\tloading?: boolean;\n\tsize?: SwitchSize;\n};\n\n/**\n * Compose with the shared field primitives for label and helper text.\n *\n * ```tsx\n * <Field orientation=\"horizontal\" size=\"sm\">\n * <Switch id=\"notifications\" />\n * <FieldContent>\n * <FieldLabel htmlFor=\"notifications\">Notifications</FieldLabel>\n * <FieldDescription>Receive product update emails.</FieldDescription>\n * </FieldContent>\n * </Field>\n * ```\n */\nfunction Switch({\n\tclassName,\n\tdisabled = false,\n\tloading = false,\n\treadOnly = false,\n\tsize,\n\t...props\n}: SwitchProps) {\n\tconst resolvedSize = useComponentSize(size);\n\tconst isDisabled = disabled;\n\tconst isReadOnly = readOnly || loading;\n\n\treturn (\n\t\t<SwitchPrimitive.Root\n\t\t\taria-busy={loading || undefined}\n\t\t\tdata-slot=\"switch\"\n\t\t\tdata-loading={loading}\n\t\t\tdata-size={resolvedSize}\n\t\t\tdisabled={isDisabled}\n\t\t\treadOnly={isReadOnly}\n\t\t\tclassName={cn(switchVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<SwitchPrimitive.Thumb\n\t\t\t\tdata-slot=\"switch-thumb\"\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"pointer-events-none grid size-(--switch-thumb-size) translate-x-0 place-items-center rounded-full bg-fg-on-brand text-fg-brand ring-0 transition-transform duration-200 ease-out data-checked:translate-x-[calc(var(--switch-track-width)-var(--switch-thumb-size)-4px)]\",\n\t\t\t\t\tloading &&\n\t\t\t\t\t\t\"translate-x-[calc(var(--switch-track-width)-var(--switch-thumb-size)-4px)]\",\n\t\t\t\t\tisDisabled && \"translate-x-0! bg-line text-fg-caption-placeholder\",\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t{loading && !isDisabled && (\n\t\t\t\t\t<span\n\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\tdata-slot=\"switch-spinner\"\n\t\t\t\t\t\tclassName=\"size-(--switch-spinner-size) animate-spin rounded-full border-2 border-current border-r-transparent\"\n\t\t\t\t\t/>\n\t\t\t\t)}\n\t\t\t</SwitchPrimitive.Thumb>\n\t\t</SwitchPrimitive.Root>\n\t);\n}\n\nexport { Switch, switchVariants };\n","\"use client\";\n\nimport type { Tabs as TabsPrimitive } from \"@base-ui/react/tabs\";\nimport { ChevronDownIcon } from \"lucide-react\";\nimport { useState } from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { useIsMobile } from \"../../lib/use-mobile\";\nimport {\n\tDropdownMenu,\n\tDropdownMenuContent,\n\tDropdownMenuItem,\n\tDropdownMenuTrigger,\n} from \"./dropdown-menu\";\nimport { Tabs, TabsCount, TabsList, TabsTrigger } from \"./tabs\";\n\ntype TabsListVariant = \"default\" | \"line\" | \"secondary\" | \"underline\";\n\ntype TabListItem = {\n\t/** Stable value used to match the active tab. */\n\tvalue: string;\n\t/** Visible label. */\n\tlabel: React.ReactNode;\n\t/** Optional count badge rendered after the label. */\n\tcount?: number;\n\tdisabled?: boolean;\n\t/**\n\t * Optional element to render the trigger as (e.g. a router `<Link>`).\n\t * Used for both the in-bar tab and its overflow menu item.\n\t */\n\trender?: React.ReactElement;\n};\n\ntype TabListProps = Omit<\n\tTabsPrimitive.Root.Props,\n\t\"children\" | \"value\" | \"defaultValue\" | \"onValueChange\"\n> & {\n\titems: TabListItem[];\n\tvalue?: string;\n\tdefaultValue?: string;\n\tonValueChange?: (value: string) => void;\n\tvariant?: TabsListVariant;\n\t/** Max tabs shown inline on small screens before collapsing into \"More\". */\n\tmaxVisibleMobile?: number;\n\t/** Max tabs shown inline on larger screens before collapsing into \"More\". */\n\tmaxVisibleDesktop?: number;\n\t/** Label for the overflow trigger. */\n\tmoreLabel?: React.ReactNode;\n\tclassName?: string;\n\tlistClassName?: string;\n\t/** Tab panels (`TabsContent`) to render under the bar. */\n\tchildren?: React.ReactNode;\n};\n\nfunction TabList({\n\titems,\n\tvalue,\n\tdefaultValue,\n\tonValueChange,\n\tvariant = \"line\",\n\tmaxVisibleMobile = 2,\n\tmaxVisibleDesktop = 4,\n\tmoreLabel = \"More\",\n\tclassName,\n\tlistClassName,\n\tchildren,\n\t...rootProps\n}: TabListProps) {\n\tconst isMobile = useIsMobile();\n\tconst [internalValue, setInternalValue] = useState(\n\t\tvalue ?? defaultValue ?? items[0]?.value,\n\t);\n\n\tconst currentValue = value ?? internalValue;\n\n\tconst selectValue = (next: string) => {\n\t\tif (value === undefined) setInternalValue(next);\n\t\tonValueChange?.(next);\n\t};\n\n\tconst maxVisible = isMobile ? maxVisibleMobile : maxVisibleDesktop;\n\tconst visibleItems = items.slice(0, maxVisible);\n\tconst overflowItems = items.slice(maxVisible);\n\tconst isOverflowActive = overflowItems.some(\n\t\t(item) => item.value === currentValue,\n\t);\n\n\treturn (\n\t\t<Tabs\n\t\t\tvalue={currentValue}\n\t\t\tonValueChange={(next) => selectValue(next as string)}\n\t\t\tclassName={className}\n\t\t\t{...rootProps}\n\t\t>\n\t\t\t<TabsList variant={variant} className={listClassName}>\n\t\t\t\t{visibleItems.map((item) => (\n\t\t\t\t\t<TabsTrigger\n\t\t\t\t\t\tkey={item.value}\n\t\t\t\t\t\tvalue={item.value}\n\t\t\t\t\t\tdisabled={item.disabled}\n\t\t\t\t\t\tnativeButton={item.render ? false : undefined}\n\t\t\t\t\t\trender={item.render}\n\t\t\t\t\t>\n\t\t\t\t\t\t{item.label}\n\t\t\t\t\t\t{item.count != null && <TabsCount>{item.count}</TabsCount>}\n\t\t\t\t\t</TabsTrigger>\n\t\t\t\t))}\n\n\t\t\t\t{overflowItems.length > 0 && (\n\t\t\t\t\t<DropdownMenu>\n\t\t\t\t\t\t<DropdownMenuTrigger\n\t\t\t\t\t\t\trender={\n\t\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\t\t\tdata-active={isOverflowActive || undefined}\n\t\t\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\t\t\"group/tab-list-more relative inline-flex shrink-0 items-center justify-center gap-1.5 whitespace-nowrap border border-transparent px-4 py-3 text-gdt-md font-semibold text-fg-secondary outline-none transition-colors hover:text-fg-primary focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] data-active:text-fg-primary max-sm:px-3 max-sm:py-2.5 max-sm:text-gdt-sm\",\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{moreLabel}\n\t\t\t\t\t\t\t<ChevronDownIcon className=\"size-4 transition-transform duration-200 group-data-[popup-open]/tab-list-more:rotate-180\" />\n\t\t\t\t\t\t</DropdownMenuTrigger>\n\t\t\t\t\t\t<DropdownMenuContent align=\"end\">\n\t\t\t\t\t\t\t{overflowItems.map((item) => (\n\t\t\t\t\t\t\t\t<DropdownMenuItem\n\t\t\t\t\t\t\t\t\tkey={item.value}\n\t\t\t\t\t\t\t\t\tdisabled={item.disabled}\n\t\t\t\t\t\t\t\t\tdata-active={item.value === currentValue || undefined}\n\t\t\t\t\t\t\t\t\tclassName=\"justify-between gap-3 data-active:text-fg-brand\"\n\t\t\t\t\t\t\t\t\trender={item.render}\n\t\t\t\t\t\t\t\t\tonClick={() => selectValue(item.value)}\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t{item.label}\n\t\t\t\t\t\t\t\t\t{item.count != null && (\n\t\t\t\t\t\t\t\t\t\t<span className=\"ml-auto inline-flex min-w-5 items-center justify-center rounded-full bg-surface-raised px-1.5 py-0.5 text-[11px] leading-none font-semibold text-fg-secondary\">\n\t\t\t\t\t\t\t\t\t\t\t{item.count}\n\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t</DropdownMenuItem>\n\t\t\t\t\t\t\t))}\n\t\t\t\t\t\t</DropdownMenuContent>\n\t\t\t\t\t</DropdownMenu>\n\t\t\t\t)}\n\t\t\t</TabsList>\n\n\t\t\t{children}\n\t\t</Tabs>\n\t);\n}\n\nexport { TabList, type TabListItem };\n","\"use client\";\n\nimport { Tabs as TabsPrimitive } from \"@base-ui/react/tabs\";\nimport { cva } from \"class-variance-authority\";\nimport type { ComponentPropsWithoutRef } from \"react\";\n\nimport { cn } from \"../../lib/cn\";\n\ntype TabsListVariant = \"default\" | \"line\" | \"secondary\" | \"underline\";\n\nfunction resolveTabsListVariant(variant: TabsListVariant) {\n\treturn variant === \"default\"\n\t\t? \"secondary\"\n\t\t: variant === \"line\"\n\t\t\t? \"underline\"\n\t\t\t: variant;\n}\n\nfunction Tabs({\n\tclassName,\n\torientation = \"horizontal\",\n\t...props\n}: TabsPrimitive.Root.Props) {\n\treturn (\n\t\t<TabsPrimitive.Root\n\t\t\tdata-slot=\"tabs\"\n\t\t\tdata-orientation={orientation}\n\t\t\tclassName={cn(\n\t\t\t\t\"group/tabs flex gap-3 data-[orientation=horizontal]:flex-col\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst tabsListVariants = cva(\n\t\"group/tabs-list relative inline-flex w-fit shrink-0 items-center gap-1 text-fg-secondary group-data-[orientation=horizontal]/tabs:border-b group-data-[orientation=horizontal]/tabs:border-line-subtle group-data-[orientation=vertical]/tabs:flex-col group-data-[orientation=vertical]/tabs:border-l group-data-[orientation=vertical]/tabs:border-line-subtle\",\n\t{\n\t\tvariants: {\n\t\t\tvariant: {\n\t\t\t\tunderline: \"rounded-none bg-transparent p-0\",\n\t\t\t\tsecondary: \"rounded-4xl bg-transparent p-0\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tvariant: \"underline\",\n\t\t},\n\t},\n);\n\nfunction TabsList({\n\tclassName,\n\tvariant = \"underline\",\n\tchildren,\n\t...props\n}: TabsPrimitive.List.Props & {\n\tvariant?: TabsListVariant;\n}) {\n\tconst resolvedVariant = resolveTabsListVariant(variant);\n\n\treturn (\n\t\t<TabsPrimitive.List\n\t\t\tdata-slot=\"tabs-list\"\n\t\t\tdata-variant={resolvedVariant}\n\t\t\tclassName={cn(tabsListVariants({ variant: resolvedVariant }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t\t<TabsPrimitive.Indicator\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"pointer-events-none absolute left-0 top-0 z-0 h-(--active-tab-height) w-(--active-tab-width) translate-x-(--active-tab-left) translate-y-(--active-tab-top) transition-[transform,width,height] duration-200 ease-in-out\",\n\t\t\t\t\t\"group-data-[variant=secondary]/tabs-list:hidden\",\n\t\t\t\t\t\"group-data-[variant=underline]/tabs-list:rounded-none group-data-[variant=underline]/tabs-list:bg-line-focus group-data-[variant=underline]/tabs-list:shadow-none\",\n\t\t\t\t\t\"group-data-[orientation=horizontal]/tabs:group-data-[variant=underline]/tabs-list:top-auto group-data-[orientation=horizontal]/tabs:group-data-[variant=underline]/tabs-list:bottom-[-1px] group-data-[orientation=horizontal]/tabs:group-data-[variant=underline]/tabs-list:h-0.5! group-data-[orientation=horizontal]/tabs:group-data-[variant=underline]/tabs-list:translate-y-0\",\n\t\t\t\t\t\"group-data-[orientation=vertical]/tabs:group-data-[variant=underline]/tabs-list:left-auto group-data-[orientation=vertical]/tabs:group-data-[variant=underline]/tabs-list:right-[-1px] group-data-[orientation=vertical]/tabs:group-data-[variant=underline]/tabs-list:w-0.5! group-data-[orientation=vertical]/tabs:group-data-[variant=underline]/tabs-list:translate-x-0\",\n\t\t\t\t)}\n\t\t\t/>\n\t\t</TabsPrimitive.List>\n\t);\n}\n\nfunction TabsTrigger({\n\tclassName,\n\tnativeButton = true,\n\t...props\n}: TabsPrimitive.Tab.Props) {\n\treturn (\n\t\t<TabsPrimitive.Tab\n\t\t\tdata-slot=\"tabs-trigger\"\n\t\t\tnativeButton={nativeButton}\n\t\t\tclassName={cn(\n\t\t\t\t\"group/tabs-trigger relative inline-flex shrink-0 items-center justify-center gap-2 whitespace-nowrap border border-transparent font-semibold outline-none transition-[background-color,color,box-shadow] focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 group-data-[orientation=vertical]/tabs:w-full group-data-[orientation=vertical]/tabs:justify-start [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg]:text-current [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\t\"group-data-[variant=underline]/tabs-list:-mb-px group-data-[variant=underline]/tabs-list:rounded-none group-data-[variant=underline]/tabs-list:px-4 group-data-[variant=underline]/tabs-list:py-3 group-data-[variant=underline]/tabs-list:text-gdt-md group-data-[variant=underline]/tabs-list:text-fg-secondary group-data-[variant=underline]/tabs-list:hover:text-fg-primary group-data-[variant=underline]/tabs-list:data-active:text-fg-primary max-sm:group-data-[variant=underline]/tabs-list:px-3 max-sm:group-data-[variant=underline]/tabs-list:py-2.5 max-sm:group-data-[variant=underline]/tabs-list:text-gdt-sm\",\n\t\t\t\t\"group-data-[variant=secondary]/tabs-list:rounded-4xl group-data-[variant=secondary]/tabs-list:bg-surface-raised group-data-[variant=secondary]/tabs-list:px-4 group-data-[variant=secondary]/tabs-list:py-3 group-data-[variant=secondary]/tabs-list:text-gdt-md group-data-[variant=secondary]/tabs-list:text-fg-secondary group-data-[variant=secondary]/tabs-list:hover:bg-surface group-data-[variant=secondary]/tabs-list:hover:text-fg-primary group-data-[variant=secondary]/tabs-list:data-active:bg-surface-brand group-data-[variant=secondary]/tabs-list:data-active:text-fg-on-brand group-data-[variant=secondary]/tabs-list:data-active:shadow-(--elevation-e1-shadow) group-data-[variant=secondary]/tabs-list:data-active:hover:bg-surface-brand group-data-[variant=secondary]/tabs-list:data-active:hover:text-fg-on-brand max-sm:group-data-[variant=secondary]/tabs-list:px-3 max-sm:group-data-[variant=secondary]/tabs-list:py-2.5 max-sm:group-data-[variant=secondary]/tabs-list:text-gdt-sm\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction TabsCount({ className, ...props }: ComponentPropsWithoutRef<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\tdata-slot=\"tabs-count\"\n\t\t\tclassName={cn(\n\t\t\t\t\"inline-flex min-w-5 items-center justify-center rounded-full px-1.5 py-0.5 text-[11px] leading-none font-semibold transition-[background-color,color]\",\n\t\t\t\t\"group-data-[variant=underline]/tabs-list:bg-surface-raised group-data-[variant=underline]/tabs-list:text-fg-secondary group-data-[variant=underline]/tabs-list:group-data-[active]/tabs-trigger:bg-surface-brand-subtle group-data-[variant=underline]/tabs-list:group-data-[active]/tabs-trigger:text-fg-brand\",\n\t\t\t\t\"group-data-[variant=secondary]/tabs-list:bg-surface-overlay group-data-[variant=secondary]/tabs-list:text-fg-secondary group-data-[variant=secondary]/tabs-list:group-data-[active]/tabs-trigger:bg-surface-brand-subtle group-data-[variant=secondary]/tabs-list:group-data-[active]/tabs-trigger:text-fg-brand\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction TabsContent({ className, ...props }: TabsPrimitive.Panel.Props) {\n\treturn (\n\t\t<TabsPrimitive.Panel\n\t\t\tdata-slot=\"tabs-content\"\n\t\t\tclassName={cn(\"flex-1 text-sm outline-none\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tTabs,\n\tTabsList,\n\tTabsTrigger,\n\tTabsCount,\n\tTabsContent,\n\ttabsListVariants,\n};\n","\"use client\";\n\nimport type * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\n\n/**\n * Outer card wrapper.\n *\n * Tokens: bg-surface-overlay (container fill), border-line (container border).\n * Pass `containerClassName` to override scroll, sizing, or rounding for\n * individual call-sites (e.g. the data-table's max-height + rounded-[20px]).\n */\nfunction Table({\n\tclassName,\n\tcontainerClassName,\n\t...props\n}: React.ComponentProps<\"table\"> & { containerClassName?: string }) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"table-container\"\n\t\t\tclassName={cn(\n\t\t\t\t\"relative w-full overflow-x-auto rounded-xl border border-line bg-surface-overlay\",\n\t\t\t\tcontainerClassName,\n\t\t\t)}\n\t\t>\n\t\t\t<table\n\t\t\t\tdata-slot=\"table\"\n\t\t\t\tclassName={cn(\"min-w-full caption-bottom\", className)}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t</div>\n\t);\n}\n\n/**\n * Header band (thead).\n *\n * Token: bg-surface-raised (header fill).\n * Add `sticky` to pin the header and show Shadow-2 elevation while scrolled.\n */\nfunction TableHeader({\n\tclassName,\n\tsticky = false,\n\t...props\n}: React.ComponentProps<\"thead\"> & { sticky?: boolean }) {\n\treturn (\n\t\t<thead\n\t\t\tdata-slot=\"table-header\"\n\t\t\tclassName={cn(\n\t\t\t\t\"bg-surface-raised\",\n\t\t\t\tsticky && \"sticky top-0 z-2 shadow-(--elevation-e2-shadow)\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction TableBody({ className, ...props }: React.ComponentProps<\"tbody\">) {\n\treturn (\n\t\t<tbody\n\t\t\tdata-slot=\"table-body\"\n\t\t\tclassName={cn(\"[&_tr:last-child]:border-0\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\n/**\n * Footer band (tfoot).\n *\n * Shares the same raised surface as the header.\n */\nfunction TableFooter({ className, ...props }: React.ComponentProps<\"tfoot\">) {\n\treturn (\n\t\t<tfoot\n\t\t\tdata-slot=\"table-footer\"\n\t\t\tclassName={cn(\n\t\t\t\t\"border-t border-line bg-surface-raised font-medium [&>tr]:last:border-b-0\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\n/**\n * Table row (tr).\n *\n * Token: border-line-subtle (row divider). The last body row has no border\n * via the [&_tr:last-child]:border-0 rule on TableBody.\n */\nfunction TableRow({ className, ...props }: React.ComponentProps<\"tr\">) {\n\treturn (\n\t\t<tr\n\t\t\tdata-slot=\"table-row\"\n\t\t\tclassName={cn(\n\t\t\t\t\"group border-b border-line-subtle transition-colors\",\n\t\t\t\t\"hover:bg-surface has-aria-expanded:bg-surface\",\n\t\t\t\t\"data-[state=selected]:bg-surface-brand-subtle\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\n/**\n * Header cell (th).\n *\n * Tokens: bg-surface-raised (always applied so sticky/pinned th cells correctly\n * cover scrolling content), text-fg-secondary, text-gdt-capitalized + uppercase\n * for the tiny-caps column label style described in the design system.\n */\nfunction TableHead({ className, ...props }: React.ComponentProps<\"th\">) {\n\treturn (\n\t\t<th\n\t\t\tdata-slot=\"table-head\"\n\t\t\tclassName={cn(\n\t\t\t\t\"h-11 px-5 py-3.5 text-left align-middle bg-surface-raised\",\n\t\t\t\t\"text-gdt-capitalized font-bold uppercase tracking-wide text-fg-secondary\",\n\t\t\t\t\"whitespace-nowrap has-[[role=checkbox]]:pr-0\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\n/**\n * Standard body cell (td).\n *\n * Token: text-fg-primary (body cell text), text-gdt-sm.\n * Pass `pinned` when the column is sticky. Pinned cells get an opaque\n * bg-canvas cover so scrolling content doesn't bleed through, and they\n * mirror the parent row's hover/selected states via group variants.\n * Non-pinned cells are left transparent so the parent row's surface shows through.\n */\nfunction TableCell({\n\tclassName,\n\tpinned = false,\n\t...props\n}: React.ComponentProps<\"td\"> & { pinned?: boolean }) {\n\treturn (\n\t\t<td\n\t\t\tdata-slot=\"table-cell\"\n\t\t\tclassName={cn(\n\t\t\t\t\"px-5 py-3.5 align-middle text-gdt-sm text-fg-primary\",\n\t\t\t\t\"whitespace-nowrap\",\n\t\t\t\tpinned &&\n\t\t\t\t\t\"bg-surface-raised group-hover:bg-surface group-data-[state=selected]:bg-surface-brand-subtle\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\n/**\n * Formatted cell title, for use within a TableCell\n */\nfunction TableCellTitle({ className, ...props }: React.ComponentProps<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\tdata-slot=\"table-cell-title\"\n\t\t\tclassName={cn(\"text-gdt-sm font-semibold\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\n/**\n * Formatted cell caption, for use within a TableCell. Usually for auxiliary info below the title, uses the secondary text token and smaller size.\n */\nfunction TableCellCaption({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"span\">) {\n\treturn (\n\t\t<span\n\t\t\tdata-slot=\"table-cell-caption\"\n\t\t\tclassName={cn(\"text-gdt-xs text-fg-secondary\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\n/**\n * Caption — rendered below the table, uses secondary text token.\n */\nfunction TableCaption({\n\tclassName,\n\t...props\n}: React.ComponentProps<\"caption\">) {\n\treturn (\n\t\t<caption\n\t\t\tdata-slot=\"table-caption\"\n\t\t\tclassName={cn(\"mt-4 text-gdt-sm text-fg-secondary\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tTable,\n\tTableHeader,\n\tTableBody,\n\tTableFooter,\n\tTableHead,\n\tTableRow,\n\tTableCell,\n\tTableCellTitle,\n\tTableCellCaption,\n\tTableCaption,\n};\n","\"use client\";\n\nimport { cva } from \"class-variance-authority\";\nimport { X } from \"lucide-react\";\nimport type { KeyboardEvent, MouseEvent, ReactNode } from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\nconst tagVariants = cva(\n\t\"group/tag inline-flex w-fit shrink-0 items-center font-bold leading-none whitespace-nowrap rounded-4xl border bg-surface-raised text-fg-secondary transition-[background-color,border-color] select-none\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"gap-1 py-0.5 pl-2 pr-1 text-gdt-xs\",\n\t\t\t\tmd: \"gap-1.5 py-1 pl-2.5 pr-1.5 text-gdt-sm\",\n\t\t\t\tlg: \"gap-2 py-1.5 pl-3 pr-2 text-gdt-md\",\n\t\t\t},\n\t\t\tborder: {\n\t\t\t\ttrue: \"border-line\",\n\t\t\t\tfalse: \"border-transparent\",\n\t\t\t},\n\t\t\tclickable: {\n\t\t\t\ttrue: \"cursor-pointer hover:bg-action-tertiary-hover active:bg-action-tertiary-pressed outline-none focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)]\",\n\t\t\t\tfalse: \"cursor-default\",\n\t\t\t},\n\t\t\tdisabled: {\n\t\t\t\ttrue: \"opacity-50 pointer-events-none\",\n\t\t\t\tfalse: \"\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t\tborder: false,\n\t\t\tclickable: false,\n\t\t\tdisabled: false,\n\t\t},\n\t},\n);\n\nconst tagCloseVariants = cva(\n\t\"inline-flex shrink-0 items-center justify-center rounded-full text-fg-secondary transition-[background-color,color] outline-none hover:bg-action-tertiary-hover hover:text-fg-primary focus-visible:bg-action-tertiary-hover focus-visible:text-fg-primary focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] active:bg-action-tertiary-pressed disabled:pointer-events-none\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"size-4 [&>svg]:size-2.5\",\n\t\t\t\tmd: \"size-5 [&>svg]:size-3\",\n\t\t\t\tlg: \"size-5 [&>svg]:size-3.5\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\ninterface TagProps {\n\tlabel: string;\n\tleadingIcon?: ReactNode;\n\tonClose?: (e: MouseEvent<HTMLButtonElement>) => void;\n\tonClick?: () => void;\n\tsize?: ComponentSize;\n\tborder?: boolean;\n\tclickable?: boolean;\n\tdisabled?: boolean;\n\tclassName?: string;\n}\n\nfunction Tag({\n\tlabel,\n\tleadingIcon,\n\tonClose,\n\tonClick,\n\tsize,\n\tborder = false,\n\tclickable = false,\n\tdisabled = false,\n\tclassName,\n}: TagProps) {\n\tconst resolvedSize = useComponentSize(size);\n\n\tconst handleKeyDown = (e: KeyboardEvent<HTMLDivElement>) => {\n\t\tif (e.key === \"Enter\" || e.key === \" \") {\n\t\t\te.preventDefault();\n\t\t\tonClick?.();\n\t\t}\n\t};\n\n\treturn (\n\t\t// biome-ignore lint/a11y/noStaticElementInteractions: clickable tags set button semantics, focus, and keyboard activation while still allowing a nested close action.\n\t\t<div\n\t\t\trole={clickable ? \"button\" : undefined}\n\t\t\ttabIndex={clickable && !disabled ? 0 : undefined}\n\t\t\taria-disabled={disabled ? true : undefined}\n\t\t\tdata-slot=\"tag\"\n\t\t\tclassName={cn(\n\t\t\t\ttagVariants({ size: resolvedSize, border, clickable, disabled }),\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tonClick={clickable ? onClick : undefined}\n\t\t\tonKeyDown={clickable ? handleKeyDown : undefined}\n\t\t>\n\t\t\t{leadingIcon && (\n\t\t\t\t<span\n\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\tdata-slot=\"tag-leading-icon\"\n\t\t\t\t\tclassName=\"inline-flex shrink-0 items-center [&>svg]:size-[1em]\"\n\t\t\t\t>\n\t\t\t\t\t{leadingIcon}\n\t\t\t\t</span>\n\t\t\t)}\n\t\t\t<span>{label}</span>\n\t\t\t<button\n\t\t\t\ttype=\"button\"\n\t\t\t\taria-label={`Remove ${label}`}\n\t\t\t\tdisabled={disabled}\n\t\t\t\tclassName={cn(tagCloseVariants({ size: resolvedSize }))}\n\t\t\t\tonClick={(e) => {\n\t\t\t\t\te.stopPropagation();\n\t\t\t\t\tonClose?.(e);\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t<X aria-hidden=\"true\" />\n\t\t\t</button>\n\t\t</div>\n\t);\n}\n\nexport { Tag, tagVariants };\n","\"use client\";\n\nimport { ClockIcon } from \"lucide-react\";\nimport * as React from \"react\";\n\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\nimport { Popover, PopoverContent, PopoverTrigger } from \"./popover\";\n\nconst ITEM_HEIGHT = 40;\nconst VISIBLE_COUNT = 5;\nconst SCROLL_PADDING = Math.floor(VISIBLE_COUNT / 2) * ITEM_HEIGHT;\n// Tilt off-center items so the column reads as a scrollable wheel — a gentle\n// dome, not the full iOS cylinder. Clamped to this many items each side.\nconst CURVE_CLAMP = 3;\n\nconst HOURS_12 = Array.from({ length: 12 }, (_, i) =>\n\tString(i + 1).padStart(2, \"0\"),\n);\nconst HOURS_24 = Array.from({ length: 24 }, (_, i) =>\n\tString(i).padStart(2, \"0\"),\n);\nconst MINUTES = Array.from({ length: 60 }, (_, i) =>\n\tString(i).padStart(2, \"0\"),\n);\nconst PERIODS = [\"AM\", \"PM\"] as const;\n\ntype Period = \"AM\" | \"PM\";\n\ninterface TimeValue {\n\thour: string;\n\tminute: string;\n\tperiod: Period | \"\";\n}\n\nfunction parseTimeString(\n\tvalue: string | undefined,\n\tformat: \"12h\" | \"24h\",\n): TimeValue {\n\tif (value) {\n\t\tif (format === \"12h\") {\n\t\t\tconst m = value.match(/^(\\d{1,2}):(\\d{2})\\s*(AM|PM)$/i);\n\t\t\tif (m) {\n\t\t\t\treturn {\n\t\t\t\t\thour: m[1].padStart(2, \"0\"),\n\t\t\t\t\tminute: m[2],\n\t\t\t\t\tperiod: m[3].toUpperCase() as Period,\n\t\t\t\t};\n\t\t\t}\n\t\t} else {\n\t\t\tconst m = value.match(/^(\\d{1,2}):(\\d{2})$/);\n\t\t\tif (m) {\n\t\t\t\treturn { hour: m[1].padStart(2, \"0\"), minute: m[2], period: \"\" };\n\t\t\t}\n\t\t}\n\t}\n\tconst now = new Date();\n\tif (format === \"12h\") {\n\t\tconst h = now.getHours();\n\t\treturn {\n\t\t\thour: String(h % 12 || 12).padStart(2, \"0\"),\n\t\t\tminute: String(now.getMinutes()).padStart(2, \"0\"),\n\t\t\tperiod: h >= 12 ? \"PM\" : \"AM\",\n\t\t};\n\t}\n\treturn {\n\t\thour: String(now.getHours()).padStart(2, \"0\"),\n\t\tminute: String(now.getMinutes()).padStart(2, \"0\"),\n\t\tperiod: \"\",\n\t};\n}\n\nfunction formatTimeValue(tv: TimeValue, format: \"12h\" | \"24h\"): string {\n\tif (format === \"12h\") return `${tv.hour}:${tv.minute} ${tv.period}`;\n\treturn `${tv.hour}:${tv.minute}`;\n}\n\n// ─── TimeColumn ────────────────────────────────────────────────────────────────\n\ninterface TimeColumnProps {\n\titems: readonly string[];\n\tvalue: string;\n\tonChange: (v: string) => void;\n}\n\nfunction TimeColumn({ items, value, onChange }: TimeColumnProps) {\n\tconst scrollRef = React.useRef<HTMLDivElement>(null);\n\tconst itemRefs = React.useRef<(HTMLButtonElement | null)[]>([]);\n\tconst [centerIndex, setCenterIndex] = React.useState(() =>\n\t\tMath.max(0, items.indexOf(value)),\n\t);\n\tconst isProgrammatic = React.useRef(false);\n\tconst settleRef = React.useRef<ReturnType<typeof setTimeout> | null>(null);\n\tconst onChangeRef = React.useRef(onChange);\n\tonChangeRef.current = onChange;\n\n\t// Tilt + fade each item by its distance from the viewport centre. Derived\n\t// purely from scrollTop (offset in item units), so it never fights layout.\n\tconst paintCurve = React.useCallback(() => {\n\t\tconst el = scrollRef.current;\n\t\tif (!el) return;\n\t\tconst offset = el.scrollTop / ITEM_HEIGHT;\n\t\titemRefs.current.forEach((node, index) => {\n\t\t\tif (!node) return;\n\t\t\tconst distance = index - offset;\n\t\t\tconst abs = Math.min(Math.abs(distance), CURVE_CLAMP);\n\t\t\tconst tilt = Math.max(Math.min(distance, CURVE_CLAMP), -CURVE_CLAMP);\n\t\t\tnode.style.opacity = String(Math.max(1 - abs * 0.28, 0.2));\n\t\t\tnode.style.transform = `perspective(280px) rotateX(${tilt * -20}deg) scale(${1 - abs * 0.04})`;\n\t\t});\n\t}, []);\n\n\t// Seed scroll position on mount (runs while the panel is visible, so the\n\t// layout-based scrollTop sticks even mid open-animation).\n\t// biome-ignore lint/correctness/useExhaustiveDependencies: mount-only seed from the initial index.\n\tReact.useEffect(() => {\n\t\tconst el = scrollRef.current;\n\t\tif (!el) return;\n\t\tisProgrammatic.current = true;\n\t\tel.scrollTop = centerIndex * ITEM_HEIGHT;\n\t\tpaintCurve();\n\t\trequestAnimationFrame(() => {\n\t\t\tisProgrammatic.current = false;\n\t\t});\n\t}, []);\n\n\t// Re-centre when the value prop changes from outside (not our own scroll).\n\t// biome-ignore lint/correctness/useExhaustiveDependencies: only re-sync on external value changes.\n\tReact.useEffect(() => {\n\t\tconst idx = items.indexOf(value);\n\t\tif (idx === -1 || idx === centerIndex) return;\n\t\tsetCenterIndex(idx);\n\t\tconst el = scrollRef.current;\n\t\tif (!el) return;\n\t\tisProgrammatic.current = true;\n\t\tel.scrollTo({ top: idx * ITEM_HEIGHT, behavior: \"smooth\" });\n\t\tsetTimeout(() => {\n\t\t\tisProgrammatic.current = false;\n\t\t\tpaintCurve();\n\t\t}, 320);\n\t}, [value]);\n\n\tfunction handleScroll() {\n\t\tpaintCurve();\n\t\tif (isProgrammatic.current) return;\n\t\tconst el = scrollRef.current;\n\t\tif (!el) return;\n\t\tconst idx = Math.max(\n\t\t\t0,\n\t\t\tMath.min(Math.round(el.scrollTop / ITEM_HEIGHT), items.length - 1),\n\t\t);\n\t\tif (idx !== centerIndex) setCenterIndex(idx);\n\t\tif (settleRef.current) clearTimeout(settleRef.current);\n\t\tsettleRef.current = setTimeout(() => onChangeRef.current(items[idx]), 120);\n\t}\n\n\treturn (\n\t\t<div\n\t\t\tref={scrollRef}\n\t\t\tonScroll={handleScroll}\n\t\t\tstyle={{ height: `${VISIBLE_COUNT * ITEM_HEIGHT}px` }}\n\t\t\tclassName=\"overflow-y-scroll [scrollbar-width:none] [&::-webkit-scrollbar]:hidden\"\n\t\t>\n\t\t\t<div\n\t\t\t\tstyle={{\n\t\t\t\t\tpaddingTop: `${SCROLL_PADDING}px`,\n\t\t\t\t\tpaddingBottom: `${SCROLL_PADDING}px`,\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t{items.map((item, index) => {\n\t\t\t\t\tconst dist = Math.abs(index - centerIndex);\n\t\t\t\t\treturn (\n\t\t\t\t\t\t<button\n\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\tkey={item}\n\t\t\t\t\t\t\tref={(node) => {\n\t\t\t\t\t\t\t\titemRefs.current[index] = node;\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\tscrollRef.current?.scrollTo({\n\t\t\t\t\t\t\t\t\ttop: index * ITEM_HEIGHT,\n\t\t\t\t\t\t\t\t\tbehavior: \"smooth\",\n\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tstyle={{ height: `${ITEM_HEIGHT}px` }}\n\t\t\t\t\t\t\tclassName=\"flex w-full cursor-pointer items-center justify-center select-none will-change-transform\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\t\"rounded-full px-4 py-1.5 text-gdt-sm font-medium transition-colors\",\n\t\t\t\t\t\t\t\t\tdist === 0\n\t\t\t\t\t\t\t\t\t\t? \"bg-action-primary text-fg-on-brand\"\n\t\t\t\t\t\t\t\t\t\t: dist === 1\n\t\t\t\t\t\t\t\t\t\t\t? \"text-fg-secondary\"\n\t\t\t\t\t\t\t\t\t\t\t: \"text-fg-caption-placeholder\",\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{item}\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t</button>\n\t\t\t\t\t);\n\t\t\t\t})}\n\t\t\t</div>\n\t\t</div>\n\t);\n}\n\n// ─── TimePicker ───────────────────────────────────────────────────────────────\n\ninterface TimePickerProps {\n\tvalue?: string;\n\tonChange?: (time: string | undefined) => void;\n\tformat?: \"12h\" | \"24h\";\n\tdisabled?: boolean;\n\tplaceholder?: string;\n\tclassName?: string;\n}\n\nfunction TimePicker({\n\tvalue,\n\tonChange,\n\tformat = \"12h\",\n\tdisabled = false,\n\tplaceholder = \"Select time\",\n\tclassName,\n}: TimePickerProps) {\n\tconst [open, setOpen] = React.useState(false);\n\tconst [pending, setPending] = React.useState<TimeValue>(() =>\n\t\tparseTimeString(value, format),\n\t);\n\n\tfunction handleOpenChange(next: boolean) {\n\t\tif (next) setPending(parseTimeString(value, format));\n\t\tsetOpen(next);\n\t}\n\n\tconst columns = [\n\t\t{ key: \"Hour\", show: true },\n\t\t{ key: \"Minute\", show: true },\n\t\t{ key: \"Period\", show: format === \"12h\" },\n\t].filter((c) => c.show);\n\n\treturn (\n\t\t<Popover open={open} onOpenChange={handleOpenChange}>\n\t\t\t<PopoverTrigger\n\t\t\t\tdisabled={disabled}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"flex h-10 w-full items-center justify-between rounded-full border px-3.5 text-gdt-sm transition-[border-color,box-shadow] outline-none\",\n\t\t\t\t\tdisabled\n\t\t\t\t\t\t? \"cursor-not-allowed border-line-subtle bg-surface text-fg-caption-placeholder\"\n\t\t\t\t\t\t: open\n\t\t\t\t\t\t\t? \"border-line-focus bg-canvas text-fg-primary inset-ring-1 inset-ring-line-focus\"\n\t\t\t\t\t\t\t: \"border-line bg-canvas text-fg-primary hover:border-line-strong\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t<span\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"min-w-0 truncate\",\n\t\t\t\t\t\t!value && \"text-fg-caption-placeholder\",\n\t\t\t\t\t)}\n\t\t\t\t>\n\t\t\t\t\t{value || placeholder}\n\t\t\t\t</span>\n\t\t\t\t<ClockIcon\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"ml-2 size-4 shrink-0\",\n\t\t\t\t\t\tdisabled ? \"text-fg-caption-placeholder\" : \"text-fg-secondary\",\n\t\t\t\t\t)}\n\t\t\t\t/>\n\t\t\t</PopoverTrigger>\n\t\t\t<PopoverContent\n\t\t\t\tshowArrow={false}\n\t\t\t\talign=\"start\"\n\t\t\t\tclassName=\"min-w-(--anchor-width) gap-0 overflow-hidden rounded-2xl p-0\"\n\t\t\t>\n\t\t\t\t<div className=\"w-full flex gap-2 items-center justify-center border-b border-line-subtle\">\n\t\t\t\t\t{columns.map((column) => (\n\t\t\t\t\t\t<p\n\t\t\t\t\t\t\tkey={column.key}\n\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\"py-3 text-center text-gdt-xs text-fg-caption-placeholder\",\n\t\t\t\t\t\t\t\tformat === \"12h\" ? \"w-20.5\" : \"w-31\",\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{column.key}\n\t\t\t\t\t\t</p>\n\t\t\t\t\t))}\n\t\t\t\t</div>\n\t\t\t\t<div\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"flex gap-2 justify-center px-3 pt-2\",\n\t\t\t\t\t\tformat === \"12h\" ? \"*:w-20.5\" : \"*:w-31\",\n\t\t\t\t\t)}\n\t\t\t\t>\n\t\t\t\t\t<TimeColumn\n\t\t\t\t\t\titems={format === \"12h\" ? HOURS_12 : HOURS_24}\n\t\t\t\t\t\tvalue={pending.hour}\n\t\t\t\t\t\tonChange={(hour) => setPending((prev) => ({ ...prev, hour }))}\n\t\t\t\t\t/>\n\t\t\t\t\t<TimeColumn\n\t\t\t\t\t\titems={MINUTES}\n\t\t\t\t\t\tvalue={pending.minute}\n\t\t\t\t\t\tonChange={(minute) => setPending((prev) => ({ ...prev, minute }))}\n\t\t\t\t\t/>\n\t\t\t\t\t{format === \"12h\" && (\n\t\t\t\t\t\t<TimeColumn\n\t\t\t\t\t\t\titems={PERIODS}\n\t\t\t\t\t\t\tvalue={pending.period}\n\t\t\t\t\t\t\tonChange={(period) =>\n\t\t\t\t\t\t\t\tsetPending((prev) => ({ ...prev, period: period as Period }))\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t\t</div>\n\t\t\t\t<div className=\"mt-2 flex items-center justify-between border-t border-line-subtle px-4 py-3\">\n\t\t\t\t\t<Button\n\t\t\t\t\t\tvariant=\"tertiary-outline\"\n\t\t\t\t\t\tsize=\"sm\"\n\t\t\t\t\t\tonClick={() => setOpen(false)}\n\t\t\t\t\t>\n\t\t\t\t\t\tCancel\n\t\t\t\t\t</Button>\n\t\t\t\t\t<Button\n\t\t\t\t\t\tsize=\"sm\"\n\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\tonChange?.(formatTimeValue(pending, format));\n\t\t\t\t\t\t\tsetOpen(false);\n\t\t\t\t\t\t}}\n\t\t\t\t\t>\n\t\t\t\t\t\tApply\n\t\t\t\t\t</Button>\n\t\t\t\t</div>\n\t\t\t</PopoverContent>\n\t\t</Popover>\n\t);\n}\n\nexport { TimePicker };\nexport type { TimePickerProps };\n","import type {\n\tToastManagerAddOptions,\n\tToastManagerUpdateOptions,\n\tToastObject,\n} from \"@base-ui/react/toast\";\nimport { Toast as BaseToast } from \"@base-ui/react/toast\";\nimport { Check, Info, X } from \"lucide-react\";\nimport type { CSSProperties, PropsWithChildren } from \"react\";\nimport { cn } from \"../../lib/cn\";\nimport { Button } from \"./button\";\n\ntype ToastVariant = \"success\" | \"info\" | \"warning\" | \"error\" | \"loading\";\ntype ResolvedToastSide = \"top\" | \"bottom\" | \"left\" | \"right\";\ntype ToastAlign = \"start\" | \"center\" | \"end\";\ntype ToastPlacement = {\n\tside: ResolvedToastSide;\n\talign: ToastAlign;\n\tkey: string;\n};\ntype ToastRootStyle = CSSProperties &\n\tRecord<\n\t\t| \"--toast-placement-index\"\n\t\t| \"--toast-placement-offset-y\"\n\t\t| \"--toast-placement-frontmost-height\",\n\t\tstring | number | undefined\n\t>;\n\ntype ToastData = {\n\ttype: ToastVariant;\n};\n\nconst DEFAULT_TOAST_SIDE = \"top\";\nconst DEFAULT_TOAST_ALIGN = \"end\";\ntype ToastSide = NonNullable<\n\tToastObject<{ type?: ToastVariant }>[\"positionerProps\"]\n>[\"side\"];\n\nexport const toastManager = BaseToast.createToastManager();\n\nexport const toast = Object.assign(\n\t(options: ToastManagerAddOptions<ToastData>) => toastManager.add(options),\n\t{\n\t\tsuccess: (options: ToastManagerAddOptions<ToastData>) =>\n\t\t\ttoastManager.add({\n\t\t\t\t...options,\n\t\t\t\tdata: { type: \"success\", ...options.data },\n\t\t\t}),\n\t\tinfo: (options: ToastManagerAddOptions<ToastData>) =>\n\t\t\ttoastManager.add({\n\t\t\t\t...options,\n\t\t\t\tdata: { type: \"info\", ...options.data },\n\t\t\t}),\n\t\twarning: (options: ToastManagerAddOptions<ToastData>) =>\n\t\t\ttoastManager.add({\n\t\t\t\t...options,\n\t\t\t\tdata: { type: \"warning\", ...options.data },\n\t\t\t}),\n\t\terror: (options: ToastManagerAddOptions<ToastData>) =>\n\t\t\ttoastManager.add({\n\t\t\t\t...options,\n\t\t\t\tdata: { type: \"error\", ...options.data },\n\t\t\t}),\n\t\tloading: (options: ToastManagerAddOptions<ToastData>) =>\n\t\t\ttoastManager.add({\n\t\t\t\t...options,\n\t\t\t\tdata: { type: \"loading\", ...options.data },\n\t\t\t}),\n\t\tdismiss: (toastId?: string | number) =>\n\t\t\ttoastManager.close(toastId?.toString()),\n\t\tupdate: (\n\t\t\ttoastId: string | number,\n\t\t\toptions: ToastManagerUpdateOptions<ToastData>,\n\t\t) => toastManager.update(toastId.toString(), options),\n\t\tpromise: toastManager.promise,\n\t},\n);\n\nexport function ToastProvider({ children }: PropsWithChildren) {\n\treturn (\n\t\t<BaseToast.Provider limit={4} timeout={5000} toastManager={toastManager}>\n\t\t\t{children}\n\t\t\t<BaseToast.Portal>\n\t\t\t\t<BaseToast.Viewport className=\"fixed inset-0 z-9999 pointer-events-none outline-none\">\n\t\t\t\t\t<ToastList />\n\t\t\t\t</BaseToast.Viewport>\n\t\t\t</BaseToast.Portal>\n\t\t</BaseToast.Provider>\n\t);\n}\n\nfunction ToastList() {\n\tconst { toasts } = BaseToast.useToastManager<ToastData>();\n\tconst placementStacks = new Map<\n\t\tstring,\n\t\t{\n\t\t\tdomIndex: number;\n\t\t\tvisibleIndex: number;\n\t\t\toffsetY: number;\n\t\t\tfrontmostHeight?: number;\n\t\t}\n\t>();\n\n\treturn toasts.map((item) => {\n\t\tconst placement = getToastPlacement(item);\n\t\tconst stack = placementStacks.get(placement.key) ?? {\n\t\t\tdomIndex: 0,\n\t\t\tvisibleIndex: 0,\n\t\t\toffsetY: 0,\n\t\t\tfrontmostHeight: item.height,\n\t\t};\n\t\tconst placementIndex =\n\t\t\titem.transitionStatus === \"ending\" ? stack.domIndex : stack.visibleIndex;\n\t\tconst style: ToastRootStyle = {\n\t\t\t\"--toast-placement-index\": placementIndex,\n\t\t\t\"--toast-placement-offset-y\": `${stack.offsetY}px`,\n\t\t\t\"--toast-placement-frontmost-height\": stack.frontmostHeight\n\t\t\t\t? `${stack.frontmostHeight}px`\n\t\t\t\t: undefined,\n\t\t};\n\n\t\tstack.offsetY += item.height ?? 0;\n\t\tstack.domIndex += 1;\n\t\tif (item.transitionStatus !== \"ending\") {\n\t\t\tstack.visibleIndex += 1;\n\t\t}\n\t\tplacementStacks.set(placement.key, stack);\n\n\t\treturn (\n\t\t\t<BaseToast.Root\n\t\t\t\tkey={item.id}\n\t\t\t\ttoast={item}\n\t\t\t\tclassName={cn(\n\t\t\t\t\ttoastRootBaseClassName,\n\t\t\t\t\tgetToastPositionClassName(placement),\n\t\t\t\t\tgetToastStackClassName(placement),\n\t\t\t\t\tgetToastExitClassName(placement.side),\n\t\t\t\t)}\n\t\t\t\tswipeDirection={getSwipeDirections(item)}\n\t\t\t\tstyle={style}\n\t\t\t>\n\t\t\t\t<BaseToast.Content\n\t\t\t\t\tclassName={\n\t\t\t\t\t\t\"grid grid-cols-[16px_minmax(0,1fr)_24px] items-start gap-3 overflow-hidden px-2.5 py-3.5 pl-3 transition-opacity duration-250 data-behind:pointer-events-none data-behind:opacity-0 data-expanded:pointer-events-auto data-expanded:opacity-100\"\n\t\t\t\t\t}\n\t\t\t\t>\n\t\t\t\t\t<ToastIcon type={item.data?.type} />\n\t\t\t\t\t<div className=\"min-w-0 flex flex-col gap-1.5\">\n\t\t\t\t\t\t{item.title ? (\n\t\t\t\t\t\t\t<BaseToast.Title className=\"text-gdt-sm font-semibold text-fg-primary\" />\n\t\t\t\t\t\t) : null}\n\t\t\t\t\t\t{item.description ? (\n\t\t\t\t\t\t\t<BaseToast.Description className=\"text-gdt-sm text-fg-secondary\" />\n\t\t\t\t\t\t) : null}\n\t\t\t\t\t\t<BaseToast.Action\n\t\t\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\t\t\"cursor-pointer border-0 bg-transparent p-0 font-inherit text-gdt-sm font-semibold inline-flex w-fit items-center hover:underline underline-offset-2\",\n\t\t\t\t\t\t\t\titem.data?.type === \"success\" && \"text-fg-brand\",\n\t\t\t\t\t\t\t\titem.data?.type === \"info\" && \"text-fg-primary\",\n\t\t\t\t\t\t\t\titem.data?.type === \"warning\" && \"text-fg-accent\",\n\t\t\t\t\t\t\t\titem.data?.type === \"error\" && \"text-fg-danger\",\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t/>\n\t\t\t\t\t</div>\n\t\t\t\t\t<BaseToast.Close\n\t\t\t\t\t\trender={<Button variant=\"ghost\" size=\"icon-xs\" />}\n\t\t\t\t\t\taria-label=\"Close toast\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<X className=\"size-4\" />\n\t\t\t\t\t</BaseToast.Close>\n\t\t\t\t</BaseToast.Content>\n\t\t\t</BaseToast.Root>\n\t\t);\n\t});\n}\n\nfunction ToastIcon({ type }: { type?: ToastVariant }) {\n\tif (!type) return null;\n\treturn (\n\t\t<span\n\t\t\tclassName={cn(\n\t\t\t\t\"inline-flex size-5 items-center justify-center rounded-full text-canvas\",\n\t\t\t\ttype === \"success\" && \"bg-status-success\",\n\t\t\t\ttype === \"info\" && \"bg-status-info\",\n\t\t\t\ttype === \"warning\" && \"bg-status-warning text-fg-on-accent\",\n\t\t\t\ttype === \"error\" && \"bg-status-danger\",\n\t\t\t)}\n\t\t\taria-hidden=\"true\"\n\t\t>\n\t\t\t{type === \"success\" ? <Check size={10} strokeWidth={3} /> : null}\n\t\t\t{type === \"info\" ? <Info size={11} strokeWidth={2.8} /> : null}\n\t\t\t{type === \"warning\" ? (\n\t\t\t\t<span className=\"text-[11px] leading-none font-extrabold\">!</span>\n\t\t\t) : null}\n\t\t\t{type === \"error\" ? <X size={10} strokeWidth={3} /> : null}\n\t\t</span>\n\t);\n}\n\nconst toastRootBaseClassName =\n\t\"[--gap:12px] [--peek:12px] [--anchor-x:0px] [--anchor-y:0px] [--scale:calc(max(0,1-(var(--toast-placement-index)*0.04)))] [--shrink:calc(1-var(--scale))] [--height:var(--toast-placement-frontmost-height,var(--toast-height))] absolute z-[calc(1000-var(--toast-placement-index))] h-[var(--height)] min-h-[var(--height)] w-[min(335px,calc(100vw-32px))] overflow-visible rounded-lg border border-line bg-surface-overlay text-fg-primary shadow-[var(--elevation-e2-shadow)] pointer-events-auto select-none [transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)))_translateY(var(--collapsed-y))_scale(var(--scale))] [transition:transform_500ms_cubic-bezier(0.22,1,0.36,1),opacity_500ms,height_150ms] after:absolute after:left-0 after:h-[calc(var(--gap)+1px)] after:w-full after:pointer-events-auto after:content-[''] data-[expanded]:h-[var(--toast-height)] data-[expanded]:[transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)))_translateY(var(--expanded-y))_scale(1)] data-[starting-style]:opacity-0 data-[starting-style]:[transform:translateX(var(--exit-x))_translateY(var(--exit-y))_scale(var(--scale))] data-[ending-style]:opacity-0 data-[limited]:opacity-0 [&[data-ending-style]:not([data-limited]):not([data-swipe-direction])]:[transform:translateX(var(--exit-x))_translateY(var(--exit-y))_scale(var(--scale))] data-[ending-style]:data-[swipe-direction=up]:[transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)))_translateY(calc(var(--anchor-y)+var(--toast-swipe-movement-y)-150%))_scale(var(--scale))] data-[expanded]:data-[ending-style]:data-[swipe-direction=up]:[transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)))_translateY(calc(var(--anchor-y)+var(--toast-swipe-movement-y)-150%))_scale(1)] data-[ending-style]:data-[swipe-direction=down]:[transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)))_translateY(calc(var(--anchor-y)+var(--toast-swipe-movement-y)+150%))_scale(var(--scale))] data-[expanded]:data-[ending-style]:data-[swipe-direction=down]:[transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)))_translateY(calc(var(--anchor-y)+var(--toast-swipe-movement-y)+150%))_scale(1)] data-[ending-style]:data-[swipe-direction=left]:[transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)-150%))_translateY(var(--expanded-y))_scale(var(--scale))] data-[expanded]:data-[ending-style]:data-[swipe-direction=left]:[transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)-150%))_translateY(var(--expanded-y))_scale(1)] data-[ending-style]:data-[swipe-direction=right]:[transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)+150%))_translateY(var(--expanded-y))_scale(var(--scale))] data-[expanded]:data-[ending-style]:data-[swipe-direction=right]:[transform:translateX(calc(var(--anchor-x)+var(--toast-swipe-movement-x,0px)+150%))_translateY(var(--expanded-y))_scale(1)]\";\n\nfunction getToastPlacement(\n\titem: ToastObject<{ type?: ToastVariant }>,\n\tisRtl = false,\n): ToastPlacement {\n\tconst side = item.positionerProps?.side ?? DEFAULT_TOAST_SIDE;\n\tconst align = (item.positionerProps?.align ??\n\t\tDEFAULT_TOAST_ALIGN) as ToastAlign;\n\tconst resolvedSide = resolveToastSide(side, isRtl);\n\n\treturn {\n\t\tside: resolvedSide,\n\t\talign,\n\t\tkey: `${resolvedSide}:${align}`,\n\t};\n}\n\nfunction resolveToastSide(\n\tside: ToastSide | undefined,\n\tisRtl: boolean,\n): ResolvedToastSide {\n\tif (side === \"inline-end\") return isRtl ? \"left\" : \"right\";\n\tif (side === \"inline-start\") return isRtl ? \"right\" : \"left\";\n\tif (\n\t\tside === \"top\" ||\n\t\tside === \"bottom\" ||\n\t\tside === \"left\" ||\n\t\tside === \"right\"\n\t) {\n\t\treturn side;\n\t}\n\treturn DEFAULT_TOAST_SIDE;\n}\n\nfunction getToastPositionClassName({ side, align }: ToastPlacement) {\n\tconst isVerticalSide = side === \"top\" || side === \"bottom\";\n\n\tif (isVerticalSide) {\n\t\treturn cn(\n\t\t\tside === \"top\" && \"top-6 max-sm:top-4\",\n\t\t\tside === \"bottom\" && \"bottom-6 max-sm:bottom-4\",\n\t\t\talign === \"start\" && \"left-6 origin-top-left max-sm:left-4\",\n\t\t\talign === \"center\" && \"left-1/2 origin-top [--anchor-x:-50%]\",\n\t\t\talign === \"end\" && \"right-6 origin-top-right max-sm:right-4\",\n\t\t\tside === \"bottom\" && align === \"start\" && \"origin-bottom-left\",\n\t\t\tside === \"bottom\" && align === \"center\" && \"origin-bottom\",\n\t\t\tside === \"bottom\" && align === \"end\" && \"origin-bottom-right\",\n\t\t);\n\t}\n\n\treturn cn(\n\t\tside === \"left\" && \"left-6 origin-left max-sm:left-4\",\n\t\tside === \"right\" && \"right-6 origin-right max-sm:right-4\",\n\t\talign === \"start\" && \"top-6 max-sm:top-4\",\n\t\talign === \"center\" && \"top-1/2 [--anchor-y:-50%]\",\n\t\talign === \"end\" && \"bottom-6 max-sm:bottom-4\",\n\t\tside === \"left\" && align === \"start\" && \"origin-top-left\",\n\t\tside === \"left\" && align === \"end\" && \"origin-bottom-left\",\n\t\tside === \"right\" && align === \"start\" && \"origin-top-right\",\n\t\tside === \"right\" && align === \"end\" && \"origin-bottom-right\",\n\t);\n}\n\nfunction getToastStackClassName({ side, align }: ToastPlacement) {\n\tconst stacksUp =\n\t\tside === \"bottom\" ||\n\t\t((side === \"left\" || side === \"right\") && align === \"end\");\n\n\tif (stacksUp) {\n\t\treturn \"after:bottom-full [--expanded-y:calc(var(--anchor-y)+var(--toast-swipe-movement-y)-var(--toast-placement-offset-y)-(var(--toast-placement-index)*var(--gap)))] [--collapsed-y:calc(var(--anchor-y)+var(--toast-swipe-movement-y)-(var(--toast-placement-index)*var(--peek))-(var(--shrink)*var(--height)))]\";\n\t}\n\n\treturn \"after:top-full [--expanded-y:calc(var(--anchor-y)+var(--toast-placement-offset-y)+(var(--toast-placement-index)*var(--gap))+var(--toast-swipe-movement-y))] [--collapsed-y:calc(var(--anchor-y)+var(--toast-swipe-movement-y)+(var(--toast-placement-index)*var(--peek))+(var(--shrink)*var(--height)))]\";\n}\n\nfunction getToastExitClassName(side: ResolvedToastSide) {\n\tif (side === \"bottom\") {\n\t\treturn \"[--exit-x:calc(var(--anchor-x)+24px)] [--exit-y:calc(var(--anchor-y)+150%)]\";\n\t}\n\tif (side === \"left\") {\n\t\treturn \"[--exit-x:calc(var(--anchor-x)-150%)] [--exit-y:var(--anchor-y)]\";\n\t}\n\tif (side === \"right\") {\n\t\treturn \"[--exit-x:calc(var(--anchor-x)+150%)] [--exit-y:var(--anchor-y)]\";\n\t}\n\treturn \"[--exit-x:calc(var(--anchor-x)+24px)] [--exit-y:calc(var(--anchor-y)-150%)]\";\n}\n\ntype SwipeDirection = \"up\" | \"down\" | \"left\" | \"right\";\nfunction getSwipeDirections(\n\titem: ToastObject<{ type?: ToastVariant }>,\n\tisRtl = false,\n) {\n\tconst { side: resolvedSide, align } = getToastPlacement(item, isRtl);\n\tconst primary: SwipeDirection =\n\t\tresolvedSide === \"top\"\n\t\t\t? \"up\"\n\t\t\t: resolvedSide === \"bottom\"\n\t\t\t\t? \"down\"\n\t\t\t\t: resolvedSide === \"left\"\n\t\t\t\t\t? \"left\"\n\t\t\t\t\t: /* right */ \"right\";\n\tif (align === \"center\") return primary;\n\tconst isVerticalSide = resolvedSide === \"top\" || resolvedSide === \"bottom\";\n\tconst secondary: SwipeDirection = isVerticalSide\n\t\t? align === \"start\"\n\t\t\t? \"left\"\n\t\t\t: \"right\"\n\t\t: align === \"start\"\n\t\t\t? \"up\"\n\t\t\t: \"down\";\n\treturn [primary, secondary];\n}\n","\"use client\";\n\nimport { cva } from \"class-variance-authority\";\nimport type * as React from \"react\";\nimport { Treemap as RechartsTreemap, type TreemapNode } from \"recharts\";\nimport { cn } from \"../../lib/cn\";\nimport {\n\tChartCard,\n\ttype ChartConfig,\n\tChartContainer,\n\tChartDescription,\n\tChartHeader,\n\tChartTitle,\n\tChartTooltip,\n\tChartTooltipContent,\n\ttype ChartValueType,\n} from \"./chart\";\nimport { type ComponentSize, useComponentSize } from \"./size-context\";\n\n/**\n * A treemap — part-to-whole composition drawn as proportionally sized, nested\n * rectangles. Reach for one to compare category shares at a glance (portfolio\n * mix, holdings by type, regional distribution).\n *\n * Two shapes share one component: `flat` lays out a single level of categories;\n * `nested` groups subcategories beneath a shared group colour (each leaf inherits\n * its group's colour unless it sets its own `fill`). Both reuse the same palette,\n * in-tile labels, legend, frame, and tooltip — only the data depth differs.\n *\n * Per the chart architecture the recharts `Treemap` primitive is rendered\n * directly here; only the giddaa frame, palette, tile content, and legend are\n * supplied around it. Tiles are sized by `value`; the in-tile label (name + share\n * of the whole) is hidden on tiles too small to fit it.\n *\n * @example\n * <TreeMap\n * data={[\n * { label: \"Lekki\", value: 40 },\n * { label: \"Ikoyi\", value: 30 },\n * { label: \"V.I.\", value: 18 },\n * { label: \"Yaba\", value: 12 },\n * ]}\n * title=\"Portfolio mix\"\n * description=\"Share of holdings by location\"\n * tooltip\n * />\n *\n * @example\n * // Nested — subcategories grouped under a shared group colour\n * <TreeMap\n * data={[\n * { label: \"Residential\", children: [\n * { label: \"Apartments\", value: 27 },\n * { label: \"Duplexes\", value: 21 },\n * ] },\n * { label: \"Commercial\", children: [\n * { label: \"Offices\", value: 17 },\n * { label: \"Retail\", value: 13 },\n * ] },\n * { label: \"Land\", children: [{ label: \"Plots\", value: 14 }] },\n * ]}\n * title=\"Portfolio mix\"\n * description=\"Holdings by category & type\"\n * />\n */\n\n/** Treemap sizes line up with the three shared `ComponentSize` values. */\ntype TreeMapSize = ComponentSize;\n\n/** Where the colour-key legend sits relative to the plot. */\ntype TreeMapLegendPlacement = \"right\" | \"bottom\";\n\ntype TreeMapDatum = {\n\t/** Category name, shown in the tile label, legend, and tooltip. */\n\tlabel: string;\n\t/** Tile value — drives the tile's area. Omit on a group with `children`. */\n\tvalue?: number;\n\t/** Tile/group colour; defaults to the palette in order. Leaves inherit it. */\n\tfill?: string;\n\t/** Subcategories for a `nested` treemap. */\n\tchildren?: TreeMapDatum[];\n};\n\n/**\n * Tile palette, ordered by share: forest → brass → moss → clay → stone. Each\n * entry pairs a tile `fill` with the `text` colour that reads on it (a tonal\n * tint of the same scale). Giddaa has no `chart-1`…`chart-N` tokens yet, so these\n * map to the brand scales; assign by order, or override per datum with `fill`.\n */\nconst TREE_MAP_PALETTE = [\n\t{ fill: \"var(--color-forest-700)\", text: \"var(--color-forest-100)\" },\n\t{ fill: \"var(--color-brass-500)\", text: \"var(--color-brass-900)\" },\n\t{ fill: \"var(--color-moss-600)\", text: \"var(--color-moss-100)\" },\n\t{ fill: \"var(--color-clay-500)\", text: \"var(--color-clay-50)\" },\n\t{ fill: \"var(--color-stone-500)\", text: \"var(--color-stone-50)\" },\n] as const;\n\ntype TreeMapLayout = {\n\t/** Plot box height in px. Width stays fluid via the ResponsiveContainer. */\n\theight: number;\n\t/** Inset around every tile in px — straddles edges to read as a gap. */\n\tgap: number;\n\t/** Tile corner radius in px. */\n\tradius: number;\n\t/** Tile label padding from the top-left corner in px. */\n\tlabelPadding: number;\n\t/** Tile label (name) font size in px. */\n\tnameFontSize: number;\n\t/** Tile label (share) font size in px. */\n\tshareFontSize: number;\n\t/** Smallest tile width/height in px that still shows its label. */\n\tlabelMinSide: number;\n};\n\nconst TREE_MAP_LAYOUT: Record<TreeMapSize, TreeMapLayout> = {\n\tsm: {\n\t\theight: 180,\n\t\tgap: 3,\n\t\tradius: 4,\n\t\tlabelPadding: 8,\n\t\tnameFontSize: 11,\n\t\tshareFontSize: 10,\n\t\tlabelMinSide: 44,\n\t},\n\tmd: {\n\t\theight: 240,\n\t\tgap: 4,\n\t\tradius: 6,\n\t\tlabelPadding: 10,\n\t\tnameFontSize: 12,\n\t\tshareFontSize: 11,\n\t\tlabelMinSide: 52,\n\t},\n\tlg: {\n\t\theight: 300,\n\t\tgap: 5,\n\t\tradius: 8,\n\t\tlabelPadding: 12,\n\t\tnameFontSize: 14,\n\t\tshareFontSize: 12,\n\t\tlabelMinSide: 60,\n\t},\n};\n\n/** Vertical legend column / value list — shared with the right-hand legend. */\nconst treeMapLegendVariants = cva(\"flex min-w-0\", {\n\tvariants: {\n\t\tplacement: {\n\t\t\tright: \"flex-col\",\n\t\t\tbottom: \"flex-row flex-wrap items-center\",\n\t\t},\n\t\tsize: {\n\t\t\tsm: \"text-gdt-xs\",\n\t\t\tmd: \"text-gdt-sm\",\n\t\t\tlg: \"text-gdt-sm\",\n\t\t},\n\t},\n\tcompoundVariants: [\n\t\t{ placement: \"right\", size: \"sm\", className: \"gap-2\" },\n\t\t{ placement: \"right\", size: \"md\", className: \"gap-3\" },\n\t\t{ placement: \"right\", size: \"lg\", className: \"gap-3.5\" },\n\t\t{ placement: \"bottom\", className: \"gap-x-4 gap-y-2\" },\n\t],\n\tdefaultVariants: { placement: \"right\", size: \"md\" },\n});\n\nconst treeMapLegendDotVariants = cva(\"shrink-0 rounded-full\", {\n\tvariants: {\n\t\tsize: { sm: \"size-2\", md: \"size-2.5\", lg: \"size-3\" },\n\t},\n\tdefaultVariants: { size: \"md\" },\n});\n\n/** A tile / group resolved with its palette colours, ready to render. */\ntype ResolvedDatum = {\n\tlabel: string;\n\tvalue?: number;\n\tfill: string;\n\ttext: string;\n\tchildren?: ResolvedDatum[];\n};\n\n/**\n * Walk the data, assigning each top-level entry a palette colour (by order) that\n * its leaves inherit, and summing the leaf values into a grand total. Top-level\n * entries become the legend keys: tiles in `flat`, groups in `nested`.\n */\nfunction resolveData(data: TreeMapDatum[]): {\n\tresolved: ResolvedDatum[];\n\ttotal: number;\n} {\n\tlet total = 0;\n\n\tconst resolve = (\n\t\tdatum: TreeMapDatum,\n\t\tpalette: { fill: string; text: string },\n\t): ResolvedDatum => {\n\t\tconst fill = datum.fill ?? palette.fill;\n\t\tconst text = palette.text;\n\n\t\tif (datum.children?.length) {\n\t\t\treturn {\n\t\t\t\tlabel: datum.label,\n\t\t\t\tfill,\n\t\t\t\ttext,\n\t\t\t\tchildren: datum.children.map((child) => resolve(child, { fill, text })),\n\t\t\t};\n\t\t}\n\n\t\ttotal += datum.value ?? 0;\n\t\treturn { label: datum.label, value: datum.value, fill, text };\n\t};\n\n\tconst resolved = data.map((datum, i) =>\n\t\tresolve(datum, TREE_MAP_PALETTE[i % TREE_MAP_PALETTE.length]),\n\t);\n\n\treturn { resolved, total };\n}\n\ntype TreeMapProps = Omit<\n\tReact.ComponentProps<typeof ChartCard>,\n\t\"size\" | \"children\"\n> & {\n\t/** Categories — flat leaves, or groups carrying `children` (nested). */\n\tdata: TreeMapDatum[];\n\t/** Explicit size; otherwise inherited from the nearest `SizeProvider`. */\n\tsize?: TreeMapSize;\n\t/** Chart heading. Omit to hide the title. */\n\ttitle?: React.ReactNode;\n\t/** Supporting metadata (period, source). Omit to hide the description. */\n\tdescription?: React.ReactNode;\n\t/** Enable the hover value tooltip. Default false. */\n\ttooltip?: boolean;\n\t/** Legend placement — a right column or a wrapped bottom row. Default right. */\n\tlegend?: TreeMapLegendPlacement;\n\t/** Format the tile value in the tooltip. Defaults to a localised number. */\n\tvalueFormatter?: (value: number) => string;\n\t/** Value formatting for the tooltip. Defaults to `number`. */\n\tvalueType?: ChartValueType;\n};\n\nfunction TreeMap({\n\tdata,\n\tsize,\n\ttitle,\n\tdescription,\n\ttooltip = false,\n\tlegend = \"right\",\n\tvalueFormatter,\n\tvalueType = \"number\",\n\tclassName,\n\t...props\n}: TreeMapProps) {\n\tconst resolvedSize = useComponentSize(size);\n\tconst layout = TREE_MAP_LAYOUT[resolvedSize];\n\tconst { resolved, total } = resolveData(data);\n\n\t// recharts reads `value`/`label`/`children`/`fill` straight off each node;\n\t// the custom content below pulls `fill`, `text`, and the share from them.\n\tconst config = Object.fromEntries(\n\t\tresolved.map((datum) => [\n\t\t\tdatum.label,\n\t\t\t{ label: datum.label, color: datum.fill },\n\t\t]),\n\t) satisfies ChartConfig;\n\n\tconst tooltipNode = tooltip ? (\n\t\t<ChartTooltip\n\t\t\tcontent={\n\t\t\t\t<ChartTooltipContent\n\t\t\t\t\tnameKey=\"label\"\n\t\t\t\t\tvalueType={valueType}\n\t\t\t\t\tformatter={\n\t\t\t\t\t\tvalueFormatter\n\t\t\t\t\t\t\t? (value) =>\n\t\t\t\t\t\t\t\t\ttypeof value === \"number\" ? valueFormatter(value) : value\n\t\t\t\t\t\t\t: undefined\n\t\t\t\t\t}\n\t\t\t\t/>\n\t\t\t}\n\t\t/>\n\t) : null;\n\n\tconst legendNode = (\n\t\t<ul\n\t\t\tclassName={cn(\n\t\t\t\ttreeMapLegendVariants({ placement: legend, size: resolvedSize }),\n\t\t\t)}\n\t\t>\n\t\t\t{resolved.map((datum) => (\n\t\t\t\t<li\n\t\t\t\t\tkey={datum.label}\n\t\t\t\t\tclassName=\"flex items-center gap-2 text-fg-primary\"\n\t\t\t\t>\n\t\t\t\t\t<span\n\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\tclassName={cn(treeMapLegendDotVariants({ size: resolvedSize }))}\n\t\t\t\t\t\tstyle={{ backgroundColor: datum.fill }}\n\t\t\t\t\t/>\n\t\t\t\t\t<span className=\"min-w-0 truncate\">{datum.label}</span>\n\t\t\t\t</li>\n\t\t\t))}\n\t\t</ul>\n\t);\n\n\treturn (\n\t\t<ChartCard size={resolvedSize} className={className} {...props}>\n\t\t\t{(title != null || description != null) && (\n\t\t\t\t<ChartHeader>\n\t\t\t\t\t{title != null && <ChartTitle>{title}</ChartTitle>}\n\t\t\t\t\t{description != null && (\n\t\t\t\t\t\t<ChartDescription>{description}</ChartDescription>\n\t\t\t\t\t)}\n\t\t\t\t</ChartHeader>\n\t\t\t)}\n\t\t\t<div\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"flex gap-4\",\n\t\t\t\t\tlegend === \"right\" ? \"flex-row items-stretch\" : \"flex-col\",\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t<ChartContainer\n\t\t\t\t\tconfig={config}\n\t\t\t\t\tclassName=\"aspect-auto min-w-0 flex-1\"\n\t\t\t\t\tstyle={{ height: layout.height }}\n\t\t\t\t>\n\t\t\t\t\t<RechartsTreemap\n\t\t\t\t\t\tdata={resolved}\n\t\t\t\t\t\tdataKey=\"value\"\n\t\t\t\t\t\tnameKey=\"label\"\n\t\t\t\t\t\ttype=\"flat\"\n\t\t\t\t\t\tisAnimationActive={false}\n\t\t\t\t\t\tcontent={<TreeMapTile total={total} layout={layout} />}\n\t\t\t\t\t>\n\t\t\t\t\t\t{tooltipNode}\n\t\t\t\t\t</RechartsTreemap>\n\t\t\t\t</ChartContainer>\n\t\t\t\t{legendNode}\n\t\t\t</div>\n\t\t</ChartCard>\n\t);\n}\n\n/**\n * Custom recharts `Treemap` tile. recharts calls it for every node (root, groups,\n * leaves); only leaves carry a value and tile the whole plot, so non-leaves draw\n * nothing. A leaf renders an inset, rounded rectangle in its colour with an\n * in-tile label (name over its share of the whole), dropped when the tile is too\n * small to fit it.\n */\ntype TreeMapTileProps = Partial<TreemapNode> & {\n\ttotal: number;\n\tlayout: TreeMapLayout;\n\t/** Resolved tile colours, attached to each datum by `resolveData`. */\n\tfill?: string;\n\ttext?: string;\n};\n\nfunction TreeMapTile({\n\ttotal,\n\tlayout,\n\tx,\n\ty,\n\twidth,\n\theight,\n\tvalue,\n\tname,\n\tchildren,\n\tfill,\n\ttext,\n}: TreeMapTileProps) {\n\t// Non-leaf nodes (root, groups) are pure containers — their leaves cover them.\n\tif (\n\t\tchildren != null ||\n\t\tx == null ||\n\t\ty == null ||\n\t\twidth == null ||\n\t\theight == null\n\t) {\n\t\treturn <g />;\n\t}\n\n\tconst tileX = x + layout.gap / 2;\n\tconst tileY = y + layout.gap / 2;\n\tconst tileW = Math.max(0, width - layout.gap);\n\tconst tileH = Math.max(0, height - layout.gap);\n\n\tconst showLabel =\n\t\ttileW >= layout.labelMinSide && tileH >= layout.labelMinSide;\n\tconst share = total > 0 ? Math.round(((value ?? 0) / total) * 100) : 0;\n\n\treturn (\n\t\t<g>\n\t\t\t<rect\n\t\t\t\tx={tileX}\n\t\t\t\ty={tileY}\n\t\t\t\twidth={tileW}\n\t\t\t\theight={tileH}\n\t\t\t\trx={layout.radius}\n\t\t\t\try={layout.radius}\n\t\t\t\tfill={fill}\n\t\t\t/>\n\t\t\t{showLabel && (\n\t\t\t\t<text\n\t\t\t\t\tx={tileX + layout.labelPadding}\n\t\t\t\t\ty={tileY + layout.labelPadding}\n\t\t\t\t\tfill={text}\n\t\t\t\t\tdominantBaseline=\"hanging\"\n\t\t\t\t>\n\t\t\t\t\t<tspan\n\t\t\t\t\t\tx={tileX + layout.labelPadding}\n\t\t\t\t\t\tclassName=\"font-semibold\"\n\t\t\t\t\t\tstyle={{ fontSize: layout.nameFontSize }}\n\t\t\t\t\t>\n\t\t\t\t\t\t{name}\n\t\t\t\t\t</tspan>\n\t\t\t\t\t<tspan\n\t\t\t\t\t\tx={tileX + layout.labelPadding}\n\t\t\t\t\t\tdy={layout.nameFontSize + 4}\n\t\t\t\t\t\tclassName=\"tabular-nums\"\n\t\t\t\t\t\tstyle={{ fontSize: layout.shareFontSize }}\n\t\t\t\t\t>\n\t\t\t\t\t\t{share}%\n\t\t\t\t\t</tspan>\n\t\t\t\t</text>\n\t\t\t)}\n\t\t</g>\n\t);\n}\n\nexport { TREE_MAP_LAYOUT, TREE_MAP_PALETTE, TreeMap };\nexport type {\n\tTreeMapDatum,\n\tTreeMapLayout,\n\tTreeMapLegendPlacement,\n\tTreeMapProps,\n\tTreeMapSize,\n};\n"],"mappings":";AAAA,SAAS,aAAa,0BAA0B;AAChD,SAAS,wBAAwB;;;ACDjC,SAA0B,YAAY;AACtC,SAAS,2BAA2B;AAEpC,IAAM,UAAU,oBAAoB;AAAA,EACnC,QAAQ;AAAA,IACP,aAAa;AAAA,MACZ,aAAa;AAAA,QACZ;AAAA,UACC,MAAM;AAAA,YACL;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,UACD;AAAA,QACD;AAAA,MACD;AAAA,IACD;AAAA,EACD;AACD,CAAC;AAEM,SAAS,MAAM,QAAsB;AAC3C,SAAO,QAAQ,KAAK,MAAM,CAAC;AAC5B;;;ADpBE,cA6BC,YA7BD;AANF,SAAS,UAAU;AAAA,EAClB;AAAA,EACA,UAAU;AAAA,EACV,GAAG;AACJ,GAAsE;AACrE,SACC;AAAA,IAAC,mBAAmB;AAAA,IAAnB;AAAA,MACA,aAAU;AAAA,MACV,gBAAc;AAAA,MACd,WAAW,GAAG,8CAA8C,SAAS;AAAA,MACpE,GAAG;AAAA;AAAA,EACL;AAEF;AAEA,SAAS,cAAc,EAAE,WAAW,GAAG,MAAM,GAAkC;AAC9E,SACC;AAAA,IAAC,mBAA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,IAAI,OAAO;AAAA,QACX;AAAA;AAAA,IACD;AAAA,IACC,aACA,gBAAAC;AAAA,MAAC;AAAA;AAAA,QACA,GAAG,QAAQ,OAAO;AAAA,QAClB,GAAG,QAAQ,OAAO;AAAA,QAClB,MAAM;AAAA,QACN,kBAAiB;AAAA,QAEjB;AAAA,0BAAAD;AAAA,YAAC;AAAA;AAAA,cACA,GAAG,QAAQ,OAAO;AAAA,cAClB,WAAU;AAAA,cACV,OAAO,EAAE,UAAU,OAAO,aAAa;AAAA,cAEtC;AAAA;AAAA,UACF;AAAA,UACA,gBAAAC;AAAA,YAAC;AAAA;AAAA,cACA,GAAG,QAAQ,OAAO;AAAA,cAClB,IAAI,OAAO,eAAe;AAAA,cAC1B,WAAU;AAAA,cACV,OAAO,EAAE,UAAU,OAAO,cAAc;AAAA,cAEvC;AAAA;AAAA,gBAAM;AAAA;AAAA;AAAA,UACR;AAAA;AAAA;AAAA,IACD;AAAA,KAEF;AAEF;","names":["jsx","jsx","cva","jsx","cva","cva","Fragment","jsx","jsxs","cva","config","jsx","mergeProps","useRender","ChevronRightIcon","jsx","jsxs","useRender","mergeProps","ChevronRightIcon","jsx","jsxs","cva","jsx","jsxs","cva","mergeProps","useRender","cva","jsx","jsx","cva","useRender","mergeProps","ChevronRightIcon","React","jsx","className","props","ChevronRightIcon","mergeProps","useRender","cva","cva","useRender","mergeProps","cva","ChevronLeftIcon","ChevronRightIcon","React","jsx","jsxs","cva","api","ChevronLeftIcon","ChevronRightIcon","dots","cva","jsx","cva","jsx","cva","CheckIcon","React","cva","cva","createContext","useContext","Fragment","jsx","jsx","cva","cva","jsx","cva","jsx","cva","jsx","jsxs","cva","CheckIcon","React","jsx","jsxs","jsx","jsxs","cva","XIcon","jsx","jsxs","cva","XIcon","cva","CheckIcon","ChevronRightIcon","jsx","jsxs","cva","ChevronRightIcon","CheckIcon","createContext","useCallback","useRef","useState","jsx","jsxs","createContext","cva","jsx","cva","cva","jsx","jsxs","jsx","jsxs","cva","cva","jsx","jsxs","cva","mergeProps","useRender","useRender","mergeProps","mergeProps","useRender","cva","jsx","Fragment","jsx","jsxs","useRender","mergeProps","cva","jsx","jsxs","jsx","cva","ChevronLeftIcon","ChevronRightIcon","MoreHorizontalIcon","jsx","jsxs","cva","ChevronLeftIcon","ChevronRightIcon","MoreHorizontalIcon","React","jsx","jsxs","CheckIcon","ChevronDownIcon","React","jsx","jsxs","ChevronDownIcon","CheckIcon","DialogPrimitive","ChevronLeftIcon","ChevronRightIcon","XIcon","React","Fragment","jsx","jsxs","ChevronLeftIcon","ChevronRightIcon","DialogPrimitive","XIcon","cva","jsx","jsxs","cva","cva","React","jsx","jsxs","cva","cva","jsx","cva","React","jsx","jsxs","X","React","jsx","jsxs","SearchInput","X","cva","CheckIcon","ChevronDownIcon","React","jsx","jsxs","cva","ChevronDownIcon","CheckIcon","cva","XIcon","jsx","jsxs","cva","XIcon","mergeProps","useRender","cva","React","React","useState","PopoverPrimitive","jsx","jsxs","Tooltip","PopoverPrimitive","jsx","jsxs","open","useRender","mergeProps","cva","Tooltip","Bar","BarChart","XAxis","jsx","jsxs","BarChart","Bar","XAxis","cva","CheckIcon","React","jsx","jsxs","cva","CheckIcon","cva","jsx","cva","ChevronDownIcon","useState","cva","jsx","jsxs","cva","jsx","jsxs","useState","ChevronDownIcon","jsx","cva","X","jsx","jsxs","cva","X","React","jsx","jsxs","X","jsx","jsxs","X","cva","jsx","jsxs","cva"]}