@devxcrew/react-ui 0.0.0-stage → 0.1.7

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 (326) hide show
  1. package/README.md +85 -2
  2. package/package.json +105 -4
  3. package/src/blocks/agent-chat-workspace/agent-chat-workspace.tsx +162 -0
  4. package/src/blocks/agent-chat-workspace/index.ts +2 -0
  5. package/src/blocks/agent-provider-settings/agent-provider-settings.tsx +183 -0
  6. package/src/blocks/agent-provider-settings/index.ts +2 -0
  7. package/src/blocks/agent-task-workspace/agent-task-workspace.tsx +48 -0
  8. package/src/blocks/agent-task-workspace/index.ts +2 -0
  9. package/src/blocks/analysis-context/analysis-context.tsx +6 -0
  10. package/src/blocks/analysis-context/index.ts +1 -0
  11. package/src/blocks/app-header/app-header.tsx +159 -0
  12. package/src/blocks/app-header/index.ts +2 -0
  13. package/src/blocks/archived-chat-workspace/archived-chat-workspace.tsx +29 -0
  14. package/src/blocks/archived-chat-workspace/index.ts +2 -0
  15. package/src/blocks/auth/README.md +32 -0
  16. package/src/blocks/auth/admin-login-page.tsx +15 -0
  17. package/src/blocks/auth/admin-password-forgot-page.tsx +5 -0
  18. package/src/blocks/auth/auth-page-layout.tsx +90 -0
  19. package/src/blocks/auth/client-login-page.tsx +20 -0
  20. package/src/blocks/auth/client-password-forgot-page.tsx +5 -0
  21. package/src/blocks/auth/identity-management-desk.tsx +530 -0
  22. package/src/blocks/auth/index.ts +12 -0
  23. package/src/blocks/auth/login-page.tsx +206 -0
  24. package/src/blocks/auth/password-forgot-page.tsx +60 -0
  25. package/src/blocks/auth/portal-pages.tsx +32 -0
  26. package/src/blocks/auth/privileged-desk.tsx +55 -0
  27. package/src/blocks/auth/register-page.tsx +117 -0
  28. package/src/blocks/auth/session-boundary.tsx +296 -0
  29. package/src/blocks/auth/super-admin-login-page.tsx +15 -0
  30. package/src/blocks/auth/super-admin-password-forgot-page.tsx +5 -0
  31. package/src/blocks/blog/blog-card.tsx +156 -0
  32. package/src/blocks/blog/blog-reader.tsx +175 -0
  33. package/src/blocks/blog/blog-types.ts +47 -0
  34. package/src/blocks/blog/index.ts +3 -0
  35. package/src/blocks/chat-composer/chat-composer.tsx +140 -0
  36. package/src/blocks/chat-composer/index.ts +1 -0
  37. package/src/blocks/chat-history/chat-history.tsx +59 -0
  38. package/src/blocks/chat-history/index.ts +1 -0
  39. package/src/blocks/chat-response-progress/chat-response-progress.tsx +34 -0
  40. package/src/blocks/chat-response-progress/index.ts +2 -0
  41. package/src/blocks/chat-runtime-controls/chat-runtime-controls.tsx +56 -0
  42. package/src/blocks/chat-runtime-controls/index.ts +2 -0
  43. package/src/blocks/chat-runtime-trace/chat-runtime-trace.tsx +71 -0
  44. package/src/blocks/chat-runtime-trace/index.ts +2 -0
  45. package/src/blocks/codex-connection-settings/codex-connection-settings.tsx +42 -0
  46. package/src/blocks/codex-connection-settings/index.ts +1 -0
  47. package/src/blocks/dropzone/dropzone-file-item.tsx +113 -0
  48. package/src/blocks/dropzone/dropzone-types.ts +32 -0
  49. package/src/blocks/dropzone/dropzone.tsx +216 -0
  50. package/src/blocks/dropzone/index.ts +3 -0
  51. package/src/blocks/ecommerce/cart/cart-drawer.tsx +228 -0
  52. package/src/blocks/ecommerce/cart/cart-types.ts +27 -0
  53. package/src/blocks/ecommerce/cart/index.ts +2 -0
  54. package/src/blocks/ecommerce/categories/categories-types.ts +23 -0
  55. package/src/blocks/ecommerce/categories/category-showcase.tsx +125 -0
  56. package/src/blocks/ecommerce/categories/index.ts +2 -0
  57. package/src/blocks/ecommerce/checkout/checkout-types.ts +48 -0
  58. package/src/blocks/ecommerce/checkout/checkout-wizard.tsx +468 -0
  59. package/src/blocks/ecommerce/checkout/index.ts +2 -0
  60. package/src/blocks/ecommerce/comparison/comparison-types.ts +28 -0
  61. package/src/blocks/ecommerce/comparison/index.ts +2 -0
  62. package/src/blocks/ecommerce/comparison/product-comparison.tsx +174 -0
  63. package/src/blocks/ecommerce/coupon-wallet/coupon-wallet-types.ts +21 -0
  64. package/src/blocks/ecommerce/coupon-wallet/coupon-wallet.tsx +154 -0
  65. package/src/blocks/ecommerce/coupon-wallet/index.ts +2 -0
  66. package/src/blocks/ecommerce/delivery-tracker/delivery-tracker-types.ts +20 -0
  67. package/src/blocks/ecommerce/delivery-tracker/delivery-tracker.tsx +169 -0
  68. package/src/blocks/ecommerce/delivery-tracker/index.ts +2 -0
  69. package/src/blocks/ecommerce/index.ts +12 -0
  70. package/src/blocks/ecommerce/payment-methods/index.ts +2 -0
  71. package/src/blocks/ecommerce/payment-methods/payment-method-selector.tsx +224 -0
  72. package/src/blocks/ecommerce/payment-methods/payment-methods-types.ts +21 -0
  73. package/src/blocks/ecommerce/price-history/index.ts +2 -0
  74. package/src/blocks/ecommerce/price-history/price-history-chart.tsx +217 -0
  75. package/src/blocks/ecommerce/price-history/price-history-types.ts +16 -0
  76. package/src/blocks/ecommerce/reviews/index.ts +2 -0
  77. package/src/blocks/ecommerce/reviews/reviews-section.tsx +309 -0
  78. package/src/blocks/ecommerce/reviews/reviews-types.ts +26 -0
  79. package/src/blocks/ecommerce/wishlist/index.ts +2 -0
  80. package/src/blocks/ecommerce/wishlist/wishlist-grid.tsx +149 -0
  81. package/src/blocks/ecommerce/wishlist/wishlist-types.ts +19 -0
  82. package/src/blocks/execution-status/README.md +25 -0
  83. package/src/blocks/execution-status/execution-status.tsx +135 -0
  84. package/src/blocks/execution-status/index.ts +2 -0
  85. package/src/blocks/file-tree/file-icons.tsx +84 -0
  86. package/src/blocks/file-tree/file-tree-node.tsx +158 -0
  87. package/src/blocks/file-tree/file-tree-types.ts +33 -0
  88. package/src/blocks/file-tree/file-tree.tsx +163 -0
  89. package/src/blocks/file-tree/index.ts +5 -0
  90. package/src/blocks/filter-builder/filter-builder.tsx +169 -0
  91. package/src/blocks/filter-builder/filter-row.tsx +164 -0
  92. package/src/blocks/filter-builder/filter-types.ts +61 -0
  93. package/src/blocks/filter-builder/index.ts +12 -0
  94. package/src/blocks/footer/footer-types.ts +35 -0
  95. package/src/blocks/footer/index.ts +2 -0
  96. package/src/blocks/footer/site-footer.tsx +212 -0
  97. package/src/blocks/form/form-block.tsx +113 -0
  98. package/src/blocks/form/form-lookup-field.tsx +60 -0
  99. package/src/blocks/form/index.ts +4 -0
  100. package/src/blocks/handover-stack/handover-stack.tsx +41 -0
  101. package/src/blocks/handover-stack/index.ts +1 -0
  102. package/src/blocks/idea-handover/idea-handover-readiness.ts +41 -0
  103. package/src/blocks/idea-handover/idea-handover-workspace.tsx +150 -0
  104. package/src/blocks/idea-handover/index.ts +4 -0
  105. package/src/blocks/kanban/index.ts +11 -0
  106. package/src/blocks/kanban/kanban-board.tsx +146 -0
  107. package/src/blocks/kanban/kanban-card.tsx +149 -0
  108. package/src/blocks/kanban/kanban-column.tsx +102 -0
  109. package/src/blocks/kanban/kanban-types.ts +38 -0
  110. package/src/blocks/loader/global-loader.tsx +90 -0
  111. package/src/blocks/loader/index.ts +1 -0
  112. package/src/blocks/mascot/README.md +21 -0
  113. package/src/blocks/mascot/index.ts +2 -0
  114. package/src/blocks/mascot/mascot.tsx +202 -0
  115. package/src/blocks/master-list/README.md +21 -0
  116. package/src/blocks/master-list/index.ts +12 -0
  117. package/src/blocks/master-list/master-form.tsx +157 -0
  118. package/src/blocks/master-list/master-list-desk.tsx +370 -0
  119. package/src/blocks/master-list/master-list.tsx +189 -0
  120. package/src/blocks/master-list/types.ts +18 -0
  121. package/src/blocks/mermaid-preview/index.ts +1 -0
  122. package/src/blocks/mermaid-preview/mermaid-preview.tsx +164 -0
  123. package/src/blocks/notifications/README.md +7 -0
  124. package/src/blocks/notifications/index.ts +1 -0
  125. package/src/blocks/notifications/notification-center-page.tsx +73 -0
  126. package/src/blocks/pricing/index.ts +7 -0
  127. package/src/blocks/pricing/pricing-table.tsx +173 -0
  128. package/src/blocks/pricing/pricing-types.ts +34 -0
  129. package/src/blocks/product-card/index.ts +2 -0
  130. package/src/blocks/product-card/product-card-types.ts +35 -0
  131. package/src/blocks/product-card/product-card.tsx +183 -0
  132. package/src/blocks/table/data-table-block.tsx +313 -0
  133. package/src/blocks/table/data-table-filter-menu.tsx +48 -0
  134. package/src/blocks/table/data-table-icon-menu-trigger.tsx +44 -0
  135. package/src/blocks/table/data-table-menu-content.tsx +32 -0
  136. package/src/blocks/table/data-table-pagination.tsx +149 -0
  137. package/src/blocks/table/data-table-row-actions.tsx +53 -0
  138. package/src/blocks/table/data-table-status.tsx +42 -0
  139. package/src/blocks/table/data-table-toolbar.tsx +124 -0
  140. package/src/blocks/table/data-table-totals.tsx +31 -0
  141. package/src/blocks/table/index.ts +13 -0
  142. package/src/blocks/workspace/index.ts +19 -0
  143. package/src/blocks/workspace/workspace-action-card.tsx +73 -0
  144. package/src/blocks/workspace/workspace-application-header.tsx +67 -0
  145. package/src/blocks/workspace/workspace-entity-card.tsx +48 -0
  146. package/src/blocks/workspace/workspace-health-summary.tsx +15 -0
  147. package/src/blocks/workspace/workspace-metric-card.tsx +97 -0
  148. package/src/blocks/workspace/workspace-page-header.tsx +43 -0
  149. package/src/blocks/workspace/workspace-publish-status.tsx +15 -0
  150. package/src/blocks/workspace/workspace-route-checklist.tsx +28 -0
  151. package/src/blocks/workspace/workspace-runtime-status.tsx +48 -0
  152. package/src/blocks/workspace/workspace-section-card.tsx +42 -0
  153. package/src/components/accordion.tsx +65 -0
  154. package/src/components/alert-dialog.tsx +160 -0
  155. package/src/components/alert.tsx +68 -0
  156. package/src/components/aspect-ratio.tsx +22 -0
  157. package/src/components/attachment.tsx +195 -0
  158. package/src/components/avatar.tsx +90 -0
  159. package/src/components/badge.tsx +55 -0
  160. package/src/components/breadcrumb.tsx +100 -0
  161. package/src/components/bubble.tsx +123 -0
  162. package/src/components/button-group.tsx +79 -0
  163. package/src/components/button.tsx +71 -0
  164. package/src/components/calendar.tsx +185 -0
  165. package/src/components/card.tsx +100 -0
  166. package/src/components/carousel.tsx +229 -0
  167. package/src/components/chart.tsx +338 -0
  168. package/src/components/checkbox.tsx +27 -0
  169. package/src/components/collapsible.tsx +15 -0
  170. package/src/components/combobox.tsx +269 -0
  171. package/src/components/command.tsx +181 -0
  172. package/src/components/compact-model-switcher.tsx +128 -0
  173. package/src/components/context-menu.tsx +244 -0
  174. package/src/components/dialog.tsx +138 -0
  175. package/src/components/direction.tsx +1 -0
  176. package/src/components/drawer.tsx +208 -0
  177. package/src/components/dropdown-menu.tsx +257 -0
  178. package/src/components/empty.tsx +93 -0
  179. package/src/components/field.tsx +232 -0
  180. package/src/components/hover-card.tsx +45 -0
  181. package/src/components/input-group.tsx +146 -0
  182. package/src/components/input-otp.tsx +83 -0
  183. package/src/components/input.tsx +19 -0
  184. package/src/components/item.tsx +188 -0
  185. package/src/components/kbd.tsx +26 -0
  186. package/src/components/label.tsx +17 -0
  187. package/src/components/markdown-content.tsx +113 -0
  188. package/src/components/marker.tsx +67 -0
  189. package/src/components/menubar.tsx +267 -0
  190. package/src/components/message-scroller.tsx +91 -0
  191. package/src/components/message.tsx +84 -0
  192. package/src/components/native-select.tsx +54 -0
  193. package/src/components/navigation-menu.tsx +160 -0
  194. package/src/components/pagination.tsx +118 -0
  195. package/src/components/popover.tsx +74 -0
  196. package/src/components/progress.tsx +82 -0
  197. package/src/components/questionnaire.tsx +150 -0
  198. package/src/components/radio-group.tsx +35 -0
  199. package/src/components/resizable.tsx +41 -0
  200. package/src/components/rich-text-editor.tsx +604 -0
  201. package/src/components/scroll-area.tsx +47 -0
  202. package/src/components/select.tsx +189 -0
  203. package/src/components/separator.tsx +18 -0
  204. package/src/components/sheet.tsx +125 -0
  205. package/src/components/sidebar.tsx +693 -0
  206. package/src/components/skeleton.tsx +13 -0
  207. package/src/components/slider.tsx +51 -0
  208. package/src/components/sonner.tsx +45 -0
  209. package/src/components/sparkline.tsx +231 -0
  210. package/src/components/spinner.tsx +20 -0
  211. package/src/components/status-badge.tsx +114 -0
  212. package/src/components/switch.tsx +31 -0
  213. package/src/components/table.tsx +91 -0
  214. package/src/components/tabs.tsx +72 -0
  215. package/src/components/textarea.tsx +17 -0
  216. package/src/components/toast.tsx +222 -0
  217. package/src/components/toggle-group.tsx +85 -0
  218. package/src/components/toggle.tsx +42 -0
  219. package/src/components/tooltip.tsx +53 -0
  220. package/src/design-system/README.md +55 -0
  221. package/src/design-system/action-intents.ts +21 -0
  222. package/src/design-system/agent-manifest.ts +83 -0
  223. package/src/design-system/block-registry.ts +272 -0
  224. package/src/design-system/component-registry.ts +142 -0
  225. package/src/design-system/contracts.ts +69 -0
  226. package/src/design-system/defaults.ts +3 -0
  227. package/src/design-system/index.ts +29 -0
  228. package/src/design-system/mcp-server.ts +156 -0
  229. package/src/design-system/page-registry.ts +74 -0
  230. package/src/design-system/selection.ts +67 -0
  231. package/src/design-system/template-registry.ts +33 -0
  232. package/src/features/interface-topology/index.ts +14 -0
  233. package/src/features/interface-topology/interface-topology.types.ts +40 -0
  234. package/src/features/interface-topology/topology-control.tsx +18 -0
  235. package/src/features/interface-topology/topology-inspector.tsx +228 -0
  236. package/src/features/interface-topology/topology-marker.tsx +47 -0
  237. package/src/features/interface-topology/topology-region.tsx +44 -0
  238. package/src/features/interface-topology/use-interface-topology.ts +178 -0
  239. package/src/hooks/use-mobile.ts +19 -0
  240. package/src/hooks/use-scroll-follow.ts +22 -0
  241. package/src/index.ts +11 -0
  242. package/src/layouts/README.md +65 -0
  243. package/src/layouts/agent-workspace/agent-activity-rail.tsx +101 -0
  244. package/src/layouts/agent-workspace/agent-workspace.tsx +27 -0
  245. package/src/layouts/agent-workspace/agent-workspace.types.ts +28 -0
  246. package/src/layouts/agent-workspace/index.ts +7 -0
  247. package/src/layouts/blog-header/blog-header-types.ts +25 -0
  248. package/src/layouts/blog-header/blog-header.tsx +172 -0
  249. package/src/layouts/blog-header/index.ts +2 -0
  250. package/src/layouts/documentation-workspace/README.md +8 -0
  251. package/src/layouts/documentation-workspace/documentation-workspace.tsx +34 -0
  252. package/src/layouts/documentation-workspace/index.ts +1 -0
  253. package/src/layouts/ecommerce-header/ecommerce-actions.tsx +89 -0
  254. package/src/layouts/ecommerce-header/ecommerce-announcement.tsx +43 -0
  255. package/src/layouts/ecommerce-header/ecommerce-drawer.tsx +97 -0
  256. package/src/layouts/ecommerce-header/ecommerce-header-types.ts +59 -0
  257. package/src/layouts/ecommerce-header/ecommerce-header.tsx +47 -0
  258. package/src/layouts/ecommerce-header/ecommerce-navigation.tsx +98 -0
  259. package/src/layouts/ecommerce-header/ecommerce-search.tsx +86 -0
  260. package/src/layouts/ecommerce-header/index.ts +2 -0
  261. package/src/layouts/main-workspace/index.ts +28 -0
  262. package/src/layouts/mdi/index.ts +1 -0
  263. package/src/layouts/mdi/mdi.tsx +20 -0
  264. package/src/layouts/mdi-main/index.ts +27 -0
  265. package/src/layouts/mdi-main/mdi-app-catalog.generated.ts +159 -0
  266. package/src/layouts/mdi-main/mdi-app-catalog.ts +76 -0
  267. package/src/layouts/mdi-main/mdi-app-switcher.tsx +107 -0
  268. package/src/layouts/mdi-main/mdi-feature-settings.tsx +135 -0
  269. package/src/layouts/mdi-main/mdi-global-search.tsx +192 -0
  270. package/src/layouts/mdi-main/mdi-main.tsx +241 -0
  271. package/src/layouts/mdi-main/mdi-notifications-menu.tsx +197 -0
  272. package/src/layouts/mdi-main/mdi-profile-menu.tsx +79 -0
  273. package/src/layouts/mdi-main/mdi-sidebar-navigation.tsx +226 -0
  274. package/src/layouts/mdi-main/mdi-sidebar.tsx +110 -0
  275. package/src/layouts/mdi-main/mdi-status-bar.tsx +26 -0
  276. package/src/layouts/mdi-main/mdi-top-menu-control.ts +4 -0
  277. package/src/layouts/mdi-main/mdi-top-menu.tsx +117 -0
  278. package/src/layouts/mdi-main/mdi-topology.tsx +297 -0
  279. package/src/layouts/mdi-main/mdi-tweak-panel.tsx +104 -0
  280. package/src/layouts/mdi-main/mdi-types.ts +131 -0
  281. package/src/layouts/mdi-main/use-mdi-features.ts +36 -0
  282. package/src/layouts/mdi-main/use-mdi-sidebar-state.ts +59 -0
  283. package/src/layouts/site-header/announcement-bar.tsx +55 -0
  284. package/src/layouts/site-header/category-strip.tsx +41 -0
  285. package/src/layouts/site-header/index.ts +16 -0
  286. package/src/layouts/site-header/main-navbar.tsx +179 -0
  287. package/src/layouts/site-header/mobile-drawer.tsx +140 -0
  288. package/src/layouts/site-header/site-header-types.ts +63 -0
  289. package/src/layouts/site-header/site-header.tsx +58 -0
  290. package/src/lib/random-id.ts +19 -0
  291. package/src/lib/utils.ts +6 -0
  292. package/src/providers/pdf-provider.ts +137 -0
  293. package/src/styles/globals.css +374 -0
  294. package/src/templates/README.md +12 -0
  295. package/src/templates/dashboard-01/components/app-sidebar.tsx +177 -0
  296. package/src/templates/dashboard-01/components/chart-area-interactive.tsx +276 -0
  297. package/src/templates/dashboard-01/components/data-table-cell-viewer.tsx +213 -0
  298. package/src/templates/dashboard-01/components/data-table.tsx +577 -0
  299. package/src/templates/dashboard-01/components/nav-documents.tsx +79 -0
  300. package/src/templates/dashboard-01/components/nav-main.tsx +55 -0
  301. package/src/templates/dashboard-01/components/nav-secondary.tsx +39 -0
  302. package/src/templates/dashboard-01/components/nav-user.tsx +97 -0
  303. package/src/templates/dashboard-01/components/section-cards.tsx +99 -0
  304. package/src/templates/dashboard-01/components/site-header.tsx +14 -0
  305. package/src/templates/dashboard-01/data.json +614 -0
  306. package/src/templates/dashboard-01/index.ts +7 -0
  307. package/src/templates/documentation-sidebar/app-sidebar.tsx +95 -0
  308. package/src/templates/documentation-sidebar/index.ts +2 -0
  309. package/src/templates/sidebar-07/components/app-sidebar.tsx +175 -0
  310. package/src/templates/sidebar-07/components/nav-main.tsx +64 -0
  311. package/src/templates/sidebar-07/components/nav-projects.tsx +79 -0
  312. package/src/templates/sidebar-07/components/nav-user.tsx +105 -0
  313. package/src/templates/sidebar-07/components/team-switcher.tsx +94 -0
  314. package/src/templates/sidebar-07/index.ts +1 -0
  315. package/src/templates/ui-page/index.ts +7 -0
  316. package/src/templates/ui-page/ui-browser-frame.tsx +27 -0
  317. package/src/templates/ui-page/ui-template-code.tsx +48 -0
  318. package/src/templates/ui-page/ui-template-header.tsx +87 -0
  319. package/src/templates/ui-page/ui-template-navigation.tsx +60 -0
  320. package/src/templates/ui-page/ui-template-page.tsx +97 -0
  321. package/src/theme/index.ts +12 -0
  322. package/src/theme/theme-config.ts +30 -0
  323. package/src/theme/theme-provider.tsx +142 -0
  324. package/src/theme/theme-selector.tsx +75 -0
  325. package/src/tokens/index.ts +15 -0
  326. package/src/vite-env.d.ts +3 -0
@@ -0,0 +1,100 @@
1
+ import * as React from 'react'
2
+ import { mergeProps } from '@base-ui/react/merge-props'
3
+ import { useRender } from '@base-ui/react/use-render'
4
+ import { cn } from '../lib/utils'
5
+ import { ChevronRightIcon, MoreHorizontalIcon } from 'lucide-react'
6
+
7
+ function Breadcrumb({ className, ...props }: React.ComponentProps<'nav'>) {
8
+ return <nav aria-label="breadcrumb" data-slot="breadcrumb" className={cn(className)} {...props} />
9
+ }
10
+
11
+ function BreadcrumbList({ className, ...props }: React.ComponentProps<'ol'>) {
12
+ return (
13
+ <ol
14
+ data-slot="breadcrumb-list"
15
+ className={cn(
16
+ 'flex flex-wrap items-center gap-1.5 text-sm wrap-break-word text-muted-foreground',
17
+ className,
18
+ )}
19
+ {...props}
20
+ />
21
+ )
22
+ }
23
+
24
+ function BreadcrumbItem({ className, ...props }: React.ComponentProps<'li'>) {
25
+ return (
26
+ <li
27
+ data-slot="breadcrumb-item"
28
+ className={cn('inline-flex items-center gap-1', className)}
29
+ {...props}
30
+ />
31
+ )
32
+ }
33
+
34
+ function BreadcrumbLink({ className, render, ...props }: useRender.ComponentProps<'a'>) {
35
+ return useRender({
36
+ defaultTagName: 'a',
37
+ props: mergeProps<'a'>(
38
+ {
39
+ className: cn('transition-colors hover:text-foreground', className),
40
+ },
41
+ props,
42
+ ),
43
+ render,
44
+ state: {
45
+ slot: 'breadcrumb-link',
46
+ },
47
+ })
48
+ }
49
+
50
+ function BreadcrumbPage({ className, ...props }: React.ComponentProps<'span'>) {
51
+ return (
52
+ <span
53
+ data-slot="breadcrumb-page"
54
+ role="link"
55
+ aria-disabled="true"
56
+ aria-current="page"
57
+ className={cn('font-normal text-foreground', className)}
58
+ {...props}
59
+ />
60
+ )
61
+ }
62
+
63
+ function BreadcrumbSeparator({ children, className, ...props }: React.ComponentProps<'li'>) {
64
+ return (
65
+ <li
66
+ data-slot="breadcrumb-separator"
67
+ role="presentation"
68
+ aria-hidden="true"
69
+ className={cn('[&>svg]:size-3.5', className)}
70
+ {...props}
71
+ >
72
+ {children ?? <ChevronRightIcon />}
73
+ </li>
74
+ )
75
+ }
76
+
77
+ function BreadcrumbEllipsis({ className, ...props }: React.ComponentProps<'span'>) {
78
+ return (
79
+ <span
80
+ data-slot="breadcrumb-ellipsis"
81
+ role="presentation"
82
+ aria-hidden="true"
83
+ className={cn('flex size-5 items-center justify-center [&>svg]:size-4', className)}
84
+ {...props}
85
+ >
86
+ <MoreHorizontalIcon />
87
+ <span className="sr-only">More</span>
88
+ </span>
89
+ )
90
+ }
91
+
92
+ export {
93
+ Breadcrumb,
94
+ BreadcrumbList,
95
+ BreadcrumbItem,
96
+ BreadcrumbLink,
97
+ BreadcrumbPage,
98
+ BreadcrumbSeparator,
99
+ BreadcrumbEllipsis,
100
+ }
@@ -0,0 +1,123 @@
1
+ import * as React from 'react'
2
+ import { mergeProps } from '@base-ui/react/merge-props'
3
+ import { useRender } from '@base-ui/react/use-render'
4
+ import { cva, type VariantProps } from 'class-variance-authority'
5
+ import { cn } from '../lib/utils'
6
+
7
+ function BubbleGroup({ className, ...props }: React.ComponentProps<'div'>) {
8
+ return (
9
+ <div
10
+ data-slot="bubble-group"
11
+ className={cn('flex min-w-0 flex-col gap-2', className)}
12
+ {...props}
13
+ />
14
+ )
15
+ }
16
+
17
+ const bubbleVariants = cva(
18
+ 'group/bubble relative flex w-fit max-w-[80%] min-w-0 flex-col gap-1 group-data-[align=end]/message:self-end data-[align=end]:self-end data-[variant=ghost]:max-w-full',
19
+ {
20
+ variants: {
21
+ variant: {
22
+ default:
23
+ '*:data-[slot=bubble-content]:bg-primary *:data-[slot=bubble-content]:text-primary-foreground [&>[data-slot=bubble-content]:is(button,a):hover]:bg-primary/80',
24
+ secondary:
25
+ '*:data-[slot=bubble-content]:bg-secondary *:data-[slot=bubble-content]:text-secondary-foreground [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)]',
26
+ muted:
27
+ '*:data-[slot=bubble-content]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[color-mix(in_oklch,var(--muted),var(--foreground)_5%)]',
28
+ tinted:
29
+ '*:data-[slot=bubble-content]:bg-[oklch(from_var(--primary)_0.93_calc(c*0.4)_h)] *:data-[slot=bubble-content]:text-foreground dark:*:data-[slot=bubble-content]:bg-[oklch(from_var(--primary)_0.3_calc(c*0.4)_h)] [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[oklch(from_var(--primary)_0.88_calc(c*0.5)_h)] dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-[oklch(from_var(--primary)_0.35_calc(c*0.5)_h)]',
30
+ outline:
31
+ '*:data-[slot=bubble-content]:border-border *:data-[slot=bubble-content]:bg-background [&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:text-foreground dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-input/30',
32
+ ghost:
33
+ 'border-none *:data-[slot=bubble-content]:rounded-none *:data-[slot=bubble-content]:bg-transparent *:data-[slot=bubble-content]:p-0 [&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:text-foreground dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted/50',
34
+ destructive:
35
+ '*:data-[slot=bubble-content]:bg-destructive/10 *:data-[slot=bubble-content]:text-destructive dark:*:data-[slot=bubble-content]:bg-destructive/20 [&>[data-slot=bubble-content]:is(button,a):hover]:bg-destructive/20 dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-destructive/30',
36
+ },
37
+ },
38
+ defaultVariants: {
39
+ variant: 'default',
40
+ },
41
+ },
42
+ )
43
+
44
+ function Bubble({
45
+ variant = 'default',
46
+ align = 'start',
47
+ className,
48
+ ...props
49
+ }: React.ComponentProps<'div'> &
50
+ VariantProps<typeof bubbleVariants> & {
51
+ align?: 'start' | 'end'
52
+ }) {
53
+ return (
54
+ <div
55
+ data-slot="bubble"
56
+ data-variant={variant}
57
+ data-align={align}
58
+ className={cn(bubbleVariants({ variant }), className)}
59
+ {...props}
60
+ />
61
+ )
62
+ }
63
+
64
+ function BubbleContent({ className, render, ...props }: useRender.ComponentProps<'div'>) {
65
+ return useRender({
66
+ defaultTagName: 'div',
67
+ props: mergeProps<'div'>(
68
+ {
69
+ className: cn(
70
+ 'w-fit max-w-full min-w-0 overflow-hidden rounded-xl border border-transparent px-3 py-2 text-sm leading-relaxed wrap-break-word group-data-[align=end]/bubble:self-end [button]:text-left [button,a]:transition-colors [button,a]:outline-none [button,a]:focus-visible:border-ring [button,a]:focus-visible:ring-3 [button,a]:focus-visible:ring-ring/50',
71
+ className,
72
+ ),
73
+ },
74
+ props,
75
+ ),
76
+ render,
77
+ state: {
78
+ slot: 'bubble-content',
79
+ },
80
+ })
81
+ }
82
+
83
+ const bubbleReactionsVariants = cva(
84
+ 'absolute z-10 flex w-fit shrink-0 items-center justify-center gap-1 rounded-full bg-muted px-1.5 py-0.5 text-sm ring-3 ring-card has-[button]:p-0',
85
+ {
86
+ variants: {
87
+ side: {
88
+ top: 'top-0 -translate-y-3/4',
89
+ bottom: 'bottom-0 translate-y-3/4',
90
+ },
91
+ align: {
92
+ start: 'left-3',
93
+ end: 'right-3',
94
+ },
95
+ },
96
+ defaultVariants: {
97
+ side: 'bottom',
98
+ align: 'end',
99
+ },
100
+ },
101
+ )
102
+
103
+ function BubbleReactions({
104
+ side = 'bottom',
105
+ align = 'end',
106
+ className,
107
+ ...props
108
+ }: React.ComponentProps<'div'> & {
109
+ align?: 'start' | 'end'
110
+ side?: 'top' | 'bottom'
111
+ }) {
112
+ return (
113
+ <div
114
+ data-slot="bubble-reactions"
115
+ data-align={align}
116
+ data-side={side}
117
+ className={cn(bubbleReactionsVariants({ side, align }), className)}
118
+ {...props}
119
+ />
120
+ )
121
+ }
122
+
123
+ export { BubbleGroup, Bubble, BubbleContent, BubbleReactions }
@@ -0,0 +1,79 @@
1
+ import { mergeProps } from '@base-ui/react/merge-props'
2
+ import { useRender } from '@base-ui/react/use-render'
3
+ import { cva, type VariantProps } from 'class-variance-authority'
4
+ import { cn } from '../lib/utils'
5
+ import { buttonGroupDefaultOrientation } from '../design-system/defaults'
6
+
7
+ import { Separator } from '@devxcrew/react-ui/components/separator'
8
+
9
+ const buttonGroupVariants = cva(
10
+ "flex w-fit items-stretch *:focus-visible:relative *:focus-visible:z-10 has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-lg [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1",
11
+ {
12
+ variants: {
13
+ orientation: {
14
+ horizontal:
15
+ '*:data-slot:rounded-r-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-r-lg! [&>[data-slot]~[data-slot]]:rounded-l-none [&>[data-slot]~[data-slot]]:border-l-0',
16
+ vertical:
17
+ 'flex-col *:data-slot:rounded-b-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-b-lg! [&>[data-slot]~[data-slot]]:rounded-t-none [&>[data-slot]~[data-slot]]:border-t-0',
18
+ },
19
+ },
20
+ defaultVariants: {
21
+ orientation: buttonGroupDefaultOrientation,
22
+ },
23
+ },
24
+ )
25
+
26
+ function ButtonGroup({
27
+ className,
28
+ orientation = buttonGroupDefaultOrientation,
29
+ ...props
30
+ }: React.ComponentProps<'div'> & VariantProps<typeof buttonGroupVariants>) {
31
+ return (
32
+ <div
33
+ role="group"
34
+ data-slot="button-group"
35
+ data-orientation={orientation}
36
+ className={cn(buttonGroupVariants({ orientation }), className)}
37
+ {...props}
38
+ />
39
+ )
40
+ }
41
+
42
+ function ButtonGroupText({ className, render, ...props }: useRender.ComponentProps<'div'>) {
43
+ return useRender({
44
+ defaultTagName: 'div',
45
+ props: mergeProps<'div'>(
46
+ {
47
+ className: cn(
48
+ "flex items-center gap-2 rounded-lg border bg-muted px-2.5 text-sm font-medium [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",
49
+ className,
50
+ ),
51
+ },
52
+ props,
53
+ ),
54
+ render,
55
+ state: {
56
+ slot: 'button-group-text',
57
+ },
58
+ })
59
+ }
60
+
61
+ function ButtonGroupSeparator({
62
+ className,
63
+ orientation = 'vertical',
64
+ ...props
65
+ }: React.ComponentProps<typeof Separator>) {
66
+ return (
67
+ <Separator
68
+ data-slot="button-group-separator"
69
+ orientation={orientation}
70
+ className={cn(
71
+ 'relative self-stretch bg-input data-horizontal:mx-px data-horizontal:w-auto data-vertical:my-px data-vertical:h-auto',
72
+ className,
73
+ )}
74
+ {...props}
75
+ />
76
+ )
77
+ }
78
+
79
+ export { ButtonGroup, ButtonGroupSeparator, ButtonGroupText, buttonGroupVariants }
@@ -0,0 +1,71 @@
1
+ import { Button as ButtonPrimitive } from '@base-ui/react/button'
2
+ import { cva, type VariantProps } from 'class-variance-authority'
3
+ import { cn } from '../lib/utils'
4
+ import { buttonDefaultSize, buttonDefaultVariant } from '../design-system/defaults'
5
+
6
+ const buttonVariants = cva(
7
+ "group/button inline-flex w-fit shrink-0 cursor-pointer items-center justify-center gap-2 rounded-md border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-[color,background-color,border-color,box-shadow,transform] duration-200 outline-none select-none hover:-translate-y-0.5 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:translate-y-0 disabled:pointer-events-none disabled:translate-y-0 disabled:opacity-50 motion-reduce:transform-none motion-reduce:transition-none aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
8
+ {
9
+ variants: {
10
+ variant: {
11
+ default: 'bg-primary text-primary-foreground hover:bg-primary/90',
12
+ primary: 'bg-primary text-primary-foreground hover:bg-primary/90',
13
+ neutral:
14
+ 'bg-neutral-600 text-white hover:bg-neutral-700 dark:bg-neutral-600 dark:text-white dark:hover:bg-neutral-500',
15
+ outline:
16
+ 'border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50',
17
+ secondary:
18
+ 'bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground',
19
+ ghost:
20
+ 'hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50',
21
+ success: 'bg-success text-success-foreground hover:bg-success/90',
22
+ warning: 'bg-warning text-warning-foreground hover:bg-warning/90',
23
+ info: 'bg-info text-info-foreground hover:bg-info/90',
24
+ destructive:
25
+ 'bg-destructive text-destructive-foreground hover:bg-destructive/90 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40',
26
+ link: 'text-primary underline-offset-4 hover:underline',
27
+ studio:
28
+ 'border-[#3a3b3f] bg-[#26282c] text-[#f3f4f6] hover:bg-[#32353a] hover:border-[#40434a] shadow-xs active:bg-[#191a1c]',
29
+ 'studio-ghost':
30
+ 'border-transparent text-[#8c8d8e] hover:bg-[#26282c] hover:text-[#f3f4f6]',
31
+ 'studio-active':
32
+ 'border-[#40434a] bg-[#191a1c] text-[#9cd2ae] font-medium shadow-xs',
33
+ 'studio-accent':
34
+ 'border-[#9cd2ae]/35 bg-[#9cd2ae]/15 text-[#9cd2ae] hover:bg-[#9cd2ae]/25 hover:border-[#9cd2ae]/50 font-medium',
35
+ },
36
+ size: {
37
+ default: 'h-10 px-5',
38
+ xs: "h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",
39
+ sm: "h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",
40
+ lg: 'h-11 px-6 text-base',
41
+ icon: 'size-10 p-0',
42
+ 'icon-xs':
43
+ "size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3",
44
+ 'icon-sm':
45
+ 'size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg',
46
+ 'icon-lg': 'size-11 p-0',
47
+ },
48
+ },
49
+ defaultVariants: {
50
+ variant: buttonDefaultVariant,
51
+ size: buttonDefaultSize,
52
+ },
53
+ },
54
+ )
55
+
56
+ function Button({
57
+ className,
58
+ variant = buttonDefaultVariant,
59
+ size = buttonDefaultSize,
60
+ ...props
61
+ }: ButtonPrimitive.Props & VariantProps<typeof buttonVariants>) {
62
+ return (
63
+ <ButtonPrimitive
64
+ data-slot="button"
65
+ className={cn(buttonVariants({ variant, size, className }))}
66
+ {...props}
67
+ />
68
+ )
69
+ }
70
+
71
+ export { Button, buttonVariants }
@@ -0,0 +1,185 @@
1
+ 'use client'
2
+
3
+ import * as React from 'react'
4
+ import { cn } from '../lib/utils'
5
+ import { DayPicker, getDefaultClassNames, type DayButton, type Locale } from 'react-day-picker'
6
+
7
+ import { Button, buttonVariants } from '@devxcrew/react-ui/components/button'
8
+ import { ChevronLeftIcon, ChevronRightIcon, ChevronDownIcon } from 'lucide-react'
9
+
10
+ function Calendar({
11
+ className,
12
+ classNames,
13
+ showOutsideDays = true,
14
+ captionLayout = 'label',
15
+ buttonVariant = 'ghost',
16
+ locale,
17
+ formatters,
18
+ components,
19
+ ...props
20
+ }: React.ComponentProps<typeof DayPicker> & {
21
+ buttonVariant?: React.ComponentProps<typeof Button>['variant']
22
+ }) {
23
+ const defaultClassNames = getDefaultClassNames()
24
+
25
+ return (
26
+ <DayPicker
27
+ showOutsideDays={showOutsideDays}
28
+ className={cn(
29
+ 'group/calendar bg-background p-2 [--cell-radius:var(--radius-md)] [--cell-size:--spacing(7)] in-data-[slot=card-content]:bg-transparent in-data-[slot=popover-content]:bg-transparent',
30
+ String.raw`rtl:**:[.rdp-button\_next>svg]:rotate-180`,
31
+ String.raw`rtl:**:[.rdp-button\_previous>svg]:rotate-180`,
32
+ className,
33
+ )}
34
+ captionLayout={captionLayout}
35
+ locale={locale}
36
+ formatters={{
37
+ formatMonthDropdown: (date) => date.toLocaleString(locale?.code, { month: 'short' }),
38
+ ...formatters,
39
+ }}
40
+ classNames={{
41
+ root: cn('w-fit', defaultClassNames.root),
42
+ months: cn('relative flex flex-col gap-4 md:flex-row', defaultClassNames.months),
43
+ month: cn('flex w-full flex-col gap-4', defaultClassNames.month),
44
+ nav: cn(
45
+ 'absolute inset-x-0 top-0 flex w-full items-center justify-between gap-1',
46
+ defaultClassNames.nav,
47
+ ),
48
+ button_previous: cn(
49
+ buttonVariants({ variant: buttonVariant }),
50
+ 'size-(--cell-size) p-0 select-none aria-disabled:opacity-50',
51
+ defaultClassNames.button_previous,
52
+ ),
53
+ button_next: cn(
54
+ buttonVariants({ variant: buttonVariant }),
55
+ 'size-(--cell-size) p-0 select-none aria-disabled:opacity-50',
56
+ defaultClassNames.button_next,
57
+ ),
58
+ month_caption: cn(
59
+ 'flex h-(--cell-size) w-full items-center justify-center px-(--cell-size)',
60
+ defaultClassNames.month_caption,
61
+ ),
62
+ dropdowns: cn(
63
+ 'flex h-(--cell-size) w-full items-center justify-center gap-1.5 text-sm font-medium',
64
+ defaultClassNames.dropdowns,
65
+ ),
66
+ dropdown_root: cn('relative rounded-(--cell-radius)', defaultClassNames.dropdown_root),
67
+ dropdown: cn('absolute inset-0 bg-popover opacity-0', defaultClassNames.dropdown),
68
+ caption_label: cn(
69
+ 'font-medium select-none',
70
+ captionLayout === 'label'
71
+ ? 'text-sm'
72
+ : 'flex items-center gap-1 rounded-(--cell-radius) text-sm [&>svg]:size-3.5 [&>svg]:text-muted-foreground',
73
+ defaultClassNames.caption_label,
74
+ ),
75
+ month_grid: cn('w-full border-collapse', defaultClassNames.month_grid),
76
+ weekdays: cn('flex', defaultClassNames.weekdays),
77
+ weekday: cn(
78
+ 'flex-1 rounded-(--cell-radius) text-[0.8rem] font-normal text-muted-foreground select-none',
79
+ defaultClassNames.weekday,
80
+ ),
81
+ week: cn('mt-2 flex w-full', defaultClassNames.week),
82
+ week_number_header: cn('w-(--cell-size) select-none', defaultClassNames.week_number_header),
83
+ week_number: cn(
84
+ 'text-[0.8rem] text-muted-foreground select-none',
85
+ defaultClassNames.week_number,
86
+ ),
87
+ day: cn(
88
+ 'group/day relative aspect-square h-full w-full rounded-(--cell-radius) p-0 text-center select-none [&:last-child[data-selected=true]_button]:rounded-r-(--cell-radius)',
89
+ props.showWeekNumber
90
+ ? '[&:nth-child(2)[data-selected=true]_button]:rounded-l-(--cell-radius)'
91
+ : '[&:first-child[data-selected=true]_button]:rounded-l-(--cell-radius)',
92
+ defaultClassNames.day,
93
+ ),
94
+ range_start: cn(
95
+ 'relative isolate z-0 rounded-l-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:right-0 after:w-4 after:bg-muted',
96
+ defaultClassNames.range_start,
97
+ ),
98
+ range_middle: cn('rounded-none', defaultClassNames.range_middle),
99
+ range_end: cn(
100
+ 'relative isolate z-0 rounded-r-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:left-0 after:w-4 after:bg-muted',
101
+ defaultClassNames.range_end,
102
+ ),
103
+ today: cn(
104
+ 'rounded-(--cell-radius) bg-muted text-foreground data-[selected=true]:rounded-none',
105
+ defaultClassNames.today,
106
+ ),
107
+ outside: cn(
108
+ 'text-muted-foreground aria-selected:text-muted-foreground',
109
+ defaultClassNames.outside,
110
+ ),
111
+ disabled: cn('text-muted-foreground opacity-50', defaultClassNames.disabled),
112
+ hidden: cn('invisible', defaultClassNames.hidden),
113
+ ...classNames,
114
+ }}
115
+ components={{
116
+ Root: ({ className, rootRef, ...props }) => {
117
+ return <div data-slot="calendar" ref={rootRef} className={cn(className)} {...props} />
118
+ },
119
+ Chevron: ({ className, orientation, ...props }) => {
120
+ if (orientation === 'left') {
121
+ return <ChevronLeftIcon className={cn('size-4', className)} {...props} />
122
+ }
123
+
124
+ if (orientation === 'right') {
125
+ return <ChevronRightIcon className={cn('size-4', className)} {...props} />
126
+ }
127
+
128
+ return <ChevronDownIcon className={cn('size-4', className)} {...props} />
129
+ },
130
+ DayButton: ({ ...props }) => <CalendarDayButton locale={locale} {...props} />,
131
+ WeekNumber: ({ children, ...props }) => {
132
+ return (
133
+ <td {...props}>
134
+ <div className="flex size-(--cell-size) items-center justify-center text-center">
135
+ {children}
136
+ </div>
137
+ </td>
138
+ )
139
+ },
140
+ ...components,
141
+ }}
142
+ {...props}
143
+ />
144
+ )
145
+ }
146
+
147
+ function CalendarDayButton({
148
+ className,
149
+ day,
150
+ modifiers,
151
+ locale,
152
+ ...props
153
+ }: React.ComponentProps<typeof DayButton> & { locale?: Partial<Locale> }) {
154
+ const defaultClassNames = getDefaultClassNames()
155
+
156
+ const ref = React.useRef<HTMLButtonElement>(null)
157
+ React.useEffect(() => {
158
+ if (modifiers.focused) ref.current?.focus()
159
+ }, [modifiers.focused])
160
+
161
+ return (
162
+ <Button
163
+ variant="ghost"
164
+ size="icon"
165
+ data-day={day.date.toLocaleDateString(locale?.code)}
166
+ data-selected-single={
167
+ modifiers.selected &&
168
+ !modifiers.range_start &&
169
+ !modifiers.range_end &&
170
+ !modifiers.range_middle
171
+ }
172
+ data-range-start={modifiers.range_start}
173
+ data-range-end={modifiers.range_end}
174
+ data-range-middle={modifiers.range_middle}
175
+ className={cn(
176
+ 'relative isolate z-10 flex aspect-square size-auto w-full min-w-(--cell-size) flex-col gap-1 border-0 leading-none font-normal group-data-[focused=true]/day:relative group-data-[focused=true]/day:z-10 group-data-[focused=true]/day:border-ring group-data-[focused=true]/day:ring-[3px] group-data-[focused=true]/day:ring-ring/50 data-[range-end=true]:rounded-(--cell-radius) data-[range-end=true]:rounded-r-(--cell-radius) data-[range-end=true]:bg-primary data-[range-end=true]:text-primary-foreground data-[range-middle=true]:rounded-none data-[range-middle=true]:bg-muted data-[range-middle=true]:text-foreground data-[range-start=true]:rounded-(--cell-radius) data-[range-start=true]:rounded-l-(--cell-radius) data-[range-start=true]:bg-primary data-[range-start=true]:text-primary-foreground data-[selected-single=true]:bg-primary data-[selected-single=true]:text-primary-foreground dark:hover:text-foreground [&>span]:text-xs [&>span]:opacity-70',
177
+ defaultClassNames.day,
178
+ className,
179
+ )}
180
+ {...props}
181
+ />
182
+ )
183
+ }
184
+
185
+ export { Calendar, CalendarDayButton }
@@ -0,0 +1,100 @@
1
+ import * as React from 'react'
2
+ import { cn } from '../lib/utils'
3
+
4
+ function Card({
5
+ className,
6
+ size = 'default',
7
+ variant = 'default',
8
+ ...props
9
+ }: React.ComponentProps<'div'> & {
10
+ size?: 'default' | 'sm';
11
+ variant?: 'default' | 'studio' | 'studio-surface';
12
+ }) {
13
+ const variantClasses =
14
+ variant === 'studio'
15
+ ? 'border border-[#3a3b3f] bg-[#191a1c] text-[#e2e3e5] ring-0 shadow-xs'
16
+ : variant === 'studio-surface'
17
+ ? 'border border-[#3a3b3f] bg-[#26282c] text-[#e2e3e5] ring-0 shadow-xs'
18
+ : 'bg-card text-card-foreground ring-1 ring-foreground/10';
19
+
20
+ return (
21
+ <div
22
+ data-slot="card"
23
+ data-size={size}
24
+ data-variant={variant}
25
+ className={cn(
26
+ 'group/card flex flex-col gap-(--card-spacing) overflow-hidden rounded-xl py-(--card-spacing) text-sm [--card-spacing:--spacing(4)] has-data-[slot=card-footer]:pb-0 has-[>img:first-child]:pt-0 data-[size=sm]:[--card-spacing:--spacing(3)] data-[size=sm]:has-data-[slot=card-footer]:pb-0 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl',
27
+ variantClasses,
28
+ className,
29
+ )}
30
+ {...props}
31
+ />
32
+ )
33
+ }
34
+
35
+ function CardHeader({ className, ...props }: React.ComponentProps<'div'>) {
36
+ return (
37
+ <div
38
+ data-slot="card-header"
39
+ className={cn(
40
+ 'group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-(--card-spacing) has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-(--card-spacing)',
41
+ className,
42
+ )}
43
+ {...props}
44
+ />
45
+ )
46
+ }
47
+
48
+ function CardTitle({ className, ...props }: React.ComponentProps<'div'>) {
49
+ return (
50
+ <div
51
+ data-slot="card-title"
52
+ className={cn(
53
+ 'text-base leading-snug font-medium group-data-[size=sm]/card:text-sm',
54
+ className,
55
+ )}
56
+ {...props}
57
+ />
58
+ )
59
+ }
60
+
61
+ function CardDescription({ className, ...props }: React.ComponentProps<'div'>) {
62
+ return (
63
+ <div
64
+ data-slot="card-description"
65
+ className={cn('text-sm text-muted-foreground', className)}
66
+ {...props}
67
+ />
68
+ )
69
+ }
70
+
71
+ function CardAction({ className, ...props }: React.ComponentProps<'div'>) {
72
+ return (
73
+ <div
74
+ data-slot="card-action"
75
+ className={cn('col-start-2 row-span-2 row-start-1 self-start justify-self-end', className)}
76
+ {...props}
77
+ />
78
+ )
79
+ }
80
+
81
+ function CardContent({ className, ...props }: React.ComponentProps<'div'>) {
82
+ return (
83
+ <div data-slot="card-content" className={cn('px-(--card-spacing)', className)} {...props} />
84
+ )
85
+ }
86
+
87
+ function CardFooter({ className, ...props }: React.ComponentProps<'div'>) {
88
+ return (
89
+ <div
90
+ data-slot="card-footer"
91
+ className={cn(
92
+ 'flex items-center rounded-b-xl border-t bg-muted/50 p-(--card-spacing)',
93
+ className,
94
+ )}
95
+ {...props}
96
+ />
97
+ )
98
+ }
99
+
100
+ export { Card, CardHeader, CardFooter, CardTitle, CardAction, CardDescription, CardContent }