@btst/stack 1.10.0 → 1.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (237) hide show
  1. package/dist/node_modules/.pnpm/@dnd-kit_core@6.3.1_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/@dnd-kit/core/dist/core.esm.cjs +1 -1
  2. package/dist/node_modules/.pnpm/@dnd-kit_core@6.3.1_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/@dnd-kit/core/dist/core.esm.mjs +1 -1
  3. package/dist/node_modules/.pnpm/@dnd-kit_sortable@10.0.0_@dnd-kit_core@6.3.1_react-dom@19.2.0_react@19.2.0__react@19.2.0__react@19.2.0/node_modules/@dnd-kit/sortable/dist/sortable.esm.cjs +77 -0
  4. package/dist/node_modules/.pnpm/@dnd-kit_sortable@10.0.0_@dnd-kit_core@6.3.1_react-dom@19.2.0_react@19.2.0__react@19.2.0__react@19.2.0/node_modules/@dnd-kit/sortable/dist/sortable.esm.mjs +79 -3
  5. package/dist/node_modules/.pnpm/@radix-ui_react-avatar@1.1.11_@types_react-dom@19.2.3_@types_react@19.2.6__@types_react_850cfbef1935a6e49a6ad6c93c7ca70d/node_modules/@radix-ui/react-avatar/dist/index.cjs +140 -0
  6. package/dist/node_modules/.pnpm/@radix-ui_react-avatar@1.1.11_@types_react-dom@19.2.3_@types_react@19.2.6__@types_react_850cfbef1935a6e49a6ad6c93c7ca70d/node_modules/@radix-ui/react-avatar/dist/index.mjs +119 -0
  7. package/dist/node_modules/.pnpm/@radix-ui_react-context@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-context/dist/index.cjs +80 -0
  8. package/dist/node_modules/.pnpm/@radix-ui_react-context@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-context/dist/index.mjs +64 -0
  9. package/dist/node_modules/.pnpm/@radix-ui_react-use-is-hydrated@0.1.0_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-is-hydrated/dist/index.cjs +18 -0
  10. package/dist/node_modules/.pnpm/@radix-ui_react-use-is-hydrated@0.1.0_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-is-hydrated/dist/index.mjs +16 -0
  11. package/dist/packages/better-stack/src/plugins/kanban/api/plugin.cjs +846 -0
  12. package/dist/packages/better-stack/src/plugins/kanban/api/plugin.mjs +844 -0
  13. package/dist/packages/better-stack/src/plugins/kanban/client/components/forms/board-form.cjs +85 -0
  14. package/dist/packages/better-stack/src/plugins/kanban/client/components/forms/board-form.mjs +83 -0
  15. package/dist/packages/better-stack/src/plugins/kanban/client/components/forms/column-form.cjs +72 -0
  16. package/dist/packages/better-stack/src/plugins/kanban/client/components/forms/column-form.mjs +70 -0
  17. package/dist/packages/better-stack/src/plugins/kanban/client/components/forms/task-form.cjs +200 -0
  18. package/dist/packages/better-stack/src/plugins/kanban/client/components/forms/task-form.mjs +198 -0
  19. package/dist/packages/better-stack/src/plugins/kanban/client/components/loading/board-skeleton.cjs +47 -0
  20. package/dist/packages/better-stack/src/plugins/kanban/client/components/loading/board-skeleton.mjs +45 -0
  21. package/dist/packages/better-stack/src/plugins/kanban/client/components/loading/boards-list-skeleton.cjs +30 -0
  22. package/dist/packages/better-stack/src/plugins/kanban/client/components/loading/boards-list-skeleton.mjs +28 -0
  23. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/404-page.cjs +27 -0
  24. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/404-page.mjs +25 -0
  25. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/board-page.cjs +31 -0
  26. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/board-page.internal.cjs +458 -0
  27. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/board-page.internal.mjs +456 -0
  28. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/board-page.mjs +29 -0
  29. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/boards-list-page.cjs +30 -0
  30. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/boards-list-page.internal.cjs +72 -0
  31. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/boards-list-page.internal.mjs +70 -0
  32. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/boards-list-page.mjs +28 -0
  33. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/new-board-page.cjs +30 -0
  34. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/new-board-page.internal.cjs +51 -0
  35. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/new-board-page.internal.mjs +49 -0
  36. package/dist/packages/better-stack/src/plugins/kanban/client/components/pages/new-board-page.mjs +28 -0
  37. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/column-content.cjs +76 -0
  38. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/column-content.mjs +74 -0
  39. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/default-error.cjs +27 -0
  40. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/default-error.mjs +25 -0
  41. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/empty-state.cjs +32 -0
  42. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/empty-state.mjs +30 -0
  43. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/kanban-board.cjs +78 -0
  44. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/kanban-board.mjs +76 -0
  45. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/page-wrapper.cjs +15 -0
  46. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/page-wrapper.mjs +13 -0
  47. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/task-card.cjs +68 -0
  48. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/task-card.mjs +66 -0
  49. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/user-avatar.cjs +32 -0
  50. package/dist/packages/better-stack/src/plugins/kanban/client/components/shared/user-avatar.mjs +30 -0
  51. package/dist/packages/better-stack/src/plugins/kanban/client/hooks/kanban-hooks.cjs +391 -0
  52. package/dist/packages/better-stack/src/plugins/kanban/client/hooks/kanban-hooks.mjs +381 -0
  53. package/dist/packages/better-stack/src/plugins/kanban/client/plugin.cjs +290 -0
  54. package/dist/packages/better-stack/src/plugins/kanban/client/plugin.mjs +288 -0
  55. package/dist/packages/better-stack/src/plugins/kanban/db.cjs +125 -0
  56. package/dist/packages/better-stack/src/plugins/kanban/db.mjs +123 -0
  57. package/dist/packages/better-stack/src/plugins/kanban/schemas.cjs +117 -0
  58. package/dist/packages/better-stack/src/plugins/kanban/schemas.mjs +102 -0
  59. package/dist/packages/better-stack/src/plugins/kanban/utils.cjs +49 -0
  60. package/dist/packages/better-stack/src/plugins/kanban/utils.mjs +45 -0
  61. package/dist/packages/ui/src/components/avatar.cjs +58 -0
  62. package/dist/packages/ui/src/components/avatar.mjs +54 -0
  63. package/dist/packages/ui/src/components/command.cjs +3 -3
  64. package/dist/packages/ui/src/components/command.mjs +3 -3
  65. package/dist/packages/ui/src/components/form-builder/index.mjs +2 -2
  66. package/dist/packages/ui/src/components/kanban.cjs +835 -0
  67. package/dist/packages/ui/src/components/kanban.mjs +805 -0
  68. package/dist/packages/ui/src/components/minimal-tiptap/utils.cjs +15 -11
  69. package/dist/packages/ui/src/components/minimal-tiptap/utils.mjs +15 -11
  70. package/dist/packages/ui/src/components/popover.cjs +8 -3
  71. package/dist/packages/ui/src/components/popover.mjs +9 -4
  72. package/dist/packages/ui/src/components/search-select.cjs +75 -0
  73. package/dist/packages/ui/src/components/search-select.mjs +73 -0
  74. package/dist/packages/ui/src/components/ui-builder/index.cjs +9 -7
  75. package/dist/packages/ui/src/components/ui-builder/index.mjs +9 -7
  76. package/dist/packages/ui/src/components/ui-builder/internal/canvas/auto-frame.cjs +6 -3
  77. package/dist/packages/ui/src/components/ui-builder/internal/canvas/auto-frame.mjs +6 -3
  78. package/dist/packages/ui/src/components/ui-builder/internal/components/add-component-popover.cjs +228 -48
  79. package/dist/packages/ui/src/components/ui-builder/internal/components/add-component-popover.mjs +228 -48
  80. package/dist/packages/ui/src/components/ui-builder/internal/components/element-selector.cjs +1 -1
  81. package/dist/packages/ui/src/components/ui-builder/internal/components/element-selector.mjs +1 -1
  82. package/dist/packages/ui/src/components/ui-builder/internal/components/error-fallback.cjs +4 -2
  83. package/dist/packages/ui/src/components/ui-builder/internal/components/error-fallback.mjs +4 -2
  84. package/dist/packages/ui/src/components/ui-builder/internal/components/multi-select.cjs +6 -3
  85. package/dist/packages/ui/src/components/ui-builder/internal/components/multi-select.mjs +6 -3
  86. package/dist/packages/ui/src/components/ui-builder/internal/dnd/draggable-new-component.cjs +67 -0
  87. package/dist/packages/ui/src/components/ui-builder/internal/dnd/draggable-new-component.mjs +62 -0
  88. package/dist/packages/ui/src/components/ui-builder/internal/dnd/drop-zone.cjs +181 -37
  89. package/dist/packages/ui/src/components/ui-builder/internal/dnd/drop-zone.mjs +181 -38
  90. package/dist/packages/ui/src/components/ui-builder/internal/editor-panel.cjs +1 -1
  91. package/dist/packages/ui/src/components/ui-builder/internal/editor-panel.mjs +1 -1
  92. package/dist/packages/ui/src/components/ui-builder/internal/form-fields/classname-control/classname-group-control.cjs +1 -1
  93. package/dist/packages/ui/src/components/ui-builder/internal/form-fields/classname-control/classname-group-control.mjs +1 -1
  94. package/dist/packages/ui/src/components/ui-builder/internal/form-fields/classname-control/classname-item-control.cjs +9 -2
  95. package/dist/packages/ui/src/components/ui-builder/internal/form-fields/classname-control/classname-item-control.mjs +9 -2
  96. package/dist/packages/ui/src/components/ui-builder/internal/form-fields/iconname-field.cjs +3 -2
  97. package/dist/packages/ui/src/components/ui-builder/internal/form-fields/iconname-field.mjs +3 -2
  98. package/dist/packages/ui/src/components/ui-builder/internal/layers-panel.cjs +1 -1
  99. package/dist/packages/ui/src/components/ui-builder/internal/layers-panel.mjs +1 -1
  100. package/dist/packages/ui/src/components/ui-builder/internal/props-panel.cjs +17 -5
  101. package/dist/packages/ui/src/components/ui-builder/internal/props-panel.mjs +17 -5
  102. package/dist/packages/ui/src/components/ui-builder/internal/utils/render-utils.cjs +70 -16
  103. package/dist/packages/ui/src/components/ui-builder/internal/utils/render-utils.mjs +73 -20
  104. package/dist/packages/ui/src/lib/compose-refs.cjs +56 -0
  105. package/dist/packages/ui/src/lib/compose-refs.mjs +39 -0
  106. package/dist/packages/ui/src/lib/ui-builder/context/dnd-context-colission-utils.cjs +14 -9
  107. package/dist/packages/ui/src/lib/ui-builder/context/dnd-context-colission-utils.mjs +14 -9
  108. package/dist/packages/ui/src/lib/ui-builder/context/dnd-context.cjs +38 -10
  109. package/dist/packages/ui/src/lib/ui-builder/context/dnd-context.mjs +35 -11
  110. package/dist/packages/ui/src/lib/ui-builder/context/dnd-contexts.cjs +1 -0
  111. package/dist/packages/ui/src/lib/ui-builder/context/dnd-contexts.mjs +1 -0
  112. package/dist/packages/ui/src/lib/ui-builder/context/drag-overlay.cjs +7 -4
  113. package/dist/packages/ui/src/lib/ui-builder/context/drag-overlay.mjs +7 -4
  114. package/dist/packages/ui/src/lib/ui-builder/hooks/use-auto-scroll.cjs +4 -4
  115. package/dist/packages/ui/src/lib/ui-builder/hooks/use-auto-scroll.mjs +4 -4
  116. package/dist/packages/ui/src/lib/ui-builder/hooks/use-dnd-event-handlers.cjs +53 -16
  117. package/dist/packages/ui/src/lib/ui-builder/hooks/use-dnd-event-handlers.mjs +53 -16
  118. package/dist/packages/ui/src/lib/ui-builder/hooks/use-drop-validation.cjs +23 -7
  119. package/dist/packages/ui/src/lib/ui-builder/hooks/use-drop-validation.mjs +23 -7
  120. package/dist/packages/ui/src/lib/ui-builder/registry/form-field-overrides.cjs +110 -11
  121. package/dist/packages/ui/src/lib/ui-builder/registry/form-field-overrides.mjs +111 -13
  122. package/dist/packages/ui/src/lib/ui-builder/store/editor-store.cjs +3 -2
  123. package/dist/packages/ui/src/lib/ui-builder/store/editor-store.mjs +3 -2
  124. package/dist/packages/ui/src/lib/ui-builder/store/layer-store.cjs +53 -7
  125. package/dist/packages/ui/src/lib/ui-builder/store/layer-store.mjs +54 -8
  126. package/dist/packages/ui/src/lib/ui-builder/store/layer-utils.cjs +4 -3
  127. package/dist/packages/ui/src/lib/ui-builder/store/layer-utils.mjs +4 -3
  128. package/dist/packages/ui/src/lib/ui-builder/utils/variable-resolver.cjs +12 -0
  129. package/dist/packages/ui/src/lib/ui-builder/utils/variable-resolver.mjs +12 -1
  130. package/dist/plugins/blog/api/index.d.cts +1 -1
  131. package/dist/plugins/blog/api/index.d.mts +1 -1
  132. package/dist/plugins/blog/api/index.d.ts +1 -1
  133. package/dist/plugins/blog/client/hooks/index.d.cts +2 -2
  134. package/dist/plugins/blog/client/hooks/index.d.mts +2 -2
  135. package/dist/plugins/blog/client/hooks/index.d.ts +2 -2
  136. package/dist/plugins/blog/client/index.d.cts +1 -1
  137. package/dist/plugins/blog/client/index.d.mts +1 -1
  138. package/dist/plugins/blog/client/index.d.ts +1 -1
  139. package/dist/plugins/blog/query-keys.d.cts +2 -2
  140. package/dist/plugins/blog/query-keys.d.mts +2 -2
  141. package/dist/plugins/blog/query-keys.d.ts +2 -2
  142. package/dist/plugins/kanban/api/index.cjs +7 -0
  143. package/dist/plugins/kanban/api/index.d.cts +403 -0
  144. package/dist/plugins/kanban/api/index.d.mts +403 -0
  145. package/dist/plugins/kanban/api/index.d.ts +403 -0
  146. package/dist/plugins/kanban/api/index.mjs +1 -0
  147. package/dist/plugins/kanban/client/components/index.cjs +35 -0
  148. package/dist/plugins/kanban/client/components/index.d.cts +102 -0
  149. package/dist/plugins/kanban/client/components/index.d.mts +102 -0
  150. package/dist/plugins/kanban/client/components/index.d.ts +102 -0
  151. package/dist/plugins/kanban/client/components/index.mjs +15 -0
  152. package/dist/plugins/kanban/client/hooks/index.cjs +15 -0
  153. package/dist/plugins/kanban/client/hooks/index.d.cts +143 -0
  154. package/dist/plugins/kanban/client/hooks/index.d.mts +143 -0
  155. package/dist/plugins/kanban/client/hooks/index.d.ts +143 -0
  156. package/dist/plugins/kanban/client/hooks/index.mjs +1 -0
  157. package/dist/plugins/kanban/client/index.cjs +7 -0
  158. package/dist/plugins/kanban/client/index.d.cts +196 -0
  159. package/dist/plugins/kanban/client/index.d.mts +196 -0
  160. package/dist/plugins/kanban/client/index.d.ts +196 -0
  161. package/dist/plugins/kanban/client/index.mjs +1 -0
  162. package/dist/plugins/kanban/client.css +68 -0
  163. package/dist/plugins/kanban/query-keys.cjs +105 -0
  164. package/dist/plugins/kanban/query-keys.d.cts +59 -0
  165. package/dist/plugins/kanban/query-keys.d.mts +59 -0
  166. package/dist/plugins/kanban/query-keys.d.ts +59 -0
  167. package/dist/plugins/kanban/query-keys.mjs +103 -0
  168. package/dist/plugins/kanban/style.css +7 -0
  169. package/dist/plugins/ui-builder/client/components/index.d.cts +1 -1
  170. package/dist/plugins/ui-builder/client/components/index.d.mts +1 -1
  171. package/dist/plugins/ui-builder/client/components/index.d.ts +1 -1
  172. package/dist/plugins/ui-builder/client/hooks/index.d.cts +2 -2
  173. package/dist/plugins/ui-builder/client/hooks/index.d.mts +2 -2
  174. package/dist/plugins/ui-builder/client/hooks/index.d.ts +2 -2
  175. package/dist/plugins/ui-builder/client/index.d.cts +17 -7
  176. package/dist/plugins/ui-builder/client/index.d.mts +17 -7
  177. package/dist/plugins/ui-builder/client/index.d.ts +17 -7
  178. package/dist/plugins/ui-builder/index.d.cts +2 -2
  179. package/dist/plugins/ui-builder/index.d.mts +2 -2
  180. package/dist/plugins/ui-builder/index.d.ts +2 -2
  181. package/dist/plugins/ui-builder/style.css +6 -0
  182. package/dist/shared/{stack.BSM2cgoq.d.cts → stack.BYysGdHl.d.cts} +1 -1
  183. package/dist/shared/{stack.CqfZWfjJ.d.cts → stack.BdJFrdyt.d.cts} +8 -2
  184. package/dist/shared/{stack.e1FN86dE.d.mts → stack.ChVuHi5e.d.mts} +8 -2
  185. package/dist/shared/stack.DKDMI-QO.d.cts +70 -0
  186. package/dist/shared/stack.DKDMI-QO.d.mts +70 -0
  187. package/dist/shared/stack.DKDMI-QO.d.ts +70 -0
  188. package/dist/shared/{stack.CLtOoAqF.d.mts → stack.DYCFcnkL.d.mts} +1 -1
  189. package/dist/shared/{stack.MMntCVZZ.d.ts → stack.EhM4pmtN.d.ts} +8 -2
  190. package/dist/shared/stack.FeaWkglm.d.cts +190 -0
  191. package/dist/shared/stack.FeaWkglm.d.mts +190 -0
  192. package/dist/shared/stack.FeaWkglm.d.ts +190 -0
  193. package/dist/shared/{stack.BD1m-4yB.d.ts → stack.kFbDspnF.d.ts} +1 -1
  194. package/package.json +56 -2
  195. package/src/plugins/kanban/api/index.ts +6 -0
  196. package/src/plugins/kanban/api/plugin.ts +1245 -0
  197. package/src/plugins/kanban/client/components/forms/board-form.tsx +108 -0
  198. package/src/plugins/kanban/client/components/forms/column-form.tsx +97 -0
  199. package/src/plugins/kanban/client/components/forms/task-form.tsx +274 -0
  200. package/src/plugins/kanban/client/components/index.tsx +21 -0
  201. package/src/plugins/kanban/client/components/loading/board-skeleton.tsx +49 -0
  202. package/src/plugins/kanban/client/components/loading/boards-list-skeleton.tsx +34 -0
  203. package/src/plugins/kanban/client/components/loading/index.tsx +2 -0
  204. package/src/plugins/kanban/client/components/pages/404-page.tsx +28 -0
  205. package/src/plugins/kanban/client/components/pages/board-page.internal.tsx +575 -0
  206. package/src/plugins/kanban/client/components/pages/board-page.tsx +31 -0
  207. package/src/plugins/kanban/client/components/pages/boards-list-page.internal.tsx +101 -0
  208. package/src/plugins/kanban/client/components/pages/boards-list-page.tsx +26 -0
  209. package/src/plugins/kanban/client/components/pages/new-board-page.internal.tsx +65 -0
  210. package/src/plugins/kanban/client/components/pages/new-board-page.tsx +26 -0
  211. package/src/plugins/kanban/client/components/shared/column-content.tsx +108 -0
  212. package/src/plugins/kanban/client/components/shared/default-error.tsx +32 -0
  213. package/src/plugins/kanban/client/components/shared/empty-state.tsx +37 -0
  214. package/src/plugins/kanban/client/components/shared/kanban-board.tsx +87 -0
  215. package/src/plugins/kanban/client/components/shared/page-wrapper.tsx +20 -0
  216. package/src/plugins/kanban/client/components/shared/task-card.tsx +79 -0
  217. package/src/plugins/kanban/client/components/shared/user-avatar.tsx +63 -0
  218. package/src/plugins/kanban/client/hooks/index.tsx +11 -0
  219. package/src/plugins/kanban/client/hooks/kanban-hooks.tsx +560 -0
  220. package/src/plugins/kanban/client/index.ts +8 -0
  221. package/src/plugins/kanban/client/localization/index.ts +28 -0
  222. package/src/plugins/kanban/client/localization/kanban-common.ts +69 -0
  223. package/src/plugins/kanban/client/localization/kanban-forms.ts +70 -0
  224. package/src/plugins/kanban/client/localization/kanban-list.ts +36 -0
  225. package/src/plugins/kanban/client/overrides.ts +145 -0
  226. package/src/plugins/kanban/client/plugin.tsx +463 -0
  227. package/src/plugins/kanban/client.css +68 -0
  228. package/src/plugins/kanban/db.ts +125 -0
  229. package/src/plugins/kanban/query-keys.ts +154 -0
  230. package/src/plugins/kanban/schemas.ts +143 -0
  231. package/src/plugins/kanban/style.css +7 -0
  232. package/src/plugins/kanban/types.ts +106 -0
  233. package/src/plugins/kanban/utils.ts +107 -0
  234. package/src/plugins/ui-builder/style.css +6 -0
  235. package/dist/shared/{stack.DLhzx1-D.d.mts → stack.CcI4sYJP.d.cts} +1 -1
  236. package/dist/shared/{stack.DLhzx1-D.d.ts → stack.CcI4sYJP.d.mts} +1 -1
  237. package/dist/shared/{stack.DLhzx1-D.d.cts → stack.CcI4sYJP.d.ts} +1 -1
@@ -0,0 +1,28 @@
1
+ "use client";
2
+ import { jsx } from 'react/jsx-runtime';
3
+ import { lazy } from 'react';
4
+ import { ComposedRoute } from '@btst/stack/client/components';
5
+ import { DefaultError } from '../shared/default-error.mjs';
6
+ import { BoardsListSkeleton } from '../loading/boards-list-skeleton.mjs';
7
+ import { NotFoundPage } from './404-page.mjs';
8
+
9
+ const BoardsListPage = lazy(
10
+ () => import('./boards-list-page.internal.mjs').then((m) => ({
11
+ default: m.BoardsListPage
12
+ }))
13
+ );
14
+ function BoardsListPageComponent() {
15
+ return /* @__PURE__ */ jsx(
16
+ ComposedRoute,
17
+ {
18
+ path: "/kanban",
19
+ PageComponent: BoardsListPage,
20
+ ErrorComponent: DefaultError,
21
+ LoadingComponent: BoardsListSkeleton,
22
+ NotFoundComponent: NotFoundPage,
23
+ onError: (error) => console.error("BoardsListPage error:", error)
24
+ }
25
+ );
26
+ }
27
+
28
+ export { BoardsListPageComponent };
@@ -0,0 +1,30 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ const jsxRuntime = require('react/jsx-runtime');
5
+ const React = require('react');
6
+ const components = require('@btst/stack/client/components');
7
+ const defaultError = require('../shared/default-error.cjs');
8
+ const boardsListSkeleton = require('../loading/boards-list-skeleton.cjs');
9
+ const _404Page = require('./404-page.cjs');
10
+
11
+ const NewBoardPage = React.lazy(
12
+ () => import('./new-board-page.internal.cjs').then((m) => ({
13
+ default: m.NewBoardPage
14
+ }))
15
+ );
16
+ function NewBoardPageComponent() {
17
+ return /* @__PURE__ */ jsxRuntime.jsx(
18
+ components.ComposedRoute,
19
+ {
20
+ path: "/kanban/new",
21
+ PageComponent: NewBoardPage,
22
+ ErrorComponent: defaultError.DefaultError,
23
+ LoadingComponent: boardsListSkeleton.BoardsListSkeleton,
24
+ NotFoundComponent: _404Page.NotFoundPage,
25
+ onError: (error) => console.error("NewBoardPage error:", error)
26
+ }
27
+ );
28
+ }
29
+
30
+ exports.NewBoardPageComponent = NewBoardPageComponent;
@@ -0,0 +1,51 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ const jsxRuntime = require('react/jsx-runtime');
5
+ const LucideIcons = require('lucide-react');
6
+ const card = require('../../../../../../../ui/src/components/card.cjs');
7
+ const context = require('@btst/stack/context');
8
+ const boardForm = require('../forms/board-form.cjs');
9
+ const pageWrapper = require('../shared/page-wrapper.cjs');
10
+
11
+ function NewBoardPage() {
12
+ const { Link: OverrideLink, navigate: overrideNavigate } = context.usePluginOverrides("kanban");
13
+ const navigate = overrideNavigate || ((path) => {
14
+ window.location.href = path;
15
+ });
16
+ const Link = OverrideLink || "a";
17
+ const handleSuccess = (boardId) => {
18
+ navigate(`/pages/kanban/${boardId}`);
19
+ };
20
+ return /* @__PURE__ */ jsxRuntime.jsxs(pageWrapper.PageWrapper, { "data-testid": "new-board-page", children: [
21
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-4 mb-8", children: [
22
+ /* @__PURE__ */ jsxRuntime.jsx(
23
+ Link,
24
+ {
25
+ href: "/pages/kanban",
26
+ className: "text-muted-foreground hover:text-foreground",
27
+ children: /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.ArrowLeft, { className: "h-5 w-5" })
28
+ }
29
+ ),
30
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
31
+ /* @__PURE__ */ jsxRuntime.jsx("h1", { className: "text-3xl font-bold", "data-testid": "page-header", children: "Create New Board" }),
32
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground mt-1", children: "Set up a new kanban board for your project" })
33
+ ] })
34
+ ] }),
35
+ /* @__PURE__ */ jsxRuntime.jsxs(card.Card, { className: "max-w-2xl", children: [
36
+ /* @__PURE__ */ jsxRuntime.jsxs(card.CardHeader, { children: [
37
+ /* @__PURE__ */ jsxRuntime.jsx(card.CardTitle, { children: "Board Details" }),
38
+ /* @__PURE__ */ jsxRuntime.jsx(card.CardDescription, { children: "Enter the details for your new kanban board." })
39
+ ] }),
40
+ /* @__PURE__ */ jsxRuntime.jsx(card.CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(
41
+ boardForm.BoardForm,
42
+ {
43
+ onClose: () => navigate("/pages/kanban"),
44
+ onSuccess: handleSuccess
45
+ }
46
+ ) })
47
+ ] })
48
+ ] });
49
+ }
50
+
51
+ exports.NewBoardPage = NewBoardPage;
@@ -0,0 +1,49 @@
1
+ "use client";
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { ArrowLeft } from 'lucide-react';
4
+ import { Card, CardHeader, CardTitle, CardDescription, CardContent } from '../../../../../../../ui/src/components/card.mjs';
5
+ import { usePluginOverrides } from '@btst/stack/context';
6
+ import { BoardForm } from '../forms/board-form.mjs';
7
+ import { PageWrapper } from '../shared/page-wrapper.mjs';
8
+
9
+ function NewBoardPage() {
10
+ const { Link: OverrideLink, navigate: overrideNavigate } = usePluginOverrides("kanban");
11
+ const navigate = overrideNavigate || ((path) => {
12
+ window.location.href = path;
13
+ });
14
+ const Link = OverrideLink || "a";
15
+ const handleSuccess = (boardId) => {
16
+ navigate(`/pages/kanban/${boardId}`);
17
+ };
18
+ return /* @__PURE__ */ jsxs(PageWrapper, { "data-testid": "new-board-page", children: [
19
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-4 mb-8", children: [
20
+ /* @__PURE__ */ jsx(
21
+ Link,
22
+ {
23
+ href: "/pages/kanban",
24
+ className: "text-muted-foreground hover:text-foreground",
25
+ children: /* @__PURE__ */ jsx(ArrowLeft, { className: "h-5 w-5" })
26
+ }
27
+ ),
28
+ /* @__PURE__ */ jsxs("div", { children: [
29
+ /* @__PURE__ */ jsx("h1", { className: "text-3xl font-bold", "data-testid": "page-header", children: "Create New Board" }),
30
+ /* @__PURE__ */ jsx("p", { className: "text-muted-foreground mt-1", children: "Set up a new kanban board for your project" })
31
+ ] })
32
+ ] }),
33
+ /* @__PURE__ */ jsxs(Card, { className: "max-w-2xl", children: [
34
+ /* @__PURE__ */ jsxs(CardHeader, { children: [
35
+ /* @__PURE__ */ jsx(CardTitle, { children: "Board Details" }),
36
+ /* @__PURE__ */ jsx(CardDescription, { children: "Enter the details for your new kanban board." })
37
+ ] }),
38
+ /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsx(
39
+ BoardForm,
40
+ {
41
+ onClose: () => navigate("/pages/kanban"),
42
+ onSuccess: handleSuccess
43
+ }
44
+ ) })
45
+ ] })
46
+ ] });
47
+ }
48
+
49
+ export { NewBoardPage };
@@ -0,0 +1,28 @@
1
+ "use client";
2
+ import { jsx } from 'react/jsx-runtime';
3
+ import { lazy } from 'react';
4
+ import { ComposedRoute } from '@btst/stack/client/components';
5
+ import { DefaultError } from '../shared/default-error.mjs';
6
+ import { BoardsListSkeleton } from '../loading/boards-list-skeleton.mjs';
7
+ import { NotFoundPage } from './404-page.mjs';
8
+
9
+ const NewBoardPage = lazy(
10
+ () => import('./new-board-page.internal.mjs').then((m) => ({
11
+ default: m.NewBoardPage
12
+ }))
13
+ );
14
+ function NewBoardPageComponent() {
15
+ return /* @__PURE__ */ jsx(
16
+ ComposedRoute,
17
+ {
18
+ path: "/kanban/new",
19
+ PageComponent: NewBoardPage,
20
+ ErrorComponent: DefaultError,
21
+ LoadingComponent: BoardsListSkeleton,
22
+ NotFoundComponent: NotFoundPage,
23
+ onError: (error) => console.error("NewBoardPage error:", error)
24
+ }
25
+ );
26
+ }
27
+
28
+ export { NewBoardPageComponent };
@@ -0,0 +1,76 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ const jsxRuntime = require('react/jsx-runtime');
5
+ const React = require('react');
6
+ const LucideIcons = require('lucide-react');
7
+ const button = require('../../../../../../../ui/src/components/button.cjs');
8
+ const badge = require('../../../../../../../ui/src/components/badge.cjs');
9
+ const kanban = require('../../../../../../../ui/src/components/kanban.cjs');
10
+ const dropdownMenu = require('../../../../../../../ui/src/components/dropdown-menu.cjs');
11
+ const taskCard = require('./task-card.cjs');
12
+
13
+ function ColumnContentComponent({
14
+ column,
15
+ onAddTask,
16
+ onEditTask,
17
+ onEditColumn,
18
+ onDeleteColumn
19
+ }) {
20
+ const hasTasks = column.tasks && column.tasks.length > 0;
21
+ return /* @__PURE__ */ jsxRuntime.jsxs(kanban.KanbanColumn, { value: column.id, children: [
22
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center", children: [
23
+ /* @__PURE__ */ jsxRuntime.jsx(kanban.KanbanColumnHandle, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "ghost", size: "icon", children: /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.GripVertical, { className: "h-4 w-4" }) }) }),
24
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 flex-1", children: [
25
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-bold text-lg line-clamp-1 flex-1 text-left", children: column.title }),
26
+ /* @__PURE__ */ jsxRuntime.jsx(badge.Badge, { variant: "outline", className: "pointer-events-none rounded-sm", children: column.tasks?.length || 0 })
27
+ ] }),
28
+ /* @__PURE__ */ jsxRuntime.jsxs(dropdownMenu.DropdownMenu, { children: [
29
+ /* @__PURE__ */ jsxRuntime.jsx(dropdownMenu.DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "ghost", size: "icon", children: /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.MoreVertical, { className: "h-4 w-4" }) }) }),
30
+ /* @__PURE__ */ jsxRuntime.jsxs(dropdownMenu.DropdownMenuContent, { align: "end", children: [
31
+ /* @__PURE__ */ jsxRuntime.jsxs(dropdownMenu.DropdownMenuItem, { onClick: onEditColumn, children: [
32
+ /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.Pencil, { className: "mr-2 h-4 w-4" }),
33
+ "Edit Column"
34
+ ] }),
35
+ /* @__PURE__ */ jsxRuntime.jsxs(dropdownMenu.DropdownMenuItem, { onClick: onAddTask, children: [
36
+ /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.Plus, { className: "mr-2 h-4 w-4" }),
37
+ "Add Task"
38
+ ] }),
39
+ /* @__PURE__ */ jsxRuntime.jsx(dropdownMenu.DropdownMenuSeparator, {}),
40
+ /* @__PURE__ */ jsxRuntime.jsxs(
41
+ dropdownMenu.DropdownMenuItem,
42
+ {
43
+ onClick: onDeleteColumn,
44
+ className: "text-red-600 focus:text-red-600",
45
+ children: [
46
+ /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.Trash2, { className: "mr-2 h-4 w-4" }),
47
+ "Delete Column"
48
+ ]
49
+ }
50
+ )
51
+ ] })
52
+ ] })
53
+ ] }),
54
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "p-0.5 space-y-2", children: hasTasks ? column.tasks.map((task) => /* @__PURE__ */ jsxRuntime.jsx(
55
+ taskCard.TaskCard,
56
+ {
57
+ task,
58
+ onClick: () => onEditTask(task.id)
59
+ },
60
+ task.id
61
+ )) : /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center justify-center py-1 md:py-8 text-center", children: [
62
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "rounded-full bg-muted p-4 mb-3 hidden md:block", children: /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.Plus, { className: "h-5 w-5 text-muted-foreground" }) }),
63
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1 mb-2 md:space-y-2 md:mb-4", children: [
64
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground", children: "No tasks yet" }),
65
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-muted-foreground", children: "Add a task to get started" })
66
+ ] }),
67
+ /* @__PURE__ */ jsxRuntime.jsxs(button.Button, { onClick: onAddTask, size: "sm", children: [
68
+ /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.Plus, { className: "mr-2 h-4 w-4" }),
69
+ "Add Task"
70
+ ] })
71
+ ] }) })
72
+ ] }, column.id);
73
+ }
74
+ const ColumnContent = React.memo(ColumnContentComponent);
75
+
76
+ exports.ColumnContent = ColumnContent;
@@ -0,0 +1,74 @@
1
+ "use client";
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { memo } from 'react';
4
+ import { GripVertical, MoreVertical, Pencil, Plus, Trash2 } from 'lucide-react';
5
+ import { Button } from '../../../../../../../ui/src/components/button.mjs';
6
+ import { Badge } from '../../../../../../../ui/src/components/badge.mjs';
7
+ import { KanbanColumn, KanbanColumnHandle } from '../../../../../../../ui/src/components/kanban.mjs';
8
+ import { DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuItem, DropdownMenuSeparator } from '../../../../../../../ui/src/components/dropdown-menu.mjs';
9
+ import { TaskCard } from './task-card.mjs';
10
+
11
+ function ColumnContentComponent({
12
+ column,
13
+ onAddTask,
14
+ onEditTask,
15
+ onEditColumn,
16
+ onDeleteColumn
17
+ }) {
18
+ const hasTasks = column.tasks && column.tasks.length > 0;
19
+ return /* @__PURE__ */ jsxs(KanbanColumn, { value: column.id, children: [
20
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center", children: [
21
+ /* @__PURE__ */ jsx(KanbanColumnHandle, { asChild: true, children: /* @__PURE__ */ jsx(Button, { variant: "ghost", size: "icon", children: /* @__PURE__ */ jsx(GripVertical, { className: "h-4 w-4" }) }) }),
22
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 flex-1", children: [
23
+ /* @__PURE__ */ jsx("span", { className: "font-bold text-lg line-clamp-1 flex-1 text-left", children: column.title }),
24
+ /* @__PURE__ */ jsx(Badge, { variant: "outline", className: "pointer-events-none rounded-sm", children: column.tasks?.length || 0 })
25
+ ] }),
26
+ /* @__PURE__ */ jsxs(DropdownMenu, { children: [
27
+ /* @__PURE__ */ jsx(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ jsx(Button, { variant: "ghost", size: "icon", children: /* @__PURE__ */ jsx(MoreVertical, { className: "h-4 w-4" }) }) }),
28
+ /* @__PURE__ */ jsxs(DropdownMenuContent, { align: "end", children: [
29
+ /* @__PURE__ */ jsxs(DropdownMenuItem, { onClick: onEditColumn, children: [
30
+ /* @__PURE__ */ jsx(Pencil, { className: "mr-2 h-4 w-4" }),
31
+ "Edit Column"
32
+ ] }),
33
+ /* @__PURE__ */ jsxs(DropdownMenuItem, { onClick: onAddTask, children: [
34
+ /* @__PURE__ */ jsx(Plus, { className: "mr-2 h-4 w-4" }),
35
+ "Add Task"
36
+ ] }),
37
+ /* @__PURE__ */ jsx(DropdownMenuSeparator, {}),
38
+ /* @__PURE__ */ jsxs(
39
+ DropdownMenuItem,
40
+ {
41
+ onClick: onDeleteColumn,
42
+ className: "text-red-600 focus:text-red-600",
43
+ children: [
44
+ /* @__PURE__ */ jsx(Trash2, { className: "mr-2 h-4 w-4" }),
45
+ "Delete Column"
46
+ ]
47
+ }
48
+ )
49
+ ] })
50
+ ] })
51
+ ] }),
52
+ /* @__PURE__ */ jsx("div", { className: "p-0.5 space-y-2", children: hasTasks ? column.tasks.map((task) => /* @__PURE__ */ jsx(
53
+ TaskCard,
54
+ {
55
+ task,
56
+ onClick: () => onEditTask(task.id)
57
+ },
58
+ task.id
59
+ )) : /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center justify-center py-1 md:py-8 text-center", children: [
60
+ /* @__PURE__ */ jsx("div", { className: "rounded-full bg-muted p-4 mb-3 hidden md:block", children: /* @__PURE__ */ jsx(Plus, { className: "h-5 w-5 text-muted-foreground" }) }),
61
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1 mb-2 md:space-y-2 md:mb-4", children: [
62
+ /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", children: "No tasks yet" }),
63
+ /* @__PURE__ */ jsx("p", { className: "text-xs text-muted-foreground", children: "Add a task to get started" })
64
+ ] }),
65
+ /* @__PURE__ */ jsxs(Button, { onClick: onAddTask, size: "sm", children: [
66
+ /* @__PURE__ */ jsx(Plus, { className: "mr-2 h-4 w-4" }),
67
+ "Add Task"
68
+ ] })
69
+ ] }) })
70
+ ] }, column.id);
71
+ }
72
+ const ColumnContent = memo(ColumnContentComponent);
73
+
74
+ export { ColumnContent };
@@ -0,0 +1,27 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ const jsxRuntime = require('react/jsx-runtime');
5
+ const LucideIcons = require('lucide-react');
6
+ const button = require('../../../../../../../ui/src/components/button.cjs');
7
+
8
+ function DefaultError({ error, reset }) {
9
+ return /* @__PURE__ */ jsxRuntime.jsxs(
10
+ "div",
11
+ {
12
+ className: "flex flex-col items-center justify-center py-12 text-center",
13
+ "data-testid": "error-placeholder",
14
+ children: [
15
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "rounded-full bg-destructive/10 p-6 mb-4", children: /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.AlertCircle, { className: "h-8 w-8 text-destructive" }) }),
16
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-lg font-semibold mb-2", children: "Something went wrong" }),
17
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground max-w-md mb-4", children: error?.message || "An unexpected error occurred. Please try again." }),
18
+ reset && /* @__PURE__ */ jsxRuntime.jsxs(button.Button, { onClick: reset, variant: "outline", children: [
19
+ /* @__PURE__ */ jsxRuntime.jsx(LucideIcons.RefreshCw, { className: "mr-2 h-4 w-4" }),
20
+ "Try Again"
21
+ ] })
22
+ ]
23
+ }
24
+ );
25
+ }
26
+
27
+ exports.DefaultError = DefaultError;
@@ -0,0 +1,25 @@
1
+ "use client";
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { AlertCircle, RefreshCw } from 'lucide-react';
4
+ import { Button } from '../../../../../../../ui/src/components/button.mjs';
5
+
6
+ function DefaultError({ error, reset }) {
7
+ return /* @__PURE__ */ jsxs(
8
+ "div",
9
+ {
10
+ className: "flex flex-col items-center justify-center py-12 text-center",
11
+ "data-testid": "error-placeholder",
12
+ children: [
13
+ /* @__PURE__ */ jsx("div", { className: "rounded-full bg-destructive/10 p-6 mb-4", children: /* @__PURE__ */ jsx(AlertCircle, { className: "h-8 w-8 text-destructive" }) }),
14
+ /* @__PURE__ */ jsx("h3", { className: "text-lg font-semibold mb-2", children: "Something went wrong" }),
15
+ /* @__PURE__ */ jsx("p", { className: "text-muted-foreground max-w-md mb-4", children: error?.message || "An unexpected error occurred. Please try again." }),
16
+ reset && /* @__PURE__ */ jsxs(Button, { onClick: reset, variant: "outline", children: [
17
+ /* @__PURE__ */ jsx(RefreshCw, { className: "mr-2 h-4 w-4" }),
18
+ "Try Again"
19
+ ] })
20
+ ]
21
+ }
22
+ );
23
+ }
24
+
25
+ export { DefaultError };
@@ -0,0 +1,32 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ const jsxRuntime = require('react/jsx-runtime');
5
+ const utils = require('../../../../../../../ui/src/lib/utils.cjs');
6
+
7
+ function EmptyState({
8
+ title,
9
+ description,
10
+ action,
11
+ icon,
12
+ className
13
+ }) {
14
+ return /* @__PURE__ */ jsxRuntime.jsxs(
15
+ "div",
16
+ {
17
+ className: utils.cn(
18
+ "flex flex-col items-center justify-center py-12 text-center",
19
+ className
20
+ ),
21
+ "data-testid": "empty-state",
22
+ children: [
23
+ icon && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "rounded-full bg-muted p-6 mb-4", children: icon }),
24
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-lg font-semibold mb-2", children: title }),
25
+ description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground max-w-md mb-4", children: description }),
26
+ action && /* @__PURE__ */ jsxRuntime.jsx("div", { children: action })
27
+ ]
28
+ }
29
+ );
30
+ }
31
+
32
+ exports.EmptyState = EmptyState;
@@ -0,0 +1,30 @@
1
+ "use client";
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { cn } from '../../../../../../../ui/src/lib/utils.mjs';
4
+
5
+ function EmptyState({
6
+ title,
7
+ description,
8
+ action,
9
+ icon,
10
+ className
11
+ }) {
12
+ return /* @__PURE__ */ jsxs(
13
+ "div",
14
+ {
15
+ className: cn(
16
+ "flex flex-col items-center justify-center py-12 text-center",
17
+ className
18
+ ),
19
+ "data-testid": "empty-state",
20
+ children: [
21
+ icon && /* @__PURE__ */ jsx("div", { className: "rounded-full bg-muted p-6 mb-4", children: icon }),
22
+ /* @__PURE__ */ jsx("h3", { className: "text-lg font-semibold mb-2", children: title }),
23
+ description && /* @__PURE__ */ jsx("p", { className: "text-muted-foreground max-w-md mb-4", children: description }),
24
+ action && /* @__PURE__ */ jsx("div", { children: action })
25
+ ]
26
+ }
27
+ );
28
+ }
29
+
30
+ export { EmptyState };
@@ -0,0 +1,78 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ const jsxRuntime = require('react/jsx-runtime');
5
+ const React = require('react');
6
+ const kanban = require('../../../../../../../ui/src/components/kanban.cjs');
7
+ const utils = require('../../../../../../../ui/src/lib/utils.cjs');
8
+ const columnContent = require('./column-content.cjs');
9
+
10
+ function KanbanBoardComponent({
11
+ columns,
12
+ kanbanState,
13
+ onKanbanChange,
14
+ onAddTask,
15
+ onEditTask,
16
+ onEditColumn,
17
+ onDeleteColumn
18
+ }) {
19
+ const orderedColumns = React.useMemo(() => {
20
+ const columnMap = new Map(columns.map((c) => [c.id, c]));
21
+ return Object.keys(kanbanState).map((columnId) => {
22
+ const column = columnMap.get(columnId);
23
+ if (!column) return null;
24
+ return {
25
+ ...column,
26
+ tasks: kanbanState[columnId] || []
27
+ };
28
+ }).filter(
29
+ (c) => c !== null
30
+ );
31
+ }, [columns, kanbanState]);
32
+ const mdClass = React.useMemo(() => {
33
+ const gridClassMap = {
34
+ 1: "md:grid-cols-1",
35
+ 2: "md:grid-cols-2",
36
+ 3: "md:grid-cols-3",
37
+ 4: "md:grid-cols-4",
38
+ 5: "md:grid-cols-5",
39
+ 6: "md:grid-cols-6"
40
+ };
41
+ return gridClassMap[orderedColumns.length] || "md:grid-cols-6";
42
+ }, [orderedColumns.length]);
43
+ return /* @__PURE__ */ jsxRuntime.jsxs(
44
+ kanban.Kanban,
45
+ {
46
+ orientation: "horizontal",
47
+ value: kanbanState,
48
+ onValueChange: onKanbanChange,
49
+ getItemValue: (item) => item.id,
50
+ children: [
51
+ /* @__PURE__ */ jsxRuntime.jsx(
52
+ kanban.KanbanBoard,
53
+ {
54
+ className: utils.cn(
55
+ "flex flex-col gap-4 md:auto-rows-fr md:grid-cols-1 md:grid min-h-[400px]",
56
+ mdClass
57
+ ),
58
+ children: orderedColumns.map((column) => /* @__PURE__ */ jsxRuntime.jsx(
59
+ columnContent.ColumnContent,
60
+ {
61
+ column,
62
+ onAddTask: () => onAddTask(column.id),
63
+ onEditTask: (taskId) => onEditTask(column.id, taskId),
64
+ onEditColumn: () => onEditColumn(column.id),
65
+ onDeleteColumn: () => onDeleteColumn(column.id)
66
+ },
67
+ column.id
68
+ ))
69
+ }
70
+ ),
71
+ /* @__PURE__ */ jsxRuntime.jsx(kanban.KanbanOverlay, { children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "size-full rounded-md bg-primary/10" }) })
72
+ ]
73
+ }
74
+ );
75
+ }
76
+ const KanbanBoard = React.memo(KanbanBoardComponent);
77
+
78
+ exports.KanbanBoard = KanbanBoard;
@@ -0,0 +1,76 @@
1
+ "use client";
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { memo, useMemo } from 'react';
4
+ import { Kanban as KanbanRoot, KanbanBoard as KanbanBoard$1, KanbanOverlay } from '../../../../../../../ui/src/components/kanban.mjs';
5
+ import { cn } from '../../../../../../../ui/src/lib/utils.mjs';
6
+ import { ColumnContent } from './column-content.mjs';
7
+
8
+ function KanbanBoardComponent({
9
+ columns,
10
+ kanbanState,
11
+ onKanbanChange,
12
+ onAddTask,
13
+ onEditTask,
14
+ onEditColumn,
15
+ onDeleteColumn
16
+ }) {
17
+ const orderedColumns = useMemo(() => {
18
+ const columnMap = new Map(columns.map((c) => [c.id, c]));
19
+ return Object.keys(kanbanState).map((columnId) => {
20
+ const column = columnMap.get(columnId);
21
+ if (!column) return null;
22
+ return {
23
+ ...column,
24
+ tasks: kanbanState[columnId] || []
25
+ };
26
+ }).filter(
27
+ (c) => c !== null
28
+ );
29
+ }, [columns, kanbanState]);
30
+ const mdClass = useMemo(() => {
31
+ const gridClassMap = {
32
+ 1: "md:grid-cols-1",
33
+ 2: "md:grid-cols-2",
34
+ 3: "md:grid-cols-3",
35
+ 4: "md:grid-cols-4",
36
+ 5: "md:grid-cols-5",
37
+ 6: "md:grid-cols-6"
38
+ };
39
+ return gridClassMap[orderedColumns.length] || "md:grid-cols-6";
40
+ }, [orderedColumns.length]);
41
+ return /* @__PURE__ */ jsxs(
42
+ KanbanRoot,
43
+ {
44
+ orientation: "horizontal",
45
+ value: kanbanState,
46
+ onValueChange: onKanbanChange,
47
+ getItemValue: (item) => item.id,
48
+ children: [
49
+ /* @__PURE__ */ jsx(
50
+ KanbanBoard$1,
51
+ {
52
+ className: cn(
53
+ "flex flex-col gap-4 md:auto-rows-fr md:grid-cols-1 md:grid min-h-[400px]",
54
+ mdClass
55
+ ),
56
+ children: orderedColumns.map((column) => /* @__PURE__ */ jsx(
57
+ ColumnContent,
58
+ {
59
+ column,
60
+ onAddTask: () => onAddTask(column.id),
61
+ onEditTask: (taskId) => onEditTask(column.id, taskId),
62
+ onEditColumn: () => onEditColumn(column.id),
63
+ onDeleteColumn: () => onDeleteColumn(column.id)
64
+ },
65
+ column.id
66
+ ))
67
+ }
68
+ ),
69
+ /* @__PURE__ */ jsx(KanbanOverlay, { children: /* @__PURE__ */ jsx("div", { className: "size-full rounded-md bg-primary/10" }) })
70
+ ]
71
+ }
72
+ );
73
+ }
74
+ const KanbanBoard = memo(KanbanBoardComponent);
75
+
76
+ export { KanbanBoard };
@@ -0,0 +1,15 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ const jsxRuntime = require('react/jsx-runtime');
5
+ const utils = require('../../../../../../../ui/src/lib/utils.cjs');
6
+
7
+ function PageWrapper({
8
+ children,
9
+ className,
10
+ ...props
11
+ }) {
12
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { className: utils.cn("container mx-auto py-8 px-4", className), ...props, children });
13
+ }
14
+
15
+ exports.PageWrapper = PageWrapper;
@@ -0,0 +1,13 @@
1
+ "use client";
2
+ import { jsx } from 'react/jsx-runtime';
3
+ import { cn } from '../../../../../../../ui/src/lib/utils.mjs';
4
+
5
+ function PageWrapper({
6
+ children,
7
+ className,
8
+ ...props
9
+ }) {
10
+ return /* @__PURE__ */ jsx("div", { className: cn("container mx-auto py-8 px-4", className), ...props, children });
11
+ }
12
+
13
+ export { PageWrapper };