@kumix/ui 0.3.12 → 0.3.13

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 (530) hide show
  1. package/README.md +1 -1
  2. package/dist/components/agents/agent-activity/activity-row.js +2 -2
  3. package/dist/components/agents/agent-activity/activity-row.js.map +1 -1
  4. package/dist/components/agents/agent-activity/index.js +2 -2
  5. package/dist/components/agents/agent-activity/index.js.map +1 -1
  6. package/dist/components/agents/agent-code.d.ts.map +1 -1
  7. package/dist/components/agents/agent-code.js +2 -2
  8. package/dist/components/agents/agent-code.js.map +1 -1
  9. package/dist/components/agents/agent-disclosure.js +1 -1
  10. package/dist/components/agents/agent-disclosure.js.map +1 -1
  11. package/dist/components/agents/ai-sidebar.js +2 -2
  12. package/dist/components/agents/ai-sidebar.js.map +1 -1
  13. package/dist/components/agents/approval-card/index.js +2 -2
  14. package/dist/components/agents/approval-card/index.js.map +1 -1
  15. package/dist/components/agents/chat-app.js +1 -1
  16. package/dist/components/agents/chat-app.js.map +1 -1
  17. package/dist/components/agents/citations.js +2 -2
  18. package/dist/components/agents/citations.js.map +1 -1
  19. package/dist/components/agents/code-block.js +2 -2
  20. package/dist/components/agents/code-block.js.map +1 -1
  21. package/dist/components/agents/file-diff.js +2 -2
  22. package/dist/components/agents/file-diff.js.map +1 -1
  23. package/dist/components/agents/image-generation.js +2 -2
  24. package/dist/components/agents/image-generation.js.map +1 -1
  25. package/dist/components/agents/loading-states/agent-progress.js +1 -1
  26. package/dist/components/agents/loading-states/agent-progress.js.map +1 -1
  27. package/dist/components/agents/loading-states/reasoning-text.js +1 -1
  28. package/dist/components/agents/loading-states/reasoning-text.js.map +1 -1
  29. package/dist/components/agents/loading-states/thinking-shimmer.js +1 -1
  30. package/dist/components/agents/loading-states/thinking-shimmer.js.map +1 -1
  31. package/dist/components/agents/message-bubble.js +2 -2
  32. package/dist/components/agents/message-bubble.js.map +1 -1
  33. package/dist/components/agents/message-scroller.js +1 -1
  34. package/dist/components/agents/message-scroller.js.map +1 -1
  35. package/dist/components/agents/message.js +1 -1
  36. package/dist/components/agents/message.js.map +1 -1
  37. package/dist/components/agents/prompt-input.js +2 -2
  38. package/dist/components/agents/prompt-input.js.map +1 -1
  39. package/dist/components/agents/streaming-response.js +2 -2
  40. package/dist/components/agents/streaming-response.js.map +1 -1
  41. package/dist/components/agents/todo-list.js +2 -2
  42. package/dist/components/agents/todo-list.js.map +1 -1
  43. package/dist/components/agents/tool-approval.js +2 -2
  44. package/dist/components/agents/tool-approval.js.map +1 -1
  45. package/dist/components/agents/tool-result.js +2 -2
  46. package/dist/components/agents/tool-result.js.map +1 -1
  47. package/dist/components/custom/confirm-dialog.js +1 -1
  48. package/dist/components/motion/action-swap.js +1 -1
  49. package/dist/components/motion/action-swap.js.map +1 -1
  50. package/dist/components/motion/adaptive-stepper.js +2 -2
  51. package/dist/components/motion/adaptive-stepper.js.map +1 -1
  52. package/dist/components/motion/animated-badge.js +2 -2
  53. package/dist/components/motion/animated-badge.js.map +1 -1
  54. package/dist/components/motion/animated-number.js +1 -1
  55. package/dist/components/motion/animated-number.js.map +1 -1
  56. package/dist/components/motion/animated-sidebar.js +2 -2
  57. package/dist/components/motion/animated-sidebar.js.map +1 -1
  58. package/dist/components/motion/animated-toast-stack.js +2 -2
  59. package/dist/components/motion/animated-toast-stack.js.map +1 -1
  60. package/dist/components/motion/attachment-upload.js +2 -2
  61. package/dist/components/motion/attachment-upload.js.map +1 -1
  62. package/dist/components/motion/availability-scheduler/copy-menu.js +1 -1
  63. package/dist/components/motion/availability-scheduler/day-row.js +2 -2
  64. package/dist/components/motion/availability-scheduler/icon-button.js +1 -1
  65. package/dist/components/motion/availability-scheduler/icon-button.js.map +1 -1
  66. package/dist/components/motion/availability-scheduler/index.js +2 -2
  67. package/dist/components/motion/availability-scheduler/index.js.map +1 -1
  68. package/dist/components/motion/bloom-menu.js +2 -2
  69. package/dist/components/motion/bloom-menu.js.map +1 -1
  70. package/dist/components/motion/bottom-sheet.js +1 -1
  71. package/dist/components/motion/bottom-sheet.js.map +1 -1
  72. package/dist/components/motion/bounce-sidebar.d.ts.map +1 -1
  73. package/dist/components/motion/bounce-sidebar.js +1 -1
  74. package/dist/components/motion/bounce-sidebar.js.map +1 -1
  75. package/dist/components/motion/bouncy-accordion.js +2 -2
  76. package/dist/components/motion/bouncy-accordion.js.map +1 -1
  77. package/dist/components/motion/button/base.js +1 -1
  78. package/dist/components/motion/button/base.js.map +1 -1
  79. package/dist/components/motion/button/metallic.js +1 -1
  80. package/dist/components/motion/button/metallic.js.map +1 -1
  81. package/dist/components/motion/button/stateful.js +1 -1
  82. package/dist/components/motion/card-folder.d.ts +30 -0
  83. package/dist/components/motion/card-folder.d.ts.map +1 -0
  84. package/dist/components/motion/card-folder.js +254 -0
  85. package/dist/components/motion/card-folder.js.map +1 -0
  86. package/dist/components/motion/center-morph-modal.js +2 -2
  87. package/dist/components/motion/center-morph-modal.js.map +1 -1
  88. package/dist/components/motion/checkbox.js +1 -1
  89. package/dist/components/motion/checkbox.js.map +1 -1
  90. package/dist/components/motion/chromatic-text-reveal.js +1 -1
  91. package/dist/components/motion/chromatic-text-reveal.js.map +1 -1
  92. package/dist/components/motion/combobox/content.js +1 -1
  93. package/dist/components/motion/combobox/content.js.map +1 -1
  94. package/dist/components/motion/combobox/context.js +1 -1
  95. package/dist/components/motion/combobox/context.js.map +1 -1
  96. package/dist/components/motion/combobox/list.js +2 -2
  97. package/dist/components/motion/combobox/list.js.map +1 -1
  98. package/dist/components/motion/combobox/trigger.js +2 -2
  99. package/dist/components/motion/combobox/trigger.js.map +1 -1
  100. package/dist/components/motion/command-palette.js +2 -2
  101. package/dist/components/motion/command-palette.js.map +1 -1
  102. package/dist/components/motion/context-menu.js +2 -2
  103. package/dist/components/motion/context-menu.js.map +1 -1
  104. package/dist/components/motion/cylinder-carousel.js +1 -1
  105. package/dist/components/motion/cylinder-carousel.js.map +1 -1
  106. package/dist/components/motion/digit-swap.d.ts +23 -0
  107. package/dist/components/motion/digit-swap.d.ts.map +1 -0
  108. package/dist/components/motion/digit-swap.js +77 -0
  109. package/dist/components/motion/digit-swap.js.map +1 -0
  110. package/dist/components/motion/dock.js +1 -1
  111. package/dist/components/motion/dock.js.map +1 -1
  112. package/dist/components/motion/drawer.js +1 -1
  113. package/dist/components/motion/drawer.js.map +1 -1
  114. package/dist/components/motion/dynamic-island.js +1 -1
  115. package/dist/components/motion/dynamic-island.js.map +1 -1
  116. package/dist/components/motion/expandable-action-bar.js +1 -1
  117. package/dist/components/motion/expandable-action-bar.js.map +1 -1
  118. package/dist/components/motion/expandable-control.d.ts.map +1 -1
  119. package/dist/components/motion/expandable-control.js +1 -1
  120. package/dist/components/motion/expandable-control.js.map +1 -1
  121. package/dist/components/motion/expandable-tabs.js +1 -1
  122. package/dist/components/motion/expandable-tabs.js.map +1 -1
  123. package/dist/components/motion/expanding-arrow-button.js +1 -1
  124. package/dist/components/motion/expanding-arrow-button.js.map +1 -1
  125. package/dist/components/motion/feedback-widget.js +2 -2
  126. package/dist/components/motion/feedback-widget.js.map +1 -1
  127. package/dist/components/motion/file-tree.js +2 -2
  128. package/dist/components/motion/file-tree.js.map +1 -1
  129. package/dist/components/motion/file-upload.js +2 -2
  130. package/dist/components/motion/file-upload.js.map +1 -1
  131. package/dist/components/motion/hold-action-button.js +1 -1
  132. package/dist/components/motion/hold-action-button.js.map +1 -1
  133. package/dist/components/motion/infinite-masonry.js +2 -2
  134. package/dist/components/motion/infinite-masonry.js.map +1 -1
  135. package/dist/components/motion/input.d.ts.map +1 -1
  136. package/dist/components/motion/input.js +1 -1
  137. package/dist/components/motion/input.js.map +1 -1
  138. package/dist/components/motion/liquid.js +1 -1
  139. package/dist/components/motion/liquid.js.map +1 -1
  140. package/dist/components/motion/loader.js +1 -1
  141. package/dist/components/motion/loader.js.map +1 -1
  142. package/dist/components/motion/magnetic.js +1 -1
  143. package/dist/components/motion/magnetic.js.map +1 -1
  144. package/dist/components/motion/marquee.d.ts.map +1 -1
  145. package/dist/components/motion/marquee.js +1 -1
  146. package/dist/components/motion/marquee.js.map +1 -1
  147. package/dist/components/motion/morphing-modal.js +1 -1
  148. package/dist/components/motion/morphing-modal.js.map +1 -1
  149. package/dist/components/motion/morphing-search.js +2 -2
  150. package/dist/components/motion/morphing-search.js.map +1 -1
  151. package/dist/components/motion/morphing-tabs.js +2 -2
  152. package/dist/components/motion/morphing-tabs.js.map +1 -1
  153. package/dist/components/motion/multi-select/content.js +1 -1
  154. package/dist/components/motion/multi-select/content.js.map +1 -1
  155. package/dist/components/motion/multi-select/context.js +1 -1
  156. package/dist/components/motion/multi-select/context.js.map +1 -1
  157. package/dist/components/motion/multi-select/list.js +2 -2
  158. package/dist/components/motion/multi-select/list.js.map +1 -1
  159. package/dist/components/motion/multi-select/trigger.js +2 -2
  160. package/dist/components/motion/multi-select/trigger.js.map +1 -1
  161. package/dist/components/motion/not-found/magnetic.d.ts.map +1 -1
  162. package/dist/components/motion/not-found/magnetic.js +1 -1
  163. package/dist/components/motion/not-found/magnetic.js.map +1 -1
  164. package/dist/components/motion/not-found/shared.js +1 -1
  165. package/dist/components/motion/not-found/shared.js.map +1 -1
  166. package/dist/components/motion/not-found/spotlight.js +1 -1
  167. package/dist/components/motion/not-found/spotlight.js.map +1 -1
  168. package/dist/components/motion/notification-stack.js +2 -2
  169. package/dist/components/motion/notification-stack.js.map +1 -1
  170. package/dist/components/motion/number-ticker.js +1 -1
  171. package/dist/components/motion/number-ticker.js.map +1 -1
  172. package/dist/components/motion/otp-input.js +1 -1
  173. package/dist/components/motion/otp-input.js.map +1 -1
  174. package/dist/components/motion/overflow-actions.js +2 -2
  175. package/dist/components/motion/overflow-actions.js.map +1 -1
  176. package/dist/components/motion/parallax.d.ts.map +1 -1
  177. package/dist/components/motion/parallax.js +1 -1
  178. package/dist/components/motion/parallax.js.map +1 -1
  179. package/dist/components/motion/popover-morph.js +1 -1
  180. package/dist/components/motion/popover-morph.js.map +1 -1
  181. package/dist/components/motion/popover.js +1 -1
  182. package/dist/components/motion/popover.js.map +1 -1
  183. package/dist/components/motion/preview-rail.js +1 -1
  184. package/dist/components/motion/preview-rail.js.map +1 -1
  185. package/dist/components/motion/project-folder.js +2 -2
  186. package/dist/components/motion/project-folder.js.map +1 -1
  187. package/dist/components/motion/pull-to-refresh.js +1 -1
  188. package/dist/components/motion/pull-to-refresh.js.map +1 -1
  189. package/dist/components/motion/radio.js +1 -1
  190. package/dist/components/motion/radio.js.map +1 -1
  191. package/dist/components/motion/range-slider-bubble.js +1 -1
  192. package/dist/components/motion/range-slider-bubble.js.map +1 -1
  193. package/dist/components/motion/range-slider-fluid.js +1 -1
  194. package/dist/components/motion/range-slider-fluid.js.map +1 -1
  195. package/dist/components/motion/range-slider-ruler.js +1 -1
  196. package/dist/components/motion/range-slider-ruler.js.map +1 -1
  197. package/dist/components/motion/range-slider-wave.js +1 -1
  198. package/dist/components/motion/range-slider-wave.js.map +1 -1
  199. package/dist/components/motion/range-slider.js +1 -1
  200. package/dist/components/motion/range-slider.js.map +1 -1
  201. package/dist/components/motion/scroll-progress.js +1 -1
  202. package/dist/components/motion/scroll-progress.js.map +1 -1
  203. package/dist/components/motion/scroll-reveal.js +1 -1
  204. package/dist/components/motion/scroll-reveal.js.map +1 -1
  205. package/dist/components/motion/scroll-to.js +1 -1
  206. package/dist/components/motion/scroll-to.js.map +1 -1
  207. package/dist/components/motion/select-morph.d.ts.map +1 -1
  208. package/dist/components/motion/select-morph.js +2 -2
  209. package/dist/components/motion/select-morph.js.map +1 -1
  210. package/dist/components/motion/select.js +2 -2
  211. package/dist/components/motion/select.js.map +1 -1
  212. package/dist/components/motion/shader-background.d.ts.map +1 -1
  213. package/dist/components/motion/shader-background.js +1 -1
  214. package/dist/components/motion/shader-background.js.map +1 -1
  215. package/dist/components/motion/shared-layout-bg.js +1 -1
  216. package/dist/components/motion/shared-layout-bg.js.map +1 -1
  217. package/dist/components/motion/signup-form.js +2 -2
  218. package/dist/components/motion/signup-form.js.map +1 -1
  219. package/dist/components/motion/slide-action-button.js +1 -1
  220. package/dist/components/motion/slide-action-button.js.map +1 -1
  221. package/dist/components/motion/swipeable-list.js +1 -1
  222. package/dist/components/motion/swipeable-list.js.map +1 -1
  223. package/dist/components/motion/switch.d.ts.map +1 -1
  224. package/dist/components/motion/switch.js +1 -1
  225. package/dist/components/motion/switch.js.map +1 -1
  226. package/dist/components/motion/table/index.js +1 -1
  227. package/dist/components/motion/table/index.js.map +1 -1
  228. package/dist/components/motion/table/row-handle.js +1 -1
  229. package/dist/components/motion/table/skeleton-rows.d.ts.map +1 -1
  230. package/dist/components/motion/table/skeleton-rows.js +1 -1
  231. package/dist/components/motion/table/skeleton-rows.js.map +1 -1
  232. package/dist/components/motion/table/table-header.js +2 -2
  233. package/dist/components/motion/table/table-header.js.map +1 -1
  234. package/dist/components/motion/table/table-menu.js +1 -1
  235. package/dist/components/motion/table/table-menu.js.map +1 -1
  236. package/dist/components/motion/tabs.js +1 -1
  237. package/dist/components/motion/tabs.js.map +1 -1
  238. package/dist/components/motion/text-reveal.js +1 -1
  239. package/dist/components/motion/text-reveal.js.map +1 -1
  240. package/dist/components/motion/text-scramble.d.ts.map +1 -1
  241. package/dist/components/motion/text-scramble.js +1 -1
  242. package/dist/components/motion/text-scramble.js.map +1 -1
  243. package/dist/components/motion/text-shimmer.js +1 -1
  244. package/dist/components/motion/text-shimmer.js.map +1 -1
  245. package/dist/components/motion/theme-toggle.js +2 -2
  246. package/dist/components/motion/theme-toggle.js.map +1 -1
  247. package/dist/components/motion/tilt-card.js +1 -1
  248. package/dist/components/motion/tilt-card.js.map +1 -1
  249. package/dist/components/motion/tooltip.js +1 -1
  250. package/dist/components/motion/tooltip.js.map +1 -1
  251. package/dist/components/motion/wheel-picker.js +1 -1
  252. package/dist/components/motion/wheel-picker.js.map +1 -1
  253. package/dist/components/reui/alert.d.ts +1 -1
  254. package/dist/components/reui/alert.d.ts.map +1 -1
  255. package/dist/components/reui/alert.js +2 -2
  256. package/dist/components/reui/alert.js.map +1 -1
  257. package/dist/components/reui/autocomplete.d.ts +1 -1
  258. package/dist/components/reui/autocomplete.js +2 -2
  259. package/dist/components/reui/autocomplete.js.map +1 -1
  260. package/dist/components/reui/badge.d.ts +2 -2
  261. package/dist/components/reui/badge.d.ts.map +1 -1
  262. package/dist/components/reui/badge.js +1 -1
  263. package/dist/components/reui/badge.js.map +1 -1
  264. package/dist/components/reui/cascader/cascader-columns.js +2 -2
  265. package/dist/components/reui/cascader/cascader-columns.js.map +1 -1
  266. package/dist/components/reui/cascader/cascader-footer.js +2 -2
  267. package/dist/components/reui/cascader/cascader-footer.js.map +1 -1
  268. package/dist/components/reui/cascader/cascader-item.js +2 -2
  269. package/dist/components/reui/cascader/cascader-item.js.map +1 -1
  270. package/dist/components/reui/cascader/cascader-nav.js +2 -2
  271. package/dist/components/reui/cascader/cascader-nav.js.map +1 -1
  272. package/dist/components/reui/cascader/cascader.js +2 -2
  273. package/dist/components/reui/cascader/cascader.js.map +1 -1
  274. package/dist/components/reui/code-block/code-block.js +1 -1
  275. package/dist/components/reui/code-block/code-block.js.map +1 -1
  276. package/dist/components/reui/data-grid/data-grid-cell-selection.js +1 -1
  277. package/dist/components/reui/data-grid/data-grid-cell-selection.js.map +1 -1
  278. package/dist/components/reui/data-grid/data-grid-column-filter.js +2 -2
  279. package/dist/components/reui/data-grid/data-grid-column-filter.js.map +1 -1
  280. package/dist/components/reui/data-grid/data-grid-column-header.js +2 -2
  281. package/dist/components/reui/data-grid/data-grid-column-header.js.map +1 -1
  282. package/dist/components/reui/data-grid/data-grid-pagination.js +2 -2
  283. package/dist/components/reui/data-grid/data-grid-pagination.js.map +1 -1
  284. package/dist/components/reui/data-grid/data-grid-scroll-area.js +1 -1
  285. package/dist/components/reui/data-grid/data-grid-scroll-area.js.map +1 -1
  286. package/dist/components/reui/data-grid/data-grid-table-dnd-rows.js +2 -2
  287. package/dist/components/reui/data-grid/data-grid-table-dnd-rows.js.map +1 -1
  288. package/dist/components/reui/data-grid/data-grid-table-dnd.js +1 -1
  289. package/dist/components/reui/data-grid/data-grid-table-virtual.js +1 -1
  290. package/dist/components/reui/data-grid/data-grid-table-virtual.js.map +1 -1
  291. package/dist/components/reui/data-grid/data-grid-table.js +2 -2
  292. package/dist/components/reui/data-grid/data-grid-table.js.map +1 -1
  293. package/dist/components/reui/data-grid/data-grid.js +1 -1
  294. package/dist/components/reui/data-grid/data-grid.js.map +1 -1
  295. package/dist/components/reui/date-selector.js +2 -2
  296. package/dist/components/reui/date-selector.js.map +1 -1
  297. package/dist/components/reui/event-calendar/event-calendar-agenda-view.js +2 -2
  298. package/dist/components/reui/event-calendar/event-calendar-agenda-view.js.map +1 -1
  299. package/dist/components/reui/event-calendar/event-calendar-content.js +1 -1
  300. package/dist/components/reui/event-calendar/event-calendar-content.js.map +1 -1
  301. package/dist/components/reui/event-calendar/event-calendar-event.js +2 -2
  302. package/dist/components/reui/event-calendar/event-calendar-event.js.map +1 -1
  303. package/dist/components/reui/event-calendar/event-calendar-month-view.js +2 -2
  304. package/dist/components/reui/event-calendar/event-calendar-month-view.js.map +1 -1
  305. package/dist/components/reui/event-calendar/event-calendar-nav.js +2 -2
  306. package/dist/components/reui/event-calendar/event-calendar-nav.js.map +1 -1
  307. package/dist/components/reui/event-calendar/event-calendar-resource-view.js +1 -1
  308. package/dist/components/reui/event-calendar/event-calendar-resource-view.js.map +1 -1
  309. package/dist/components/reui/event-calendar/event-calendar-time-grid.js +1 -1
  310. package/dist/components/reui/event-calendar/event-calendar-time-grid.js.map +1 -1
  311. package/dist/components/reui/event-calendar/event-calendar.js +1 -1
  312. package/dist/components/reui/event-calendar/event-calendar.js.map +1 -1
  313. package/dist/components/reui/filters/filters-advanced.js +2 -2
  314. package/dist/components/reui/filters/filters-advanced.js.map +1 -1
  315. package/dist/components/reui/filters/filters-builder.js +3 -3
  316. package/dist/components/reui/filters/filters-builder.js.map +1 -1
  317. package/dist/components/reui/filters/filters-chip.js +2 -2
  318. package/dist/components/reui/filters/filters-chip.js.map +1 -1
  319. package/dist/components/reui/filters/filters-editors.js +3 -3
  320. package/dist/components/reui/filters/filters-editors.js.map +1 -1
  321. package/dist/components/reui/filters/filters.js +2 -2
  322. package/dist/components/reui/filters/filters.js.map +1 -1
  323. package/dist/components/reui/frame.d.ts +2 -2
  324. package/dist/components/reui/frame.d.ts.map +1 -1
  325. package/dist/components/reui/frame.js +2 -2
  326. package/dist/components/reui/frame.js.map +1 -1
  327. package/dist/components/reui/gantt/gantt-bar.js +2 -2
  328. package/dist/components/reui/gantt/gantt-bar.js.map +1 -1
  329. package/dist/components/reui/gantt/gantt-nav.js +2 -2
  330. package/dist/components/reui/gantt/gantt-nav.js.map +1 -1
  331. package/dist/components/reui/gantt/gantt-view.js +2 -2
  332. package/dist/components/reui/gantt/gantt-view.js.map +1 -1
  333. package/dist/components/reui/gantt/gantt.js +1 -1
  334. package/dist/components/reui/gantt/gantt.js.map +1 -1
  335. package/dist/components/reui/icon-stack.js +1 -1
  336. package/dist/components/reui/icon-stack.js.map +1 -1
  337. package/dist/components/reui/icon-tile.d.ts +2 -2
  338. package/dist/components/reui/icon-tile.d.ts.map +1 -1
  339. package/dist/components/reui/icon-tile.js +1 -1
  340. package/dist/components/reui/icon-tile.js.map +1 -1
  341. package/dist/components/reui/kanban.d.ts.map +1 -1
  342. package/dist/components/reui/kanban.js +1 -1
  343. package/dist/components/reui/kanban.js.map +1 -1
  344. package/dist/components/reui/number-field.d.ts +3 -3
  345. package/dist/components/reui/number-field.js +2 -2
  346. package/dist/components/reui/number-field.js.map +1 -1
  347. package/dist/components/reui/phone-input.js +2 -2
  348. package/dist/components/reui/phone-input.js.map +1 -1
  349. package/dist/components/reui/rating.d.ts +1 -1
  350. package/dist/components/reui/rating.d.ts.map +1 -1
  351. package/dist/components/reui/rating.js +2 -2
  352. package/dist/components/reui/rating.js.map +1 -1
  353. package/dist/components/reui/sortable.d.ts.map +1 -1
  354. package/dist/components/reui/sortable.js +1 -1
  355. package/dist/components/reui/sortable.js.map +1 -1
  356. package/dist/components/reui/stepper.d.ts.map +1 -1
  357. package/dist/components/reui/stepper.js +1 -1
  358. package/dist/components/reui/stepper.js.map +1 -1
  359. package/dist/components/reui/timeline.d.ts.map +1 -1
  360. package/dist/components/reui/timeline.js +1 -1
  361. package/dist/components/reui/timeline.js.map +1 -1
  362. package/dist/components/reui/tree.d.ts.map +1 -1
  363. package/dist/components/reui/tree.js +2 -2
  364. package/dist/components/reui/tree.js.map +1 -1
  365. package/dist/components/ui/accordion.d.ts.map +1 -1
  366. package/dist/components/ui/accordion.js +2 -2
  367. package/dist/components/ui/accordion.js.map +1 -1
  368. package/dist/components/ui/alert-dialog.js +2 -2
  369. package/dist/components/ui/alert-dialog.js.map +1 -1
  370. package/dist/components/ui/alert.d.ts.map +1 -1
  371. package/dist/components/ui/alert.js +2 -2
  372. package/dist/components/ui/alert.js.map +1 -1
  373. package/dist/components/ui/aspect-ratio.js +1 -1
  374. package/dist/components/ui/aspect-ratio.js.map +1 -1
  375. package/dist/components/ui/attachment.d.ts +1 -1
  376. package/dist/components/ui/attachment.js +2 -2
  377. package/dist/components/ui/attachment.js.map +1 -1
  378. package/dist/components/ui/avatar.d.ts.map +1 -1
  379. package/dist/components/ui/avatar.js +1 -1
  380. package/dist/components/ui/avatar.js.map +1 -1
  381. package/dist/components/ui/badge.d.ts +1 -1
  382. package/dist/components/ui/badge.d.ts.map +1 -1
  383. package/dist/components/ui/badge.js +1 -1
  384. package/dist/components/ui/badge.js.map +1 -1
  385. package/dist/components/ui/breadcrumb.d.ts.map +1 -1
  386. package/dist/components/ui/breadcrumb.js +2 -2
  387. package/dist/components/ui/breadcrumb.js.map +1 -1
  388. package/dist/components/ui/bubble.d.ts +1 -1
  389. package/dist/components/ui/bubble.d.ts.map +1 -1
  390. package/dist/components/ui/bubble.js +2 -2
  391. package/dist/components/ui/bubble.js.map +1 -1
  392. package/dist/components/ui/button-group.js +2 -2
  393. package/dist/components/ui/button-group.js.map +1 -1
  394. package/dist/components/ui/button.d.ts +2 -2
  395. package/dist/components/ui/button.d.ts.map +1 -1
  396. package/dist/components/ui/button.js +2 -2
  397. package/dist/components/ui/button.js.map +1 -1
  398. package/dist/components/ui/calendar.js +2 -2
  399. package/dist/components/ui/calendar.js.map +1 -1
  400. package/dist/components/ui/card.d.ts.map +1 -1
  401. package/dist/components/ui/card.js +1 -1
  402. package/dist/components/ui/card.js.map +1 -1
  403. package/dist/components/ui/carousel.js +2 -2
  404. package/dist/components/ui/carousel.js.map +1 -1
  405. package/dist/components/ui/chart.d.ts.map +1 -1
  406. package/dist/components/ui/chart.js +1 -1
  407. package/dist/components/ui/chart.js.map +1 -1
  408. package/dist/components/ui/checkbox.d.ts.map +1 -1
  409. package/dist/components/ui/checkbox.js +3 -3
  410. package/dist/components/ui/checkbox.js.map +1 -1
  411. package/dist/components/ui/combobox.js +2 -2
  412. package/dist/components/ui/combobox.js.map +1 -1
  413. package/dist/components/ui/command.js +2 -2
  414. package/dist/components/ui/command.js.map +1 -1
  415. package/dist/components/ui/context-menu.d.ts.map +1 -1
  416. package/dist/components/ui/context-menu.js +2 -2
  417. package/dist/components/ui/context-menu.js.map +1 -1
  418. package/dist/components/ui/dialog.js +2 -2
  419. package/dist/components/ui/dialog.js.map +1 -1
  420. package/dist/components/ui/drawer.d.ts.map +1 -1
  421. package/dist/components/ui/drawer.js +1 -1
  422. package/dist/components/ui/drawer.js.map +1 -1
  423. package/dist/components/ui/dropdown-menu.d.ts.map +1 -1
  424. package/dist/components/ui/dropdown-menu.js +2 -2
  425. package/dist/components/ui/dropdown-menu.js.map +1 -1
  426. package/dist/components/ui/empty.d.ts.map +1 -1
  427. package/dist/components/ui/empty.js +2 -2
  428. package/dist/components/ui/empty.js.map +1 -1
  429. package/dist/components/ui/field.js +3 -3
  430. package/dist/components/ui/field.js.map +1 -1
  431. package/dist/components/ui/hover-card.d.ts.map +1 -1
  432. package/dist/components/ui/hover-card.js +1 -1
  433. package/dist/components/ui/hover-card.js.map +1 -1
  434. package/dist/components/ui/input-group.d.ts +1 -1
  435. package/dist/components/ui/input-group.js +2 -2
  436. package/dist/components/ui/input-group.js.map +1 -1
  437. package/dist/components/ui/input-otp.d.ts.map +1 -1
  438. package/dist/components/ui/input-otp.js +2 -2
  439. package/dist/components/ui/input-otp.js.map +1 -1
  440. package/dist/components/ui/input.d.ts.map +1 -1
  441. package/dist/components/ui/input.js +1 -1
  442. package/dist/components/ui/input.js.map +1 -1
  443. package/dist/components/ui/item.d.ts +1 -1
  444. package/dist/components/ui/item.js +2 -2
  445. package/dist/components/ui/item.js.map +1 -1
  446. package/dist/components/ui/kbd.js +1 -1
  447. package/dist/components/ui/kbd.js.map +1 -1
  448. package/dist/components/ui/label.d.ts.map +1 -1
  449. package/dist/components/ui/label.js +1 -1
  450. package/dist/components/ui/label.js.map +1 -1
  451. package/dist/components/ui/marker.d.ts.map +1 -1
  452. package/dist/components/ui/marker.js +2 -2
  453. package/dist/components/ui/marker.js.map +1 -1
  454. package/dist/components/ui/menubar.js +2 -2
  455. package/dist/components/ui/menubar.js.map +1 -1
  456. package/dist/components/ui/message-scroller.js +2 -2
  457. package/dist/components/ui/message-scroller.js.map +1 -1
  458. package/dist/components/ui/message.d.ts.map +1 -1
  459. package/dist/components/ui/message.js +1 -1
  460. package/dist/components/ui/message.js.map +1 -1
  461. package/dist/components/ui/native-select.d.ts.map +1 -1
  462. package/dist/components/ui/native-select.js +2 -2
  463. package/dist/components/ui/native-select.js.map +1 -1
  464. package/dist/components/ui/navigation-menu.d.ts.map +1 -1
  465. package/dist/components/ui/navigation-menu.js +2 -2
  466. package/dist/components/ui/navigation-menu.js.map +1 -1
  467. package/dist/components/ui/pagination.js +2 -2
  468. package/dist/components/ui/pagination.js.map +1 -1
  469. package/dist/components/ui/popover.d.ts.map +1 -1
  470. package/dist/components/ui/popover.js +1 -1
  471. package/dist/components/ui/popover.js.map +1 -1
  472. package/dist/components/ui/progress.d.ts.map +1 -1
  473. package/dist/components/ui/progress.js +1 -1
  474. package/dist/components/ui/progress.js.map +1 -1
  475. package/dist/components/ui/questionnaire.js +4 -4
  476. package/dist/components/ui/questionnaire.js.map +1 -1
  477. package/dist/components/ui/radio-group.d.ts.map +1 -1
  478. package/dist/components/ui/radio-group.js +2 -2
  479. package/dist/components/ui/radio-group.js.map +1 -1
  480. package/dist/components/ui/resizable.d.ts.map +1 -1
  481. package/dist/components/ui/resizable.js +1 -1
  482. package/dist/components/ui/resizable.js.map +1 -1
  483. package/dist/components/ui/scroll-area.d.ts.map +1 -1
  484. package/dist/components/ui/scroll-area.js +1 -1
  485. package/dist/components/ui/scroll-area.js.map +1 -1
  486. package/dist/components/ui/select.d.ts.map +1 -1
  487. package/dist/components/ui/select.js +2 -2
  488. package/dist/components/ui/select.js.map +1 -1
  489. package/dist/components/ui/separator.d.ts.map +1 -1
  490. package/dist/components/ui/separator.js +1 -1
  491. package/dist/components/ui/separator.js.map +1 -1
  492. package/dist/components/ui/sheet.js +2 -2
  493. package/dist/components/ui/sheet.js.map +1 -1
  494. package/dist/components/ui/sidebar.d.ts +1 -1
  495. package/dist/components/ui/sidebar.js +2 -2
  496. package/dist/components/ui/sidebar.js.map +1 -1
  497. package/dist/components/ui/skeleton.js +1 -1
  498. package/dist/components/ui/skeleton.js.map +1 -1
  499. package/dist/components/ui/slider.d.ts.map +1 -1
  500. package/dist/components/ui/slider.js +1 -1
  501. package/dist/components/ui/slider.js.map +1 -1
  502. package/dist/components/ui/spinner.d.ts.map +1 -1
  503. package/dist/components/ui/spinner.js +2 -2
  504. package/dist/components/ui/spinner.js.map +1 -1
  505. package/dist/components/ui/switch.d.ts.map +1 -1
  506. package/dist/components/ui/switch.js +2 -2
  507. package/dist/components/ui/switch.js.map +1 -1
  508. package/dist/components/ui/table.d.ts.map +1 -1
  509. package/dist/components/ui/table.js +1 -1
  510. package/dist/components/ui/table.js.map +1 -1
  511. package/dist/components/ui/tabs.d.ts.map +1 -1
  512. package/dist/components/ui/tabs.js +2 -2
  513. package/dist/components/ui/tabs.js.map +1 -1
  514. package/dist/components/ui/textarea.d.ts.map +1 -1
  515. package/dist/components/ui/textarea.js +1 -1
  516. package/dist/components/ui/textarea.js.map +1 -1
  517. package/dist/components/ui/toast.js +3 -3
  518. package/dist/components/ui/toast.js.map +1 -1
  519. package/dist/components/ui/toggle-group.js +1 -1
  520. package/dist/components/ui/toggle-group.js.map +1 -1
  521. package/dist/components/ui/toggle.d.ts +1 -1
  522. package/dist/components/ui/toggle.d.ts.map +1 -1
  523. package/dist/components/ui/toggle.js +2 -2
  524. package/dist/components/ui/toggle.js.map +1 -1
  525. package/dist/components/ui/tooltip.d.ts.map +1 -1
  526. package/dist/components/ui/tooltip.js +1 -1
  527. package/dist/components/ui/tooltip.js.map +1 -1
  528. package/dist/{copy-menu-TIKvPaAZ.js → copy-menu-C5GaT4Z-.js} +2 -2
  529. package/dist/{copy-menu-TIKvPaAZ.js.map → copy-menu-C5GaT4Z-.js.map} +1 -1
  530. package/package.json +5 -3
@@ -13,8 +13,8 @@ import { VariantProps } from "class-variance-authority";
13
13
  * :not() or !important needed
14
14
  */
15
15
  declare const frameVariants: (props?: ({
16
- variant?: "default" | "ghost" | "inverse" | null | undefined;
17
- spacing?: "xs" | "sm" | "default" | "lg" | null | undefined;
16
+ variant?: "ghost" | "default" | "inverse" | null | undefined;
17
+ spacing?: "default" | "sm" | "lg" | "xs" | null | undefined;
18
18
  stacked?: boolean | null | undefined;
19
19
  dense?: boolean | null | undefined;
20
20
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
@@ -1 +1 @@
1
- {"version":3,"file":"frame.d.ts","names":[],"sources":["../../../src/components/reui/frame.tsx"],"mappings":";;;;;;;;;;;;;;cAkBM,gBAAa;;;;;6CAwElB;iBAEQ,QACP,WACA,SACA,SACA,SACA,UACG,SACF,MAAM,wBAAwB,oBAAoB,iCAAc,IAAA;iBAW1D,aAAa,WAAW,QAAQ,SAAS,MAAM;EAA0B;oBAAe,IAAA;iBAqBxF,cAAc,cAAc,SAAS,MAAM,2CAAwB,IAAA;iBAanE,aAAa,cAAc,SAAS,MAAM,wCAAqB,IAAA;iBAU/D,mBAAmB,cAAc,SAAS,MAAM,wCAAqB,IAAA;iBAUrE,cAAc,cAAc,SAAS,MAAM,2CAAwB,IAAA"}
1
+ {"version":3,"file":"frame.d.ts","names":[],"sources":["../../../src/components/reui/frame.tsx"],"mappings":";;;;;;;;;;;;;;cAiBM,gBAAa;;;;;6CAwElB;iBAEQ,QACP,WACA,SACA,SACA,SACA,UACG,SACF,MAAM,wBAAwB,oBAAoB,iCAAc,IAAA;iBAW1D,aAAa,WAAW,QAAQ,SAAS,MAAM;EAA0B;oBAAe,IAAA;iBAqBxF,cAAc,cAAc,SAAS,MAAM,2CAAwB,IAAA;iBAanE,aAAa,cAAc,SAAS,MAAM,wCAAqB,IAAA;iBAU/D,mBAAmB,cAAc,SAAS,MAAM,wCAAqB,IAAA;iBAUrE,cAAc,cAAc,SAAS,MAAM,2CAAwB,IAAA"}
@@ -1,7 +1,7 @@
1
1
  "use client";
2
- import { cn } from "@kumix/utils";
3
- import { cva } from "class-variance-authority";
2
+ import { cn } from "cn";
4
3
  import { jsx } from "react/jsx-runtime";
4
+ import { cva } from "class-variance-authority";
5
5
  //#region src/components/reui/frame.tsx
6
6
  /**
7
7
  * CSS variable architecture for FramePanel theming:
@@ -1 +1 @@
1
- {"version":3,"file":"frame.js","names":[],"sources":["../../../src/components/reui/frame.tsx"],"sourcesContent":["\"use client\";\n\nimport { cva, type VariantProps } from \"class-variance-authority\";\n\nimport { cn } from \"@kumix/utils\";\n\n/**\n * CSS variable architecture for FramePanel theming:\n *\n * The Frame parent sets --frame-panel-bg and --frame-panel-border-color.\n * FramePanel consumes them directly via bg-(--frame-panel-bg) and\n * border-(--frame-panel-border-color). This means:\n *\n * - variant=\"inverse\" overrides those vars on Frame → all panels pick it up\n * - <FramePanel className=\"bg-blue-50\"> adds a direct utility on the element\n * which wins over bg-(--frame-panel-bg) by Tailwind source order — no\n * :not() or !important needed\n */\nconst frameVariants = cva(\n [\n \"relative flex flex-col gap-(--frame-gap) rounded-(--frame-radius) bg-muted/50 px-(--frame-px) py-(--frame-py)\",\n \"(--radius-xl)] [--frame-radius:var(--radius-xl)]\",\n \"(--radius-none)] (--radius-2xl)] (--radius-lg)] (--radius-none)]\",\n \"[--frame-gap:--spacing(0.75)] [--frame-panel-footer-gap:--spacing(1)] [--frame-panel-header-gap:0rem] [--frame-px:--spacing(0.75)] [--frame-py:--spacing(0.75)]\",\n \"[--frame-panel-footer-px-adjust:0px] [--frame-panel-footer-py-adjust:0px] [--frame-panel-header-px-adjust:0px] [--frame-panel-header-py-adjust:0px] [--frame-panel-px-adjust:0px] [--frame-panel-py-adjust:0px]\",\n \"[--frame-panel-footer-px:calc(var(--frame-panel-footer-px-base)_+_var(--frame-panel-footer-px-adjust))] [--frame-panel-footer-py:calc(var(--frame-panel-footer-py-base)_+_var(--frame-panel-footer-py-adjust))] [--frame-panel-header-px:calc(var(--frame-panel-header-px-base)_+_var(--frame-panel-header-px-adjust))] [--frame-panel-header-py:calc(var(--frame-panel-header-py-base)_+_var(--frame-panel-header-py-adjust))] [--frame-panel-px:calc(var(--frame-panel-px-base)_+_var(--frame-panel-px-adjust))] [--frame-panel-py:calc(var(--frame-panel-py-base)_+_var(--frame-panel-py-adjust))]\",\n \"(1)] (1)] (1.25)] (1.5)] (1.5)] (0.5)] (1)] (1)]\",\n // Default panel token values — overridden per-variant below\n \"[--frame-border-color:var(--color-border)] [--frame-panel-bg:var(--color-card)] [--frame-panel-border-color:var(--color-border)]\",\n // Concentric inner radius: the panel corner nests smoothly inside the frame\n // corner instead of matching it. The panel sits inset from the frame's outer\n // edge by the frame's 1px border + --frame-px padding, so its radius is\n // reduced by that same gap (radius − gap keeps the two arcs parallel). This\n // base value assumes the bordered default/inverse frame; `ghost` drops the\n // 1px border term and `dense` pins it back to the frame radius (its panels\n // are pulled flush to the edge).\n \"[--frame-panel-radius:calc(var(--frame-radius)_-_var(--frame-px)_-_1px)]\",\n ],\n {\n variants: {\n variant: {\n default: \"border border-[var(--frame-border-color)] bg-clip-padding\",\n inverse:\n \"border border-[var(--frame-border-color)] bg-background bg-clip-padding [--frame-panel-bg:color-mix(in_oklch,var(--color-muted)_40%,transparent)]\",\n // No frame border, so the panel is inset by --frame-px padding only.\n ghost: \"[--frame-panel-radius:calc(var(--frame-radius)_-_var(--frame-px))]\",\n },\n // Header/footer vertical rhythm is tighter than the panel body's, and\n // the gap widens as the frame grows: the bars read as chrome rather than\n // as another content block. py ladder is 0.5 / 1.5 / 2 / 2.5 against a\n // body py of 2 / 3.5 / 4 / 5. These vars are style-agnostic - no\n // style-*.css overrides them - so this single ladder drives all shadcn\n // styles. `px` is deliberately left level with the body so header,\n // content and footer stay left-aligned. `xs` holds at 0.5 (2px): it is\n // the practical floor, since anything lower stops reading as padding.\n spacing: {\n xs: \"[--frame-panel-footer-px-base:--spacing(2)] [--frame-panel-footer-py-base:--spacing(0.5)] [--frame-panel-header-px-base:--spacing(2)] [--frame-panel-header-py-base:--spacing(0.5)] [--frame-panel-px-base:--spacing(2)] [--frame-panel-py-base:--spacing(2)]\",\n sm: \"[--frame-panel-footer-px-base:--spacing(3)] [--frame-panel-footer-py-base:--spacing(1.5)] [--frame-panel-header-px-base:--spacing(3)] [--frame-panel-header-py-base:--spacing(1.5)] [--frame-panel-px-base:--spacing(3)] [--frame-panel-py-base:--spacing(3.5)]\",\n default:\n \"[--frame-panel-footer-px-base:--spacing(4)] [--frame-panel-footer-py-base:--spacing(2)] [--frame-panel-header-px-base:--spacing(4)] [--frame-panel-header-py-base:--spacing(2)] [--frame-panel-px-base:--spacing(4)] [--frame-panel-py-base:--spacing(4)]\",\n lg: \"[--frame-panel-footer-px-base:--spacing(5)] [--frame-panel-footer-py-base:--spacing(2.5)] [--frame-panel-header-px-base:--spacing(5)] [--frame-panel-header-py-base:--spacing(2.5)] [--frame-panel-px-base:--spacing(5)] [--frame-panel-py-base:--spacing(5)]\",\n },\n stacked: {\n true: [\n \"gap-0 *:has-[+[data-slot=frame-panel]]:rounded-b-none\",\n \"*:has-[+[data-slot=frame-panel]]:before:hidden\",\n \"*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:rounded-t-none\",\n \"*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:border-t-0\",\n ],\n false: [\n \"data-[spacing=sm]:*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:mt-0.5\",\n \"data-[spacing=default]:*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:mt-1\",\n \"data-[spacing=lg]:*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:mt-2\",\n ],\n },\n dense: {\n // Positional rules must stay as parent selectors — cannot be expressed via CSS vars.\n // Padding is 0 and panels are pulled flush to the frame edge (-mx-px), so\n // their corners align with the frame radius rather than nesting inside it.\n true: \"gap-0 border-[var(--frame-border-color)] p-0 [--frame-panel-radius:var(--frame-radius)] [&:not(:has([data-slot=frame-panel-header]))_[data-slot=frame-panel]:is(:first-child)]:-mt-px [&_[data-slot=frame-panel]:last-child]:-mb-px [&_[data-slot=frame-panel]]:-mx-px [&_[data-slot=frame-panel]]:before:hidden\",\n false: \"\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n spacing: \"default\",\n stacked: false,\n dense: false,\n },\n },\n);\n\nfunction Frame({\n className,\n variant,\n spacing,\n stacked,\n dense,\n ...props\n}: React.ComponentProps<\"div\"> & VariantProps<typeof frameVariants>) {\n return (\n <div\n className={cn(frameVariants({ variant, spacing, stacked, dense }), className)}\n data-slot=\"frame\"\n data-spacing={spacing}\n {...props}\n />\n );\n}\n\nfunction FramePanel({ className, fit, ...props }: React.ComponentProps<\"div\"> & { fit?: boolean }) {\n return (\n <div\n className={cn(\n // bg-(--frame-panel-bg) and border-(--frame-panel-border-color) consume the\n // CSS vars set by the Frame parent. Any explicit bg-* or border-* class passed\n // via className overrides these by Tailwind source order - no ! needed.\n \"relative overflow-hidden rounded-(--frame-panel-radius) border border-(--frame-panel-border-color) bg-(--frame-panel-bg) bg-clip-padding shadow-xs\",\n // `fit` sizes the panel to its content; otherwise it grows to fill the frame.\n !fit && \"grow\",\n \"before:pointer-events-none before:absolute before:inset-0 before:rounded-[calc(var(--frame-panel-radius)-1px)] before:shadow-black/5\",\n \"dark:bg-clip-border dark:before:shadow-white/5\",\n \"px-(--frame-panel-px) py-(--frame-panel-py)\",\n className,\n )}\n data-slot=\"frame-panel\"\n {...props}\n />\n );\n}\n\nfunction FrameHeader({ className, ...props }: React.ComponentProps<\"header\">) {\n return (\n <header\n className={cn(\n \"flex flex-col gap-(--frame-panel-header-gap) px-(--frame-panel-header-px) py-(--frame-panel-header-py)\",\n className,\n )}\n data-slot=\"frame-panel-header\"\n {...props}\n />\n );\n}\n\nfunction FrameTitle({ className, ...props }: React.ComponentProps<\"div\">) {\n return (\n <div\n className={cn(\"font-semibold text-sm\", className)}\n data-slot=\"frame-panel-title\"\n {...props}\n />\n );\n}\n\nfunction FrameDescription({ className, ...props }: React.ComponentProps<\"div\">) {\n return (\n <div\n className={cn(\"text-muted-foreground text-sm\", className)}\n data-slot=\"frame-panel-description\"\n {...props}\n />\n );\n}\n\nfunction FrameFooter({ className, ...props }: React.ComponentProps<\"footer\">) {\n return (\n <footer\n className={cn(\n \"flex flex-col gap-(--frame-panel-footer-gap) px-(--frame-panel-footer-px) py-(--frame-panel-footer-py)\",\n className,\n )}\n data-slot=\"frame-panel-footer\"\n {...props}\n />\n );\n}\n\nexport { Frame, FrameDescription, FrameFooter, FrameHeader, FramePanel, FrameTitle, frameVariants };\n"],"mappings":";;;;;;;;;;;;;;;;;AAkBA,MAAM,gBAAgB,IACpB;CACE;CACA;CACA;CACA;CACA;CACA;CACA;CAEA;CAQA;AACF,GACA;CACE,UAAU;EACR,SAAS;GACP,SAAS;GACT,SACE;GAEF,OAAO;EACT;EASA,SAAS;GACP,IAAI;GACJ,IAAI;GACJ,SACE;GACF,IAAI;EACN;EACA,SAAS;GACP,MAAM;IACJ;IACA;IACA;IACA;GACF;GACA,OAAO;IACL;IACA;IACA;GACF;EACF;EACA,OAAO;GAIL,MAAM;GACN,OAAO;EACT;CACF;CACA,iBAAiB;EACf,SAAS;EACT,SAAS;EACT,SAAS;EACT,OAAO;CACT;AACF,CACF;AAEA,SAAS,MAAM,EACb,WACA,SACA,SACA,SACA,OACA,GAAG,SACgE;CACnE,OACE,oBAAC,OAAD;EACE,WAAW,GAAG,cAAc;GAAE;GAAS;GAAS;GAAS;EAAM,CAAC,GAAG,SAAS;EAC5E,aAAU;EACV,gBAAc;EACd,GAAI;CACL,CAAA;AAEL;AAEA,SAAS,WAAW,EAAE,WAAW,KAAK,GAAG,SAA0D;CACjG,OACE,oBAAC,OAAD;EACE,WAAW,GAIT,sJAEA,CAAC,OAAO,QACR,wIACA,kDACA,+CACA,SACF;EACA,aAAU;EACV,GAAI;CACL,CAAA;AAEL;AAEA,SAAS,YAAY,EAAE,WAAW,GAAG,SAAyC;CAC5E,OACE,oBAAC,UAAD;EACE,WAAW,GACT,0GACA,SACF;EACA,aAAU;EACV,GAAI;CACL,CAAA;AAEL;AAEA,SAAS,WAAW,EAAE,WAAW,GAAG,SAAsC;CACxE,OACE,oBAAC,OAAD;EACE,WAAW,GAAG,yBAAyB,SAAS;EAChD,aAAU;EACV,GAAI;CACL,CAAA;AAEL;AAEA,SAAS,iBAAiB,EAAE,WAAW,GAAG,SAAsC;CAC9E,OACE,oBAAC,OAAD;EACE,WAAW,GAAG,iCAAiC,SAAS;EACxD,aAAU;EACV,GAAI;CACL,CAAA;AAEL;AAEA,SAAS,YAAY,EAAE,WAAW,GAAG,SAAyC;CAC5E,OACE,oBAAC,UAAD;EACE,WAAW,GACT,0GACA,SACF;EACA,aAAU;EACV,GAAI;CACL,CAAA;AAEL"}
1
+ {"version":3,"file":"frame.js","names":[],"sources":["../../../src/components/reui/frame.tsx"],"sourcesContent":["\"use client\";\n\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { cn } from \"cn\";\n\n/**\n * CSS variable architecture for FramePanel theming:\n *\n * The Frame parent sets --frame-panel-bg and --frame-panel-border-color.\n * FramePanel consumes them directly via bg-(--frame-panel-bg) and\n * border-(--frame-panel-border-color). This means:\n *\n * - variant=\"inverse\" overrides those vars on Frame → all panels pick it up\n * - <FramePanel className=\"bg-blue-50\"> adds a direct utility on the element\n * which wins over bg-(--frame-panel-bg) by Tailwind source order — no\n * :not() or !important needed\n */\nconst frameVariants = cva(\n [\n \"relative flex flex-col gap-(--frame-gap) rounded-(--frame-radius) bg-muted/50 px-(--frame-px) py-(--frame-py)\",\n \"(--radius-xl)] [--frame-radius:var(--radius-xl)]\",\n \"(--radius-none)] (--radius-2xl)] (--radius-lg)] (--radius-none)]\",\n \"[--frame-gap:--spacing(0.75)] [--frame-panel-footer-gap:--spacing(1)] [--frame-panel-header-gap:0rem] [--frame-px:--spacing(0.75)] [--frame-py:--spacing(0.75)]\",\n \"[--frame-panel-footer-px-adjust:0px] [--frame-panel-footer-py-adjust:0px] [--frame-panel-header-px-adjust:0px] [--frame-panel-header-py-adjust:0px] [--frame-panel-px-adjust:0px] [--frame-panel-py-adjust:0px]\",\n \"[--frame-panel-footer-px:calc(var(--frame-panel-footer-px-base)_+_var(--frame-panel-footer-px-adjust))] [--frame-panel-footer-py:calc(var(--frame-panel-footer-py-base)_+_var(--frame-panel-footer-py-adjust))] [--frame-panel-header-px:calc(var(--frame-panel-header-px-base)_+_var(--frame-panel-header-px-adjust))] [--frame-panel-header-py:calc(var(--frame-panel-header-py-base)_+_var(--frame-panel-header-py-adjust))] [--frame-panel-px:calc(var(--frame-panel-px-base)_+_var(--frame-panel-px-adjust))] [--frame-panel-py:calc(var(--frame-panel-py-base)_+_var(--frame-panel-py-adjust))]\",\n \"(1)] (1)] (1.25)] (1.5)] (1.5)] (0.5)] (1)] (1)]\",\n // Default panel token values — overridden per-variant below\n \"[--frame-border-color:var(--color-border)] [--frame-panel-bg:var(--color-card)] [--frame-panel-border-color:var(--color-border)]\",\n // Concentric inner radius: the panel corner nests smoothly inside the frame\n // corner instead of matching it. The panel sits inset from the frame's outer\n // edge by the frame's 1px border + --frame-px padding, so its radius is\n // reduced by that same gap (radius − gap keeps the two arcs parallel). This\n // base value assumes the bordered default/inverse frame; `ghost` drops the\n // 1px border term and `dense` pins it back to the frame radius (its panels\n // are pulled flush to the edge).\n \"[--frame-panel-radius:calc(var(--frame-radius)_-_var(--frame-px)_-_1px)]\",\n ],\n {\n variants: {\n variant: {\n default: \"border border-[var(--frame-border-color)] bg-clip-padding\",\n inverse:\n \"border border-[var(--frame-border-color)] bg-background bg-clip-padding [--frame-panel-bg:color-mix(in_oklch,var(--color-muted)_40%,transparent)]\",\n // No frame border, so the panel is inset by --frame-px padding only.\n ghost: \"[--frame-panel-radius:calc(var(--frame-radius)_-_var(--frame-px))]\",\n },\n // Header/footer vertical rhythm is tighter than the panel body's, and\n // the gap widens as the frame grows: the bars read as chrome rather than\n // as another content block. py ladder is 0.5 / 1.5 / 2 / 2.5 against a\n // body py of 2 / 3.5 / 4 / 5. These vars are style-agnostic - no\n // style-*.css overrides them - so this single ladder drives all shadcn\n // styles. `px` is deliberately left level with the body so header,\n // content and footer stay left-aligned. `xs` holds at 0.5 (2px): it is\n // the practical floor, since anything lower stops reading as padding.\n spacing: {\n xs: \"[--frame-panel-footer-px-base:--spacing(2)] [--frame-panel-footer-py-base:--spacing(0.5)] [--frame-panel-header-px-base:--spacing(2)] [--frame-panel-header-py-base:--spacing(0.5)] [--frame-panel-px-base:--spacing(2)] [--frame-panel-py-base:--spacing(2)]\",\n sm: \"[--frame-panel-footer-px-base:--spacing(3)] [--frame-panel-footer-py-base:--spacing(1.5)] [--frame-panel-header-px-base:--spacing(3)] [--frame-panel-header-py-base:--spacing(1.5)] [--frame-panel-px-base:--spacing(3)] [--frame-panel-py-base:--spacing(3.5)]\",\n default:\n \"[--frame-panel-footer-px-base:--spacing(4)] [--frame-panel-footer-py-base:--spacing(2)] [--frame-panel-header-px-base:--spacing(4)] [--frame-panel-header-py-base:--spacing(2)] [--frame-panel-px-base:--spacing(4)] [--frame-panel-py-base:--spacing(4)]\",\n lg: \"[--frame-panel-footer-px-base:--spacing(5)] [--frame-panel-footer-py-base:--spacing(2.5)] [--frame-panel-header-px-base:--spacing(5)] [--frame-panel-header-py-base:--spacing(2.5)] [--frame-panel-px-base:--spacing(5)] [--frame-panel-py-base:--spacing(5)]\",\n },\n stacked: {\n true: [\n \"gap-0 *:has-[+[data-slot=frame-panel]]:rounded-b-none\",\n \"*:has-[+[data-slot=frame-panel]]:before:hidden\",\n \"*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:rounded-t-none\",\n \"*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:border-t-0\",\n ],\n false: [\n \"data-[spacing=sm]:*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:mt-0.5\",\n \"data-[spacing=default]:*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:mt-1\",\n \"data-[spacing=lg]:*:[[data-slot=frame-panel]+[data-slot=frame-panel]]:mt-2\",\n ],\n },\n dense: {\n // Positional rules must stay as parent selectors — cannot be expressed via CSS vars.\n // Padding is 0 and panels are pulled flush to the frame edge (-mx-px), so\n // their corners align with the frame radius rather than nesting inside it.\n true: \"gap-0 border-[var(--frame-border-color)] p-0 [--frame-panel-radius:var(--frame-radius)] [&:not(:has([data-slot=frame-panel-header]))_[data-slot=frame-panel]:is(:first-child)]:-mt-px [&_[data-slot=frame-panel]:last-child]:-mb-px [&_[data-slot=frame-panel]]:-mx-px [&_[data-slot=frame-panel]]:before:hidden\",\n false: \"\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n spacing: \"default\",\n stacked: false,\n dense: false,\n },\n },\n);\n\nfunction Frame({\n className,\n variant,\n spacing,\n stacked,\n dense,\n ...props\n}: React.ComponentProps<\"div\"> & VariantProps<typeof frameVariants>) {\n return (\n <div\n className={cn(frameVariants({ variant, spacing, stacked, dense }), className)}\n data-slot=\"frame\"\n data-spacing={spacing}\n {...props}\n />\n );\n}\n\nfunction FramePanel({ className, fit, ...props }: React.ComponentProps<\"div\"> & { fit?: boolean }) {\n return (\n <div\n className={cn(\n // bg-(--frame-panel-bg) and border-(--frame-panel-border-color) consume the\n // CSS vars set by the Frame parent. Any explicit bg-* or border-* class passed\n // via className overrides these by Tailwind source order - no ! needed.\n \"relative overflow-hidden rounded-(--frame-panel-radius) border border-(--frame-panel-border-color) bg-(--frame-panel-bg) bg-clip-padding shadow-xs\",\n // `fit` sizes the panel to its content; otherwise it grows to fill the frame.\n !fit && \"grow\",\n \"before:pointer-events-none before:absolute before:inset-0 before:rounded-[calc(var(--frame-panel-radius)-1px)] before:shadow-black/5\",\n \"dark:bg-clip-border dark:before:shadow-white/5\",\n \"px-(--frame-panel-px) py-(--frame-panel-py)\",\n className,\n )}\n data-slot=\"frame-panel\"\n {...props}\n />\n );\n}\n\nfunction FrameHeader({ className, ...props }: React.ComponentProps<\"header\">) {\n return (\n <header\n className={cn(\n \"flex flex-col gap-(--frame-panel-header-gap) px-(--frame-panel-header-px) py-(--frame-panel-header-py)\",\n className,\n )}\n data-slot=\"frame-panel-header\"\n {...props}\n />\n );\n}\n\nfunction FrameTitle({ className, ...props }: React.ComponentProps<\"div\">) {\n return (\n <div\n className={cn(\"font-semibold text-sm\", className)}\n data-slot=\"frame-panel-title\"\n {...props}\n />\n );\n}\n\nfunction FrameDescription({ className, ...props }: React.ComponentProps<\"div\">) {\n return (\n <div\n className={cn(\"text-muted-foreground text-sm\", className)}\n data-slot=\"frame-panel-description\"\n {...props}\n />\n );\n}\n\nfunction FrameFooter({ className, ...props }: React.ComponentProps<\"footer\">) {\n return (\n <footer\n className={cn(\n \"flex flex-col gap-(--frame-panel-footer-gap) px-(--frame-panel-footer-px) py-(--frame-panel-footer-py)\",\n className,\n )}\n data-slot=\"frame-panel-footer\"\n {...props}\n />\n );\n}\n\nexport { Frame, FrameDescription, FrameFooter, FrameHeader, FramePanel, FrameTitle, frameVariants };\n"],"mappings":";;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AAE,WAAW,GAAG,SAAyC;CAC5E,OACE,oBAAC,UAAD;EACE,WAAW,GACT,0GACA,SACF;EACA,aAAU;EACV,GAAI;CACL,CAAA;AAEL"}
@@ -5,9 +5,9 @@ import { flattenResources, getBaselineVariance, resolveEventBaseline, toZoned }
5
5
  import { useGantt, useGanttSelector, useGanttViewConfig } from "./gantt.js";
6
6
  import { useGanttGestures, wasRecentDrag } from "./gantt-dnd.js";
7
7
  import { createContext, useContext, useMemo, useState } from "react";
8
- import { cn } from "@kumix/utils";
9
- import { CheckIcon, RepeatIcon } from "lucide-react";
8
+ import { cn } from "cn";
10
9
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
10
+ import { CheckIcon, RepeatIcon } from "lucide-react";
11
11
  import { mergeProps } from "@base-ui/react/merge-props";
12
12
  import { useRender } from "@base-ui/react/use-render";
13
13
  //#region src/components/reui/gantt/gantt-bar.tsx
@@ -1 +1 @@
1
- {"version":3,"file":"gantt-bar.js","names":[],"sources":["../../../../src/components/reui/gantt/gantt-bar.tsx"],"sourcesContent":["\"use client\";\n\nimport {\n type CSSProperties,\n createContext,\n type ReactNode,\n useContext,\n useMemo,\n useState,\n} from \"react\";\nimport { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { CheckIcon, RepeatIcon } from \"lucide-react\";\n\nimport { cn } from \"@kumix/utils\";\nimport { ContextMenu, ContextMenuContent, ContextMenuTrigger } from \"../../ui/context-menu\";\nimport { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from \"../../ui/tooltip\";\nimport { useGantt, useGanttSelector, useGanttViewConfig } from \"./gantt\";\nimport { useGanttGestures, wasRecentDrag } from \"./gantt-dnd\";\nimport { flattenResources, getBaselineVariance, resolveEventBaseline, toZoned } from \"./gantt-lib\";\nimport type { GanttOccurrence, GanttSegment } from \"./gantt-types\";\n\n/**\n * Effective Tailwind palette presets for bar colors; every entry works on\n * light and dark surfaces through the bar's alpha background + accent border.\n */\nconst GANTT_COLORS: Array<{ name: string; value: string }> = [\n { name: \"Blue\", value: \"var(--color-blue-500)\" },\n { name: \"Emerald\", value: \"var(--color-emerald-500)\" },\n { name: \"Violet\", value: \"var(--color-violet-500)\" },\n { name: \"Rose\", value: \"var(--color-rose-500)\" },\n { name: \"Amber\", value: \"var(--color-amber-500)\" },\n { name: \"Cyan\", value: \"var(--color-cyan-500)\" },\n { name: \"Orange\", value: \"var(--color-orange-500)\" },\n { name: \"Pink\", value: \"var(--color-pink-500)\" },\n { name: \"Teal\", value: \"var(--color-teal-500)\" },\n { name: \"Indigo\", value: \"var(--color-indigo-500)\" },\n];\n\ninterface GanttBarContextValue<TData = unknown> {\n occurrence: GanttOccurrence<TData>;\n segment: GanttSegment<TData>;\n isDragging: boolean;\n isSelected: boolean;\n}\n\nconst GanttBarContext =\n // biome-ignore lint/suspicious/noExplicitAny: <>\n createContext<GanttBarContextValue<any> | null>(null);\n\n/** The bar's subject; usable inside renderEvent content and bar children. */\nfunction useGanttBarContext<TData = unknown>(): GanttBarContextValue<TData> {\n const ctx = useContext(GanttBarContext);\n if (!ctx) {\n throw new Error(\"useGanttBarContext must be used within <GanttBar>\");\n }\n return ctx as GanttBarContextValue<TData>;\n}\n\ninterface GanttBarProps<TData = unknown>\n extends Omit<useRender.ComponentProps<\"button\">, \"children\"> {\n segment: GanttSegment<TData>;\n /** Replaces the default bar CONTENT; the wrapper stays gantt-owned. */\n children?: ReactNode;\n /**\n * The title renders beside the bar (view-owned), so the default inner\n * content is suppressed. Explicit children and renderEvent still win.\n */\n labelOutside?: boolean;\n /**\n * The owning row's title for the aria-label. Pass it when the row is in\n * scope (the internal view does); omitting falls back to a tree lookup.\n */\n rowTitle?: string;\n}\n\n/**\n * The one interactive bar element. The wrapper owns positioning hooks, a11y,\n * selection, drag/resize listeners, and data attributes; content comes from\n * children, the root renderEvent override, or the built-in default.\n */\nfunction GanttBar<TData = unknown>({\n segment,\n className,\n render,\n children,\n labelOutside,\n rowTitle: rowTitleProp,\n ...props\n}: GanttBarProps<TData>) {\n const instance = useGantt<TData>();\n const viewConfig = useGanttViewConfig<TData>();\n const gestures = useGanttGestures<TData>();\n const { settings } = instance;\n const occurrence = segment.occurrence;\n const event = occurrence.event;\n\n const isSelected = useGanttSelector<TData, boolean>(\n (state) => state.selection.eventKeys.includes(occurrence.key),\n { calendar: instance },\n );\n const isDragging = useGanttSelector<TData, boolean>(\n (state) => state.drag?.occurrence.key === occurrence.key,\n { calendar: instance },\n );\n // Which gesture owns this bar: a move hides the original (the smooth clone\n // stands in for it); a resize keeps it as a faint placeholder behind the\n // dashed preview so you can see the original extent.\n const dragKind = useGanttSelector<TData, string | null>(\n (state) => (state.drag?.occurrence.key === occurrence.key ? state.drag.kind : null),\n { calendar: instance },\n );\n // Hover-only range tooltip. Focus opens are ignored (the known button+\n // tooltip flash: clicking a bar opens a dialog, focus returns, and a\n // focus-triggered tooltip would pop). Hidden while dragging/resizing.\n const [tipOpen, setTipOpen] = useState(false);\n // Gated on tipOpen: with the tooltip closed the selector returns a stable\n // false, so gesture start/end doesn't re-render every mounted bar.\n const anyInteracting = useGanttSelector<TData, boolean>(\n (state) => tipOpen && (state.drag !== null || state.slotDraft !== null),\n { calendar: instance },\n );\n\n const progress =\n typeof event.progress === \"number\"\n ? Math.min(Math.max(Math.round(event.progress), 0), 100)\n : null;\n\n // A zero-duration occurrence is a MILESTONE: the button stays the\n // interactive shell (click, select, menu, move), the diamond replaces the\n // tinted bar body, and the view keeps the title outside.\n const milestone = occurrence.end.getTime() === occurrence.start.getTime();\n\n // The bar only LABELS its baseline (attributes, tooltip, aria); the ghost\n // itself is view-owned chrome, because its range differs from this bar's.\n const baseline = viewConfig.baselineBars ? resolveEventBaseline(event) : null;\n const baselineVariance = baseline ? getBaselineVariance(event) : null;\n\n const defaultContent = (\n <>\n {occurrence.isRecurring && (\n <RepeatIcon className=\"size-2.5 shrink-0 opacity-70\" aria-hidden=\"true\" />\n )}\n <span className=\"truncate font-medium\">{event.title}</span>\n {!occurrence.allDay && segment.isStart && (\n <span className=\"@[8rem]:inline hidden truncate text-muted-foreground\">\n {settings.i18n.functions.formatEventTime(\n toZoned(occurrence.start, settings.timeZone),\n toZoned(occurrence.end, settings.timeZone),\n occurrence.allDay,\n settings.locale,\n )}\n </span>\n )}\n </>\n );\n\n const renderProps = { occurrence, segment, isDragging, isSelected };\n const content =\n children ??\n viewConfig.renderEvent?.(renderProps) ??\n (labelOutside || milestone ? null : defaultContent);\n // Consumer-owned content owns the WHOLE inner visualization: the built-in\n // progress fill and done mark yield so custom bars start from a blank\n // canvas (progress stays readable via data-progress/data-completed).\n const consumerOwnsContent = children !== undefined || !!viewConfig.renderEvent;\n\n const timeLabel = settings.i18n.functions.formatEventTime(\n toZoned(occurrence.start, settings.timeZone),\n toZoned(occurrence.end, settings.timeZone),\n occurrence.allDay,\n settings.locale,\n );\n // Memoized: a second full formatEventTime per render would double the\n // bar's formatting cost, and it cannot wait for the tooltip because the\n // label also feeds aria-label. Keyed on the instants, not the baseline\n // object - resolveEventBaseline allocates a fresh one every render.\n const baselineStartMs = baseline?.start.getTime();\n const baselineEndMs = baseline?.end.getTime();\n const plannedLabel = useMemo(\n () =>\n baselineStartMs === undefined || baselineEndMs === undefined\n ? undefined\n : settings.i18n.labels.planned(\n settings.i18n.functions.formatEventTime(\n toZoned(new Date(baselineStartMs), settings.timeZone),\n toZoned(new Date(baselineEndMs), settings.timeZone),\n occurrence.allDay,\n settings.locale,\n ),\n ),\n [\n baselineStartMs,\n baselineEndMs,\n occurrence.allDay,\n settings.i18n,\n settings.timeZone,\n settings.locale,\n ],\n );\n // name the row too: the split-pane layout carries no grid semantics.\n // The prop path is O(1); the lookup fallback is memoized so external\n // GanttBar usage never flattens the tree per render.\n const fallbackRowTitle = useMemo(\n () =>\n rowTitleProp === undefined && event.resourceId\n ? flattenResources(settings.resources).find(\n ({ resource }) => resource.id === event.resourceId,\n )?.resource.title\n : undefined,\n [rowTitleProp, event.resourceId, settings.resources],\n );\n const rowTitle = rowTitleProp ?? fallbackRowTitle;\n\n const showResize = gestures.canResize(segment);\n const resizeHandles = showResize && (\n <>\n {segment.isStart && (\n <span\n data-slot=\"gantt-resize-handle\"\n data-edge=\"start\"\n // grip hugs the start edge (justify-start + tight inset) so the\n // indicator reads as \"resize this end\", not a centered pill.\n // pointer-coarse keeps it visible on touch, where hover never fires\n className=\"absolute inset-y-0 start-0.5 flex w-2 cursor-ew-resize items-center justify-start opacity-0 pointer-coarse:opacity-100 group-hover/gantt-bar-group:opacity-100\"\n onPointerDown={(e) => gestures.beginResize(e, segment, \"start\")}\n >\n <span aria-hidden className=\"h-2.5 w-0.5 rounded-full bg-foreground/40\" />\n </span>\n )}\n {segment.isEnd && (\n <span\n data-slot=\"gantt-resize-handle\"\n data-edge=\"end\"\n // grip hugs the end edge (justify-end + tight inset) so the\n // indicator reads as \"resize this end\", not a centered pill.\n // pointer-coarse keeps it visible on touch, where hover never fires\n className=\"absolute inset-y-0 end-0.5 flex w-2 cursor-ew-resize items-center justify-end opacity-0 pointer-coarse:opacity-100 group-hover/gantt-bar-group:opacity-100\"\n onPointerDown={(e) => gestures.beginResize(e, segment, \"end\")}\n >\n <span aria-hidden className=\"h-2.5 w-0.5 rounded-full bg-foreground/40\" />\n </span>\n )}\n </>\n );\n\n const defaultProps = {\n type: \"button\" as const,\n \"data-slot\": \"gantt-bar\",\n \"data-milestone\": milestone || undefined,\n \"data-all-day\": occurrence.allDay || undefined,\n \"data-recurring\": occurrence.isRecurring || undefined,\n \"data-selected\": isSelected || undefined,\n \"data-dragging\": isDragging || undefined,\n \"data-drag-kind\": dragKind ?? undefined,\n \"data-past\": occurrence.end.getTime() < Date.now() || undefined,\n \"data-label-outside\": labelOutside || undefined,\n \"data-progress\": progress ?? undefined,\n \"data-completed\": progress === 100 || undefined,\n \"data-baseline\": !!baseline || undefined,\n \"data-baseline-variance\": baselineVariance ?? undefined,\n \"aria-label\": settings.i18n.functions.formatEventAriaLabel({\n title: event.title,\n timeLabel,\n milestoneLabel: milestone ? settings.i18n.labels.milestone : undefined,\n rowTitle,\n progressLabel: progress !== null ? settings.i18n.labels.progress(progress) : undefined,\n plannedLabel,\n continues: segment.continuesBefore || segment.continuesAfter,\n }),\n style: {\n \"--gantt-event-color\": event.color ?? \"var(--color-primary)\",\n } as CSSProperties,\n onPointerDown: (e: React.PointerEvent) => {\n e.stopPropagation();\n gestures.beginMove(e, segment);\n },\n onClick: (e: React.MouseEvent) => {\n e.stopPropagation();\n if (wasRecentDrag()) return;\n instance.api.selectEvent(occurrence.key);\n settings.onEventClick?.(occurrence, e);\n },\n onDoubleClick: (e: React.MouseEvent) => {\n e.stopPropagation();\n settings.onEventDoubleClick?.(occurrence, e);\n },\n className: cn(\n \"group/gantt-bar-group @container relative flex w-full min-w-0 cursor-pointer touch-none select-none items-center gap-1.5 overflow-hidden rounded-sm px-1.5 py-0.5 text-start text-foreground leading-normal\",\n \"outline-none focus-visible:ring-2 focus-visible:ring-ring/50\",\n // the unfilled remainder has to be legible on its own - at /12 a bar\n // with a progress fill read as a floating segment with no basement\n \"bg-(--gantt-event-color)/20 hover:bg-(--gantt-event-color)/30\",\n // move: hide the original (the smooth cursor clone represents it)\n \"data-[drag-kind=move]:opacity-0\",\n // resize: keep the original event exactly, just fade it to a soft\n // placeholder behind the dashed preview - no dramatic restyle\n \"data-[drag-kind=resize-end]:opacity-40 data-[drag-kind=resize-start]:opacity-40\",\n \"data-selected:bg-(--gantt-event-color)/30\",\n /* the diamond is the milestone's body, so the shell sheds its own\n tinted fill and centers the glyph on the instant */\n milestone &&\n \"justify-center bg-transparent px-0 hover:bg-transparent data-selected:bg-transparent\",\n segment.continuesBefore && \"rounded-s-none\",\n segment.continuesAfter && \"rounded-e-none\",\n viewConfig.classNames?.event,\n className,\n ),\n children: (\n <>\n {milestone && !consumerOwnsContent && (\n // the filled diamond IS the milestone's body - chrome, so a custom\n // renderEvent still starts from a blank canvas (data-milestone\n // keeps the fact readable there)\n <span\n aria-hidden\n data-slot=\"gantt-bar-milestone\"\n className={cn(\n \"size-2.5 shrink-0 rotate-45 rounded-[2px] border border-(--gantt-event-color) bg-(--gantt-event-color)/80\",\n isSelected && \"ring-2 ring-ring/50\",\n )}\n />\n )}\n {progress !== null && !milestone && (\n // Chrome, not content: it is an absolutely-positioned layer BEHIND\n // whatever the bar renders, so a consumer bar (renderEvent) keeps\n // its completion fill instead of silently losing it. The inline\n // done-mark below stays gated, because that one really is content.\n <span\n aria-hidden\n data-slot=\"gantt-bar-progress\"\n className=\"pointer-events-none absolute inset-y-0 start-0 border-(--gantt-event-color)/65 border-e bg-(--gantt-event-color)/40 data-full:border-e-0\"\n data-full={progress === 100 || undefined}\n style={{ width: `${progress}%` }}\n />\n )}\n {progress === 100 && !consumerOwnsContent && !milestone && (\n // done mark: completion chrome like the fill itself, so it shows\n // for outside-label bars too (where the inner content is empty)\n <CheckIcon className=\"relative size-2.5 shrink-0 opacity-80\" aria-hidden=\"true\" />\n )}\n {content}\n {resizeHandles}\n </>\n ),\n };\n\n const barButton = useRender({\n defaultTagName: \"button\",\n render,\n props: mergeProps<\"button\">(defaultProps, props),\n });\n\n // Consumer-owned right-click menu (headless): the primitive only wires the\n // ContextMenu; the items and their handlers come entirely from the block.\n const menu = viewConfig.renderEventMenu?.(renderProps);\n\n // The bar is simultaneously the tooltip trigger and (when a menu exists)\n // the context-menu trigger; Base UI composes both via render props.\n const trigger = menu ? (\n <ContextMenuTrigger render={<TooltipTrigger render={barButton} />} />\n ) : (\n <TooltipTrigger render={barButton} />\n );\n\n const barTree = (\n <TooltipProvider delay={500} closeDelay={0} timeout={300}>\n <Tooltip\n open={tipOpen && !anyInteracting}\n onOpenChange={(next: boolean, details: { reason?: string }) => {\n // opens only on hover; focus/press opens are dropped\n if (next && details?.reason !== \"trigger-hover\") return;\n setTipOpen(next);\n }}\n >\n {trigger}\n {tipOpen && !anyInteracting && (\n <TooltipContent side=\"top\" className=\"pointer-events-none\">\n <div className=\"font-medium\">{event.title}</div>\n <div className=\"opacity-80\">{timeLabel}</div>\n {plannedLabel && <div className=\"opacity-80\">{plannedLabel}</div>}\n </TooltipContent>\n )}\n </Tooltip>\n </TooltipProvider>\n );\n\n return (\n <GanttBarContext.Provider value={{ occurrence, segment, isDragging, isSelected }}>\n {menu ? (\n <ContextMenu>\n {barTree}\n <ContextMenuContent data-slot=\"gantt-bar-menu\" className=\"min-w-44\">\n {menu}\n </ContextMenuContent>\n </ContextMenu>\n ) : (\n barTree\n )}\n </GanttBarContext.Provider>\n );\n}\n\nexport type { GanttBarContextValue, GanttBarProps };\nexport { GANTT_COLORS, GanttBar, useGanttBarContext };\n"],"mappings":";;;;;;;;;;;;;;;;;AA0BA,MAAM,eAAuD;CAC3D;EAAE,MAAM;EAAQ,OAAO;CAAwB;CAC/C;EAAE,MAAM;EAAW,OAAO;CAA2B;CACrD;EAAE,MAAM;EAAU,OAAO;CAA0B;CACnD;EAAE,MAAM;EAAQ,OAAO;CAAwB;CAC/C;EAAE,MAAM;EAAS,OAAO;CAAyB;CACjD;EAAE,MAAM;EAAQ,OAAO;CAAwB;CAC/C;EAAE,MAAM;EAAU,OAAO;CAA0B;CACnD;EAAE,MAAM;EAAQ,OAAO;CAAwB;CAC/C;EAAE,MAAM;EAAQ,OAAO;CAAwB;CAC/C;EAAE,MAAM;EAAU,OAAO;CAA0B;AACrD;AASA,MAAM,kBAEJ,cAAgD,IAAI;;AAGtD,SAAS,qBAAmE;CAC1E,MAAM,MAAM,WAAW,eAAe;CACtC,IAAI,CAAC,KACH,MAAM,IAAI,MAAM,mDAAmD;CAErE,OAAO;AACT;;;;;;AAwBA,SAAS,SAA0B,EACjC,SACA,WACA,QACA,UACA,cACA,UAAU,cACV,GAAG,SACoB;CACvB,MAAM,WAAW,SAAgB;CACjC,MAAM,aAAa,mBAA0B;CAC7C,MAAM,WAAW,iBAAwB;CACzC,MAAM,EAAE,aAAa;CACrB,MAAM,aAAa,QAAQ;CAC3B,MAAM,QAAQ,WAAW;C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nB,OACE,oBAAC,gBAAgB,UAAjB;EAA0B,OAAO;GAAE;GAAY;GAAS;GAAY;EAAW;EAC5E,UAAA,OACC,qBAAC,aAAD,EAAA,UAAA,CACG,SACD,oBAAC,oBAAD;GAAoB,aAAU;GAAiB,WAAU;GACtD,UAAA;EACiB,CAAA,CACT,EAAA,CAAA,IAEb;CAEsB,CAAA;AAE9B"}
1
+ {"version":3,"file":"gantt-bar.js","names":[],"sources":["../../../../src/components/reui/gantt/gantt-bar.tsx"],"sourcesContent":["\"use client\";\n\nimport {\n type CSSProperties,\n createContext,\n type ReactNode,\n useContext,\n useMemo,\n useState,\n} from \"react\";\nimport { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { cn } from \"cn\";\nimport { CheckIcon, RepeatIcon } from \"lucide-react\";\n\nimport { ContextMenu, ContextMenuContent, ContextMenuTrigger } from \"../../ui/context-menu\";\nimport { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from \"../../ui/tooltip\";\nimport { useGantt, useGanttSelector, useGanttViewConfig } from \"./gantt\";\nimport { useGanttGestures, wasRecentDrag } from \"./gantt-dnd\";\nimport { flattenResources, getBaselineVariance, resolveEventBaseline, toZoned } from \"./gantt-lib\";\nimport type { GanttOccurrence, GanttSegment } from \"./gantt-types\";\n\n/**\n * Effective Tailwind palette presets for bar colors; every entry works on\n * light and dark surfaces through the bar's alpha background + accent border.\n */\nconst GANTT_COLORS: Array<{ name: string; value: string }> = [\n { name: \"Blue\", value: \"var(--color-blue-500)\" },\n { name: \"Emerald\", value: \"var(--color-emerald-500)\" },\n { name: \"Violet\", value: \"var(--color-violet-500)\" },\n { name: \"Rose\", value: \"var(--color-rose-500)\" },\n { name: \"Amber\", value: \"var(--color-amber-500)\" },\n { name: \"Cyan\", value: \"var(--color-cyan-500)\" },\n { name: \"Orange\", value: \"var(--color-orange-500)\" },\n { name: \"Pink\", value: \"var(--color-pink-500)\" },\n { name: \"Teal\", value: \"var(--color-teal-500)\" },\n { name: \"Indigo\", value: \"var(--color-indigo-500)\" },\n];\n\ninterface GanttBarContextValue<TData = unknown> {\n occurrence: GanttOccurrence<TData>;\n segment: GanttSegment<TData>;\n isDragging: boolean;\n isSelected: boolean;\n}\n\nconst GanttBarContext =\n // biome-ignore lint/suspicious/noExplicitAny: <>\n createContext<GanttBarContextValue<any> | null>(null);\n\n/** The bar's subject; usable inside renderEvent content and bar children. */\nfunction useGanttBarContext<TData = unknown>(): GanttBarContextValue<TData> {\n const ctx = useContext(GanttBarContext);\n if (!ctx) {\n throw new Error(\"useGanttBarContext must be used within <GanttBar>\");\n }\n return ctx as GanttBarContextValue<TData>;\n}\n\ninterface GanttBarProps<TData = unknown>\n extends Omit<useRender.ComponentProps<\"button\">, \"children\"> {\n segment: GanttSegment<TData>;\n /** Replaces the default bar CONTENT; the wrapper stays gantt-owned. */\n children?: ReactNode;\n /**\n * The title renders beside the bar (view-owned), so the default inner\n * content is suppressed. Explicit children and renderEvent still win.\n */\n labelOutside?: boolean;\n /**\n * The owning row's title for the aria-label. Pass it when the row is in\n * scope (the internal view does); omitting falls back to a tree lookup.\n */\n rowTitle?: string;\n}\n\n/**\n * The one interactive bar element. The wrapper owns positioning hooks, a11y,\n * selection, drag/resize listeners, and data attributes; content comes from\n * children, the root renderEvent override, or the built-in default.\n */\nfunction GanttBar<TData = unknown>({\n segment,\n className,\n render,\n children,\n labelOutside,\n rowTitle: rowTitleProp,\n ...props\n}: GanttBarProps<TData>) {\n const instance = useGantt<TData>();\n const viewConfig = useGanttViewConfig<TData>();\n const gestures = useGanttGestures<TData>();\n const { settings } = instance;\n const occurrence = segment.occurrence;\n const event = occurrence.event;\n\n const isSelected = useGanttSelector<TData, boolean>(\n (state) => state.selection.eventKeys.includes(occurrence.key),\n { calendar: instance },\n );\n const isDragging = useGanttSelector<TData, boolean>(\n (state) => state.drag?.occurrence.key === occurrence.key,\n { calendar: instance },\n );\n // Which gesture owns this bar: a move hides the original (the smooth clone\n // stands in for it); a resize keeps it as a faint placeholder behind the\n // dashed preview so you can see the original extent.\n const dragKind = useGanttSelector<TData, string | null>(\n (state) => (state.drag?.occurrence.key === occurrence.key ? state.drag.kind : null),\n { calendar: instance },\n );\n // Hover-only range tooltip. Focus opens are ignored (the known button+\n // tooltip flash: clicking a bar opens a dialog, focus returns, and a\n // focus-triggered tooltip would pop). Hidden while dragging/resizing.\n const [tipOpen, setTipOpen] = useState(false);\n // Gated on tipOpen: with the tooltip closed the selector returns a stable\n // false, so gesture start/end doesn't re-render every mounted bar.\n const anyInteracting = useGanttSelector<TData, boolean>(\n (state) => tipOpen && (state.drag !== null || state.slotDraft !== null),\n { calendar: instance },\n );\n\n const progress =\n typeof event.progress === \"number\"\n ? Math.min(Math.max(Math.round(event.progress), 0), 100)\n : null;\n\n // A zero-duration occurrence is a MILESTONE: the button stays the\n // interactive shell (click, select, menu, move), the diamond replaces the\n // tinted bar body, and the view keeps the title outside.\n const milestone = occurrence.end.getTime() === occurrence.start.getTime();\n\n // The bar only LABELS its baseline (attributes, tooltip, aria); the ghost\n // itself is view-owned chrome, because its range differs from this bar's.\n const baseline = viewConfig.baselineBars ? resolveEventBaseline(event) : null;\n const baselineVariance = baseline ? getBaselineVariance(event) : null;\n\n const defaultContent = (\n <>\n {occurrence.isRecurring && (\n <RepeatIcon className=\"size-2.5 shrink-0 opacity-70\" aria-hidden=\"true\" />\n )}\n <span className=\"truncate font-medium\">{event.title}</span>\n {!occurrence.allDay && segment.isStart && (\n <span className=\"@[8rem]:inline hidden truncate text-muted-foreground\">\n {settings.i18n.functions.formatEventTime(\n toZoned(occurrence.start, settings.timeZone),\n toZoned(occurrence.end, settings.timeZone),\n occurrence.allDay,\n settings.locale,\n )}\n </span>\n )}\n </>\n );\n\n const renderProps = { occurrence, segment, isDragging, isSelected };\n const content =\n children ??\n viewConfig.renderEvent?.(renderProps) ??\n (labelOutside || milestone ? null : defaultContent);\n // Consumer-owned content owns the WHOLE inner visualization: the built-in\n // progress fill and done mark yield so custom bars start from a blank\n // canvas (progress stays readable via data-progress/data-completed).\n const consumerOwnsContent = children !== undefined || !!viewConfig.renderEvent;\n\n const timeLabel = settings.i18n.functions.formatEventTime(\n toZoned(occurrence.start, settings.timeZone),\n toZoned(occurrence.end, settings.timeZone),\n occurrence.allDay,\n settings.locale,\n );\n // Memoized: a second full formatEventTime per render would double the\n // bar's formatting cost, and it cannot wait for the tooltip because the\n // label also feeds aria-label. Keyed on the instants, not the baseline\n // object - resolveEventBaseline allocates a fresh one every render.\n const baselineStartMs = baseline?.start.getTime();\n const baselineEndMs = baseline?.end.getTime();\n const plannedLabel = useMemo(\n () =>\n baselineStartMs === undefined || baselineEndMs === undefined\n ? undefined\n : settings.i18n.labels.planned(\n settings.i18n.functions.formatEventTime(\n toZoned(new Date(baselineStartMs), settings.timeZone),\n toZoned(new Date(baselineEndMs), settings.timeZone),\n occurrence.allDay,\n settings.locale,\n ),\n ),\n [\n baselineStartMs,\n baselineEndMs,\n occurrence.allDay,\n settings.i18n,\n settings.timeZone,\n settings.locale,\n ],\n );\n // name the row too: the split-pane layout carries no grid semantics.\n // The prop path is O(1); the lookup fallback is memoized so external\n // GanttBar usage never flattens the tree per render.\n const fallbackRowTitle = useMemo(\n () =>\n rowTitleProp === undefined && event.resourceId\n ? flattenResources(settings.resources).find(\n ({ resource }) => resource.id === event.resourceId,\n )?.resource.title\n : undefined,\n [rowTitleProp, event.resourceId, settings.resources],\n );\n const rowTitle = rowTitleProp ?? fallbackRowTitle;\n\n const showResize = gestures.canResize(segment);\n const resizeHandles = showResize && (\n <>\n {segment.isStart && (\n <span\n data-slot=\"gantt-resize-handle\"\n data-edge=\"start\"\n // grip hugs the start edge (justify-start + tight inset) so the\n // indicator reads as \"resize this end\", not a centered pill.\n // pointer-coarse keeps it visible on touch, where hover never fires\n className=\"absolute inset-y-0 start-0.5 flex w-2 cursor-ew-resize items-center justify-start opacity-0 pointer-coarse:opacity-100 group-hover/gantt-bar-group:opacity-100\"\n onPointerDown={(e) => gestures.beginResize(e, segment, \"start\")}\n >\n <span aria-hidden className=\"h-2.5 w-0.5 rounded-full bg-foreground/40\" />\n </span>\n )}\n {segment.isEnd && (\n <span\n data-slot=\"gantt-resize-handle\"\n data-edge=\"end\"\n // grip hugs the end edge (justify-end + tight inset) so the\n // indicator reads as \"resize this end\", not a centered pill.\n // pointer-coarse keeps it visible on touch, where hover never fires\n className=\"absolute inset-y-0 end-0.5 flex w-2 cursor-ew-resize items-center justify-end opacity-0 pointer-coarse:opacity-100 group-hover/gantt-bar-group:opacity-100\"\n onPointerDown={(e) => gestures.beginResize(e, segment, \"end\")}\n >\n <span aria-hidden className=\"h-2.5 w-0.5 rounded-full bg-foreground/40\" />\n </span>\n )}\n </>\n );\n\n const defaultProps = {\n type: \"button\" as const,\n \"data-slot\": \"gantt-bar\",\n \"data-milestone\": milestone || undefined,\n \"data-all-day\": occurrence.allDay || undefined,\n \"data-recurring\": occurrence.isRecurring || undefined,\n \"data-selected\": isSelected || undefined,\n \"data-dragging\": isDragging || undefined,\n \"data-drag-kind\": dragKind ?? undefined,\n \"data-past\": occurrence.end.getTime() < Date.now() || undefined,\n \"data-label-outside\": labelOutside || undefined,\n \"data-progress\": progress ?? undefined,\n \"data-completed\": progress === 100 || undefined,\n \"data-baseline\": !!baseline || undefined,\n \"data-baseline-variance\": baselineVariance ?? undefined,\n \"aria-label\": settings.i18n.functions.formatEventAriaLabel({\n title: event.title,\n timeLabel,\n milestoneLabel: milestone ? settings.i18n.labels.milestone : undefined,\n rowTitle,\n progressLabel: progress !== null ? settings.i18n.labels.progress(progress) : undefined,\n plannedLabel,\n continues: segment.continuesBefore || segment.continuesAfter,\n }),\n style: {\n \"--gantt-event-color\": event.color ?? \"var(--color-primary)\",\n } as CSSProperties,\n onPointerDown: (e: React.PointerEvent) => {\n e.stopPropagation();\n gestures.beginMove(e, segment);\n },\n onClick: (e: React.MouseEvent) => {\n e.stopPropagation();\n if (wasRecentDrag()) return;\n instance.api.selectEvent(occurrence.key);\n settings.onEventClick?.(occurrence, e);\n },\n onDoubleClick: (e: React.MouseEvent) => {\n e.stopPropagation();\n settings.onEventDoubleClick?.(occurrence, e);\n },\n className: cn(\n \"group/gantt-bar-group @container relative flex w-full min-w-0 cursor-pointer touch-none select-none items-center gap-1.5 overflow-hidden rounded-sm px-1.5 py-0.5 text-start text-foreground leading-normal\",\n \"outline-none focus-visible:ring-2 focus-visible:ring-ring/50\",\n // the unfilled remainder has to be legible on its own - at /12 a bar\n // with a progress fill read as a floating segment with no basement\n \"bg-(--gantt-event-color)/20 hover:bg-(--gantt-event-color)/30\",\n // move: hide the original (the smooth cursor clone represents it)\n \"data-[drag-kind=move]:opacity-0\",\n // resize: keep the original event exactly, just fade it to a soft\n // placeholder behind the dashed preview - no dramatic restyle\n \"data-[drag-kind=resize-end]:opacity-40 data-[drag-kind=resize-start]:opacity-40\",\n \"data-selected:bg-(--gantt-event-color)/30\",\n /* the diamond is the milestone's body, so the shell sheds its own\n tinted fill and centers the glyph on the instant */\n milestone &&\n \"justify-center bg-transparent px-0 hover:bg-transparent data-selected:bg-transparent\",\n segment.continuesBefore && \"rounded-s-none\",\n segment.continuesAfter && \"rounded-e-none\",\n viewConfig.classNames?.event,\n className,\n ),\n children: (\n <>\n {milestone && !consumerOwnsContent && (\n // the filled diamond IS the milestone's body - chrome, so a custom\n // renderEvent still starts from a blank canvas (data-milestone\n // keeps the fact readable there)\n <span\n aria-hidden\n data-slot=\"gantt-bar-milestone\"\n className={cn(\n \"size-2.5 shrink-0 rotate-45 rounded-[2px] border border-(--gantt-event-color) bg-(--gantt-event-color)/80\",\n isSelected && \"ring-2 ring-ring/50\",\n )}\n />\n )}\n {progress !== null && !milestone && (\n // Chrome, not content: it is an absolutely-positioned layer BEHIND\n // whatever the bar renders, so a consumer bar (renderEvent) keeps\n // its completion fill instead of silently losing it. The inline\n // done-mark below stays gated, because that one really is content.\n <span\n aria-hidden\n data-slot=\"gantt-bar-progress\"\n className=\"pointer-events-none absolute inset-y-0 start-0 border-(--gantt-event-color)/65 border-e bg-(--gantt-event-color)/40 data-full:border-e-0\"\n data-full={progress === 100 || undefined}\n style={{ width: `${progress}%` }}\n />\n )}\n {progress === 100 && !consumerOwnsContent && !milestone && (\n // done mark: completion chrome like the fill itself, so it shows\n // for outside-label bars too (where the inner content is empty)\n <CheckIcon className=\"relative size-2.5 shrink-0 opacity-80\" aria-hidden=\"true\" />\n )}\n {content}\n {resizeHandles}\n </>\n ),\n };\n\n const barButton = useRender({\n defaultTagName: \"button\",\n render,\n props: mergeProps<\"button\">(defaultProps, props),\n });\n\n // Consumer-owned right-click menu (headless): the primitive only wires the\n // ContextMenu; the items and their handlers come entirely from the block.\n const menu = viewConfig.renderEventMenu?.(renderProps);\n\n // The bar is simultaneously the tooltip trigger and (when a menu exists)\n // the context-menu trigger; Base UI composes both via render props.\n const trigger = menu ? (\n <ContextMenuTrigger render={<TooltipTrigger render={barButton} />} />\n ) : (\n <TooltipTrigger render={barButton} />\n );\n\n const barTree = (\n <TooltipProvider delay={500} closeDelay={0} timeout={300}>\n <Tooltip\n open={tipOpen && !anyInteracting}\n onOpenChange={(next: boolean, details: { reason?: string }) => {\n // opens only on hover; focus/press opens are dropped\n if (next && details?.reason !== \"trigger-hover\") return;\n setTipOpen(next);\n }}\n >\n {trigger}\n {tipOpen && !anyInteracting && (\n <TooltipContent side=\"top\" className=\"pointer-events-none\">\n <div className=\"font-medium\">{event.title}</div>\n <div className=\"opacity-80\">{timeLabel}</div>\n {plannedLabel && <div className=\"opacity-80\">{plannedLabel}</div>}\n </TooltipContent>\n )}\n </Tooltip>\n </TooltipProvider>\n );\n\n return (\n <GanttBarContext.Provider value={{ occurrence, segment, isDragging, isSelected }}>\n {menu ? (\n <ContextMenu>\n {barTree}\n <ContextMenuContent data-slot=\"gantt-bar-menu\" className=\"min-w-44\">\n {menu}\n </ContextMenuContent>\n </ContextMenu>\n ) : (\n barTree\n )}\n </GanttBarContext.Provider>\n );\n}\n\nexport type { GanttBar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igation, useGanttScale, useGanttSettings, useGanttViewConfig } from "./gantt.js";
9
9
  import { useState } from "react";
10
- import { cn } from "@kumix/utils";
11
- import { CalendarIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon } from "lucide-react";
10
+ import { cn } from "cn";
12
11
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
12
+ import { CalendarIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon } from "lucide-react";
13
13
  import { mergeProps } from "@base-ui/react/merge-props";
14
14
  import { useRender } from "@base-ui/react/use-render";
15
15
  import { format } from "date-fns";
@@ -1 +1 @@
1
- {"version":3,"file":"gantt-nav.js","names":[],"sources":["../../../../src/components/reui/gantt/gantt-nav.tsx"],"sourcesContent":["\"use client\";\n\nimport { type ReactNode, useState } from \"react\";\nimport { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { format } from \"date-fns\";\nimport { CalendarIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon } from \"lucide-react\";\n\nimport { cn } from \"@kumix/utils\";\nimport { Button } from \"../../ui/button\";\nimport { Calendar } from \"../../ui/calendar\";\nimport {\n DropdownMenu,\n DropdownMenuContent,\n DropdownMenuGroup,\n DropdownMenuItem,\n DropdownMenuLabel,\n DropdownMenuTrigger,\n} from \"../../ui/dropdown-menu\";\nimport { Popover, PopoverContent, PopoverTrigger } from \"../../ui/popover\";\nimport { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from \"../../ui/tooltip\";\nimport { useGanttNavigation, useGanttScale, useGanttSettings, useGanttViewConfig } from \"./gantt\";\nimport { toZoned } from \"./gantt-lib\";\nimport type { GanttScale } from \"./gantt-types\";\n\nconst GANTT_SCALES: GanttScale[] = [\"day\", \"week\", \"month\", \"quarter\", \"year\"];\n\n/** Configured nav button variant/size (viewConfig.navButtonVariant/Size). */\nfunction useNavButtonProps(): {\n variant: \"ghost\" | \"outline\" | \"secondary\" | \"default\";\n size: \"sm\" | \"default\";\n iconSize: \"icon-sm\" | \"icon\";\n} {\n const viewConfig = useGanttViewConfig();\n return {\n variant: viewConfig.navButtonVariant,\n size: viewConfig.navButtonSize,\n iconSize: viewConfig.navButtonSize === \"sm\" ? \"icon-sm\" : \"icon\",\n };\n}\n\ntype NavButtonProps = Omit<useRender.ComponentProps<\"button\">, \"children\"> & {\n children?: ReactNode;\n /**\n * Tooltip policy (the part that usually goes wrong on clickable elements):\n * tooltips appear ONLY on hover or keyboard focus-visible - a pointer click\n * never re-triggers them, and buttons that open overlays (the period\n * selector, consumer dialog buttons) get NO tooltip at all so nothing\n * flashes when focus returns. Icon-only buttons default to their accessible\n * label; Today defaults to the actual current date. Pass null to disable.\n */\n tooltip?: ReactNode | null;\n};\n\n/** Hover/focus-visible tooltip wrapper; renders the bare button when disabled. */\nfunction NavTooltip({\n content,\n children,\n}: {\n content: ReactNode | null;\n children: React.ReactElement;\n}) {\n if (content === null || content === undefined) return children;\n return (\n <Tooltip>\n <TooltipTrigger render={children} />\n <TooltipContent side=\"bottom\">{content}</TooltipContent>\n </Tooltip>\n );\n}\n\nfunction GanttNavToday({ className, render, children, tooltip, ...props }: NavButtonProps) {\n const { today, isToday } = useGanttNavigation();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n // zoned: a system-zone new Date() can name a different day than Today opens\n const defaultTooltip = format(\n toZoned(new Date(), settings.timeZone),\n settings.i18n.formats.dayTitle,\n { locale: settings.locale },\n );\n return (\n <NavTooltip content={tooltip === undefined ? defaultTooltip : tooltip}>\n <Button\n variant={nav.variant}\n size={nav.size}\n data-slot=\"gantt-nav-today\"\n data-active={isToday || undefined}\n className={cn(className)}\n onClick={today}\n render={render}\n {...props}\n >\n {children ?? settings.i18n.labels.today}\n </Button>\n </NavTooltip>\n );\n}\n\nfunction GanttNavPrev({ className, render, children, tooltip, ...props }: NavButtonProps) {\n const { prev } = useGanttNavigation();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n return (\n <NavTooltip content={tooltip === undefined ? settings.i18n.labels.previous : tooltip}>\n <Button\n variant={nav.variant}\n size={nav.iconSize}\n data-slot=\"gantt-nav-prev\"\n aria-label={settings.i18n.labels.previous}\n className={cn(className)}\n onClick={prev}\n render={render}\n {...props}\n >\n {children ?? <ChevronLeftIcon className=\"size-4\" aria-hidden=\"true\" />}\n </Button>\n </NavTooltip>\n );\n}\n\nfunction GanttNavNext({ className, render, children, tooltip, ...props }: NavButtonProps) {\n const { next } = useGanttNavigation();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n return (\n <NavTooltip content={tooltip === undefined ? settings.i18n.labels.next : tooltip}>\n <Button\n variant={nav.variant}\n size={nav.iconSize}\n data-slot=\"gantt-nav-next\"\n aria-label={settings.i18n.labels.next}\n className={cn(className)}\n onClick={next}\n render={render}\n {...props}\n >\n {children ?? <ChevronRightIcon className=\"size-4\" aria-hidden=\"true\" />}\n </Button>\n </NavTooltip>\n );\n}\n\ninterface GanttTitleProps extends useRender.ComponentProps<\"div\"> {\n format?: (ctx: { title: string }) => ReactNode;\n}\n\nfunction GanttTitle({ className, render, format: formatTitle, ...props }: GanttTitleProps) {\n const { title } = useGanttNavigation();\n const defaultProps = {\n \"data-slot\": \"gantt-title\",\n \"aria-live\": \"polite\" as const,\n className: cn(\"min-w-0 truncate font-semibold text-sm\", className),\n children: formatTitle?.({ title }) ?? title,\n };\n return useRender({\n defaultTagName: \"div\",\n render,\n props: mergeProps<\"div\">(defaultProps, props),\n });\n}\n\ninterface GanttScaleSwitcherProps extends Omit<useRender.ComponentProps<\"button\">, \"children\"> {\n children?: ReactNode;\n /** Hover/focus-visible hint; defaults to the \"Select view\" label. Pass\n * null to disable (overlay-opener policy). */\n tooltip?: ReactNode | null;\n /** The offered scales, in menu order. Default: all five. */\n scales?: GanttScale[];\n}\n\n/**\n * Scale switcher (\"Select view\"): Day / Week / Month / Quarter / Year, a ghost\n * dropdown button (same shape as the event-calendar view switcher).\n */\nfunction GanttScaleSwitcher({\n className,\n render,\n children,\n tooltip,\n scales = GANTT_SCALES,\n ...props\n}: GanttScaleSwitcherProps) {\n const { scale, setScale } = useGanttScale();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n const labels = settings.i18n.labels;\n // Controlled open: selecting a scale swaps the whole track subtree in the\n // same click, so closing must not depend on the menu's internal handler.\n const [open, setOpen] = useState(false);\n // Hover-only tooltip: when the menu closes, Base UI focuses the trigger\n // again and a focus-opened tooltip would flash - ignore focus opens.\n const [tipOpen, setTipOpen] = useState(false);\n\n const selectScale = (next: GanttScale) => {\n setOpen(false);\n setScale(next);\n };\n\n return (\n <DropdownMenu\n open={open}\n onOpenChange={(next: boolean) => {\n setOpen(next);\n if (next) setTipOpen(false);\n }}\n >\n {/* Tooltip on an overlay-opener: hover-only (focus opens ignored) and\n force-closed while the menu is up, so it never lingers or flashes\n when focus returns on close. */}\n <Tooltip\n open={tipOpen && !open}\n onOpenChange={(next: boolean, details: { reason?: string }) => {\n // opens are hover-only; the trigger-focus open that follows a\n // menu close is ignored, closes always land\n if (next && details?.reason !== \"trigger-hover\") return;\n setTipOpen(next);\n }}\n >\n <DropdownMenuTrigger\n render={\n <TooltipTrigger\n render={\n <Button\n variant={nav.variant}\n size={nav.size}\n data-slot=\"gantt-scale-switcher\"\n aria-label={labels.selectView}\n className={cn(\"gap-1\", className)}\n />\n }\n />\n }\n {...props}\n >\n {children ?? (\n <>\n {labels.scales[scale]}\n <ChevronDownIcon className=\"size-4 opacity-60\" aria-hidden=\"true\" />\n </>\n )}\n </DropdownMenuTrigger>\n {tipOpen && !open && tooltip !== null && (\n <TooltipContent side=\"bottom\">{tooltip ?? labels.selectView}</TooltipContent>\n )}\n </Tooltip>\n <DropdownMenuContent align=\"start\" className=\"min-w-36\">\n {/* Base UI contract: GroupLabel must live inside Menu.Group */}\n <DropdownMenuGroup>\n <DropdownMenuLabel className=\"font-normal text-muted-foreground\">\n {labels.selectView}\n </DropdownMenuLabel>\n {scales.map((value) => (\n <DropdownMenuItem\n key={value}\n data-active={scale === value || undefined}\n onClick={() => selectScale(value)}\n >\n {labels.scales[value]}\n </DropdownMenuItem>\n ))}\n </DropdownMenuGroup>\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n\ninterface GanttDatePickerProps {\n className?: string;\n}\n\n/**\n * Compact go-to-date picker (shadcn Calendar in a popover). No tooltip by\n * design: it opens an overlay (see the NavButtonProps tooltip policy).\n */\nfunction GanttDatePicker({ className }: GanttDatePickerProps) {\n const { date, goTo } = useGanttNavigation();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n const [open, setOpen] = useState(false);\n const zoned = toZoned(date, settings.timeZone);\n\n return (\n <Popover open={open} onOpenChange={setOpen}>\n <PopoverTrigger\n render={\n <Button\n variant={nav.variant}\n size={nav.iconSize}\n data-slot=\"gantt-date-picker\"\n aria-label={settings.i18n.labels.goToDate}\n className={cn(className)}\n />\n }\n >\n <CalendarIcon className=\"size-4\" aria-hidden=\"true\" />\n </PopoverTrigger>\n <PopoverContent align=\"start\" className=\"w-auto p-0!\">\n <Calendar\n mode=\"single\"\n selected={zoned}\n defaultMonth={zoned}\n locale={settings.locale}\n weekStartsOn={settings.weekStartsOn}\n onSelect={(next: Date | undefined) => {\n if (next) {\n goTo(next);\n setOpen(false);\n }\n }}\n />\n </PopoverContent>\n </Popover>\n );\n}\n\ntype GanttToolbarProps = useRender.ComponentProps<\"div\">;\n\n/** Free slot for consumer toolbar buttons; pure layout shell. */\nfunction GanttToolbar({ className, render, ...props }: GanttToolbarProps) {\n const viewConfig = useGanttViewConfig();\n const defaultProps = {\n \"data-slot\": \"gantt-toolbar\",\n className: cn(\"flex items-center gap-2\", viewConfig.classNames?.toolbar, className),\n children: props.children,\n };\n return useRender({\n defaultTagName: \"div\",\n render,\n props: mergeProps<\"div\">(defaultProps, props),\n });\n}\n\ntype GanttNavProps = useRender.ComponentProps<\"div\">;\n\n/**\n * Default composed nav (event-calendar parity): Today, time-period switcher,\n * prev/next, title, spacer. GanttDatePicker stays available for custom\n * compositions. Pass children to use it as a pure layout shell instead.\n */\nfunction GanttNav({ className, render, children, ...props }: GanttNavProps) {\n const viewConfig = useGanttViewConfig();\n const defaultProps = {\n \"data-slot\": \"gantt-nav\",\n className: cn(\n // px so the toolbar controls do not hug the container edge; border-b\n // separates the toolbar from the column header below it\n \"flex min-w-0 flex-wrap items-center gap-2 border-b px-3 py-2\",\n viewConfig.stickyNav && \"sticky top-0 z-30 bg-background\",\n viewConfig.classNames?.nav,\n className,\n ),\n children: children ?? (\n // Shared provider: first tooltip waits, moving between buttons is instant\n <TooltipProvider delay={600} closeDelay={0} timeout={300}>\n <GanttNavToday />\n <GanttScaleSwitcher />\n <div className=\"flex items-center\">\n <GanttNavPrev />\n <GanttNavNext />\n </div>\n <GanttTitle />\n <div className=\"grow\" />\n </TooltipProvider>\n ),\n };\n return useRender({\n defaultTagName: \"div\",\n render,\n props: mergeProps<\"div\">(defaultProps, props),\n });\n}\n\nexport type { GanttNavProps, GanttScaleSwitcherProps, GanttTitleProps, GanttToolbarProps };\nexport {\n GANTT_SCALES,\n GanttDatePicker,\n GanttNav,\n GanttNavNext,\n GanttNavPrev,\n GanttNavToday,\n GanttScaleSwitcher,\n GanttTitle,\n GanttToolbar,\n};\n"],"mappings":";;;;;;;;;;;;;;;;AAyBA,MAAM,eAA6B;CAAC;CAAO;CAAQ;CAAS;CAAW;AAAM;;AAG7E,SAAS,oBAIP;CACA,MAAM,aAAa,mBAAmB;CACtC,OAAO;EACL,SAAS,WAAW;EACpB,MAAM,WAAW;EACjB,UAAU,WAAW,kBAAkB,OAAO,YAAY;CAC5D;AACF;;AAgBA,SAAS,WAAW,EAClB,SACA,YAIC;CACD,IAAI,YAAY,QAAQ,YAAY,KAAA,GAAW,OAAO;CACtD,OACE,qBAAC,SAAD,EAAA,UAAA,CACE,oBAAC,gBAAD,EAAgB,QAAQ,SAAW,CAAA,GACnC,oBAAC,gBAAD;EAAgB,MAAK;EAAU,UAAA;CAAwB,CAAA,CAChD,EAAA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/gantt/gantt-nav.tsx"],"sourcesContent":["\"use client\";\n\nimport { type ReactNode, useState } from \"react\";\nimport { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { cn } from \"cn\";\nimport { format } from \"date-fns\";\nimport { CalendarIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon } from \"lucide-react\";\n\nimport { Button } from \"../../ui/button\";\nimport { Calendar } from \"../../ui/calendar\";\nimport {\n DropdownMenu,\n DropdownMenuContent,\n DropdownMenuGroup,\n DropdownMenuItem,\n DropdownMenuLabel,\n DropdownMenuTrigger,\n} from \"../../ui/dropdown-menu\";\nimport { Popover, PopoverContent, PopoverTrigger } from \"../../ui/popover\";\nimport { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from \"../../ui/tooltip\";\nimport { useGanttNavigation, useGanttScale, useGanttSettings, useGanttViewConfig } from \"./gantt\";\nimport { toZoned } from \"./gantt-lib\";\nimport type { GanttScale } from \"./gantt-types\";\n\nconst GANTT_SCALES: GanttScale[] = [\"day\", \"week\", \"month\", \"quarter\", \"year\"];\n\n/** Configured nav button variant/size (viewConfig.navButtonVariant/Size). */\nfunction useNavButtonProps(): {\n variant: \"ghost\" | \"outline\" | \"secondary\" | \"default\";\n size: \"sm\" | \"default\";\n iconSize: \"icon-sm\" | \"icon\";\n} {\n const viewConfig = useGanttViewConfig();\n return {\n variant: viewConfig.navButtonVariant,\n size: viewConfig.navButtonSize,\n iconSize: viewConfig.navButtonSize === \"sm\" ? \"icon-sm\" : \"icon\",\n };\n}\n\ntype NavButtonProps = Omit<useRender.ComponentProps<\"button\">, \"children\"> & {\n children?: ReactNode;\n /**\n * Tooltip policy (the part that usually goes wrong on clickable elements):\n * tooltips appear ONLY on hover or keyboard focus-visible - a pointer click\n * never re-triggers them, and buttons that open overlays (the period\n * selector, consumer dialog buttons) get NO tooltip at all so nothing\n * flashes when focus returns. Icon-only buttons default to their accessible\n * label; Today defaults to the actual current date. Pass null to disable.\n */\n tooltip?: ReactNode | null;\n};\n\n/** Hover/focus-visible tooltip wrapper; renders the bare button when disabled. */\nfunction NavTooltip({\n content,\n children,\n}: {\n content: ReactNode | null;\n children: React.ReactElement;\n}) {\n if (content === null || content === undefined) return children;\n return (\n <Tooltip>\n <TooltipTrigger render={children} />\n <TooltipContent side=\"bottom\">{content}</TooltipContent>\n </Tooltip>\n );\n}\n\nfunction GanttNavToday({ className, render, children, tooltip, ...props }: NavButtonProps) {\n const { today, isToday } = useGanttNavigation();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n // zoned: a system-zone new Date() can name a different day than Today opens\n const defaultTooltip = format(\n toZoned(new Date(), settings.timeZone),\n settings.i18n.formats.dayTitle,\n { locale: settings.locale },\n );\n return (\n <NavTooltip content={tooltip === undefined ? defaultTooltip : tooltip}>\n <Button\n variant={nav.variant}\n size={nav.size}\n data-slot=\"gantt-nav-today\"\n data-active={isToday || undefined}\n className={cn(className)}\n onClick={today}\n render={render}\n {...props}\n >\n {children ?? settings.i18n.labels.today}\n </Button>\n </NavTooltip>\n );\n}\n\nfunction GanttNavPrev({ className, render, children, tooltip, ...props }: NavButtonProps) {\n const { prev } = useGanttNavigation();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n return (\n <NavTooltip content={tooltip === undefined ? settings.i18n.labels.previous : tooltip}>\n <Button\n variant={nav.variant}\n size={nav.iconSize}\n data-slot=\"gantt-nav-prev\"\n aria-label={settings.i18n.labels.previous}\n className={cn(className)}\n onClick={prev}\n render={render}\n {...props}\n >\n {children ?? <ChevronLeftIcon className=\"size-4\" aria-hidden=\"true\" />}\n </Button>\n </NavTooltip>\n );\n}\n\nfunction GanttNavNext({ className, render, children, tooltip, ...props }: NavButtonProps) {\n const { next } = useGanttNavigation();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n return (\n <NavTooltip content={tooltip === undefined ? settings.i18n.labels.next : tooltip}>\n <Button\n variant={nav.variant}\n size={nav.iconSize}\n data-slot=\"gantt-nav-next\"\n aria-label={settings.i18n.labels.next}\n className={cn(className)}\n onClick={next}\n render={render}\n {...props}\n >\n {children ?? <ChevronRightIcon className=\"size-4\" aria-hidden=\"true\" />}\n </Button>\n </NavTooltip>\n );\n}\n\ninterface GanttTitleProps extends useRender.ComponentProps<\"div\"> {\n format?: (ctx: { title: string }) => ReactNode;\n}\n\nfunction GanttTitle({ className, render, format: formatTitle, ...props }: GanttTitleProps) {\n const { title } = useGanttNavigation();\n const defaultProps = {\n \"data-slot\": \"gantt-title\",\n \"aria-live\": \"polite\" as const,\n className: cn(\"min-w-0 truncate font-semibold text-sm\", className),\n children: formatTitle?.({ title }) ?? title,\n };\n return useRender({\n defaultTagName: \"div\",\n render,\n props: mergeProps<\"div\">(defaultProps, props),\n });\n}\n\ninterface GanttScaleSwitcherProps extends Omit<useRender.ComponentProps<\"button\">, \"children\"> {\n children?: ReactNode;\n /** Hover/focus-visible hint; defaults to the \"Select view\" label. Pass\n * null to disable (overlay-opener policy). */\n tooltip?: ReactNode | null;\n /** The offered scales, in menu order. Default: all five. */\n scales?: GanttScale[];\n}\n\n/**\n * Scale switcher (\"Select view\"): Day / Week / Month / Quarter / Year, a ghost\n * dropdown button (same shape as the event-calendar view switcher).\n */\nfunction GanttScaleSwitcher({\n className,\n render,\n children,\n tooltip,\n scales = GANTT_SCALES,\n ...props\n}: GanttScaleSwitcherProps) {\n const { scale, setScale } = useGanttScale();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n const labels = settings.i18n.labels;\n // Controlled open: selecting a scale swaps the whole track subtree in the\n // same click, so closing must not depend on the menu's internal handler.\n const [open, setOpen] = useState(false);\n // Hover-only tooltip: when the menu closes, Base UI focuses the trigger\n // again and a focus-opened tooltip would flash - ignore focus opens.\n const [tipOpen, setTipOpen] = useState(false);\n\n const selectScale = (next: GanttScale) => {\n setOpen(false);\n setScale(next);\n };\n\n return (\n <DropdownMenu\n open={open}\n onOpenChange={(next: boolean) => {\n setOpen(next);\n if (next) setTipOpen(false);\n }}\n >\n {/* Tooltip on an overlay-opener: hover-only (focus opens ignored) and\n force-closed while the menu is up, so it never lingers or flashes\n when focus returns on close. */}\n <Tooltip\n open={tipOpen && !open}\n onOpenChange={(next: boolean, details: { reason?: string }) => {\n // opens are hover-only; the trigger-focus open that follows a\n // menu close is ignored, closes always land\n if (next && details?.reason !== \"trigger-hover\") return;\n setTipOpen(next);\n }}\n >\n <DropdownMenuTrigger\n render={\n <TooltipTrigger\n render={\n <Button\n variant={nav.variant}\n size={nav.size}\n data-slot=\"gantt-scale-switcher\"\n aria-label={labels.selectView}\n className={cn(\"gap-1\", className)}\n />\n }\n />\n }\n {...props}\n >\n {children ?? (\n <>\n {labels.scales[scale]}\n <ChevronDownIcon className=\"size-4 opacity-60\" aria-hidden=\"true\" />\n </>\n )}\n </DropdownMenuTrigger>\n {tipOpen && !open && tooltip !== null && (\n <TooltipContent side=\"bottom\">{tooltip ?? labels.selectView}</TooltipContent>\n )}\n </Tooltip>\n <DropdownMenuContent align=\"start\" className=\"min-w-36\">\n {/* Base UI contract: GroupLabel must live inside Menu.Group */}\n <DropdownMenuGroup>\n <DropdownMenuLabel className=\"font-normal text-muted-foreground\">\n {labels.selectView}\n </DropdownMenuLabel>\n {scales.map((value) => (\n <DropdownMenuItem\n key={value}\n data-active={scale === value || undefined}\n onClick={() => selectScale(value)}\n >\n {labels.scales[value]}\n </DropdownMenuItem>\n ))}\n </DropdownMenuGroup>\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n\ninterface GanttDatePickerProps {\n className?: string;\n}\n\n/**\n * Compact go-to-date picker (shadcn Calendar in a popover). No tooltip by\n * design: it opens an overlay (see the NavButtonProps tooltip policy).\n */\nfunction GanttDatePicker({ className }: GanttDatePickerProps) {\n const { date, goTo } = useGanttNavigation();\n const settings = useGanttSettings();\n const nav = useNavButtonProps();\n const [open, setOpen] = useState(false);\n const zoned = toZoned(date, settings.timeZone);\n\n return (\n <Popover open={open} onOpenChange={setOpen}>\n <PopoverTrigger\n render={\n <Button\n variant={nav.variant}\n size={nav.iconSize}\n data-slot=\"gantt-date-picker\"\n aria-label={settings.i18n.labels.goToDate}\n className={cn(className)}\n />\n }\n >\n <CalendarIcon className=\"size-4\" aria-hidden=\"true\" />\n </PopoverTrigger>\n <PopoverContent align=\"start\" className=\"w-auto p-0!\">\n <Calendar\n mode=\"single\"\n selected={zoned}\n defaultMonth={zoned}\n locale={settings.locale}\n weekStartsOn={settings.weekStartsOn}\n onSelect={(next: Date | undefined) => {\n if (next) {\n goTo(next);\n setOpen(false);\n }\n }}\n />\n </PopoverContent>\n </Popover>\n );\n}\n\ntype GanttToolbarProps = useRender.ComponentProps<\"div\">;\n\n/** Free slot for consumer toolbar buttons; pure layout shell. */\nfunction GanttToolbar({ className, render, ...props }: GanttToolbarProps) {\n const viewConfig = useGanttViewConfig();\n const defaultProps = {\n \"data-slot\": \"gantt-toolbar\",\n className: cn(\"flex items-center gap-2\", viewConfig.classNames?.toolbar, className),\n children: props.children,\n };\n return useRender({\n defaultTagName: \"div\",\n render,\n props: mergeProps<\"div\">(defaultProps, props),\n });\n}\n\ntype GanttNavProps = useRender.ComponentProps<\"div\">;\n\n/**\n * Default composed nav (event-calendar parity): Today, time-period switcher,\n * prev/next, title, spacer. GanttDatePicker stays available for custom\n * compositions. Pass children to use it as a pure layout shell instead.\n */\nfunction GanttNav({ className, render, children, ...props }: GanttNavProps) {\n const viewConfig = useGanttViewConfig();\n const defaultProps = {\n \"data-slot\": \"gantt-nav\",\n className: cn(\n // px so the toolbar controls do not hug the container edge; border-b\n // separates the toolbar from the column header below it\n \"flex min-w-0 flex-wrap items-center gap-2 border-b px-3 py-2\",\n viewConfig.stickyNav && \"sticky top-0 z-30 bg-background\",\n viewConfig.classNames?.nav,\n className,\n ),\n children: children ?? (\n // Shared provider: first tooltip waits, moving between buttons is instant\n <TooltipProvider delay={600} closeDelay={0} timeout={300}>\n <GanttNavToday />\n <GanttScaleSwitcher />\n <div className=\"flex items-center\">\n <GanttNavPrev />\n <GanttNavNext />\n </div>\n <GanttTitle />\n <div className=\"grow\" />\n </TooltipProvider>\n ),\n };\n return useRender({\n defaultTagName: \"div\",\n render,\n props: mergeProps<\"div\">(defaultProps, props),\n });\n}\n\nexport type { GanttNavProps, GanttScaleSwitcherProps, GanttTitleProps, GanttToolbarProps };\nexport {\n GANTT_SCALES,\n GanttDatePicker,\n GanttNav,\n GanttNavNext,\n GanttNavPrev,\n GanttNavToday,\n GanttScaleSwitcher,\n GanttTitle,\n GanttToolbar,\n};\n"],"mappings":";;;;;;;;;;;;;;;;AAyBA,MAAM,eAA6B;CAAC;CAAO;CAAQ;CAAS;CAAW;AAAM;;AAG7E,SAAS,oBAIP;CACA,MAAM,aAAa,mBAAmB;CACtC,OAAO;EACL,SAAS,WAAW;EACpB,MAAM,WAAW;EACjB,UAAU,WAAW,kBAAkB,OAAO,YAAY;CAC5D;AACF;;AAgBA,SAAS,WAAW,EAClB,SACA,YAIC;CACD,IAAI,YAAY,QAAQ,YAAY,KAAA,GAAW,OAAO;CACtD,OACE,qBAAC,SAAD,EAAA,UAAA,CACE,oBAAC,gBAAD,EAAgB,QAAQ,SAAW,CAAA,GACnC,oBAAC,gBAAD;EAAgB,MAAK;EAAU,UAAA;CAAwB,CAAA,CAChD,EAAA,CAAA;AAEb;AAEA,SAAS,cAAc,EAAE,WAAW,QAAQ,UAAU,SAAS,GAAG,SAAyB;CACzF,MAAM,EAAE,OAAO,YAAY,mBAAmB;CAC9C,MAAM,WAAW,iBAAiB;CAClC,MAAM,MAAM,kBAAkB;CAE9B,MAAM,iBAAiB,OACrB,wBAAQ,IAAI,KAAK,GAAG,SAAS,QAAQ,GACrC,SAAS,KAAK,QAAQ,UACtB,EAAE,QAAQ,SAAS,OAAO,CAC5B;CACA,OACE,oBAAC,YAAD;EAAY,SAAS,YAAY,KAAA,IAAY,iBAAiB;EAC5D,UAAA,oBAAC,QAAD;GACE,SAAS,IAAI;GACb,MAAM,IAAI;GACV,aAAU;GACV,eA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AAW,YAAY,SAAS,SAAS;EAClF,UAAU,MAAM;CAClB;CACA,OAAO,UAAU;EACf,gBAAgB;EAChB;EACA,OAAO,WAAkB,cAAc,KAAK;CAC9C,CAAC;AACH;;;;;;AASA,SAAS,SAAS,EAAE,WAAW,QAAQ,UAAU,GAAG,SAAwB;CAC1E,MAAM,aAAa,mBAAmB;CACtC,MAAM,eAAe;EACnB,aAAa;EACb,WAAW,GAGT,gEACA,WAAW,aAAa,mCACxB,WAAW,YAAY,KACvB,SACF;EACA,UAAU,YAER,qBAAC,iBAAD;GAAiB,OAAO;GAAK,YAAY;GAAG,SAAS;GAArD,UAAA;IACE,oBAAC,eAAD,CAAgB,CAAA;IAChB,oBAAC,oBAAD,CAAqB,CAAA;IACrB,qBAAC,OAAD;KAAK,WAAU;KAAf,UAAA,CACE,oBAAC,cAAD,CAAe,CAAA,GACf,oBAAC,cAAD,CAAe,CAAA,CACZ;;IACL,oBAAC,YAAD,CAAa,CAAA;IACb,oBAAC,OAAD,EAAK,WAAU,OAAQ,CAAA;GACR;;CAErB;CACA,OAAO,UAAU;EACf,gBAAgB;EAChB;EACA,OAAO,WAAkB,cAAc,KAAK;CAC9C,CAAC;AACH"}
@@ -9,9 +9,9 @@ import { resolveScheduleMode, resolveTimelineLines, useGantt, useGanttSelector,
9
9
  import { cancelActiveGanttGestures, markGestureEnd, useGanttGestureTeardown, useGanttGestures, wasRecentDrag } from "./gantt-dnd.js";
10
10
  import { GanttBar } from "./gantt-bar.js";
11
11
  import { memo, useCallback, useEffect, useLayoutEffect, useMemo, useRef, useState } from "react";
12
- import { cn } from "@kumix/utils";
13
- import { ChevronLeftIcon, ChevronRightIcon, GripVerticalIcon, MinusIcon, PlusIcon } from "lucide-react";
12
+ import { cn } from "cn";
14
13
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
14
+ import { ChevronLeftIcon, ChevronRightIcon, GripVerticalIcon, MinusIcon, PlusIcon } from "lucide-react";
15
15
  import { ScrollArea } from "@base-ui/react/scroll-area";
16
16
  import { mergeProps } from "@base-ui/react/merge-props";
17
17
  import { useRender } from "@base-ui/react/use-render";