@lark-apaas/coding-templates 0.1.3 → 0.1.4

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 (261) hide show
  1. package/package.json +2 -3
  2. package/template-vite-react/_gitignore +24 -0
  3. package/template-vite-react/client/index.html +13 -0
  4. package/template-vite-react/client/public/favicon.svg +1 -0
  5. package/template-vite-react/client/public/icons.svg +24 -0
  6. package/template-vite-react/client/src/api/index.ts +7 -0
  7. package/template-vite-react/client/src/app.tsx +17 -0
  8. package/{template-nextjs-static → template-vite-react/client}/src/components/header.tsx +5 -13
  9. package/template-vite-react/client/src/components/layout.tsx +13 -0
  10. package/template-vite-react/client/src/components/theme-provider.tsx +45 -0
  11. package/template-vite-react/client/src/components/ui/accordion.tsx +72 -0
  12. package/template-vite-react/client/src/components/ui/alert-dialog.tsx +187 -0
  13. package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/alert.tsx +15 -10
  14. package/template-vite-react/client/src/components/ui/aspect-ratio.tsx +22 -0
  15. package/template-vite-react/client/src/components/ui/avatar.tsx +109 -0
  16. package/template-vite-react/client/src/components/ui/badge.tsx +52 -0
  17. package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/breadcrumb.tsx +39 -23
  18. package/template-vite-react/client/src/components/ui/button.tsx +58 -0
  19. package/{template-nextjs-static → template-vite-react/client}/src/components/ui/calendar.tsx +43 -37
  20. package/template-vite-react/client/src/components/ui/card.tsx +103 -0
  21. package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/carousel.tsx +8 -7
  22. package/{template-nextjs-static → template-vite-react/client}/src/components/ui/chart.tsx +49 -35
  23. package/template-vite-react/client/src/components/ui/checkbox.tsx +29 -0
  24. package/template-vite-react/client/src/components/ui/collapsible.tsx +19 -0
  25. package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/command.tsx +40 -52
  26. package/template-vite-react/client/src/components/ui/context-menu.tsx +271 -0
  27. package/template-vite-react/client/src/components/ui/dialog.tsx +158 -0
  28. package/{template-nextjs-static → template-vite-react/client}/src/components/ui/drawer.tsx +9 -12
  29. package/template-vite-react/client/src/components/ui/dropdown-menu.tsx +268 -0
  30. package/template-vite-react/client/src/components/ui/hover-card.tsx +49 -0
  31. package/template-vite-react/client/src/components/ui/input-group.tsx +156 -0
  32. package/{template-nextjs-static → template-vite-react/client}/src/components/ui/input-otp.tsx +17 -7
  33. package/template-vite-react/client/src/components/ui/input.tsx +20 -0
  34. package/template-vite-react/client/src/components/ui/label.tsx +18 -0
  35. package/template-vite-react/client/src/components/ui/menubar.tsx +280 -0
  36. package/template-vite-react/client/src/components/ui/navigation-menu.tsx +168 -0
  37. package/{template-nextjs-static → template-vite-react/client}/src/components/ui/pagination.tsx +35 -32
  38. package/template-vite-react/client/src/components/ui/popover.tsx +90 -0
  39. package/template-vite-react/client/src/components/ui/progress.tsx +81 -0
  40. package/template-vite-react/client/src/components/ui/radio-group.tsx +38 -0
  41. package/template-vite-react/client/src/components/ui/resizable.tsx +48 -0
  42. package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/scroll-area.tsx +10 -13
  43. package/template-vite-react/client/src/components/ui/select.tsx +199 -0
  44. package/template-vite-react/client/src/components/ui/separator.tsx +25 -0
  45. package/template-vite-react/client/src/components/ui/sheet.tsx +138 -0
  46. package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/sidebar.tsx +156 -162
  47. package/{template-nextjs-static → template-vite-react/client}/src/components/ui/skeleton.tsx +1 -1
  48. package/template-vite-react/client/src/components/ui/slider.tsx +57 -0
  49. package/template-vite-react/client/src/components/ui/sonner.tsx +49 -0
  50. package/template-vite-react/client/src/components/ui/switch.tsx +30 -0
  51. package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/table.tsx +5 -5
  52. package/template-vite-react/client/src/components/ui/tabs.tsx +80 -0
  53. package/template-vite-react/client/src/components/ui/textarea.tsx +18 -0
  54. package/template-vite-react/client/src/components/ui/toggle-group.tsx +89 -0
  55. package/template-vite-react/client/src/components/ui/toggle.tsx +44 -0
  56. package/template-vite-react/client/src/components/ui/tooltip.tsx +64 -0
  57. package/template-vite-react/client/src/index.css +1 -0
  58. package/template-vite-react/client/src/main.tsx +13 -0
  59. package/template-vite-react/client/src/pages/home/index.tsx +12 -0
  60. package/template-vite-react/client/src/pages/not-found/index.tsx +11 -0
  61. package/template-vite-react/client/src/types/index.ts +1 -0
  62. package/{template-nextjs-static → template-vite-react}/components.json +2 -2
  63. package/template-vite-react/eslint.config.js +23 -0
  64. package/template-vite-react/package.json +58 -0
  65. package/template-vite-react/scripts/build.sh +40 -0
  66. package/template-vite-react/shared/types.ts +1 -0
  67. package/template-vite-react/tsconfig.app.json +33 -0
  68. package/template-vite-react/tsconfig.json +14 -0
  69. package/template-vite-react/tsconfig.node.json +26 -0
  70. package/template-vite-react/vite.config.ts +17 -0
  71. package/template-nextjs-fullstack/README.md +0 -169
  72. package/template-nextjs-fullstack/_env.local.example +0 -1
  73. package/template-nextjs-fullstack/_gitignore +0 -41
  74. package/template-nextjs-fullstack/components.json +0 -25
  75. package/template-nextjs-fullstack/drizzle.config.ts +0 -10
  76. package/template-nextjs-fullstack/eslint.config.js +0 -15
  77. package/template-nextjs-fullstack/next.config.ts +0 -5
  78. package/template-nextjs-fullstack/package.json +0 -85
  79. package/template-nextjs-fullstack/postcss.config.js +0 -8
  80. package/template-nextjs-fullstack/scripts/build.sh +0 -37
  81. package/template-nextjs-fullstack/src/app/favicon.ico +0 -0
  82. package/template-nextjs-fullstack/src/app/globals.css +0 -130
  83. package/template-nextjs-fullstack/src/app/layout.tsx +0 -24
  84. package/template-nextjs-fullstack/src/app/page.tsx +0 -69
  85. package/template-nextjs-fullstack/src/app/todos/actions.ts +0 -37
  86. package/template-nextjs-fullstack/src/app/todos/page.tsx +0 -26
  87. package/template-nextjs-fullstack/src/app/todos/todo-form.tsx +0 -27
  88. package/template-nextjs-fullstack/src/app/todos/todo-list.tsx +0 -44
  89. package/template-nextjs-fullstack/src/components/header.tsx +0 -32
  90. package/template-nextjs-fullstack/src/components/theme-provider.tsx +0 -8
  91. package/template-nextjs-fullstack/src/components/ui/README.md +0 -134
  92. package/template-nextjs-fullstack/src/components/ui/accordion.tsx +0 -66
  93. package/template-nextjs-fullstack/src/components/ui/alert-dialog.tsx +0 -157
  94. package/template-nextjs-fullstack/src/components/ui/aspect-ratio.tsx +0 -11
  95. package/template-nextjs-fullstack/src/components/ui/avatar.tsx +0 -53
  96. package/template-nextjs-fullstack/src/components/ui/badge.tsx +0 -42
  97. package/template-nextjs-fullstack/src/components/ui/button.tsx +0 -69
  98. package/template-nextjs-fullstack/src/components/ui/calendar.tsx +0 -213
  99. package/template-nextjs-fullstack/src/components/ui/card.tsx +0 -82
  100. package/template-nextjs-fullstack/src/components/ui/chart.tsx +0 -357
  101. package/template-nextjs-fullstack/src/components/ui/checkbox.tsx +0 -32
  102. package/template-nextjs-fullstack/src/components/ui/collapsible.tsx +0 -33
  103. package/template-nextjs-fullstack/src/components/ui/context-menu.tsx +0 -324
  104. package/template-nextjs-fullstack/src/components/ui/dialog.tsx +0 -143
  105. package/template-nextjs-fullstack/src/components/ui/drawer.tsx +0 -135
  106. package/template-nextjs-fullstack/src/components/ui/dropdown-menu.tsx +0 -329
  107. package/template-nextjs-fullstack/src/components/ui/hover-card.tsx +0 -44
  108. package/template-nextjs-fullstack/src/components/ui/input-group.tsx +0 -166
  109. package/template-nextjs-fullstack/src/components/ui/input-otp.tsx +0 -77
  110. package/template-nextjs-fullstack/src/components/ui/input.tsx +0 -21
  111. package/template-nextjs-fullstack/src/components/ui/label.tsx +0 -24
  112. package/template-nextjs-fullstack/src/components/ui/menubar.tsx +0 -348
  113. package/template-nextjs-fullstack/src/components/ui/navigation-menu.tsx +0 -168
  114. package/template-nextjs-fullstack/src/components/ui/pagination.tsx +0 -127
  115. package/template-nextjs-fullstack/src/components/ui/popover.tsx +0 -48
  116. package/template-nextjs-fullstack/src/components/ui/progress.tsx +0 -31
  117. package/template-nextjs-fullstack/src/components/ui/radio-group.tsx +0 -45
  118. package/template-nextjs-fullstack/src/components/ui/resizable.tsx +0 -56
  119. package/template-nextjs-fullstack/src/components/ui/select.tsx +0 -243
  120. package/template-nextjs-fullstack/src/components/ui/separator.tsx +0 -28
  121. package/template-nextjs-fullstack/src/components/ui/sheet.tsx +0 -139
  122. package/template-nextjs-fullstack/src/components/ui/skeleton.tsx +0 -13
  123. package/template-nextjs-fullstack/src/components/ui/slider.tsx +0 -87
  124. package/template-nextjs-fullstack/src/components/ui/sonner.tsx +0 -67
  125. package/template-nextjs-fullstack/src/components/ui/switch.tsx +0 -31
  126. package/template-nextjs-fullstack/src/components/ui/tabs.tsx +0 -66
  127. package/template-nextjs-fullstack/src/components/ui/textarea.tsx +0 -18
  128. package/template-nextjs-fullstack/src/components/ui/toggle-group.tsx +0 -83
  129. package/template-nextjs-fullstack/src/components/ui/toggle.tsx +0 -47
  130. package/template-nextjs-fullstack/src/components/ui/tooltip.tsx +0 -61
  131. package/template-nextjs-fullstack/src/db/index.ts +0 -8
  132. package/template-nextjs-fullstack/src/db/schema.ts +0 -11
  133. package/template-nextjs-fullstack/tailwind.config.ts +0 -10
  134. package/template-nextjs-fullstack/tsconfig.json +0 -34
  135. package/template-nextjs-static/README.md +0 -80
  136. package/template-nextjs-static/_gitignore +0 -41
  137. package/template-nextjs-static/eslint.config.js +0 -15
  138. package/template-nextjs-static/next.config.ts +0 -8
  139. package/template-nextjs-static/package.json +0 -77
  140. package/template-nextjs-static/postcss.config.js +0 -8
  141. package/template-nextjs-static/public/favicon.ico +0 -0
  142. package/template-nextjs-static/scripts/build.sh +0 -36
  143. package/template-nextjs-static/src/components/theme-provider.tsx +0 -6
  144. package/template-nextjs-static/src/components/ui/README.md +0 -134
  145. package/template-nextjs-static/src/components/ui/accordion.tsx +0 -66
  146. package/template-nextjs-static/src/components/ui/alert-dialog.tsx +0 -157
  147. package/template-nextjs-static/src/components/ui/alert.tsx +0 -71
  148. package/template-nextjs-static/src/components/ui/aspect-ratio.tsx +0 -11
  149. package/template-nextjs-static/src/components/ui/avatar.tsx +0 -53
  150. package/template-nextjs-static/src/components/ui/badge.tsx +0 -42
  151. package/template-nextjs-static/src/components/ui/breadcrumb.tsx +0 -109
  152. package/template-nextjs-static/src/components/ui/button-group.tsx +0 -83
  153. package/template-nextjs-static/src/components/ui/button.tsx +0 -69
  154. package/template-nextjs-static/src/components/ui/card.tsx +0 -82
  155. package/template-nextjs-static/src/components/ui/carousel.tsx +0 -241
  156. package/template-nextjs-static/src/components/ui/checkbox.tsx +0 -32
  157. package/template-nextjs-static/src/components/ui/collapsible.tsx +0 -33
  158. package/template-nextjs-static/src/components/ui/command.tsx +0 -208
  159. package/template-nextjs-static/src/components/ui/context-menu.tsx +0 -324
  160. package/template-nextjs-static/src/components/ui/dialog.tsx +0 -143
  161. package/template-nextjs-static/src/components/ui/dropdown-menu.tsx +0 -329
  162. package/template-nextjs-static/src/components/ui/empty.tsx +0 -104
  163. package/template-nextjs-static/src/components/ui/field.tsx +0 -248
  164. package/template-nextjs-static/src/components/ui/form.tsx +0 -167
  165. package/template-nextjs-static/src/components/ui/hover-card.tsx +0 -44
  166. package/template-nextjs-static/src/components/ui/icons/file-ae-colorful-icon.tsx +0 -21
  167. package/template-nextjs-static/src/components/ui/icons/file-ai-colorful-icon.tsx +0 -36
  168. package/template-nextjs-static/src/components/ui/icons/file-android-colorful-icon.tsx +0 -33
  169. package/template-nextjs-static/src/components/ui/icons/file-audio-colorful-icon.tsx +0 -21
  170. package/template-nextjs-static/src/components/ui/icons/file-code-colorful-icon.tsx +0 -28
  171. package/template-nextjs-static/src/components/ui/icons/file-csv-colorful-icon.tsx +0 -21
  172. package/template-nextjs-static/src/components/ui/icons/file-eml-colorful-icon.tsx +0 -29
  173. package/template-nextjs-static/src/components/ui/icons/file-ios-colorful-icon.tsx +0 -25
  174. package/template-nextjs-static/src/components/ui/icons/file-keynote-colorful-icon.tsx +0 -29
  175. package/template-nextjs-static/src/components/ui/icons/file-pages-colorful-icon.tsx +0 -29
  176. package/template-nextjs-static/src/components/ui/icons/file-ps-colorful-icon.tsx +0 -21
  177. package/template-nextjs-static/src/components/ui/icons/file-sketch-colorful-icon.tsx +0 -21
  178. package/template-nextjs-static/src/components/ui/icons/file-slide-colorful-icon.tsx +0 -21
  179. package/template-nextjs-static/src/components/ui/icons/file-vcf-colorful-icon.tsx +0 -29
  180. package/template-nextjs-static/src/components/ui/icons/file-wiki-excel-colorful-icon.tsx +0 -23
  181. package/template-nextjs-static/src/components/ui/icons/file-wiki-image-colorful-icon.tsx +0 -27
  182. package/template-nextjs-static/src/components/ui/icons/file-wiki-pdf-colorful-icon.tsx +0 -20
  183. package/template-nextjs-static/src/components/ui/icons/file-wiki-ppt-colorful-icon.tsx +0 -21
  184. package/template-nextjs-static/src/components/ui/icons/file-wiki-text-colorful-icon.tsx +0 -12
  185. package/template-nextjs-static/src/components/ui/icons/file-wiki-unknown-colorful-icon.tsx +0 -14
  186. package/template-nextjs-static/src/components/ui/icons/file-wiki-video-colorful-icon.tsx +0 -23
  187. package/template-nextjs-static/src/components/ui/icons/file-wiki-word-colorful-icon.tsx +0 -38
  188. package/template-nextjs-static/src/components/ui/icons/file-wiki-zip-colorful-icon.tsx +0 -21
  189. package/template-nextjs-static/src/components/ui/image.tsx +0 -183
  190. package/template-nextjs-static/src/components/ui/input-group.tsx +0 -166
  191. package/template-nextjs-static/src/components/ui/input.tsx +0 -21
  192. package/template-nextjs-static/src/components/ui/item.tsx +0 -193
  193. package/template-nextjs-static/src/components/ui/kbd.tsx +0 -28
  194. package/template-nextjs-static/src/components/ui/label.tsx +0 -24
  195. package/template-nextjs-static/src/components/ui/menubar.tsx +0 -348
  196. package/template-nextjs-static/src/components/ui/native-select.tsx +0 -48
  197. package/template-nextjs-static/src/components/ui/navigation-menu.tsx +0 -168
  198. package/template-nextjs-static/src/components/ui/popover.tsx +0 -48
  199. package/template-nextjs-static/src/components/ui/progress.tsx +0 -31
  200. package/template-nextjs-static/src/components/ui/radio-group.tsx +0 -45
  201. package/template-nextjs-static/src/components/ui/resizable.tsx +0 -56
  202. package/template-nextjs-static/src/components/ui/scroll-area.tsx +0 -58
  203. package/template-nextjs-static/src/components/ui/select.tsx +0 -243
  204. package/template-nextjs-static/src/components/ui/separator.tsx +0 -28
  205. package/template-nextjs-static/src/components/ui/sheet.tsx +0 -139
  206. package/template-nextjs-static/src/components/ui/sidebar.tsx +0 -727
  207. package/template-nextjs-static/src/components/ui/slider.tsx +0 -87
  208. package/template-nextjs-static/src/components/ui/sonner.tsx +0 -67
  209. package/template-nextjs-static/src/components/ui/spinner.tsx +0 -16
  210. package/template-nextjs-static/src/components/ui/streamdown.tsx +0 -186
  211. package/template-nextjs-static/src/components/ui/switch.tsx +0 -31
  212. package/template-nextjs-static/src/components/ui/table.tsx +0 -116
  213. package/template-nextjs-static/src/components/ui/tabs.tsx +0 -66
  214. package/template-nextjs-static/src/components/ui/textarea.tsx +0 -18
  215. package/template-nextjs-static/src/components/ui/toggle-group.tsx +0 -83
  216. package/template-nextjs-static/src/components/ui/toggle.tsx +0 -47
  217. package/template-nextjs-static/src/components/ui/tooltip.tsx +0 -61
  218. package/template-nextjs-static/src/hooks/use-mobile.ts +0 -19
  219. package/template-nextjs-static/src/lib/utils.ts +0 -6
  220. package/template-nextjs-static/src/pages/_app.tsx +0 -11
  221. package/template-nextjs-static/src/pages/_document.tsx +0 -13
  222. package/template-nextjs-static/src/pages/hello.tsx +0 -32
  223. package/template-nextjs-static/src/pages/index.tsx +0 -76
  224. package/template-nextjs-static/src/styles/globals.css +0 -143
  225. package/template-nextjs-static/tailwind.config.ts +0 -10
  226. package/template-nextjs-static/tsconfig.json +0 -34
  227. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/button-group.tsx +0 -0
  228. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/empty.tsx +0 -0
  229. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/field.tsx +0 -0
  230. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/form.tsx +0 -0
  231. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-ae-colorful-icon.tsx +0 -0
  232. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-ai-colorful-icon.tsx +0 -0
  233. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-android-colorful-icon.tsx +0 -0
  234. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-audio-colorful-icon.tsx +0 -0
  235. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-code-colorful-icon.tsx +0 -0
  236. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-csv-colorful-icon.tsx +0 -0
  237. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-eml-colorful-icon.tsx +0 -0
  238. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-ios-colorful-icon.tsx +0 -0
  239. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-keynote-colorful-icon.tsx +0 -0
  240. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-pages-colorful-icon.tsx +0 -0
  241. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-ps-colorful-icon.tsx +0 -0
  242. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-sketch-colorful-icon.tsx +0 -0
  243. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-slide-colorful-icon.tsx +0 -0
  244. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-vcf-colorful-icon.tsx +0 -0
  245. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-wiki-excel-colorful-icon.tsx +0 -0
  246. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-wiki-image-colorful-icon.tsx +0 -0
  247. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-wiki-pdf-colorful-icon.tsx +0 -0
  248. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-wiki-ppt-colorful-icon.tsx +0 -0
  249. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-wiki-text-colorful-icon.tsx +0 -0
  250. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-wiki-unknown-colorful-icon.tsx +0 -0
  251. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-wiki-video-colorful-icon.tsx +0 -0
  252. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-wiki-word-colorful-icon.tsx +0 -0
  253. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/icons/file-wiki-zip-colorful-icon.tsx +0 -0
  254. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/image.tsx +0 -0
  255. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/item.tsx +0 -0
  256. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/kbd.tsx +0 -0
  257. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/native-select.tsx +0 -0
  258. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/spinner.tsx +0 -0
  259. /package/{template-nextjs-fullstack → template-vite-react/client}/src/components/ui/streamdown.tsx +0 -0
  260. /package/{template-nextjs-fullstack → template-vite-react/client}/src/hooks/use-mobile.ts +0 -0
  261. /package/{template-nextjs-fullstack → template-vite-react/client}/src/lib/utils.ts +0 -0
@@ -4,10 +4,10 @@ import * as React from "react"
4
4
  import useEmblaCarousel, {
5
5
  type UseEmblaCarouselType,
6
6
  } from "embla-carousel-react"
7
- import { ArrowLeft, ArrowRight } from "lucide-react"
8
7
 
9
8
  import { cn } from "@/lib/utils"
10
9
  import { Button } from "@/components/ui/button"
10
+ import { ChevronLeftIcon, ChevronRightIcon } from "lucide-react"
11
11
 
12
12
  type CarouselApi = UseEmblaCarouselType[1]
13
13
  type UseCarouselParameters = Parameters<typeof useEmblaCarousel>
@@ -174,7 +174,7 @@ function CarouselItem({ className, ...props }: React.ComponentProps<"div">) {
174
174
  function CarouselPrevious({
175
175
  className,
176
176
  variant = "outline",
177
- size = "icon",
177
+ size = "icon-sm",
178
178
  ...props
179
179
  }: React.ComponentProps<typeof Button>) {
180
180
  const { orientation, scrollPrev, canScrollPrev } = useCarousel()
@@ -185,7 +185,7 @@ function CarouselPrevious({
185
185
  variant={variant}
186
186
  size={size}
187
187
  className={cn(
188
- "absolute size-8 rounded-full",
188
+ "absolute touch-manipulation rounded-full",
189
189
  orientation === "horizontal"
190
190
  ? "top-1/2 -left-12 -translate-y-1/2"
191
191
  : "-top-12 left-1/2 -translate-x-1/2 rotate-90",
@@ -195,7 +195,7 @@ function CarouselPrevious({
195
195
  onClick={scrollPrev}
196
196
  {...props}
197
197
  >
198
- <ArrowLeft />
198
+ <ChevronLeftIcon />
199
199
  <span className="sr-only">Previous slide</span>
200
200
  </Button>
201
201
  )
@@ -204,7 +204,7 @@ function CarouselPrevious({
204
204
  function CarouselNext({
205
205
  className,
206
206
  variant = "outline",
207
- size = "icon",
207
+ size = "icon-sm",
208
208
  ...props
209
209
  }: React.ComponentProps<typeof Button>) {
210
210
  const { orientation, scrollNext, canScrollNext } = useCarousel()
@@ -215,7 +215,7 @@ function CarouselNext({
215
215
  variant={variant}
216
216
  size={size}
217
217
  className={cn(
218
- "absolute size-8 rounded-full",
218
+ "absolute touch-manipulation rounded-full",
219
219
  orientation === "horizontal"
220
220
  ? "top-1/2 -right-12 -translate-y-1/2"
221
221
  : "-bottom-12 left-1/2 -translate-x-1/2 rotate-90",
@@ -225,7 +225,7 @@ function CarouselNext({
225
225
  onClick={scrollNext}
226
226
  {...props}
227
227
  >
228
- <ArrowRight />
228
+ <ChevronRightIcon />
229
229
  <span className="sr-only">Next slide</span>
230
230
  </Button>
231
231
  )
@@ -238,4 +238,5 @@ export {
238
238
  CarouselItem,
239
239
  CarouselPrevious,
240
240
  CarouselNext,
241
+ useCarousel,
241
242
  }
@@ -1,22 +1,25 @@
1
- "use client"
2
-
3
1
  import * as React from "react"
4
2
  import * as RechartsPrimitive from "recharts"
3
+ import type { TooltipValueType } from "recharts"
5
4
 
6
5
  import { cn } from "@/lib/utils"
7
6
 
8
7
  // Format: { THEME_NAME: CSS_SELECTOR }
9
8
  const THEMES = { light: "", dark: ".dark" } as const
10
9
 
11
- export type ChartConfig = {
12
- [k in string]: {
10
+ const INITIAL_DIMENSION = { width: 320, height: 200 } as const
11
+ type TooltipNameType = number | string
12
+
13
+ export type ChartConfig = Record<
14
+ string,
15
+ {
13
16
  label?: React.ReactNode
14
17
  icon?: React.ComponentType
15
18
  } & (
16
19
  | { color?: string; theme?: never }
17
20
  | { color?: never; theme: Record<keyof typeof THEMES, string> }
18
21
  )
19
- }
22
+ >
20
23
 
21
24
  type ChartContextProps = {
22
25
  config: ChartConfig
@@ -39,15 +42,20 @@ function ChartContainer({
39
42
  className,
40
43
  children,
41
44
  config,
45
+ initialDimension = INITIAL_DIMENSION,
42
46
  ...props
43
47
  }: React.ComponentProps<"div"> & {
44
48
  config: ChartConfig
45
49
  children: React.ComponentProps<
46
50
  typeof RechartsPrimitive.ResponsiveContainer
47
51
  >["children"]
52
+ initialDimension?: {
53
+ width: number
54
+ height: number
55
+ }
48
56
  }) {
49
57
  const uniqueId = React.useId()
50
- const chartId = `chart-${id || uniqueId.replace(/:/g, "")}`
58
+ const chartId = `chart-${id ?? uniqueId.replace(/:/g, "")}`
51
59
 
52
60
  return (
53
61
  <ChartContext.Provider value={{ config }}>
@@ -55,13 +63,15 @@ function ChartContainer({
55
63
  data-slot="chart"
56
64
  data-chart={chartId}
57
65
  className={cn(
58
- "[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border flex aspect-video justify-center text-xs [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden",
66
+ "flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden",
59
67
  className
60
68
  )}
61
69
  {...props}
62
70
  >
63
71
  <ChartStyle id={chartId} config={config} />
64
- <RechartsPrimitive.ResponsiveContainer>
72
+ <RechartsPrimitive.ResponsiveContainer
73
+ initialDimension={initialDimension}
74
+ >
65
75
  {children}
66
76
  </RechartsPrimitive.ResponsiveContainer>
67
77
  </div>
@@ -71,7 +81,7 @@ function ChartContainer({
71
81
 
72
82
  const ChartStyle = ({ id, config }: { id: string; config: ChartConfig }) => {
73
83
  const colorConfig = Object.entries(config).filter(
74
- ([, config]) => config.theme || config.color
84
+ ([, config]) => config.theme ?? config.color
75
85
  )
76
86
 
77
87
  if (!colorConfig.length) {
@@ -88,7 +98,7 @@ ${prefix} [data-chart=${id}] {
88
98
  ${colorConfig
89
99
  .map(([key, itemConfig]) => {
90
100
  const color =
91
- itemConfig.theme?.[theme as keyof typeof itemConfig.theme] ||
101
+ itemConfig.theme?.[theme as keyof typeof itemConfig.theme] ??
92
102
  itemConfig.color
93
103
  return color ? ` --color-${key}: ${color};` : null
94
104
  })
@@ -125,7 +135,13 @@ function ChartTooltipContent({
125
135
  indicator?: "line" | "dot" | "dashed"
126
136
  nameKey?: string
127
137
  labelKey?: string
128
- }) {
138
+ } & Omit<
139
+ RechartsPrimitive.DefaultTooltipContentProps<
140
+ TooltipValueType,
141
+ TooltipNameType
142
+ >,
143
+ "accessibilityLayer"
144
+ >) {
129
145
  const { config } = useChart()
130
146
 
131
147
  const tooltipLabel = React.useMemo(() => {
@@ -134,11 +150,11 @@ function ChartTooltipContent({
134
150
  }
135
151
 
136
152
  const [item] = payload
137
- const key = `${labelKey || item?.dataKey || item?.name || "value"}`
153
+ const key = `${labelKey ?? item?.dataKey ?? item?.name ?? "value"}`
138
154
  const itemConfig = getPayloadConfigFromPayload(config, item, key)
139
155
  const value =
140
156
  !labelKey && typeof label === "string"
141
- ? config[label as keyof typeof config]?.label || label
157
+ ? (config[label]?.label ?? label)
142
158
  : itemConfig?.label
143
159
 
144
160
  if (labelFormatter) {
@@ -173,7 +189,7 @@ function ChartTooltipContent({
173
189
  return (
174
190
  <div
175
191
  className={cn(
176
- "border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl",
192
+ "grid min-w-32 items-start gap-1.5 rounded-lg border border-border/50 bg-background px-2.5 py-1.5 text-xs shadow-xl",
177
193
  className
178
194
  )}
179
195
  >
@@ -182,15 +198,15 @@ function ChartTooltipContent({
182
198
  {payload
183
199
  .filter((item) => item.type !== "none")
184
200
  .map((item, index) => {
185
- const key = `${nameKey || item.name || item.dataKey || "value"}`
201
+ const key = `${nameKey ?? item.name ?? item.dataKey ?? "value"}`
186
202
  const itemConfig = getPayloadConfigFromPayload(config, item, key)
187
- const indicatorColor = color || item.payload.fill || item.color
203
+ const indicatorColor = color ?? item.payload?.fill ?? item.color
188
204
 
189
205
  return (
190
206
  <div
191
- key={item.dataKey}
207
+ key={index}
192
208
  className={cn(
193
- "[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5",
209
+ "flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5 [&>svg]:text-muted-foreground",
194
210
  indicator === "dot" && "items-center"
195
211
  )}
196
212
  >
@@ -231,12 +247,14 @@ function ChartTooltipContent({
231
247
  <div className="grid gap-1.5">
232
248
  {nestLabel ? tooltipLabel : null}
233
249
  <span className="text-muted-foreground">
234
- {itemConfig?.label || item.name}
250
+ {itemConfig?.label ?? item.name}
235
251
  </span>
236
252
  </div>
237
- {item.value && (
238
- <span className="text-foreground font-mono font-medium tabular-nums">
239
- {item.value.toLocaleString()}
253
+ {item.value != null && (
254
+ <span className="font-mono font-medium text-foreground tabular-nums">
255
+ {typeof item.value === "number"
256
+ ? item.value.toLocaleString()
257
+ : String(item.value)}
240
258
  </span>
241
259
  )}
242
260
  </div>
@@ -258,11 +276,10 @@ function ChartLegendContent({
258
276
  payload,
259
277
  verticalAlign = "bottom",
260
278
  nameKey,
261
- }: React.ComponentProps<"div"> &
262
- Pick<RechartsPrimitive.LegendProps, "payload" | "verticalAlign"> & {
263
- hideIcon?: boolean
264
- nameKey?: string
265
- }) {
279
+ }: React.ComponentProps<"div"> & {
280
+ hideIcon?: boolean
281
+ nameKey?: string
282
+ } & RechartsPrimitive.DefaultLegendContentProps) {
266
283
  const { config } = useChart()
267
284
 
268
285
  if (!payload?.length) {
@@ -279,15 +296,15 @@ function ChartLegendContent({
279
296
  >
280
297
  {payload
281
298
  .filter((item) => item.type !== "none")
282
- .map((item) => {
283
- const key = `${nameKey || item.dataKey || "value"}`
299
+ .map((item, index) => {
300
+ const key = `${nameKey ?? item.dataKey ?? "value"}`
284
301
  const itemConfig = getPayloadConfigFromPayload(config, item, key)
285
302
 
286
303
  return (
287
304
  <div
288
- key={item.value}
305
+ key={index}
289
306
  className={cn(
290
- "[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3"
307
+ "flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3 [&>svg]:text-muted-foreground"
291
308
  )}
292
309
  >
293
310
  {itemConfig?.icon && !hideIcon ? (
@@ -308,7 +325,6 @@ function ChartLegendContent({
308
325
  )
309
326
  }
310
327
 
311
- // Helper to extract item config from a payload.
312
328
  function getPayloadConfigFromPayload(
313
329
  config: ChartConfig,
314
330
  payload: unknown,
@@ -342,9 +358,7 @@ function getPayloadConfigFromPayload(
342
358
  ] as string
343
359
  }
344
360
 
345
- return configLabelKey in config
346
- ? config[configLabelKey]
347
- : config[key as keyof typeof config]
361
+ return configLabelKey in config ? config[configLabelKey] : config[key]
348
362
  }
349
363
 
350
364
  export {
@@ -0,0 +1,29 @@
1
+ "use client"
2
+
3
+ import { Checkbox as CheckboxPrimitive } from "@base-ui/react/checkbox"
4
+
5
+ import { cn } from "@/lib/utils"
6
+ import { CheckIcon } from "lucide-react"
7
+
8
+ function Checkbox({ className, ...props }: CheckboxPrimitive.Root.Props) {
9
+ return (
10
+ <CheckboxPrimitive.Root
11
+ data-slot="checkbox"
12
+ className={cn(
13
+ "peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary",
14
+ className
15
+ )}
16
+ {...props}
17
+ >
18
+ <CheckboxPrimitive.Indicator
19
+ data-slot="checkbox-indicator"
20
+ className="grid place-content-center text-current transition-none [&>svg]:size-3.5"
21
+ >
22
+ <CheckIcon
23
+ />
24
+ </CheckboxPrimitive.Indicator>
25
+ </CheckboxPrimitive.Root>
26
+ )
27
+ }
28
+
29
+ export { Checkbox }
@@ -0,0 +1,19 @@
1
+ import { Collapsible as CollapsiblePrimitive } from "@base-ui/react/collapsible"
2
+
3
+ function Collapsible({ ...props }: CollapsiblePrimitive.Root.Props) {
4
+ return <CollapsiblePrimitive.Root data-slot="collapsible" {...props} />
5
+ }
6
+
7
+ function CollapsibleTrigger({ ...props }: CollapsiblePrimitive.Trigger.Props) {
8
+ return (
9
+ <CollapsiblePrimitive.Trigger data-slot="collapsible-trigger" {...props} />
10
+ )
11
+ }
12
+
13
+ function CollapsibleContent({ ...props }: CollapsiblePrimitive.Panel.Props) {
14
+ return (
15
+ <CollapsiblePrimitive.Panel data-slot="collapsible-content" {...props} />
16
+ )
17
+ }
18
+
19
+ export { Collapsible, CollapsibleTrigger, CollapsibleContent }
@@ -2,7 +2,6 @@
2
2
 
3
3
  import * as React from "react"
4
4
  import { Command as CommandPrimitive } from "cmdk"
5
- import { SearchIcon } from "lucide-react"
6
5
 
7
6
  import { cn } from "@/lib/utils"
8
7
  import {
@@ -12,6 +11,11 @@ import {
12
11
  DialogHeader,
13
12
  DialogTitle,
14
13
  } from "@/components/ui/dialog"
14
+ import {
15
+ InputGroup,
16
+ InputGroupAddon,
17
+ } from "@/components/ui/input-group"
18
+ import { SearchIcon, CheckIcon } from "lucide-react"
15
19
 
16
20
  function Command({
17
21
  className,
@@ -21,7 +25,7 @@ function Command({
21
25
  <CommandPrimitive
22
26
  data-slot="command"
23
27
  className={cn(
24
- "bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md",
28
+ "flex size-full flex-col overflow-hidden rounded-xl! bg-popover p-1 text-popover-foreground",
25
29
  className
26
30
  )}
27
31
  {...props}
@@ -34,13 +38,14 @@ function CommandDialog({
34
38
  description = "Search for a command to run...",
35
39
  children,
36
40
  className,
37
- showCloseButton = true,
41
+ showCloseButton = false,
38
42
  ...props
39
- }: React.ComponentProps<typeof Dialog> & {
43
+ }: Omit<React.ComponentProps<typeof Dialog>, "children"> & {
40
44
  title?: string
41
45
  description?: string
42
46
  className?: string
43
47
  showCloseButton?: boolean
48
+ children: React.ReactNode
44
49
  }) {
45
50
  return (
46
51
  <Dialog {...props}>
@@ -49,12 +54,13 @@ function CommandDialog({
49
54
  <DialogDescription>{description}</DialogDescription>
50
55
  </DialogHeader>
51
56
  <DialogContent
52
- className={cn("overflow-hidden p-0", className)}
57
+ className={cn(
58
+ "top-1/3 translate-y-0 overflow-hidden rounded-xl! p-0",
59
+ className
60
+ )}
53
61
  showCloseButton={showCloseButton}
54
62
  >
55
- <Command className="[&_[cmdk-group-heading]]:text-muted-foreground **:data-[slot=command-input-wrapper]:h-12 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group]]:px-2 [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5">
56
- {children}
57
- </Command>
63
+ {children}
58
64
  </DialogContent>
59
65
  </Dialog>
60
66
  )
@@ -65,19 +71,20 @@ function CommandInput({
65
71
  ...props
66
72
  }: React.ComponentProps<typeof CommandPrimitive.Input>) {
67
73
  return (
68
- <div
69
- data-slot="command-input-wrapper"
70
- className="flex h-9 items-center gap-2 border-b px-3"
71
- >
72
- <SearchIcon className="size-4 shrink-0 opacity-50" />
73
- <CommandPrimitive.Input
74
- data-slot="command-input"
75
- className={cn(
76
- "placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",
77
- className
78
- )}
79
- {...props}
80
- />
74
+ <div data-slot="command-input-wrapper" className="p-1 pb-0">
75
+ <InputGroup className="h-8! rounded-lg! border-input/30 bg-input/30 shadow-none! *:data-[slot=input-group-addon]:pl-2!">
76
+ <CommandPrimitive.Input
77
+ data-slot="command-input"
78
+ className={cn(
79
+ "w-full text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",
80
+ className
81
+ )}
82
+ {...props}
83
+ />
84
+ <InputGroupAddon>
85
+ <SearchIcon className="size-4 shrink-0 opacity-50" />
86
+ </InputGroupAddon>
87
+ </InputGroup>
81
88
  </div>
82
89
  )
83
90
  }
@@ -90,7 +97,7 @@ function CommandList({
90
97
  <CommandPrimitive.List
91
98
  data-slot="command-list"
92
99
  className={cn(
93
- "max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",
100
+ "no-scrollbar max-h-72 scroll-py-1 overflow-x-hidden overflow-y-auto outline-none",
94
101
  className
95
102
  )}
96
103
  {...props}
@@ -99,12 +106,13 @@ function CommandList({
99
106
  }
100
107
 
101
108
  function CommandEmpty({
109
+ className,
102
110
  ...props
103
111
  }: React.ComponentProps<typeof CommandPrimitive.Empty>) {
104
112
  return (
105
113
  <CommandPrimitive.Empty
106
114
  data-slot="command-empty"
107
- className="py-6 text-center text-sm"
115
+ className={cn("py-6 text-center text-sm", className)}
108
116
  {...props}
109
117
  />
110
118
  )
@@ -118,7 +126,7 @@ function CommandGroup({
118
126
  <CommandPrimitive.Group
119
127
  data-slot="command-group"
120
128
  className={cn(
121
- "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",
129
+ "overflow-hidden p-1 text-foreground **:[[cmdk-group-heading]]:px-2 **:[[cmdk-group-heading]]:py-1.5 **:[[cmdk-group-heading]]:text-xs **:[[cmdk-group-heading]]:font-medium **:[[cmdk-group-heading]]:text-muted-foreground",
122
130
  className
123
131
  )}
124
132
  {...props}
@@ -133,7 +141,7 @@ function CommandSeparator({
133
141
  return (
134
142
  <CommandPrimitive.Separator
135
143
  data-slot="command-separator"
136
- className={cn("bg-border -mx-1 h-px", className)}
144
+ className={cn("-mx-1 h-px bg-border", className)}
137
145
  {...props}
138
146
  />
139
147
  )
@@ -141,41 +149,21 @@ function CommandSeparator({
141
149
 
142
150
  function CommandItem({
143
151
  className,
144
- disabled,
145
- onClick,
146
- onMouseDown,
147
- onKeyDown,
148
- onKeyUp,
149
- onPointerDown,
152
+ children,
150
153
  ...props
151
154
  }: React.ComponentProps<typeof CommandPrimitive.Item>) {
152
155
  return (
153
156
  <CommandPrimitive.Item
154
157
  data-slot="command-item"
155
158
  className={cn(
156
- "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]:cursor-not-allowed data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
159
+ "group/command-item relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none in-data-[slot=dialog-content]:rounded-lg! data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 data-selected:bg-muted data-selected:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-selected:*:[svg]:text-foreground",
157
160
  className
158
161
  )}
159
- disabled={disabled}
160
- onClick={(event) => {
161
- if (disabled) {
162
- event.preventDefault()
163
- return
164
- }
165
- onClick?.(event)
166
- }}
167
- onMouseDown={disabled ? undefined : onMouseDown}
168
- onKeyDown={disabled ? undefined : onKeyDown}
169
- onKeyUp={disabled ? undefined : onKeyUp}
170
- onPointerDown={(event) => {
171
- if (disabled) {
172
- event.preventDefault()
173
- return
174
- }
175
- onPointerDown?.(event)
176
- }}
177
162
  {...props}
178
- />
163
+ >
164
+ {children}
165
+ <CheckIcon className="ml-auto opacity-0 group-has-data-[slot=command-shortcut]/command-item:hidden group-data-[checked=true]/command-item:opacity-100" />
166
+ </CommandPrimitive.Item>
179
167
  )
180
168
  }
181
169
 
@@ -187,7 +175,7 @@ function CommandShortcut({
187
175
  <span
188
176
  data-slot="command-shortcut"
189
177
  className={cn(
190
- "text-muted-foreground ml-auto text-xs tracking-widest",
178
+ "ml-auto text-xs tracking-widest text-muted-foreground group-data-selected/command-item:text-foreground",
191
179
  className
192
180
  )}
193
181
  {...props}