shadcn-glass-ui 2.2.3 → 2.3.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 (370) hide show
  1. package/CHANGELOG.md +57 -1
  2. package/dist/cli/commands/info.d.ts +15 -0
  3. package/dist/cli/commands/info.d.ts.map +1 -0
  4. package/dist/cli/commands/list.d.ts +23 -0
  5. package/dist/cli/commands/list.d.ts.map +1 -0
  6. package/dist/cli/index.cjs +1 -1
  7. package/dist/cli/index.d.ts.map +1 -0
  8. package/dist/cli/{index.js → index.mjs} +1 -1
  9. package/dist/cli/index.mjs.map +1 -0
  10. package/dist/cli/utils/format.d.ts +76 -0
  11. package/dist/cli/utils/format.d.ts.map +1 -0
  12. package/dist/cli/utils/fuzzy-search.d.ts +73 -0
  13. package/dist/cli/utils/fuzzy-search.d.ts.map +1 -0
  14. package/dist/cli/utils/load-exports.d.ts +141 -0
  15. package/dist/cli/utils/load-exports.d.ts.map +1 -0
  16. package/dist/components/blocks/avatar-gallery/index.d.ts +2 -0
  17. package/dist/components/blocks/avatar-gallery/index.d.ts.map +1 -0
  18. package/dist/components/blocks/avatar-gallery/page.d.ts +7 -0
  19. package/dist/components/blocks/avatar-gallery/page.d.ts.map +1 -0
  20. package/dist/components/blocks/badges/index.d.ts +2 -0
  21. package/dist/components/blocks/badges/index.d.ts.map +1 -0
  22. package/dist/components/blocks/badges/page.d.ts +7 -0
  23. package/dist/components/blocks/badges/page.d.ts.map +1 -0
  24. package/dist/components/blocks/buttons/index.d.ts +2 -0
  25. package/dist/components/blocks/buttons/index.d.ts.map +1 -0
  26. package/dist/components/blocks/buttons/page.d.ts +7 -0
  27. package/dist/components/blocks/buttons/page.d.ts.map +1 -0
  28. package/dist/components/blocks/form-elements/index.d.ts +2 -0
  29. package/dist/components/blocks/form-elements/index.d.ts.map +1 -0
  30. package/dist/components/blocks/form-elements/page.d.ts +7 -0
  31. package/dist/components/blocks/form-elements/page.d.ts.map +1 -0
  32. package/dist/components/blocks/index.d.ts +14 -0
  33. package/dist/components/blocks/index.d.ts.map +1 -0
  34. package/dist/components/blocks/notifications/index.d.ts +2 -0
  35. package/dist/components/blocks/notifications/index.d.ts.map +1 -0
  36. package/dist/components/blocks/notifications/page.d.ts +7 -0
  37. package/dist/components/blocks/notifications/page.d.ts.map +1 -0
  38. package/dist/components/blocks/progress/index.d.ts +2 -0
  39. package/dist/components/blocks/progress/index.d.ts.map +1 -0
  40. package/dist/components/blocks/progress/page.d.ts +7 -0
  41. package/dist/components/blocks/progress/page.d.ts.map +1 -0
  42. package/dist/components/blocks/registry.d.ts +16 -0
  43. package/dist/components/blocks/registry.d.ts.map +1 -0
  44. package/dist/components/demos/AnimatedBackground.d.ts +5 -0
  45. package/dist/components/demos/AnimatedBackground.d.ts.map +1 -0
  46. package/dist/components/demos/ComponentShowcase.d.ts +6 -0
  47. package/dist/components/demos/ComponentShowcase.d.ts.map +1 -0
  48. package/dist/components/demos/DesktopShowcase.d.ts +3 -0
  49. package/dist/components/demos/DesktopShowcase.d.ts.map +1 -0
  50. package/dist/components/demos/GlassFixesDemo.d.ts +6 -0
  51. package/dist/components/demos/GlassFixesDemo.d.ts.map +1 -0
  52. package/dist/components/demos/MobileShowcase.d.ts +3 -0
  53. package/dist/components/demos/MobileShowcase.d.ts.map +1 -0
  54. package/dist/components/glass/atomic/expandable-header-glass.d.ts +16 -0
  55. package/dist/components/glass/atomic/expandable-header-glass.d.ts.map +1 -0
  56. package/dist/components/glass/atomic/icon-button-glass.d.ts +18 -0
  57. package/dist/components/glass/atomic/icon-button-glass.d.ts.map +1 -0
  58. package/dist/components/glass/atomic/index.d.ts +14 -0
  59. package/dist/components/glass/atomic/index.d.ts.map +1 -0
  60. package/dist/components/glass/atomic/insight-card-glass.d.ts +22 -0
  61. package/dist/components/glass/atomic/insight-card-glass.d.ts.map +1 -0
  62. package/dist/components/glass/atomic/search-box-glass.d.ts +17 -0
  63. package/dist/components/glass/atomic/search-box-glass.d.ts.map +1 -0
  64. package/dist/components/glass/atomic/sort-dropdown-glass.d.ts +38 -0
  65. package/dist/components/glass/atomic/sort-dropdown-glass.d.ts.map +1 -0
  66. package/dist/components/glass/atomic/stat-item-glass.d.ts +22 -0
  67. package/dist/components/glass/atomic/stat-item-glass.d.ts.map +1 -0
  68. package/dist/components/glass/atomic/theme-toggle-glass.d.ts +11 -0
  69. package/dist/components/glass/atomic/theme-toggle-glass.d.ts.map +1 -0
  70. package/dist/components/glass/composite/ai-card-glass.d.ts +7 -0
  71. package/dist/components/glass/composite/ai-card-glass.d.ts.map +1 -0
  72. package/dist/components/glass/composite/career-stats-header-glass.d.ts +15 -0
  73. package/dist/components/glass/composite/career-stats-header-glass.d.ts.map +1 -0
  74. package/dist/components/glass/composite/circular-metric-glass.d.ts +24 -0
  75. package/dist/components/glass/composite/circular-metric-glass.d.ts.map +1 -0
  76. package/dist/components/glass/composite/contribution-metrics-glass.d.ts +15 -0
  77. package/dist/components/glass/composite/contribution-metrics-glass.d.ts.map +1 -0
  78. package/dist/components/glass/composite/index.d.ts +22 -0
  79. package/dist/components/glass/composite/index.d.ts.map +1 -0
  80. package/dist/components/glass/composite/metric-card-glass.d.ts +96 -0
  81. package/dist/components/glass/composite/metric-card-glass.d.ts.map +1 -0
  82. package/dist/components/glass/composite/metrics-grid-glass.d.ts +17 -0
  83. package/dist/components/glass/composite/metrics-grid-glass.d.ts.map +1 -0
  84. package/dist/components/glass/composite/repository-card-glass.d.ts +16 -0
  85. package/dist/components/glass/composite/repository-card-glass.d.ts.map +1 -0
  86. package/dist/components/glass/composite/repository-header-glass.d.ts +16 -0
  87. package/dist/components/glass/composite/repository-header-glass.d.ts.map +1 -0
  88. package/dist/components/glass/composite/repository-metadata-glass.d.ts +13 -0
  89. package/dist/components/glass/composite/repository-metadata-glass.d.ts.map +1 -0
  90. package/dist/components/glass/composite/split-layout-glass/index.d.ts +16 -0
  91. package/dist/components/glass/composite/split-layout-glass/index.d.ts.map +1 -0
  92. package/dist/components/glass/composite/split-layout-glass/split-layout-accordion.d.ts +66 -0
  93. package/dist/components/glass/composite/split-layout-glass/split-layout-accordion.d.ts.map +1 -0
  94. package/dist/components/glass/composite/split-layout-glass/split-layout-context.d.ts +122 -0
  95. package/dist/components/glass/composite/split-layout-glass/split-layout-context.d.ts.map +1 -0
  96. package/dist/components/glass/composite/split-layout-glass/split-layout-glass.d.ts +177 -0
  97. package/dist/components/glass/composite/split-layout-glass/split-layout-glass.d.ts.map +1 -0
  98. package/dist/components/glass/composite/trust-score-display-glass.d.ts +15 -0
  99. package/dist/components/glass/composite/trust-score-display-glass.d.ts.map +1 -0
  100. package/dist/components/glass/composite/user-info-glass.d.ts +15 -0
  101. package/dist/components/glass/composite/user-info-glass.d.ts.map +1 -0
  102. package/dist/components/glass/composite/user-stats-line-glass.d.ts +15 -0
  103. package/dist/components/glass/composite/user-stats-line-glass.d.ts.map +1 -0
  104. package/dist/components/glass/composite/year-card-glass.d.ts +53 -0
  105. package/dist/components/glass/composite/year-card-glass.d.ts.map +1 -0
  106. package/dist/components/glass/index.d.ts +16 -0
  107. package/dist/components/glass/index.d.ts.map +1 -0
  108. package/dist/components/glass/primitives/form-field-wrapper.d.ts +69 -0
  109. package/dist/components/glass/primitives/form-field-wrapper.d.ts.map +1 -0
  110. package/dist/components/glass/primitives/index.d.ts +12 -0
  111. package/dist/components/glass/primitives/index.d.ts.map +1 -0
  112. package/dist/components/glass/primitives/interactive-card.d.ts +91 -0
  113. package/dist/components/glass/primitives/interactive-card.d.ts.map +1 -0
  114. package/dist/components/glass/primitives/style-utils.d.ts +147 -0
  115. package/dist/components/glass/primitives/style-utils.d.ts.map +1 -0
  116. package/dist/components/glass/primitives/touch-target.d.ts +46 -0
  117. package/dist/components/glass/primitives/touch-target.d.ts.map +1 -0
  118. package/dist/components/glass/sections/career-stats-glass.d.ts +17 -0
  119. package/dist/components/glass/sections/career-stats-glass.d.ts.map +1 -0
  120. package/dist/components/glass/sections/flags-section-glass.d.ts +13 -0
  121. package/dist/components/glass/sections/flags-section-glass.d.ts.map +1 -0
  122. package/dist/components/glass/sections/header-branding-glass.d.ts +16 -0
  123. package/dist/components/glass/sections/header-branding-glass.d.ts.map +1 -0
  124. package/dist/components/glass/sections/header-nav-glass.d.ts +7 -0
  125. package/dist/components/glass/sections/header-nav-glass.d.ts.map +1 -0
  126. package/dist/components/glass/sections/index.d.ts +13 -0
  127. package/dist/components/glass/sections/index.d.ts.map +1 -0
  128. package/dist/components/glass/sections/profile-header-glass.d.ts +16 -0
  129. package/dist/components/glass/sections/profile-header-glass.d.ts.map +1 -0
  130. package/dist/components/glass/sections/projects-list-glass.d.ts +42 -0
  131. package/dist/components/glass/sections/projects-list-glass.d.ts.map +1 -0
  132. package/dist/components/glass/sections/trust-score-card-glass.d.ts +12 -0
  133. package/dist/components/glass/sections/trust-score-card-glass.d.ts.map +1 -0
  134. package/dist/components/glass/specialized/base-progress-glass.d.ts +8 -0
  135. package/dist/components/glass/specialized/base-progress-glass.d.ts.map +1 -0
  136. package/dist/components/glass/specialized/flag-alert-glass.d.ts +8 -0
  137. package/dist/components/glass/specialized/flag-alert-glass.d.ts.map +1 -0
  138. package/dist/components/glass/specialized/index.d.ts +21 -0
  139. package/dist/components/glass/specialized/index.d.ts.map +1 -0
  140. package/dist/components/glass/specialized/language-bar-glass.d.ts +24 -0
  141. package/dist/components/glass/specialized/language-bar-glass.d.ts.map +1 -0
  142. package/dist/components/glass/specialized/profile-avatar-glass.d.ts +26 -0
  143. package/dist/components/glass/specialized/profile-avatar-glass.d.ts.map +1 -0
  144. package/dist/components/glass/specialized/progress-glass.d.ts +9 -0
  145. package/dist/components/glass/specialized/progress-glass.d.ts.map +1 -0
  146. package/dist/components/glass/specialized/rainbow-progress-glass.d.ts +8 -0
  147. package/dist/components/glass/specialized/rainbow-progress-glass.d.ts.map +1 -0
  148. package/dist/components/glass/specialized/segmented-control-glass.d.ts +11 -0
  149. package/dist/components/glass/specialized/segmented-control-glass.d.ts.map +1 -0
  150. package/dist/components/glass/specialized/sparkline-glass.d.ts +34 -0
  151. package/dist/components/glass/specialized/sparkline-glass.d.ts.map +1 -0
  152. package/dist/components/glass/specialized/status-indicator-glass.d.ts +8 -0
  153. package/dist/components/glass/specialized/status-indicator-glass.d.ts.map +1 -0
  154. package/dist/components/glass/ui/alert-glass.d.ts +13 -0
  155. package/dist/components/glass/ui/alert-glass.d.ts.map +1 -0
  156. package/dist/components/glass/ui/avatar-glass.d.ts +58 -0
  157. package/dist/components/glass/ui/avatar-glass.d.ts.map +1 -0
  158. package/dist/components/glass/ui/badge-glass.d.ts +74 -0
  159. package/dist/components/glass/ui/badge-glass.d.ts.map +1 -0
  160. package/dist/components/glass/ui/button-glass.d.ts +110 -0
  161. package/dist/components/glass/ui/button-glass.d.ts.map +1 -0
  162. package/dist/components/glass/ui/card-glass.d.ts +115 -0
  163. package/dist/components/glass/ui/card-glass.d.ts.map +1 -0
  164. package/dist/components/glass/ui/checkbox-glass.d.ts +113 -0
  165. package/dist/components/glass/ui/checkbox-glass.d.ts.map +1 -0
  166. package/dist/components/glass/ui/circular-progress-glass.d.ts +36 -0
  167. package/dist/components/glass/ui/circular-progress-glass.d.ts.map +1 -0
  168. package/dist/components/glass/ui/combobox-glass.d.ts +61 -0
  169. package/dist/components/glass/ui/combobox-glass.d.ts.map +1 -0
  170. package/dist/components/glass/ui/dropdown-glass.d.ts +83 -0
  171. package/dist/components/glass/ui/dropdown-glass.d.ts.map +1 -0
  172. package/dist/components/glass/ui/dropdown-menu-glass.d.ts +77 -0
  173. package/dist/components/glass/ui/dropdown-menu-glass.d.ts.map +1 -0
  174. package/dist/components/glass/ui/glass-card.d.ts +78 -0
  175. package/dist/components/glass/ui/glass-card.d.ts.map +1 -0
  176. package/dist/components/glass/ui/index.d.ts +44 -0
  177. package/dist/components/glass/ui/index.d.ts.map +1 -0
  178. package/dist/components/glass/ui/input-glass.d.ts +98 -0
  179. package/dist/components/glass/ui/input-glass.d.ts.map +1 -0
  180. package/dist/components/glass/ui/modal-glass.d.ts +180 -0
  181. package/dist/components/glass/ui/modal-glass.d.ts.map +1 -0
  182. package/dist/components/glass/ui/notification-glass.d.ts +13 -0
  183. package/dist/components/glass/ui/notification-glass.d.ts.map +1 -0
  184. package/dist/components/glass/ui/popover-glass.d.ts +71 -0
  185. package/dist/components/glass/ui/popover-glass.d.ts.map +1 -0
  186. package/dist/components/glass/ui/sidebar-glass/index.d.ts +100 -0
  187. package/dist/components/glass/ui/sidebar-glass/index.d.ts.map +1 -0
  188. package/dist/components/glass/ui/sidebar-glass/sidebar-context.d.ts +96 -0
  189. package/dist/components/glass/ui/sidebar-glass/sidebar-context.d.ts.map +1 -0
  190. package/dist/components/glass/ui/sidebar-glass/sidebar-glass.d.ts +88 -0
  191. package/dist/components/glass/ui/sidebar-glass/sidebar-glass.d.ts.map +1 -0
  192. package/dist/components/glass/ui/sidebar-glass/sidebar-menu.d.ts +121 -0
  193. package/dist/components/glass/ui/sidebar-glass/sidebar-menu.d.ts.map +1 -0
  194. package/dist/components/glass/ui/skeleton-glass.d.ts +8 -0
  195. package/dist/components/glass/ui/skeleton-glass.d.ts.map +1 -0
  196. package/dist/components/glass/ui/slider-glass.d.ts +38 -0
  197. package/dist/components/glass/ui/slider-glass.d.ts.map +1 -0
  198. package/dist/components/glass/ui/stepper-glass.d.ts +63 -0
  199. package/dist/components/glass/ui/stepper-glass.d.ts.map +1 -0
  200. package/dist/components/glass/ui/tabs-glass.d.ts +199 -0
  201. package/dist/components/glass/ui/tabs-glass.d.ts.map +1 -0
  202. package/dist/components/glass/ui/toggle-glass.d.ts +27 -0
  203. package/dist/components/glass/ui/toggle-glass.d.ts.map +1 -0
  204. package/dist/components/glass/ui/tooltip-glass.d.ts +65 -0
  205. package/dist/components/glass/ui/tooltip-glass.d.ts.map +1 -0
  206. package/dist/components/ui/alert.d.ts +8 -0
  207. package/dist/components/ui/alert.d.ts.map +1 -0
  208. package/dist/components/ui/avatar.d.ts +7 -0
  209. package/dist/components/ui/avatar.d.ts.map +1 -0
  210. package/dist/components/ui/badge.d.ts +8 -0
  211. package/dist/components/ui/badge.d.ts.map +1 -0
  212. package/dist/components/ui/button.d.ts +8 -0
  213. package/dist/components/ui/button.d.ts.map +1 -0
  214. package/dist/components/ui/card.d.ts +10 -0
  215. package/dist/components/ui/card.d.ts.map +1 -0
  216. package/dist/components/ui/chart.d.ts +69 -0
  217. package/dist/components/ui/chart.d.ts.map +1 -0
  218. package/dist/components/ui/checkbox.d.ts +5 -0
  219. package/dist/components/ui/checkbox.d.ts.map +1 -0
  220. package/dist/components/ui/collapsible.d.ts +6 -0
  221. package/dist/components/ui/collapsible.d.ts.map +1 -0
  222. package/dist/components/ui/command.d.ts +19 -0
  223. package/dist/components/ui/command.d.ts.map +1 -0
  224. package/dist/components/ui/dialog.d.ts +16 -0
  225. package/dist/components/ui/dialog.d.ts.map +1 -0
  226. package/dist/components/ui/dropdown-menu.d.ts +26 -0
  227. package/dist/components/ui/dropdown-menu.d.ts.map +1 -0
  228. package/dist/components/ui/input.d.ts +4 -0
  229. package/dist/components/ui/input.d.ts.map +1 -0
  230. package/dist/components/ui/popover.d.ts +8 -0
  231. package/dist/components/ui/popover.d.ts.map +1 -0
  232. package/dist/components/ui/progress.d.ts +5 -0
  233. package/dist/components/ui/progress.d.ts.map +1 -0
  234. package/dist/components/ui/scroll-area.d.ts +6 -0
  235. package/dist/components/ui/scroll-area.d.ts.map +1 -0
  236. package/dist/components/ui/separator.d.ts +5 -0
  237. package/dist/components/ui/separator.d.ts.map +1 -0
  238. package/dist/components/ui/skeleton.d.ts +3 -0
  239. package/dist/components/ui/skeleton.d.ts.map +1 -0
  240. package/dist/components/ui/slider.d.ts +5 -0
  241. package/dist/components/ui/slider.d.ts.map +1 -0
  242. package/dist/components/ui/sonner.d.ts +4 -0
  243. package/dist/components/ui/sonner.d.ts.map +1 -0
  244. package/dist/components/ui/switch.d.ts +5 -0
  245. package/dist/components/ui/switch.d.ts.map +1 -0
  246. package/dist/components/ui/tabs.d.ts +8 -0
  247. package/dist/components/ui/tabs.d.ts.map +1 -0
  248. package/dist/components/ui/tooltip.d.ts +8 -0
  249. package/dist/components/ui/tooltip.d.ts.map +1 -0
  250. package/dist/components.cjs +4 -4
  251. package/dist/components.d.ts +56 -1932
  252. package/dist/components.d.ts.map +1 -0
  253. package/dist/components.mjs +5 -0
  254. package/dist/hooks.cjs +2 -2
  255. package/dist/hooks.d.ts +5 -225
  256. package/dist/hooks.d.ts.map +1 -0
  257. package/dist/{hooks.js → hooks.mjs} +2 -2
  258. package/dist/index.cjs +48 -1109
  259. package/dist/index.cjs.map +1 -1
  260. package/dist/index.d.ts +83 -1
  261. package/dist/index.d.ts.map +1 -0
  262. package/dist/{index.js → index.mjs} +29 -1115
  263. package/dist/index.mjs.map +1 -0
  264. package/dist/lib/config.d.ts +28 -0
  265. package/dist/lib/config.d.ts.map +1 -0
  266. package/dist/lib/hooks/index.d.ts +11 -0
  267. package/dist/lib/hooks/index.d.ts.map +1 -0
  268. package/dist/lib/hooks/use-focus.d.ts +61 -0
  269. package/dist/lib/hooks/use-focus.d.ts.map +1 -0
  270. package/dist/lib/hooks/use-hover.d.ts +54 -0
  271. package/dist/lib/hooks/use-hover.d.ts.map +1 -0
  272. package/dist/lib/hooks/use-responsive.d.ts +44 -0
  273. package/dist/lib/hooks/use-responsive.d.ts.map +1 -0
  274. package/dist/lib/hooks/use-wallpaper-tint.d.ts +57 -0
  275. package/dist/lib/hooks/use-wallpaper-tint.d.ts.map +1 -0
  276. package/dist/lib/hooks.d.ts +92 -0
  277. package/dist/lib/hooks.d.ts.map +1 -0
  278. package/dist/lib/theme/tokens.d.ts +441 -0
  279. package/dist/lib/theme/tokens.d.ts.map +1 -0
  280. package/dist/lib/theme-context.d.ts +115 -0
  281. package/dist/lib/theme-context.d.ts.map +1 -0
  282. package/dist/lib/types.d.ts +24 -0
  283. package/dist/lib/types.d.ts.map +1 -0
  284. package/dist/lib/utils.d.ts +8 -0
  285. package/dist/lib/utils.d.ts.map +1 -0
  286. package/dist/lib/variants/alert-glass-variants.d.ts +10 -0
  287. package/dist/lib/variants/alert-glass-variants.d.ts.map +1 -0
  288. package/dist/lib/variants/alert-variants.d.ts +8 -0
  289. package/dist/lib/variants/alert-variants.d.ts.map +1 -0
  290. package/dist/lib/variants/avatar-glass-variants.d.ts +12 -0
  291. package/dist/lib/variants/avatar-glass-variants.d.ts.map +1 -0
  292. package/dist/lib/variants/badge-glass-variants.d.ts +10 -0
  293. package/dist/lib/variants/badge-glass-variants.d.ts.map +1 -0
  294. package/dist/lib/variants/badge-variants.d.ts +8 -0
  295. package/dist/lib/variants/badge-variants.d.ts.map +1 -0
  296. package/dist/lib/variants/button-glass-variants.d.ts +29 -0
  297. package/dist/lib/variants/button-glass-variants.d.ts.map +1 -0
  298. package/dist/lib/variants/button-variants.d.ts +9 -0
  299. package/dist/lib/variants/button-variants.d.ts.map +1 -0
  300. package/dist/lib/variants/dropdown-content-styles.d.ts +102 -0
  301. package/dist/lib/variants/dropdown-content-styles.d.ts.map +1 -0
  302. package/dist/lib/variants/dropdown-glass-variants.d.ts +9 -0
  303. package/dist/lib/variants/dropdown-glass-variants.d.ts.map +1 -0
  304. package/dist/lib/variants/glass-card-variants.d.ts +13 -0
  305. package/dist/lib/variants/glass-card-variants.d.ts.map +1 -0
  306. package/dist/lib/variants/index.d.ts +26 -0
  307. package/dist/lib/variants/index.d.ts.map +1 -0
  308. package/dist/lib/variants/input-glass-variants.d.ts +9 -0
  309. package/dist/lib/variants/input-glass-variants.d.ts.map +1 -0
  310. package/dist/lib/variants/insight-card-glass-variants.d.ts +11 -0
  311. package/dist/lib/variants/insight-card-glass-variants.d.ts.map +1 -0
  312. package/dist/lib/variants/modal-glass-variants.d.ts +9 -0
  313. package/dist/lib/variants/modal-glass-variants.d.ts.map +1 -0
  314. package/dist/lib/variants/notification-glass-variants.d.ts +9 -0
  315. package/dist/lib/variants/notification-glass-variants.d.ts.map +1 -0
  316. package/dist/lib/variants/progress-glass-variants.d.ts +10 -0
  317. package/dist/lib/variants/progress-glass-variants.d.ts.map +1 -0
  318. package/dist/lib/variants/skeleton-glass-variants.d.ts +9 -0
  319. package/dist/lib/variants/skeleton-glass-variants.d.ts.map +1 -0
  320. package/dist/lib/variants/sparkline-glass-variants.d.ts +10 -0
  321. package/dist/lib/variants/sparkline-glass-variants.d.ts.map +1 -0
  322. package/dist/lib/variants/stepper-glass-variants.d.ts +40 -0
  323. package/dist/lib/variants/stepper-glass-variants.d.ts.map +1 -0
  324. package/dist/lib/variants/toggle-glass-variants.d.ts +26 -0
  325. package/dist/lib/variants/toggle-glass-variants.d.ts.map +1 -0
  326. package/dist/lib/variants/tooltip-glass-variants.d.ts +9 -0
  327. package/dist/lib/variants/tooltip-glass-variants.d.ts.map +1 -0
  328. package/dist/r/checkbox-glass.json +3 -2
  329. package/dist/r/tabs-glass.json +4 -2
  330. package/dist/{theme-context-_T5r1KG4.js → theme-context-DLS2uAgJ.mjs} +1 -1
  331. package/dist/theme-context-DLS2uAgJ.mjs.map +1 -0
  332. package/dist/{theme-context-BEA8K_rq.cjs → theme-context-DmTETrFi.cjs} +2 -2
  333. package/dist/{theme-context-BEA8K_rq.cjs.map → theme-context-DmTETrFi.cjs.map} +1 -1
  334. package/dist/themes.cjs +1 -1
  335. package/dist/themes.d.ts +2 -124
  336. package/dist/themes.d.ts.map +1 -0
  337. package/dist/{themes.js → themes.mjs} +1 -1
  338. package/dist/trust-score-card-glass-3VBi9soW.cjs +4893 -0
  339. package/dist/trust-score-card-glass-3VBi9soW.cjs.map +1 -0
  340. package/dist/trust-score-card-glass-EfMB5l5J.mjs +4226 -0
  341. package/dist/trust-score-card-glass-EfMB5l5J.mjs.map +1 -0
  342. package/dist/{use-focus-CX0TJJIj.js → use-focus-C5kPAKr_.mjs} +1 -1
  343. package/dist/use-focus-C5kPAKr_.mjs.map +1 -0
  344. package/dist/{use-focus-CdoUzFQ8.cjs → use-focus-CswOSq71.cjs} +2 -2
  345. package/dist/{use-focus-CdoUzFQ8.cjs.map → use-focus-CswOSq71.cjs.map} +1 -1
  346. package/dist/{use-wallpaper-tint-DUgmytlY.js → use-wallpaper-tint-C0kYXNiN.mjs} +1 -1
  347. package/dist/use-wallpaper-tint-C0kYXNiN.mjs.map +1 -0
  348. package/dist/{use-wallpaper-tint-Rq5UgY9L.cjs → use-wallpaper-tint-WtRWtupA.cjs} +2 -2
  349. package/dist/{use-wallpaper-tint-Rq5UgY9L.cjs.map → use-wallpaper-tint-WtRWtupA.cjs.map} +1 -1
  350. package/dist/{utils-CcyeqpKQ.js → utils-B792GPM_.mjs} +1 -1
  351. package/dist/utils-B792GPM_.mjs.map +1 -0
  352. package/dist/{utils-NLnOCttr.cjs → utils-DX6rdBol.cjs} +2 -2
  353. package/dist/{utils-NLnOCttr.cjs.map → utils-DX6rdBol.cjs.map} +1 -1
  354. package/dist/utils.cjs +1 -1
  355. package/dist/utils.d.ts +2 -10
  356. package/dist/utils.d.ts.map +1 -0
  357. package/dist/utils.mjs +2 -0
  358. package/package.json +8 -8
  359. package/dist/cli/index.js.map +0 -1
  360. package/dist/components.js +0 -5
  361. package/dist/index.js.map +0 -1
  362. package/dist/theme-context-_T5r1KG4.js.map +0 -1
  363. package/dist/trust-score-card-glass-DTS1RdIt.cjs +0 -28660
  364. package/dist/trust-score-card-glass-DTS1RdIt.cjs.map +0 -1
  365. package/dist/trust-score-card-glass-Dg4_b_g_.js +0 -27660
  366. package/dist/trust-score-card-glass-Dg4_b_g_.js.map +0 -1
  367. package/dist/use-focus-CX0TJJIj.js.map +0 -1
  368. package/dist/use-wallpaper-tint-DUgmytlY.js.map +0 -1
  369. package/dist/utils-CcyeqpKQ.js.map +0 -1
  370. package/dist/utils.js +0 -2
@@ -0,0 +1,4226 @@
1
+ import { t as cn } from "./utils-B792GPM_.mjs";
2
+ import { n as useHover, t as useFocus } from "./use-focus-C5kPAKr_.mjs";
3
+ import { o as useTheme } from "./theme-context-DLS2uAgJ.mjs";
4
+ import * as React from "react";
5
+ import { createContext, forwardRef, useCallback, useContext, useEffect, useId, useMemo, useRef, useState } from "react";
6
+ import { AlertCircle, AlertTriangle, ArrowDown, ArrowUp, Calendar, Check, CheckCircle, CheckIcon, ChevronDown, ChevronRight, ChevronRightIcon, ChevronUp, ChevronsUpDownIcon, CircleIcon, Clock, Code, ExternalLink, FolderGit2, GitPullRequest, Github, Info, Minus, Moon, Palette, RefreshCw, Search, SearchIcon, Sparkles, Star, Sun, Target, TrendingDown, TrendingUp, User, Users, X, Zap } from "lucide-react";
7
+ import { cva } from "class-variance-authority";
8
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
9
+ import * as AvatarPrimitive from "@radix-ui/react-avatar";
10
+ import { Slot } from "@radix-ui/react-slot";
11
+ import * as PopoverPrimitive from "@radix-ui/react-popover";
12
+ import { Command } from "cmdk";
13
+ import * as DialogPrimitive from "@radix-ui/react-dialog";
14
+ import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
15
+ import * as SliderPrimitive from "@radix-ui/react-slider";
16
+ import * as TooltipPrimitive from "@radix-ui/react-tooltip";
17
+ import { Bar, BarChart, Cell, ResponsiveContainer, Tooltip } from "recharts";
18
+ const alertVariants = cva("flex items-start gap-2 md:gap-3 p-3 md:p-4 rounded-xl transition-all duration-300 backdrop-blur-sm min-w-96 max-w-2xl", {
19
+ variants: { variant: {
20
+ default: "",
21
+ destructive: "",
22
+ success: "",
23
+ warning: "",
24
+ info: "",
25
+ error: ""
26
+ } },
27
+ defaultVariants: { variant: "default" }
28
+ });
29
+ const ICON_SIZES = {
30
+ xs: "w-2.5 h-2.5 md:w-3 md:h-3",
31
+ sm: "w-3 h-3 md:w-3.5 md:h-3.5",
32
+ md: "w-3.5 h-3.5 md:w-4 md:h-4",
33
+ lg: "w-4 h-4 md:w-5 md:h-5",
34
+ xl: "w-5 h-5 md:w-6 md:h-6"
35
+ };
36
+ const TouchTarget = forwardRef(({ children, minSize = 44, center = true, className, ...props }, ref) => {
37
+ return /* @__PURE__ */ jsx("div", {
38
+ ref,
39
+ className: cn(minSize === 44 ? "min-h-11 min-w-11" : "min-h-12 min-w-12", center && "flex items-center justify-center", className),
40
+ ...props,
41
+ children
42
+ });
43
+ });
44
+ TouchTarget.displayName = "TouchTarget";
45
+ const FormFieldWrapper = forwardRef(({ label, error, success, htmlFor, required, className, children, ...props }, ref) => {
46
+ return /* @__PURE__ */ jsxs("div", {
47
+ ref,
48
+ className: cn("flex flex-col gap-1 md:gap-1.5", className),
49
+ ...props,
50
+ children: [
51
+ label && /* @__PURE__ */ jsxs("label", {
52
+ htmlFor,
53
+ className: "text-xs md:text-sm font-medium",
54
+ style: { color: "var(--text-secondary)" },
55
+ children: [label, required && /* @__PURE__ */ jsx("span", {
56
+ className: "text-[var(--alert-danger-text)] ml-1",
57
+ "aria-label": "required",
58
+ children: "*"
59
+ })]
60
+ }),
61
+ children,
62
+ error && /* @__PURE__ */ jsx("p", {
63
+ className: "text-xs",
64
+ style: { color: "var(--alert-danger-text)" },
65
+ role: "alert",
66
+ "aria-live": "polite",
67
+ children: error
68
+ }),
69
+ success && !error && /* @__PURE__ */ jsx("p", {
70
+ className: "text-xs",
71
+ style: { color: "var(--alert-success-text)" },
72
+ "aria-live": "polite",
73
+ children: success
74
+ })
75
+ ]
76
+ });
77
+ });
78
+ FormFieldWrapper.displayName = "FormFieldWrapper";
79
+ const InteractiveCard = forwardRef(({ hoverLift = true, hoverGlow, hoverBg, baseBg = "var(--card-bg)", borderColor = "var(--card-border)", hoverBorderColor, blur = "sm", disabled = false, rounded = "rounded-2xl", transition = "var(--transition-slow)", className, style, children, ...props }, ref) => {
80
+ const { isHovered, hoverProps } = useHover({ includeFocus: !disabled });
81
+ const cardStyles = {
82
+ background: isHovered && hoverBg ? hoverBg : baseBg,
83
+ border: `1px solid ${isHovered && hoverBorderColor ? hoverBorderColor : borderColor}`,
84
+ backdropFilter: `blur(var(--blur-${blur}))`,
85
+ WebkitBackdropFilter: `blur(var(--blur-${blur}))`,
86
+ transform: hoverLift && isHovered && !disabled ? "translateY(-2px)" : "translateY(0)",
87
+ boxShadow: isHovered && hoverGlow && !disabled ? hoverGlow : "none",
88
+ transition: `all ${transition}`,
89
+ ...style
90
+ };
91
+ return /* @__PURE__ */ jsx("div", {
92
+ ref,
93
+ className: cn(rounded, className),
94
+ style: cardStyles,
95
+ ...disabled ? {} : hoverProps,
96
+ ...props,
97
+ children
98
+ });
99
+ });
100
+ InteractiveCard.displayName = "InteractiveCard";
101
+ var iconMap = {
102
+ default: Info,
103
+ destructive: AlertCircle,
104
+ success: CheckCircle,
105
+ warning: AlertTriangle,
106
+ info: Info,
107
+ error: AlertCircle
108
+ };
109
+ var variantStyles$2 = {
110
+ default: {
111
+ bg: "var(--alert-default-bg)",
112
+ border: "var(--alert-default-border)",
113
+ text: "var(--alert-default-text)"
114
+ },
115
+ destructive: {
116
+ bg: "var(--alert-destructive-bg)",
117
+ border: "var(--alert-destructive-border)",
118
+ text: "var(--alert-destructive-text)"
119
+ },
120
+ success: {
121
+ bg: "var(--alert-success-bg)",
122
+ border: "var(--alert-success-border)",
123
+ text: "var(--alert-success-text)"
124
+ },
125
+ warning: {
126
+ bg: "var(--alert-warning-bg)",
127
+ border: "var(--alert-warning-border)",
128
+ text: "var(--alert-warning-text)"
129
+ },
130
+ info: {
131
+ bg: "var(--alert-default-bg)",
132
+ border: "var(--alert-default-border)",
133
+ text: "var(--alert-default-text)"
134
+ },
135
+ error: {
136
+ bg: "var(--alert-destructive-bg)",
137
+ border: "var(--alert-destructive-border)",
138
+ text: "var(--alert-destructive-text)"
139
+ }
140
+ };
141
+ var getAlertStyles = (variant) => {
142
+ const config = variantStyles$2[variant];
143
+ return {
144
+ background: config.bg,
145
+ border: `1px solid ${config.border}`,
146
+ color: config.text
147
+ };
148
+ };
149
+ var AlertGlassRoot = forwardRef(({ className, variant = "default", dismissible, onDismiss, children, ...props }, ref) => {
150
+ const effectiveVariant = variant ?? "default";
151
+ const Icon = iconMap[effectiveVariant];
152
+ const config = variantStyles$2[effectiveVariant];
153
+ return /* @__PURE__ */ jsxs("div", {
154
+ ref,
155
+ "data-slot": "alert",
156
+ className: cn(alertVariants({ variant: effectiveVariant }), className),
157
+ style: getAlertStyles(effectiveVariant),
158
+ role: "alert",
159
+ ...props,
160
+ children: [
161
+ /* @__PURE__ */ jsx(Icon, {
162
+ className: "w-4 h-4 md:w-5 md:h-5 shrink-0 mt-0.5",
163
+ style: { color: config.text },
164
+ "aria-hidden": "true"
165
+ }),
166
+ /* @__PURE__ */ jsx("div", {
167
+ className: "flex-1",
168
+ children
169
+ }),
170
+ dismissible && /* @__PURE__ */ jsx("button", {
171
+ onClick: onDismiss,
172
+ className: "p-0.5 md:p-1 rounded transition-colors duration-200 hover:bg-black/5 shrink-0",
173
+ "aria-label": "Dismiss alert",
174
+ children: /* @__PURE__ */ jsx(X, {
175
+ className: ICON_SIZES.md,
176
+ style: { color: config.text }
177
+ })
178
+ })
179
+ ]
180
+ });
181
+ });
182
+ AlertGlassRoot.displayName = "AlertGlass";
183
+ var AlertGlassTitle = forwardRef(({ className, style, ...props }, ref) => {
184
+ return /* @__PURE__ */ jsx("div", {
185
+ ref,
186
+ "data-slot": "alert-title",
187
+ className: cn("font-medium text-xs md:text-sm mb-0.5 md:mb-1", className),
188
+ style: {
189
+ color: "inherit",
190
+ ...style
191
+ },
192
+ ...props
193
+ });
194
+ });
195
+ AlertGlassTitle.displayName = "AlertGlassTitle";
196
+ var AlertGlassDescription = forwardRef(({ className, style, ...props }, ref) => {
197
+ return /* @__PURE__ */ jsx("div", {
198
+ ref,
199
+ "data-slot": "alert-description",
200
+ className: cn("text-xs md:text-sm opacity-80", className),
201
+ style: {
202
+ color: "inherit",
203
+ ...style
204
+ },
205
+ ...props
206
+ });
207
+ });
208
+ AlertGlassDescription.displayName = "AlertGlassDescription";
209
+ const AlertGlass = AlertGlassRoot;
210
+ const avatarSizes = cva("rounded-full flex items-center justify-center font-semibold transition-all duration-300", {
211
+ variants: { size: {
212
+ sm: "w-7 h-7 md:w-8 md:h-8 text-[10px] md:text-xs",
213
+ md: "w-9 h-9 md:w-10 md:h-10 text-xs md:text-sm",
214
+ lg: "w-10 h-10 md:w-12 md:h-12 text-sm md:text-base",
215
+ xl: "w-14 h-14 md:w-16 md:h-16 text-base md:text-lg"
216
+ } },
217
+ defaultVariants: { size: "md" }
218
+ });
219
+ const statusSizes = cva("absolute -bottom-0.5 -right-0.5 rounded-full", {
220
+ variants: { size: {
221
+ sm: "w-2 h-2 md:w-2.5 md:h-2.5",
222
+ md: "w-2.5 h-2.5 md:w-3 md:h-3",
223
+ lg: "w-3 h-3 md:w-3.5 md:h-3.5",
224
+ xl: "w-3.5 h-3.5 md:w-4 md:h-4"
225
+ } },
226
+ defaultVariants: { size: "md" }
227
+ });
228
+ var getStatusVars$1 = (statusType) => {
229
+ return {
230
+ online: {
231
+ bg: "var(--status-online)",
232
+ glow: "var(--status-online-glow)"
233
+ },
234
+ offline: {
235
+ bg: "var(--status-offline)",
236
+ glow: "none"
237
+ },
238
+ busy: {
239
+ bg: "var(--status-busy)",
240
+ glow: "var(--status-busy-glow)"
241
+ },
242
+ away: {
243
+ bg: "var(--status-away)",
244
+ glow: "var(--status-away-glow)"
245
+ }
246
+ }[statusType];
247
+ };
248
+ var AvatarGlassContext = React.createContext({ size: "md" });
249
+ var AvatarGlassRoot = React.forwardRef(({ className, size = "md", status, glowing = false, children, ...props }, ref) => {
250
+ const { isHovered, hoverProps } = useHover();
251
+ const avatarStyles = {
252
+ background: "var(--avatar-bg)",
253
+ border: "3px solid var(--avatar-border)",
254
+ boxShadow: isHovered ? "var(--avatar-hover-glow)" : "var(--avatar-shadow)",
255
+ color: "var(--text-inverse)"
256
+ };
257
+ return /* @__PURE__ */ jsx(AvatarGlassContext.Provider, {
258
+ value: {
259
+ size,
260
+ status,
261
+ glowing
262
+ },
263
+ children: /* @__PURE__ */ jsxs("div", {
264
+ className: cn("relative inline-flex", className),
265
+ onMouseEnter: hoverProps.onMouseEnter,
266
+ onMouseLeave: hoverProps.onMouseLeave,
267
+ children: [/* @__PURE__ */ jsx(AvatarPrimitive.Root, {
268
+ ref,
269
+ className: cn(avatarSizes({ size }), glowing && "animate-[glow-pulse_2s_ease-in-out_infinite]"),
270
+ style: avatarStyles,
271
+ ...props,
272
+ children
273
+ }), status && /* @__PURE__ */ jsx("span", {
274
+ className: cn(statusSizes({ size })),
275
+ style: {
276
+ background: getStatusVars$1(status).bg,
277
+ boxShadow: getStatusVars$1(status).glow
278
+ },
279
+ role: "status",
280
+ "aria-label": `Status: ${status}`
281
+ })]
282
+ })
283
+ });
284
+ });
285
+ AvatarGlassRoot.displayName = "AvatarGlass";
286
+ var AvatarGlassImage = React.forwardRef(({ className, ...props }, ref) => {
287
+ return /* @__PURE__ */ jsx(AvatarPrimitive.Image, {
288
+ ref,
289
+ className: cn("aspect-square h-full w-full object-cover", className),
290
+ ...props
291
+ });
292
+ });
293
+ AvatarGlassImage.displayName = "AvatarGlassImage";
294
+ var AvatarGlassFallback = React.forwardRef(({ className, ...props }, ref) => {
295
+ return /* @__PURE__ */ jsx(AvatarPrimitive.Fallback, {
296
+ ref,
297
+ className: cn("flex h-full w-full items-center justify-center font-semibold uppercase", className),
298
+ ...props
299
+ });
300
+ });
301
+ AvatarGlassFallback.displayName = "AvatarGlassFallback";
302
+ var getInitials = (name) => {
303
+ if (!name || name.trim().length === 0) return "?";
304
+ return name.split(" ").map((part) => part[0]).join("").toUpperCase().slice(0, 2);
305
+ };
306
+ var AvatarGlassSimple = ({ name, size = "md", status, glowing, className }) => {
307
+ return /* @__PURE__ */ jsx(AvatarGlassRoot, {
308
+ size,
309
+ status,
310
+ glowing,
311
+ className,
312
+ children: /* @__PURE__ */ jsx(AvatarGlassFallback, { children: getInitials(name) })
313
+ });
314
+ };
315
+ const AvatarGlass = AvatarGlassRoot;
316
+ const badgeVariants = cva("inline-flex items-center gap-1 md:gap-1.5 rounded-full font-medium", {
317
+ variants: { size: {
318
+ sm: "px-1 py-0.5 md:px-1.5 text-[9px] md:text-[10px]",
319
+ md: "px-2 py-0.5 md:px-2.5 text-[10px] md:text-xs",
320
+ lg: "px-2.5 py-0.5 md:px-3 md:py-1 text-xs md:text-sm"
321
+ } },
322
+ defaultVariants: { size: "md" }
323
+ });
324
+ var variantStyles$1 = {
325
+ default: {
326
+ bg: "var(--badge-default-bg)",
327
+ text: "var(--badge-default-text)",
328
+ border: "var(--badge-default-border)"
329
+ },
330
+ secondary: {
331
+ bg: "var(--badge-secondary-bg)",
332
+ text: "var(--badge-secondary-text)",
333
+ border: "var(--badge-secondary-border)"
334
+ },
335
+ destructive: {
336
+ bg: "var(--badge-destructive-bg)",
337
+ text: "var(--badge-destructive-text)",
338
+ border: "var(--badge-destructive-border)"
339
+ },
340
+ outline: {
341
+ bg: "var(--badge-outline-bg)",
342
+ text: "var(--badge-outline-text)",
343
+ border: "var(--badge-outline-border)"
344
+ },
345
+ success: {
346
+ bg: "var(--badge-success-bg)",
347
+ text: "var(--badge-success-text)",
348
+ border: "var(--badge-success-border)"
349
+ },
350
+ warning: {
351
+ bg: "var(--badge-warning-bg)",
352
+ text: "var(--badge-warning-text)",
353
+ border: "var(--badge-warning-border)"
354
+ },
355
+ info: {
356
+ bg: "var(--badge-info-bg)",
357
+ text: "var(--badge-info-text)",
358
+ border: "var(--badge-info-border)"
359
+ }
360
+ };
361
+ var getBadgeStyles = (variant) => {
362
+ const v = variantStyles$1[variant] || variantStyles$1.default;
363
+ return {
364
+ background: v.bg,
365
+ color: v.text,
366
+ border: `1px solid ${v.border}`
367
+ };
368
+ };
369
+ const BadgeGlass = forwardRef(({ children, className, variant = "default", size = "md", dot, ...props }, ref) => {
370
+ const v = variantStyles$1[variant];
371
+ return /* @__PURE__ */ jsxs("span", {
372
+ ref,
373
+ "data-slot": "badge",
374
+ className: cn(badgeVariants({ size }), className),
375
+ style: getBadgeStyles(variant),
376
+ ...props,
377
+ children: [dot && /* @__PURE__ */ jsx("span", {
378
+ className: "w-1 h-1 md:w-1.5 md:h-1.5 rounded-full animate-pulse",
379
+ style: { background: v.text }
380
+ }), children]
381
+ });
382
+ });
383
+ BadgeGlass.displayName = "BadgeGlass";
384
+ const buttonGlassVariants = cva("relative overflow-hidden font-medium inline-flex items-center justify-center transition-all duration-300 ease-out cursor-pointer disabled:opacity-50 disabled:cursor-not-allowed", {
385
+ variants: {
386
+ variant: {
387
+ default: "",
388
+ secondary: "",
389
+ ghost: "",
390
+ destructive: "",
391
+ outline: "",
392
+ success: "",
393
+ link: ""
394
+ },
395
+ size: {
396
+ sm: "px-3 py-1.5 text-sm gap-1.5 min-h-[44px] rounded-xl",
397
+ default: "px-4 py-2.5 text-sm gap-2 min-h-[44px] rounded-xl",
398
+ lg: "px-6 py-3 text-base gap-2.5 min-h-[48px] rounded-xl",
399
+ xl: "px-8 py-4 text-lg gap-3 min-h-[56px] rounded-xl",
400
+ icon: "p-2.5 min-h-[44px] min-w-[44px] rounded-xl"
401
+ }
402
+ },
403
+ defaultVariants: {
404
+ variant: "default",
405
+ size: "default"
406
+ }
407
+ });
408
+ var getVariantStyles = (variant, isHovered, isFocusVisible) => {
409
+ return {
410
+ default: {
411
+ background: isHovered ? "var(--btn-primary-hover-bg)" : "var(--btn-primary-bg)",
412
+ color: "var(--btn-primary-text)",
413
+ border: "none",
414
+ boxShadow: isFocusVisible ? "var(--focus-glow)" : isHovered ? "var(--btn-primary-glow)" : "var(--btn-primary-shadow)"
415
+ },
416
+ secondary: {
417
+ background: isHovered ? "var(--btn-secondary-hover-bg)" : "var(--btn-secondary-bg)",
418
+ color: "var(--btn-secondary-text)",
419
+ border: "1px solid var(--btn-secondary-border)",
420
+ boxShadow: isFocusVisible ? "var(--focus-glow)" : isHovered ? "var(--btn-secondary-glow)" : "none"
421
+ },
422
+ ghost: {
423
+ background: isHovered ? "var(--btn-ghost-hover-bg)" : "var(--btn-ghost-bg)",
424
+ color: "var(--btn-ghost-text)",
425
+ border: "none",
426
+ boxShadow: isFocusVisible ? "var(--focus-glow)" : "none"
427
+ },
428
+ destructive: {
429
+ background: "var(--btn-destructive-bg)",
430
+ color: "var(--btn-destructive-text)",
431
+ border: "none",
432
+ boxShadow: isFocusVisible ? "var(--focus-glow)" : isHovered ? "var(--btn-destructive-glow)" : "var(--btn-destructive-shadow)"
433
+ },
434
+ outline: {
435
+ background: isHovered ? "var(--btn-outline-hover-bg)" : "transparent",
436
+ color: "var(--btn-outline-text)",
437
+ border: "1px solid var(--btn-outline-border)",
438
+ boxShadow: isFocusVisible ? "var(--focus-glow)" : isHovered ? "var(--btn-outline-glow)" : "none"
439
+ },
440
+ success: {
441
+ background: "var(--btn-success-bg)",
442
+ color: "var(--btn-success-text)",
443
+ border: "none",
444
+ boxShadow: isFocusVisible ? "var(--focus-glow)" : isHovered ? "var(--btn-success-glow)" : "var(--btn-success-shadow)"
445
+ },
446
+ link: {
447
+ background: "transparent",
448
+ color: "var(--btn-link-text)",
449
+ border: "none",
450
+ boxShadow: isFocusVisible ? "var(--focus-glow)" : "none",
451
+ textDecoration: isHovered ? "underline" : "none"
452
+ }
453
+ }[variant];
454
+ };
455
+ const ButtonGlass = forwardRef(({ asChild = false, className, variant = "default", size = "default", children, loading = false, disabled, icon: Icon, iconPosition = "left", onClick, ...props }, ref) => {
456
+ const { isHovered, hoverProps } = useHover();
457
+ const { isFocusVisible, focusProps } = useFocus({ focusVisible: true });
458
+ const [ripple, setRipple] = useState(null);
459
+ const isDisabled = disabled || loading;
460
+ const rippleTimeoutRef = useRef(null);
461
+ useEffect(() => {
462
+ return () => {
463
+ if (rippleTimeoutRef.current) clearTimeout(rippleTimeoutRef.current);
464
+ };
465
+ }, []);
466
+ const handleClick = useCallback((e) => {
467
+ if (isDisabled) return;
468
+ const rect = e.currentTarget.getBoundingClientRect();
469
+ setRipple({
470
+ x: e.clientX - rect.left,
471
+ y: e.clientY - rect.top
472
+ });
473
+ if (rippleTimeoutRef.current) clearTimeout(rippleTimeoutRef.current);
474
+ rippleTimeoutRef.current = setTimeout(() => {
475
+ setRipple(null);
476
+ rippleTimeoutRef.current = null;
477
+ }, 600);
478
+ onClick?.(e);
479
+ }, [isDisabled, onClick]);
480
+ return /* @__PURE__ */ jsx(asChild ? Slot : "button", {
481
+ ref,
482
+ "data-slot": "button",
483
+ className: cn(buttonGlassVariants({
484
+ variant,
485
+ size
486
+ }), isHovered && !isDisabled && "scale-[1.02]", className),
487
+ style: {
488
+ ...getVariantStyles(variant, isHovered && !isDisabled, isFocusVisible && !isDisabled),
489
+ outline: "none"
490
+ },
491
+ type: asChild ? void 0 : "button",
492
+ disabled: isDisabled,
493
+ onClick: handleClick,
494
+ onMouseEnter: hoverProps.onMouseEnter,
495
+ onMouseLeave: hoverProps.onMouseLeave,
496
+ onFocus: focusProps.onFocus,
497
+ onBlur: focusProps.onBlur,
498
+ ...props,
499
+ children: asChild ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
500
+ isHovered && variant === "default" && !isDisabled && /* @__PURE__ */ jsx("div", {
501
+ className: "absolute inset-0 overflow-hidden pointer-events-none",
502
+ style: { borderRadius: "inherit" },
503
+ children: /* @__PURE__ */ jsx("div", {
504
+ className: "absolute top-0 h-full w-1/3 bg-linear-to-r from-transparent via-white/20 to-transparent",
505
+ style: { animation: "btn-shine 1.5s ease-in-out infinite" }
506
+ })
507
+ }),
508
+ ripple && /* @__PURE__ */ jsx("span", {
509
+ className: "absolute rounded-full bg-white/30 pointer-events-none",
510
+ style: {
511
+ left: ripple.x,
512
+ top: ripple.y,
513
+ width: 10,
514
+ height: 10,
515
+ transform: "translate(-50%, -50%)",
516
+ animation: "ripple 0.6s ease-out"
517
+ }
518
+ }),
519
+ isHovered && variant === "default" && !isDisabled && /* @__PURE__ */ jsx("div", {
520
+ className: "absolute inset-0 rounded-xl animate-glow-pulse pointer-events-none",
521
+ style: { background: "var(--btn-glow-radial)" }
522
+ }),
523
+ loading && /* @__PURE__ */ jsx(RefreshCw, { className: cn(ICON_SIZES.md, "animate-spin") }),
524
+ !loading && Icon && iconPosition === "left" && /* @__PURE__ */ jsx(Icon, { className: ICON_SIZES.md }),
525
+ !loading && children,
526
+ !loading && Icon && iconPosition === "right" && /* @__PURE__ */ jsx(Icon, { className: ICON_SIZES.md })
527
+ ] })
528
+ });
529
+ });
530
+ ButtonGlass.displayName = "ButtonGlass";
531
+ const CheckboxGlass = forwardRef(({ className, checked: controlledChecked, defaultChecked, onCheckedChange, onChange, label, disabled, ...props }, ref) => {
532
+ const { isHovered, hoverProps } = useHover();
533
+ const { isFocusVisible, focusProps } = useFocus({ focusVisible: true });
534
+ const [uncontrolledChecked, setUncontrolledChecked] = React.useState(defaultChecked ?? false);
535
+ const isControlled = controlledChecked !== void 0;
536
+ const checked = isControlled ? controlledChecked : uncontrolledChecked;
537
+ const isChecked = checked === true;
538
+ const isIndeterminate = checked === "indeterminate";
539
+ const showIndicator = isChecked || isIndeterminate;
540
+ const handleChange = (newChecked) => {
541
+ if (disabled) return;
542
+ if (!isControlled) setUncontrolledChecked(newChecked);
543
+ onCheckedChange?.(newChecked);
544
+ if (onChange && typeof newChecked === "boolean") onChange(newChecked);
545
+ };
546
+ const toggleChecked = () => {
547
+ if (isIndeterminate) handleChange(true);
548
+ else handleChange(!isChecked);
549
+ };
550
+ const checkboxStyles = {
551
+ background: showIndicator ? "var(--checkbox-checked-bg)" : "var(--checkbox-bg)",
552
+ border: `2px solid ${showIndicator ? "var(--checkbox-checked-bg)" : "var(--checkbox-border)"}`,
553
+ boxShadow: isFocusVisible && !disabled ? "var(--focus-glow)" : isHovered && !disabled ? "var(--checkbox-glow)" : "none"
554
+ };
555
+ const ariaChecked = isIndeterminate ? "mixed" : isChecked;
556
+ return /* @__PURE__ */ jsxs("label", {
557
+ className: cn("inline-flex items-center gap-2 md:gap-2.5", disabled ? "opacity-50 cursor-not-allowed" : "cursor-pointer", className),
558
+ onMouseEnter: hoverProps.onMouseEnter,
559
+ onMouseLeave: hoverProps.onMouseLeave,
560
+ children: [
561
+ /* @__PURE__ */ jsx("input", {
562
+ ref,
563
+ type: "checkbox",
564
+ checked: isChecked,
565
+ onChange: (e) => handleChange(e.target.checked),
566
+ disabled,
567
+ className: "sr-only",
568
+ ...props
569
+ }),
570
+ /* @__PURE__ */ jsx("span", {
571
+ className: "inline-flex items-center justify-center min-w-11 min-h-11",
572
+ children: /* @__PURE__ */ jsxs("div", {
573
+ onClick: toggleChecked,
574
+ onFocus: focusProps.onFocus,
575
+ onBlur: focusProps.onBlur,
576
+ className: "relative w-6 h-6 md:w-5 md:h-5 rounded-md flex items-center justify-center transition-all duration-300",
577
+ style: checkboxStyles,
578
+ role: "checkbox",
579
+ "aria-checked": ariaChecked,
580
+ "aria-label": label || "Checkbox",
581
+ tabIndex: disabled ? -1 : 0,
582
+ onKeyDown: (e) => {
583
+ if (!disabled && (e.key === "Enter" || e.key === " ")) {
584
+ e.preventDefault();
585
+ toggleChecked();
586
+ }
587
+ },
588
+ children: [isChecked && /* @__PURE__ */ jsx(Check, {
589
+ className: "w-3.5 h-3.5 md:w-3 md:h-3",
590
+ style: { color: "var(--text-inverse)" }
591
+ }), isIndeterminate && /* @__PURE__ */ jsx(Minus, {
592
+ className: "w-3.5 h-3.5 md:w-3 md:h-3",
593
+ style: { color: "var(--text-inverse)" }
594
+ })]
595
+ })
596
+ }),
597
+ label && /* @__PURE__ */ jsx("span", {
598
+ className: "text-xs md:text-sm",
599
+ style: { color: "var(--text-secondary)" },
600
+ children: label
601
+ })
602
+ ]
603
+ });
604
+ });
605
+ CheckboxGlass.displayName = "CheckboxGlass";
606
+ const Checkbox = CheckboxGlass;
607
+ var circularProgressVariants = cva("relative inline-flex items-center justify-center p-4", {
608
+ variants: { size: {
609
+ sm: "w-20 h-20",
610
+ md: "w-28 h-28",
611
+ lg: "w-36 h-36",
612
+ xl: "w-44 h-44"
613
+ } },
614
+ defaultVariants: { size: "md" }
615
+ });
616
+ var getGradientColors = (gradient) => {
617
+ return {
618
+ violet: {
619
+ from: "#8b5cf6",
620
+ to: "#a855f7",
621
+ glowVar: "--progress-glow-violet"
622
+ },
623
+ blue: {
624
+ from: "#3b82f6",
625
+ to: "#60a5fa",
626
+ glowVar: "--progress-glow-blue"
627
+ },
628
+ cyan: {
629
+ from: "#06b6d4",
630
+ to: "#22d3ee",
631
+ glowVar: "--progress-glow-cyan"
632
+ },
633
+ amber: {
634
+ from: "#f59e0b",
635
+ to: "#fbbf24",
636
+ glowVar: "--progress-glow-amber"
637
+ },
638
+ emerald: {
639
+ from: "#10b981",
640
+ to: "#34d399",
641
+ glowVar: "--progress-glow-emerald"
642
+ },
643
+ rose: {
644
+ from: "#f43f5e",
645
+ to: "#fb7185",
646
+ glowVar: "--progress-glow-rose"
647
+ }
648
+ }[gradient];
649
+ };
650
+ var getGlowStdDeviation = (intensity) => {
651
+ return {
652
+ low: 2,
653
+ medium: 4,
654
+ high: 6
655
+ }[intensity];
656
+ };
657
+ const CircularProgressGlass = forwardRef(({ className, size = "md", value = 0, variant = "determinate", thickness = 8, trackWidth = 8, color = "violet", trackColor = "oklch(100% 0 0 / 0.1)", showLabel = true, label, labelColor, showGlow = true, glowIntensity = "medium", strokeLinecap = "round", animationDuration = 1, ...props }, ref) => {
658
+ const clampedValue = Math.min(100, Math.max(0, value));
659
+ const gradientColors = getGradientColors(color);
660
+ const svgSize = {
661
+ sm: 64,
662
+ md: 96,
663
+ lg: 128,
664
+ xl: 160
665
+ }[size || "md"];
666
+ const radius = (svgSize - Math.max(thickness, trackWidth)) / 2;
667
+ const circumference = 2 * Math.PI * radius;
668
+ const center = svgSize / 2;
669
+ const dashOffset = useMemo(() => {
670
+ if (variant === "indeterminate") return circumference * .75;
671
+ return circumference * ((100 - clampedValue) / 100);
672
+ }, [
673
+ variant,
674
+ clampedValue,
675
+ circumference
676
+ ]);
677
+ const uniqueId = useId();
678
+ const gradientId = `circular-gradient-${uniqueId}`;
679
+ const glowId = `circular-glow-${uniqueId}`;
680
+ return /* @__PURE__ */ jsxs("div", {
681
+ ref,
682
+ className: cn(circularProgressVariants({ size }), className),
683
+ ...props,
684
+ children: [
685
+ /* @__PURE__ */ jsxs("svg", {
686
+ width: svgSize,
687
+ height: svgSize,
688
+ className: "transform -rotate-90 overflow-visible",
689
+ "aria-hidden": "true",
690
+ style: { overflow: "visible" },
691
+ children: [
692
+ /* @__PURE__ */ jsxs("defs", { children: [/* @__PURE__ */ jsxs("linearGradient", {
693
+ id: gradientId,
694
+ x1: "0%",
695
+ y1: "0%",
696
+ x2: "100%",
697
+ y2: "100%",
698
+ children: [/* @__PURE__ */ jsx("stop", {
699
+ offset: "0%",
700
+ stopColor: gradientColors.from
701
+ }), /* @__PURE__ */ jsx("stop", {
702
+ offset: "100%",
703
+ stopColor: gradientColors.to
704
+ })]
705
+ }), showGlow && /* @__PURE__ */ jsxs("filter", {
706
+ id: glowId,
707
+ children: [/* @__PURE__ */ jsx("feGaussianBlur", {
708
+ stdDeviation: getGlowStdDeviation(glowIntensity),
709
+ result: "coloredBlur"
710
+ }), /* @__PURE__ */ jsxs("feMerge", { children: [/* @__PURE__ */ jsx("feMergeNode", { in: "coloredBlur" }), /* @__PURE__ */ jsx("feMergeNode", { in: "SourceGraphic" })] })]
711
+ })] }),
712
+ /* @__PURE__ */ jsx("circle", {
713
+ cx: center,
714
+ cy: center,
715
+ r: radius,
716
+ fill: "none",
717
+ stroke: trackColor,
718
+ strokeWidth: trackWidth
719
+ }),
720
+ /* @__PURE__ */ jsx("circle", {
721
+ cx: center,
722
+ cy: center,
723
+ r: radius,
724
+ fill: "none",
725
+ stroke: `url(#${gradientId})`,
726
+ strokeWidth: thickness,
727
+ strokeLinecap,
728
+ strokeDasharray: circumference,
729
+ strokeDashoffset: dashOffset,
730
+ filter: showGlow ? `url(#${glowId})` : void 0,
731
+ className: cn("transition-all", variant === "indeterminate" && "animate-circular-progress-spin"),
732
+ style: {
733
+ transitionDuration: `${animationDuration}s`,
734
+ transitionTimingFunction: "cubic-bezier(0.4, 0, 0.2, 1)"
735
+ }
736
+ })
737
+ ]
738
+ }),
739
+ showLabel && /* @__PURE__ */ jsx("div", {
740
+ className: "absolute inset-0 flex items-center justify-center",
741
+ children: /* @__PURE__ */ jsx("span", {
742
+ className: "text-sm font-semibold tabular-nums",
743
+ style: { color: labelColor || gradientColors.to },
744
+ children: label || (variant === "determinate" ? `${clampedValue}%` : "")
745
+ })
746
+ }),
747
+ /* @__PURE__ */ jsx("div", {
748
+ role: "progressbar",
749
+ "aria-valuenow": variant === "determinate" ? clampedValue : void 0,
750
+ "aria-valuemin": 0,
751
+ "aria-valuemax": 100,
752
+ "aria-label": label || (variant === "determinate" ? `Progress: ${clampedValue}%` : "Loading progress"),
753
+ "aria-valuetext": label || (variant === "determinate" ? `${clampedValue}%` : "Loading..."),
754
+ className: "sr-only",
755
+ children: label || (variant === "determinate" ? `${clampedValue}%` : "Loading...")
756
+ })
757
+ ]
758
+ });
759
+ });
760
+ CircularProgressGlass.displayName = "CircularProgressGlass";
761
+ function Popover({ ...props }) {
762
+ return /* @__PURE__ */ jsx(PopoverPrimitive.Root, {
763
+ "data-slot": "popover",
764
+ ...props
765
+ });
766
+ }
767
+ function PopoverTrigger({ ...props }) {
768
+ return /* @__PURE__ */ jsx(PopoverPrimitive.Trigger, {
769
+ "data-slot": "popover-trigger",
770
+ ...props
771
+ });
772
+ }
773
+ function PopoverContent({ className, align = "center", sideOffset = 4, ...props }) {
774
+ return /* @__PURE__ */ jsx(PopoverPrimitive.Portal, { children: /* @__PURE__ */ jsx(PopoverPrimitive.Content, {
775
+ "data-slot": "popover-content",
776
+ align,
777
+ sideOffset,
778
+ className: cn("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-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 z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden", className),
779
+ ...props
780
+ }) });
781
+ }
782
+ function Command$1({ className, ...props }) {
783
+ return /* @__PURE__ */ jsx(Command, {
784
+ "data-slot": "command",
785
+ className: cn("bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md", className),
786
+ ...props
787
+ });
788
+ }
789
+ function CommandInput({ className, ...props }) {
790
+ return /* @__PURE__ */ jsxs("div", {
791
+ "data-slot": "command-input-wrapper",
792
+ className: "flex h-9 items-center gap-2 border-b border-border px-3",
793
+ children: [/* @__PURE__ */ jsx(SearchIcon, { className: "size-4 shrink-0 opacity-60 text-muted-foreground" }), /* @__PURE__ */ jsx(Command.Input, {
794
+ "data-slot": "command-input",
795
+ className: cn("placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent py-3 text-sm font-medium outline-hidden disabled:cursor-not-allowed disabled:opacity-50", className),
796
+ ...props
797
+ })]
798
+ });
799
+ }
800
+ function CommandList({ className, ...props }) {
801
+ return /* @__PURE__ */ jsx(Command.List, {
802
+ "data-slot": "command-list",
803
+ className: cn("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto", className),
804
+ ...props
805
+ });
806
+ }
807
+ function CommandEmpty({ ...props }) {
808
+ return /* @__PURE__ */ jsx(Command.Empty, {
809
+ "data-slot": "command-empty",
810
+ className: "py-6 text-center text-sm",
811
+ ...props
812
+ });
813
+ }
814
+ function CommandGroup({ className, ...props }) {
815
+ return /* @__PURE__ */ jsx(Command.Group, {
816
+ "data-slot": "command-group",
817
+ className: cn("text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium", className),
818
+ ...props
819
+ });
820
+ }
821
+ function CommandItem({ className, ...props }) {
822
+ return /* @__PURE__ */ jsx(Command.Item, {
823
+ "data-slot": "command-item",
824
+ className: cn("data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
825
+ ...props
826
+ });
827
+ }
828
+ const inputVariants = cva("w-full transition-all duration-300 outline-none backdrop-blur-sm disabled:opacity-50 disabled:cursor-not-allowed", {
829
+ variants: { size: {
830
+ sm: "px-3 py-2 text-base rounded-md min-h-[44px]",
831
+ md: "px-4 py-2.5 text-base rounded-md min-h-[44px]",
832
+ lg: "px-5 py-3 text-base md:text-lg rounded-md min-h-[48px]"
833
+ } },
834
+ defaultVariants: { size: "md" }
835
+ });
836
+ function getDropdownContentStyles() {
837
+ return {
838
+ background: "var(--dropdown-bg)",
839
+ border: "1px solid var(--dropdown-border)",
840
+ boxShadow: "var(--dropdown-glow)",
841
+ backdropFilter: "blur(var(--blur-md))",
842
+ WebkitBackdropFilter: "blur(var(--blur-md))"
843
+ };
844
+ }
845
+ const dropdownContentClasses = cn("min-w-40 md:min-w-[200px]", "rounded-2xl overflow-hidden", "z-[50002]", "animate-in fade-in-0 zoom-in-95", "data-[side=bottom]:slide-in-from-top-2", "data-[side=top]:slide-in-from-bottom-2");
846
+ function getDropdownItemClasses(options) {
847
+ const { danger, selected, highlighted } = options ?? {};
848
+ return cn("w-full px-3 py-2.5", "text-sm text-left", "flex items-center gap-2", "rounded-lg", "outline-none cursor-pointer select-none", "transition-colors duration-150", highlighted && "bg-(--dropdown-item-hover)", "data-[highlighted]:bg-(--dropdown-item-hover)", "data-[selected=true]:bg-(--dropdown-item-hover)", selected && "bg-(--select-item-selected-bg) text-(--select-item-selected-text)", danger ? "text-(--alert-danger-text) data-[highlighted]:text-(--alert-danger-text)" : "text-(--dropdown-item-text)");
849
+ }
850
+ const dropdownSeparatorClasses = cn("h-px my-1", "bg-[var(--dropdown-border)]");
851
+ const dropdownLabelClasses = cn("px-3 py-1.5 md:px-4 md:py-2", "text-xs font-medium", "text-[var(--text-muted)]");
852
+ function ComboBoxGlassInner({ options, value, onValueChange, placeholder = "Select option...", emptyText = "No results found.", searchPlaceholder = "Search...", glassVariant = "glass", disabled = false, className, popoverClassName, clearable = false, side = "bottom", align = "start", label, error, success, required = false, size = "md", searchable = true, icon: TriggerIcon }, ref) {
853
+ const [open, setOpen] = useState(false);
854
+ const [search, setSearch] = useState("");
855
+ const fieldId = useId();
856
+ const selectedOption = useMemo(() => options.find((opt) => opt.value === value), [options, value]);
857
+ const filteredOptions = useMemo(() => {
858
+ if (!search) return options;
859
+ const searchLower = search.toLowerCase();
860
+ return options.filter((opt) => opt.label.toLowerCase().includes(searchLower));
861
+ }, [options, search]);
862
+ const handleSelect = useCallback((optionValue) => {
863
+ if (clearable && value === optionValue) onValueChange?.(void 0);
864
+ else onValueChange?.(optionValue);
865
+ setOpen(false);
866
+ setSearch("");
867
+ }, [
868
+ value,
869
+ onValueChange,
870
+ clearable
871
+ ]);
872
+ const getGlassClass = () => {
873
+ return {
874
+ glass: "glass",
875
+ frosted: "frosted",
876
+ fluted: "fluted",
877
+ crystal: "crystal"
878
+ }[glassVariant];
879
+ };
880
+ const comboboxContent = /* @__PURE__ */ jsxs(Popover, {
881
+ open,
882
+ onOpenChange: setOpen,
883
+ children: [/* @__PURE__ */ jsx(PopoverTrigger, {
884
+ asChild: true,
885
+ children: /* @__PURE__ */ jsxs(ButtonGlass, {
886
+ ref,
887
+ variant: "secondary",
888
+ role: "combobox",
889
+ "aria-expanded": open,
890
+ "aria-haspopup": "listbox",
891
+ "aria-label": selectedOption?.label || placeholder,
892
+ "aria-describedby": error ? `${fieldId}-error` : success ? `${fieldId}-success` : void 0,
893
+ disabled,
894
+ className: cn("w-full justify-between", inputVariants({ size }), !selectedOption && "text-muted-foreground", className),
895
+ children: [/* @__PURE__ */ jsxs("span", {
896
+ className: "flex items-center gap-2 truncate",
897
+ children: [TriggerIcon && /* @__PURE__ */ jsx(TriggerIcon, { className: ICON_SIZES.md }), selectedOption ? selectedOption.label : placeholder]
898
+ }), /* @__PURE__ */ jsx(ChevronsUpDownIcon, { className: cn(ICON_SIZES.md, "shrink-0 opacity-50") })]
899
+ })
900
+ }), /* @__PURE__ */ jsx(PopoverContent, {
901
+ side,
902
+ align,
903
+ className: cn(dropdownContentClasses, "w-[--radix-popover-trigger-width] p-0 border-0", getGlassClass(), popoverClassName),
904
+ style: getDropdownContentStyles(),
905
+ children: /* @__PURE__ */ jsxs(Command$1, {
906
+ shouldFilter: false,
907
+ className: cn("bg-transparent", "[&_[data-slot=command-input-wrapper]]:border-b-0", "[&_[data-slot=command-input-wrapper]_svg]:text-[var(--text-muted)]", "[&_[data-slot=command-input-wrapper]_svg]:opacity-80"),
908
+ children: [searchable && /* @__PURE__ */ jsx(CommandInput, {
909
+ placeholder: searchPlaceholder,
910
+ value: search,
911
+ onValueChange: setSearch,
912
+ className: "text-[var(--text-primary)] placeholder:text-[var(--text-muted)] h-10 font-medium"
913
+ }), /* @__PURE__ */ jsxs(CommandList, {
914
+ className: "p-1.5 scrollbar-hide",
915
+ children: [/* @__PURE__ */ jsx(CommandEmpty, {
916
+ className: "text-[var(--text-muted)] py-4",
917
+ children: emptyText
918
+ }), /* @__PURE__ */ jsx(CommandGroup, {
919
+ className: "text-[var(--text-primary)] p-0",
920
+ children: filteredOptions.map((option) => {
921
+ const OptionIcon = option.icon;
922
+ const isSelected = value === option.value;
923
+ return /* @__PURE__ */ jsxs(CommandItem, {
924
+ value: String(option.value),
925
+ disabled: option.disabled,
926
+ onSelect: () => handleSelect(option.value),
927
+ className: cn(getDropdownItemClasses({ selected: isSelected }), option.disabled && "cursor-not-allowed opacity-50"),
928
+ children: [
929
+ /* @__PURE__ */ jsx(CheckIcon, { className: cn(ICON_SIZES.md, "shrink-0", isSelected ? "opacity-100 text-[var(--text-accent)]" : "opacity-0") }),
930
+ OptionIcon && /* @__PURE__ */ jsx(OptionIcon, { className: cn(ICON_SIZES.md, "shrink-0 text-[var(--dropdown-icon)]") }),
931
+ /* @__PURE__ */ jsx("span", {
932
+ className: "truncate",
933
+ children: option.label
934
+ })
935
+ ]
936
+ }, String(option.value));
937
+ })
938
+ })]
939
+ })]
940
+ })
941
+ })]
942
+ });
943
+ if (label || error || success) return /* @__PURE__ */ jsx(FormFieldWrapper, {
944
+ label,
945
+ error,
946
+ success,
947
+ required,
948
+ htmlFor: fieldId,
949
+ children: comboboxContent
950
+ });
951
+ return comboboxContent;
952
+ }
953
+ const ComboBoxGlass = forwardRef(ComboBoxGlassInner);
954
+ ComboBoxGlassInner.displayName = "ComboBoxGlass";
955
+ var DropdownMenuGlass = DropdownMenuPrimitive.Root;
956
+ var DropdownMenuGlassTrigger = DropdownMenuPrimitive.Trigger;
957
+ var DropdownMenuGlassGroup = DropdownMenuPrimitive.Group;
958
+ var DropdownMenuGlassPortal = DropdownMenuPrimitive.Portal;
959
+ var DropdownMenuGlassSub = DropdownMenuPrimitive.Sub;
960
+ var DropdownMenuGlassRadioGroup = DropdownMenuPrimitive.RadioGroup;
961
+ var DropdownMenuGlassSubTrigger = React.forwardRef(({ className, inset, children, ...props }, ref) => /* @__PURE__ */ jsxs(DropdownMenuPrimitive.SubTrigger, {
962
+ ref,
963
+ className: cn(getDropdownItemClasses(), "data-[state=open]:bg-[var(--dropdown-item-hover)]", inset && "pl-8", className),
964
+ ...props,
965
+ children: [children, /* @__PURE__ */ jsx(ChevronRightIcon, { className: "ml-auto h-4 w-4" })]
966
+ }));
967
+ DropdownMenuGlassSubTrigger.displayName = "DropdownMenuGlassSubTrigger";
968
+ var DropdownMenuGlassSubContent = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(DropdownMenuPrimitive.SubContent, {
969
+ ref,
970
+ className: cn(dropdownContentClasses, "p-1.5", className),
971
+ style: getDropdownContentStyles(),
972
+ ...props
973
+ }));
974
+ DropdownMenuGlassSubContent.displayName = "DropdownMenuGlassSubContent";
975
+ var DropdownMenuGlassContent = React.forwardRef(({ className, sideOffset = 8, ...props }, ref) => /* @__PURE__ */ jsx(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx(DropdownMenuPrimitive.Content, {
976
+ ref,
977
+ sideOffset,
978
+ className: cn(dropdownContentClasses, "p-1.5", className),
979
+ style: getDropdownContentStyles(),
980
+ ...props
981
+ }) }));
982
+ DropdownMenuGlassContent.displayName = "DropdownMenuGlassContent";
983
+ var DropdownMenuGlassItem = React.forwardRef(({ className, inset, variant = "default", ...props }, ref) => /* @__PURE__ */ jsx(DropdownMenuPrimitive.Item, {
984
+ ref,
985
+ className: cn(getDropdownItemClasses({ danger: variant === "destructive" }), inset && "pl-8", className),
986
+ ...props
987
+ }));
988
+ DropdownMenuGlassItem.displayName = "DropdownMenuGlassItem";
989
+ var DropdownMenuGlassCheckboxItem = React.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ jsxs(DropdownMenuPrimitive.CheckboxItem, {
990
+ ref,
991
+ className: cn(getDropdownItemClasses(), "pl-8 pr-2", className),
992
+ checked,
993
+ ...props,
994
+ children: [/* @__PURE__ */ jsx("span", {
995
+ className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center",
996
+ children: /* @__PURE__ */ jsx(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, { className: "h-4 w-4" }) })
997
+ }), children]
998
+ }));
999
+ DropdownMenuGlassCheckboxItem.displayName = "DropdownMenuGlassCheckboxItem";
1000
+ var DropdownMenuGlassRadioItem = React.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs(DropdownMenuPrimitive.RadioItem, {
1001
+ ref,
1002
+ className: cn(getDropdownItemClasses(), "pl-8 pr-2", className),
1003
+ ...props,
1004
+ children: [/* @__PURE__ */ jsx("span", {
1005
+ className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center",
1006
+ children: /* @__PURE__ */ jsx(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(CircleIcon, { className: "h-2 w-2 fill-current" }) })
1007
+ }), children]
1008
+ }));
1009
+ DropdownMenuGlassRadioItem.displayName = "DropdownMenuGlassRadioItem";
1010
+ var DropdownMenuGlassLabel = React.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsx(DropdownMenuPrimitive.Label, {
1011
+ ref,
1012
+ className: cn(dropdownLabelClasses, inset && "pl-8", className),
1013
+ ...props
1014
+ }));
1015
+ DropdownMenuGlassLabel.displayName = "DropdownMenuGlassLabel";
1016
+ var DropdownMenuGlassSeparator = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(DropdownMenuPrimitive.Separator, {
1017
+ ref,
1018
+ className: cn(dropdownSeparatorClasses, "-mx-1 my-1", className),
1019
+ ...props
1020
+ }));
1021
+ DropdownMenuGlassSeparator.displayName = "DropdownMenuGlassSeparator";
1022
+ var DropdownMenuGlassShortcut = ({ className, ...props }) => {
1023
+ return /* @__PURE__ */ jsx("span", {
1024
+ className: cn("ml-auto text-xs tracking-widest text-(--text-muted)", className),
1025
+ ...props
1026
+ });
1027
+ };
1028
+ DropdownMenuGlassShortcut.displayName = "DropdownMenuGlassShortcut";
1029
+ const DropdownGlass = React.forwardRef(({ trigger, items, align = "left", className }, ref) => {
1030
+ return /* @__PURE__ */ jsx("div", {
1031
+ ref,
1032
+ className: cn("relative inline-block", className),
1033
+ children: /* @__PURE__ */ jsxs(DropdownMenuGlass, { children: [/* @__PURE__ */ jsx(DropdownMenuGlassTrigger, {
1034
+ asChild: true,
1035
+ children: trigger
1036
+ }), /* @__PURE__ */ jsx(DropdownMenuGlassContent, {
1037
+ align: align === "left" ? "start" : "end",
1038
+ children: items.map((item, idx) => item.divider ? /* @__PURE__ */ jsx(DropdownMenuGlassSeparator, {}, `divider-${idx}`) : /* @__PURE__ */ jsxs(DropdownMenuGlassItem, {
1039
+ variant: item.danger ? "destructive" : "default",
1040
+ onSelect: item.onClick,
1041
+ children: [item.icon && /* @__PURE__ */ jsx(item.icon, { className: cn(ICON_SIZES.md, "shrink-0", item.danger ? "text-(--alert-danger-text)" : "text-(--dropdown-icon) group-data-highlighted:text-(--dropdown-icon-hover)") }), /* @__PURE__ */ jsx("span", {
1042
+ className: "font-medium",
1043
+ children: item.label
1044
+ })]
1045
+ }, `item-${idx}`))
1046
+ })] })
1047
+ });
1048
+ });
1049
+ DropdownGlass.displayName = "DropdownGlass";
1050
+ const cardIntensity = cva("border transition-all duration-300 text-[var(--text-primary)]", {
1051
+ variants: {
1052
+ intensity: {
1053
+ subtle: "",
1054
+ medium: "",
1055
+ strong: ""
1056
+ },
1057
+ hover: {
1058
+ true: "hover-glow cursor-pointer",
1059
+ false: ""
1060
+ },
1061
+ padding: {
1062
+ none: "",
1063
+ compact: "p-4 md:p-5 rounded-lg",
1064
+ default: "p-6 rounded-xl",
1065
+ featured: "p-8 rounded-[20px]"
1066
+ }
1067
+ },
1068
+ defaultVariants: {
1069
+ intensity: "medium",
1070
+ hover: true,
1071
+ padding: "default"
1072
+ }
1073
+ });
1074
+ var blurMap = {
1075
+ subtle: "var(--blur-sm)",
1076
+ medium: "var(--blur-md)",
1077
+ strong: "var(--blur-lg)"
1078
+ };
1079
+ var bgVarMap = {
1080
+ subtle: "var(--card-subtle-bg)",
1081
+ medium: "var(--card-medium-bg)",
1082
+ strong: "var(--card-strong-bg)"
1083
+ };
1084
+ var borderVarMap = {
1085
+ subtle: "var(--card-subtle-border)",
1086
+ medium: "var(--card-medium-border)",
1087
+ strong: "var(--card-strong-border)"
1088
+ };
1089
+ var glowVarMap = {
1090
+ blue: "var(--glow-blue)",
1091
+ violet: "var(--glow-violet)",
1092
+ purple: "var(--glow-violet)",
1093
+ cyan: "var(--glow-cyan)"
1094
+ };
1095
+ const GlassCard = forwardRef(({ asChild = false, children, className, intensity = "medium", glow = null, hover = true, padding = "default", ...props }, ref) => {
1096
+ const { isHovered, hoverProps } = useHover();
1097
+ const intensityVal = intensity ?? "medium";
1098
+ const cardStyles = {
1099
+ background: isHovered && hover ? "var(--card-hover-bg)" : bgVarMap[intensityVal],
1100
+ borderColor: isHovered && hover ? "var(--card-hover-border)" : borderVarMap[intensityVal],
1101
+ backdropFilter: `blur(${blurMap[intensityVal]})`,
1102
+ WebkitBackdropFilter: `blur(${blurMap[intensityVal]})`,
1103
+ boxShadow: glow ? glowVarMap[glow] : isHovered && hover ? "var(--card-hover-glow)" : "var(--glow-neutral)"
1104
+ };
1105
+ return /* @__PURE__ */ jsx(asChild ? Slot : "div", {
1106
+ ref,
1107
+ className: cn(cardIntensity({
1108
+ intensity,
1109
+ hover,
1110
+ padding
1111
+ }), className),
1112
+ style: cardStyles,
1113
+ onMouseEnter: hoverProps.onMouseEnter,
1114
+ onMouseLeave: hoverProps.onMouseLeave,
1115
+ ...props,
1116
+ children
1117
+ });
1118
+ });
1119
+ GlassCard.displayName = "GlassCard";
1120
+ var getInputStyles = (isFocused, error, success) => {
1121
+ let borderColor = "var(--input-border)";
1122
+ if (error) borderColor = "var(--alert-danger-text)";
1123
+ else if (success) borderColor = "var(--alert-success-text)";
1124
+ else if (isFocused) borderColor = "var(--input-focus-border)";
1125
+ return {
1126
+ background: "var(--input-bg)",
1127
+ border: `1px solid ${borderColor}`,
1128
+ color: "var(--input-text)",
1129
+ boxShadow: isFocused ? "var(--focus-glow)" : "none"
1130
+ };
1131
+ };
1132
+ const InputGlass = forwardRef(({ className, size, inputSize, label, error, success, icon: Icon, iconPosition = "left", disabled, onFocus, onBlur, ...props }, ref) => {
1133
+ const sizeValue = size ?? inputSize ?? "md";
1134
+ if (process.env.NODE_ENV !== "production" && inputSize !== void 0) console.warn("[InputGlass] The `inputSize` prop is deprecated and will be removed in v4.0. Use `size` instead.");
1135
+ const { isFocused, focusProps } = useFocus();
1136
+ const handleFocus = useCallback((e) => {
1137
+ focusProps.onFocus(e);
1138
+ onFocus?.(e);
1139
+ }, [focusProps, onFocus]);
1140
+ const handleBlur = useCallback((e) => {
1141
+ focusProps.onBlur(e);
1142
+ onBlur?.(e);
1143
+ }, [focusProps, onBlur]);
1144
+ const hasIcon = Boolean(Icon);
1145
+ const paddingLeft = hasIcon && iconPosition === "left" ? "pl-10" : "";
1146
+ const paddingRight = hasIcon && iconPosition === "right" ? "pr-10" : "";
1147
+ return /* @__PURE__ */ jsx(FormFieldWrapper, {
1148
+ label,
1149
+ error,
1150
+ success,
1151
+ htmlFor: props.id,
1152
+ className,
1153
+ children: /* @__PURE__ */ jsxs("div", {
1154
+ className: "relative",
1155
+ children: [
1156
+ Icon && iconPosition === "left" && /* @__PURE__ */ jsx(Icon, {
1157
+ className: cn("absolute left-2.5 md:left-3 top-1/2 -translate-y-1/2 transition-colors duration-300 z-10", ICON_SIZES.md),
1158
+ style: { color: isFocused ? "var(--text-accent)" : "var(--text-muted)" }
1159
+ }),
1160
+ /* @__PURE__ */ jsx("input", {
1161
+ ref,
1162
+ "data-slot": "input",
1163
+ className: cn(inputVariants({ size: sizeValue }), paddingLeft, paddingRight),
1164
+ style: getInputStyles(isFocused, error, success),
1165
+ disabled,
1166
+ onFocus: handleFocus,
1167
+ onBlur: handleBlur,
1168
+ ...props
1169
+ }),
1170
+ Icon && iconPosition === "right" && /* @__PURE__ */ jsx(Icon, {
1171
+ className: cn("absolute right-2.5 md:right-3 top-1/2 -translate-y-1/2 transition-colors duration-300 z-10", ICON_SIZES.md),
1172
+ style: { color: isFocused ? "var(--text-accent)" : "var(--text-muted)" }
1173
+ })
1174
+ ]
1175
+ })
1176
+ });
1177
+ });
1178
+ InputGlass.displayName = "InputGlass";
1179
+ const modalSizes = cva("relative w-full max-w-[calc(100%-2rem)] rounded-2xl p-6 transition-all duration-300", {
1180
+ variants: { size: {
1181
+ sm: "sm:max-w-[480px]",
1182
+ md: "sm:max-w-[640px]",
1183
+ lg: "sm:max-w-[800px]",
1184
+ xl: "sm:max-w-xl",
1185
+ full: "sm:max-w-4xl"
1186
+ } },
1187
+ defaultVariants: { size: "sm" }
1188
+ });
1189
+ var ModalContext = React.createContext({ size: "sm" });
1190
+ var useModalContext = () => React.useContext(ModalContext);
1191
+ function ModalRoot({ size = "sm", children, ...props }) {
1192
+ return /* @__PURE__ */ jsx(ModalContext.Provider, {
1193
+ value: { size },
1194
+ children: /* @__PURE__ */ jsx(DialogPrimitive.Root, {
1195
+ "data-slot": "dialog",
1196
+ ...props,
1197
+ children
1198
+ })
1199
+ });
1200
+ }
1201
+ function ModalTrigger({ ...props }) {
1202
+ return /* @__PURE__ */ jsx(DialogPrimitive.Trigger, {
1203
+ "data-slot": "dialog-trigger",
1204
+ ...props
1205
+ });
1206
+ }
1207
+ function ModalPortal({ ...props }) {
1208
+ return /* @__PURE__ */ jsx(DialogPrimitive.Portal, {
1209
+ "data-slot": "dialog-portal",
1210
+ ...props
1211
+ });
1212
+ }
1213
+ var ModalOverlay = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(DialogPrimitive.Overlay, {
1214
+ ref,
1215
+ "data-slot": "dialog-overlay",
1216
+ className: cn("fixed inset-0 z-50", "data-[state=open]:animate-in data-[state=closed]:animate-out", "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0", className),
1217
+ style: {
1218
+ background: "var(--modal-overlay)",
1219
+ backdropFilter: "blur(var(--blur-sm))",
1220
+ WebkitBackdropFilter: "blur(var(--blur-sm))"
1221
+ },
1222
+ ...props
1223
+ }));
1224
+ ModalOverlay.displayName = "ModalOverlay";
1225
+ var ModalContent = React.forwardRef(({ className, children, showCloseButton = true, size: sizeProp, ...props }, ref) => {
1226
+ const { size: contextSize } = useModalContext();
1227
+ const size = sizeProp ?? contextSize;
1228
+ return /* @__PURE__ */ jsxs(ModalPortal, { children: [/* @__PURE__ */ jsx(ModalOverlay, {}), /* @__PURE__ */ jsxs(DialogPrimitive.Content, {
1229
+ ref,
1230
+ "data-slot": "dialog-content",
1231
+ className: cn(modalSizes({ size }), "fixed top-[50%] left-[50%] z-50", "translate-x-[-50%] translate-y-[-50%]", "data-[state=open]:animate-in data-[state=closed]:animate-out", "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0", "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95", "data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%]", "data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%]", "duration-200", className),
1232
+ style: {
1233
+ background: "var(--modal-bg)",
1234
+ border: "1px solid var(--modal-border)",
1235
+ boxShadow: "var(--modal-glow)",
1236
+ backdropFilter: "blur(var(--blur-lg))",
1237
+ WebkitBackdropFilter: "blur(var(--blur-lg))"
1238
+ },
1239
+ ...props,
1240
+ children: [
1241
+ /* @__PURE__ */ jsx("div", {
1242
+ className: "absolute inset-0 rounded-3xl pointer-events-none",
1243
+ style: { background: "var(--modal-glow-effect)" },
1244
+ "aria-hidden": "true"
1245
+ }),
1246
+ /* @__PURE__ */ jsx("div", {
1247
+ className: "relative",
1248
+ children
1249
+ }),
1250
+ showCloseButton && /* @__PURE__ */ jsxs(DialogPrimitive.Close, {
1251
+ "data-slot": "dialog-close",
1252
+ className: cn("absolute top-4 right-4", "p-1.5 md:p-2 rounded-xl", "transition-all duration-300", "ring-offset-background", "focus:outline-none focus:ring-2 focus:ring-(--semantic-primary) focus:ring-offset-2", "hover:opacity-100 opacity-70", "disabled:pointer-events-none"),
1253
+ style: {
1254
+ background: "var(--modal-close-btn-bg)",
1255
+ border: "var(--modal-close-btn-border)",
1256
+ color: "var(--text-muted)"
1257
+ },
1258
+ children: [/* @__PURE__ */ jsx(X, { className: ICON_SIZES.md }), /* @__PURE__ */ jsx("span", {
1259
+ className: "sr-only",
1260
+ children: "Close"
1261
+ })]
1262
+ })
1263
+ ]
1264
+ })] });
1265
+ });
1266
+ ModalContent.displayName = "ModalContent";
1267
+ function ModalHeader({ className, ...props }) {
1268
+ return /* @__PURE__ */ jsx("div", {
1269
+ "data-slot": "dialog-header",
1270
+ className: cn("flex flex-col gap-2 text-center sm:text-left mb-4", className),
1271
+ ...props
1272
+ });
1273
+ }
1274
+ function ModalBody({ className, ...props }) {
1275
+ return /* @__PURE__ */ jsx("div", {
1276
+ "data-slot": "dialog-body",
1277
+ className: cn("relative", className),
1278
+ style: { color: "var(--text-secondary)" },
1279
+ ...props
1280
+ });
1281
+ }
1282
+ function ModalFooter({ className, ...props }) {
1283
+ return /* @__PURE__ */ jsx("div", {
1284
+ "data-slot": "dialog-footer",
1285
+ className: cn("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end mt-4", className),
1286
+ ...props
1287
+ });
1288
+ }
1289
+ var ModalTitle = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(DialogPrimitive.Title, {
1290
+ ref,
1291
+ "data-slot": "dialog-title",
1292
+ className: cn("text-lg md:text-xl font-semibold leading-none tracking-tight", className),
1293
+ style: { color: "var(--text-primary)" },
1294
+ ...props
1295
+ }));
1296
+ ModalTitle.displayName = "ModalTitle";
1297
+ var ModalDescription = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(DialogPrimitive.Description, {
1298
+ ref,
1299
+ "data-slot": "dialog-description",
1300
+ className: cn("text-sm", className),
1301
+ style: { color: "var(--text-muted)" },
1302
+ ...props
1303
+ }));
1304
+ ModalDescription.displayName = "ModalDescription";
1305
+ function ModalClose({ ...props }) {
1306
+ return /* @__PURE__ */ jsx(DialogPrimitive.Close, {
1307
+ "data-slot": "dialog-close",
1308
+ ...props
1309
+ });
1310
+ }
1311
+ const ModalGlass = {
1312
+ Root: ModalRoot,
1313
+ Trigger: ModalTrigger,
1314
+ Portal: ModalPortal,
1315
+ Overlay: ModalOverlay,
1316
+ Content: ModalContent,
1317
+ Header: ModalHeader,
1318
+ Body: ModalBody,
1319
+ Footer: ModalFooter,
1320
+ Title: ModalTitle,
1321
+ Description: ModalDescription,
1322
+ Close: ModalClose
1323
+ };
1324
+ const notificationVariants = cva("flex items-start gap-3 md:gap-4 p-4 md:p-5 rounded-2xl min-w-[280px] md:min-w-[320px] max-w-[360px] md:max-w-[420px] transition-all duration-300", {
1325
+ variants: { type: {
1326
+ info: "",
1327
+ success: "",
1328
+ warning: "",
1329
+ error: ""
1330
+ } },
1331
+ defaultVariants: { type: "info" }
1332
+ });
1333
+ var NOTIFICATION_ICONS = {
1334
+ info: Info,
1335
+ success: CheckCircle,
1336
+ warning: AlertTriangle,
1337
+ error: AlertCircle
1338
+ };
1339
+ var getTypeVars = (notifType) => {
1340
+ return {
1341
+ info: {
1342
+ color: "var(--notification-info-color)",
1343
+ glow: "var(--notification-info-glow)",
1344
+ iconBg: "var(--notification-info-icon-bg)"
1345
+ },
1346
+ success: {
1347
+ color: "var(--notification-success-color)",
1348
+ glow: "var(--notification-success-glow)",
1349
+ iconBg: "var(--notification-success-icon-bg)"
1350
+ },
1351
+ warning: {
1352
+ color: "var(--notification-warning-color)",
1353
+ glow: "var(--notification-warning-glow)",
1354
+ iconBg: "var(--notification-warning-icon-bg)"
1355
+ },
1356
+ error: {
1357
+ color: "var(--notification-error-color)",
1358
+ glow: "var(--notification-error-glow)",
1359
+ iconBg: "var(--notification-error-icon-bg)"
1360
+ }
1361
+ }[notifType];
1362
+ };
1363
+ const NotificationGlass = forwardRef(({ variant: variantProp, type: typeProp, title, message, onClose, className, ...props }, ref) => {
1364
+ const variant = variantProp ?? typeProp ?? "default";
1365
+ if (process.env.NODE_ENV === "development" && typeProp) console.warn("NotificationGlass: The \"type\" prop is deprecated. Use \"variant\" instead. Example: <NotificationGlass variant=\"destructive\" />");
1366
+ const effectiveType = {
1367
+ default: "info",
1368
+ destructive: "error",
1369
+ success: "success",
1370
+ warning: "warning",
1371
+ info: "info",
1372
+ error: "error"
1373
+ }[variant] || "info";
1374
+ const { isHovered, hoverProps } = useHover();
1375
+ const Icon = NOTIFICATION_ICONS[effectiveType];
1376
+ const config = getTypeVars(effectiveType);
1377
+ const containerStyles = {
1378
+ background: "var(--notification-bg)",
1379
+ border: "1px solid var(--notification-border)",
1380
+ boxShadow: isHovered ? config.glow : "var(--notification-shadow)",
1381
+ transform: isHovered ? "translateY(-2px)" : "translateY(0)"
1382
+ };
1383
+ const iconContainerStyles = {
1384
+ background: config.iconBg,
1385
+ boxShadow: isHovered ? config.glow : "none"
1386
+ };
1387
+ return /* @__PURE__ */ jsxs("div", {
1388
+ ref,
1389
+ className: cn(notificationVariants({ type: effectiveType }), className),
1390
+ style: containerStyles,
1391
+ role: "alert",
1392
+ "aria-live": "polite",
1393
+ onMouseEnter: hoverProps.onMouseEnter,
1394
+ onMouseLeave: hoverProps.onMouseLeave,
1395
+ ...props,
1396
+ children: [
1397
+ /* @__PURE__ */ jsx("div", {
1398
+ className: "w-8 h-8 md:w-10 md:h-10 rounded-xl flex items-center justify-center shrink-0",
1399
+ style: iconContainerStyles,
1400
+ children: /* @__PURE__ */ jsx(Icon, {
1401
+ className: "w-4 h-4 md:w-5 md:h-5",
1402
+ style: { color: config.color }
1403
+ })
1404
+ }),
1405
+ /* @__PURE__ */ jsxs("div", {
1406
+ className: "flex-1 min-w-0",
1407
+ children: [/* @__PURE__ */ jsx("p", {
1408
+ className: "font-semibold text-xs md:text-sm mb-0.5 md:mb-1",
1409
+ style: { color: "var(--text-primary)" },
1410
+ children: title
1411
+ }), /* @__PURE__ */ jsx("p", {
1412
+ className: "text-xs md:text-sm",
1413
+ style: { color: "var(--text-secondary)" },
1414
+ children: message
1415
+ })]
1416
+ }),
1417
+ /* @__PURE__ */ jsx("button", {
1418
+ onClick: onClose,
1419
+ className: "p-1 md:p-1.5 rounded-lg shrink-0",
1420
+ style: { color: "var(--text-muted)" },
1421
+ type: "button",
1422
+ "aria-label": "Close notification",
1423
+ children: /* @__PURE__ */ jsx(X, { className: ICON_SIZES.md })
1424
+ })
1425
+ ]
1426
+ });
1427
+ });
1428
+ NotificationGlass.displayName = "NotificationGlass";
1429
+ var PopoverGlassRoot = PopoverPrimitive.Root;
1430
+ var PopoverGlassTrigger = PopoverPrimitive.Trigger;
1431
+ var PopoverGlassAnchor = PopoverPrimitive.Anchor;
1432
+ var PopoverGlassContent = React.forwardRef(({ className, align = "center", sideOffset = 8, showArrow = true, children, ...props }, ref) => {
1433
+ const popoverStyles = {
1434
+ background: "var(--popover-bg)",
1435
+ border: "1px solid var(--popover-border)",
1436
+ boxShadow: "var(--popover-shadow)",
1437
+ backdropFilter: "blur(var(--blur-md))",
1438
+ WebkitBackdropFilter: "blur(var(--blur-md))"
1439
+ };
1440
+ const arrowStyles = { fill: "var(--popover-arrow-bg)" };
1441
+ return /* @__PURE__ */ jsx(PopoverPrimitive.Portal, { children: /* @__PURE__ */ jsxs(PopoverPrimitive.Content, {
1442
+ ref,
1443
+ align,
1444
+ sideOffset,
1445
+ className: cn("z-50003 rounded-2xl", "animate-in fade-in-0 zoom-in-95 duration-200", "data-[side=bottom]:slide-in-from-top-2", "data-[side=top]:slide-in-from-bottom-2", "data-[side=right]:slide-in-from-left-2", "data-[side=left]:slide-in-from-right-2", "outline-none", className),
1446
+ style: popoverStyles,
1447
+ ...props,
1448
+ children: [children, showArrow && /* @__PURE__ */ jsx(PopoverPrimitive.Arrow, {
1449
+ className: "fill-current",
1450
+ style: arrowStyles,
1451
+ width: 16,
1452
+ height: 8
1453
+ })]
1454
+ }) });
1455
+ });
1456
+ PopoverGlassContent.displayName = "PopoverGlassContent";
1457
+ var PopoverGlassLegacy = React.forwardRef(({ trigger, children, side = "bottom", align = "center", sideOffset = 8, open, onOpenChange, showArrow = true, className }, ref) => {
1458
+ return /* @__PURE__ */ jsxs(PopoverGlassRoot, {
1459
+ open,
1460
+ onOpenChange,
1461
+ children: [/* @__PURE__ */ jsx(PopoverGlassTrigger, {
1462
+ asChild: true,
1463
+ children: trigger
1464
+ }), /* @__PURE__ */ jsx(PopoverGlassContent, {
1465
+ ref,
1466
+ side,
1467
+ align,
1468
+ sideOffset,
1469
+ showArrow,
1470
+ className,
1471
+ children
1472
+ })]
1473
+ });
1474
+ });
1475
+ PopoverGlassLegacy.displayName = "PopoverGlassLegacy";
1476
+ const PopoverGlass = PopoverGlassRoot;
1477
+ const skeletonVariants = cva("overflow-hidden", {
1478
+ variants: { variant: {
1479
+ text: "h-3 md:h-4 rounded",
1480
+ title: "h-5 md:h-6 rounded",
1481
+ avatar: "w-10 h-10 md:w-12 md:h-12 rounded-full",
1482
+ thumbnail: "w-full h-24 md:h-32 rounded-xl",
1483
+ card: "w-full h-36 md:h-48 rounded-2xl"
1484
+ } },
1485
+ defaultVariants: { variant: "text" }
1486
+ });
1487
+ const SkeletonGlass = forwardRef(({ className, variant = "text", width, height, style, ...props }, ref) => {
1488
+ const skeletonStyles = {
1489
+ width,
1490
+ height,
1491
+ background: "linear-gradient(90deg, var(--skeleton-bg) 25%, var(--skeleton-shine) 50%, var(--skeleton-bg) 75%)",
1492
+ backgroundSize: "200% 100%",
1493
+ animation: "skeleton-loading 1.5s infinite",
1494
+ ...style
1495
+ };
1496
+ return /* @__PURE__ */ jsx("div", {
1497
+ ref,
1498
+ className: cn(skeletonVariants({ variant }), className),
1499
+ style: skeletonStyles,
1500
+ "aria-hidden": "true",
1501
+ ...props
1502
+ });
1503
+ });
1504
+ SkeletonGlass.displayName = "SkeletonGlass";
1505
+ const SliderGlass = forwardRef(({ className, value, defaultValue, onValueChange, onValueCommit, min = 0, max = 100, step = 1, showValue, label, error, success, disabled, orientation = "horizontal", ...props }, ref) => {
1506
+ const currentValue = value ?? defaultValue ?? [min];
1507
+ const formatValueDisplay = (values) => {
1508
+ if (values.length === 1) return `${values[0]}`;
1509
+ return `${values[0]} - ${values[values.length - 1]}`;
1510
+ };
1511
+ const trackStyles = { background: "var(--slider-track)" };
1512
+ const rangeStyles = { background: "var(--slider-fill)" };
1513
+ const thumbStyles = {
1514
+ background: "var(--slider-thumb)",
1515
+ border: "2px solid var(--slider-thumb-border)"
1516
+ };
1517
+ const customLabel = label && showValue || !label && showValue ? /* @__PURE__ */ jsxs("div", {
1518
+ className: "flex justify-between mb-1.5 md:mb-2",
1519
+ children: [label && /* @__PURE__ */ jsx("label", {
1520
+ className: "text-xs md:text-sm font-medium",
1521
+ style: { color: "var(--text-secondary)" },
1522
+ children: label
1523
+ }), /* @__PURE__ */ jsx("span", {
1524
+ className: "text-xs md:text-sm font-medium tabular-nums",
1525
+ style: { color: "var(--text-secondary)" },
1526
+ children: formatValueDisplay(currentValue)
1527
+ })]
1528
+ }) : void 0;
1529
+ return /* @__PURE__ */ jsxs(FormFieldWrapper, {
1530
+ label: showValue ? void 0 : label,
1531
+ error,
1532
+ success,
1533
+ className: cn("w-full", className),
1534
+ children: [customLabel, /* @__PURE__ */ jsxs(SliderPrimitive.Root, {
1535
+ ref,
1536
+ value,
1537
+ defaultValue,
1538
+ onValueChange,
1539
+ onValueCommit,
1540
+ min,
1541
+ max,
1542
+ step,
1543
+ disabled,
1544
+ orientation,
1545
+ className: cn("relative flex touch-none select-none", orientation === "horizontal" ? "w-full h-8 md:h-6 items-center" : "flex-col h-full w-8 md:w-6 justify-center", disabled && "opacity-50 cursor-not-allowed", "group"),
1546
+ ...props,
1547
+ children: [/* @__PURE__ */ jsx(SliderPrimitive.Track, {
1548
+ className: cn("relative grow rounded-full", orientation === "horizontal" ? "h-2.5 md:h-2 w-full" : "w-2.5 md:w-2 h-full"),
1549
+ style: trackStyles,
1550
+ children: /* @__PURE__ */ jsx(SliderPrimitive.Range, {
1551
+ className: cn("absolute rounded-full transition-shadow duration-150", orientation === "horizontal" ? "h-full" : "w-full", "group-hover:shadow-(--slider-fill-glow)", "group-active:shadow-(--slider-fill-glow)"),
1552
+ style: rangeStyles
1553
+ })
1554
+ }), currentValue.map((_, index) => /* @__PURE__ */ jsx(SliderPrimitive.Thumb, {
1555
+ className: cn("block rounded-full shadow-md transition-all duration-150", "w-6 h-6 md:w-5 md:h-5", "hover:scale-105", "focus-visible:outline-none focus-visible:shadow-(--focus-glow)", "active:scale-110", disabled && "pointer-events-none"),
1556
+ style: thumbStyles,
1557
+ "aria-label": label ? currentValue.length > 1 ? `${label} thumb ${index + 1}` : label : `Slider thumb ${index + 1}`
1558
+ }, index))]
1559
+ })]
1560
+ });
1561
+ });
1562
+ SliderGlass.displayName = "SliderGlass";
1563
+ var TabsContext = createContext(null);
1564
+ var useTabsContext = () => {
1565
+ const context = useContext(TabsContext);
1566
+ if (!context) throw new Error("Tabs compound components must be used within TabsGlass.Root");
1567
+ return context;
1568
+ };
1569
+ var TabsRoot = ({ value: controlledValue, defaultValue, onValueChange, children, className }) => {
1570
+ const [uncontrolledValue, setUncontrolledValue] = useState(defaultValue ?? "");
1571
+ const isControlled = controlledValue !== void 0;
1572
+ const value = isControlled ? controlledValue : uncontrolledValue;
1573
+ const handleValueChange = (newValue) => {
1574
+ if (!isControlled) setUncontrolledValue(newValue);
1575
+ onValueChange?.(newValue);
1576
+ };
1577
+ return /* @__PURE__ */ jsx(TabsContext.Provider, {
1578
+ value: {
1579
+ value,
1580
+ onValueChange: handleValueChange
1581
+ },
1582
+ children: /* @__PURE__ */ jsx("div", {
1583
+ className: cn("tabs-glass-root", className),
1584
+ children
1585
+ })
1586
+ });
1587
+ };
1588
+ var TabsList = forwardRef(({ children, className, ...props }, ref) => {
1589
+ return /* @__PURE__ */ jsx("div", {
1590
+ ref,
1591
+ className: cn("inline-flex gap-0.5 md:gap-1 p-0.5 md:p-1 rounded-xl", className),
1592
+ style: {
1593
+ background: "var(--tab-container-bg)",
1594
+ border: "1px solid var(--tab-container-border)"
1595
+ },
1596
+ role: "tablist",
1597
+ ...props,
1598
+ children
1599
+ });
1600
+ });
1601
+ TabsList.displayName = "TabsList";
1602
+ var TabsTrigger = forwardRef(({ value, children, className, disabled }, ref) => {
1603
+ const { value: activeValue, onValueChange } = useTabsContext();
1604
+ const { isFocusVisible, focusProps } = useFocus({ focusVisible: true });
1605
+ const isActive = activeValue === value;
1606
+ const tabStyles = {
1607
+ background: isActive ? "var(--tab-active-bg)" : "var(--tab-bg)",
1608
+ color: isActive ? "var(--tab-active-text)" : "var(--text-secondary)",
1609
+ boxShadow: isFocusVisible && !disabled ? "var(--focus-glow)" : "none"
1610
+ };
1611
+ const handleKeyDown = (e) => {
1612
+ if (disabled) return;
1613
+ const tablist = e.currentTarget.closest("[role=\"tablist\"]");
1614
+ if (!tablist) return;
1615
+ const tabs = Array.from(tablist.querySelectorAll("[role=\"tab\"]:not([disabled])"));
1616
+ const currentIndex = tabs.indexOf(e.currentTarget);
1617
+ let nextIndex = currentIndex;
1618
+ switch (e.key) {
1619
+ case "ArrowRight":
1620
+ e.preventDefault();
1621
+ nextIndex = currentIndex + 1 >= tabs.length ? 0 : currentIndex + 1;
1622
+ break;
1623
+ case "ArrowLeft":
1624
+ e.preventDefault();
1625
+ nextIndex = currentIndex - 1 < 0 ? tabs.length - 1 : currentIndex - 1;
1626
+ break;
1627
+ case "Home":
1628
+ e.preventDefault();
1629
+ nextIndex = 0;
1630
+ break;
1631
+ case "End":
1632
+ e.preventDefault();
1633
+ nextIndex = tabs.length - 1;
1634
+ break;
1635
+ default: return;
1636
+ }
1637
+ const nextTab = tabs[nextIndex];
1638
+ if (nextTab) {
1639
+ nextTab.focus();
1640
+ const nextValue = nextTab.getAttribute("data-value");
1641
+ if (nextValue && onValueChange) onValueChange(nextValue);
1642
+ }
1643
+ };
1644
+ return /* @__PURE__ */ jsxs("button", {
1645
+ ref,
1646
+ type: "button",
1647
+ role: "tab",
1648
+ "aria-selected": isActive,
1649
+ disabled,
1650
+ "data-value": value,
1651
+ className: cn("relative px-2.5 py-1.5 md:px-4 md:py-2 rounded-lg text-xs md:text-sm font-medium transition-[background-color,color,opacity] duration-300", disabled && "opacity-50 cursor-not-allowed", className),
1652
+ style: tabStyles,
1653
+ onClick: () => !disabled && onValueChange?.(value),
1654
+ onKeyDown: handleKeyDown,
1655
+ onFocus: focusProps.onFocus,
1656
+ onBlur: focusProps.onBlur,
1657
+ children: [children, isActive && /* @__PURE__ */ jsx("div", {
1658
+ className: "absolute bottom-0 left-1/2 -translate-x-1/2 w-6 md:w-8 h-0.5 rounded-full",
1659
+ style: { background: "var(--tab-indicator)" }
1660
+ })]
1661
+ });
1662
+ });
1663
+ TabsTrigger.displayName = "TabsTrigger";
1664
+ var TabsContent = ({ value, children, className }) => {
1665
+ const { value: activeValue } = useTabsContext();
1666
+ const isActive = activeValue === value;
1667
+ if (!isActive) return null;
1668
+ return /* @__PURE__ */ jsx("div", {
1669
+ role: "tabpanel",
1670
+ "aria-hidden": !isActive,
1671
+ className: cn("animate-in fade-in-0 duration-200", className),
1672
+ children
1673
+ });
1674
+ };
1675
+ const TabsGlass = {
1676
+ Root: TabsRoot,
1677
+ List: TabsList,
1678
+ Trigger: TabsTrigger,
1679
+ Content: TabsContent
1680
+ };
1681
+ const Tabs = TabsRoot;
1682
+ const toggleSizes = cva("relative rounded-full transition-all duration-300", {
1683
+ variants: {
1684
+ size: {
1685
+ sm: "w-8 h-4",
1686
+ default: "w-11 h-6",
1687
+ lg: "w-14 h-7"
1688
+ },
1689
+ variant: {
1690
+ default: "",
1691
+ outline: "border-2"
1692
+ }
1693
+ },
1694
+ defaultVariants: {
1695
+ size: "default",
1696
+ variant: "default"
1697
+ }
1698
+ });
1699
+ var sizesConfig = {
1700
+ sm: {
1701
+ track: "w-8 h-4",
1702
+ knob: "w-3 h-3",
1703
+ translate: "translate-x-4"
1704
+ },
1705
+ default: {
1706
+ track: "w-11 h-6",
1707
+ knob: "w-5 h-5",
1708
+ translate: "translate-x-5"
1709
+ },
1710
+ lg: {
1711
+ track: "w-14 h-7",
1712
+ knob: "w-6 h-6",
1713
+ translate: "translate-x-7"
1714
+ }
1715
+ };
1716
+ const ToggleGlass = forwardRef(({ className, size = "default", variant = "default", pressed: controlledPressed, defaultPressed = false, onPressedChange, disabled, label, ...props }, ref) => {
1717
+ const [uncontrolledPressed, setUncontrolledPressed] = useState(defaultPressed);
1718
+ const isControlled = controlledPressed !== void 0;
1719
+ const isPressed = isControlled ? controlledPressed : uncontrolledPressed;
1720
+ const { isFocusVisible, focusProps } = useFocus({ focusVisible: true });
1721
+ const s = sizesConfig[size ?? "default"];
1722
+ const handleToggle = () => {
1723
+ if (disabled) return;
1724
+ const newValue = !isPressed;
1725
+ if (!isControlled) setUncontrolledPressed(newValue);
1726
+ onPressedChange?.(newValue);
1727
+ };
1728
+ const getTrackStyles = () => {
1729
+ if (variant === "outline") return {
1730
+ background: isPressed ? "var(--toggle-outline-active-bg)" : "transparent",
1731
+ borderColor: isPressed ? "var(--toggle-outline-active-border)" : "var(--toggle-outline-border)",
1732
+ boxShadow: isFocusVisible && !disabled ? "var(--focus-glow)" : "none"
1733
+ };
1734
+ return {
1735
+ background: isPressed ? "var(--toggle-active-bg)" : "var(--toggle-bg)",
1736
+ boxShadow: isFocusVisible && !disabled ? "var(--focus-glow)" : isPressed ? "var(--toggle-glow)" : "none"
1737
+ };
1738
+ };
1739
+ const knobStyles = { background: "var(--toggle-knob)" };
1740
+ const toggle = /* @__PURE__ */ jsx("span", {
1741
+ className: "inline-flex items-center justify-center min-h-11",
1742
+ children: /* @__PURE__ */ jsx("button", {
1743
+ ref,
1744
+ type: "button",
1745
+ role: "switch",
1746
+ "aria-pressed": isPressed,
1747
+ "aria-label": label || "Toggle switch",
1748
+ disabled,
1749
+ className: cn(toggleSizes({
1750
+ size,
1751
+ variant
1752
+ }), disabled ? "opacity-50 cursor-not-allowed" : "cursor-pointer", !label && className),
1753
+ style: getTrackStyles(),
1754
+ onClick: handleToggle,
1755
+ onFocus: focusProps.onFocus,
1756
+ onBlur: focusProps.onBlur,
1757
+ ...props,
1758
+ children: /* @__PURE__ */ jsx("div", {
1759
+ className: cn("absolute top-0.5 left-0.5 rounded-full shadow-md transition-all duration-300", s.knob, isPressed && s.translate),
1760
+ style: knobStyles
1761
+ })
1762
+ })
1763
+ });
1764
+ if (label) return /* @__PURE__ */ jsxs("label", {
1765
+ className: cn("inline-flex items-center gap-2 md:gap-2.5", disabled ? "opacity-50 cursor-not-allowed" : "cursor-pointer", className),
1766
+ children: [toggle, /* @__PURE__ */ jsx("span", {
1767
+ className: "text-xs md:text-sm",
1768
+ style: { color: "var(--text-secondary)" },
1769
+ children: label
1770
+ })]
1771
+ });
1772
+ return toggle;
1773
+ });
1774
+ ToggleGlass.displayName = "ToggleGlass";
1775
+ var TooltipGlassProvider = ({ delayDuration = 0, ...props }) => {
1776
+ return /* @__PURE__ */ jsx(TooltipPrimitive.Provider, {
1777
+ "data-slot": "tooltip-provider",
1778
+ delayDuration,
1779
+ ...props
1780
+ });
1781
+ };
1782
+ TooltipGlassProvider.displayName = "TooltipGlassProvider";
1783
+ function TooltipGlassRoot({ ...props }) {
1784
+ return /* @__PURE__ */ jsx(TooltipGlassProvider, { children: /* @__PURE__ */ jsx(TooltipPrimitive.Root, {
1785
+ "data-slot": "tooltip",
1786
+ ...props
1787
+ }) });
1788
+ }
1789
+ var TooltipGlassTrigger = React.forwardRef(({ ...props }, ref) => /* @__PURE__ */ jsx(TooltipPrimitive.Trigger, {
1790
+ ref,
1791
+ "data-slot": "tooltip-trigger",
1792
+ ...props
1793
+ }));
1794
+ TooltipGlassTrigger.displayName = "TooltipGlassTrigger";
1795
+ var TooltipGlassContent = React.forwardRef(({ className, sideOffset = 0, children, ...props }, ref) => {
1796
+ const tooltipStyles = {
1797
+ background: "var(--tooltip-bg)",
1798
+ color: "var(--tooltip-text)",
1799
+ border: "1px solid var(--tooltip-border)",
1800
+ boxShadow: "var(--tooltip-shadow)",
1801
+ backdropFilter: "blur(var(--blur-xl))",
1802
+ WebkitBackdropFilter: "blur(var(--blur-xl))"
1803
+ };
1804
+ return /* @__PURE__ */ jsx(TooltipPrimitive.Portal, { children: /* @__PURE__ */ jsxs(TooltipPrimitive.Content, {
1805
+ ref,
1806
+ sideOffset,
1807
+ "data-slot": "tooltip-content",
1808
+ className: cn("z-50 w-fit origin-(--radix-tooltip-content-transform-origin) rounded-md px-3 py-1.5 text-xs text-balance", "animate-in fade-in-0 zoom-in-95", "data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95", "data-[side=bottom]:slide-in-from-top-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", className),
1809
+ style: tooltipStyles,
1810
+ ...props,
1811
+ children: [children, /* @__PURE__ */ jsx(TooltipPrimitive.Arrow, {
1812
+ className: "z-50 size-2.5 translate-y-[calc(-50%-2px)] rotate-45 rounded-xs",
1813
+ style: {
1814
+ fill: "var(--tooltip-bg)",
1815
+ background: "var(--tooltip-bg)"
1816
+ }
1817
+ })]
1818
+ }) });
1819
+ });
1820
+ TooltipGlassContent.displayName = "TooltipGlassContent";
1821
+ var TooltipGlassSimple = ({ content, children, side = "top", className }) => {
1822
+ return /* @__PURE__ */ jsxs(TooltipGlassRoot, { children: [/* @__PURE__ */ jsx(TooltipGlassTrigger, {
1823
+ asChild: true,
1824
+ children
1825
+ }), /* @__PURE__ */ jsx(TooltipGlassContent, {
1826
+ side,
1827
+ className,
1828
+ children: content
1829
+ })] });
1830
+ };
1831
+ const TooltipGlass = TooltipGlassRoot;
1832
+ const ExpandableHeaderGlass = forwardRef(({ title, icon: Icon, iconColor = "var(--text-accent)", expanded, onToggle, className, ...props }, ref) => {
1833
+ const textStyles = { color: "var(--text-primary)" };
1834
+ const chevronStyles = { color: "var(--text-muted)" };
1835
+ const iconStyles = { color: iconColor };
1836
+ return /* @__PURE__ */ jsxs("button", {
1837
+ ref,
1838
+ type: "button",
1839
+ onClick: onToggle,
1840
+ "aria-expanded": expanded,
1841
+ className: cn("w-full p-4 flex items-center justify-between rounded-2xl transition-colors hover:bg-white/5", className),
1842
+ style: textStyles,
1843
+ ...props,
1844
+ children: [/* @__PURE__ */ jsxs("div", {
1845
+ className: "flex items-center gap-2",
1846
+ children: [Icon && /* @__PURE__ */ jsx(Icon, {
1847
+ className: "w-5 h-5",
1848
+ style: iconStyles
1849
+ }), /* @__PURE__ */ jsx("span", {
1850
+ className: "font-medium",
1851
+ children: title
1852
+ })]
1853
+ }), expanded ? /* @__PURE__ */ jsx(ChevronUp, {
1854
+ className: "w-5 h-5",
1855
+ style: chevronStyles
1856
+ }) : /* @__PURE__ */ jsx(ChevronDown, {
1857
+ className: "w-5 h-5",
1858
+ style: chevronStyles
1859
+ })]
1860
+ });
1861
+ });
1862
+ ExpandableHeaderGlass.displayName = "ExpandableHeaderGlass";
1863
+ var iconButtonVariants = cva("rounded-xl flex items-center justify-center transition-all duration-300 hover:scale-105 focus:outline-none focus:ring-2 focus:ring-offset-2", {
1864
+ variants: {
1865
+ size: {
1866
+ sm: "w-8 h-8",
1867
+ md: "w-10 h-10",
1868
+ lg: "w-12 h-12",
1869
+ touch: "w-11 h-11 md:w-10 md:h-10"
1870
+ },
1871
+ variant: {
1872
+ gradient: "",
1873
+ subtle: "",
1874
+ ghost: "bg-transparent hover:bg-white/10"
1875
+ }
1876
+ },
1877
+ defaultVariants: {
1878
+ size: "md",
1879
+ variant: "gradient"
1880
+ }
1881
+ });
1882
+ const IconButtonGlass = forwardRef(({ icon: Icon, iconSize = 20, size, variant, className, "aria-label": ariaLabel, ...props }, ref) => {
1883
+ const gradientStyles = variant === "gradient" ? {
1884
+ background: "linear-gradient(135deg, var(--icon-btn-from), var(--icon-btn-to))",
1885
+ boxShadow: "var(--icon-btn-shadow)"
1886
+ } : void 0;
1887
+ const subtleStyles = variant === "subtle" ? {
1888
+ background: "var(--card-subtle-bg)",
1889
+ border: "1px solid var(--card-subtle-border)"
1890
+ } : void 0;
1891
+ const iconStyles = { color: "var(--icon-btn-text)" };
1892
+ return /* @__PURE__ */ jsx("button", {
1893
+ ref,
1894
+ type: "button",
1895
+ "aria-label": ariaLabel,
1896
+ className: cn(iconButtonVariants({
1897
+ size,
1898
+ variant
1899
+ }), className),
1900
+ style: gradientStyles ?? subtleStyles,
1901
+ ...props,
1902
+ children: /* @__PURE__ */ jsx(Icon, {
1903
+ size: iconSize,
1904
+ style: iconStyles
1905
+ })
1906
+ });
1907
+ });
1908
+ IconButtonGlass.displayName = "IconButtonGlass";
1909
+ const insightVariantConfig = {
1910
+ default: {
1911
+ defaultEmoji: "💡",
1912
+ glowVar: "--glow-primary",
1913
+ borderVar: "--glass-border"
1914
+ },
1915
+ tip: {
1916
+ defaultEmoji: "💡",
1917
+ glowVar: "--glow-secondary",
1918
+ borderVar: "--alert-default-border"
1919
+ },
1920
+ highlight: {
1921
+ defaultEmoji: "✨",
1922
+ glowVar: "--glow-success",
1923
+ borderVar: "--alert-success-border"
1924
+ },
1925
+ warning: {
1926
+ defaultEmoji: "⚠️",
1927
+ glowVar: "--glow-warning",
1928
+ borderVar: "--alert-warning-border"
1929
+ },
1930
+ stat: {
1931
+ defaultEmoji: "📊",
1932
+ glowVar: null,
1933
+ borderVar: "--glass-border"
1934
+ },
1935
+ growth: {
1936
+ defaultEmoji: "📈",
1937
+ glowVar: "--glow-success",
1938
+ borderVar: "--alert-success-border"
1939
+ },
1940
+ decline: {
1941
+ defaultEmoji: "📉",
1942
+ glowVar: "--glow-error",
1943
+ borderVar: "--alert-destructive-border"
1944
+ }
1945
+ };
1946
+ const insightCardVariants = cva("relative rounded-lg transition-all duration-200", {
1947
+ variants: {
1948
+ inline: {
1949
+ true: "inline-flex items-center gap-1.5",
1950
+ false: "p-3 bg-[var(--glass-bg-subtle)] border"
1951
+ },
1952
+ clickable: {
1953
+ true: "cursor-pointer hover:bg-[var(--glass-bg)]",
1954
+ false: ""
1955
+ }
1956
+ },
1957
+ defaultVariants: {
1958
+ inline: false,
1959
+ clickable: false
1960
+ }
1961
+ });
1962
+ const InsightCardGlass = forwardRef(({ emoji, text, detail, variant = "default", inline = false, onClick, showArrow = false, animated = false, className, ...props }, ref) => {
1963
+ const config = insightVariantConfig[variant];
1964
+ const displayEmoji = emoji ?? config.defaultEmoji;
1965
+ const isClickable = !!onClick;
1966
+ const handleClick = () => onClick?.();
1967
+ const handleKeyDown = (e) => {
1968
+ if (isClickable && (e.key === "Enter" || e.key === " ")) {
1969
+ e.preventDefault();
1970
+ onClick?.();
1971
+ }
1972
+ };
1973
+ const borderStyle = !inline ? { borderColor: `var(${config.borderVar})` } : {};
1974
+ const glowStyle = isClickable && config.glowVar ? { "--hover-glow": `var(${config.glowVar})` } : {};
1975
+ if (inline) return /* @__PURE__ */ jsxs("span", {
1976
+ ref,
1977
+ className: cn("inline-flex items-center gap-1.5 text-sm text-[var(--text-secondary)]", className),
1978
+ ...props,
1979
+ children: [
1980
+ /* @__PURE__ */ jsx("span", {
1981
+ "aria-hidden": "true",
1982
+ children: displayEmoji
1983
+ }),
1984
+ /* @__PURE__ */ jsx("span", { children: text }),
1985
+ detail && /* @__PURE__ */ jsxs("span", {
1986
+ className: "text-[var(--text-muted)]",
1987
+ children: [
1988
+ "(",
1989
+ detail,
1990
+ ")"
1991
+ ]
1992
+ })
1993
+ ]
1994
+ });
1995
+ return /* @__PURE__ */ jsx("div", {
1996
+ ref,
1997
+ role: isClickable ? "button" : void 0,
1998
+ tabIndex: isClickable ? 0 : void 0,
1999
+ onClick: isClickable ? handleClick : void 0,
2000
+ onKeyDown: isClickable ? handleKeyDown : void 0,
2001
+ className: cn(insightCardVariants({
2002
+ inline,
2003
+ clickable: isClickable
2004
+ }), isClickable && config.glowVar && "hover:shadow-[0_0_12px_var(--hover-glow)]", animated && "animate-insight-fade-in", className),
2005
+ style: {
2006
+ ...borderStyle,
2007
+ ...glowStyle
2008
+ },
2009
+ ...props,
2010
+ children: /* @__PURE__ */ jsxs("div", {
2011
+ className: "flex items-start gap-2",
2012
+ children: [
2013
+ /* @__PURE__ */ jsx("span", {
2014
+ className: "text-lg flex-shrink-0",
2015
+ "aria-hidden": "true",
2016
+ children: displayEmoji
2017
+ }),
2018
+ /* @__PURE__ */ jsxs("div", {
2019
+ className: "flex-1 min-w-0",
2020
+ children: [/* @__PURE__ */ jsx("p", {
2021
+ className: "text-sm text-[var(--text-primary)]",
2022
+ children: text
2023
+ }), detail && /* @__PURE__ */ jsx("p", {
2024
+ className: "text-xs text-[var(--text-muted)] mt-0.5",
2025
+ children: detail
2026
+ })]
2027
+ }),
2028
+ showArrow && /* @__PURE__ */ jsx(ChevronRight, {
2029
+ className: "w-4 h-4 text-[var(--text-muted)] flex-shrink-0",
2030
+ "aria-hidden": "true"
2031
+ })
2032
+ ]
2033
+ })
2034
+ });
2035
+ });
2036
+ InsightCardGlass.displayName = "InsightCardGlass";
2037
+ const SearchBoxGlass = forwardRef(({ onSubmit, defaultValue = "", value: controlledValue, onChange: controlledOnChange, variant = "default", inputWidth = "w-32 sm:w-40 md:w-48", placeholder = "Search username...", className, ...props }, ref) => {
2038
+ const [internalValue, setInternalValue] = useState(defaultValue);
2039
+ const [isFocused, setIsFocused] = useState(false);
2040
+ const isControlled = controlledValue !== void 0;
2041
+ const value = isControlled ? controlledValue : internalValue;
2042
+ const handleChange = (e) => {
2043
+ const newValue = e.target.value;
2044
+ if (isControlled) controlledOnChange?.(newValue);
2045
+ else setInternalValue(newValue);
2046
+ };
2047
+ const handleSubmit = () => {
2048
+ onSubmit?.(value);
2049
+ };
2050
+ const handleKeyDown = (e) => {
2051
+ if (e.key === "Enter") handleSubmit();
2052
+ };
2053
+ const containerStyles = { boxShadow: isFocused ? "var(--focus-glow)" : "none" };
2054
+ const inputStyles = {
2055
+ background: "var(--search-bg)",
2056
+ color: "var(--text-primary)",
2057
+ border: "1px solid var(--search-border)",
2058
+ borderRight: "none",
2059
+ borderTopLeftRadius: "0.75rem",
2060
+ borderBottomLeftRadius: "0.75rem"
2061
+ };
2062
+ const buttonStyles = {
2063
+ background: "var(--search-btn-bg)",
2064
+ color: "var(--search-btn-text)",
2065
+ borderTopRightRadius: "0.75rem",
2066
+ borderBottomRightRadius: "0.75rem"
2067
+ };
2068
+ return /* @__PURE__ */ jsxs("div", {
2069
+ className: cn("flex w-fit rounded-xl overflow-hidden", className),
2070
+ style: containerStyles,
2071
+ children: [/* @__PURE__ */ jsx("input", {
2072
+ ref,
2073
+ type: "text",
2074
+ value,
2075
+ onChange: handleChange,
2076
+ onFocus: () => setIsFocused(true),
2077
+ onBlur: () => setIsFocused(false),
2078
+ onKeyDown: handleKeyDown,
2079
+ placeholder,
2080
+ "aria-label": placeholder,
2081
+ className: cn("px-4 py-2 text-sm outline-none transition-all", inputWidth),
2082
+ style: inputStyles,
2083
+ ...props
2084
+ }), /* @__PURE__ */ jsxs("button", {
2085
+ onClick: handleSubmit,
2086
+ type: "button",
2087
+ className: cn("px-5 py-2 text-sm font-medium flex items-center gap-2 hover:scale-[1.02] transition-transform", variant === "compact" && "px-3"),
2088
+ style: buttonStyles,
2089
+ "aria-label": "Search",
2090
+ children: [/* @__PURE__ */ jsx(Search, { className: "w-4 h-4" }), variant === "default" && /* @__PURE__ */ jsx("span", {
2091
+ className: "hidden sm:inline",
2092
+ children: "Search"
2093
+ })]
2094
+ })]
2095
+ });
2096
+ });
2097
+ SearchBoxGlass.displayName = "SearchBoxGlass";
2098
+ var fieldLabels = {
2099
+ commits: "Commits",
2100
+ stars: "Stars",
2101
+ name: "Name",
2102
+ contribution: "Contribution"
2103
+ };
2104
+ const SortDropdownGlass = React.forwardRef(({ sortBy, sortOrder, onSortChange, options = [
2105
+ "commits",
2106
+ "stars",
2107
+ "name",
2108
+ "contribution"
2109
+ ], compact = false, className, ...props }, ref) => {
2110
+ const handleFieldSelect = React.useCallback((field) => {
2111
+ if (field === sortBy) onSortChange(field, sortOrder === "asc" ? "desc" : "asc");
2112
+ else onSortChange(field, "desc");
2113
+ }, [
2114
+ sortBy,
2115
+ sortOrder,
2116
+ onSortChange
2117
+ ]);
2118
+ const SortIcon = sortOrder === "asc" ? ArrowUp : ArrowDown;
2119
+ return /* @__PURE__ */ jsx("div", {
2120
+ ref,
2121
+ className: cn("relative inline-block", className),
2122
+ ...props,
2123
+ children: /* @__PURE__ */ jsxs(DropdownMenuGlass, { children: [/* @__PURE__ */ jsx(DropdownMenuGlassTrigger, {
2124
+ asChild: true,
2125
+ children: /* @__PURE__ */ jsx("button", {
2126
+ type: "button",
2127
+ className: cn("flex items-center gap-1.5 px-3 py-1.5 rounded-xl text-xs font-medium", "sm:gap-2 sm:px-4 sm:py-2 sm:text-sm", "bg-(--dropdown-bg) border border-(--dropdown-border)", "backdrop-blur-md", "transition-all duration-200", "hover:opacity-90 hover:shadow-(--dropdown-glow)", "focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2", "focus-visible:ring-(--text-accent)", "text-(--dropdown-item-text)"),
2128
+ "aria-haspopup": "menu",
2129
+ children: compact ? /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx("span", { children: "Sort" }), /* @__PURE__ */ jsx(SortIcon, { className: cn(ICON_SIZES.sm, "text-(--text-accent)") })] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
2130
+ /* @__PURE__ */ jsx("span", {
2131
+ className: "hidden sm:inline text-(--text-muted)",
2132
+ children: "Sort:"
2133
+ }),
2134
+ /* @__PURE__ */ jsx("span", { children: fieldLabels[sortBy] }),
2135
+ /* @__PURE__ */ jsx(SortIcon, { className: cn(ICON_SIZES.sm, "text-(--text-accent)") }),
2136
+ /* @__PURE__ */ jsx(ChevronDown, { className: cn(ICON_SIZES.sm, "text-(--text-muted)", "transition-transform duration-200", "group-data-[state=open]:rotate-180") })
2137
+ ] })
2138
+ })
2139
+ }), /* @__PURE__ */ jsx(DropdownMenuGlassContent, {
2140
+ align: "start",
2141
+ "aria-label": "Sort options",
2142
+ children: options.map((field) => {
2143
+ const isSelected = field === sortBy;
2144
+ return /* @__PURE__ */ jsxs(DropdownMenuGlassItem, {
2145
+ onSelect: () => handleFieldSelect(field),
2146
+ className: cn("justify-between", isSelected && "bg-(--select-item-selected-bg)"),
2147
+ children: [/* @__PURE__ */ jsx("span", {
2148
+ className: "font-medium",
2149
+ children: fieldLabels[field]
2150
+ }), isSelected && /* @__PURE__ */ jsxs("div", {
2151
+ className: "flex items-center gap-1 text-(--text-accent)",
2152
+ children: [sortOrder === "asc" ? /* @__PURE__ */ jsx(ArrowUp, { className: ICON_SIZES.sm }) : /* @__PURE__ */ jsx(ArrowDown, { className: ICON_SIZES.sm }), /* @__PURE__ */ jsx(Check, { className: ICON_SIZES.sm })]
2153
+ })]
2154
+ }, field);
2155
+ })
2156
+ })] })
2157
+ });
2158
+ });
2159
+ SortDropdownGlass.displayName = "SortDropdownGlass";
2160
+ var statItemVariants = cva("flex items-center gap-1", {
2161
+ variants: {
2162
+ size: {
2163
+ sm: "text-xs",
2164
+ md: "text-sm",
2165
+ lg: "text-base"
2166
+ },
2167
+ layout: {
2168
+ horizontal: "flex-row",
2169
+ vertical: "flex-col items-start gap-0.5"
2170
+ }
2171
+ },
2172
+ defaultVariants: {
2173
+ size: "md",
2174
+ layout: "horizontal"
2175
+ }
2176
+ });
2177
+ const StatItemGlass = forwardRef(({ icon: Icon, value, label, iconSize = 16, abbreviated = false, size, layout, className, ...props }, ref) => {
2178
+ const textStyles = { color: "var(--text-secondary)" };
2179
+ const iconStyles = { color: "var(--text-accent)" };
2180
+ const formatValue = (val) => {
2181
+ if (!abbreviated || typeof val !== "number") return String(val);
2182
+ if (val >= 1e6) return `${(val / 1e6).toFixed(1)}M`;
2183
+ if (val >= 1e3) return `${(val / 1e3).toFixed(1)}k`;
2184
+ return String(val);
2185
+ };
2186
+ return /* @__PURE__ */ jsxs("span", {
2187
+ ref,
2188
+ className: cn(statItemVariants({
2189
+ size,
2190
+ layout
2191
+ }), className),
2192
+ style: textStyles,
2193
+ ...props,
2194
+ children: [/* @__PURE__ */ jsx(Icon, {
2195
+ size: iconSize,
2196
+ style: iconStyles
2197
+ }), /* @__PURE__ */ jsxs("span", {
2198
+ className: "font-medium",
2199
+ children: [
2200
+ formatValue(value),
2201
+ " ",
2202
+ label
2203
+ ]
2204
+ })]
2205
+ });
2206
+ });
2207
+ StatItemGlass.displayName = "StatItemGlass";
2208
+ var themes$1 = [
2209
+ "light",
2210
+ "aurora",
2211
+ "glass"
2212
+ ];
2213
+ var themeConfig$1 = {
2214
+ light: {
2215
+ label: "Light",
2216
+ icon: Sun
2217
+ },
2218
+ aurora: {
2219
+ label: "Aurora",
2220
+ icon: Moon
2221
+ },
2222
+ glass: {
2223
+ label: "Glass",
2224
+ icon: Palette
2225
+ }
2226
+ };
2227
+ const ThemeToggleGlass = forwardRef(({ onToggle, iconSize = 20, iconOnly = false, className, ...props }, ref) => {
2228
+ const { theme, cycleTheme } = useTheme();
2229
+ const nextTheme = themes$1[(themes$1.indexOf(theme) + 1) % themes$1.length];
2230
+ const NextIcon = themeConfig$1[nextTheme].icon;
2231
+ const nextLabel = themeConfig$1[nextTheme].label;
2232
+ const buttonStyles = {
2233
+ background: "var(--card-subtle-bg)",
2234
+ border: "1px solid var(--card-subtle-border)"
2235
+ };
2236
+ const iconStyles = { color: "var(--text-secondary)" };
2237
+ return /* @__PURE__ */ jsx("button", {
2238
+ ref,
2239
+ type: "button",
2240
+ onClick: onToggle ?? cycleTheme,
2241
+ "aria-label": `Switch to ${nextLabel} theme`,
2242
+ className: cn("p-2.5 rounded-xl transition-all duration-300 hover:scale-105 focus:outline-none focus:ring-2 focus:ring-offset-2", iconOnly && "md:px-4 md:gap-2", className),
2243
+ style: buttonStyles,
2244
+ ...props,
2245
+ children: /* @__PURE__ */ jsxs("div", {
2246
+ className: "flex items-center gap-2",
2247
+ children: [/* @__PURE__ */ jsx(NextIcon, {
2248
+ size: iconSize,
2249
+ style: iconStyles
2250
+ }), !iconOnly && /* @__PURE__ */ jsx("span", {
2251
+ className: "hidden md:inline text-sm font-medium",
2252
+ style: iconStyles,
2253
+ children: nextLabel
2254
+ })]
2255
+ })
2256
+ });
2257
+ });
2258
+ ThemeToggleGlass.displayName = "ThemeToggleGlass";
2259
+ const BaseProgressGlass = forwardRef(({ value = 0, max = 100, className, children, ...props }, ref) => {
2260
+ const percentage = Math.min(100, Math.max(0, value / max * 100));
2261
+ return /* @__PURE__ */ jsx("div", {
2262
+ ref,
2263
+ className: cn("relative h-2 w-full overflow-hidden rounded-full", "bg-white/5 backdrop-blur-sm", className),
2264
+ role: "progressbar",
2265
+ "aria-valuenow": value,
2266
+ "aria-valuemin": 0,
2267
+ "aria-valuemax": max,
2268
+ "aria-valuetext": `${Math.round(percentage)}%`,
2269
+ ...props,
2270
+ children: typeof children === "function" ? children(percentage) : children || /* @__PURE__ */ jsx("div", {
2271
+ className: "h-full transition-all duration-300 ease-out",
2272
+ style: {
2273
+ width: `${percentage}%`,
2274
+ background: "var(--progress-bar-bg, linear-gradient(90deg, #a855f7, #ec4899))"
2275
+ }
2276
+ })
2277
+ });
2278
+ });
2279
+ BaseProgressGlass.displayName = "BaseProgressGlass";
2280
+ var sizeClasses$1 = {
2281
+ normal: "w-2 h-2 md:w-2.5 md:h-2.5",
2282
+ large: "w-3.5 h-3.5 md:w-4 md:h-4"
2283
+ };
2284
+ var statusSymbols = {
2285
+ green: "✓",
2286
+ yellow: "!",
2287
+ red: "✕"
2288
+ };
2289
+ var statusVarMap = {
2290
+ green: {
2291
+ bg: "var(--status-online)",
2292
+ glow: "var(--status-online-glow)"
2293
+ },
2294
+ yellow: {
2295
+ bg: "var(--status-away)",
2296
+ glow: "var(--status-away-glow)"
2297
+ },
2298
+ red: {
2299
+ bg: "var(--status-busy)",
2300
+ glow: "var(--status-busy-glow)"
2301
+ }
2302
+ };
2303
+ const StatusIndicatorGlass = forwardRef(({ type = "green", size = "normal", className, ...props }, ref) => {
2304
+ const colors = statusVarMap[type];
2305
+ const indicatorStyles = {
2306
+ backgroundColor: colors.bg,
2307
+ boxShadow: colors.glow
2308
+ };
2309
+ return /* @__PURE__ */ jsx("div", {
2310
+ ref,
2311
+ className: cn("rounded-full flex items-center justify-center", sizeClasses$1[size], className),
2312
+ style: indicatorStyles,
2313
+ role: "status",
2314
+ "aria-label": `Status: ${type}`,
2315
+ ...props,
2316
+ children: size === "large" && /* @__PURE__ */ jsx("span", {
2317
+ className: "text-white text-[8px] md:text-[10px] font-bold",
2318
+ children: statusSymbols[type]
2319
+ })
2320
+ });
2321
+ });
2322
+ StatusIndicatorGlass.displayName = "StatusIndicatorGlass";
2323
+ var flagVarMap = {
2324
+ danger: {
2325
+ bg: "var(--alert-danger-bg)",
2326
+ border: "var(--alert-danger-border)",
2327
+ text: "var(--alert-danger-text)",
2328
+ statusType: "red"
2329
+ },
2330
+ warning: {
2331
+ bg: "var(--alert-warning-bg)",
2332
+ border: "var(--alert-warning-border)",
2333
+ text: "var(--alert-warning-text)",
2334
+ statusType: "yellow"
2335
+ }
2336
+ };
2337
+ const FlagAlertGlass = forwardRef(({ type = "warning", title, description, className, ...props }, ref) => {
2338
+ const [isHovered, setIsHovered] = useState(false);
2339
+ const config = flagVarMap[type];
2340
+ const alertStyles = {
2341
+ background: config.bg,
2342
+ borderColor: config.border,
2343
+ transform: isHovered ? "translateX(4px)" : "translateX(0)"
2344
+ };
2345
+ return /* @__PURE__ */ jsxs("div", {
2346
+ ref,
2347
+ className: cn("p-2.5 md:p-3 rounded-xl border transition-all duration-300", className),
2348
+ style: alertStyles,
2349
+ onMouseEnter: () => setIsHovered(true),
2350
+ onMouseLeave: () => setIsHovered(false),
2351
+ role: "alert",
2352
+ ...props,
2353
+ children: [/* @__PURE__ */ jsxs("div", {
2354
+ className: "flex items-center gap-1.5 md:gap-2 font-medium text-xs md:text-sm",
2355
+ style: { color: config.text },
2356
+ children: [/* @__PURE__ */ jsx(StatusIndicatorGlass, { type: config.statusType }), title]
2357
+ }), description && /* @__PURE__ */ jsx("p", {
2358
+ className: "text-(length:--font-size-2xs) md:text-xs mt-0.5 md:mt-1 ml-4 md:ml-5 text-(--text-muted)",
2359
+ children: description
2360
+ })]
2361
+ });
2362
+ });
2363
+ FlagAlertGlass.displayName = "FlagAlertGlass";
2364
+ var defaultLangColors = {
2365
+ TypeScript: "var(--language-typescript)",
2366
+ JavaScript: "var(--language-javascript)",
2367
+ Python: "var(--language-python)",
2368
+ HTML: "var(--language-html)",
2369
+ CSS: "var(--language-css)",
2370
+ Java: "var(--language-java)",
2371
+ Go: "var(--language-go)",
2372
+ Rust: "var(--language-rust)",
2373
+ Ruby: "var(--language-ruby)",
2374
+ PHP: "var(--language-php)"
2375
+ };
2376
+ const LanguageBarGlass = forwardRef(({ languages = [], showLegend = true, className, ...props }, ref) => {
2377
+ const [hoveredLang, setHoveredLang] = useState(null);
2378
+ const barStyles = { boxShadow: "var(--rainbow-glow)" };
2379
+ if (!languages || languages.length === 0) return null;
2380
+ return /* @__PURE__ */ jsxs("div", {
2381
+ ref,
2382
+ className: cn("w-full", className),
2383
+ ...props,
2384
+ children: [/* @__PURE__ */ jsx("div", {
2385
+ className: "flex h-2 md:h-2.5 rounded-full overflow-hidden",
2386
+ style: barStyles,
2387
+ role: "group",
2388
+ "aria-label": "Language distribution",
2389
+ children: languages.map((lang, i) => {
2390
+ const bgColor = lang.color ?? defaultLangColors[lang.name] ?? "var(--oklch-slate-400)";
2391
+ return /* @__PURE__ */ jsx("div", {
2392
+ style: {
2393
+ width: `${lang.percent}%`,
2394
+ backgroundColor: bgColor,
2395
+ opacity: hoveredLang !== null && hoveredLang !== i ? .5 : 1,
2396
+ transition: "all 0.3s"
2397
+ },
2398
+ role: "progressbar",
2399
+ "aria-label": `${lang.name}: ${lang.percent}%`,
2400
+ "aria-valuenow": lang.percent,
2401
+ "aria-valuemin": 0,
2402
+ "aria-valuemax": 100,
2403
+ onMouseEnter: () => setHoveredLang(i),
2404
+ onMouseLeave: () => setHoveredLang(null)
2405
+ }, `bar-${lang.name}-${i}`);
2406
+ })
2407
+ }), showLegend && /* @__PURE__ */ jsx("div", {
2408
+ className: "flex items-center gap-3 md:gap-4 mt-1.5 md:mt-2 text-(length:--font-size-2xs) md:text-xs flex-wrap text-(--text-secondary)",
2409
+ children: languages.map((lang, i) => {
2410
+ return /* @__PURE__ */ jsxs("span", {
2411
+ className: "flex items-center gap-1 md:gap-1.5 cursor-pointer",
2412
+ onMouseEnter: () => setHoveredLang(i),
2413
+ onMouseLeave: () => setHoveredLang(null),
2414
+ children: [
2415
+ /* @__PURE__ */ jsx("span", {
2416
+ className: "w-2 h-2 md:w-2.5 md:h-2.5 rounded-full",
2417
+ style: { backgroundColor: lang.color ?? defaultLangColors[lang.name] ?? "var(--oklch-slate-400)" }
2418
+ }),
2419
+ lang.name,
2420
+ " ",
2421
+ lang.percent,
2422
+ "%"
2423
+ ]
2424
+ }, `legend-${lang.name}-${i}`);
2425
+ })
2426
+ })]
2427
+ });
2428
+ });
2429
+ LanguageBarGlass.displayName = "LanguageBarGlass";
2430
+ var profileSizeClasses = {
2431
+ sm: "w-9 h-9 md:w-10 md:h-10 text-xs md:text-sm",
2432
+ md: "w-12 h-12 md:w-14 md:h-14 text-base md:text-lg",
2433
+ lg: "w-14 h-14 md:w-16 md:h-16 text-lg md:text-xl",
2434
+ xl: "w-18 h-18 md:w-20 md:h-20 text-xl md:text-2xl"
2435
+ };
2436
+ var getStatusVars = (statusType) => {
2437
+ return {
2438
+ online: {
2439
+ bg: "var(--status-online)",
2440
+ glow: "var(--status-online-glow)"
2441
+ },
2442
+ offline: {
2443
+ bg: "var(--status-offline)",
2444
+ glow: "none"
2445
+ },
2446
+ busy: {
2447
+ bg: "var(--status-busy)",
2448
+ glow: "var(--status-busy-glow)"
2449
+ },
2450
+ away: {
2451
+ bg: "var(--status-away)",
2452
+ glow: "var(--status-away-glow)"
2453
+ }
2454
+ }[statusType];
2455
+ };
2456
+ const ProfileAvatarGlass = forwardRef(({ initials, size = "lg", status, glowing = true, className, ...props }, ref) => {
2457
+ const { isHovered, hoverProps } = useHover();
2458
+ const avatarStyles = {
2459
+ background: "var(--avatar-bg)",
2460
+ border: "3px solid var(--avatar-border)",
2461
+ boxShadow: isHovered ? "var(--avatar-hover-glow)" : "var(--avatar-shadow)",
2462
+ color: "var(--text-inverse)"
2463
+ };
2464
+ return /* @__PURE__ */ jsxs("div", {
2465
+ ref,
2466
+ className: cn("relative inline-flex", className),
2467
+ onMouseEnter: hoverProps.onMouseEnter,
2468
+ onMouseLeave: hoverProps.onMouseLeave,
2469
+ ...props,
2470
+ children: [/* @__PURE__ */ jsx("div", {
2471
+ className: cn("rounded-full flex items-center justify-center font-bold transition-all duration-300", profileSizeClasses[size], glowing && "animate-[glow-pulse_2s_ease-in-out_infinite]"),
2472
+ style: avatarStyles,
2473
+ role: "img",
2474
+ "aria-label": `Profile avatar with initials ${initials}`,
2475
+ children: initials
2476
+ }), status && /* @__PURE__ */ jsx("span", {
2477
+ className: cn(statusSizes({ size }), "absolute -bottom-0.5 -right-0.5"),
2478
+ style: {
2479
+ background: getStatusVars(status).bg,
2480
+ boxShadow: getStatusVars(status).glow
2481
+ },
2482
+ role: "status",
2483
+ "aria-label": `Status: ${status}`
2484
+ })]
2485
+ });
2486
+ });
2487
+ ProfileAvatarGlass.displayName = "ProfileAvatarGlass";
2488
+ const progressSizes = cva("rounded-full overflow-hidden", {
2489
+ variants: { size: {
2490
+ sm: "h-1.5 md:h-1",
2491
+ md: "h-2.5 md:h-2",
2492
+ lg: "h-3.5 md:h-3",
2493
+ xl: "h-5 md:h-4"
2494
+ } },
2495
+ defaultVariants: { size: "md" }
2496
+ });
2497
+ var getGradientColor = (gradient = "violet") => {
2498
+ const gradients = {
2499
+ violet: {
2500
+ colorVar: "--metric-default-text",
2501
+ glowVar: "--progress-glow-violet"
2502
+ },
2503
+ blue: {
2504
+ colorVar: "--metric-default-text",
2505
+ glowVar: "--progress-glow-blue"
2506
+ },
2507
+ cyan: {
2508
+ colorVar: "--metric-secondary-text",
2509
+ glowVar: "--progress-glow-cyan"
2510
+ },
2511
+ amber: {
2512
+ colorVar: "--metric-warning-text",
2513
+ glowVar: "--progress-glow-amber"
2514
+ },
2515
+ emerald: {
2516
+ colorVar: "--metric-success-text",
2517
+ glowVar: "--progress-glow-emerald"
2518
+ },
2519
+ rose: {
2520
+ colorVar: "--metric-destructive-text",
2521
+ glowVar: "--progress-glow-rose"
2522
+ }
2523
+ };
2524
+ return gradients[gradient] || gradients.violet;
2525
+ };
2526
+ const ProgressGlass = forwardRef(({ className, size = "md", value = 0, gradient = "violet", showLabel, ...props }, ref) => {
2527
+ const clampedValue = Math.min(100, Math.max(0, value));
2528
+ const { colorVar, glowVar } = getGradientColor(gradient);
2529
+ const trackStyles = { background: "var(--progress-bg)" };
2530
+ const fillStyles = {
2531
+ width: `${clampedValue}%`,
2532
+ background: `var(${colorVar})`,
2533
+ boxShadow: `var(${glowVar})`
2534
+ };
2535
+ return /* @__PURE__ */ jsxs("div", {
2536
+ ref,
2537
+ className: cn("w-full", className),
2538
+ ...props,
2539
+ children: [showLabel && /* @__PURE__ */ jsxs("div", {
2540
+ className: "flex justify-between mb-1 md:mb-1.5",
2541
+ children: [/* @__PURE__ */ jsx("span", {
2542
+ className: "text-(length:--font-size-2xs) md:text-xs text-(--text-muted)",
2543
+ children: "Progress"
2544
+ }), /* @__PURE__ */ jsxs("span", {
2545
+ className: "text-(length:--font-size-2xs) md:text-xs font-medium text-(--text-secondary)",
2546
+ children: [clampedValue, "%"]
2547
+ })]
2548
+ }), /* @__PURE__ */ jsx("div", {
2549
+ className: cn(progressSizes({ size })),
2550
+ style: trackStyles,
2551
+ children: /* @__PURE__ */ jsx("div", {
2552
+ className: "h-full rounded-full transition-all duration-700 ease-out",
2553
+ style: fillStyles,
2554
+ role: "progressbar",
2555
+ "aria-valuenow": clampedValue,
2556
+ "aria-valuemin": 0,
2557
+ "aria-valuemax": 100,
2558
+ "aria-label": `Progress: ${clampedValue}%`
2559
+ })
2560
+ })]
2561
+ });
2562
+ });
2563
+ ProgressGlass.displayName = "ProgressGlass";
2564
+ var sizeClasses = {
2565
+ sm: "h-2.5 md:h-2",
2566
+ md: "h-3.5 md:h-3",
2567
+ lg: "h-[1.125rem] md:h-4",
2568
+ xl: "h-6 md:h-5"
2569
+ };
2570
+ const RainbowProgressGlass = forwardRef(({ value, size = "lg", showGlow = true, className, ...props }, ref) => {
2571
+ const clampedValue = Math.min(100, Math.max(0, value));
2572
+ const trackStyles = { background: "var(--progress-bg)" };
2573
+ const fillStyles = {
2574
+ width: `${clampedValue}%`,
2575
+ background: "var(--rainbow-gradient)",
2576
+ boxShadow: showGlow ? "var(--rainbow-glow)" : "none",
2577
+ animation: showGlow ? "var(--rainbow-animation)" : "none"
2578
+ };
2579
+ return /* @__PURE__ */ jsx("div", {
2580
+ ref,
2581
+ className: cn("rounded-full overflow-hidden", sizeClasses[size], className),
2582
+ style: trackStyles,
2583
+ role: "progressbar",
2584
+ "aria-valuenow": clampedValue,
2585
+ "aria-valuemin": 0,
2586
+ "aria-valuemax": 100,
2587
+ "aria-label": `Rainbow progress: ${clampedValue}%`,
2588
+ ...props,
2589
+ children: /* @__PURE__ */ jsx("div", {
2590
+ className: "h-full rounded-full transition-all duration-1000",
2591
+ style: fillStyles
2592
+ })
2593
+ });
2594
+ });
2595
+ RainbowProgressGlass.displayName = "RainbowProgressGlass";
2596
+ const SegmentedControlGlass = forwardRef(({ options = [], value, onChange, className, ...props }, ref) => {
2597
+ const containerStyles = {
2598
+ border: "1px solid var(--segmented-container-border)",
2599
+ background: "var(--segmented-container-bg)"
2600
+ };
2601
+ if (!options || options.length === 0) return null;
2602
+ return /* @__PURE__ */ jsx("div", {
2603
+ ref,
2604
+ className: cn("inline-flex rounded-xl overflow-hidden", className),
2605
+ style: containerStyles,
2606
+ role: "tablist",
2607
+ ...props,
2608
+ children: options.map((opt) => {
2609
+ const isActive = value === opt.value;
2610
+ return /* @__PURE__ */ jsx("button", {
2611
+ onClick: () => onChange?.(opt.value),
2612
+ className: "px-3 py-1.5 md:px-4 md:py-2 text-xs md:text-sm font-medium transition-all duration-300",
2613
+ style: {
2614
+ background: isActive ? "var(--segmented-active-bg)" : "transparent",
2615
+ color: isActive ? "var(--segmented-active-text)" : "var(--segmented-inactive-text)"
2616
+ },
2617
+ type: "button",
2618
+ role: "tab",
2619
+ "aria-selected": isActive,
2620
+ children: opt.label
2621
+ }, opt.value);
2622
+ })
2623
+ });
2624
+ });
2625
+ SegmentedControlGlass.displayName = "SegmentedControlGlass";
2626
+ const sparklineContainerVariants = cva("flex items-end", {
2627
+ variants: {
2628
+ height: {
2629
+ sm: "h-4",
2630
+ md: "h-6",
2631
+ lg: "h-8"
2632
+ },
2633
+ gap: {
2634
+ none: "gap-0",
2635
+ sm: "gap-px",
2636
+ md: "gap-0.5"
2637
+ }
2638
+ },
2639
+ defaultVariants: {
2640
+ height: "md",
2641
+ gap: "sm"
2642
+ }
2643
+ });
2644
+ const sparklineBarVariants = cva("flex-1 rounded-sm transition-all duration-300", {
2645
+ variants: { animated: {
2646
+ true: "animate-sparkline-grow",
2647
+ false: ""
2648
+ } },
2649
+ defaultVariants: { animated: false }
2650
+ });
2651
+ var defaultSparklineConfig = {
2652
+ value: {
2653
+ label: "Value",
2654
+ color: "var(--sparkline-bar-fill, hsl(var(--chart-1-base)))"
2655
+ },
2656
+ max: {
2657
+ label: "Maximum",
2658
+ color: "var(--sparkline-bar-max, var(--alert-success-text))"
2659
+ }
2660
+ };
2661
+ var heightMap = {
2662
+ sm: 16,
2663
+ md: 24,
2664
+ lg: 32
2665
+ };
2666
+ var SparklineTooltip = ({ active, payload, valueFormatter }) => {
2667
+ if (!active || !payload?.length) return null;
2668
+ const data = payload[0];
2669
+ const value = data.value;
2670
+ const index = data.payload.index;
2671
+ const label = data.payload.label;
2672
+ const displayValue = valueFormatter ? valueFormatter(value, index) : value.toLocaleString();
2673
+ return /* @__PURE__ */ jsxs("div", {
2674
+ className: "rounded-md border border-[var(--glass-border)] bg-[var(--glass-bg)] px-2 py-1 text-xs shadow-lg backdrop-blur-md",
2675
+ children: [label && /* @__PURE__ */ jsx("div", {
2676
+ className: "font-medium text-[var(--text-primary)]",
2677
+ children: label
2678
+ }), /* @__PURE__ */ jsx("div", {
2679
+ className: "text-[var(--text-secondary)]",
2680
+ children: displayValue
2681
+ })]
2682
+ });
2683
+ };
2684
+ const SparklineGlass = forwardRef(({ data, labels, showLabels = false, highlightMax = false, barColor, maxBarColor, tooltips, height = "md", gap = "sm", animated = false, minBarHeightPercent = 4, config = defaultSparklineConfig, valueFormatter, onBarClick, showTooltip = true, className, ...props }, ref) => {
2685
+ const chartData = useMemo(() => {
2686
+ const maxValue$1 = Math.max(...data, 0);
2687
+ const maxIndex$1 = data.indexOf(maxValue$1);
2688
+ return data.map((value, index) => ({
2689
+ index,
2690
+ value,
2691
+ label: labels?.[index] || tooltips?.[index],
2692
+ isMax: highlightMax && index === maxIndex$1 && value > 0,
2693
+ displayValue: maxValue$1 > 0 ? Math.max(value, maxValue$1 * (minBarHeightPercent / 100)) : minBarHeightPercent
2694
+ }));
2695
+ }, [
2696
+ data,
2697
+ labels,
2698
+ tooltips,
2699
+ highlightMax,
2700
+ minBarHeightPercent
2701
+ ]);
2702
+ const { maxValue, maxIndex } = useMemo(() => {
2703
+ const max = Math.max(...data, 0);
2704
+ return {
2705
+ maxValue: max,
2706
+ maxIndex: data.indexOf(max)
2707
+ };
2708
+ }, [data]);
2709
+ const ariaLabel = useMemo(() => {
2710
+ if (data.length === 0) return "Empty sparkline chart";
2711
+ return `Sparkline chart with ${data.length} data points, maximum value ${maxValue}${labels ? ` at ${labels[maxIndex] || `position ${maxIndex + 1}`}` : ""}`;
2712
+ }, [
2713
+ data.length,
2714
+ maxValue,
2715
+ maxIndex,
2716
+ labels
2717
+ ]);
2718
+ const resolvedBarColor = barColor || config.value?.color || "var(--sparkline-bar-fill)";
2719
+ const resolvedMaxColor = maxBarColor || config.max?.color || "var(--sparkline-bar-max)";
2720
+ const barGap = {
2721
+ none: 0,
2722
+ sm: 1,
2723
+ md: 2
2724
+ }[gap || "sm"];
2725
+ const chartHeight = heightMap[height || "md"];
2726
+ const handleClick = (dataPoint) => {
2727
+ if (onBarClick) onBarClick(dataPoint.value, dataPoint.index);
2728
+ };
2729
+ return /* @__PURE__ */ jsxs("div", {
2730
+ ref,
2731
+ role: "img",
2732
+ "aria-label": ariaLabel,
2733
+ className: cn("flex flex-col", className),
2734
+ ...props,
2735
+ children: [/* @__PURE__ */ jsx("div", {
2736
+ className: cn(sparklineContainerVariants({
2737
+ height,
2738
+ gap
2739
+ })),
2740
+ "data-chart": "sparkline",
2741
+ style: {
2742
+ "--color-value": resolvedBarColor,
2743
+ "--color-max": resolvedMaxColor
2744
+ },
2745
+ children: /* @__PURE__ */ jsx(ResponsiveContainer, {
2746
+ width: "100%",
2747
+ height: chartHeight,
2748
+ children: /* @__PURE__ */ jsxs(BarChart, {
2749
+ data: chartData,
2750
+ margin: {
2751
+ top: 0,
2752
+ right: 0,
2753
+ bottom: 0,
2754
+ left: 0
2755
+ },
2756
+ barGap,
2757
+ children: [showTooltip && /* @__PURE__ */ jsx(Tooltip, {
2758
+ content: /* @__PURE__ */ jsx(SparklineTooltip, { valueFormatter }),
2759
+ cursor: false,
2760
+ isAnimationActive: false
2761
+ }), /* @__PURE__ */ jsx(Bar, {
2762
+ dataKey: "displayValue",
2763
+ radius: [
2764
+ 2,
2765
+ 2,
2766
+ 0,
2767
+ 0
2768
+ ],
2769
+ isAnimationActive: animated,
2770
+ animationDuration: 500,
2771
+ animationEasing: "ease-out",
2772
+ onClick: (_, index) => handleClick(chartData[index]),
2773
+ style: { cursor: onBarClick ? "pointer" : "default" },
2774
+ children: chartData.map((entry, index) => /* @__PURE__ */ jsx(Cell, {
2775
+ fill: entry.isMax ? resolvedMaxColor : resolvedBarColor,
2776
+ className: "transition-colors duration-200 hover:opacity-80"
2777
+ }, `cell-${index}`))
2778
+ })]
2779
+ })
2780
+ })
2781
+ }), showLabels && labels && labels.length > 0 && /* @__PURE__ */ jsx("div", {
2782
+ className: "flex mt-1",
2783
+ "aria-hidden": "true",
2784
+ children: labels.map((label, index) => /* @__PURE__ */ jsx("span", {
2785
+ className: cn("flex-1 text-center leading-none truncate text-xs", "text-(--text-muted)"),
2786
+ children: label
2787
+ }, index))
2788
+ })]
2789
+ });
2790
+ });
2791
+ SparklineGlass.displayName = "SparklineGlass";
2792
+ var defaultFeatures = [
2793
+ "Code quality assessment",
2794
+ "Architecture patterns",
2795
+ "Best practices"
2796
+ ];
2797
+ const AICardGlass = forwardRef(({ onGenerate, features = defaultFeatures, estimatedTime = "~30 seconds", className, ...props }, ref) => {
2798
+ return /* @__PURE__ */ jsxs(InteractiveCard, {
2799
+ ref,
2800
+ baseBg: "var(--ai-card-bg)",
2801
+ borderColor: "var(--ai-card-border)",
2802
+ hoverGlow: "var(--ai-card-hover-glow)",
2803
+ hoverLift: true,
2804
+ blur: "sm",
2805
+ rounded: "rounded-xl",
2806
+ className: cn("w-full sm:w-56 md:w-64 p-3 md:p-4", className),
2807
+ ...props,
2808
+ children: [
2809
+ /* @__PURE__ */ jsxs("div", {
2810
+ className: "flex items-center gap-1.5 md:gap-2 font-semibold text-xs md:text-sm mb-1.5 md:mb-2",
2811
+ style: { color: "var(--text-accent)" },
2812
+ children: [/* @__PURE__ */ jsx(Sparkles, { className: "w-3.5 h-3.5 md:w-4 md:h-4" }), "AI Summary"]
2813
+ }),
2814
+ /* @__PURE__ */ jsx("p", {
2815
+ className: "text-(length:--font-size-2xs) md:text-xs mb-1.5 md:mb-2 text-(--text-secondary)",
2816
+ children: "Get comprehensive analysis:"
2817
+ }),
2818
+ /* @__PURE__ */ jsx("ul", {
2819
+ className: "text-(length:--font-size-2xs) md:text-xs space-y-0.5 md:space-y-1 mb-2 md:mb-3",
2820
+ children: features.map((feature, i) => /* @__PURE__ */ jsxs("li", {
2821
+ className: "flex items-center gap-1",
2822
+ style: { color: "var(--text-muted)" },
2823
+ children: [/* @__PURE__ */ jsx(Check, {
2824
+ className: "w-2.5 h-2.5 md:w-3 md:h-3",
2825
+ style: { color: "var(--status-online)" }
2826
+ }), feature]
2827
+ }, `feature-${i}`))
2828
+ }),
2829
+ /* @__PURE__ */ jsx(ButtonGlass, {
2830
+ variant: "default",
2831
+ size: "sm",
2832
+ icon: Zap,
2833
+ onClick: onGenerate,
2834
+ className: "w-full",
2835
+ children: "Generate Report"
2836
+ }),
2837
+ /* @__PURE__ */ jsxs("p", {
2838
+ className: "text-(length:--font-size-2xs) md:text-xs mt-1.5 md:mt-2 text-center flex items-center justify-center gap-1 text-(--text-muted)",
2839
+ children: [/* @__PURE__ */ jsx(Clock, { className: "w-2.5 h-2.5 md:w-3 md:h-3" }), estimatedTime]
2840
+ })
2841
+ ]
2842
+ });
2843
+ });
2844
+ AICardGlass.displayName = "AICardGlass";
2845
+ const CareerStatsHeaderGlass = forwardRef(({ totalCommits, totalPRs, totalRepos, title = "Career Stats", wrapStats = true, className, ...props }, ref) => {
2846
+ const titleStyles = { color: "var(--text-primary)" };
2847
+ const accentStyles = { color: "var(--text-accent)" };
2848
+ const statsStyles = { color: "var(--text-secondary)" };
2849
+ return /* @__PURE__ */ jsxs("div", {
2850
+ ref,
2851
+ className: cn("mb-4", className),
2852
+ ...props,
2853
+ children: [/* @__PURE__ */ jsxs("h3", {
2854
+ className: "font-semibold flex items-center gap-2 mb-1",
2855
+ style: titleStyles,
2856
+ children: [/* @__PURE__ */ jsx(TrendingUp, {
2857
+ className: "w-5 h-5",
2858
+ style: accentStyles
2859
+ }), title]
2860
+ }), /* @__PURE__ */ jsxs("p", {
2861
+ className: cn("text-sm flex items-center gap-2", wrapStats && "flex-wrap"),
2862
+ style: statsStyles,
2863
+ children: [
2864
+ /* @__PURE__ */ jsxs("span", {
2865
+ className: "flex items-center gap-1",
2866
+ children: [
2867
+ /* @__PURE__ */ jsx(Code, { className: "w-4 h-4" }),
2868
+ totalCommits.toLocaleString(),
2869
+ " commits"
2870
+ ]
2871
+ }),
2872
+ /* @__PURE__ */ jsx("span", { children: "·" }),
2873
+ /* @__PURE__ */ jsxs("span", {
2874
+ className: "flex items-center gap-1",
2875
+ children: [
2876
+ /* @__PURE__ */ jsx(GitPullRequest, { className: "w-4 h-4" }),
2877
+ totalPRs,
2878
+ " PRs"
2879
+ ]
2880
+ }),
2881
+ /* @__PURE__ */ jsx("span", { children: "·" }),
2882
+ /* @__PURE__ */ jsxs("span", {
2883
+ className: "flex items-center gap-1",
2884
+ children: [
2885
+ /* @__PURE__ */ jsx(FolderGit2, { className: "w-4 h-4" }),
2886
+ totalRepos,
2887
+ " repos"
2888
+ ]
2889
+ })
2890
+ ]
2891
+ })]
2892
+ });
2893
+ });
2894
+ CareerStatsHeaderGlass.displayName = "CareerStatsHeaderGlass";
2895
+ var colorMap = {
2896
+ emerald: {
2897
+ gradient: "emerald",
2898
+ textVar: "var(--metric-success-text)"
2899
+ },
2900
+ amber: {
2901
+ gradient: "amber",
2902
+ textVar: "var(--metric-warning-text)"
2903
+ },
2904
+ blue: {
2905
+ gradient: "blue",
2906
+ textVar: "var(--metric-default-text)"
2907
+ },
2908
+ red: {
2909
+ gradient: "rose",
2910
+ textVar: "var(--metric-destructive-text)"
2911
+ }
2912
+ };
2913
+ const CircularMetricGlass = forwardRef(({ label, value, color = "blue", size = "sm", className, ...props }, ref) => {
2914
+ const { gradient, textVar } = colorMap[color];
2915
+ return /* @__PURE__ */ jsxs("div", {
2916
+ ref,
2917
+ className: cn("flex flex-col items-center gap-1", className),
2918
+ ...props,
2919
+ children: [/* @__PURE__ */ jsx(CircularProgressGlass, {
2920
+ value,
2921
+ size,
2922
+ color: gradient,
2923
+ labelColor: textVar,
2924
+ thickness: size === "sm" ? 6 : 8,
2925
+ showGlow: true,
2926
+ glowIntensity: "medium"
2927
+ }), /* @__PURE__ */ jsx("span", {
2928
+ className: "text-xs font-medium",
2929
+ style: { color: textVar },
2930
+ children: label
2931
+ })]
2932
+ });
2933
+ });
2934
+ CircularMetricGlass.displayName = "CircularMetricGlass";
2935
+ const ContributionMetricsGlass = forwardRef(({ userCommits, userContribution, totalProjectCommits: providedTotal, estimatedLines: providedLines, columns = 2, className, ...props }, ref) => {
2936
+ const totalProjectCommits = providedTotal ?? (userContribution > 0 ? Math.round(userCommits / (userContribution / 100)) : userCommits);
2937
+ const estimatedLines = providedLines ?? Math.round(userCommits * 12);
2938
+ const cardStyles = {
2939
+ background: "var(--card-bg)",
2940
+ borderColor: "var(--card-border)"
2941
+ };
2942
+ const mutedStyles = { color: "var(--text-muted)" };
2943
+ const primaryStyles = { color: "var(--text-primary)" };
2944
+ return /* @__PURE__ */ jsxs("div", {
2945
+ ref,
2946
+ className: cn("grid gap-2", {
2947
+ 1: "grid-cols-1",
2948
+ 2: "grid-cols-1 sm:grid-cols-2"
2949
+ }[columns], className),
2950
+ ...props,
2951
+ children: [/* @__PURE__ */ jsxs("div", {
2952
+ className: "p-2.5 rounded-lg border",
2953
+ style: cardStyles,
2954
+ children: [
2955
+ /* @__PURE__ */ jsx("div", {
2956
+ className: "text-xs",
2957
+ style: mutedStyles,
2958
+ children: "Your Contribution"
2959
+ }),
2960
+ /* @__PURE__ */ jsxs("div", {
2961
+ className: "font-semibold",
2962
+ style: primaryStyles,
2963
+ children: [userCommits.toLocaleString(), " commits"]
2964
+ }),
2965
+ /* @__PURE__ */ jsxs("div", {
2966
+ className: "text-xs",
2967
+ style: mutedStyles,
2968
+ children: [userContribution, "%"]
2969
+ })
2970
+ ]
2971
+ }), /* @__PURE__ */ jsxs("div", {
2972
+ className: "p-2.5 rounded-lg border",
2973
+ style: cardStyles,
2974
+ children: [
2975
+ /* @__PURE__ */ jsx("div", {
2976
+ className: "text-xs",
2977
+ style: mutedStyles,
2978
+ children: "Full Project"
2979
+ }),
2980
+ /* @__PURE__ */ jsxs("div", {
2981
+ className: "font-semibold",
2982
+ style: primaryStyles,
2983
+ children: [totalProjectCommits.toLocaleString(), " commits"]
2984
+ }),
2985
+ /* @__PURE__ */ jsxs("div", {
2986
+ className: "text-xs",
2987
+ style: mutedStyles,
2988
+ children: [
2989
+ "~",
2990
+ estimatedLines.toLocaleString(),
2991
+ " lines"
2992
+ ]
2993
+ })
2994
+ ]
2995
+ })]
2996
+ });
2997
+ });
2998
+ ContributionMetricsGlass.displayName = "ContributionMetricsGlass";
2999
+ var variantStyles = {
3000
+ default: {
3001
+ bg: "var(--metric-default-bg)",
3002
+ text: "var(--metric-default-text)",
3003
+ border: "var(--metric-default-border)",
3004
+ glow: "var(--metric-default-glow)"
3005
+ },
3006
+ secondary: {
3007
+ bg: "var(--metric-secondary-bg)",
3008
+ text: "var(--metric-secondary-text)",
3009
+ border: "var(--metric-secondary-border)",
3010
+ glow: "var(--metric-secondary-glow)"
3011
+ },
3012
+ success: {
3013
+ bg: "var(--metric-success-bg)",
3014
+ text: "var(--metric-success-text)",
3015
+ border: "var(--metric-success-border)",
3016
+ glow: "var(--metric-success-glow)"
3017
+ },
3018
+ warning: {
3019
+ bg: "var(--metric-warning-bg)",
3020
+ text: "var(--metric-warning-text)",
3021
+ border: "var(--metric-warning-border)",
3022
+ glow: "var(--metric-warning-glow)"
3023
+ },
3024
+ destructive: {
3025
+ bg: "var(--metric-destructive-bg)",
3026
+ text: "var(--metric-destructive-text)",
3027
+ border: "var(--metric-destructive-border)",
3028
+ glow: "var(--metric-destructive-glow)"
3029
+ }
3030
+ };
3031
+ var variantToGradient = {
3032
+ default: "blue",
3033
+ secondary: "cyan",
3034
+ success: "emerald",
3035
+ warning: "amber",
3036
+ destructive: "rose"
3037
+ };
3038
+ var colorToVariant = {
3039
+ emerald: "success",
3040
+ amber: "warning",
3041
+ blue: "default",
3042
+ red: "destructive"
3043
+ };
3044
+ var trendColors = {
3045
+ up: "text-[var(--alert-success-text)]",
3046
+ down: "text-[var(--alert-destructive-text)]",
3047
+ neutral: "text-[var(--text-muted)]"
3048
+ };
3049
+ var TrendIcons = {
3050
+ up: TrendingUp,
3051
+ down: TrendingDown,
3052
+ neutral: Minus
3053
+ };
3054
+ const MetricCardGlass = forwardRef(({ title, value, description, change, variant, progress, label, color, valueFormatter, valueSuffix, trend, icon, sparklineData, showSparkline = true, showProgress = true, className, ...props }, ref) => {
3055
+ const actualTitle = title || label;
3056
+ if (!actualTitle) console.warn("[MetricCardGlass] Missing required prop: `title` (or deprecated `label`)");
3057
+ if (label && !title) console.warn("[MetricCardGlass] Deprecated prop `label` used. Please use `title` instead. Will be removed in v2.0");
3058
+ const actualVariant = variant || (color ? colorToVariant[color] : "default");
3059
+ if (color && !variant) console.warn(`[MetricCardGlass] Deprecated prop \`color="${color}"\` used. Please use \`variant="${colorToVariant[color]}"\` instead. Will be removed in v2.0`);
3060
+ const actualDescription = description || valueSuffix;
3061
+ if (valueSuffix && !description) console.warn("[MetricCardGlass] Deprecated prop `valueSuffix` used. Please use `description` instead. Will be removed in v2.0");
3062
+ const actualChange = change || (trend ? {
3063
+ value: trend.value,
3064
+ direction: trend.direction,
3065
+ period: trend.label
3066
+ } : void 0);
3067
+ if (trend && !change) console.warn("[MetricCardGlass] Deprecated prop `trend` used. Please use `change` instead. Will be removed in v2.0");
3068
+ const displayValue = typeof value === "number" && valueFormatter ? valueFormatter(value) : String(value);
3069
+ if (valueFormatter) console.warn("[MetricCardGlass] Deprecated prop `valueFormatter` used. Please format value before passing. Will be removed in v2.0");
3070
+ const actualProgress = progress ?? (typeof value === "number" && value >= 0 && value <= 100 ? value : void 0);
3071
+ const variantVars = variantStyles[actualVariant];
3072
+ const hasSparkline = showSparkline && sparklineData && sparklineData.length > 0;
3073
+ const valueStyles = {
3074
+ color: variantVars.text,
3075
+ textShadow: variantVars.glow
3076
+ };
3077
+ const renderChange = () => {
3078
+ if (!actualChange) return null;
3079
+ if (typeof actualChange === "string" || typeof actualChange === "number") {
3080
+ const changeStr = String(actualChange);
3081
+ const isPositive = changeStr.startsWith("+") || !changeStr.startsWith("-") && parseFloat(changeStr) > 0;
3082
+ const isNegative = changeStr.startsWith("-") || parseFloat(changeStr) < 0;
3083
+ const direction$1 = isPositive ? "up" : isNegative ? "down" : "neutral";
3084
+ const TrendIcon$1 = TrendIcons[direction$1];
3085
+ return /* @__PURE__ */ jsxs("div", {
3086
+ className: cn("flex items-center gap-1 text-xs", trendColors[direction$1]),
3087
+ children: [/* @__PURE__ */ jsx(TrendIcon$1, {
3088
+ className: "w-3 h-3",
3089
+ "aria-hidden": "true"
3090
+ }), /* @__PURE__ */ jsx("span", {
3091
+ className: "font-medium",
3092
+ children: changeStr
3093
+ })]
3094
+ });
3095
+ }
3096
+ const changeValue = actualChange.value;
3097
+ const direction = actualChange.direction || (changeValue > 0 ? "up" : changeValue < 0 ? "down" : "neutral");
3098
+ const TrendIcon = TrendIcons[direction];
3099
+ const displayChange = direction === "down" ? `-${Math.abs(changeValue)}` : `+${changeValue}`;
3100
+ return /* @__PURE__ */ jsxs("div", {
3101
+ className: cn("flex items-center gap-1 text-xs", trendColors[direction]),
3102
+ children: [
3103
+ /* @__PURE__ */ jsx(TrendIcon, {
3104
+ className: "w-3 h-3",
3105
+ "aria-hidden": "true"
3106
+ }),
3107
+ /* @__PURE__ */ jsxs("span", {
3108
+ className: "font-medium",
3109
+ children: [displayChange, "%"]
3110
+ }),
3111
+ actualChange.period && /* @__PURE__ */ jsx("span", {
3112
+ className: "text-[var(--text-muted)] ml-0.5",
3113
+ children: actualChange.period
3114
+ })
3115
+ ]
3116
+ });
3117
+ };
3118
+ return /* @__PURE__ */ jsxs(InteractiveCard, {
3119
+ ref,
3120
+ baseBg: variantVars.bg,
3121
+ borderColor: variantVars.border,
3122
+ hoverGlow: variantVars.glow,
3123
+ hoverLift: true,
3124
+ blur: "sm",
3125
+ rounded: "rounded-xl",
3126
+ className: cn("p-3 md:p-4", className),
3127
+ ...props,
3128
+ children: [
3129
+ /* @__PURE__ */ jsxs("div", {
3130
+ className: "flex items-start justify-between mb-2",
3131
+ children: [/* @__PURE__ */ jsxs("div", {
3132
+ className: "flex items-center gap-2",
3133
+ children: [icon && /* @__PURE__ */ jsx("div", {
3134
+ className: "text-(--text-muted)",
3135
+ "aria-hidden": "true",
3136
+ children: icon
3137
+ }), /* @__PURE__ */ jsx("span", {
3138
+ className: "text-(length:--font-size-2xs) sm:text-xs md:text-sm font-medium truncate text-(--text-secondary)",
3139
+ children: actualTitle
3140
+ })]
3141
+ }), renderChange()]
3142
+ }),
3143
+ /* @__PURE__ */ jsxs("div", {
3144
+ className: "flex flex-col items-center mb-2 md:mb-3 gap-1",
3145
+ children: [/* @__PURE__ */ jsx("span", {
3146
+ className: "font-bold text-lg sm:text-xl md:text-2xl whitespace-nowrap",
3147
+ style: valueStyles,
3148
+ children: displayValue
3149
+ }), actualDescription && /* @__PURE__ */ jsx("span", {
3150
+ className: "text-(length:--font-size-2xs) text-(--text-muted)",
3151
+ children: actualDescription
3152
+ })]
3153
+ }),
3154
+ hasSparkline ? /* @__PURE__ */ jsxs("div", {
3155
+ className: "space-y-2",
3156
+ children: [showProgress && actualProgress !== void 0 && /* @__PURE__ */ jsx(ProgressGlass, {
3157
+ value: actualProgress,
3158
+ gradient: variantToGradient[actualVariant],
3159
+ size: "sm"
3160
+ }), /* @__PURE__ */ jsx(SparklineGlass, {
3161
+ data: sparklineData,
3162
+ height: "sm",
3163
+ gap: "sm",
3164
+ className: "w-full",
3165
+ barColor: variantVars.text,
3166
+ highlightMax: true,
3167
+ "aria-label": `${actualTitle} trend`
3168
+ })]
3169
+ }) : showProgress && actualProgress !== void 0 ? /* @__PURE__ */ jsx(ProgressGlass, {
3170
+ value: actualProgress,
3171
+ gradient: variantToGradient[actualVariant],
3172
+ size: "sm"
3173
+ }) : null
3174
+ ]
3175
+ });
3176
+ });
3177
+ MetricCardGlass.displayName = "MetricCardGlass";
3178
+ const MetricsGridGlass = forwardRef(({ metrics, columns = 4, gap = "md", className, ...props }, ref) => {
3179
+ const gapClasses = {
3180
+ sm: "gap-2",
3181
+ md: "gap-4",
3182
+ lg: "gap-6"
3183
+ };
3184
+ const columnClasses = {
3185
+ 1: "grid-cols-1",
3186
+ 2: "grid-cols-1 sm:grid-cols-2",
3187
+ 3: "grid-cols-1 sm:grid-cols-2 md:grid-cols-3",
3188
+ 4: "grid-cols-2 sm:grid-cols-3 md:grid-cols-4",
3189
+ 5: "grid-cols-2 sm:grid-cols-3 md:grid-cols-5",
3190
+ 6: "grid-cols-2 sm:grid-cols-3 md:grid-cols-6"
3191
+ };
3192
+ if (metrics.length === 0) return null;
3193
+ return /* @__PURE__ */ jsx("div", {
3194
+ ref,
3195
+ className: cn("grid", columnClasses[columns], gapClasses[gap], className),
3196
+ ...props,
3197
+ children: metrics.map((metric) => /* @__PURE__ */ jsx(MetricCardGlass, {
3198
+ title: metric.title,
3199
+ value: metric.value,
3200
+ variant: metric.variant
3201
+ }, metric.title))
3202
+ });
3203
+ });
3204
+ MetricsGridGlass.displayName = "MetricsGridGlass";
3205
+ const RepositoryCardGlass = forwardRef(({ name, languages, commits, contribution, stars = 0, flagType = "green", issues = [], expanded = false, onToggle, onGitHubClick, onAIAnalysisClick, className, ...props }, ref) => {
3206
+ const totalProjectCommits = contribution > 0 ? Math.round(commits / (contribution / 100)) : commits;
3207
+ const estimatedLines = Math.round(commits * 12);
3208
+ const expandedStyles = {
3209
+ background: "var(--expanded-bg)",
3210
+ borderColor: "var(--card-border)"
3211
+ };
3212
+ const metricCardStyles = {
3213
+ background: "var(--card-bg)",
3214
+ borderColor: "var(--card-border)"
3215
+ };
3216
+ return /* @__PURE__ */ jsxs(InteractiveCard, {
3217
+ ref,
3218
+ baseBg: "var(--card-bg)",
3219
+ hoverBg: "var(--card-hover-bg)",
3220
+ borderColor: "var(--card-border)",
3221
+ hoverLift: false,
3222
+ blur: "sm",
3223
+ rounded: "rounded-xl",
3224
+ className: cn("overflow-hidden", className),
3225
+ ...props,
3226
+ children: [/* @__PURE__ */ jsxs("div", {
3227
+ className: "p-3 md:p-3.5 cursor-pointer",
3228
+ onClick: onToggle,
3229
+ role: "button",
3230
+ tabIndex: 0,
3231
+ onKeyDown: (e) => {
3232
+ if (e.key === "Enter" || e.key === " ") {
3233
+ e.preventDefault();
3234
+ onToggle?.();
3235
+ }
3236
+ },
3237
+ "aria-expanded": expanded,
3238
+ children: [
3239
+ /* @__PURE__ */ jsxs("div", {
3240
+ className: "flex items-center justify-between",
3241
+ children: [/* @__PURE__ */ jsxs("div", {
3242
+ className: "flex items-center gap-2.5",
3243
+ children: [/* @__PURE__ */ jsx("span", {
3244
+ className: "font-medium text-sm",
3245
+ style: { color: "var(--text-primary)" },
3246
+ children: name
3247
+ }), /* @__PURE__ */ jsx(StatusIndicatorGlass, { type: flagType })]
3248
+ }), /* @__PURE__ */ jsxs("div", {
3249
+ className: "flex items-center gap-2",
3250
+ children: [stars > 0 && /* @__PURE__ */ jsxs("span", {
3251
+ className: "flex items-center gap-1 text-xs",
3252
+ style: { color: "var(--status-away)" },
3253
+ children: [/* @__PURE__ */ jsx(Star, { className: "w-3 h-3" }), stars]
3254
+ }), expanded ? /* @__PURE__ */ jsx(ChevronUp, {
3255
+ className: "w-4 h-4",
3256
+ style: { color: "var(--text-muted)" }
3257
+ }) : /* @__PURE__ */ jsx(ChevronDown, {
3258
+ className: "w-4 h-4",
3259
+ style: { color: "var(--text-muted)" }
3260
+ })]
3261
+ })]
3262
+ }),
3263
+ /* @__PURE__ */ jsx("div", {
3264
+ className: "text-xs mt-1.5",
3265
+ style: { color: "var(--text-muted)" },
3266
+ children: languages
3267
+ }),
3268
+ /* @__PURE__ */ jsxs("div", {
3269
+ className: "text-xs mt-0.5",
3270
+ style: { color: "var(--text-secondary)" },
3271
+ children: [
3272
+ commits,
3273
+ " commits · ",
3274
+ contribution,
3275
+ "%"
3276
+ ]
3277
+ })
3278
+ ]
3279
+ }), expanded && /* @__PURE__ */ jsxs("div", {
3280
+ className: "border-t p-3.5 space-y-3",
3281
+ style: expandedStyles,
3282
+ children: [
3283
+ issues.length > 0 && /* @__PURE__ */ jsxs("div", {
3284
+ className: "p-3 rounded-xl border",
3285
+ style: {
3286
+ background: "var(--alert-danger-bg)",
3287
+ borderColor: "var(--alert-danger-border)"
3288
+ },
3289
+ children: [/* @__PURE__ */ jsxs("div", {
3290
+ className: "text-xs font-semibold flex items-center gap-1.5 mb-1.5",
3291
+ style: { color: "var(--alert-danger-text)" },
3292
+ children: [/* @__PURE__ */ jsx(AlertTriangle, { className: "w-3.5 h-3.5" }), "Issues"]
3293
+ }), issues.map((issue, index) => /* @__PURE__ */ jsxs("div", {
3294
+ className: "text-xs opacity-70",
3295
+ style: { color: "var(--alert-danger-text)" },
3296
+ children: ["• ", issue]
3297
+ }, index))]
3298
+ }),
3299
+ /* @__PURE__ */ jsxs("div", {
3300
+ className: "grid grid-cols-2 gap-2",
3301
+ children: [/* @__PURE__ */ jsxs("div", {
3302
+ className: "p-2.5 rounded-lg border",
3303
+ style: metricCardStyles,
3304
+ children: [
3305
+ /* @__PURE__ */ jsx("div", {
3306
+ className: "text-xs",
3307
+ style: { color: "var(--text-muted)" },
3308
+ children: "Your Contribution"
3309
+ }),
3310
+ /* @__PURE__ */ jsxs("div", {
3311
+ className: "font-semibold",
3312
+ style: { color: "var(--text-primary)" },
3313
+ children: [commits, " commits"]
3314
+ }),
3315
+ /* @__PURE__ */ jsxs("div", {
3316
+ className: "text-xs",
3317
+ style: { color: "var(--text-muted)" },
3318
+ children: [contribution, "%"]
3319
+ })
3320
+ ]
3321
+ }), /* @__PURE__ */ jsxs("div", {
3322
+ className: "p-2.5 rounded-lg border",
3323
+ style: metricCardStyles,
3324
+ children: [
3325
+ /* @__PURE__ */ jsx("div", {
3326
+ className: "text-xs",
3327
+ style: { color: "var(--text-muted)" },
3328
+ children: "Full Project"
3329
+ }),
3330
+ /* @__PURE__ */ jsxs("div", {
3331
+ className: "font-semibold",
3332
+ style: { color: "var(--text-primary)" },
3333
+ children: [totalProjectCommits, " commits"]
3334
+ }),
3335
+ /* @__PURE__ */ jsxs("div", {
3336
+ className: "text-xs",
3337
+ style: { color: "var(--text-muted)" },
3338
+ children: [
3339
+ "~",
3340
+ estimatedLines,
3341
+ " lines"
3342
+ ]
3343
+ })
3344
+ ]
3345
+ })]
3346
+ }),
3347
+ /* @__PURE__ */ jsxs("div", {
3348
+ className: "flex flex-col sm:flex-row gap-2",
3349
+ children: [/* @__PURE__ */ jsx(ButtonGlass, {
3350
+ variant: "secondary",
3351
+ size: "sm",
3352
+ icon: ExternalLink,
3353
+ onClick: (e) => {
3354
+ e.stopPropagation();
3355
+ onGitHubClick?.();
3356
+ },
3357
+ className: "flex-1",
3358
+ children: "GitHub"
3359
+ }), /* @__PURE__ */ jsx(ButtonGlass, {
3360
+ variant: "default",
3361
+ size: "sm",
3362
+ icon: Sparkles,
3363
+ onClick: (e) => {
3364
+ e.stopPropagation();
3365
+ onAIAnalysisClick?.();
3366
+ },
3367
+ className: "flex-1",
3368
+ children: "AI Analysis"
3369
+ })]
3370
+ })
3371
+ ]
3372
+ })]
3373
+ });
3374
+ });
3375
+ RepositoryCardGlass.displayName = "RepositoryCardGlass";
3376
+ const RepositoryHeaderGlass = forwardRef(({ name, flagType = "green", stars = 0, expanded = false, abbreviatedStars = false, className, ...props }, ref) => {
3377
+ const titleStyles = { color: "var(--text-primary)" };
3378
+ const starStyles = { color: "var(--status-away)" };
3379
+ const mutedStyles = { color: "var(--text-muted)" };
3380
+ const formatStars = (count) => {
3381
+ if (!abbreviatedStars) return String(count);
3382
+ if (count >= 1e6) return `${(count / 1e6).toFixed(1)}M`;
3383
+ if (count >= 1e3) return `${(count / 1e3).toFixed(1)}k`;
3384
+ return String(count);
3385
+ };
3386
+ return /* @__PURE__ */ jsxs("div", {
3387
+ ref,
3388
+ className: cn("flex items-center justify-between", className),
3389
+ ...props,
3390
+ children: [/* @__PURE__ */ jsxs("div", {
3391
+ className: "flex items-center gap-2.5",
3392
+ children: [/* @__PURE__ */ jsx("span", {
3393
+ className: "font-medium text-sm",
3394
+ style: titleStyles,
3395
+ children: name
3396
+ }), /* @__PURE__ */ jsx(StatusIndicatorGlass, { type: flagType })]
3397
+ }), /* @__PURE__ */ jsxs("div", {
3398
+ className: "flex items-center gap-2",
3399
+ children: [stars > 0 && /* @__PURE__ */ jsxs("span", {
3400
+ className: "flex items-center gap-1 text-xs",
3401
+ style: starStyles,
3402
+ children: [/* @__PURE__ */ jsx(Star, { className: "w-3 h-3" }), formatStars(stars)]
3403
+ }), expanded ? /* @__PURE__ */ jsx(ChevronUp, {
3404
+ className: "w-4 h-4",
3405
+ style: mutedStyles
3406
+ }) : /* @__PURE__ */ jsx(ChevronDown, {
3407
+ className: "w-4 h-4",
3408
+ style: mutedStyles
3409
+ })]
3410
+ })]
3411
+ });
3412
+ });
3413
+ RepositoryHeaderGlass.displayName = "RepositoryHeaderGlass";
3414
+ const RepositoryMetadataGlass = forwardRef(({ languages, commits, contribution, stacked = false, className, ...props }, ref) => {
3415
+ const mutedStyles = { color: "var(--text-muted)" };
3416
+ const secondaryStyles = { color: "var(--text-secondary)" };
3417
+ return /* @__PURE__ */ jsxs("div", {
3418
+ ref,
3419
+ className: cn(stacked ? "space-y-0.5" : "space-y-1", className),
3420
+ ...props,
3421
+ children: [/* @__PURE__ */ jsx("div", {
3422
+ className: "text-xs",
3423
+ style: mutedStyles,
3424
+ children: languages
3425
+ }), /* @__PURE__ */ jsxs("div", {
3426
+ className: "text-xs",
3427
+ style: secondaryStyles,
3428
+ children: [
3429
+ commits.toLocaleString(),
3430
+ " commits · ",
3431
+ contribution,
3432
+ "%"
3433
+ ]
3434
+ })]
3435
+ });
3436
+ });
3437
+ RepositoryMetadataGlass.displayName = "RepositoryMetadataGlass";
3438
+ const TrustScoreDisplayGlass = forwardRef(({ score, maxScore = 100, title = "Overall Trust Score", showIcon = true, size = "md", className, ...props }, ref) => {
3439
+ const titleStyles = { color: "var(--text-primary)" };
3440
+ const accentStyles = { color: "var(--text-accent)" };
3441
+ const mutedStyles = { color: "var(--text-muted)" };
3442
+ const sizes = {
3443
+ sm: {
3444
+ title: "text-base",
3445
+ score: "text-2xl",
3446
+ max: "text-lg",
3447
+ icon: "w-4 h-4"
3448
+ },
3449
+ md: {
3450
+ title: "text-lg",
3451
+ score: "text-4xl",
3452
+ max: "text-xl",
3453
+ icon: "w-5 h-5"
3454
+ },
3455
+ lg: {
3456
+ title: "text-xl",
3457
+ score: "text-5xl",
3458
+ max: "text-2xl",
3459
+ icon: "w-6 h-6"
3460
+ }
3461
+ }[size];
3462
+ return /* @__PURE__ */ jsxs("div", {
3463
+ ref,
3464
+ className: cn("flex items-center justify-between", className),
3465
+ ...props,
3466
+ children: [/* @__PURE__ */ jsxs("h2", {
3467
+ className: cn("font-semibold flex items-center gap-2", sizes.title),
3468
+ style: titleStyles,
3469
+ children: [showIcon && /* @__PURE__ */ jsx(Target, {
3470
+ className: sizes.icon,
3471
+ style: accentStyles
3472
+ }), title]
3473
+ }), /* @__PURE__ */ jsxs("div", {
3474
+ className: "flex items-center gap-2 animate-[score-pulse_2s_ease-in-out_infinite]",
3475
+ children: [/* @__PURE__ */ jsx("span", {
3476
+ className: cn(sizes.score, "font-bold bg-clip-text text-transparent"),
3477
+ style: { backgroundImage: "var(--score-gradient)" },
3478
+ children: score
3479
+ }), /* @__PURE__ */ jsxs("span", {
3480
+ className: sizes.max,
3481
+ style: mutedStyles,
3482
+ children: ["/ ", maxScore]
3483
+ })]
3484
+ })]
3485
+ });
3486
+ });
3487
+ TrustScoreDisplayGlass.displayName = "TrustScoreDisplayGlass";
3488
+ const UserInfoGlass = forwardRef(({ name, username, joinDate, profileUrl = "#", layout = "vertical", className, ...props }, ref) => {
3489
+ const titleStyles = { color: "var(--text-primary)" };
3490
+ const metaStyles = { color: "var(--text-secondary)" };
3491
+ const linkStyles = { color: "var(--text-accent)" };
3492
+ return /* @__PURE__ */ jsxs("div", {
3493
+ ref,
3494
+ className: cn(layout === "vertical" ? "space-y-1" : "flex items-center gap-4", className),
3495
+ ...props,
3496
+ children: [/* @__PURE__ */ jsx("h1", {
3497
+ className: cn("font-bold", layout === "vertical" ? "text-lg md:text-xl" : "text-xl"),
3498
+ style: titleStyles,
3499
+ children: name
3500
+ }), /* @__PURE__ */ jsxs("div", {
3501
+ className: cn("flex items-center gap-2 text-sm flex-wrap", layout === "vertical" && "mt-0.5"),
3502
+ style: metaStyles,
3503
+ children: [
3504
+ /* @__PURE__ */ jsxs("a", {
3505
+ href: profileUrl,
3506
+ className: "flex items-center gap-1 hover:underline",
3507
+ style: linkStyles,
3508
+ "aria-label": `View ${username}'s profile`,
3509
+ children: [
3510
+ "@",
3511
+ username,
3512
+ " ",
3513
+ /* @__PURE__ */ jsx(ExternalLink, { className: "w-3 h-3" })
3514
+ ]
3515
+ }),
3516
+ /* @__PURE__ */ jsx("span", { children: "·" }),
3517
+ /* @__PURE__ */ jsxs("span", {
3518
+ className: "flex items-center gap-1",
3519
+ children: [
3520
+ /* @__PURE__ */ jsx(Calendar, { className: "w-3 h-3" }),
3521
+ " Joined ",
3522
+ joinDate
3523
+ ]
3524
+ })
3525
+ ]
3526
+ })]
3527
+ });
3528
+ });
3529
+ UserInfoGlass.displayName = "UserInfoGlass";
3530
+ const UserStatsLineGlass = forwardRef(({ repos, followers, following, wrap = true, abbreviated = false, className, ...props }, ref) => {
3531
+ return /* @__PURE__ */ jsxs("div", {
3532
+ ref,
3533
+ className: cn("flex items-center gap-4 text-sm", wrap && "flex-wrap", className),
3534
+ ...props,
3535
+ children: [
3536
+ /* @__PURE__ */ jsx(StatItemGlass, {
3537
+ icon: FolderGit2,
3538
+ value: repos,
3539
+ label: "repos",
3540
+ abbreviated
3541
+ }),
3542
+ /* @__PURE__ */ jsx(StatItemGlass, {
3543
+ icon: Users,
3544
+ value: followers,
3545
+ label: "followers",
3546
+ abbreviated
3547
+ }),
3548
+ /* @__PURE__ */ jsx(StatItemGlass, {
3549
+ icon: User,
3550
+ value: following,
3551
+ label: "following",
3552
+ abbreviated
3553
+ })
3554
+ ]
3555
+ });
3556
+ });
3557
+ UserStatsLineGlass.displayName = "UserStatsLineGlass";
3558
+ const YearCardGlass = forwardRef(({ year, emoji, label, commits, progress, isExpanded = false, gradient = "blue", prs = 0, repos = 0, onShowYear, sparklineData, sparklineLabels, insights, stats, actionLabel, showSparklineCollapsed = true, valueFormatter, children, className, onClick, ...props }, ref) => {
3559
+ const expandedStyles = {
3560
+ background: "var(--expanded-bg)",
3561
+ borderColor: "var(--expanded-border)"
3562
+ };
3563
+ const metricCardStyles = {
3564
+ background: "var(--card-bg)",
3565
+ borderColor: "var(--card-border)"
3566
+ };
3567
+ const displayCommits = valueFormatter ? valueFormatter(commits) : commits;
3568
+ const displayStats = stats || [
3569
+ {
3570
+ label: "Commits",
3571
+ value: commits
3572
+ },
3573
+ {
3574
+ label: "PRs",
3575
+ value: prs
3576
+ },
3577
+ {
3578
+ label: "Repos",
3579
+ value: repos
3580
+ }
3581
+ ];
3582
+ const buttonLabel = actionLabel || `Show repos from ${year}`;
3583
+ return /* @__PURE__ */ jsxs(InteractiveCard, {
3584
+ ref,
3585
+ baseBg: "var(--year-card-bg)",
3586
+ hoverBg: "var(--card-hover-bg)",
3587
+ borderColor: "var(--year-card-border)",
3588
+ hoverGlow: "var(--year-card-hover-glow)",
3589
+ hoverLift: true,
3590
+ rounded: "rounded-xl",
3591
+ className: cn("w-full max-w-2xl p-2.5 md:p-3 cursor-pointer", className),
3592
+ onClick,
3593
+ role: "button",
3594
+ tabIndex: 0,
3595
+ onKeyDown: (e) => {
3596
+ if (e.key === "Enter" || e.key === " ") {
3597
+ e.preventDefault();
3598
+ onClick?.(e);
3599
+ }
3600
+ },
3601
+ "aria-expanded": isExpanded,
3602
+ "aria-label": `${year} year: ${label}, ${commits} commits. ${isExpanded ? "Collapse" : "Expand"} details`,
3603
+ ...props,
3604
+ children: [
3605
+ /* @__PURE__ */ jsxs("div", {
3606
+ className: "flex items-center justify-between mb-1.5 md:mb-2",
3607
+ children: [/* @__PURE__ */ jsxs("div", {
3608
+ className: "flex items-center gap-1.5 md:gap-2",
3609
+ children: [/* @__PURE__ */ jsx("span", {
3610
+ className: "font-semibold text-sm md:text-base",
3611
+ style: { color: "var(--text-primary)" },
3612
+ children: year
3613
+ }), /* @__PURE__ */ jsxs(BadgeGlass, { children: [
3614
+ emoji,
3615
+ " ",
3616
+ label
3617
+ ] })]
3618
+ }), /* @__PURE__ */ jsxs("span", {
3619
+ className: "text-xs md:text-sm flex items-center gap-0.5 md:gap-1",
3620
+ style: { color: "var(--text-secondary)" },
3621
+ children: [displayCommits, isExpanded ? /* @__PURE__ */ jsx(ChevronUp, {
3622
+ className: "w-3.5 h-3.5 md:w-4 md:h-4",
3623
+ "aria-hidden": "true"
3624
+ }) : /* @__PURE__ */ jsx(ChevronDown, {
3625
+ className: "w-3.5 h-3.5 md:w-4 md:h-4",
3626
+ "aria-hidden": "true"
3627
+ })]
3628
+ })]
3629
+ }),
3630
+ /* @__PURE__ */ jsxs("div", {
3631
+ className: "flex items-center gap-2",
3632
+ children: [/* @__PURE__ */ jsx("div", {
3633
+ className: "flex-1",
3634
+ children: /* @__PURE__ */ jsx(ProgressGlass, {
3635
+ value: progress,
3636
+ gradient,
3637
+ size: "sm"
3638
+ })
3639
+ }), showSparklineCollapsed && sparklineData && sparklineData.length > 0 && /* @__PURE__ */ jsx(SparklineGlass, {
3640
+ data: sparklineData,
3641
+ labels: sparklineLabels,
3642
+ height: "sm",
3643
+ gap: "sm",
3644
+ className: "w-16 md:w-20",
3645
+ "aria-label": `Activity trend for ${year}`
3646
+ })]
3647
+ }),
3648
+ isExpanded && /* @__PURE__ */ jsxs("div", {
3649
+ className: "mt-3 pt-3 border-t space-y-3",
3650
+ style: expandedStyles,
3651
+ children: [
3652
+ /* @__PURE__ */ jsx("div", {
3653
+ className: "grid gap-2 md:gap-3",
3654
+ style: { gridTemplateColumns: `repeat(${Math.min(displayStats.length, 4)}, 1fr)` },
3655
+ children: displayStats.map((stat, index) => /* @__PURE__ */ jsxs("div", {
3656
+ className: "p-2 md:p-2.5 rounded-lg border text-center",
3657
+ style: metricCardStyles,
3658
+ children: [
3659
+ stat.icon && /* @__PURE__ */ jsx("div", {
3660
+ className: "mb-1 flex justify-center text-[var(--text-muted)]",
3661
+ children: stat.icon
3662
+ }),
3663
+ /* @__PURE__ */ jsx("div", {
3664
+ className: "text-base md:text-xl font-bold",
3665
+ style: { color: "var(--text-primary)" },
3666
+ children: stat.value
3667
+ }),
3668
+ /* @__PURE__ */ jsx("div", {
3669
+ className: "text-(length:--font-size-2xs) md:text-xs text-(--text-muted)",
3670
+ children: stat.label
3671
+ })
3672
+ ]
3673
+ }, index))
3674
+ }),
3675
+ !showSparklineCollapsed && sparklineData && sparklineData.length > 0 && /* @__PURE__ */ jsx(SparklineGlass, {
3676
+ data: sparklineData,
3677
+ labels: sparklineLabels,
3678
+ showLabels: !!sparklineLabels,
3679
+ height: "md",
3680
+ gap: "sm",
3681
+ highlightMax: true,
3682
+ className: "w-full",
3683
+ "aria-label": `Monthly activity for ${year}`
3684
+ }),
3685
+ insights && insights.length > 0 && /* @__PURE__ */ jsx("div", {
3686
+ className: "space-y-2",
3687
+ children: insights.map((insight, index) => /* @__PURE__ */ jsx(InsightCardGlass, {
3688
+ variant: insight.variant,
3689
+ emoji: insight.emoji,
3690
+ text: insight.text,
3691
+ detail: insight.detail,
3692
+ inline: false
3693
+ }, index))
3694
+ }),
3695
+ children,
3696
+ onShowYear && /* @__PURE__ */ jsx(ButtonGlass, {
3697
+ variant: "default",
3698
+ size: "sm",
3699
+ onClick: (e) => {
3700
+ e.stopPropagation();
3701
+ onShowYear();
3702
+ },
3703
+ className: "w-full",
3704
+ children: buttonLabel
3705
+ })
3706
+ ]
3707
+ })
3708
+ ]
3709
+ });
3710
+ });
3711
+ YearCardGlass.displayName = "YearCardGlass";
3712
+ const CareerStatsGlass = forwardRef(({ totalCommits = 2242, totalPRs = 47, totalRepos = 11, years = [], className, ...props }, ref) => {
3713
+ const [expandedYear, setExpandedYear] = useState(null);
3714
+ const handleYearClick = (year) => {
3715
+ setExpandedYear(expandedYear === year ? null : year);
3716
+ };
3717
+ return /* @__PURE__ */ jsxs(GlassCard, {
3718
+ ref,
3719
+ className: cn("p-4 md:p-5 lg:p-6", className),
3720
+ intensity: "medium",
3721
+ hover: false,
3722
+ ...props,
3723
+ children: [
3724
+ /* @__PURE__ */ jsxs("h3", {
3725
+ className: "font-semibold flex items-center gap-2 md:gap-2.5 lg:gap-3 mb-1 text-base md:text-lg lg:text-xl",
3726
+ style: { color: "var(--text-primary)" },
3727
+ children: [/* @__PURE__ */ jsx(TrendingUp, {
3728
+ className: "w-4 h-4 md:w-5 md:h-5 lg:w-6 lg:h-6",
3729
+ style: { color: "var(--text-accent)" }
3730
+ }), "Career Stats"]
3731
+ }),
3732
+ /* @__PURE__ */ jsxs("p", {
3733
+ className: "text-xs md:text-sm lg:text-base mb-3 md:mb-4 flex items-center gap-2 md:gap-2.5 lg:gap-3 flex-wrap",
3734
+ style: { color: "var(--text-secondary)" },
3735
+ children: [
3736
+ /* @__PURE__ */ jsxs("span", {
3737
+ className: "flex items-center gap-1 md:gap-1.5",
3738
+ children: [
3739
+ /* @__PURE__ */ jsx(Code, { className: "w-3.5 h-3.5 md:w-4 md:h-4 lg:w-5 lg:h-5" }),
3740
+ totalCommits.toLocaleString(),
3741
+ " commits"
3742
+ ]
3743
+ }),
3744
+ /* @__PURE__ */ jsx("span", { children: "·" }),
3745
+ /* @__PURE__ */ jsxs("span", {
3746
+ className: "flex items-center gap-1 md:gap-1.5",
3747
+ children: [
3748
+ /* @__PURE__ */ jsx(GitPullRequest, { className: "w-3.5 h-3.5 md:w-4 md:h-4 lg:w-5 lg:h-5" }),
3749
+ totalPRs,
3750
+ " PRs"
3751
+ ]
3752
+ }),
3753
+ /* @__PURE__ */ jsx("span", { children: "·" }),
3754
+ /* @__PURE__ */ jsxs("span", {
3755
+ className: "flex items-center gap-1 md:gap-1.5",
3756
+ children: [
3757
+ /* @__PURE__ */ jsx(FolderGit2, { className: "w-3.5 h-3.5 md:w-4 md:h-4 lg:w-5 lg:h-5" }),
3758
+ totalRepos,
3759
+ " repos"
3760
+ ]
3761
+ })
3762
+ ]
3763
+ }),
3764
+ /* @__PURE__ */ jsx("div", {
3765
+ className: "space-y-2 md:space-y-2.5 lg:space-y-3",
3766
+ children: years.map((y) => /* @__PURE__ */ jsx(YearCardGlass, {
3767
+ year: y.year,
3768
+ emoji: y.emoji,
3769
+ label: y.label,
3770
+ commits: y.commits,
3771
+ progress: y.progress,
3772
+ prs: y.prs,
3773
+ repos: y.repos,
3774
+ isExpanded: expandedYear === y.year,
3775
+ onClick: () => handleYearClick(y.year),
3776
+ onShowYear: () => {}
3777
+ }, y.year))
3778
+ })
3779
+ ]
3780
+ });
3781
+ });
3782
+ CareerStatsGlass.displayName = "CareerStatsGlass";
3783
+ const FlagsSectionGlass = forwardRef(({ flags = [], expanded = false, onToggle, className, ...props }, ref) => {
3784
+ return /* @__PURE__ */ jsxs(GlassCard, {
3785
+ ref,
3786
+ className: cn("w-full max-w-2xl", className),
3787
+ intensity: "medium",
3788
+ hover: false,
3789
+ ...props,
3790
+ children: [/* @__PURE__ */ jsxs("button", {
3791
+ onClick: onToggle,
3792
+ className: "w-full p-3 md:p-4 flex items-center justify-between rounded-2xl",
3793
+ style: { color: "var(--text-primary)" },
3794
+ type: "button",
3795
+ "aria-expanded": expanded,
3796
+ children: [/* @__PURE__ */ jsxs("div", {
3797
+ className: "flex items-center gap-1.5 md:gap-2",
3798
+ children: [/* @__PURE__ */ jsx(AlertTriangle, {
3799
+ className: "w-4 h-4 md:w-5 md:h-5",
3800
+ style: { color: "var(--status-away)" }
3801
+ }), /* @__PURE__ */ jsxs("span", {
3802
+ className: "font-medium text-sm md:text-base",
3803
+ children: [flags.length, " flags detected"]
3804
+ })]
3805
+ }), expanded ? /* @__PURE__ */ jsx(ChevronUp, {
3806
+ className: "w-4 h-4 md:w-5 md:h-5",
3807
+ style: { color: "var(--text-muted)" }
3808
+ }) : /* @__PURE__ */ jsx(ChevronDown, {
3809
+ className: "w-4 h-4 md:w-5 md:h-5",
3810
+ style: { color: "var(--text-muted)" }
3811
+ })]
3812
+ }), expanded && /* @__PURE__ */ jsx("div", {
3813
+ className: "px-3 pb-3 md:px-4 md:pb-4 space-y-1.5 md:space-y-2",
3814
+ children: flags.map((flag, i) => /* @__PURE__ */ jsx(FlagAlertGlass, {
3815
+ type: flag.type,
3816
+ title: flag.title,
3817
+ description: flag.description
3818
+ }, `flag-${i}`))
3819
+ })]
3820
+ });
3821
+ });
3822
+ FlagsSectionGlass.displayName = "FlagsSectionGlass";
3823
+ const HeaderBrandingGlass = forwardRef(({ logoIcon, title, subtitle, onLogoClick, logoAriaLabel = "Home", className, ...props }, ref) => {
3824
+ const titleStyles = { color: "var(--text-primary)" };
3825
+ return /* @__PURE__ */ jsxs("div", {
3826
+ ref,
3827
+ className: cn("flex items-center gap-4", className),
3828
+ ...props,
3829
+ children: [/* @__PURE__ */ jsx(IconButtonGlass, {
3830
+ icon: logoIcon,
3831
+ "aria-label": logoAriaLabel,
3832
+ onClick: onLogoClick,
3833
+ variant: "gradient",
3834
+ size: "md"
3835
+ }), /* @__PURE__ */ jsxs("div", {
3836
+ className: "flex flex-col sm:flex-row sm:items-center sm:gap-2",
3837
+ children: [/* @__PURE__ */ jsx("span", {
3838
+ className: "font-semibold text-base md:text-lg",
3839
+ style: titleStyles,
3840
+ children: title
3841
+ }), subtitle && /* @__PURE__ */ jsxs("span", {
3842
+ className: "hidden md:inline text-sm",
3843
+ style: { color: "var(--text-secondary)" },
3844
+ children: ["· ", subtitle]
3845
+ })]
3846
+ })]
3847
+ });
3848
+ });
3849
+ HeaderBrandingGlass.displayName = "HeaderBrandingGlass";
3850
+ var themes = [
3851
+ "light",
3852
+ "aurora",
3853
+ "glass"
3854
+ ];
3855
+ var themeConfig = {
3856
+ light: {
3857
+ label: "Light",
3858
+ icon: Sun
3859
+ },
3860
+ aurora: {
3861
+ label: "Aurora",
3862
+ icon: Moon
3863
+ },
3864
+ glass: {
3865
+ label: "Glass",
3866
+ icon: Palette
3867
+ }
3868
+ };
3869
+ const HeaderNavGlass = forwardRef(({ username = "Yhooi2", onSearch, onThemeToggle, className, ...props }, ref) => {
3870
+ const { theme, cycleTheme } = useTheme();
3871
+ const nextTheme = themes[(themes.indexOf(theme) + 1) % themes.length];
3872
+ const NextIcon = themeConfig[nextTheme].icon;
3873
+ const headerStyles = {
3874
+ background: "var(--header-bg)",
3875
+ borderColor: "var(--header-border)",
3876
+ backdropFilter: "blur(var(--blur-md))",
3877
+ WebkitBackdropFilter: "blur(var(--blur-md))"
3878
+ };
3879
+ const iconBtnStyles = {
3880
+ background: "linear-gradient(135deg, var(--icon-btn-from), var(--icon-btn-to))",
3881
+ boxShadow: "var(--icon-btn-shadow)"
3882
+ };
3883
+ const themeBtnStyles = {
3884
+ background: "var(--card-subtle-bg)",
3885
+ border: "1px solid var(--card-subtle-border)"
3886
+ };
3887
+ return /* @__PURE__ */ jsx("header", {
3888
+ ref,
3889
+ className: cn("border rounded-xl py-2 px-3 md:py-3 md:px-4 transition-all duration-300", className),
3890
+ style: headerStyles,
3891
+ ...props,
3892
+ children: /* @__PURE__ */ jsxs("div", {
3893
+ className: "flex items-center justify-between",
3894
+ children: [/* @__PURE__ */ jsxs("div", {
3895
+ className: "flex items-center gap-2 md:gap-4",
3896
+ children: [
3897
+ /* @__PURE__ */ jsx("button", {
3898
+ className: "w-8 h-8 md:w-10 md:h-10 rounded-xl flex items-center justify-center transition-all duration-300 hover:scale-105",
3899
+ style: iconBtnStyles,
3900
+ type: "button",
3901
+ "aria-label": "GitHub",
3902
+ children: /* @__PURE__ */ jsx(Github, {
3903
+ className: "w-4 h-4 md:w-5 md:h-5",
3904
+ style: { color: "var(--icon-btn-text)" }
3905
+ })
3906
+ }),
3907
+ /* @__PURE__ */ jsx("span", {
3908
+ className: "font-semibold text-base md:text-lg",
3909
+ style: { color: "var(--text-primary)" },
3910
+ children: "User Analytics"
3911
+ }),
3912
+ /* @__PURE__ */ jsx(SearchBoxGlass, {
3913
+ className: "ml-2 md:ml-4",
3914
+ defaultValue: username,
3915
+ onSubmit: onSearch,
3916
+ inputWidth: "w-28 sm:w-36 md:w-48",
3917
+ placeholder: "Search username..."
3918
+ })
3919
+ ]
3920
+ }), /* @__PURE__ */ jsxs("div", {
3921
+ className: "flex items-center gap-2 md:gap-3",
3922
+ children: [/* @__PURE__ */ jsx("button", {
3923
+ onClick: onThemeToggle ?? cycleTheme,
3924
+ className: "p-2 md:p-2.5 rounded-xl transition-all duration-300 hover:scale-105",
3925
+ style: themeBtnStyles,
3926
+ type: "button",
3927
+ "aria-label": `Switch to ${themeConfig[nextTheme].label} theme`,
3928
+ children: /* @__PURE__ */ jsx(NextIcon, {
3929
+ className: "w-4 h-4 md:w-5 md:h-5",
3930
+ style: { color: "var(--text-secondary)" }
3931
+ })
3932
+ }), /* @__PURE__ */ jsx(ButtonGlass, {
3933
+ variant: "secondary",
3934
+ icon: Github,
3935
+ className: "hidden md:inline-flex",
3936
+ children: "Sign in with GitHub"
3937
+ })]
3938
+ })]
3939
+ })
3940
+ });
3941
+ });
3942
+ HeaderNavGlass.displayName = "HeaderNavGlass";
3943
+ const ProfileHeaderGlass = forwardRef(({ name = "Artem Safronov", username = "Yhooi2", joinDate = "Jan 2023", stats = {}, languages = [], onAIGenerate, className, ...props }, ref) => {
3944
+ const s = {
3945
+ repos: 11,
3946
+ followers: 1,
3947
+ following: 5,
3948
+ ...stats
3949
+ };
3950
+ const getInitials$1 = (fullName) => {
3951
+ return fullName.split(" ").map((n) => n[0]).join("").toUpperCase().slice(0, 2);
3952
+ };
3953
+ return /* @__PURE__ */ jsx(GlassCard, {
3954
+ ref,
3955
+ className: cn("p-5", className),
3956
+ intensity: "strong",
3957
+ glow: "violet",
3958
+ hover: false,
3959
+ ...props,
3960
+ children: /* @__PURE__ */ jsxs("div", {
3961
+ className: "flex flex-col md:flex-row gap-3 md:gap-6",
3962
+ children: [/* @__PURE__ */ jsxs("div", {
3963
+ className: "flex-1",
3964
+ children: [/* @__PURE__ */ jsxs("div", {
3965
+ className: "flex gap-4",
3966
+ children: [/* @__PURE__ */ jsx(ProfileAvatarGlass, {
3967
+ initials: getInitials$1(name),
3968
+ size: "lg",
3969
+ status: "online"
3970
+ }), /* @__PURE__ */ jsxs("div", { children: [
3971
+ /* @__PURE__ */ jsx("h1", {
3972
+ className: "text-lg md:text-xl font-bold",
3973
+ style: { color: "var(--text-primary)" },
3974
+ children: name
3975
+ }),
3976
+ /* @__PURE__ */ jsxs("div", {
3977
+ className: "flex items-center gap-2 text-sm mt-0.5",
3978
+ style: { color: "var(--text-secondary)" },
3979
+ children: [
3980
+ /* @__PURE__ */ jsxs("a", {
3981
+ href: "#",
3982
+ className: "flex items-center gap-1 hover:underline",
3983
+ style: { color: "var(--text-accent)" },
3984
+ children: [
3985
+ "@",
3986
+ username,
3987
+ " ",
3988
+ /* @__PURE__ */ jsx(ExternalLink, { className: "w-3 h-3" })
3989
+ ]
3990
+ }),
3991
+ /* @__PURE__ */ jsx("span", { children: "·" }),
3992
+ /* @__PURE__ */ jsxs("span", {
3993
+ className: "flex items-center gap-1",
3994
+ children: [
3995
+ /* @__PURE__ */ jsx(Calendar, { className: "w-3 h-3" }),
3996
+ " Joined ",
3997
+ joinDate
3998
+ ]
3999
+ })
4000
+ ]
4001
+ }),
4002
+ /* @__PURE__ */ jsxs("div", {
4003
+ className: "flex items-center gap-3 md:gap-4 mt-2 text-sm flex-wrap",
4004
+ style: { color: "var(--text-secondary)" },
4005
+ children: [
4006
+ /* @__PURE__ */ jsxs("span", {
4007
+ className: "flex items-center gap-1",
4008
+ children: [
4009
+ /* @__PURE__ */ jsx(FolderGit2, {
4010
+ className: "w-4 h-4",
4011
+ style: { color: "var(--text-accent)" }
4012
+ }),
4013
+ s.repos,
4014
+ " repos"
4015
+ ]
4016
+ }),
4017
+ /* @__PURE__ */ jsxs("span", {
4018
+ className: "flex items-center gap-1",
4019
+ children: [
4020
+ /* @__PURE__ */ jsx(Users, {
4021
+ className: "w-4 h-4",
4022
+ style: { color: "var(--text-accent)" }
4023
+ }),
4024
+ s.followers,
4025
+ " followers"
4026
+ ]
4027
+ }),
4028
+ /* @__PURE__ */ jsxs("span", {
4029
+ className: "flex items-center gap-1",
4030
+ children: [
4031
+ /* @__PURE__ */ jsx(User, {
4032
+ className: "w-4 h-4",
4033
+ style: { color: "var(--text-accent)" }
4034
+ }),
4035
+ s.following,
4036
+ " following"
4037
+ ]
4038
+ })
4039
+ ]
4040
+ })
4041
+ ] })]
4042
+ }), languages.length > 0 && /* @__PURE__ */ jsx("div", {
4043
+ className: "mt-4",
4044
+ children: /* @__PURE__ */ jsx(LanguageBarGlass, { languages })
4045
+ })]
4046
+ }), /* @__PURE__ */ jsx(AICardGlass, { onGenerate: onAIGenerate })]
4047
+ })
4048
+ });
4049
+ });
4050
+ ProfileHeaderGlass.displayName = "ProfileHeaderGlass";
4051
+ var ownershipOptions = [{
4052
+ value: "your",
4053
+ label: "Your"
4054
+ }, {
4055
+ value: "contrib",
4056
+ label: "Contrib"
4057
+ }];
4058
+ const ProjectsListGlass = forwardRef(({ repositories, showFlaggedOnly = false, selectedYear = null, onClearFilters, title, ownershipFilter, onOwnershipChange, sortBy = "commits", sortOrder = "desc", onSortChange, showControls, className, ...props }, ref) => {
4059
+ const [expandedIndex, setExpandedIndex] = useState(null);
4060
+ const shouldShowControls = showControls ?? (onOwnershipChange !== void 0 || onSortChange !== void 0);
4061
+ const filteredRepos = useMemo(() => {
4062
+ return repositories.filter((repo) => {
4063
+ if (showFlaggedOnly && repo.flagType === "green") return false;
4064
+ if (selectedYear && repo.createdYear !== selectedYear) return false;
4065
+ if (ownershipFilter && ownershipFilter !== "all" && repo.ownership !== ownershipFilter) return false;
4066
+ return true;
4067
+ });
4068
+ }, [
4069
+ repositories,
4070
+ showFlaggedOnly,
4071
+ selectedYear,
4072
+ ownershipFilter
4073
+ ]);
4074
+ const sortedRepos = useMemo(() => {
4075
+ if (!onSortChange) return filteredRepos;
4076
+ return [...filteredRepos].sort((a, b) => {
4077
+ const multiplier = sortOrder === "asc" ? 1 : -1;
4078
+ switch (sortBy) {
4079
+ case "commits": return (a.commits - b.commits) * multiplier;
4080
+ case "stars": return ((a.stars ?? 0) - (b.stars ?? 0)) * multiplier;
4081
+ case "name": return a.name.localeCompare(b.name) * multiplier;
4082
+ case "contribution": return (a.contribution - b.contribution) * multiplier;
4083
+ default: return 0;
4084
+ }
4085
+ });
4086
+ }, [
4087
+ filteredRepos,
4088
+ sortBy,
4089
+ sortOrder,
4090
+ onSortChange
4091
+ ]);
4092
+ const displayTitle = title ?? (showFlaggedOnly ? "Flagged" : selectedYear ? `${selectedYear}` : "All") + " Projects";
4093
+ const emptyContainerStyles = { background: "var(--card-bg)" };
4094
+ const handleOwnershipChange = (value) => {
4095
+ if (onOwnershipChange && (value === "your" || value === "contrib")) onOwnershipChange(value);
4096
+ };
4097
+ return /* @__PURE__ */ jsxs(GlassCard, {
4098
+ ref,
4099
+ intensity: "medium",
4100
+ className: cn("p-3 sm:p-4", className),
4101
+ ...props,
4102
+ children: [/* @__PURE__ */ jsxs("div", {
4103
+ className: "flex flex-col sm:flex-row sm:items-center sm:justify-between gap-3 mb-4",
4104
+ children: [/* @__PURE__ */ jsxs("div", {
4105
+ className: "flex items-center gap-2",
4106
+ children: [
4107
+ showFlaggedOnly ? /* @__PURE__ */ jsx(AlertTriangle, {
4108
+ className: "w-4 h-4",
4109
+ style: { color: "var(--status-away)" }
4110
+ }) : /* @__PURE__ */ jsx(FolderGit2, {
4111
+ className: "w-4 h-4",
4112
+ style: { color: "var(--text-accent)" }
4113
+ }),
4114
+ /* @__PURE__ */ jsx("h3", {
4115
+ className: "font-semibold text-sm sm:text-base",
4116
+ style: { color: "var(--text-primary)" },
4117
+ children: displayTitle
4118
+ }),
4119
+ /* @__PURE__ */ jsxs(BadgeGlass, {
4120
+ variant: "info",
4121
+ children: [sortedRepos.length, " repos"]
4122
+ })
4123
+ ]
4124
+ }), shouldShowControls && /* @__PURE__ */ jsxs("div", {
4125
+ className: "flex items-center gap-2 flex-wrap",
4126
+ children: [onSortChange && /* @__PURE__ */ jsx(SortDropdownGlass, {
4127
+ sortBy,
4128
+ sortOrder,
4129
+ onSortChange
4130
+ }), onOwnershipChange && ownershipFilter && /* @__PURE__ */ jsx(SegmentedControlGlass, {
4131
+ options: ownershipOptions,
4132
+ value: ownershipFilter,
4133
+ onChange: handleOwnershipChange
4134
+ })]
4135
+ })]
4136
+ }), sortedRepos.length === 0 ? /* @__PURE__ */ jsxs("div", {
4137
+ className: "text-center py-10",
4138
+ children: [
4139
+ /* @__PURE__ */ jsx("div", {
4140
+ className: "w-16 h-16 mx-auto mb-3 rounded-2xl flex items-center justify-center",
4141
+ style: emptyContainerStyles,
4142
+ children: /* @__PURE__ */ jsx(FolderGit2, {
4143
+ className: "w-8 h-8",
4144
+ style: { color: "var(--text-muted)" }
4145
+ })
4146
+ }),
4147
+ /* @__PURE__ */ jsx("p", {
4148
+ className: "text-sm",
4149
+ style: { color: "var(--text-muted)" },
4150
+ children: "No repositories found"
4151
+ }),
4152
+ onClearFilters && /* @__PURE__ */ jsx("button", {
4153
+ onClick: onClearFilters,
4154
+ className: "mt-2 text-sm underline transition-colors hover:opacity-80",
4155
+ style: { color: "var(--text-accent)" },
4156
+ children: "Clear filters"
4157
+ })
4158
+ ]
4159
+ }) : /* @__PURE__ */ jsx("div", {
4160
+ className: "space-y-2",
4161
+ children: sortedRepos.map((repo, index) => /* @__PURE__ */ jsx(RepositoryCardGlass, {
4162
+ name: repo.name,
4163
+ languages: repo.languages,
4164
+ commits: repo.commits,
4165
+ contribution: repo.contribution,
4166
+ stars: repo.stars,
4167
+ flagType: repo.flagType,
4168
+ issues: repo.issues,
4169
+ expanded: expandedIndex === index,
4170
+ onToggle: () => setExpandedIndex(expandedIndex === index ? null : index)
4171
+ }, repo.name))
4172
+ })]
4173
+ });
4174
+ });
4175
+ ProjectsListGlass.displayName = "ProjectsListGlass";
4176
+ const TrustScoreCardGlass = forwardRef(({ score = 72, metrics = [], className, ...props }, ref) => {
4177
+ return /* @__PURE__ */ jsxs(GlassCard, {
4178
+ ref,
4179
+ className: cn("p-4 md:p-5", className),
4180
+ intensity: "strong",
4181
+ glow: "cyan",
4182
+ hover: false,
4183
+ ...props,
4184
+ children: [
4185
+ /* @__PURE__ */ jsxs("div", {
4186
+ className: "flex items-center justify-between mb-3 md:mb-4",
4187
+ children: [/* @__PURE__ */ jsxs("h2", {
4188
+ className: "font-semibold flex items-center gap-1.5 md:gap-2 text-base md:text-lg",
4189
+ style: { color: "var(--text-primary)" },
4190
+ children: [/* @__PURE__ */ jsx(Target, {
4191
+ className: "w-4 h-4 md:w-5 md:h-5",
4192
+ style: { color: "var(--text-accent)" }
4193
+ }), "Overall Trust Score"]
4194
+ }), /* @__PURE__ */ jsxs("div", {
4195
+ className: "flex items-center gap-1.5 md:gap-2 animate-[score-pulse_2s_ease-in-out_infinite]",
4196
+ children: [/* @__PURE__ */ jsx("span", {
4197
+ className: "text-3xl md:text-4xl font-bold bg-clip-text text-transparent",
4198
+ style: { backgroundImage: "var(--score-gradient)" },
4199
+ children: score
4200
+ }), /* @__PURE__ */ jsx("span", {
4201
+ className: "text-lg md:text-xl",
4202
+ style: { color: "var(--text-muted)" },
4203
+ children: "/ 100"
4204
+ })]
4205
+ })]
4206
+ }),
4207
+ /* @__PURE__ */ jsx(RainbowProgressGlass, {
4208
+ value: score,
4209
+ size: "lg",
4210
+ showGlow: true
4211
+ }),
4212
+ metrics.length > 0 && /* @__PURE__ */ jsx("div", {
4213
+ className: "grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 gap-3 md:gap-4 mt-4 md:mt-5",
4214
+ children: metrics.map((m) => /* @__PURE__ */ jsx(MetricCardGlass, {
4215
+ title: m.title,
4216
+ value: m.value,
4217
+ variant: m.variant
4218
+ }, m.title))
4219
+ })
4220
+ ]
4221
+ });
4222
+ });
4223
+ TrustScoreCardGlass.displayName = "TrustScoreCardGlass";
4224
+ export { TabsTrigger as $, FlagAlertGlass as A, DropdownMenuGlassTrigger as At, IconButtonGlass as B, AvatarGlass as Bt, sparklineContainerVariants as C, DropdownMenuGlassRadioGroup as Ct, progressSizes as D, DropdownMenuGlassSub as Dt, ProgressGlass as E, DropdownMenuGlassShortcut as Et, SortDropdownGlass as F, CheckboxGlass as Ft, TooltipGlassSimple as G, statusSizes as Gt, TooltipGlass as H, AvatarGlassImage as Ht, SearchBoxGlass as I, ButtonGlass as It, toggleSizes as J, AlertGlassTitle as Jt, TooltipGlassTrigger as K, AlertGlass as Kt, InsightCardGlass as L, buttonGlassVariants as Lt, BaseProgressGlass as M, inputVariants as Mt, ThemeToggleGlass as N, CircularProgressGlass as Nt, ProfileAvatarGlass as O, DropdownMenuGlassSubContent as Ot, StatItemGlass as P, Checkbox as Pt, TabsList as Q, alertVariants as Qt, insightCardVariants as R, BadgeGlass as Rt, sparklineBarVariants as S, DropdownMenuGlassPortal as St, RainbowProgressGlass as T, DropdownMenuGlassSeparator as Tt, TooltipGlassContent as U, AvatarGlassSimple as Ut, ExpandableHeaderGlass as V, AvatarGlassFallback as Vt, TooltipGlassProvider as W, avatarSizes as Wt, TabsContent as X, FormFieldWrapper as Xt, Tabs as Y, InteractiveCard as Yt, TabsGlass as Z, TouchTarget as Zt, ContributionMetricsGlass as _, DropdownMenuGlassCheckboxItem as _t, HeaderBrandingGlass as a, PopoverGlassContent as at, AICardGlass as b, DropdownMenuGlassItem as bt, YearCardGlass as c, NotificationGlass as ct, TrustScoreDisplayGlass as d, modalSizes as dt, SliderGlass as et, RepositoryMetadataGlass as f, InputGlass as ft, MetricCardGlass as g, DropdownMenuGlass as gt, MetricsGridGlass as h, DropdownGlass as ht, HeaderNavGlass as i, PopoverGlassAnchor as it, StatusIndicatorGlass as j, ComboBoxGlass as jt, LanguageBarGlass as k, DropdownMenuGlassSubTrigger as kt, UserStatsLineGlass as l, notificationVariants as lt, RepositoryCardGlass as m, cardIntensity as mt, ProjectsListGlass as n, skeletonVariants as nt, FlagsSectionGlass as o, PopoverGlassLegacy as ot, RepositoryHeaderGlass as p, GlassCard as pt, ToggleGlass as q, AlertGlassDescription as qt, ProfileHeaderGlass as r, PopoverGlass as rt, CareerStatsGlass as s, PopoverGlassTrigger as st, TrustScoreCardGlass as t, SkeletonGlass as tt, UserInfoGlass as u, ModalGlass as ut, CircularMetricGlass as v, DropdownMenuGlassContent as vt, SegmentedControlGlass as w, DropdownMenuGlassRadioItem as wt, SparklineGlass as x, DropdownMenuGlassLabel as xt, CareerStatsHeaderGlass as y, DropdownMenuGlassGroup as yt, insightVariantConfig as z, badgeVariants as zt };
4225
+
4226
+ //# sourceMappingURL=trust-score-card-glass-EfMB5l5J.mjs.map