@health-samurai/react-components 0.0.0-alpha.2 → 0.0.0-alpha.21

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 (571) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +102 -1
  3. package/dist/bundle.css +2349 -754
  4. package/dist/src/components/button-dropdown.d.ts +10 -0
  5. package/dist/src/components/button-dropdown.d.ts.map +1 -0
  6. package/dist/src/components/button-dropdown.js +70 -0
  7. package/dist/src/components/button-dropdown.js.map +1 -0
  8. package/dist/src/components/button-dropdown.stories.js +48 -0
  9. package/dist/src/components/button-dropdown.stories.js.map +1 -0
  10. package/dist/src/components/code-editor/fhir-autocomplete.d.ts +70 -0
  11. package/dist/src/components/code-editor/fhir-autocomplete.d.ts.map +1 -0
  12. package/dist/src/components/code-editor/fhir-autocomplete.js +1850 -0
  13. package/dist/src/components/code-editor/fhir-autocomplete.js.map +1 -0
  14. package/dist/src/components/code-editor/fhir-autocomplete.test.js +1099 -0
  15. package/dist/src/components/code-editor/fhir-autocomplete.test.js.map +1 -0
  16. package/dist/src/components/code-editor/http/grammar/http.d.ts +3 -0
  17. package/dist/src/components/code-editor/http/grammar/http.d.ts.map +1 -0
  18. package/dist/src/components/code-editor/http/grammar/http.grammar +74 -0
  19. package/dist/src/components/code-editor/http/grammar/http.js +38 -0
  20. package/dist/src/components/code-editor/http/grammar/http.js.map +1 -0
  21. package/dist/src/components/code-editor/http/grammar/http.terms.d.ts +2 -0
  22. package/dist/src/components/code-editor/http/grammar/http.terms.d.ts.map +1 -0
  23. package/dist/src/components/code-editor/http/grammar/http.terms.js +4 -0
  24. package/dist/src/components/code-editor/http/grammar/http.terms.js.map +1 -0
  25. package/dist/src/components/code-editor/http/grammar/http.test.js +80 -0
  26. package/dist/src/components/code-editor/http/grammar/http.test.js.map +1 -0
  27. package/dist/src/components/code-editor/http/index.d.ts +12 -0
  28. package/dist/src/components/code-editor/http/index.d.ts.map +1 -0
  29. package/dist/src/components/code-editor/http/index.js +486 -0
  30. package/dist/src/components/code-editor/http/index.js.map +1 -0
  31. package/dist/src/components/code-editor/index.d.ts +39 -1
  32. package/dist/src/components/code-editor/index.d.ts.map +1 -1
  33. package/dist/src/components/code-editor/index.js +1792 -45
  34. package/dist/src/components/code-editor/index.js.map +1 -1
  35. package/dist/src/components/code-editor/json-ast.d.ts +46 -0
  36. package/dist/src/components/code-editor/json-ast.d.ts.map +1 -0
  37. package/dist/src/components/code-editor/json-ast.js +465 -0
  38. package/dist/src/components/code-editor/json-ast.js.map +1 -0
  39. package/dist/src/components/code-editor/json-ast.test.js +206 -0
  40. package/dist/src/components/code-editor/json-ast.test.js.map +1 -0
  41. package/dist/src/components/code-editor/sql-completion.d.ts +22 -0
  42. package/dist/src/components/code-editor/sql-completion.d.ts.map +1 -0
  43. package/dist/src/components/code-editor/sql-completion.js +897 -0
  44. package/dist/src/components/code-editor/sql-completion.js.map +1 -0
  45. package/dist/src/components/code-editor.stories.js +280 -3
  46. package/dist/src/components/code-editor.stories.js.map +1 -1
  47. package/dist/src/components/copy-icon.d.ts +5 -1
  48. package/dist/src/components/copy-icon.d.ts.map +1 -1
  49. package/dist/src/components/copy-icon.js +41 -3
  50. package/dist/src/components/copy-icon.js.map +1 -1
  51. package/dist/src/components/data-table.d.ts +9 -0
  52. package/dist/src/components/data-table.d.ts.map +1 -0
  53. package/dist/src/components/data-table.js +66 -0
  54. package/dist/src/components/data-table.js.map +1 -0
  55. package/dist/src/components/data-table.stories.js +240 -0
  56. package/dist/src/components/data-table.stories.js.map +1 -0
  57. package/dist/src/components/date-picker-input.d.ts +10 -0
  58. package/dist/src/components/date-picker-input.d.ts.map +1 -0
  59. package/dist/src/components/date-picker-input.js +90 -0
  60. package/dist/src/components/date-picker-input.js.map +1 -0
  61. package/dist/src/components/date-picker-input.stories.js +76 -0
  62. package/dist/src/components/date-picker-input.stories.js.map +1 -0
  63. package/dist/src/components/fhir-structure-view.d.ts +34 -0
  64. package/dist/src/components/fhir-structure-view.d.ts.map +1 -0
  65. package/dist/src/components/fhir-structure-view.js +230 -0
  66. package/dist/src/components/fhir-structure-view.js.map +1 -0
  67. package/dist/src/components/fhir-structure-view.stories.js +447 -0
  68. package/dist/src/components/fhir-structure-view.stories.js.map +1 -0
  69. package/dist/src/components/icon-button.d.ts +12 -0
  70. package/dist/src/components/icon-button.d.ts.map +1 -0
  71. package/dist/src/components/icon-button.js +41 -0
  72. package/dist/src/components/icon-button.js.map +1 -0
  73. package/dist/src/components/icon-button.stories.js +157 -0
  74. package/dist/src/components/icon-button.stories.js.map +1 -0
  75. package/dist/src/components/operation-outcome-view.d.ts +27 -0
  76. package/dist/src/components/operation-outcome-view.d.ts.map +1 -0
  77. package/dist/src/components/operation-outcome-view.js +198 -0
  78. package/dist/src/components/operation-outcome-view.js.map +1 -0
  79. package/dist/src/components/operation-outcome-view.stories.js +207 -0
  80. package/dist/src/components/operation-outcome-view.stories.js.map +1 -0
  81. package/dist/src/components/request-line-editor.d.ts +13 -35
  82. package/dist/src/components/request-line-editor.d.ts.map +1 -1
  83. package/dist/src/components/request-line-editor.js +73 -49
  84. package/dist/src/components/request-line-editor.js.map +1 -1
  85. package/dist/src/components/request-line-editor.stories.js +17 -53
  86. package/dist/src/components/request-line-editor.stories.js.map +1 -1
  87. package/dist/src/components/sandbox.d.ts +13 -0
  88. package/dist/src/components/sandbox.d.ts.map +1 -0
  89. package/dist/src/components/sandbox.js +107 -0
  90. package/dist/src/components/sandbox.js.map +1 -0
  91. package/dist/src/components/sandbox.stories.js +126 -0
  92. package/dist/src/components/sandbox.stories.js.map +1 -0
  93. package/dist/src/components/segment-control.d.ts +13 -0
  94. package/dist/src/components/segment-control.d.ts.map +1 -0
  95. package/dist/src/components/segment-control.js +33 -0
  96. package/dist/src/components/segment-control.js.map +1 -0
  97. package/dist/src/components/segment-control.stories.js +68 -0
  98. package/dist/src/components/segment-control.stories.js.map +1 -0
  99. package/dist/src/components/split-button.d.ts +12 -0
  100. package/dist/src/components/split-button.d.ts.map +1 -0
  101. package/dist/src/components/split-button.js +33 -0
  102. package/dist/src/components/split-button.js.map +1 -0
  103. package/dist/src/components/split-button.stories.js +84 -0
  104. package/dist/src/components/split-button.stories.js.map +1 -0
  105. package/dist/src/components/tag.d.ts +16 -0
  106. package/dist/src/components/tag.d.ts.map +1 -0
  107. package/dist/src/components/tag.js +198 -0
  108. package/dist/src/components/tag.js.map +1 -0
  109. package/dist/src/components/tag.stories.js +459 -0
  110. package/dist/src/components/tag.stories.js.map +1 -0
  111. package/dist/src/components/tile.d.ts +15 -0
  112. package/dist/src/components/tile.d.ts.map +1 -0
  113. package/dist/src/components/tile.js +76 -0
  114. package/dist/src/components/tile.js.map +1 -0
  115. package/dist/src/components/tile.stories.js +167 -0
  116. package/dist/src/components/tile.stories.js.map +1 -0
  117. package/dist/src/components/toolbar.d.ts +18 -0
  118. package/dist/src/components/toolbar.d.ts.map +1 -0
  119. package/dist/src/components/toolbar.js +61 -0
  120. package/dist/src/components/toolbar.js.map +1 -0
  121. package/dist/src/components/toolbar.stories.js +69 -0
  122. package/dist/src/components/toolbar.stories.js.map +1 -0
  123. package/dist/src/components/tree-view.d.ts +47 -0
  124. package/dist/src/components/tree-view.d.ts.map +1 -0
  125. package/dist/src/components/tree-view.js +122 -0
  126. package/dist/src/components/tree-view.js.map +1 -0
  127. package/dist/src/components/tree-view.stories.js +283 -0
  128. package/dist/src/components/tree-view.stories.js.map +1 -0
  129. package/dist/src/icons.d.ts +11 -0
  130. package/dist/src/icons.d.ts.map +1 -0
  131. package/dist/src/icons.js +328 -0
  132. package/dist/src/icons.js.map +1 -0
  133. package/dist/src/index.css +358 -74
  134. package/dist/src/index.d.ts +17 -1
  135. package/dist/src/index.d.ts.map +1 -1
  136. package/dist/src/index.js +17 -1
  137. package/dist/src/index.js.map +1 -1
  138. package/dist/src/shadcn/components/ui/accordion.d.ts +2 -2
  139. package/dist/src/shadcn/components/ui/accordion.d.ts.map +1 -1
  140. package/dist/src/shadcn/components/ui/accordion.js +35 -9
  141. package/dist/src/shadcn/components/ui/accordion.js.map +1 -1
  142. package/dist/src/shadcn/components/ui/alert-dialog.d.ts +12 -4
  143. package/dist/src/shadcn/components/ui/alert-dialog.d.ts.map +1 -1
  144. package/dist/src/shadcn/components/ui/alert-dialog.js +128 -18
  145. package/dist/src/shadcn/components/ui/alert-dialog.js.map +1 -1
  146. package/dist/src/shadcn/components/ui/alert-dialog.stories.js +269 -19
  147. package/dist/src/shadcn/components/ui/alert-dialog.stories.js.map +1 -1
  148. package/dist/src/shadcn/components/ui/alert.d.ts +29 -6
  149. package/dist/src/shadcn/components/ui/alert.d.ts.map +1 -1
  150. package/dist/src/shadcn/components/ui/alert.js +50 -19
  151. package/dist/src/shadcn/components/ui/alert.js.map +1 -1
  152. package/dist/src/shadcn/components/ui/alert.stories.js +140 -36
  153. package/dist/src/shadcn/components/ui/alert.stories.js.map +1 -1
  154. package/dist/src/shadcn/components/ui/aspect-ratio.d.ts.map +1 -1
  155. package/dist/src/shadcn/components/ui/aspect-ratio.js +1 -0
  156. package/dist/src/shadcn/components/ui/aspect-ratio.js.map +1 -1
  157. package/dist/src/shadcn/components/ui/avatar.d.ts.map +1 -1
  158. package/dist/src/shadcn/components/ui/avatar.js +4 -3
  159. package/dist/src/shadcn/components/ui/avatar.js.map +1 -1
  160. package/dist/src/shadcn/components/ui/avatar.stories.js +68 -2
  161. package/dist/src/shadcn/components/ui/avatar.stories.js.map +1 -1
  162. package/dist/src/shadcn/components/ui/badge.d.ts +1 -1
  163. package/dist/src/shadcn/components/ui/badge.d.ts.map +1 -1
  164. package/dist/src/shadcn/components/ui/badge.js +16 -5
  165. package/dist/src/shadcn/components/ui/badge.js.map +1 -1
  166. package/dist/src/shadcn/components/ui/breadcrumb.d.ts +5 -2
  167. package/dist/src/shadcn/components/ui/breadcrumb.d.ts.map +1 -1
  168. package/dist/src/shadcn/components/ui/breadcrumb.js +98 -13
  169. package/dist/src/shadcn/components/ui/breadcrumb.js.map +1 -1
  170. package/dist/src/shadcn/components/ui/breadcrumb.stories.js +205 -45
  171. package/dist/src/shadcn/components/ui/breadcrumb.stories.js.map +1 -1
  172. package/dist/src/shadcn/components/ui/button.d.ts.map +1 -1
  173. package/dist/src/shadcn/components/ui/button.js +65 -11
  174. package/dist/src/shadcn/components/ui/button.js.map +1 -1
  175. package/dist/src/shadcn/components/ui/button.stories.js +99 -17
  176. package/dist/src/shadcn/components/ui/button.stories.js.map +1 -1
  177. package/dist/src/shadcn/components/ui/calendar.d.ts +1 -1
  178. package/dist/src/shadcn/components/ui/calendar.d.ts.map +1 -1
  179. package/dist/src/shadcn/components/ui/calendar.js +1 -0
  180. package/dist/src/shadcn/components/ui/calendar.js.map +1 -1
  181. package/dist/src/shadcn/components/ui/card.d.ts +5 -1
  182. package/dist/src/shadcn/components/ui/card.d.ts.map +1 -1
  183. package/dist/src/shadcn/components/ui/card.js +28 -7
  184. package/dist/src/shadcn/components/ui/card.js.map +1 -1
  185. package/dist/src/shadcn/components/ui/card.stories.js +23 -2
  186. package/dist/src/shadcn/components/ui/card.stories.js.map +1 -1
  187. package/dist/src/shadcn/components/ui/carousel.d.ts +1 -1
  188. package/dist/src/shadcn/components/ui/carousel.d.ts.map +1 -1
  189. package/dist/src/shadcn/components/ui/carousel.js +1 -0
  190. package/dist/src/shadcn/components/ui/carousel.js.map +1 -1
  191. package/dist/src/shadcn/components/ui/chart.d.ts +5 -5
  192. package/dist/src/shadcn/components/ui/chart.d.ts.map +1 -1
  193. package/dist/src/shadcn/components/ui/chart.js +4 -3
  194. package/dist/src/shadcn/components/ui/chart.js.map +1 -1
  195. package/dist/src/shadcn/components/ui/checkbox.d.ts +5 -1
  196. package/dist/src/shadcn/components/ui/checkbox.d.ts.map +1 -1
  197. package/dist/src/shadcn/components/ui/checkbox.js +46 -6
  198. package/dist/src/shadcn/components/ui/checkbox.js.map +1 -1
  199. package/dist/src/shadcn/components/ui/checkbox.stories.js +156 -46
  200. package/dist/src/shadcn/components/ui/checkbox.stories.js.map +1 -1
  201. package/dist/src/shadcn/components/ui/combobox.d.ts +29 -0
  202. package/dist/src/shadcn/components/ui/combobox.d.ts.map +1 -0
  203. package/dist/src/shadcn/components/ui/combobox.js +226 -0
  204. package/dist/src/shadcn/components/ui/combobox.js.map +1 -0
  205. package/dist/src/shadcn/components/ui/combobox.stories.js +167 -0
  206. package/dist/src/shadcn/components/ui/combobox.stories.js.map +1 -0
  207. package/dist/src/shadcn/components/ui/command.d.ts +4 -2
  208. package/dist/src/shadcn/components/ui/command.d.ts.map +1 -1
  209. package/dist/src/shadcn/components/ui/command.js +75 -13
  210. package/dist/src/shadcn/components/ui/command.js.map +1 -1
  211. package/dist/src/shadcn/components/ui/command.stories.js +277 -57
  212. package/dist/src/shadcn/components/ui/command.stories.js.map +1 -1
  213. package/dist/src/shadcn/components/ui/context-menu.d.ts +7 -3
  214. package/dist/src/shadcn/components/ui/context-menu.d.ts.map +1 -1
  215. package/dist/src/shadcn/components/ui/context-menu.js +120 -13
  216. package/dist/src/shadcn/components/ui/context-menu.js.map +1 -1
  217. package/dist/src/shadcn/components/ui/dialog.d.ts.map +1 -1
  218. package/dist/src/shadcn/components/ui/dialog.js +35 -7
  219. package/dist/src/shadcn/components/ui/dialog.js.map +1 -1
  220. package/dist/src/shadcn/components/ui/drawer.d.ts.map +1 -1
  221. package/dist/src/shadcn/components/ui/drawer.js +27 -5
  222. package/dist/src/shadcn/components/ui/drawer.js.map +1 -1
  223. package/dist/src/shadcn/components/ui/dropdown-menu.d.ts +7 -3
  224. package/dist/src/shadcn/components/ui/dropdown-menu.d.ts.map +1 -1
  225. package/dist/src/shadcn/components/ui/dropdown-menu.js +122 -14
  226. package/dist/src/shadcn/components/ui/dropdown-menu.js.map +1 -1
  227. package/dist/src/shadcn/components/ui/dropdown-menu.stories.js +22 -5
  228. package/dist/src/shadcn/components/ui/dropdown-menu.stories.js.map +1 -1
  229. package/dist/src/shadcn/components/ui/form.d.ts +2 -2
  230. package/dist/src/shadcn/components/ui/form.d.ts.map +1 -1
  231. package/dist/src/shadcn/components/ui/form.js +17 -8
  232. package/dist/src/shadcn/components/ui/form.js.map +1 -1
  233. package/dist/src/shadcn/components/ui/hover-card.d.ts.map +1 -1
  234. package/dist/src/shadcn/components/ui/hover-card.js +2 -1
  235. package/dist/src/shadcn/components/ui/hover-card.js.map +1 -1
  236. package/dist/src/shadcn/components/ui/input-otp.d.ts.map +1 -1
  237. package/dist/src/shadcn/components/ui/input-otp.js +1 -0
  238. package/dist/src/shadcn/components/ui/input-otp.js.map +1 -1
  239. package/dist/src/shadcn/components/ui/input.d.ts +3 -1
  240. package/dist/src/shadcn/components/ui/input.d.ts.map +1 -1
  241. package/dist/src/shadcn/components/ui/input.js +126 -17
  242. package/dist/src/shadcn/components/ui/input.js.map +1 -1
  243. package/dist/src/shadcn/components/ui/input.stories.js +218 -29
  244. package/dist/src/shadcn/components/ui/input.stories.js.map +1 -1
  245. package/dist/src/shadcn/components/ui/label.d.ts.map +1 -1
  246. package/dist/src/shadcn/components/ui/label.js +9 -1
  247. package/dist/src/shadcn/components/ui/label.js.map +1 -1
  248. package/dist/src/shadcn/components/ui/menubar.d.ts.map +1 -1
  249. package/dist/src/shadcn/components/ui/menubar.js +35 -13
  250. package/dist/src/shadcn/components/ui/menubar.js.map +1 -1
  251. package/dist/src/shadcn/components/ui/pagination.d.ts +9 -2
  252. package/dist/src/shadcn/components/ui/pagination.d.ts.map +1 -1
  253. package/dist/src/shadcn/components/ui/pagination.js +41 -24
  254. package/dist/src/shadcn/components/ui/pagination.js.map +1 -1
  255. package/dist/src/shadcn/components/ui/pagination.stories.js +44 -37
  256. package/dist/src/shadcn/components/ui/pagination.stories.js.map +1 -1
  257. package/dist/src/shadcn/components/ui/popover.d.ts.map +1 -1
  258. package/dist/src/shadcn/components/ui/popover.js +13 -1
  259. package/dist/src/shadcn/components/ui/popover.js.map +1 -1
  260. package/dist/src/shadcn/components/ui/progress.d.ts.map +1 -1
  261. package/dist/src/shadcn/components/ui/progress.js +6 -2
  262. package/dist/src/shadcn/components/ui/progress.js.map +1 -1
  263. package/dist/src/shadcn/components/ui/radio-button-group.d.ts +21 -0
  264. package/dist/src/shadcn/components/ui/radio-button-group.d.ts.map +1 -0
  265. package/dist/src/shadcn/components/ui/radio-button-group.js +148 -0
  266. package/dist/src/shadcn/components/ui/radio-button-group.js.map +1 -0
  267. package/dist/src/shadcn/components/ui/radio-button-group.stories.js +283 -0
  268. package/dist/src/shadcn/components/ui/radio-button-group.stories.js.map +1 -0
  269. package/dist/src/shadcn/components/ui/radio-group.d.ts +5 -1
  270. package/dist/src/shadcn/components/ui/radio-group.d.ts.map +1 -1
  271. package/dist/src/shadcn/components/ui/radio-group.js +40 -7
  272. package/dist/src/shadcn/components/ui/radio-group.js.map +1 -1
  273. package/dist/src/shadcn/components/ui/radio-group.stories.js +107 -32
  274. package/dist/src/shadcn/components/ui/radio-group.stories.js.map +1 -1
  275. package/dist/src/shadcn/components/ui/resizable.d.ts.map +1 -1
  276. package/dist/src/shadcn/components/ui/resizable.js +2 -1
  277. package/dist/src/shadcn/components/ui/resizable.js.map +1 -1
  278. package/dist/src/shadcn/components/ui/resizable.stories.js +2 -2
  279. package/dist/src/shadcn/components/ui/resizable.stories.js.map +1 -1
  280. package/dist/src/shadcn/components/ui/scroll-area.d.ts.map +1 -1
  281. package/dist/src/shadcn/components/ui/scroll-area.js +10 -3
  282. package/dist/src/shadcn/components/ui/scroll-area.js.map +1 -1
  283. package/dist/src/shadcn/components/ui/select.d.ts +1 -2
  284. package/dist/src/shadcn/components/ui/select.d.ts.map +1 -1
  285. package/dist/src/shadcn/components/ui/select.js +49 -19
  286. package/dist/src/shadcn/components/ui/select.js.map +1 -1
  287. package/dist/src/shadcn/components/ui/select.stories.js +193 -70
  288. package/dist/src/shadcn/components/ui/select.stories.js.map +1 -1
  289. package/dist/src/shadcn/components/ui/separator.d.ts.map +1 -1
  290. package/dist/src/shadcn/components/ui/separator.js +8 -1
  291. package/dist/src/shadcn/components/ui/separator.js.map +1 -1
  292. package/dist/src/shadcn/components/ui/sheet.js +1 -1
  293. package/dist/src/shadcn/components/ui/sheet.js.map +1 -1
  294. package/dist/src/shadcn/components/ui/sidebar.d.ts +4 -4
  295. package/dist/src/shadcn/components/ui/sidebar.d.ts.map +1 -1
  296. package/dist/src/shadcn/components/ui/sidebar.js +21 -6
  297. package/dist/src/shadcn/components/ui/sidebar.js.map +1 -1
  298. package/dist/src/shadcn/components/ui/skeleton.d.ts.map +1 -1
  299. package/dist/src/shadcn/components/ui/skeleton.js +3 -1
  300. package/dist/src/shadcn/components/ui/skeleton.js.map +1 -1
  301. package/dist/src/shadcn/components/ui/slider.d.ts.map +1 -1
  302. package/dist/src/shadcn/components/ui/slider.js +35 -4
  303. package/dist/src/shadcn/components/ui/slider.js.map +1 -1
  304. package/dist/src/shadcn/components/ui/sonner.d.ts +24 -2
  305. package/dist/src/shadcn/components/ui/sonner.d.ts.map +1 -1
  306. package/dist/src/shadcn/components/ui/sonner.js +127 -9
  307. package/dist/src/shadcn/components/ui/sonner.js.map +1 -1
  308. package/dist/src/shadcn/components/ui/sonner.stories.js +251 -12
  309. package/dist/src/shadcn/components/ui/sonner.stories.js.map +1 -1
  310. package/dist/src/shadcn/components/ui/switch.d.ts +7 -1
  311. package/dist/src/shadcn/components/ui/switch.d.ts.map +1 -1
  312. package/dist/src/shadcn/components/ui/switch.js +55 -3
  313. package/dist/src/shadcn/components/ui/switch.js.map +1 -1
  314. package/dist/src/shadcn/components/ui/switch.stories.js +84 -9
  315. package/dist/src/shadcn/components/ui/switch.stories.js.map +1 -1
  316. package/dist/src/shadcn/components/ui/table.d.ts +23 -6
  317. package/dist/src/shadcn/components/ui/table.d.ts.map +1 -1
  318. package/dist/src/shadcn/components/ui/table.js +65 -20
  319. package/dist/src/shadcn/components/ui/table.js.map +1 -1
  320. package/dist/src/shadcn/components/ui/table.stories.js +217 -97
  321. package/dist/src/shadcn/components/ui/table.stories.js.map +1 -1
  322. package/dist/src/shadcn/components/ui/tabs.d.ts +30 -5
  323. package/dist/src/shadcn/components/ui/tabs.d.ts.map +1 -1
  324. package/dist/src/shadcn/components/ui/tabs.js +470 -23
  325. package/dist/src/shadcn/components/ui/tabs.js.map +1 -1
  326. package/dist/src/shadcn/components/ui/tabs.stories.js +405 -181
  327. package/dist/src/shadcn/components/ui/tabs.stories.js.map +1 -1
  328. package/dist/src/shadcn/components/ui/textarea.d.ts +8 -1
  329. package/dist/src/shadcn/components/ui/textarea.d.ts.map +1 -1
  330. package/dist/src/shadcn/components/ui/textarea.js +30 -2
  331. package/dist/src/shadcn/components/ui/textarea.js.map +1 -1
  332. package/dist/src/shadcn/components/ui/textarea.stories.js +85 -4
  333. package/dist/src/shadcn/components/ui/textarea.stories.js.map +1 -1
  334. package/dist/src/shadcn/components/ui/toggle-group.d.ts +3 -3
  335. package/dist/src/shadcn/components/ui/toggle-group.d.ts.map +1 -1
  336. package/dist/src/shadcn/components/ui/toggle-group.js +14 -12
  337. package/dist/src/shadcn/components/ui/toggle-group.js.map +1 -1
  338. package/dist/src/shadcn/components/ui/toggle.d.ts +3 -4
  339. package/dist/src/shadcn/components/ui/toggle.d.ts.map +1 -1
  340. package/dist/src/shadcn/components/ui/toggle.js +44 -16
  341. package/dist/src/shadcn/components/ui/toggle.js.map +1 -1
  342. package/dist/src/shadcn/components/ui/toggle.stories.js +130 -7
  343. package/dist/src/shadcn/components/ui/toggle.stories.js.map +1 -1
  344. package/dist/src/shadcn/components/ui/tooltip.d.ts.map +1 -1
  345. package/dist/src/shadcn/components/ui/tooltip.js +12 -1
  346. package/dist/src/shadcn/components/ui/tooltip.js.map +1 -1
  347. package/dist/src/shadcn/components/ui/tree.d.ts +29 -0
  348. package/dist/src/shadcn/components/ui/tree.d.ts.map +1 -0
  349. package/dist/src/shadcn/components/ui/tree.js +135 -0
  350. package/dist/src/shadcn/components/ui/tree.js.map +1 -0
  351. package/dist/src/shadcn/shadcn.css +4 -4
  352. package/dist/src/tokens.css +50 -20
  353. package/dist/src/typography.css +78 -15
  354. package/package.json +84 -64
  355. package/src/components/button-dropdown.stories.tsx +41 -0
  356. package/src/components/button-dropdown.tsx +97 -0
  357. package/src/components/code-editor/fhir-autocomplete.test.ts +993 -0
  358. package/src/components/code-editor/fhir-autocomplete.ts +2322 -0
  359. package/src/components/code-editor/http/grammar/http.grammar +74 -0
  360. package/src/components/code-editor/http/grammar/http.terms.ts +9 -0
  361. package/src/components/code-editor/http/grammar/http.test.ts +110 -0
  362. package/src/components/code-editor/http/grammar/http.ts +21 -0
  363. package/src/components/code-editor/http/index.ts +424 -0
  364. package/src/components/code-editor/index.tsx +1944 -42
  365. package/src/components/code-editor/json-ast.test.ts +230 -0
  366. package/src/components/code-editor/json-ast.ts +590 -0
  367. package/src/components/code-editor/sql-completion.ts +1112 -0
  368. package/src/components/code-editor.stories.tsx +325 -2
  369. package/src/components/copy-icon.tsx +57 -3
  370. package/src/components/data-table.stories.tsx +91 -0
  371. package/src/components/data-table.tsx +126 -0
  372. package/src/components/date-picker-input.stories.tsx +79 -0
  373. package/src/components/date-picker-input.tsx +104 -0
  374. package/src/components/fhir-structure-view.stories.tsx +439 -0
  375. package/src/components/fhir-structure-view.tsx +233 -0
  376. package/src/components/icon-button.stories.tsx +86 -0
  377. package/src/components/icon-button.tsx +57 -0
  378. package/src/components/operation-outcome-view.stories.tsx +163 -0
  379. package/src/components/operation-outcome-view.tsx +254 -0
  380. package/src/components/request-line-editor.stories.tsx +17 -27
  381. package/src/components/request-line-editor.tsx +103 -61
  382. package/src/components/sandbox.stories.tsx +131 -0
  383. package/src/components/sandbox.tsx +191 -0
  384. package/src/components/segment-control.stories.tsx +61 -0
  385. package/src/components/segment-control.tsx +83 -0
  386. package/src/components/split-button.stories.tsx +68 -0
  387. package/src/components/split-button.tsx +74 -0
  388. package/src/components/tag.stories.tsx +371 -0
  389. package/src/components/tag.tsx +236 -0
  390. package/src/components/tile.stories.tsx +149 -0
  391. package/src/components/tile.tsx +105 -0
  392. package/src/components/toolbar.stories.tsx +64 -0
  393. package/src/components/toolbar.tsx +98 -0
  394. package/src/components/tree-view.stories.tsx +265 -0
  395. package/src/components/tree-view.tsx +246 -0
  396. package/src/icons.tsx +331 -0
  397. package/src/index.css +358 -74
  398. package/src/index.tsx +17 -3
  399. package/src/shadcn/components/ui/accordion.tsx +91 -10
  400. package/src/shadcn/components/ui/alert-dialog.stories.tsx +209 -15
  401. package/src/shadcn/components/ui/alert-dialog.tsx +236 -26
  402. package/src/shadcn/components/ui/alert.stories.tsx +120 -21
  403. package/src/shadcn/components/ui/alert.tsx +125 -28
  404. package/src/shadcn/components/ui/aspect-ratio.tsx +1 -0
  405. package/src/shadcn/components/ui/avatar.stories.tsx +74 -1
  406. package/src/shadcn/components/ui/avatar.tsx +22 -6
  407. package/src/shadcn/components/ui/badge.tsx +67 -18
  408. package/src/shadcn/components/ui/breadcrumb.stories.tsx +161 -41
  409. package/src/shadcn/components/ui/breadcrumb.tsx +172 -23
  410. package/src/shadcn/components/ui/button.stories.tsx +106 -18
  411. package/src/shadcn/components/ui/button.tsx +151 -55
  412. package/src/shadcn/components/ui/calendar.tsx +1 -0
  413. package/src/shadcn/components/ui/card.stories.tsx +17 -3
  414. package/src/shadcn/components/ui/card.tsx +89 -14
  415. package/src/shadcn/components/ui/carousel.tsx +1 -0
  416. package/src/shadcn/components/ui/chart.tsx +9 -5
  417. package/src/shadcn/components/ui/checkbox.stories.tsx +78 -30
  418. package/src/shadcn/components/ui/checkbox.tsx +91 -8
  419. package/src/shadcn/components/ui/combobox.stories.tsx +148 -0
  420. package/src/shadcn/components/ui/combobox.tsx +324 -0
  421. package/src/shadcn/components/ui/command.stories.tsx +184 -39
  422. package/src/shadcn/components/ui/command.tsx +218 -37
  423. package/src/shadcn/components/ui/context-menu.tsx +333 -40
  424. package/src/shadcn/components/ui/dialog.tsx +101 -13
  425. package/src/shadcn/components/ui/drawer.tsx +94 -18
  426. package/src/shadcn/components/ui/dropdown-menu.stories.tsx +18 -2
  427. package/src/shadcn/components/ui/dropdown-menu.tsx +334 -68
  428. package/src/shadcn/components/ui/form.tsx +22 -11
  429. package/src/shadcn/components/ui/hover-card.tsx +2 -1
  430. package/src/shadcn/components/ui/input-otp.tsx +1 -0
  431. package/src/shadcn/components/ui/input.stories.tsx +235 -27
  432. package/src/shadcn/components/ui/input.tsx +400 -29
  433. package/src/shadcn/components/ui/label.tsx +22 -4
  434. package/src/shadcn/components/ui/menubar.tsx +188 -43
  435. package/src/shadcn/components/ui/pagination.stories.tsx +8 -2
  436. package/src/shadcn/components/ui/pagination.tsx +65 -8
  437. package/src/shadcn/components/ui/popover.tsx +36 -4
  438. package/src/shadcn/components/ui/progress.tsx +21 -5
  439. package/src/shadcn/components/ui/radio-button-group.stories.tsx +247 -0
  440. package/src/shadcn/components/ui/radio-button-group.tsx +188 -0
  441. package/src/shadcn/components/ui/radio-group.stories.tsx +70 -14
  442. package/src/shadcn/components/ui/radio-group.tsx +85 -9
  443. package/src/shadcn/components/ui/resizable.stories.tsx +2 -2
  444. package/src/shadcn/components/ui/resizable.tsx +2 -1
  445. package/src/shadcn/components/ui/scroll-area.tsx +34 -5
  446. package/src/shadcn/components/ui/select.stories.tsx +108 -32
  447. package/src/shadcn/components/ui/select.tsx +182 -36
  448. package/src/shadcn/components/ui/separator.tsx +16 -5
  449. package/src/shadcn/components/ui/sheet.tsx +1 -1
  450. package/src/shadcn/components/ui/sidebar.tsx +69 -26
  451. package/src/shadcn/components/ui/skeleton.tsx +4 -1
  452. package/src/shadcn/components/ui/slider.tsx +83 -11
  453. package/src/shadcn/components/ui/sonner.stories.tsx +238 -17
  454. package/src/shadcn/components/ui/sonner.tsx +254 -11
  455. package/src/shadcn/components/ui/switch.stories.tsx +52 -5
  456. package/src/shadcn/components/ui/switch.tsx +92 -7
  457. package/src/shadcn/components/ui/table.stories.tsx +252 -72
  458. package/src/shadcn/components/ui/table.tsx +204 -26
  459. package/src/shadcn/components/ui/tabs.stories.tsx +235 -123
  460. package/src/shadcn/components/ui/tabs.tsx +694 -36
  461. package/src/shadcn/components/ui/textarea.stories.tsx +94 -2
  462. package/src/shadcn/components/ui/textarea.tsx +70 -5
  463. package/src/shadcn/components/ui/toggle-group.tsx +35 -13
  464. package/src/shadcn/components/ui/toggle.stories.tsx +92 -5
  465. package/src/shadcn/components/ui/toggle.tsx +96 -23
  466. package/src/shadcn/components/ui/tooltip.tsx +34 -8
  467. package/src/shadcn/components/ui/tree.tsx +257 -0
  468. package/src/shadcn/shadcn.css +4 -4
  469. package/src/tokens.css +50 -20
  470. package/src/typography.css +78 -15
  471. package/dist/src/components/code-editor.stories.d.ts +0 -7
  472. package/dist/src/components/code-editor.stories.d.ts.map +0 -1
  473. package/dist/src/components/request-line-editor.stories.d.ts +0 -11
  474. package/dist/src/components/request-line-editor.stories.d.ts.map +0 -1
  475. package/dist/src/index.stories.d.ts +0 -14
  476. package/dist/src/index.stories.d.ts.map +0 -1
  477. package/dist/src/index.stories.js +0 -19
  478. package/dist/src/index.stories.js.map +0 -1
  479. package/dist/src/shadcn/components/ui/accordion.stories.d.ts +0 -8
  480. package/dist/src/shadcn/components/ui/accordion.stories.d.ts.map +0 -1
  481. package/dist/src/shadcn/components/ui/alert-dialog.stories.d.ts +0 -8
  482. package/dist/src/shadcn/components/ui/alert-dialog.stories.d.ts.map +0 -1
  483. package/dist/src/shadcn/components/ui/alert.stories.d.ts +0 -8
  484. package/dist/src/shadcn/components/ui/alert.stories.d.ts.map +0 -1
  485. package/dist/src/shadcn/components/ui/aspect-ratio.stories.d.ts +0 -8
  486. package/dist/src/shadcn/components/ui/aspect-ratio.stories.d.ts.map +0 -1
  487. package/dist/src/shadcn/components/ui/avatar.stories.d.ts +0 -8
  488. package/dist/src/shadcn/components/ui/avatar.stories.d.ts.map +0 -1
  489. package/dist/src/shadcn/components/ui/badge.stories.d.ts +0 -8
  490. package/dist/src/shadcn/components/ui/badge.stories.d.ts.map +0 -1
  491. package/dist/src/shadcn/components/ui/breadcrumb.stories.d.ts +0 -8
  492. package/dist/src/shadcn/components/ui/breadcrumb.stories.d.ts.map +0 -1
  493. package/dist/src/shadcn/components/ui/button.stories.d.ts +0 -23
  494. package/dist/src/shadcn/components/ui/button.stories.d.ts.map +0 -1
  495. package/dist/src/shadcn/components/ui/calendar.stories.d.ts +0 -8
  496. package/dist/src/shadcn/components/ui/calendar.stories.d.ts.map +0 -1
  497. package/dist/src/shadcn/components/ui/card.stories.d.ts +0 -8
  498. package/dist/src/shadcn/components/ui/card.stories.d.ts.map +0 -1
  499. package/dist/src/shadcn/components/ui/carousel.stories.d.ts +0 -8
  500. package/dist/src/shadcn/components/ui/carousel.stories.d.ts.map +0 -1
  501. package/dist/src/shadcn/components/ui/chart.stories.d.ts +0 -8
  502. package/dist/src/shadcn/components/ui/chart.stories.d.ts.map +0 -1
  503. package/dist/src/shadcn/components/ui/checkbox.stories.d.ts +0 -8
  504. package/dist/src/shadcn/components/ui/checkbox.stories.d.ts.map +0 -1
  505. package/dist/src/shadcn/components/ui/collapsible.stories.d.ts +0 -8
  506. package/dist/src/shadcn/components/ui/collapsible.stories.d.ts.map +0 -1
  507. package/dist/src/shadcn/components/ui/command.stories.d.ts +0 -8
  508. package/dist/src/shadcn/components/ui/command.stories.d.ts.map +0 -1
  509. package/dist/src/shadcn/components/ui/context-menu.stories.d.ts +0 -8
  510. package/dist/src/shadcn/components/ui/context-menu.stories.d.ts.map +0 -1
  511. package/dist/src/shadcn/components/ui/dialog.stories.d.ts +0 -8
  512. package/dist/src/shadcn/components/ui/dialog.stories.d.ts.map +0 -1
  513. package/dist/src/shadcn/components/ui/drawer.stories.d.ts +0 -8
  514. package/dist/src/shadcn/components/ui/drawer.stories.d.ts.map +0 -1
  515. package/dist/src/shadcn/components/ui/dropdown-menu.stories.d.ts +0 -8
  516. package/dist/src/shadcn/components/ui/dropdown-menu.stories.d.ts.map +0 -1
  517. package/dist/src/shadcn/components/ui/form.stories.d.ts +0 -8
  518. package/dist/src/shadcn/components/ui/form.stories.d.ts.map +0 -1
  519. package/dist/src/shadcn/components/ui/hover-card.stories.d.ts +0 -8
  520. package/dist/src/shadcn/components/ui/hover-card.stories.d.ts.map +0 -1
  521. package/dist/src/shadcn/components/ui/input-otp.stories.d.ts +0 -8
  522. package/dist/src/shadcn/components/ui/input-otp.stories.d.ts.map +0 -1
  523. package/dist/src/shadcn/components/ui/input.stories.d.ts +0 -18
  524. package/dist/src/shadcn/components/ui/input.stories.d.ts.map +0 -1
  525. package/dist/src/shadcn/components/ui/label.stories.d.ts +0 -8
  526. package/dist/src/shadcn/components/ui/label.stories.d.ts.map +0 -1
  527. package/dist/src/shadcn/components/ui/menubar.stories.d.ts +0 -8
  528. package/dist/src/shadcn/components/ui/menubar.stories.d.ts.map +0 -1
  529. package/dist/src/shadcn/components/ui/navigation-menu.stories.d.ts +0 -8
  530. package/dist/src/shadcn/components/ui/navigation-menu.stories.d.ts.map +0 -1
  531. package/dist/src/shadcn/components/ui/pagination.stories.d.ts +0 -8
  532. package/dist/src/shadcn/components/ui/pagination.stories.d.ts.map +0 -1
  533. package/dist/src/shadcn/components/ui/popover.stories.d.ts +0 -8
  534. package/dist/src/shadcn/components/ui/popover.stories.d.ts.map +0 -1
  535. package/dist/src/shadcn/components/ui/progress.stories.d.ts +0 -8
  536. package/dist/src/shadcn/components/ui/progress.stories.d.ts.map +0 -1
  537. package/dist/src/shadcn/components/ui/radio-group.stories.d.ts +0 -8
  538. package/dist/src/shadcn/components/ui/radio-group.stories.d.ts.map +0 -1
  539. package/dist/src/shadcn/components/ui/resizable.stories.d.ts +0 -8
  540. package/dist/src/shadcn/components/ui/resizable.stories.d.ts.map +0 -1
  541. package/dist/src/shadcn/components/ui/scroll-area.stories.d.ts +0 -8
  542. package/dist/src/shadcn/components/ui/scroll-area.stories.d.ts.map +0 -1
  543. package/dist/src/shadcn/components/ui/select.stories.d.ts +0 -11
  544. package/dist/src/shadcn/components/ui/select.stories.d.ts.map +0 -1
  545. package/dist/src/shadcn/components/ui/separator.stories.d.ts +0 -8
  546. package/dist/src/shadcn/components/ui/separator.stories.d.ts.map +0 -1
  547. package/dist/src/shadcn/components/ui/sheet.stories.d.ts +0 -8
  548. package/dist/src/shadcn/components/ui/sheet.stories.d.ts.map +0 -1
  549. package/dist/src/shadcn/components/ui/sidebar.stories.d.ts +0 -11
  550. package/dist/src/shadcn/components/ui/sidebar.stories.d.ts.map +0 -1
  551. package/dist/src/shadcn/components/ui/skeleton.stories.d.ts +0 -8
  552. package/dist/src/shadcn/components/ui/skeleton.stories.d.ts.map +0 -1
  553. package/dist/src/shadcn/components/ui/slider.stories.d.ts +0 -8
  554. package/dist/src/shadcn/components/ui/slider.stories.d.ts.map +0 -1
  555. package/dist/src/shadcn/components/ui/sonner.stories.d.ts +0 -8
  556. package/dist/src/shadcn/components/ui/sonner.stories.d.ts.map +0 -1
  557. package/dist/src/shadcn/components/ui/switch.stories.d.ts +0 -8
  558. package/dist/src/shadcn/components/ui/switch.stories.d.ts.map +0 -1
  559. package/dist/src/shadcn/components/ui/table.stories.d.ts +0 -8
  560. package/dist/src/shadcn/components/ui/table.stories.d.ts.map +0 -1
  561. package/dist/src/shadcn/components/ui/tabs.stories.d.ts +0 -32
  562. package/dist/src/shadcn/components/ui/tabs.stories.d.ts.map +0 -1
  563. package/dist/src/shadcn/components/ui/textarea.stories.d.ts +0 -8
  564. package/dist/src/shadcn/components/ui/textarea.stories.d.ts.map +0 -1
  565. package/dist/src/shadcn/components/ui/toggle-group.stories.d.ts +0 -8
  566. package/dist/src/shadcn/components/ui/toggle-group.stories.d.ts.map +0 -1
  567. package/dist/src/shadcn/components/ui/toggle.stories.d.ts +0 -8
  568. package/dist/src/shadcn/components/ui/toggle.stories.d.ts.map +0 -1
  569. package/dist/src/shadcn/components/ui/tooltip.stories.d.ts +0 -8
  570. package/dist/src/shadcn/components/ui/tooltip.stories.d.ts.map +0 -1
  571. package/src/index.stories.tsx +0 -21
@@ -1,15 +1,138 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- import { Bold } from "lucide-react";
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
+ import { PanelRight } from "lucide-react";
3
+ import { Badge } from "./badge.js";
3
4
  import { Toggle } from "./toggle.js";
4
5
  const meta = {
5
- title: "Component/Toggle"
6
+ title: "Component/Toggle",
7
+ component: Toggle,
8
+ parameters: {
9
+ controls: {
10
+ exclude: [
11
+ "size",
12
+ "asChild"
13
+ ]
14
+ }
15
+ },
16
+ argTypes: {
17
+ variant: {
18
+ control: "select",
19
+ options: [
20
+ "filled",
21
+ "outline"
22
+ ]
23
+ }
24
+ },
25
+ args: {
26
+ variant: "filled",
27
+ children: /*#__PURE__*/ _jsxs(_Fragment, {
28
+ children: [
29
+ /*#__PURE__*/ _jsx(PanelRight, {}),
30
+ " Instance preview"
31
+ ]
32
+ }),
33
+ "aria-label": "Toggle panel"
34
+ }
6
35
  };
7
36
  export default meta;
37
+ export const WithText = {
38
+ args: {
39
+ children: /*#__PURE__*/ _jsxs(_Fragment, {
40
+ children: [
41
+ /*#__PURE__*/ _jsx(PanelRight, {}),
42
+ " Instance preview"
43
+ ]
44
+ }),
45
+ "aria-label": "Toggle panel",
46
+ variant: "filled"
47
+ }
48
+ };
49
+ export const IconOnly = {
50
+ args: {
51
+ children: /*#__PURE__*/ _jsx(PanelRight, {}),
52
+ "aria-label": "Toggle panel"
53
+ }
54
+ };
8
55
  export const Demo = {
9
- render: ()=>/*#__PURE__*/ _jsx(Toggle, {
10
- "aria-label": "Toggle italic",
11
- children: /*#__PURE__*/ _jsx(Bold, {
12
- className: "h-4 w-4"
56
+ render: ()=>/*#__PURE__*/ _jsx("div", {
57
+ className: "p-6 min-h-screen flex justify-center items-center",
58
+ children: /*#__PURE__*/ _jsxs("div", {
59
+ className: "rounded-lg p-6 shadow-sm w-200",
60
+ children: [
61
+ /*#__PURE__*/ _jsxs("div", {
62
+ className: "flex items-center mb-4 justify-between",
63
+ children: [
64
+ /*#__PURE__*/ _jsx("div", {
65
+ className: "w-30 text-center",
66
+ children: "Variant"
67
+ }),
68
+ /*#__PURE__*/ _jsx("div", {
69
+ className: "w-40 text-center text-sm text-text-secondary",
70
+ children: "Default"
71
+ }),
72
+ /*#__PURE__*/ _jsx("div", {
73
+ className: "w-40 text-center text-sm text-text-secondary",
74
+ children: "Disabled"
75
+ })
76
+ ]
77
+ }),
78
+ [
79
+ "filled",
80
+ "outline"
81
+ ].map((variant)=>/*#__PURE__*/ _jsx("div", {
82
+ className: "border-t border-border-separator py-4",
83
+ children: /*#__PURE__*/ _jsxs("div", {
84
+ className: "flex gap-4 items-center py-2 justify-between",
85
+ children: [
86
+ /*#__PURE__*/ _jsx("div", {
87
+ className: "w-30 text-sm text-text-secondary",
88
+ children: /*#__PURE__*/ _jsx(Badge, {
89
+ variant: "outline",
90
+ className: "text-xs",
91
+ children: variant
92
+ })
93
+ }),
94
+ /*#__PURE__*/ _jsxs("div", {
95
+ className: "w-40 flex gap-3 justify-center items-center",
96
+ children: [
97
+ /*#__PURE__*/ _jsxs(Toggle, {
98
+ variant: variant,
99
+ "aria-label": "Toggle with text",
100
+ children: [
101
+ /*#__PURE__*/ _jsx(PanelRight, {}),
102
+ " Instance preview"
103
+ ]
104
+ }),
105
+ /*#__PURE__*/ _jsx(Toggle, {
106
+ variant: variant,
107
+ "aria-label": "Toggle icon only",
108
+ children: /*#__PURE__*/ _jsx(PanelRight, {})
109
+ })
110
+ ]
111
+ }),
112
+ /*#__PURE__*/ _jsxs("div", {
113
+ className: "w-40 flex gap-3 justify-center items-center",
114
+ children: [
115
+ /*#__PURE__*/ _jsxs(Toggle, {
116
+ variant: variant,
117
+ disabled: true,
118
+ "aria-label": "Toggle with text",
119
+ children: [
120
+ /*#__PURE__*/ _jsx(PanelRight, {}),
121
+ " Instance preview"
122
+ ]
123
+ }),
124
+ /*#__PURE__*/ _jsx(Toggle, {
125
+ variant: variant,
126
+ disabled: true,
127
+ "aria-label": "Toggle icon only",
128
+ children: /*#__PURE__*/ _jsx(PanelRight, {})
129
+ })
130
+ ]
131
+ })
132
+ ]
133
+ })
134
+ }, variant))
135
+ ]
13
136
  })
14
137
  })
15
138
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../src/shadcn/components/ui/toggle.stories.tsx"],"sourcesContent":["import type { Meta, StoryObj } from \"@storybook/react-vite\";\nimport { Bold } from \"lucide-react\";\nimport { Toggle } from \"#shadcn/components/ui/toggle\";\n\nconst meta = {\n\ttitle: \"Component/Toggle\",\n} satisfies Meta;\nexport default meta;\n\ntype Story = StoryObj<typeof meta>;\n\nexport const Demo = {\n\trender: () => (\n\t\t<Toggle aria-label=\"Toggle italic\">\n\t\t\t<Bold className=\"h-4 w-4\" />\n\t\t</Toggle>\n\t),\n} satisfies Story;\n"],"names":["Bold","Toggle","meta","title","Demo","render","aria-label","className"],"mappings":";AACA,SAASA,IAAI,QAAQ,eAAe;AACpC,SAASC,MAAM,QAAQ,cAA+B;AAEtD,MAAMC,OAAO;IACZC,OAAO;AACR;AACA,eAAeD,KAAK;AAIpB,OAAO,MAAME,OAAO;IACnBC,QAAQ,kBACP,KAACJ;YAAOK,cAAW;sBAClB,cAAA,KAACN;gBAAKO,WAAU;;;AAGnB,EAAkB"}
1
+ {"version":3,"sources":["../../../../../src/shadcn/components/ui/toggle.stories.tsx"],"sourcesContent":["import type { Meta, StoryObj } from \"@storybook/react-vite\";\nimport { PanelRight } from \"lucide-react\";\nimport { Badge } from \"#shadcn/components/ui/badge\";\nimport { Toggle } from \"#shadcn/components/ui/toggle\";\n\nconst meta = {\n\ttitle: \"Component/Toggle\",\n\tcomponent: Toggle,\n\tparameters: {\n\t\tcontrols: {\n\t\t\texclude: [\"size\", \"asChild\"],\n\t\t},\n\t},\n\targTypes: {\n\t\tvariant: {\n\t\t\tcontrol: \"select\",\n\t\t\toptions: [\"filled\", \"outline\"],\n\t\t},\n\t},\n\targs: {\n\t\tvariant: \"filled\",\n\t\tchildren: (\n\t\t\t<>\n\t\t\t\t<PanelRight /> Instance preview\n\t\t\t</>\n\t\t),\n\t\t\"aria-label\": \"Toggle panel\",\n\t},\n} satisfies Meta<typeof Toggle>;\nexport default meta;\n\ntype Story = StoryObj<typeof meta>;\n\nexport const WithText = {\n\targs: {\n\t\tchildren: (\n\t\t\t<>\n\t\t\t\t<PanelRight /> Instance preview\n\t\t\t</>\n\t\t),\n\t\t\"aria-label\": \"Toggle panel\",\n\t\tvariant: \"filled\",\n\t},\n} satisfies Story;\n\nexport const IconOnly = {\n\targs: {\n\t\tchildren: <PanelRight />,\n\t\t\"aria-label\": \"Toggle panel\",\n\t},\n} satisfies Story;\n\nexport const Demo = {\n\trender: () => (\n\t\t<div className=\"p-6 min-h-screen flex justify-center items-center\">\n\t\t\t<div className=\"rounded-lg p-6 shadow-sm w-200\">\n\t\t\t\t<div className=\"flex items-center mb-4 justify-between\">\n\t\t\t\t\t<div className=\"w-30 text-center\">Variant</div>\n\t\t\t\t\t<div className=\"w-40 text-center text-sm text-text-secondary\">\n\t\t\t\t\t\tDefault\n\t\t\t\t\t</div>\n\t\t\t\t\t<div className=\"w-40 text-center text-sm text-text-secondary\">\n\t\t\t\t\t\tDisabled\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\n\t\t\t\t{([\"filled\", \"outline\"] as const).map((variant) => (\n\t\t\t\t\t<div className=\"border-t border-border-separator py-4\" key={variant}>\n\t\t\t\t\t\t<div className=\"flex gap-4 items-center py-2 justify-between\">\n\t\t\t\t\t\t\t<div className=\"w-30 text-sm text-text-secondary\">\n\t\t\t\t\t\t\t\t<Badge variant=\"outline\" className=\"text-xs\">\n\t\t\t\t\t\t\t\t\t{variant}\n\t\t\t\t\t\t\t\t</Badge>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div className=\"w-40 flex gap-3 justify-center items-center\">\n\t\t\t\t\t\t\t\t<Toggle variant={variant} aria-label=\"Toggle with text\">\n\t\t\t\t\t\t\t\t\t<PanelRight /> Instance preview\n\t\t\t\t\t\t\t\t</Toggle>\n\t\t\t\t\t\t\t\t<Toggle variant={variant} aria-label=\"Toggle icon only\">\n\t\t\t\t\t\t\t\t\t<PanelRight />\n\t\t\t\t\t\t\t\t</Toggle>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div className=\"w-40 flex gap-3 justify-center items-center\">\n\t\t\t\t\t\t\t\t<Toggle\n\t\t\t\t\t\t\t\t\tvariant={variant}\n\t\t\t\t\t\t\t\t\tdisabled\n\t\t\t\t\t\t\t\t\taria-label=\"Toggle with text\"\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<PanelRight /> Instance preview\n\t\t\t\t\t\t\t\t</Toggle>\n\t\t\t\t\t\t\t\t<Toggle\n\t\t\t\t\t\t\t\t\tvariant={variant}\n\t\t\t\t\t\t\t\t\tdisabled\n\t\t\t\t\t\t\t\t\taria-label=\"Toggle icon only\"\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<PanelRight />\n\t\t\t\t\t\t\t\t</Toggle>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t))}\n\t\t\t</div>\n\t\t</div>\n\t),\n} satisfies Story;\n"],"names":["PanelRight","Badge","Toggle","meta","title","component","parameters","controls","exclude","argTypes","variant","control","options","args","children","WithText","IconOnly","Demo","render","div","className","map","aria-label","disabled"],"mappings":";AACA,SAASA,UAAU,QAAQ,eAAe;AAC1C,SAASC,KAAK,QAAQ,aAA8B;AACpD,SAASC,MAAM,QAAQ,cAA+B;AAEtD,MAAMC,OAAO;IACZC,OAAO;IACPC,WAAWH;IACXI,YAAY;QACXC,UAAU;YACTC,SAAS;gBAAC;gBAAQ;aAAU;QAC7B;IACD;IACAC,UAAU;QACTC,SAAS;YACRC,SAAS;YACTC,SAAS;gBAAC;gBAAU;aAAU;QAC/B;IACD;IACAC,MAAM;QACLH,SAAS;QACTI,wBACC;;8BACC,KAACd;gBAAa;;;QAGhB,cAAc;IACf;AACD;AACA,eAAeG,KAAK;AAIpB,OAAO,MAAMY,WAAW;IACvBF,MAAM;QACLC,wBACC;;8BACC,KAACd;gBAAa;;;QAGhB,cAAc;QACdU,SAAS;IACV;AACD,EAAkB;AAElB,OAAO,MAAMM,WAAW;IACvBH,MAAM;QACLC,wBAAU,KAACd;QACX,cAAc;IACf;AACD,EAAkB;AAElB,OAAO,MAAMiB,OAAO;IACnBC,QAAQ,kBACP,KAACC;YAAIC,WAAU;sBACd,cAAA,MAACD;gBAAIC,WAAU;;kCACd,MAACD;wBAAIC,WAAU;;0CACd,KAACD;gCAAIC,WAAU;0CAAmB;;0CAClC,KAACD;gCAAIC,WAAU;0CAA+C;;0CAG9D,KAACD;gCAAIC,WAAU;0CAA+C;;;;oBAK7D;wBAAC;wBAAU;qBAAU,CAAWC,GAAG,CAAC,CAACX,wBACtC,KAACS;4BAAIC,WAAU;sCACd,cAAA,MAACD;gCAAIC,WAAU;;kDACd,KAACD;wCAAIC,WAAU;kDACd,cAAA,KAACnB;4CAAMS,SAAQ;4CAAUU,WAAU;sDACjCV;;;kDAGH,MAACS;wCAAIC,WAAU;;0DACd,MAAClB;gDAAOQ,SAASA;gDAASY,cAAW;;kEACpC,KAACtB;oDAAa;;;0DAEf,KAACE;gDAAOQ,SAASA;gDAASY,cAAW;0DACpC,cAAA,KAACtB;;;;kDAGH,MAACmB;wCAAIC,WAAU;;0DACd,MAAClB;gDACAQ,SAASA;gDACTa,QAAQ;gDACRD,cAAW;;kEAEX,KAACtB;oDAAa;;;0DAEf,KAACE;gDACAQ,SAASA;gDACTa,QAAQ;gDACRD,cAAW;0DAEX,cAAA,KAACtB;;;;;;2BA5BuDU;;;;AAqCjE,EAAkB"}
@@ -1 +1 @@
1
- {"version":3,"file":"tooltip.d.ts","sourceRoot":"","sources":["../../../../../src/shadcn/components/ui/tooltip.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAC;AAC5D,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAIpC,iBAAS,eAAe,CAAC,EACxB,aAAiB,EACjB,GAAG,KAAK,EACR,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,QAAQ,CAAC,2CAQxD;AAED,iBAAS,OAAO,CAAC,EAChB,GAAG,KAAK,EACR,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,IAAI,CAAC,2CAMpD;AAED,iBAAS,cAAc,CAAC,EACvB,GAAG,KAAK,EACR,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,OAAO,CAAC,2CAEvD;AAED,iBAAS,cAAc,CAAC,EACvB,SAAS,EACT,UAAc,EACd,QAAQ,EACR,GAAG,KAAK,EACR,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,OAAO,CAAC,2CAoBvD;AAED,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,eAAe,EAAE,CAAC"}
1
+ {"version":3,"file":"tooltip.d.ts","sourceRoot":"","sources":["../../../../../src/shadcn/components/ui/tooltip.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAC;AAC5D,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAoCpC,iBAAS,eAAe,CAAC,EACxB,aAAiB,EACjB,GAAG,KAAK,EACR,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,QAAQ,CAAC,2CAQxD;AAED,iBAAS,OAAO,CAAC,EAChB,GAAG,KAAK,EACR,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,IAAI,CAAC,2CAMpD;AAED,iBAAS,cAAc,CAAC,EACvB,GAAG,KAAK,EACR,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,OAAO,CAAC,2CAEvD;AAED,iBAAS,cAAc,CAAC,EACvB,SAAS,EACT,UAAc,EACd,QAAQ,EACR,GAAG,KAAK,EACR,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,OAAO,CAAC,2CAavD;AAED,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,eAAe,EAAE,CAAC"}
@@ -1,6 +1,17 @@
1
+ "use client";
1
2
  import { jsx as _jsx } from "react/jsx-runtime";
2
3
  import * as TooltipPrimitive from "@radix-ui/react-tooltip";
3
4
  import { cn } from "../../lib/utils.js";
5
+ // Tooltip content styles
6
+ const tooltipContentStyles = cn(// Layout
7
+ "z-50", "w-fit", "origin-(--radix-tooltip-content-transform-origin)", // Shape
8
+ "rounded-md", // Background & Colors
9
+ "bg-bg-overlay", "text-text-primary_on-brand", // Spacing
10
+ "px-3", "py-1.5", // Typography
11
+ "text-xs", "text-balance", // Animations - open
12
+ "animate-in", "fade-in-0", "zoom-in-95", // Animations - closed
13
+ "data-[state=closed]:animate-out", "data-[state=closed]:fade-out-0", "data-[state=closed]:zoom-out-95", // Slide animations
14
+ "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");
4
15
  function TooltipProvider({ delayDuration = 0, ...props }) {
5
16
  return /*#__PURE__*/ _jsx(TooltipPrimitive.Provider, {
6
17
  "data-slot": "tooltip-provider",
@@ -27,7 +38,7 @@ function TooltipContent({ className, sideOffset = 0, children, ...props }) {
27
38
  children: /*#__PURE__*/ _jsx(TooltipPrimitive.Content, {
28
39
  "data-slot": "tooltip-content",
29
40
  sideOffset: sideOffset,
30
- className: cn("bg-(--color-elements-assistive) text-(--color-elements-readable-inv) 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 z-50 w-fit origin-(--radix-tooltip-content-transform-origin) rounded-md", "px-3 py-1.5 text-xs text-balance", className),
41
+ className: cn(tooltipContentStyles, className),
31
42
  ...props,
32
43
  children: children
33
44
  })
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../src/shadcn/components/ui/tooltip.tsx"],"sourcesContent":["import * as TooltipPrimitive from \"@radix-ui/react-tooltip\";\nimport type * as React from \"react\";\n\nimport { cn } from \"#shadcn/lib/utils\";\n\nfunction TooltipProvider({\n\tdelayDuration = 0,\n\t...props\n}: React.ComponentProps<typeof TooltipPrimitive.Provider>) {\n\treturn (\n\t\t<TooltipPrimitive.Provider\n\t\t\tdata-slot=\"tooltip-provider\"\n\t\t\tdelayDuration={delayDuration}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction Tooltip({\n\t...props\n}: React.ComponentProps<typeof TooltipPrimitive.Root>) {\n\treturn (\n\t\t<TooltipProvider>\n\t\t\t<TooltipPrimitive.Root data-slot=\"tooltip\" {...props} />\n\t\t</TooltipProvider>\n\t);\n}\n\nfunction TooltipTrigger({\n\t...props\n}: React.ComponentProps<typeof TooltipPrimitive.Trigger>) {\n\treturn <TooltipPrimitive.Trigger data-slot=\"tooltip-trigger\" {...props} />;\n}\n\nfunction TooltipContent({\n\tclassName,\n\tsideOffset = 0,\n\tchildren,\n\t...props\n}: React.ComponentProps<typeof TooltipPrimitive.Content>) {\n\treturn (\n\t\t<TooltipPrimitive.Portal>\n\t\t\t<TooltipPrimitive.Content\n\t\t\t\tdata-slot=\"tooltip-content\"\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"bg-(--color-elements-assistive) text-(--color-elements-readable-inv) animate-in fade-in-0 zoom-in-95\",\n\t\t\t\t\t\"data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95\",\n\t\t\t\t\t\"data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2\",\n\t\t\t\t\t\"data-[side=top]:slide-in-from-bottom-2 z-50 w-fit origin-(--radix-tooltip-content-transform-origin) rounded-md\",\n\t\t\t\t\t\"px-3 py-1.5 text-xs text-balance\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</TooltipPrimitive.Content>\n\t\t</TooltipPrimitive.Portal>\n\t);\n}\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n"],"names":["TooltipPrimitive","cn","TooltipProvider","delayDuration","props","Provider","data-slot","Tooltip","Root","TooltipTrigger","Trigger","TooltipContent","className","sideOffset","children","Portal","Content"],"mappings":";AAAA,YAAYA,sBAAsB,0BAA0B;AAG5D,SAASC,EAAE,QAAQ,qBAAoB;AAEvC,SAASC,gBAAgB,EACxBC,gBAAgB,CAAC,EACjB,GAAGC,OACqD;IACxD,qBACC,KAACJ,iBAAiBK,QAAQ;QACzBC,aAAU;QACVH,eAAeA;QACd,GAAGC,KAAK;;AAGZ;AAEA,SAASG,QAAQ,EAChB,GAAGH,OACiD;IACpD,qBACC,KAACF;kBACA,cAAA,KAACF,iBAAiBQ,IAAI;YAACF,aAAU;YAAW,GAAGF,KAAK;;;AAGvD;AAEA,SAASK,eAAe,EACvB,GAAGL,OACoD;IACvD,qBAAO,KAACJ,iBAAiBU,OAAO;QAACJ,aAAU;QAAmB,GAAGF,KAAK;;AACvE;AAEA,SAASO,eAAe,EACvBC,SAAS,EACTC,aAAa,CAAC,EACdC,QAAQ,EACR,GAAGV,OACoD;IACvD,qBACC,KAACJ,iBAAiBe,MAAM;kBACvB,cAAA,KAACf,iBAAiBgB,OAAO;YACxBV,aAAU;YACVO,YAAYA;YACZD,WAAWX,GACV,wGACA,kGACA,wHACA,kHACA,oCACAW;YAEA,GAAGR,KAAK;sBAERU;;;AAIL;AAEA,SAASP,OAAO,EAAEE,cAAc,EAAEE,cAAc,EAAET,eAAe,GAAG"}
1
+ {"version":3,"sources":["../../../../../src/shadcn/components/ui/tooltip.tsx"],"sourcesContent":["\"use client\";\nimport * as TooltipPrimitive from \"@radix-ui/react-tooltip\";\nimport type * as React from \"react\";\n\nimport { cn } from \"#shadcn/lib/utils\";\n\n// Tooltip content styles\nconst tooltipContentStyles = cn(\n\t// Layout\n\t\"z-50\",\n\t\"w-fit\",\n\t\"origin-(--radix-tooltip-content-transform-origin)\",\n\t// Shape\n\t\"rounded-md\",\n\t// Background & Colors\n\t\"bg-bg-overlay\",\n\t\"text-text-primary_on-brand\",\n\t// Spacing\n\t\"px-3\",\n\t\"py-1.5\",\n\t// Typography\n\t\"text-xs\",\n\t\"text-balance\",\n\t// Animations - open\n\t\"animate-in\",\n\t\"fade-in-0\",\n\t\"zoom-in-95\",\n\t// Animations - closed\n\t\"data-[state=closed]:animate-out\",\n\t\"data-[state=closed]:fade-out-0\",\n\t\"data-[state=closed]:zoom-out-95\",\n\t// Slide animations\n\t\"data-[side=bottom]:slide-in-from-top-2\",\n\t\"data-[side=left]:slide-in-from-right-2\",\n\t\"data-[side=right]:slide-in-from-left-2\",\n\t\"data-[side=top]:slide-in-from-bottom-2\",\n);\n\nfunction TooltipProvider({\n\tdelayDuration = 0,\n\t...props\n}: React.ComponentProps<typeof TooltipPrimitive.Provider>) {\n\treturn (\n\t\t<TooltipPrimitive.Provider\n\t\t\tdata-slot=\"tooltip-provider\"\n\t\t\tdelayDuration={delayDuration}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction Tooltip({\n\t...props\n}: React.ComponentProps<typeof TooltipPrimitive.Root>) {\n\treturn (\n\t\t<TooltipProvider>\n\t\t\t<TooltipPrimitive.Root data-slot=\"tooltip\" {...props} />\n\t\t</TooltipProvider>\n\t);\n}\n\nfunction TooltipTrigger({\n\t...props\n}: React.ComponentProps<typeof TooltipPrimitive.Trigger>) {\n\treturn <TooltipPrimitive.Trigger data-slot=\"tooltip-trigger\" {...props} />;\n}\n\nfunction TooltipContent({\n\tclassName,\n\tsideOffset = 0,\n\tchildren,\n\t...props\n}: React.ComponentProps<typeof TooltipPrimitive.Content>) {\n\treturn (\n\t\t<TooltipPrimitive.Portal>\n\t\t\t<TooltipPrimitive.Content\n\t\t\t\tdata-slot=\"tooltip-content\"\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t\tclassName={cn(tooltipContentStyles, className)}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</TooltipPrimitive.Content>\n\t\t</TooltipPrimitive.Portal>\n\t);\n}\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n"],"names":["TooltipPrimitive","cn","tooltipContentStyles","TooltipProvider","delayDuration","props","Provider","data-slot","Tooltip","Root","TooltipTrigger","Trigger","TooltipContent","className","sideOffset","children","Portal","Content"],"mappings":"AAAA;;AACA,YAAYA,sBAAsB,0BAA0B;AAG5D,SAASC,EAAE,QAAQ,qBAAoB;AAEvC,yBAAyB;AACzB,MAAMC,uBAAuBD,GAC5B,SAAS;AACT,QACA,SACA,qDACA,QAAQ;AACR,cACA,sBAAsB;AACtB,iBACA,8BACA,UAAU;AACV,QACA,UACA,aAAa;AACb,WACA,gBACA,oBAAoB;AACpB,cACA,aACA,cACA,sBAAsB;AACtB,mCACA,kCACA,mCACA,mBAAmB;AACnB,0CACA,0CACA,0CACA;AAGD,SAASE,gBAAgB,EACxBC,gBAAgB,CAAC,EACjB,GAAGC,OACqD;IACxD,qBACC,KAACL,iBAAiBM,QAAQ;QACzBC,aAAU;QACVH,eAAeA;QACd,GAAGC,KAAK;;AAGZ;AAEA,SAASG,QAAQ,EAChB,GAAGH,OACiD;IACpD,qBACC,KAACF;kBACA,cAAA,KAACH,iBAAiBS,IAAI;YAACF,aAAU;YAAW,GAAGF,KAAK;;;AAGvD;AAEA,SAASK,eAAe,EACvB,GAAGL,OACoD;IACvD,qBAAO,KAACL,iBAAiBW,OAAO;QAACJ,aAAU;QAAmB,GAAGF,KAAK;;AACvE;AAEA,SAASO,eAAe,EACvBC,SAAS,EACTC,aAAa,CAAC,EACdC,QAAQ,EACR,GAAGV,OACoD;IACvD,qBACC,KAACL,iBAAiBgB,MAAM;kBACvB,cAAA,KAAChB,iBAAiBiB,OAAO;YACxBV,aAAU;YACVO,YAAYA;YACZD,WAAWZ,GAAGC,sBAAsBW;YACnC,GAAGR,KAAK;sBAERU;;;AAIL;AAEA,SAASP,OAAO,EAAEE,cAAc,EAAEE,cAAc,EAAET,eAAe,GAAG"}
@@ -0,0 +1,29 @@
1
+ import type { ItemInstance } from "@headless-tree/core";
2
+ import * as React from "react";
3
+ type WithMeta = {
4
+ meta?: {
5
+ lastNode?: boolean;
6
+ };
7
+ };
8
+ interface TreeProps extends React.HTMLAttributes<HTMLDivElement> {
9
+ indent?: number;
10
+ tree?: any;
11
+ }
12
+ declare function Tree({ indent, tree, className, ...props }: TreeProps): import("react/jsx-runtime").JSX.Element;
13
+ interface TreeItemProps<T = any> extends React.HTMLAttributes<HTMLButtonElement> {
14
+ item: ItemInstance<T>;
15
+ indent?: number;
16
+ asChild?: boolean;
17
+ }
18
+ declare function TreeItem<T = any>({ item, className, asChild, children, ...props }: Omit<TreeItemProps<T>, "indent">): import("react/jsx-runtime").JSX.Element;
19
+ interface TreeItemLabelProps<T = any> extends React.HTMLAttributes<HTMLSpanElement> {
20
+ hideChevron?: boolean;
21
+ disableHover?: boolean;
22
+ item?: ItemInstance<T>;
23
+ horizontalLines?: boolean;
24
+ chevronClassName?: string;
25
+ }
26
+ declare function TreeItemLabel<T>({ item: propItem, children, className, disableHover, horizontalLines, hideChevron, chevronClassName, ...props }: TreeItemLabelProps<T & WithMeta>): import("react/jsx-runtime").JSX.Element | null;
27
+ declare function TreeDragLine({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element | null;
28
+ export { Tree, TreeItem, TreeItemLabel, TreeDragLine, type ItemInstance };
29
+ //# sourceMappingURL=tree.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tree.d.ts","sourceRoot":"","sources":["../../../../../src/shadcn/components/ui/tree.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAGxD,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,KAAK,QAAQ,GAAG;IACf,IAAI,CAAC,EAAE;QACN,QAAQ,CAAC,EAAE,OAAO,CAAC;KACnB,CAAC;CACF,CAAC;AAmBF,UAAU,SAAU,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC/D,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,IAAI,CAAC,EAAE,GAAG,CAAC;CACX;AAED,iBAAS,IAAI,CAAC,EAAE,MAAW,EAAE,IAAI,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,SAAS,2CA2BlE;AAGD,UAAU,aAAa,CAAC,CAAC,GAAG,GAAG,CAC9B,SAAQ,KAAK,CAAC,cAAc,CAAC,iBAAiB,CAAC;IAC/C,IAAI,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,OAAO,CAAC;CAClB;AAGD,iBAAS,QAAQ,CAAC,CAAC,GAAG,GAAG,EAAE,EAC1B,IAAI,EACJ,SAAS,EACT,OAAO,EACP,QAAQ,EACR,GAAG,KAAK,EACR,EAAE,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE,QAAQ,CAAC,2CAiElC;AAGD,UAAU,kBAAkB,CAAC,CAAC,GAAG,GAAG,CACnC,SAAQ,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;IAC7C,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,IAAI,CAAC,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC;IACvB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,iBAAS,aAAa,CAAC,CAAC,EAAE,EACzB,IAAI,EAAE,QAAQ,EACd,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,eAAe,EACf,WAAW,EACX,gBAAqD,EACrD,GAAG,KAAK,EACR,EAAE,kBAAkB,CAAC,CAAC,GAAG,QAAQ,CAAC,kDA8DlC;AAED,iBAAS,YAAY,CAAC,EACrB,SAAS,EACT,GAAG,KAAK,EACR,EAAE,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,kDAqBtC;AAED,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,aAAa,EAAE,YAAY,EAAE,KAAK,YAAY,EAAE,CAAC"}
@@ -0,0 +1,135 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { ChevronDownIcon } from "lucide-react";
3
+ import { Slot } from "radix-ui";
4
+ import * as React from "react";
5
+ import { cn } from "../../lib/utils.js";
6
+ const TreeContext = /*#__PURE__*/ React.createContext({
7
+ indent: 20
8
+ });
9
+ // biome-ignore lint/suspicious/noExplicitAny: FIXME Origin UI as-is
10
+ function useTreeContext() {
11
+ return React.useContext(TreeContext);
12
+ }
13
+ function Tree({ indent = 20, tree, className, ...props }) {
14
+ const containerProps = tree && typeof tree.getContainerProps === "function" ? tree.getContainerProps() : {};
15
+ const mergedProps = {
16
+ ...props,
17
+ ...containerProps
18
+ };
19
+ // Extract style from mergedProps to merge with our custom styles
20
+ const { style: propStyle, ...otherProps } = mergedProps;
21
+ // Merge styles
22
+ const mergedStyle = {
23
+ ...propStyle,
24
+ "--tree-indent": `${indent}px`,
25
+ "--border": `var(--color-border-separator)`
26
+ };
27
+ return /*#__PURE__*/ _jsx(TreeContext.Provider, {
28
+ value: {
29
+ indent,
30
+ tree
31
+ },
32
+ children: /*#__PURE__*/ _jsx("div", {
33
+ "data-slot": "tree",
34
+ style: mergedStyle,
35
+ className: cn("flex flex-col", className),
36
+ ...otherProps
37
+ })
38
+ });
39
+ }
40
+ // biome-ignore lint/suspicious/noExplicitAny: FIXME Origin UI as-is
41
+ function TreeItem({ item, className, asChild, children, ...props }) {
42
+ const { indent } = useTreeContext();
43
+ const itemProps = typeof item.getProps === "function" ? item.getProps() : {};
44
+ const mergedProps = {
45
+ ...props,
46
+ ...itemProps
47
+ };
48
+ // Extract style from mergedProps to merge with our custom styles
49
+ const { style: propStyle, ...otherProps } = mergedProps;
50
+ // Merge styles
51
+ const mergedStyle = {
52
+ ...propStyle,
53
+ "--tree-padding": `${item.getItemMeta().level * indent}px`
54
+ };
55
+ const Comp = asChild ? Slot.Root : "span";
56
+ return /*#__PURE__*/ _jsx(TreeContext.Provider, {
57
+ value: {
58
+ indent,
59
+ currentItem: item
60
+ },
61
+ children: /*#__PURE__*/ _jsx(Comp, {
62
+ "data-slot": "tree-item",
63
+ style: mergedStyle,
64
+ className: cn("z-10 ps-(--tree-padding) outline-hidden select-none focus:z-20 data-[disabled]:pointer-events-none data-[disabled]:opacity-50", className),
65
+ "data-focus": typeof item.isFocused === "function" ? item.isFocused() || false : undefined,
66
+ "data-folder": typeof item.isFolder === "function" ? item.isFolder() || false : undefined,
67
+ "data-selected": typeof item.isSelected === "function" ? item.isSelected() || false : undefined,
68
+ "data-drag-target": typeof item.isDragTarget === "function" ? item.isDragTarget() || false : undefined,
69
+ "data-search-match": typeof item.isMatchingSearch === "function" ? item.isMatchingSearch() || false : undefined,
70
+ "aria-expanded": item.isExpanded(),
71
+ ...Object.fromEntries(Object.entries(otherProps).filter(([key])=>key !== "onDragStart")),
72
+ onDragStart: (e)=>{
73
+ if (e.target.dataset.slot === "drag-handle") {
74
+ item.getProps().onDragStart?.(e);
75
+ }
76
+ },
77
+ children: children
78
+ })
79
+ });
80
+ }
81
+ function TreeItemLabel({ item: propItem, children, className, disableHover, horizontalLines, hideChevron, chevronClassName = "self-start mt-0.5 cursor-pointer", ...props }) {
82
+ const { currentItem } = useTreeContext();
83
+ const item = propItem || currentItem;
84
+ if (!item) {
85
+ console.warn("TreeItemLabel: No item provided via props or context");
86
+ return null;
87
+ }
88
+ const data = item.getItemData?.();
89
+ const isLastNode = data?.meta?.lastNode;
90
+ const itemMeta = item.getItemMeta();
91
+ return /*#__PURE__*/ _jsxs("span", {
92
+ "data-slot": "tree-item-label",
93
+ className: cn("group/tree-item-label relative select-text in-focus-visible:ring-ring/50 bg-background text-text-primary in-data-[drag-target=true]:bg-accent flex items-center gap-2 pr-2 pl-2.5 py-1.5 text-sm transition-colors not-in-data-[folder=true]:ps-2.5 in-focus-visible:ring-[3px] in-data-[search-match=true]:bg-blue-400/20! [&_svg]:pointer-events-none [&_svg]:shrink-0", !disableHover && "in-data-[focus=true]:bg-bg-secondary in-data-[focus=true]:text-text-primary", !disableHover && item.isFolder() && "hover:bg-bg-secondary hover:text-text-primary cursor-pointer", !disableHover && !item.isFolder() && "hover:bg-bg-secondary hover:text-text-primary cursor-pointer", disableHover && "text-text-primary", className),
94
+ ...props,
95
+ children: [
96
+ item.isFolder() && !hideChevron && /*#__PURE__*/ _jsx("button", {
97
+ type: "button",
98
+ className: chevronClassName,
99
+ onClick: (e)=>{
100
+ e.stopPropagation();
101
+ item.isExpanded() ? item.collapse() : item.expand();
102
+ },
103
+ children: /*#__PURE__*/ _jsx(ChevronDownIcon, {
104
+ className: "text-muted-foreground size-4 in-aria-[expanded=false]:-rotate-90"
105
+ })
106
+ }),
107
+ !item.isFolder() && horizontalLines && /*#__PURE__*/ _jsx("div", {
108
+ className: `w-5 min-w-5 h-px border-t mt-2 -ml-1 self-start`
109
+ }),
110
+ item.isFolder() && item.isExpanded() && horizontalLines && /*#__PURE__*/ _jsx("div", {
111
+ className: `absolute left-4.25 top-8 w-px min-h-full h-full border-l mt-2.25 self-start `
112
+ }),
113
+ horizontalLines && /*#__PURE__*/ _jsx("div", {
114
+ className: `absolute left-0 top-4.75 -m-[5px] border-t w-4 ${isLastNode ? "h-full bg-inherit " : ""} ${itemMeta.level === 0 ? "hidden" : ""}`
115
+ }),
116
+ children || (typeof item.getItemName === "function" ? item.getItemName() : null)
117
+ ]
118
+ });
119
+ }
120
+ function TreeDragLine({ className, ...props }) {
121
+ const { tree } = useTreeContext();
122
+ if (!tree || typeof tree.getDragLineStyle !== "function") {
123
+ console.warn("TreeDragLine: No tree provided via context or tree does not have getDragLineStyle method");
124
+ return null;
125
+ }
126
+ const dragLine = tree.getDragLineStyle();
127
+ return /*#__PURE__*/ _jsx("div", {
128
+ style: dragLine,
129
+ className: cn("bg-primary before:bg-background before:border-primary absolute z-30 -mt-px h-0.5 w-[unset] before:absolute before:-top-[3px] before:left-0 before:size-2 before:rounded-full before:border-2", className),
130
+ ...props
131
+ });
132
+ }
133
+ export { Tree, TreeItem, TreeItemLabel, TreeDragLine };
134
+
135
+ //# sourceMappingURL=tree.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/shadcn/components/ui/tree.tsx"],"sourcesContent":["import type { ItemInstance } from \"@headless-tree/core\";\nimport { ChevronDownIcon } from \"lucide-react\";\nimport { Slot } from \"radix-ui\";\nimport * as React from \"react\";\n\nimport { cn } from \"#shadcn/lib/utils\";\n\ntype WithMeta = {\n\tmeta?: {\n\t\tlastNode?: boolean;\n\t};\n};\n\n// biome-ignore lint/suspicious/noExplicitAny: FIXME Origin UI as-is\ninterface TreeContextValue<T = any> {\n\tindent: number;\n\tcurrentItem?: ItemInstance<T>;\n\t// biome-ignore lint/suspicious/noExplicitAny: FIXME Origin UI as-is\n\ttree?: any;\n}\n\nconst TreeContext = React.createContext<TreeContextValue>({\n\tindent: 20,\n});\n\n// biome-ignore lint/suspicious/noExplicitAny: FIXME Origin UI as-is\nfunction useTreeContext<T = any>() {\n\treturn React.useContext(TreeContext) as TreeContextValue<T>;\n}\n\ninterface TreeProps extends React.HTMLAttributes<HTMLDivElement> {\n\tindent?: number;\n\t// biome-ignore lint/suspicious/noExplicitAny: FIXME Origin UI as-is\n\ttree?: any;\n}\n\nfunction Tree({ indent = 20, tree, className, ...props }: TreeProps) {\n\tconst containerProps =\n\t\ttree && typeof tree.getContainerProps === \"function\"\n\t\t\t? tree.getContainerProps()\n\t\t\t: {};\n\tconst mergedProps = { ...props, ...containerProps };\n\n\t// Extract style from mergedProps to merge with our custom styles\n\tconst { style: propStyle, ...otherProps } = mergedProps;\n\n\t// Merge styles\n\tconst mergedStyle = {\n\t\t...propStyle,\n\t\t\"--tree-indent\": `${indent}px`,\n\t\t\"--border\": `var(--color-border-separator)`,\n\t} as React.CSSProperties;\n\n\treturn (\n\t\t<TreeContext.Provider value={{ indent, tree }}>\n\t\t\t<div\n\t\t\t\tdata-slot=\"tree\"\n\t\t\t\tstyle={mergedStyle}\n\t\t\t\tclassName={cn(\"flex flex-col\", className)}\n\t\t\t\t{...otherProps}\n\t\t\t/>\n\t\t</TreeContext.Provider>\n\t);\n}\n\n// biome-ignore lint/suspicious/noExplicitAny: FIXME Origin UI as-is\ninterface TreeItemProps<T = any>\n\textends React.HTMLAttributes<HTMLButtonElement> {\n\titem: ItemInstance<T>;\n\tindent?: number;\n\tasChild?: boolean;\n}\n\n// biome-ignore lint/suspicious/noExplicitAny: FIXME Origin UI as-is\nfunction TreeItem<T = any>({\n\titem,\n\tclassName,\n\tasChild,\n\tchildren,\n\t...props\n}: Omit<TreeItemProps<T>, \"indent\">) {\n\tconst { indent } = useTreeContext<T>();\n\n\tconst itemProps = typeof item.getProps === \"function\" ? item.getProps() : {};\n\tconst mergedProps = { ...props, ...itemProps };\n\n\t// Extract style from mergedProps to merge with our custom styles\n\tconst { style: propStyle, ...otherProps } = mergedProps;\n\n\t// Merge styles\n\tconst mergedStyle = {\n\t\t...propStyle,\n\t\t\"--tree-padding\": `${item.getItemMeta().level * indent}px`,\n\t} as React.CSSProperties;\n\n\tconst Comp = asChild ? Slot.Root : \"span\";\n\n\treturn (\n\t\t<TreeContext.Provider value={{ indent, currentItem: item }}>\n\t\t\t<Comp\n\t\t\t\tdata-slot=\"tree-item\"\n\t\t\t\tstyle={mergedStyle}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"z-10 ps-(--tree-padding) outline-hidden select-none focus:z-20 data-[disabled]:pointer-events-none data-[disabled]:opacity-50\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\tdata-focus={\n\t\t\t\t\ttypeof item.isFocused === \"function\"\n\t\t\t\t\t\t? item.isFocused() || false\n\t\t\t\t\t\t: undefined\n\t\t\t\t}\n\t\t\t\tdata-folder={\n\t\t\t\t\ttypeof item.isFolder === \"function\"\n\t\t\t\t\t\t? item.isFolder() || false\n\t\t\t\t\t\t: undefined\n\t\t\t\t}\n\t\t\t\tdata-selected={\n\t\t\t\t\ttypeof item.isSelected === \"function\"\n\t\t\t\t\t\t? item.isSelected() || false\n\t\t\t\t\t\t: undefined\n\t\t\t\t}\n\t\t\t\tdata-drag-target={\n\t\t\t\t\ttypeof item.isDragTarget === \"function\"\n\t\t\t\t\t\t? item.isDragTarget() || false\n\t\t\t\t\t\t: undefined\n\t\t\t\t}\n\t\t\t\tdata-search-match={\n\t\t\t\t\ttypeof item.isMatchingSearch === \"function\"\n\t\t\t\t\t\t? item.isMatchingSearch() || false\n\t\t\t\t\t\t: undefined\n\t\t\t\t}\n\t\t\t\taria-expanded={item.isExpanded()}\n\t\t\t\t{...Object.fromEntries(\n\t\t\t\t\tObject.entries(otherProps).filter(([key]) => key !== \"onDragStart\"),\n\t\t\t\t)}\n\t\t\t\tonDragStart={(e) => {\n\t\t\t\t\tif ((e.target as HTMLElement).dataset.slot === \"drag-handle\") {\n\t\t\t\t\t\titem.getProps().onDragStart?.(e);\n\t\t\t\t\t}\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</Comp>\n\t\t</TreeContext.Provider>\n\t);\n}\n\n// biome-ignore lint/suspicious/noExplicitAny: FIXME Origin UI as-is\ninterface TreeItemLabelProps<T = any>\n\textends React.HTMLAttributes<HTMLSpanElement> {\n\thideChevron?: boolean;\n\tdisableHover?: boolean;\n\titem?: ItemInstance<T>;\n\thorizontalLines?: boolean;\n\tchevronClassName?: string;\n}\n\nfunction TreeItemLabel<T>({\n\titem: propItem,\n\tchildren,\n\tclassName,\n\tdisableHover,\n\thorizontalLines,\n\thideChevron,\n\tchevronClassName = \"self-start mt-0.5 cursor-pointer\",\n\t...props\n}: TreeItemLabelProps<T & WithMeta>) {\n\tconst { currentItem } = useTreeContext<T & WithMeta>();\n\tconst item = propItem || currentItem;\n\n\tif (!item) {\n\t\tconsole.warn(\"TreeItemLabel: No item provided via props or context\");\n\t\treturn null;\n\t}\n\n\tconst data = item.getItemData?.();\n\tconst isLastNode = data?.meta?.lastNode;\n\tconst itemMeta = item.getItemMeta();\n\n\treturn (\n\t\t<span\n\t\t\tdata-slot=\"tree-item-label\"\n\t\t\tclassName={cn(\n\t\t\t\t\"group/tree-item-label relative select-text in-focus-visible:ring-ring/50 bg-background text-text-primary in-data-[drag-target=true]:bg-accent flex items-center gap-2 pr-2 pl-2.5 py-1.5 text-sm transition-colors not-in-data-[folder=true]:ps-2.5 in-focus-visible:ring-[3px] in-data-[search-match=true]:bg-blue-400/20! [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n\t\t\t\t!disableHover &&\n\t\t\t\t\t\"in-data-[focus=true]:bg-bg-secondary in-data-[focus=true]:text-text-primary\",\n\t\t\t\t!disableHover &&\n\t\t\t\t\titem.isFolder() &&\n\t\t\t\t\t\"hover:bg-bg-secondary hover:text-text-primary cursor-pointer\",\n\t\t\t\t!disableHover &&\n\t\t\t\t\t!item.isFolder() &&\n\t\t\t\t\t\"hover:bg-bg-secondary hover:text-text-primary cursor-pointer\",\n\t\t\t\tdisableHover && \"text-text-primary\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{item.isFolder() && !hideChevron && (\n\t\t\t\t<button\n\t\t\t\t\ttype=\"button\"\n\t\t\t\t\tclassName={chevronClassName}\n\t\t\t\t\tonClick={(e) => {\n\t\t\t\t\t\te.stopPropagation();\n\t\t\t\t\t\titem.isExpanded() ? item.collapse() : item.expand();\n\t\t\t\t\t}}\n\t\t\t\t>\n\t\t\t\t\t<ChevronDownIcon className=\"text-muted-foreground size-4 in-aria-[expanded=false]:-rotate-90\" />\n\t\t\t\t</button>\n\t\t\t)}\n\t\t\t{!item.isFolder() && horizontalLines && (\n\t\t\t\t<div\n\t\t\t\t\tclassName={`w-5 min-w-5 h-px border-t mt-2 -ml-1 self-start`}\n\t\t\t\t></div>\n\t\t\t)}\n\t\t\t{item.isFolder() && item.isExpanded() && horizontalLines && (\n\t\t\t\t<div\n\t\t\t\t\tclassName={`absolute left-4.25 top-8 w-px min-h-full h-full border-l mt-2.25 self-start `}\n\t\t\t\t></div>\n\t\t\t)}\n\t\t\t{horizontalLines && (\n\t\t\t\t<div\n\t\t\t\t\tclassName={`absolute left-0 top-4.75 -m-[5px] border-t w-4 ${isLastNode ? \"h-full bg-inherit \" : \"\"} ${itemMeta.level === 0 ? \"hidden\" : \"\"}`}\n\t\t\t\t></div>\n\t\t\t)}\n\t\t\t{children ||\n\t\t\t\t(typeof item.getItemName === \"function\" ? item.getItemName() : null)}\n\t\t</span>\n\t);\n}\n\nfunction TreeDragLine({\n\tclassName,\n\t...props\n}: React.HTMLAttributes<HTMLDivElement>) {\n\tconst { tree } = useTreeContext();\n\n\tif (!tree || typeof tree.getDragLineStyle !== \"function\") {\n\t\tconsole.warn(\n\t\t\t\"TreeDragLine: No tree provided via context or tree does not have getDragLineStyle method\",\n\t\t);\n\t\treturn null;\n\t}\n\n\tconst dragLine = tree.getDragLineStyle();\n\treturn (\n\t\t<div\n\t\t\tstyle={dragLine}\n\t\t\tclassName={cn(\n\t\t\t\t\"bg-primary before:bg-background before:border-primary absolute z-30 -mt-px h-0.5 w-[unset] before:absolute before:-top-[3px] before:left-0 before:size-2 before:rounded-full before:border-2\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Tree, TreeItem, TreeItemLabel, TreeDragLine, type ItemInstance };\n"],"names":["ChevronDownIcon","Slot","React","cn","TreeContext","createContext","indent","useTreeContext","useContext","Tree","tree","className","props","containerProps","getContainerProps","mergedProps","style","propStyle","otherProps","mergedStyle","Provider","value","div","data-slot","TreeItem","item","asChild","children","itemProps","getProps","getItemMeta","level","Comp","Root","currentItem","data-focus","isFocused","undefined","data-folder","isFolder","data-selected","isSelected","data-drag-target","isDragTarget","data-search-match","isMatchingSearch","aria-expanded","isExpanded","Object","fromEntries","entries","filter","key","onDragStart","e","target","dataset","slot","TreeItemLabel","propItem","disableHover","horizontalLines","hideChevron","chevronClassName","console","warn","data","getItemData","isLastNode","meta","lastNode","itemMeta","span","button","type","onClick","stopPropagation","collapse","expand","getItemName","TreeDragLine","getDragLineStyle","dragLine"],"mappings":";AACA,SAASA,eAAe,QAAQ,eAAe;AAC/C,SAASC,IAAI,QAAQ,WAAW;AAChC,YAAYC,WAAW,QAAQ;AAE/B,SAASC,EAAE,QAAQ,qBAAoB;AAgBvC,MAAMC,4BAAcF,MAAMG,aAAa,CAAmB;IACzDC,QAAQ;AACT;AAEA,oEAAoE;AACpE,SAASC;IACR,OAAOL,MAAMM,UAAU,CAACJ;AACzB;AAQA,SAASK,KAAK,EAAEH,SAAS,EAAE,EAAEI,IAAI,EAAEC,SAAS,EAAE,GAAGC,OAAkB;IAClE,MAAMC,iBACLH,QAAQ,OAAOA,KAAKI,iBAAiB,KAAK,aACvCJ,KAAKI,iBAAiB,KACtB,CAAC;IACL,MAAMC,cAAc;QAAE,GAAGH,KAAK;QAAE,GAAGC,cAAc;IAAC;IAElD,iEAAiE;IACjE,MAAM,EAAEG,OAAOC,SAAS,EAAE,GAAGC,YAAY,GAAGH;IAE5C,eAAe;IACf,MAAMI,cAAc;QACnB,GAAGF,SAAS;QACZ,iBAAiB,GAAGX,OAAO,EAAE,CAAC;QAC9B,YAAY,CAAC,6BAA6B,CAAC;IAC5C;IAEA,qBACC,KAACF,YAAYgB,QAAQ;QAACC,OAAO;YAAEf;YAAQI;QAAK;kBAC3C,cAAA,KAACY;YACAC,aAAU;YACVP,OAAOG;YACPR,WAAWR,GAAG,iBAAiBQ;YAC9B,GAAGO,UAAU;;;AAIlB;AAUA,oEAAoE;AACpE,SAASM,SAAkB,EAC1BC,IAAI,EACJd,SAAS,EACTe,OAAO,EACPC,QAAQ,EACR,GAAGf,OAC+B;IAClC,MAAM,EAAEN,MAAM,EAAE,GAAGC;IAEnB,MAAMqB,YAAY,OAAOH,KAAKI,QAAQ,KAAK,aAAaJ,KAAKI,QAAQ,KAAK,CAAC;IAC3E,MAAMd,cAAc;QAAE,GAAGH,KAAK;QAAE,GAAGgB,SAAS;IAAC;IAE7C,iEAAiE;IACjE,MAAM,EAAEZ,OAAOC,SAAS,EAAE,GAAGC,YAAY,GAAGH;IAE5C,eAAe;IACf,MAAMI,cAAc;QACnB,GAAGF,SAAS;QACZ,kBAAkB,GAAGQ,KAAKK,WAAW,GAAGC,KAAK,GAAGzB,OAAO,EAAE,CAAC;IAC3D;IAEA,MAAM0B,OAAON,UAAUzB,KAAKgC,IAAI,GAAG;IAEnC,qBACC,KAAC7B,YAAYgB,QAAQ;QAACC,OAAO;YAAEf;YAAQ4B,aAAaT;QAAK;kBACxD,cAAA,KAACO;YACAT,aAAU;YACVP,OAAOG;YACPR,WAAWR,GACV,iIACAQ;YAEDwB,cACC,OAAOV,KAAKW,SAAS,KAAK,aACvBX,KAAKW,SAAS,MAAM,QACpBC;YAEJC,eACC,OAAOb,KAAKc,QAAQ,KAAK,aACtBd,KAAKc,QAAQ,MAAM,QACnBF;YAEJG,iBACC,OAAOf,KAAKgB,UAAU,KAAK,aACxBhB,KAAKgB,UAAU,MAAM,QACrBJ;YAEJK,oBACC,OAAOjB,KAAKkB,YAAY,KAAK,aAC1BlB,KAAKkB,YAAY,MAAM,QACvBN;YAEJO,qBACC,OAAOnB,KAAKoB,gBAAgB,KAAK,aAC9BpB,KAAKoB,gBAAgB,MAAM,QAC3BR;YAEJS,iBAAerB,KAAKsB,UAAU;YAC7B,GAAGC,OAAOC,WAAW,CACrBD,OAAOE,OAAO,CAAChC,YAAYiC,MAAM,CAAC,CAAC,CAACC,IAAI,GAAKA,QAAQ,eACrD;YACDC,aAAa,CAACC;gBACb,IAAI,AAACA,EAAEC,MAAM,CAAiBC,OAAO,CAACC,IAAI,KAAK,eAAe;oBAC7DhC,KAAKI,QAAQ,GAAGwB,WAAW,GAAGC;gBAC/B;YACD;sBAEC3B;;;AAIL;AAYA,SAAS+B,cAAiB,EACzBjC,MAAMkC,QAAQ,EACdhC,QAAQ,EACRhB,SAAS,EACTiD,YAAY,EACZC,eAAe,EACfC,WAAW,EACXC,mBAAmB,kCAAkC,EACrD,GAAGnD,OAC+B;IAClC,MAAM,EAAEsB,WAAW,EAAE,GAAG3B;IACxB,MAAMkB,OAAOkC,YAAYzB;IAEzB,IAAI,CAACT,MAAM;QACVuC,QAAQC,IAAI,CAAC;QACb,OAAO;IACR;IAEA,MAAMC,OAAOzC,KAAK0C,WAAW;IAC7B,MAAMC,aAAaF,MAAMG,MAAMC;IAC/B,MAAMC,WAAW9C,KAAKK,WAAW;IAEjC,qBACC,MAAC0C;QACAjD,aAAU;QACVZ,WAAWR,GACV,4WACA,CAACyD,gBACA,+EACD,CAACA,gBACAnC,KAAKc,QAAQ,MACb,gEACD,CAACqB,gBACA,CAACnC,KAAKc,QAAQ,MACd,gEACDqB,gBAAgB,qBAChBjD;QAEA,GAAGC,KAAK;;YAERa,KAAKc,QAAQ,MAAM,CAACuB,6BACpB,KAACW;gBACAC,MAAK;gBACL/D,WAAWoD;gBACXY,SAAS,CAACrB;oBACTA,EAAEsB,eAAe;oBACjBnD,KAAKsB,UAAU,KAAKtB,KAAKoD,QAAQ,KAAKpD,KAAKqD,MAAM;gBAClD;0BAEA,cAAA,KAAC9E;oBAAgBW,WAAU;;;YAG5B,CAACc,KAAKc,QAAQ,MAAMsB,iCACpB,KAACvC;gBACAX,WAAW,CAAC,+CAA+C,CAAC;;YAG7Dc,KAAKc,QAAQ,MAAMd,KAAKsB,UAAU,MAAMc,iCACxC,KAACvC;gBACAX,WAAW,CAAC,6EAA6E,CAAC;;YAG3FkD,iCACA,KAACvC;gBACAX,WAAW,CAAC,+CAA+C,EAAEyD,aAAa,uBAAuB,GAAG,CAAC,EAAEG,SAASxC,KAAK,KAAK,IAAI,WAAW,IAAI;;YAG9IJ,YACC,CAAA,OAAOF,KAAKsD,WAAW,KAAK,aAAatD,KAAKsD,WAAW,KAAK,IAAG;;;AAGtE;AAEA,SAASC,aAAa,EACrBrE,SAAS,EACT,GAAGC,OACmC;IACtC,MAAM,EAAEF,IAAI,EAAE,GAAGH;IAEjB,IAAI,CAACG,QAAQ,OAAOA,KAAKuE,gBAAgB,KAAK,YAAY;QACzDjB,QAAQC,IAAI,CACX;QAED,OAAO;IACR;IAEA,MAAMiB,WAAWxE,KAAKuE,gBAAgB;IACtC,qBACC,KAAC3D;QACAN,OAAOkE;QACPvE,WAAWR,GACV,gMACAQ;QAEA,GAAGC,KAAK;;AAGZ;AAEA,SAASH,IAAI,EAAEe,QAAQ,EAAEkC,aAAa,EAAEsB,YAAY,GAAsB"}
@@ -78,7 +78,7 @@
78
78
  }
79
79
 
80
80
  .dark {
81
- --background: oklch(0.145 0 0);
81
+ --background: var(--color-bg-primary);
82
82
  --foreground: oklch(0.985 0 0);
83
83
  --card: oklch(0.205 0 0);
84
84
  --card-foreground: oklch(0.985 0 0);
@@ -101,11 +101,11 @@
101
101
  --chart-3: oklch(0.769 0.188 70.08);
102
102
  --chart-4: oklch(0.627 0.265 303.9);
103
103
  --chart-5: oklch(0.645 0.246 16.439);
104
- --sidebar: oklch(0.205 0 0);
104
+ --sidebar: var(--color-bg-primary);
105
105
  --sidebar-foreground: oklch(0.985 0 0);
106
106
  --sidebar-primary: oklch(0.488 0.243 264.376);
107
107
  --sidebar-primary-foreground: oklch(0.985 0 0);
108
- --sidebar-accent: oklch(0.269 0 0);
108
+ --sidebar-accent: oklch(0.205 0 0);
109
109
  --sidebar-accent-foreground: oklch(0.985 0 0);
110
110
  --sidebar-border: oklch(1 0 0 / 10%);
111
111
  --sidebar-ring: oklch(0.556 0 0);
@@ -116,7 +116,7 @@
116
116
  @apply border-border outline-ring/50;
117
117
  }
118
118
  body {
119
- @apply bg-background text-foreground;
119
+ @apply bg-background text-foreground caret-foreground;
120
120
  font-family: "Inter", system-ui, sans-serif;
121
121
  }
122
122
  }
@@ -40,8 +40,8 @@
40
40
  --color-red-50: #fef9f9;
41
41
  --color-red-100: #fff6f5;
42
42
  --color-red-200: #fdedea;
43
- --color-red-300: #f4a499;
44
- --color-red-400: #ea4a35;
43
+ --color-red-300: #f18b7e;
44
+ --color-red-400: #db2e17;
45
45
  --color-red-500: #d7270f;
46
46
  --color-red-600: #d7270f;
47
47
  --color-red-700: #c31b03;
@@ -54,7 +54,7 @@
54
54
  --color-blue-200: #e9f2fc;
55
55
  --color-blue-300: #d0e2f8;
56
56
  --color-blue-400: #a7c9f3;
57
- --color-blue-500: #2378e1;
57
+ --color-blue-500: #1e71d9;
58
58
  --color-blue-600: #045ac3;
59
59
  --color-blue-700: #014391;
60
60
  --color-blue-800: #053775;
@@ -66,25 +66,39 @@
66
66
  --color-green-200: #f1f8e6;
67
67
  --color-green-300: #e3efcb;
68
68
  --color-green-400: #c9e19b;
69
- --color-green-500: #78b506;
69
+ --color-green-500: #547f04;
70
70
  --color-green-600: #558300;
71
71
  --color-green-700: #334e02;
72
72
  --color-green-800: #1d2b03;
73
73
  --color-green-900: #090d04;
74
74
  --color-green-950: #090d04;
75
+ --color-green-550: #6aa300;
75
76
 
76
77
  --color-yellow-50: #fffdf2;
77
78
  --color-yellow-100: #fffbe5;
78
79
  --color-yellow-200: #fff9d9;
79
80
  --color-yellow-300: #fff4bf;
80
81
  --color-yellow-400: #ffea80;
81
- --color-yellow-500: #ffd400;
82
- --color-yellow-600: #dfa400;
82
+ --color-yellow-500: #f4cb00;
83
+ --color-yellow-600: #946c01;
83
84
  --color-yellow-700: #855600;
84
85
  --color-yellow-800: #562a00;
85
86
  --color-yellow-900: #341900;
86
87
  --color-yellow-950: #200900;
87
88
 
89
+ --color-violet-50: #fdf9fd;
90
+ --color-violet-100: #fcf2fb;
91
+ --color-violet-200: #faeaf8;
92
+ --color-violet-300: #f5d4f0;
93
+ --color-violet-400: #eba9e2;
94
+ --color-violet-500: #cc29b6;
95
+ --color-violet-600: #931e83;
96
+ --color-violet-700: #58124e;
97
+ --color-violet-800: #310a2c;
98
+ --color-violet-900: #10030f;
99
+ --color-violet-950: #080207;
100
+
101
+ --font-size-xxs: 10px;
88
102
  --font-size-xs: 12px;
89
103
  --font-size-sm: 14px;
90
104
  --font-size-base: 16px;
@@ -115,12 +129,12 @@
115
129
  --font-weight-extrabold: 800;
116
130
  --font-weight-black: 900;
117
131
 
118
- --font-tracking-tighter: -0.8;
119
- --font-tracking-tight: -0.4;
132
+ --font-tracking-tighter: -0.8px;
133
+ --font-tracking-tight: -0.4px;
120
134
  --font-tracking-normal: 0px;
121
- --font-tracking-wide: 0.4;
122
- --font-tracking-wider: 0.8;
123
- --font-tracking-widest: 1.6;
135
+ --font-tracking-wide: 0.4px;
136
+ --font-tracking-wider: 0.8px;
137
+ --font-tracking-widest: 1.6px;
124
138
 
125
139
  --font-leading-3: 12px;
126
140
  --font-leading-4: 16px;
@@ -146,34 +160,50 @@
146
160
  --corner-corner-m: 6px;
147
161
  --corner-corner-l: 8px;
148
162
  --corner-corner-xs: 2px;
149
- --color-elements-readable: var(--color-neutral-900);
150
163
  --color-cta: var(--color-brand-600);
151
164
  --color-critical-default: var(--color-red-600);
152
- --color-elements-disabled: var(--color-neutral-300);
153
- --color-elements-assistive: var(--color-neutral-500);
154
- --color-surface-0: var(--color-neutral-50);
155
- --color-border-default: var(--color-neutral-200);
156
- --color-surface-selected: var(--color-neutral-200);
157
165
  --color-cta-hover: var(--color-brand-700);
158
166
  --color-critical-hover: var(--color-red-700);
159
- --color-surface-1: var(--color-neutral-100);
160
167
  --color-border-XS-critical: var(--color-red-50);
161
168
  --color-border-XS-critical-hover: var(--color-red-100);
162
169
  --color-elements-green: var(--color-green-600);
163
170
  --color-elements-yellow: var(--color-yellow-500);
164
171
  --color-border-XS-regular: var(--color-blue-300);
165
172
  --color-border-XS-regular-hover: var(--color-blue-400);
166
- --color-separator: var(--color-neutral-200);
167
173
  --color-surface-info: var(--color-blue-50);
168
174
  --color-surface-warning: var(--color-yellow-50);
169
175
  --color-surface-alert: var(--color-red-50);
170
176
  --color-elements-warning: var(--color-yellow-700);
171
177
  --color-code-red: var(--color-red-600);
172
178
  --color-code-blue: var(--color-blue-500);
173
- --color-elements-readable-inv: var(--color-neutral-50);
174
179
  --color-logo-readable: var(--color-neutral-800);
175
180
  --color-elements-links: var(--color-brand-600);
176
181
  --color-elements-info: var(--color-brand-600);
177
182
  --color-elements-alert: var(--color-red-600);
178
183
  --color-illustrations-solid: var(--color-brand-600);
179
184
  }
185
+
186
+ /* Semantic tokens that need dark mode overrides — use @theme inline + :root so .dark can override */
187
+ @theme inline {
188
+ --color-elements-readable: var(--hs-elements-readable);
189
+ --color-elements-readable-inv: var(--hs-elements-readable-inv);
190
+ --color-elements-assistive: var(--hs-elements-assistive);
191
+ --color-elements-disabled: var(--hs-elements-disabled);
192
+ --color-surface-0: var(--hs-surface-0);
193
+ --color-surface-1: var(--hs-surface-1);
194
+ --color-surface-selected: var(--hs-surface-selected);
195
+ --color-border-default: var(--hs-border-default);
196
+ --color-separator: var(--hs-separator);
197
+ }
198
+
199
+ :root {
200
+ --hs-elements-readable: var(--color-neutral-900);
201
+ --hs-elements-readable-inv: var(--color-neutral-50);
202
+ --hs-elements-assistive: var(--color-neutral-500);
203
+ --hs-elements-disabled: var(--color-neutral-300);
204
+ --hs-surface-0: var(--color-neutral-50);
205
+ --hs-surface-1: var(--color-neutral-100);
206
+ --hs-surface-selected: var(--color-neutral-200);
207
+ --hs-border-default: var(--color-neutral-200);
208
+ --hs-separator: var(--color-neutral-200);
209
+ }