@vibesdotdev/workboard 0.0.0-stage → 1.0.0-rc.1

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 (591) hide show
  1. package/LICENSE +18 -0
  2. package/README.md +31 -2
  3. package/dist/agent-actions.d.ts +19 -0
  4. package/dist/agent-actions.d.ts.map +1 -0
  5. package/dist/agent-actions.js +93 -0
  6. package/dist/agent-actions.js.map +1 -0
  7. package/dist/attention/headless-attention.host.d.ts +78 -0
  8. package/dist/attention/headless-attention.host.d.ts.map +1 -0
  9. package/dist/attention/headless-attention.host.js +42 -0
  10. package/dist/attention/headless-attention.host.js.map +1 -0
  11. package/dist/attention/index.d.ts +2 -0
  12. package/dist/attention/index.d.ts.map +1 -0
  13. package/dist/attention/index.js +2 -0
  14. package/dist/attention/index.js.map +1 -0
  15. package/dist/cli/marshal/components/index.d.ts +12 -0
  16. package/dist/cli/marshal/components/index.d.ts.map +1 -0
  17. package/dist/cli/marshal/components/index.js +12 -0
  18. package/dist/cli/marshal/components/index.js.map +1 -0
  19. package/dist/cli/marshal/components/marshal-progress.d.ts +52 -0
  20. package/dist/cli/marshal/components/marshal-progress.d.ts.map +1 -0
  21. package/dist/cli/marshal/components/marshal-progress.js +182 -0
  22. package/dist/cli/marshal/components/marshal-progress.js.map +1 -0
  23. package/dist/cli/marshal/components/marshal-prompt.d.ts +72 -0
  24. package/dist/cli/marshal/components/marshal-prompt.d.ts.map +1 -0
  25. package/dist/cli/marshal/components/marshal-prompt.js +256 -0
  26. package/dist/cli/marshal/components/marshal-prompt.js.map +1 -0
  27. package/dist/cli/marshal/components/marshal-widgets.d.ts +73 -0
  28. package/dist/cli/marshal/components/marshal-widgets.d.ts.map +1 -0
  29. package/dist/cli/marshal/components/marshal-widgets.js +283 -0
  30. package/dist/cli/marshal/components/marshal-widgets.js.map +1 -0
  31. package/dist/cli/marshal/index.d.ts +2 -0
  32. package/dist/cli/marshal/index.d.ts.map +1 -0
  33. package/dist/cli/marshal/index.js +2 -0
  34. package/dist/cli/marshal/index.js.map +1 -0
  35. package/dist/client/helper.d.ts +12 -0
  36. package/dist/client/helper.d.ts.map +1 -0
  37. package/dist/client/helper.js +13 -0
  38. package/dist/client/helper.js.map +1 -0
  39. package/dist/client/index.d.ts +3 -0
  40. package/dist/client/index.d.ts.map +1 -0
  41. package/dist/client/index.js +3 -0
  42. package/dist/client/index.js.map +1 -0
  43. package/dist/client/workboard-client.d.ts +283 -0
  44. package/dist/client/workboard-client.d.ts.map +1 -0
  45. package/dist/client/workboard-client.js +550 -0
  46. package/dist/client/workboard-client.js.map +1 -0
  47. package/dist/config/workboard.config.descriptor.d.ts +38 -0
  48. package/dist/config/workboard.config.descriptor.d.ts.map +1 -0
  49. package/dist/config/workboard.config.descriptor.js +30 -0
  50. package/dist/config/workboard.config.descriptor.js.map +1 -0
  51. package/dist/docs/workboard.docs.descriptor.d.ts +4 -0
  52. package/dist/docs/workboard.docs.descriptor.d.ts.map +1 -0
  53. package/dist/docs/workboard.docs.descriptor.js +85 -0
  54. package/dist/docs/workboard.docs.descriptor.js.map +1 -0
  55. package/dist/index.d.ts +12 -0
  56. package/dist/index.d.ts.map +1 -0
  57. package/dist/index.js +15 -0
  58. package/dist/index.js.map +1 -0
  59. package/dist/marshal/agent/descriptor.d.ts +66 -0
  60. package/dist/marshal/agent/descriptor.d.ts.map +1 -0
  61. package/dist/marshal/agent/descriptor.js +144 -0
  62. package/dist/marshal/agent/descriptor.js.map +1 -0
  63. package/dist/marshal/agent/index.d.ts +10 -0
  64. package/dist/marshal/agent/index.d.ts.map +1 -0
  65. package/dist/marshal/agent/index.js +10 -0
  66. package/dist/marshal/agent/index.js.map +1 -0
  67. package/dist/marshal/agent/marshal-agent.d.ts +42 -0
  68. package/dist/marshal/agent/marshal-agent.d.ts.map +1 -0
  69. package/dist/marshal/agent/marshal-agent.js +121 -0
  70. package/dist/marshal/agent/marshal-agent.js.map +1 -0
  71. package/dist/marshal/agent/marshal.agent.descriptor.d.ts +9 -0
  72. package/dist/marshal/agent/marshal.agent.descriptor.d.ts.map +1 -0
  73. package/dist/marshal/agent/marshal.agent.descriptor.js +9 -0
  74. package/dist/marshal/agent/marshal.agent.descriptor.js.map +1 -0
  75. package/dist/marshal/agent/profile.d.ts +16 -0
  76. package/dist/marshal/agent/profile.d.ts.map +1 -0
  77. package/dist/marshal/agent/profile.js +55 -0
  78. package/dist/marshal/agent/profile.js.map +1 -0
  79. package/dist/marshal/agent/prompts/cloud-system.prompt.descriptor.d.ts +113 -0
  80. package/dist/marshal/agent/prompts/cloud-system.prompt.descriptor.d.ts.map +1 -0
  81. package/dist/marshal/agent/prompts/cloud-system.prompt.descriptor.js +85 -0
  82. package/dist/marshal/agent/prompts/cloud-system.prompt.descriptor.js.map +1 -0
  83. package/dist/marshal/agent/prompts/index.d.ts +113 -0
  84. package/dist/marshal/agent/prompts/index.d.ts.map +1 -0
  85. package/dist/marshal/agent/prompts/index.js +16 -0
  86. package/dist/marshal/agent/prompts/index.js.map +1 -0
  87. package/dist/marshal/agent/prompts/personality.prompt.descriptor.d.ts +113 -0
  88. package/dist/marshal/agent/prompts/personality.prompt.descriptor.d.ts.map +1 -0
  89. package/dist/marshal/agent/prompts/personality.prompt.descriptor.js +34 -0
  90. package/dist/marshal/agent/prompts/personality.prompt.descriptor.js.map +1 -0
  91. package/dist/marshal/agent/prompts/setup-issue.prompt.descriptor.d.ts +113 -0
  92. package/dist/marshal/agent/prompts/setup-issue.prompt.descriptor.d.ts.map +1 -0
  93. package/dist/marshal/agent/prompts/setup-issue.prompt.descriptor.js +68 -0
  94. package/dist/marshal/agent/prompts/setup-issue.prompt.descriptor.js.map +1 -0
  95. package/dist/marshal/agent/prompts/setup-wizard.prompt.descriptor.d.ts +113 -0
  96. package/dist/marshal/agent/prompts/setup-wizard.prompt.descriptor.d.ts.map +1 -0
  97. package/dist/marshal/agent/prompts/setup-wizard.prompt.descriptor.js +38 -0
  98. package/dist/marshal/agent/prompts/setup-wizard.prompt.descriptor.js.map +1 -0
  99. package/dist/marshal/agent/prompts/surface.prompt.descriptor.d.ts +113 -0
  100. package/dist/marshal/agent/prompts/surface.prompt.descriptor.d.ts.map +1 -0
  101. package/dist/marshal/agent/prompts/surface.prompt.descriptor.js +39 -0
  102. package/dist/marshal/agent/prompts/surface.prompt.descriptor.js.map +1 -0
  103. package/dist/marshal/agent/prompts/system.prompt.descriptor.d.ts +113 -0
  104. package/dist/marshal/agent/prompts/system.prompt.descriptor.d.ts.map +1 -0
  105. package/dist/marshal/agent/prompts/system.prompt.descriptor.js +63 -0
  106. package/dist/marshal/agent/prompts/system.prompt.descriptor.js.map +1 -0
  107. package/dist/marshal/agent/system-prompt.d.ts +34 -0
  108. package/dist/marshal/agent/system-prompt.d.ts.map +1 -0
  109. package/dist/marshal/agent/system-prompt.js +130 -0
  110. package/dist/marshal/agent/system-prompt.js.map +1 -0
  111. package/dist/marshal/capabilities.d.ts +55 -0
  112. package/dist/marshal/capabilities.d.ts.map +1 -0
  113. package/dist/marshal/capabilities.js +146 -0
  114. package/dist/marshal/capabilities.js.map +1 -0
  115. package/dist/marshal/cli/fleet.marshal-presence.heartbeat.command.descriptor.d.ts +4 -0
  116. package/dist/marshal/cli/fleet.marshal-presence.heartbeat.command.descriptor.d.ts.map +1 -0
  117. package/dist/marshal/cli/fleet.marshal-presence.heartbeat.command.descriptor.js +18 -0
  118. package/dist/marshal/cli/fleet.marshal-presence.heartbeat.command.descriptor.js.map +1 -0
  119. package/dist/marshal/cli/fleet.marshal-presence.heartbeat.command.impl.consumer.d.ts +16 -0
  120. package/dist/marshal/cli/fleet.marshal-presence.heartbeat.command.impl.consumer.d.ts.map +1 -0
  121. package/dist/marshal/cli/fleet.marshal-presence.heartbeat.command.impl.consumer.js +39 -0
  122. package/dist/marshal/cli/fleet.marshal-presence.heartbeat.command.impl.consumer.js.map +1 -0
  123. package/dist/marshal/cli/plugin.d.ts +3 -0
  124. package/dist/marshal/cli/plugin.d.ts.map +1 -0
  125. package/dist/marshal/cli/plugin.js +9 -0
  126. package/dist/marshal/cli/plugin.js.map +1 -0
  127. package/dist/marshal/client/helper.d.ts +24 -0
  128. package/dist/marshal/client/helper.d.ts.map +1 -0
  129. package/dist/marshal/client/helper.js +36 -0
  130. package/dist/marshal/client/helper.js.map +1 -0
  131. package/dist/marshal/client/index.d.ts +7 -0
  132. package/dist/marshal/client/index.d.ts.map +1 -0
  133. package/dist/marshal/client/index.js +6 -0
  134. package/dist/marshal/client/index.js.map +1 -0
  135. package/dist/marshal/client/marshal-api-client.impl.d.ts +22 -0
  136. package/dist/marshal/client/marshal-api-client.impl.d.ts.map +1 -0
  137. package/dist/marshal/client/marshal-api-client.impl.js +47 -0
  138. package/dist/marshal/client/marshal-api-client.impl.js.map +1 -0
  139. package/dist/marshal/client/marshal-client.runtime.d.ts +124 -0
  140. package/dist/marshal/client/marshal-client.runtime.d.ts.map +1 -0
  141. package/dist/marshal/client/marshal-client.runtime.js +216 -0
  142. package/dist/marshal/client/marshal-client.runtime.js.map +1 -0
  143. package/dist/marshal/cloud.plugin.d.ts +2 -0
  144. package/dist/marshal/cloud.plugin.d.ts.map +1 -0
  145. package/dist/marshal/cloud.plugin.js +2 -0
  146. package/dist/marshal/cloud.plugin.js.map +1 -0
  147. package/dist/marshal/components/index.d.ts +8 -0
  148. package/dist/marshal/components/index.d.ts.map +1 -0
  149. package/dist/marshal/components/index.js +15 -0
  150. package/dist/marshal/components/index.js.map +1 -0
  151. package/dist/marshal/config/manifest.d.ts +8608 -0
  152. package/dist/marshal/config/manifest.d.ts.map +1 -0
  153. package/dist/marshal/config/manifest.js +115 -0
  154. package/dist/marshal/config/manifest.js.map +1 -0
  155. package/dist/marshal/consumer.d.ts +7 -0
  156. package/dist/marshal/consumer.d.ts.map +1 -0
  157. package/dist/marshal/consumer.js +9 -0
  158. package/dist/marshal/consumer.js.map +1 -0
  159. package/dist/marshal/consumer.plugin.d.ts +2 -0
  160. package/dist/marshal/consumer.plugin.d.ts.map +1 -0
  161. package/dist/marshal/consumer.plugin.js +2 -0
  162. package/dist/marshal/consumer.plugin.js.map +1 -0
  163. package/dist/marshal/context/agents-context-kind.d.ts +9 -0
  164. package/dist/marshal/context/agents-context-kind.d.ts.map +1 -0
  165. package/dist/marshal/context/agents-context-kind.js +17 -0
  166. package/dist/marshal/context/agents-context-kind.js.map +1 -0
  167. package/dist/marshal/context/marshal.context-provider.descriptor.d.ts +26 -0
  168. package/dist/marshal/context/marshal.context-provider.descriptor.d.ts.map +1 -0
  169. package/dist/marshal/context/marshal.context-provider.descriptor.js +10 -0
  170. package/dist/marshal/context/marshal.context-provider.descriptor.js.map +1 -0
  171. package/dist/marshal/context/marshal.context-provider.impl.d.ts +4 -0
  172. package/dist/marshal/context/marshal.context-provider.impl.d.ts.map +1 -0
  173. package/dist/marshal/context/marshal.context-provider.impl.js +42 -0
  174. package/dist/marshal/context/marshal.context-provider.impl.js.map +1 -0
  175. package/dist/marshal/index.d.ts +29 -0
  176. package/dist/marshal/index.d.ts.map +1 -0
  177. package/dist/marshal/index.js +34 -0
  178. package/dist/marshal/index.js.map +1 -0
  179. package/dist/marshal/marshal.api-client.descriptor.d.ts +9 -0
  180. package/dist/marshal/marshal.api-client.descriptor.d.ts.map +1 -0
  181. package/dist/marshal/marshal.api-client.descriptor.js +19 -0
  182. package/dist/marshal/marshal.api-client.descriptor.js.map +1 -0
  183. package/dist/marshal/marshal.consumer.plugin.d.ts +4 -0
  184. package/dist/marshal/marshal.consumer.plugin.d.ts.map +1 -0
  185. package/dist/marshal/marshal.consumer.plugin.js +18 -0
  186. package/dist/marshal/marshal.consumer.plugin.js.map +1 -0
  187. package/dist/marshal/marshal.plugin.d.ts +10 -0
  188. package/dist/marshal/marshal.plugin.d.ts.map +1 -0
  189. package/dist/marshal/marshal.plugin.js +55 -0
  190. package/dist/marshal/marshal.plugin.js.map +1 -0
  191. package/dist/marshal/marshal.runtime-client.descriptor.d.ts +9 -0
  192. package/dist/marshal/marshal.runtime-client.descriptor.d.ts.map +1 -0
  193. package/dist/marshal/marshal.runtime-client.descriptor.js +19 -0
  194. package/dist/marshal/marshal.runtime-client.descriptor.js.map +1 -0
  195. package/dist/marshal/plugin.d.ts +2 -0
  196. package/dist/marshal/plugin.d.ts.map +1 -0
  197. package/dist/marshal/plugin.js +2 -0
  198. package/dist/marshal/plugin.js.map +1 -0
  199. package/dist/marshal/presence/heartbeat.d.ts +64 -0
  200. package/dist/marshal/presence/heartbeat.d.ts.map +1 -0
  201. package/dist/marshal/presence/heartbeat.js +169 -0
  202. package/dist/marshal/presence/heartbeat.js.map +1 -0
  203. package/dist/marshal/presence/index.d.ts +2 -0
  204. package/dist/marshal/presence/index.d.ts.map +1 -0
  205. package/dist/marshal/presence/index.js +2 -0
  206. package/dist/marshal/presence/index.js.map +1 -0
  207. package/dist/marshal/schemas/agent.d.ts +27 -0
  208. package/dist/marshal/schemas/agent.d.ts.map +1 -0
  209. package/dist/marshal/schemas/agent.js +2 -0
  210. package/dist/marshal/schemas/agent.js.map +1 -0
  211. package/dist/marshal/schemas/baseline.d.ts +73 -0
  212. package/dist/marshal/schemas/baseline.d.ts.map +1 -0
  213. package/dist/marshal/schemas/baseline.js +28 -0
  214. package/dist/marshal/schemas/baseline.js.map +1 -0
  215. package/dist/marshal/schemas/client.d.ts +50 -0
  216. package/dist/marshal/schemas/client.d.ts.map +1 -0
  217. package/dist/marshal/schemas/client.js +27 -0
  218. package/dist/marshal/schemas/client.js.map +1 -0
  219. package/dist/marshal/schemas/common.d.ts +252 -0
  220. package/dist/marshal/schemas/common.d.ts.map +1 -0
  221. package/dist/marshal/schemas/common.js +119 -0
  222. package/dist/marshal/schemas/common.js.map +1 -0
  223. package/dist/marshal/schemas/components.d.ts +95 -0
  224. package/dist/marshal/schemas/components.d.ts.map +1 -0
  225. package/dist/marshal/schemas/components.js +10 -0
  226. package/dist/marshal/schemas/components.js.map +1 -0
  227. package/dist/marshal/schemas/config.d.ts +20 -0
  228. package/dist/marshal/schemas/config.d.ts.map +1 -0
  229. package/dist/marshal/schemas/config.js +11 -0
  230. package/dist/marshal/schemas/config.js.map +1 -0
  231. package/dist/marshal/schemas/index.d.ts +18 -0
  232. package/dist/marshal/schemas/index.d.ts.map +1 -0
  233. package/dist/marshal/schemas/index.js +11 -0
  234. package/dist/marshal/schemas/index.js.map +1 -0
  235. package/dist/marshal/schemas/interactive.d.ts +315 -0
  236. package/dist/marshal/schemas/interactive.d.ts.map +1 -0
  237. package/dist/marshal/schemas/interactive.js +201 -0
  238. package/dist/marshal/schemas/interactive.js.map +1 -0
  239. package/dist/marshal/schemas/presence.d.ts +29 -0
  240. package/dist/marshal/schemas/presence.d.ts.map +1 -0
  241. package/dist/marshal/schemas/presence.js +14 -0
  242. package/dist/marshal/schemas/presence.js.map +1 -0
  243. package/dist/marshal/schemas/progress.d.ts +100 -0
  244. package/dist/marshal/schemas/progress.d.ts.map +1 -0
  245. package/dist/marshal/schemas/progress.js +55 -0
  246. package/dist/marshal/schemas/progress.js.map +1 -0
  247. package/dist/marshal/schemas/server.d.ts +70 -0
  248. package/dist/marshal/schemas/server.d.ts.map +1 -0
  249. package/dist/marshal/schemas/server.js +39 -0
  250. package/dist/marshal/schemas/server.js.map +1 -0
  251. package/dist/marshal/schemas/setup.d.ts +78 -0
  252. package/dist/marshal/schemas/setup.d.ts.map +1 -0
  253. package/dist/marshal/schemas/setup.js +2 -0
  254. package/dist/marshal/schemas/setup.js.map +1 -0
  255. package/dist/marshal/schemas/tools.d.ts +124 -0
  256. package/dist/marshal/schemas/tools.d.ts.map +1 -0
  257. package/dist/marshal/schemas/tools.js +75 -0
  258. package/dist/marshal/schemas/tools.js.map +1 -0
  259. package/dist/marshal/schemas/types.d.ts +33 -0
  260. package/dist/marshal/schemas/types.d.ts.map +1 -0
  261. package/dist/marshal/schemas/types.js +2 -0
  262. package/dist/marshal/schemas/types.js.map +1 -0
  263. package/dist/marshal/schemas/worker.d.ts +8 -0
  264. package/dist/marshal/schemas/worker.d.ts.map +1 -0
  265. package/dist/marshal/schemas/worker.js +7 -0
  266. package/dist/marshal/schemas/worker.js.map +1 -0
  267. package/dist/marshal/setup/guided.d.ts +26 -0
  268. package/dist/marshal/setup/guided.d.ts.map +1 -0
  269. package/dist/marshal/setup/guided.js +83 -0
  270. package/dist/marshal/setup/guided.js.map +1 -0
  271. package/dist/marshal/setup/index.d.ts +12 -0
  272. package/dist/marshal/setup/index.d.ts.map +1 -0
  273. package/dist/marshal/setup/index.js +11 -0
  274. package/dist/marshal/setup/index.js.map +1 -0
  275. package/dist/marshal/setup/provider-runtime.d.ts +23 -0
  276. package/dist/marshal/setup/provider-runtime.d.ts.map +1 -0
  277. package/dist/marshal/setup/provider-runtime.detected-models.d.ts +239 -0
  278. package/dist/marshal/setup/provider-runtime.detected-models.d.ts.map +1 -0
  279. package/dist/marshal/setup/provider-runtime.detected-models.js +30 -0
  280. package/dist/marshal/setup/provider-runtime.detected-models.js.map +1 -0
  281. package/dist/marshal/setup/provider-runtime.js +115 -0
  282. package/dist/marshal/setup/provider-runtime.js.map +1 -0
  283. package/dist/marshal/setup/provider-runtime.models.d.ts +38 -0
  284. package/dist/marshal/setup/provider-runtime.models.d.ts.map +1 -0
  285. package/dist/marshal/setup/provider-runtime.models.js +38 -0
  286. package/dist/marshal/setup/provider-runtime.models.js.map +1 -0
  287. package/dist/marshal/setup/save-baseline.d.ts +12 -0
  288. package/dist/marshal/setup/save-baseline.d.ts.map +1 -0
  289. package/dist/marshal/setup/save-baseline.js +89 -0
  290. package/dist/marshal/setup/save-baseline.js.map +1 -0
  291. package/dist/marshal/setup/save-baseline.normalizers.d.ts +20 -0
  292. package/dist/marshal/setup/save-baseline.normalizers.d.ts.map +1 -0
  293. package/dist/marshal/setup/save-baseline.normalizers.js +72 -0
  294. package/dist/marshal/setup/save-baseline.normalizers.js.map +1 -0
  295. package/dist/marshal/setup/types.d.ts +17 -0
  296. package/dist/marshal/setup/types.d.ts.map +1 -0
  297. package/dist/marshal/setup/types.js +26 -0
  298. package/dist/marshal/setup/types.js.map +1 -0
  299. package/dist/marshal/tools/index.d.ts +9 -0
  300. package/dist/marshal/tools/index.d.ts.map +1 -0
  301. package/dist/marshal/tools/index.js +9 -0
  302. package/dist/marshal/tools/index.js.map +1 -0
  303. package/dist/marshal/tools/unified/descriptor.d.ts +130 -0
  304. package/dist/marshal/tools/unified/descriptor.d.ts.map +1 -0
  305. package/dist/marshal/tools/unified/descriptor.js +53 -0
  306. package/dist/marshal/tools/unified/descriptor.js.map +1 -0
  307. package/dist/marshal/tools/unified/index.d.ts +10 -0
  308. package/dist/marshal/tools/unified/index.d.ts.map +1 -0
  309. package/dist/marshal/tools/unified/index.js +9 -0
  310. package/dist/marshal/tools/unified/index.js.map +1 -0
  311. package/dist/marshal/tools/unified/marshal.execution.d.ts +12 -0
  312. package/dist/marshal/tools/unified/marshal.execution.d.ts.map +1 -0
  313. package/dist/marshal/tools/unified/marshal.execution.js +104 -0
  314. package/dist/marshal/tools/unified/marshal.execution.js.map +1 -0
  315. package/dist/marshal/tools/unified/marshal.impl.cloud.d.ts +13 -0
  316. package/dist/marshal/tools/unified/marshal.impl.cloud.d.ts.map +1 -0
  317. package/dist/marshal/tools/unified/marshal.impl.cloud.js +15 -0
  318. package/dist/marshal/tools/unified/marshal.impl.cloud.js.map +1 -0
  319. package/dist/marshal/tools/unified/marshal.impl.consumer.d.ts +13 -0
  320. package/dist/marshal/tools/unified/marshal.impl.consumer.d.ts.map +1 -0
  321. package/dist/marshal/tools/unified/marshal.impl.consumer.js +15 -0
  322. package/dist/marshal/tools/unified/marshal.impl.consumer.js.map +1 -0
  323. package/dist/marshal/tools/unified/marshal.unified.descriptor.d.ts +140 -0
  324. package/dist/marshal/tools/unified/marshal.unified.descriptor.d.ts.map +1 -0
  325. package/dist/marshal/tools/unified/marshal.unified.descriptor.js +57 -0
  326. package/dist/marshal/tools/unified/marshal.unified.descriptor.js.map +1 -0
  327. package/dist/marshal/tools/unified/schemas.d.ts +8 -0
  328. package/dist/marshal/tools/unified/schemas.d.ts.map +1 -0
  329. package/dist/marshal/tools/unified/schemas.js +7 -0
  330. package/dist/marshal/tools/unified/schemas.js.map +1 -0
  331. package/dist/marshal/types.d.ts +2 -0
  332. package/dist/marshal/types.d.ts.map +1 -0
  333. package/dist/marshal/types.js +2 -0
  334. package/dist/marshal/types.js.map +1 -0
  335. package/dist/marshal/worker/index.d.ts +6 -0
  336. package/dist/marshal/worker/index.d.ts.map +1 -0
  337. package/dist/marshal/worker/index.js +5 -0
  338. package/dist/marshal/worker/index.js.map +1 -0
  339. package/dist/marshal/worker/jobs/assistance-job.d.ts +34 -0
  340. package/dist/marshal/worker/jobs/assistance-job.d.ts.map +1 -0
  341. package/dist/marshal/worker/jobs/assistance-job.js +43 -0
  342. package/dist/marshal/worker/jobs/assistance-job.js.map +1 -0
  343. package/dist/marshal/worker/jobs/configure-job.d.ts +48 -0
  344. package/dist/marshal/worker/jobs/configure-job.d.ts.map +1 -0
  345. package/dist/marshal/worker/jobs/configure-job.js +52 -0
  346. package/dist/marshal/worker/jobs/configure-job.js.map +1 -0
  347. package/dist/marshal/worker/jobs/index.d.ts +7 -0
  348. package/dist/marshal/worker/jobs/index.d.ts.map +1 -0
  349. package/dist/marshal/worker/jobs/index.js +7 -0
  350. package/dist/marshal/worker/jobs/index.js.map +1 -0
  351. package/dist/marshal/worker/jobs/onboarding-progress-job.d.ts +47 -0
  352. package/dist/marshal/worker/jobs/onboarding-progress-job.d.ts.map +1 -0
  353. package/dist/marshal/worker/jobs/onboarding-progress-job.js +51 -0
  354. package/dist/marshal/worker/jobs/onboarding-progress-job.js.map +1 -0
  355. package/dist/marshal/worker/marshal.assistance.job.impl.d.ts +3 -0
  356. package/dist/marshal/worker/marshal.assistance.job.impl.d.ts.map +1 -0
  357. package/dist/marshal/worker/marshal.assistance.job.impl.js +3 -0
  358. package/dist/marshal/worker/marshal.assistance.job.impl.js.map +1 -0
  359. package/dist/marshal/worker/marshal.concierge.descriptor.d.ts +3 -0
  360. package/dist/marshal/worker/marshal.concierge.descriptor.d.ts.map +1 -0
  361. package/dist/marshal/worker/marshal.concierge.descriptor.js +14 -0
  362. package/dist/marshal/worker/marshal.concierge.descriptor.js.map +1 -0
  363. package/dist/marshal/worker/marshal.concierge.impl.consumer.d.ts +12 -0
  364. package/dist/marshal/worker/marshal.concierge.impl.consumer.d.ts.map +1 -0
  365. package/dist/marshal/worker/marshal.concierge.impl.consumer.js +23 -0
  366. package/dist/marshal/worker/marshal.concierge.impl.consumer.js.map +1 -0
  367. package/dist/marshal/worker/marshal.configure.job.impl.d.ts +3 -0
  368. package/dist/marshal/worker/marshal.configure.job.impl.d.ts.map +1 -0
  369. package/dist/marshal/worker/marshal.configure.job.impl.js +3 -0
  370. package/dist/marshal/worker/marshal.configure.job.impl.js.map +1 -0
  371. package/dist/marshal/worker/marshal.jobs.descriptor.d.ts +6 -0
  372. package/dist/marshal/worker/marshal.jobs.descriptor.d.ts.map +1 -0
  373. package/dist/marshal/worker/marshal.jobs.descriptor.js +50 -0
  374. package/dist/marshal/worker/marshal.jobs.descriptor.js.map +1 -0
  375. package/dist/marshal/worker/marshal.onboarding-progress.job.impl.d.ts +3 -0
  376. package/dist/marshal/worker/marshal.onboarding-progress.job.impl.d.ts.map +1 -0
  377. package/dist/marshal/worker/marshal.onboarding-progress.job.impl.js +3 -0
  378. package/dist/marshal/worker/marshal.onboarding-progress.job.impl.js.map +1 -0
  379. package/dist/plugin/agent-tools.d.ts +15 -0
  380. package/dist/plugin/agent-tools.d.ts.map +1 -0
  381. package/dist/plugin/agent-tools.js +27 -0
  382. package/dist/plugin/agent-tools.js.map +1 -0
  383. package/dist/records/index.d.ts +7 -0
  384. package/dist/records/index.d.ts.map +1 -0
  385. package/dist/records/index.js +7 -0
  386. package/dist/records/index.js.map +1 -0
  387. package/dist/records/lane.record.descriptor.d.ts +11 -0
  388. package/dist/records/lane.record.descriptor.d.ts.map +1 -0
  389. package/dist/records/lane.record.descriptor.js +47 -0
  390. package/dist/records/lane.record.descriptor.js.map +1 -0
  391. package/dist/records/note.record.descriptor.d.ts +10 -0
  392. package/dist/records/note.record.descriptor.d.ts.map +1 -0
  393. package/dist/records/note.record.descriptor.js +46 -0
  394. package/dist/records/note.record.descriptor.js.map +1 -0
  395. package/dist/records/notification.record.descriptor.d.ts +11 -0
  396. package/dist/records/notification.record.descriptor.d.ts.map +1 -0
  397. package/dist/records/notification.record.descriptor.js +50 -0
  398. package/dist/records/notification.record.descriptor.js.map +1 -0
  399. package/dist/records/request.record.descriptor.d.ts +10 -0
  400. package/dist/records/request.record.descriptor.d.ts.map +1 -0
  401. package/dist/records/request.record.descriptor.js +50 -0
  402. package/dist/records/request.record.descriptor.js.map +1 -0
  403. package/dist/records/task.record.descriptor.d.ts +10 -0
  404. package/dist/records/task.record.descriptor.d.ts.map +1 -0
  405. package/dist/records/task.record.descriptor.js +65 -0
  406. package/dist/records/task.record.descriptor.js.map +1 -0
  407. package/dist/records/watch.record.descriptor.d.ts +10 -0
  408. package/dist/records/watch.record.descriptor.d.ts.map +1 -0
  409. package/dist/records/watch.record.descriptor.js +48 -0
  410. package/dist/records/watch.record.descriptor.js.map +1 -0
  411. package/dist/schemas/agent-action.d.ts +31 -0
  412. package/dist/schemas/agent-action.d.ts.map +1 -0
  413. package/dist/schemas/agent-action.js +24 -0
  414. package/dist/schemas/agent-action.js.map +1 -0
  415. package/dist/schemas/card-projection.d.ts +193 -0
  416. package/dist/schemas/card-projection.d.ts.map +1 -0
  417. package/dist/schemas/card-projection.js +30 -0
  418. package/dist/schemas/card-projection.js.map +1 -0
  419. package/dist/schemas/contracts.d.ts +1117 -0
  420. package/dist/schemas/contracts.d.ts.map +1 -0
  421. package/dist/schemas/contracts.js +38 -0
  422. package/dist/schemas/contracts.js.map +1 -0
  423. package/dist/schemas/headless-attention.d.ts +189 -0
  424. package/dist/schemas/headless-attention.d.ts.map +1 -0
  425. package/dist/schemas/headless-attention.js +136 -0
  426. package/dist/schemas/headless-attention.js.map +1 -0
  427. package/dist/schemas/index.d.ts +15 -0
  428. package/dist/schemas/index.d.ts.map +1 -0
  429. package/dist/schemas/index.js +15 -0
  430. package/dist/schemas/index.js.map +1 -0
  431. package/dist/schemas/lane.d.ts +17 -0
  432. package/dist/schemas/lane.d.ts.map +1 -0
  433. package/dist/schemas/lane.js +14 -0
  434. package/dist/schemas/lane.js.map +1 -0
  435. package/dist/schemas/note.d.ts +14 -0
  436. package/dist/schemas/note.d.ts.map +1 -0
  437. package/dist/schemas/note.js +11 -0
  438. package/dist/schemas/note.js.map +1 -0
  439. package/dist/schemas/notification.d.ts +33 -0
  440. package/dist/schemas/notification.d.ts.map +1 -0
  441. package/dist/schemas/notification.js +19 -0
  442. package/dist/schemas/notification.js.map +1 -0
  443. package/dist/schemas/owner.d.ts +27 -0
  444. package/dist/schemas/owner.d.ts.map +1 -0
  445. package/dist/schemas/owner.js +18 -0
  446. package/dist/schemas/owner.js.map +1 -0
  447. package/dist/schemas/request.d.ts +69 -0
  448. package/dist/schemas/request.d.ts.map +1 -0
  449. package/dist/schemas/request.js +53 -0
  450. package/dist/schemas/request.js.map +1 -0
  451. package/dist/schemas/state.d.ts +170 -0
  452. package/dist/schemas/state.d.ts.map +1 -0
  453. package/dist/schemas/state.js +19 -0
  454. package/dist/schemas/state.js.map +1 -0
  455. package/dist/schemas/support-escalate.d.ts +54 -0
  456. package/dist/schemas/support-escalate.d.ts.map +1 -0
  457. package/dist/schemas/support-escalate.js +39 -0
  458. package/dist/schemas/support-escalate.js.map +1 -0
  459. package/dist/schemas/surface.d.ts +19 -0
  460. package/dist/schemas/surface.d.ts.map +1 -0
  461. package/dist/schemas/surface.js +8 -0
  462. package/dist/schemas/surface.js.map +1 -0
  463. package/dist/schemas/task.d.ts +70 -0
  464. package/dist/schemas/task.d.ts.map +1 -0
  465. package/dist/schemas/task.js +48 -0
  466. package/dist/schemas/task.js.map +1 -0
  467. package/dist/schemas/watch.d.ts +44 -0
  468. package/dist/schemas/watch.d.ts.map +1 -0
  469. package/dist/schemas/watch.js +19 -0
  470. package/dist/schemas/watch.js.map +1 -0
  471. package/dist/schemas/workboard-status-category.d.ts +35 -0
  472. package/dist/schemas/workboard-status-category.d.ts.map +1 -0
  473. package/dist/schemas/workboard-status-category.js +45 -0
  474. package/dist/schemas/workboard-status-category.js.map +1 -0
  475. package/dist/storage/owner-transforms.d.ts +228 -0
  476. package/dist/storage/owner-transforms.d.ts.map +1 -0
  477. package/dist/storage/owner-transforms.js +132 -0
  478. package/dist/storage/owner-transforms.js.map +1 -0
  479. package/dist/svelte/components/LaneBoard.svelte +250 -0
  480. package/dist/svelte/components/LaneBoard.svelte.d.ts +20 -0
  481. package/dist/svelte/components/LaneBoard.svelte.d.ts.map +1 -0
  482. package/dist/svelte/components/LaneBoardComposer.svelte +78 -0
  483. package/dist/svelte/components/LaneBoardComposer.svelte.d.ts +24 -0
  484. package/dist/svelte/components/LaneBoardComposer.svelte.d.ts.map +1 -0
  485. package/dist/svelte/components/LaneBoardFilters.svelte +34 -0
  486. package/dist/svelte/components/LaneBoardFilters.svelte.d.ts +12 -0
  487. package/dist/svelte/components/LaneBoardFilters.svelte.d.ts.map +1 -0
  488. package/dist/svelte/components/LaneBoardLane.svelte +46 -0
  489. package/dist/svelte/components/LaneBoardLane.svelte.d.ts +18 -0
  490. package/dist/svelte/components/LaneBoardLane.svelte.d.ts.map +1 -0
  491. package/dist/svelte/components/LaneBoardSummary.svelte +38 -0
  492. package/dist/svelte/components/LaneBoardSummary.svelte.d.ts +12 -0
  493. package/dist/svelte/components/LaneBoardSummary.svelte.d.ts.map +1 -0
  494. package/dist/svelte/components/LaneBoardTaskRow.svelte +158 -0
  495. package/dist/svelte/components/LaneBoardTaskRow.svelte.d.ts +31 -0
  496. package/dist/svelte/components/LaneBoardTaskRow.svelte.d.ts.map +1 -0
  497. package/dist/svelte/components/PriorityBadge.svelte +21 -0
  498. package/dist/svelte/components/PriorityBadge.svelte.d.ts +7 -0
  499. package/dist/svelte/components/PriorityBadge.svelte.d.ts.map +1 -0
  500. package/dist/svelte/components/RequestsQueue.svelte +613 -0
  501. package/dist/svelte/components/RequestsQueue.svelte.d.ts +21 -0
  502. package/dist/svelte/components/RequestsQueue.svelte.d.ts.map +1 -0
  503. package/dist/svelte/components/StatCard.svelte +27 -0
  504. package/dist/svelte/components/StatCard.svelte.d.ts +12 -0
  505. package/dist/svelte/components/StatCard.svelte.d.ts.map +1 -0
  506. package/dist/svelte/components/StatusBadge.svelte +25 -0
  507. package/dist/svelte/components/StatusBadge.svelte.d.ts +7 -0
  508. package/dist/svelte/components/StatusBadge.svelte.d.ts.map +1 -0
  509. package/dist/svelte/components/WorkboardBoard.svelte +467 -0
  510. package/dist/svelte/components/WorkboardBoard.svelte.d.ts +26 -0
  511. package/dist/svelte/components/WorkboardBoard.svelte.d.ts.map +1 -0
  512. package/dist/svelte/index.d.ts +22 -0
  513. package/dist/svelte/index.d.ts.map +1 -0
  514. package/dist/svelte/index.js +24 -0
  515. package/dist/svelte/lane-board-client.d.ts +3 -0
  516. package/dist/svelte/lane-board-client.d.ts.map +1 -0
  517. package/dist/svelte/lane-board-client.js +2 -0
  518. package/dist/svelte/lane-board.d.ts +120 -0
  519. package/dist/svelte/lane-board.d.ts.map +1 -0
  520. package/dist/svelte/lane-board.js +221 -0
  521. package/dist/svelte/rest-workboard-client.d.ts +235 -0
  522. package/dist/svelte/rest-workboard-client.d.ts.map +1 -0
  523. package/dist/svelte/rest-workboard-client.js +52 -0
  524. package/dist/svelte/styles.css +10 -0
  525. package/dist/svelte/tool-widgets/MarshalToolCard.svelte +67 -0
  526. package/dist/svelte/tool-widgets/MarshalToolCard.svelte.d.ts +5 -0
  527. package/dist/svelte/tool-widgets/MarshalToolCard.svelte.d.ts.map +1 -0
  528. package/dist/svelte/tool-widgets/SupportEscalateToolCard.svelte +42 -0
  529. package/dist/svelte/tool-widgets/SupportEscalateToolCard.svelte.d.ts +5 -0
  530. package/dist/svelte/tool-widgets/SupportEscalateToolCard.svelte.d.ts.map +1 -0
  531. package/dist/svelte/tool-widgets/index.d.ts +7 -0
  532. package/dist/svelte/tool-widgets/index.d.ts.map +1 -0
  533. package/dist/svelte/tool-widgets/index.js +6 -0
  534. package/dist/svelte/types.d.ts +24 -0
  535. package/dist/svelte/types.d.ts.map +1 -0
  536. package/dist/svelte/types.js +1 -0
  537. package/dist/svelte/workboard-svelte.plugin.d.ts +10 -0
  538. package/dist/svelte/workboard-svelte.plugin.d.ts.map +1 -0
  539. package/dist/svelte/workboard-svelte.plugin.js +31 -0
  540. package/dist/svelte/workboard-utils.d.ts +33 -0
  541. package/dist/svelte/workboard-utils.d.ts.map +1 -0
  542. package/dist/svelte/workboard-utils.js +85 -0
  543. package/dist/tools/card-projections.d.ts +7 -0
  544. package/dist/tools/card-projections.d.ts.map +1 -0
  545. package/dist/tools/card-projections.js +64 -0
  546. package/dist/tools/card-projections.js.map +1 -0
  547. package/dist/tools/support-escalate/schemas.d.ts +2 -0
  548. package/dist/tools/support-escalate/schemas.d.ts.map +1 -0
  549. package/dist/tools/support-escalate/schemas.js +2 -0
  550. package/dist/tools/support-escalate/schemas.js.map +1 -0
  551. package/dist/tools/support-escalate/support-escalate.descriptor.d.ts +49 -0
  552. package/dist/tools/support-escalate/support-escalate.descriptor.d.ts.map +1 -0
  553. package/dist/tools/support-escalate/support-escalate.descriptor.js +42 -0
  554. package/dist/tools/support-escalate/support-escalate.descriptor.js.map +1 -0
  555. package/dist/tools/support-escalate/support-escalate.impl.cloud.d.ts +17 -0
  556. package/dist/tools/support-escalate/support-escalate.impl.cloud.d.ts.map +1 -0
  557. package/dist/tools/support-escalate/support-escalate.impl.cloud.js +63 -0
  558. package/dist/tools/support-escalate/support-escalate.impl.cloud.js.map +1 -0
  559. package/dist/tui/index.d.ts +2 -0
  560. package/dist/tui/index.d.ts.map +1 -0
  561. package/dist/tui/index.js +2 -0
  562. package/dist/tui/index.js.map +1 -0
  563. package/dist/tui/tool-widgets/MarshalToolWidget.impl.consumer.d.ts +4 -0
  564. package/dist/tui/tool-widgets/MarshalToolWidget.impl.consumer.d.ts.map +1 -0
  565. package/dist/tui/tool-widgets/MarshalToolWidget.impl.consumer.js +17 -0
  566. package/dist/tui/tool-widgets/MarshalToolWidget.impl.consumer.js.map +1 -0
  567. package/dist/tui/tool-widgets/SupportEscalateToolWidget.impl.consumer.d.ts +4 -0
  568. package/dist/tui/tool-widgets/SupportEscalateToolWidget.impl.consumer.d.ts.map +1 -0
  569. package/dist/tui/tool-widgets/SupportEscalateToolWidget.impl.consumer.js +11 -0
  570. package/dist/tui/tool-widgets/SupportEscalateToolWidget.impl.consumer.js.map +1 -0
  571. package/dist/tui/workboard-tui.plugin.d.ts +7 -0
  572. package/dist/tui/workboard-tui.plugin.d.ts.map +1 -0
  573. package/dist/tui/workboard-tui.plugin.js +32 -0
  574. package/dist/tui/workboard-tui.plugin.js.map +1 -0
  575. package/dist/types.d.ts +2 -0
  576. package/dist/types.d.ts.map +1 -0
  577. package/dist/types.js +2 -0
  578. package/dist/types.js.map +1 -0
  579. package/dist/utils/exec.d.ts +35 -0
  580. package/dist/utils/exec.d.ts.map +1 -0
  581. package/dist/utils/exec.js +31 -0
  582. package/dist/utils/exec.js.map +1 -0
  583. package/dist/workboard.plugin.d.ts +8 -0
  584. package/dist/workboard.plugin.d.ts.map +1 -0
  585. package/dist/workboard.plugin.js +46 -0
  586. package/dist/workboard.plugin.js.map +1 -0
  587. package/dist/workboard.runtime-client.descriptor.d.ts +4 -0
  588. package/dist/workboard.runtime-client.descriptor.d.ts.map +1 -0
  589. package/dist/workboard.runtime-client.descriptor.js +13 -0
  590. package/dist/workboard.runtime-client.descriptor.js.map +1 -0
  591. package/package.json +409 -4
@@ -0,0 +1,120 @@
1
+ /**
2
+ * Pure helpers for the HQ lane board — the glanceable projection of the
3
+ * workboard's task rows grouped by lane.
4
+ *
5
+ * Zero Svelte/SvelteKit/runtime imports on purpose: this module is shared by
6
+ * the package-owned browser components, the
7
+ * tracking projection (lane id on the authority row's metadata), the lane
8
+ * query/route, and the page loader — so the ONE definition of "what a lane id
9
+ * looks like", "which lane a task sits in", and "what a task's glance line
10
+ * says" holds on every door and is unit-tested here.
11
+ */
12
+ import type { TaskNote, WorkboardLane, WorkboardTask } from '../types.ts';
13
+ /** Group id for tasks that carry no lane. Sorts last; never a real lane id. */
14
+ export declare const NO_LANE_ID = "";
15
+ /**
16
+ * Canonical lane id: trimmed, lower-cased, whitespace runs → `-`. Mirrors the
17
+ * lane row's primary-key normalization so "Appearance SSR" typed into a form,
18
+ * `appearance-ssr` sent by an agent, and the stored lane row all agree.
19
+ */
20
+ export declare function normalizeLaneId(raw: string | null | undefined): string;
21
+ export interface StatusCounts {
22
+ pending: number;
23
+ in_progress: number;
24
+ blocked: number;
25
+ completed: number;
26
+ cancelled: number;
27
+ /** pending + in_progress + blocked — the work still live on the board. */
28
+ open: number;
29
+ total: number;
30
+ }
31
+ export declare function countByStatus(tasks: readonly WorkboardTask[]): StatusCounts;
32
+ /**
33
+ * Blocked → in progress → pending → done; then priority; then most recently
34
+ * updated first (oversight reads "what moved last", not "what was created
35
+ * last" — the board's creation-order comparator lives in the package).
36
+ */
37
+ export declare function compareTasksForGlance(a: WorkboardTask, b: WorkboardTask): number;
38
+ export interface LaneGroup {
39
+ /** Normalized lane id; `NO_LANE_ID` for the trailing "no lane" group. */
40
+ id: string;
41
+ label: string;
42
+ description: string;
43
+ /** Lane row `color` (an emoji or a CSS color); '' when unregistered. */
44
+ color: string;
45
+ /** True when a lane row exists; false for lanes only seen on tasks. */
46
+ registered: boolean;
47
+ tasks: WorkboardTask[];
48
+ counts: StatusCounts;
49
+ }
50
+ /**
51
+ * Group tasks by lane for the board:
52
+ * 1. every registered lane (sorted by id), INCLUDING empty ones — an empty
53
+ * lane is a fact worth seeing ("lane exists, nothing assigned");
54
+ * 2. lanes that exist only on tasks (an agent filed into a lane nobody
55
+ * registered yet) — shown, flagged `registered: false`, never hidden;
56
+ * 3. the "no lane" group last, only when it has tasks.
57
+ */
58
+ export declare function groupTasksByLane(tasks: readonly WorkboardTask[], lanes: readonly WorkboardLane[]): LaneGroup[];
59
+ /** Lane ids a task can be moved into: registered + already-seen, never ''. */
60
+ export declare function laneOptions(groups: readonly LaneGroup[]): string[];
61
+ /** Most recent note by `at`; falls back to array order for unparsable dates. */
62
+ export declare function latestNote(task: Pick<WorkboardTask, 'notes'>): TaskNote | null;
63
+ export type GlanceKind = 'blocker' | 'next' | 'none';
64
+ export interface GlanceLine {
65
+ kind: GlanceKind;
66
+ /** Note text; '' when a blocked task has no note yet (the UI says so). */
67
+ text: string;
68
+ by: string | null;
69
+ at: string | null;
70
+ }
71
+ /**
72
+ * The one line under a task that answers "why is this stuck / what happens
73
+ * next": the latest note. A blocked task's latest note is its blocker; an open
74
+ * task's latest note is its next action; finished work has no glance line.
75
+ * This reuses the workboard's own note primitive — an agent that can add a
76
+ * note can keep the board glanceable without any new field.
77
+ */
78
+ export declare function glanceLine(task: WorkboardTask): GlanceLine;
79
+ export type AgentLabel = {
80
+ name: string;
81
+ status?: string | null;
82
+ };
83
+ /** id → label (string) or `{ name, status }`; from `agentsState` in HQ. */
84
+ export type AgentLabelMap = Record<string, AgentLabel | string>;
85
+ /** The assignment first, then the producing agent, else '' (unassigned). */
86
+ export declare function ownerKey(task: Pick<WorkboardTask, 'assigned_to' | 'agentId'>): string;
87
+ export declare function ownerLabel(task: Pick<WorkboardTask, 'assigned_to' | 'agentId'>, agents?: AgentLabelMap): string;
88
+ /** Agent liveness for the owner chip when the owner is a known agent. */
89
+ export declare function ownerStatus(task: Pick<WorkboardTask, 'assigned_to' | 'agentId'>, agents?: AgentLabelMap): string | null;
90
+ export interface OwnerOption {
91
+ id: string;
92
+ label: string;
93
+ count: number;
94
+ }
95
+ export declare function distinctOwners(tasks: readonly WorkboardTask[], agents?: AgentLabelMap): OwnerOption[];
96
+ export type StatusFilter = 'all' | 'open' | 'in_progress' | 'blocked' | 'pending' | 'completed';
97
+ export declare const STATUS_FILTERS: ReadonlyArray<{
98
+ value: StatusFilter;
99
+ label: string;
100
+ }>;
101
+ /** Owner-filter sentinel for "tasks nobody owns" (a real owner id is never ''). */
102
+ export declare const UNASSIGNED_OWNER_FILTER = "__unassigned__";
103
+ export declare function matchesStatusFilter(task: WorkboardTask, filter: StatusFilter): boolean;
104
+ export interface TaskFilter {
105
+ /** Narrow to one agent (by provenance or assignment); null = all agents. */
106
+ agentId?: string | null;
107
+ status?: StatusFilter;
108
+ /** '' = every owner; `UNASSIGNED_OWNER_FILTER` = no owner; else an owner id. */
109
+ owner?: string;
110
+ }
111
+ /** Narrows only — never widens beyond the rows given. */
112
+ export declare function filterTasks(tasks: readonly WorkboardTask[], filter: TaskFilter): WorkboardTask[];
113
+ export declare const STALE_AFTER_MS: number;
114
+ /** Live work (in progress or blocked) that nobody has touched in a day. */
115
+ export declare function isStale(task: WorkboardTask, now?: number): boolean;
116
+ export interface BoardSummary extends StatusCounts {
117
+ stale: number;
118
+ }
119
+ export declare function summarize(tasks: readonly WorkboardTask[], now?: number): BoardSummary;
120
+ //# sourceMappingURL=lane-board.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lane-board.d.ts","sourceRoot":"","sources":["../../src/svelte/lane-board.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,221 @@
1
+ import { WorkboardAgentLabelSchema } from "../schemas/surface.js";
2
+ /** Group id for tasks that carry no lane. Sorts last; never a real lane id. */
3
+ export const NO_LANE_ID = '';
4
+ /**
5
+ * Canonical lane id: trimmed, lower-cased, whitespace runs → `-`. Mirrors the
6
+ * lane row's primary-key normalization so "Appearance SSR" typed into a form,
7
+ * `appearance-ssr` sent by an agent, and the stored lane row all agree.
8
+ */
9
+ export function normalizeLaneId(raw) {
10
+ return (raw ?? '').trim().toLowerCase().replace(/\s+/g, '-');
11
+ }
12
+ export function countByStatus(tasks) {
13
+ const counts = {
14
+ pending: 0,
15
+ in_progress: 0,
16
+ blocked: 0,
17
+ completed: 0,
18
+ cancelled: 0,
19
+ open: 0,
20
+ total: tasks.length
21
+ };
22
+ for (const task of tasks) {
23
+ if (task.status in counts)
24
+ counts[task.status] += 1;
25
+ }
26
+ counts.open = counts.pending + counts.in_progress + counts.blocked;
27
+ return counts;
28
+ }
29
+ // ── Ordering ──
30
+ /** Glance order inside a lane: what needs a human first. */
31
+ const STATUS_GLANCE_RANK = {
32
+ blocked: 0,
33
+ in_progress: 1,
34
+ pending: 2,
35
+ completed: 3,
36
+ cancelled: 4
37
+ };
38
+ const PRIORITY_RANK = { critical: 0, high: 1, medium: 2, low: 3 };
39
+ function epoch(iso) {
40
+ const t = iso ? new Date(iso).getTime() : Number.NaN;
41
+ return Number.isFinite(t) ? t : 0;
42
+ }
43
+ /**
44
+ * Blocked → in progress → pending → done; then priority; then most recently
45
+ * updated first (oversight reads "what moved last", not "what was created
46
+ * last" — the board's creation-order comparator lives in the package).
47
+ */
48
+ export function compareTasksForGlance(a, b) {
49
+ const status = (STATUS_GLANCE_RANK[a.status] ?? 9) - (STATUS_GLANCE_RANK[b.status] ?? 9);
50
+ if (status !== 0)
51
+ return status;
52
+ const priority = (PRIORITY_RANK[a.priority] ?? 9) - (PRIORITY_RANK[b.priority] ?? 9);
53
+ if (priority !== 0)
54
+ return priority;
55
+ return epoch(b.updated_at) - epoch(a.updated_at);
56
+ }
57
+ function laneGroup(id, lane, tasks) {
58
+ const sorted = [...tasks].sort(compareTasksForGlance);
59
+ return {
60
+ id,
61
+ label: id === NO_LANE_ID ? 'No lane' : id,
62
+ description: lane?.description ?? '',
63
+ color: lane?.color ?? '',
64
+ registered: lane !== null,
65
+ tasks: sorted,
66
+ counts: countByStatus(sorted)
67
+ };
68
+ }
69
+ /**
70
+ * Group tasks by lane for the board:
71
+ * 1. every registered lane (sorted by id), INCLUDING empty ones — an empty
72
+ * lane is a fact worth seeing ("lane exists, nothing assigned");
73
+ * 2. lanes that exist only on tasks (an agent filed into a lane nobody
74
+ * registered yet) — shown, flagged `registered: false`, never hidden;
75
+ * 3. the "no lane" group last, only when it has tasks.
76
+ */
77
+ export function groupTasksByLane(tasks, lanes) {
78
+ const byLane = new Map();
79
+ for (const task of tasks) {
80
+ const id = normalizeLaneId(task.lane);
81
+ const bucket = byLane.get(id);
82
+ if (bucket)
83
+ bucket.push(task);
84
+ else
85
+ byLane.set(id, [task]);
86
+ }
87
+ const groups = [];
88
+ const seen = new Set();
89
+ const registered = [...lanes].sort((a, b) => a.id.localeCompare(b.id));
90
+ for (const lane of registered) {
91
+ const id = normalizeLaneId(lane.id);
92
+ if (!id || seen.has(id))
93
+ continue;
94
+ seen.add(id);
95
+ groups.push(laneGroup(id, lane, byLane.get(id) ?? []));
96
+ }
97
+ const unregistered = [...byLane.keys()].filter((id) => id !== NO_LANE_ID && !seen.has(id)).sort();
98
+ for (const id of unregistered)
99
+ groups.push(laneGroup(id, null, byLane.get(id) ?? []));
100
+ const none = byLane.get(NO_LANE_ID);
101
+ if (none && none.length > 0)
102
+ groups.push(laneGroup(NO_LANE_ID, null, none));
103
+ return groups;
104
+ }
105
+ /** Lane ids a task can be moved into: registered + already-seen, never ''. */
106
+ export function laneOptions(groups) {
107
+ return groups.map((group) => group.id).filter((id) => id !== NO_LANE_ID);
108
+ }
109
+ // ── Glance line (blocker / next action) ──
110
+ /** Most recent note by `at`; falls back to array order for unparsable dates. */
111
+ export function latestNote(task) {
112
+ let best = null;
113
+ let bestAt = Number.NEGATIVE_INFINITY;
114
+ for (const note of task.notes ?? []) {
115
+ const parsed = new Date(note.at).getTime();
116
+ const at = Number.isFinite(parsed) ? parsed : Number.NEGATIVE_INFINITY;
117
+ if (best === null || at >= bestAt) {
118
+ best = note;
119
+ bestAt = at;
120
+ }
121
+ }
122
+ return best;
123
+ }
124
+ /**
125
+ * The one line under a task that answers "why is this stuck / what happens
126
+ * next": the latest note. A blocked task's latest note is its blocker; an open
127
+ * task's latest note is its next action; finished work has no glance line.
128
+ * This reuses the workboard's own note primitive — an agent that can add a
129
+ * note can keep the board glanceable without any new field.
130
+ */
131
+ export function glanceLine(task) {
132
+ const note = latestNote(task);
133
+ if (task.status === 'blocked') {
134
+ return { kind: 'blocker', text: note?.text ?? '', by: note?.by ?? null, at: note?.at ?? null };
135
+ }
136
+ if (note && task.status !== 'completed' && task.status !== 'cancelled') {
137
+ return { kind: 'next', text: note.text, by: note.by, at: note.at };
138
+ }
139
+ return { kind: 'none', text: '', by: null, at: null };
140
+ }
141
+ /** The assignment first, then the producing agent, else '' (unassigned). */
142
+ export function ownerKey(task) {
143
+ return task.assigned_to || task.agentId || '';
144
+ }
145
+ export function ownerLabel(task, agents = {}) {
146
+ const key = ownerKey(task);
147
+ if (!key)
148
+ return 'Unassigned';
149
+ const entry = agents[key];
150
+ if (!entry)
151
+ return key;
152
+ return WorkboardAgentLabelSchema.parse(entry).name || key;
153
+ }
154
+ /** Agent liveness for the owner chip when the owner is a known agent. */
155
+ export function ownerStatus(task, agents = {}) {
156
+ const entry = agents[ownerKey(task)];
157
+ return entry ? WorkboardAgentLabelSchema.parse(entry).status ?? null : null;
158
+ }
159
+ export function distinctOwners(tasks, agents = {}) {
160
+ const byId = new Map();
161
+ for (const task of tasks) {
162
+ const id = ownerKey(task);
163
+ if (!id)
164
+ continue;
165
+ const existing = byId.get(id);
166
+ if (existing)
167
+ existing.count += 1;
168
+ else
169
+ byId.set(id, { id, label: ownerLabel(task, agents), count: 1 });
170
+ }
171
+ return [...byId.values()].sort((a, b) => a.label.localeCompare(b.label));
172
+ }
173
+ export const STATUS_FILTERS = [
174
+ { value: 'open', label: 'Open' },
175
+ { value: 'in_progress', label: 'In progress' },
176
+ { value: 'blocked', label: 'Blocked' },
177
+ { value: 'pending', label: 'Pending' },
178
+ { value: 'completed', label: 'Done' },
179
+ { value: 'all', label: 'All' }
180
+ ];
181
+ /** Owner-filter sentinel for "tasks nobody owns" (a real owner id is never ''). */
182
+ export const UNASSIGNED_OWNER_FILTER = '__unassigned__';
183
+ export function matchesStatusFilter(task, filter) {
184
+ if (filter === 'all')
185
+ return true;
186
+ if (filter === 'open')
187
+ return task.status !== 'completed' && task.status !== 'cancelled';
188
+ return task.status === filter;
189
+ }
190
+ /** Narrows only — never widens beyond the rows given. */
191
+ export function filterTasks(tasks, filter) {
192
+ const { agentId = null, status = 'all', owner = '' } = filter;
193
+ return tasks.filter((task) => {
194
+ if (agentId != null && task.agentId !== agentId && task.assigned_to !== agentId)
195
+ return false;
196
+ if (!matchesStatusFilter(task, status))
197
+ return false;
198
+ if (owner === UNASSIGNED_OWNER_FILTER)
199
+ return ownerKey(task) === '';
200
+ if (owner && ownerKey(task) !== owner)
201
+ return false;
202
+ return true;
203
+ });
204
+ }
205
+ // ── Staleness / summary ──
206
+ export const STALE_AFTER_MS = 24 * 60 * 60 * 1000;
207
+ /** Live work (in progress or blocked) that nobody has touched in a day. */
208
+ export function isStale(task, now = Date.now()) {
209
+ if (task.status !== 'in_progress' && task.status !== 'blocked')
210
+ return false;
211
+ const updated = new Date(task.updated_at).getTime();
212
+ if (!Number.isFinite(updated))
213
+ return false;
214
+ return now - updated > STALE_AFTER_MS;
215
+ }
216
+ export function summarize(tasks, now = Date.now()) {
217
+ return {
218
+ ...countByStatus(tasks),
219
+ stale: tasks.filter((task) => isStale(task, now)).length
220
+ };
221
+ }
@@ -0,0 +1,235 @@
1
+ import { type WorkboardTaskDraft, type WorkboardTaskPatch, type WorkboardTaskFilter, type WorkboardRequestDraft, type WorkboardRequestReview, type WorkboardRequestFilter, type WorkboardLaneDraft } from '../schemas/index.ts';
2
+ export interface RestWorkboardClientOptions {
3
+ basePath?: string;
4
+ fetchImpl?: typeof fetch;
5
+ }
6
+ export declare function createRestWorkboardClient(options?: RestWorkboardClientOptions): {
7
+ tasks: {
8
+ list: (filter?: WorkboardTaskFilter) => Promise<{
9
+ id: string;
10
+ title: string;
11
+ lane: string;
12
+ status: "cancelled" | "completed" | "pending" | "blocked" | "in_progress";
13
+ priority: "high" | "medium" | "low" | "critical";
14
+ assigned_to: string;
15
+ notes: {
16
+ at: string;
17
+ by: string;
18
+ text: string;
19
+ }[];
20
+ created_at: string;
21
+ updated_at: string;
22
+ description?: string | undefined;
23
+ response?: string | undefined;
24
+ note?: string | undefined;
25
+ completed_at?: string | undefined;
26
+ ownerType?: "user" | "organization" | "system" | null | undefined;
27
+ ownerId?: string | null | undefined;
28
+ agentId?: string | null | undefined;
29
+ sourceEventId?: string | null | undefined;
30
+ links?: {
31
+ kind: string;
32
+ id: string;
33
+ source: string;
34
+ role: string;
35
+ }[] | undefined;
36
+ displayId?: string | undefined;
37
+ authorityUrl?: string | undefined;
38
+ }[]>;
39
+ add: (data: WorkboardTaskDraft) => Promise<{
40
+ id: string;
41
+ title: string;
42
+ lane: string;
43
+ status: "cancelled" | "completed" | "pending" | "blocked" | "in_progress";
44
+ priority: "high" | "medium" | "low" | "critical";
45
+ assigned_to: string;
46
+ notes: {
47
+ at: string;
48
+ by: string;
49
+ text: string;
50
+ }[];
51
+ created_at: string;
52
+ updated_at: string;
53
+ description?: string | undefined;
54
+ response?: string | undefined;
55
+ note?: string | undefined;
56
+ completed_at?: string | undefined;
57
+ ownerType?: "user" | "organization" | "system" | null | undefined;
58
+ ownerId?: string | null | undefined;
59
+ agentId?: string | null | undefined;
60
+ sourceEventId?: string | null | undefined;
61
+ links?: {
62
+ kind: string;
63
+ id: string;
64
+ source: string;
65
+ role: string;
66
+ }[] | undefined;
67
+ displayId?: string | undefined;
68
+ authorityUrl?: string | undefined;
69
+ }>;
70
+ update: (id: string, patch: WorkboardTaskPatch) => Promise<{
71
+ id: string;
72
+ title: string;
73
+ lane: string;
74
+ status: "cancelled" | "completed" | "pending" | "blocked" | "in_progress";
75
+ priority: "high" | "medium" | "low" | "critical";
76
+ assigned_to: string;
77
+ notes: {
78
+ at: string;
79
+ by: string;
80
+ text: string;
81
+ }[];
82
+ created_at: string;
83
+ updated_at: string;
84
+ description?: string | undefined;
85
+ response?: string | undefined;
86
+ note?: string | undefined;
87
+ completed_at?: string | undefined;
88
+ ownerType?: "user" | "organization" | "system" | null | undefined;
89
+ ownerId?: string | null | undefined;
90
+ agentId?: string | null | undefined;
91
+ sourceEventId?: string | null | undefined;
92
+ links?: {
93
+ kind: string;
94
+ id: string;
95
+ source: string;
96
+ role: string;
97
+ }[] | undefined;
98
+ displayId?: string | undefined;
99
+ authorityUrl?: string | undefined;
100
+ }>;
101
+ remove: (id: string) => Promise<void>;
102
+ addNote: (id: string, text: string) => Promise<{
103
+ id: string;
104
+ title: string;
105
+ lane: string;
106
+ status: "cancelled" | "completed" | "pending" | "blocked" | "in_progress";
107
+ priority: "high" | "medium" | "low" | "critical";
108
+ assigned_to: string;
109
+ notes: {
110
+ at: string;
111
+ by: string;
112
+ text: string;
113
+ }[];
114
+ created_at: string;
115
+ updated_at: string;
116
+ description?: string | undefined;
117
+ response?: string | undefined;
118
+ note?: string | undefined;
119
+ completed_at?: string | undefined;
120
+ ownerType?: "user" | "organization" | "system" | null | undefined;
121
+ ownerId?: string | null | undefined;
122
+ agentId?: string | null | undefined;
123
+ sourceEventId?: string | null | undefined;
124
+ links?: {
125
+ kind: string;
126
+ id: string;
127
+ source: string;
128
+ role: string;
129
+ }[] | undefined;
130
+ displayId?: string | undefined;
131
+ authorityUrl?: string | undefined;
132
+ }>;
133
+ clearCompleted: () => Promise<void>;
134
+ };
135
+ requests: {
136
+ list: (filter?: WorkboardRequestFilter) => Promise<{
137
+ id: string;
138
+ title: string;
139
+ type: "email" | "action" | "deployment" | "code_review" | "plan_confirmation" | "escalation";
140
+ status: "cancelled" | "rejected" | "approved" | "pending" | "expired";
141
+ requested_by: string;
142
+ description: string;
143
+ created_at: string;
144
+ updated_at: string;
145
+ details?: Record<string, unknown> | undefined;
146
+ links?: {
147
+ kind: string;
148
+ id: string;
149
+ source: string;
150
+ role: string;
151
+ }[] | undefined;
152
+ response?: string | undefined;
153
+ reviewed_by?: string | undefined;
154
+ reviewed_at?: string | undefined;
155
+ ownerType?: "user" | "organization" | "system" | null | undefined;
156
+ ownerId?: string | null | undefined;
157
+ agentId?: string | null | undefined;
158
+ sourceEventId?: string | null | undefined;
159
+ }[]>;
160
+ add: (data: WorkboardRequestDraft) => Promise<{
161
+ id: string;
162
+ title: string;
163
+ type: "email" | "action" | "deployment" | "code_review" | "plan_confirmation" | "escalation";
164
+ status: "cancelled" | "rejected" | "approved" | "pending" | "expired";
165
+ requested_by: string;
166
+ description: string;
167
+ created_at: string;
168
+ updated_at: string;
169
+ details?: Record<string, unknown> | undefined;
170
+ links?: {
171
+ kind: string;
172
+ id: string;
173
+ source: string;
174
+ role: string;
175
+ }[] | undefined;
176
+ response?: string | undefined;
177
+ reviewed_by?: string | undefined;
178
+ reviewed_at?: string | undefined;
179
+ ownerType?: "user" | "organization" | "system" | null | undefined;
180
+ ownerId?: string | null | undefined;
181
+ agentId?: string | null | undefined;
182
+ sourceEventId?: string | null | undefined;
183
+ }>;
184
+ review: (id: string, decision: WorkboardRequestReview) => Promise<{
185
+ id: string;
186
+ title: string;
187
+ type: "email" | "action" | "deployment" | "code_review" | "plan_confirmation" | "escalation";
188
+ status: "cancelled" | "rejected" | "approved" | "pending" | "expired";
189
+ requested_by: string;
190
+ description: string;
191
+ created_at: string;
192
+ updated_at: string;
193
+ details?: Record<string, unknown> | undefined;
194
+ links?: {
195
+ kind: string;
196
+ id: string;
197
+ source: string;
198
+ role: string;
199
+ }[] | undefined;
200
+ response?: string | undefined;
201
+ reviewed_by?: string | undefined;
202
+ reviewed_at?: string | undefined;
203
+ ownerType?: "user" | "organization" | "system" | null | undefined;
204
+ ownerId?: string | null | undefined;
205
+ agentId?: string | null | undefined;
206
+ sourceEventId?: string | null | undefined;
207
+ }>;
208
+ remove: (id: string) => Promise<void>;
209
+ clearResolved: () => Promise<void>;
210
+ };
211
+ lanes: {
212
+ list: () => Promise<{
213
+ id: string;
214
+ description: string;
215
+ auto: boolean;
216
+ color: string;
217
+ created_at?: string | undefined;
218
+ updated_at?: string | undefined;
219
+ ownerType?: "user" | "organization" | "system" | null | undefined;
220
+ ownerId?: string | null | undefined;
221
+ }[]>;
222
+ add: (input: WorkboardLaneDraft) => Promise<{
223
+ id: string;
224
+ description: string;
225
+ auto: boolean;
226
+ color: string;
227
+ created_at?: string | undefined;
228
+ updated_at?: string | undefined;
229
+ ownerType?: "user" | "organization" | "system" | null | undefined;
230
+ ownerId?: string | null | undefined;
231
+ }>;
232
+ };
233
+ };
234
+ export type RestWorkboardClient = ReturnType<typeof createRestWorkboardClient>;
235
+ //# sourceMappingURL=rest-workboard-client.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"rest-workboard-client.d.ts","sourceRoot":"","sources":["../../src/svelte/rest-workboard-client.ts"],"names":[],"mappings":"AAEA,OAAO,EAON,KAAK,kBAAkB,EAAE,KAAK,kBAAkB,EAAE,KAAK,mBAAmB,EAC1E,KAAK,qBAAqB,EAAE,KAAK,sBAAsB,EAAE,KAAK,sBAAsB,EACpF,KAAK,kBAAkB,EACvB,MAAM,qBAAqB,CAAC;AAE7B,MAAM,WAAW,0BAA0B;IAC1C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,OAAO,KAAK,CAAC;CACzB;AAED,wBAAgB,yBAAyB,CAAC,OAAO,GAAE,0BAA+B;;wBAwBjE,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBAEtB,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBAEjB,MAAM,SAAS,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBAE3B,MAAM;sBAGX,MAAM,QAAQ,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBAOnB,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;oBAEzB,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;qBAEpB,MAAM,YAAY,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;qBAElC,MAAM;;;;;;;;;;;;;;qBASZ,kBAAkB;;;;;;;;;;;EAIhC;AACD,MAAM,MAAM,mBAAmB,GAAG,UAAU,CAAC,OAAO,yBAAyB,CAAC,CAAC"}
@@ -0,0 +1,52 @@
1
+ import { WorkboardTaskDraftSchema, WorkboardTaskPatchSchema, WorkboardTaskFilterSchema, WorkboardTaskResultSchema, WorkboardTasksResultSchema, WorkboardTaskNoteInputSchema, WorkboardRequestDraftSchema, WorkboardRequestReviewSchema, WorkboardRequestFilterSchema, WorkboardRequestResultSchema, WorkboardRequestsResultSchema, WorkboardLaneDraftSchema, WorkboardLaneResultSchema, WorkboardLanesResultSchema, WorkboardOperationResultSchema } from "../schemas/index.js";
2
+ export function createRestWorkboardClient(options = {}) {
3
+ const base = options.basePath ?? '/api/workboard';
4
+ const doFetch = options.fetchImpl ?? fetch;
5
+ async function request(path, schema, init) {
6
+ const headers = new Headers(init?.headers);
7
+ if (init?.body)
8
+ headers.set('content-type', 'application/json');
9
+ const response = await doFetch(base + path, { ...init, headers });
10
+ const text = await response.text();
11
+ if (!response.ok) {
12
+ throw new Error(`workboard ${init?.method ?? 'GET'} ${base + path} failed (HTTP ${response.status})${text ? ': ' + text.slice(0, 200) : ''}`);
13
+ }
14
+ return schema.parse(text.length ? JSON.parse(text) : undefined);
15
+ }
16
+ function queryString(filter) {
17
+ const query = new URLSearchParams();
18
+ for (const [key, value] of Object.entries(filter)) {
19
+ if (value !== undefined)
20
+ query.set(key, value);
21
+ }
22
+ return query.size ? '?' + query.toString() : '';
23
+ }
24
+ const tasks = {
25
+ list: (filter = {}) => request('/tasks' + queryString(WorkboardTaskFilterSchema.parse(filter)), WorkboardTasksResultSchema),
26
+ add: (data) => request('/tasks', WorkboardTaskResultSchema, { method: 'POST', body: JSON.stringify(WorkboardTaskDraftSchema.parse(data)) }),
27
+ update: (id, patch) => request('/tasks/' + encodeURIComponent(id), WorkboardTaskResultSchema, { method: 'PATCH', body: JSON.stringify(WorkboardTaskPatchSchema.parse(patch)) }),
28
+ remove: async (id) => {
29
+ await request('/tasks/' + encodeURIComponent(id), WorkboardOperationResultSchema, { method: 'DELETE' });
30
+ },
31
+ addNote: (id, text) => request('/tasks/' + encodeURIComponent(id) + '/note', WorkboardTaskResultSchema, { method: 'POST', body: JSON.stringify(WorkboardTaskNoteInputSchema.parse({ text })) }),
32
+ clearCompleted: async () => {
33
+ await request('/tasks/clear-completed', WorkboardOperationResultSchema, { method: 'POST' });
34
+ }
35
+ };
36
+ const requests = {
37
+ list: (filter = {}) => request('/requests' + queryString(WorkboardRequestFilterSchema.parse(filter)), WorkboardRequestsResultSchema),
38
+ add: (data) => request('/requests', WorkboardRequestResultSchema, { method: 'POST', body: JSON.stringify(WorkboardRequestDraftSchema.parse(data)) }),
39
+ review: (id, decision) => request('/requests/' + encodeURIComponent(id) + '/review', WorkboardRequestResultSchema, { method: 'POST', body: JSON.stringify(WorkboardRequestReviewSchema.parse(decision)) }),
40
+ remove: async (id) => {
41
+ await request('/requests/' + encodeURIComponent(id), WorkboardOperationResultSchema, { method: 'DELETE' });
42
+ },
43
+ clearResolved: async () => {
44
+ await request('/requests/clear-resolved', WorkboardOperationResultSchema, { method: 'POST' });
45
+ }
46
+ };
47
+ const lanes = {
48
+ list: () => request('/lanes', WorkboardLanesResultSchema),
49
+ add: (input) => request('/lanes', WorkboardLaneResultSchema, { method: 'POST', body: JSON.stringify(WorkboardLaneDraftSchema.parse(input)) })
50
+ };
51
+ return { tasks, requests, lanes };
52
+ }
@@ -0,0 +1,10 @@
1
+ /*
2
+ * Tailwind v4 source declaration for consumers — mirrors @vibesdotdev/kit's
3
+ * styles.css pattern. Apps that @import this file get this package's
4
+ * components scanned by their Tailwind build, so utility classes used only
5
+ * inside these components are emitted in the app's CSS bundle. Without it,
6
+ * such classes are missing per-app by lottery (Tailwind never scans
7
+ * node_modules). Paths resolve relative to this file: dist/styles.css at
8
+ * runtime, src/styles.css under the bun condition.
9
+ */
10
+ @source "./";