@asanchez-sa/abby 0.0.0-stage → 0.1.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 (391) hide show
  1. package/README.md +245 -2
  2. package/dist/_virtual/_rolldown/runtime.js +26 -0
  3. package/dist/agents/approvals.d.ts +46 -0
  4. package/dist/agents/approvals.js +58 -0
  5. package/dist/agents/changes.d.ts +21 -0
  6. package/dist/agents/changes.js +21 -0
  7. package/dist/agents/hooks.d.ts +20 -0
  8. package/dist/agents/hooks.js +58 -0
  9. package/dist/agents/index.d.ts +11 -0
  10. package/dist/agents/index.js +9 -0
  11. package/dist/agents/run-tool.d.ts +44 -0
  12. package/dist/agents/run-tool.js +79 -0
  13. package/dist/agents/ui-sdk.d.ts +5 -0
  14. package/dist/agents/ui-sdk.js +3 -0
  15. package/dist/behaviors/canvas/index.d.ts +2 -0
  16. package/dist/behaviors/canvas/index.js +1 -0
  17. package/dist/behaviors/canvas/ui-sdk.d.ts +2 -0
  18. package/dist/behaviors/canvas/ui-sdk.js +1 -0
  19. package/dist/behaviors/drag-and-drop/index.d.ts +2 -0
  20. package/dist/behaviors/drag-and-drop/index.js +1 -0
  21. package/dist/behaviors/drag-and-drop/ui-sdk.d.ts +2 -0
  22. package/dist/behaviors/drag-and-drop/ui-sdk.js +1 -0
  23. package/dist/behaviors/dragging/index.d.ts +2 -0
  24. package/dist/behaviors/dragging/index.js +1 -0
  25. package/dist/behaviors/dragging/ui-sdk.d.ts +2 -0
  26. package/dist/behaviors/dragging/ui-sdk.js +1 -0
  27. package/dist/behaviors/focus/index.d.ts +2 -0
  28. package/dist/behaviors/focus/index.js +1 -0
  29. package/dist/behaviors/focus/ui-sdk.d.ts +2 -0
  30. package/dist/behaviors/focus/ui-sdk.js +1 -0
  31. package/dist/behaviors/lists/index.d.ts +3 -0
  32. package/dist/behaviors/lists/index.js +3 -0
  33. package/dist/behaviors/lists/ui-sdk.d.ts +3 -0
  34. package/dist/behaviors/lists/ui-sdk.js +3 -0
  35. package/dist/behaviors/popups/index.d.ts +3 -0
  36. package/dist/behaviors/popups/index.js +3 -0
  37. package/dist/behaviors/popups/ui-sdk.d.ts +3 -0
  38. package/dist/behaviors/popups/ui-sdk.js +3 -0
  39. package/dist/behaviors/preferences/index.d.ts +3 -0
  40. package/dist/behaviors/preferences/index.js +3 -0
  41. package/dist/behaviors/preferences/ui-sdk.d.ts +3 -0
  42. package/dist/behaviors/preferences/ui-sdk.js +3 -0
  43. package/dist/behaviors/selection/index.d.ts +3 -0
  44. package/dist/behaviors/selection/index.js +3 -0
  45. package/dist/behaviors/selection/indicator.d.ts +13 -0
  46. package/dist/behaviors/selection/indicator.js +20 -0
  47. package/dist/behaviors/selection/ui-sdk.d.ts +2 -0
  48. package/dist/behaviors/selection/ui-sdk.js +1 -0
  49. package/dist/behaviors/transitions/index.d.ts +3 -0
  50. package/dist/behaviors/transitions/index.js +3 -0
  51. package/dist/behaviors/transitions/ui-sdk.d.ts +3 -0
  52. package/dist/behaviors/transitions/ui-sdk.js +3 -0
  53. package/dist/behaviors/trees/index.d.ts +2 -0
  54. package/dist/behaviors/trees/index.js +1 -0
  55. package/dist/behaviors/trees/ui-sdk.d.ts +2 -0
  56. package/dist/behaviors/trees/ui-sdk.js +1 -0
  57. package/dist/components/accordion/accordion.d.ts +13 -0
  58. package/dist/components/accordion/accordion.js +165 -0
  59. package/dist/components/alert/alert.d.ts +13 -0
  60. package/dist/components/alert/alert.js +131 -0
  61. package/dist/components/alert-dialog/alert-dialog.d.ts +15 -0
  62. package/dist/components/alert-dialog/alert-dialog.js +257 -0
  63. package/dist/components/aspect-ratio/aspect-ratio.d.ts +7 -0
  64. package/dist/components/aspect-ratio/aspect-ratio.js +57 -0
  65. package/dist/components/attachment/attachment.d.ts +48 -0
  66. package/dist/components/attachment/attachment.js +372 -0
  67. package/dist/components/autocomplete/autocomplete.d.ts +32 -0
  68. package/dist/components/autocomplete/autocomplete.js +466 -0
  69. package/dist/components/avatar/avatar.d.ts +6 -0
  70. package/dist/components/avatar/avatar.js +100 -0
  71. package/dist/components/avatar-group/avatar-group.d.ts +9 -0
  72. package/dist/components/avatar-group/avatar-group.js +75 -0
  73. package/dist/components/badge/badge.d.ts +15 -0
  74. package/dist/components/badge/badge.js +31 -0
  75. package/dist/components/breadcrumb/breadcrumb.d.ts +24 -0
  76. package/dist/components/breadcrumb/breadcrumb.js +279 -0
  77. package/dist/components/bubble/bubble.d.ts +26 -0
  78. package/dist/components/bubble/bubble.js +173 -0
  79. package/dist/components/button/button.d.ts +18 -0
  80. package/dist/components/button/button.js +91 -0
  81. package/dist/components/button-group/button-group.d.ts +15 -0
  82. package/dist/components/button-group/button-group.js +71 -0
  83. package/dist/components/calendar/calendar.d.ts +29 -0
  84. package/dist/components/calendar/calendar.js +453 -0
  85. package/dist/components/card/card.d.ts +14 -0
  86. package/dist/components/card/card.js +213 -0
  87. package/dist/components/carousel/carousel.d.ts +16 -0
  88. package/dist/components/carousel/carousel.js +364 -0
  89. package/dist/components/chain-of-thought/chain-of-thought.d.ts +72 -0
  90. package/dist/components/chain-of-thought/chain-of-thought.js +491 -0
  91. package/dist/components/chat/chat.d.ts +48 -0
  92. package/dist/components/chat/chat.js +207 -0
  93. package/dist/components/checkbox/checkbox.d.ts +10 -0
  94. package/dist/components/checkbox/checkbox.js +118 -0
  95. package/dist/components/checkpoint/checkpoint.d.ts +24 -0
  96. package/dist/components/checkpoint/checkpoint.js +178 -0
  97. package/dist/components/choice-cards/choice-cards.d.ts +38 -0
  98. package/dist/components/choice-cards/choice-cards.js +255 -0
  99. package/dist/components/code-block/code-block.d.ts +58 -0
  100. package/dist/components/code-block/code-block.js +506 -0
  101. package/dist/components/code-block/highlighter.js +96 -0
  102. package/dist/components/code-block/use-highlighted-code.d.ts +11 -0
  103. package/dist/components/code-block/use-highlighted-code.js +54 -0
  104. package/dist/components/collapsible/collapsible.d.ts +10 -0
  105. package/dist/components/collapsible/collapsible.js +92 -0
  106. package/dist/components/color-picker/color-picker.d.ts +17 -0
  107. package/dist/components/color-picker/color-picker.js +395 -0
  108. package/dist/components/combobox/combobox.d.ts +54 -0
  109. package/dist/components/combobox/combobox.js +683 -0
  110. package/dist/components/command/command.d.ts +23 -0
  111. package/dist/components/command/command.js +373 -0
  112. package/dist/components/command-dock/command-dock.d.ts +118 -0
  113. package/dist/components/command-dock/command-dock.js +944 -0
  114. package/dist/components/confirmation/confirmation.d.ts +58 -0
  115. package/dist/components/confirmation/confirmation.js +181 -0
  116. package/dist/components/context/context.d.ts +82 -0
  117. package/dist/components/context/context.js +490 -0
  118. package/dist/components/date-input/date-input.d.ts +16 -0
  119. package/dist/components/date-input/date-input.js +89 -0
  120. package/dist/components/date-picker/date-picker.d.ts +28 -0
  121. package/dist/components/date-picker/date-picker.js +361 -0
  122. package/dist/components/dialog/dialog.d.ts +14 -0
  123. package/dist/components/dialog/dialog.js +261 -0
  124. package/dist/components/drawer/drawer.d.ts +16 -0
  125. package/dist/components/drawer/drawer.js +309 -0
  126. package/dist/components/empty/empty.d.ts +18 -0
  127. package/dist/components/empty/empty.js +192 -0
  128. package/dist/components/field/field.d.ts +15 -0
  129. package/dist/components/field/field.js +261 -0
  130. package/dist/components/file-input/file-input.d.ts +12 -0
  131. package/dist/components/file-input/file-input.js +216 -0
  132. package/dist/components/file-tree/file-tree.d.ts +45 -0
  133. package/dist/components/file-tree/file-tree.js +283 -0
  134. package/dist/components/hover-card/hover-card.d.ts +10 -0
  135. package/dist/components/hover-card/hover-card.js +118 -0
  136. package/dist/components/icon/icon.d.ts +14 -0
  137. package/dist/components/icon/icon.js +60 -0
  138. package/dist/components/image-cropper/image-cropper.d.ts +15 -0
  139. package/dist/components/image-cropper/image-cropper.js +334 -0
  140. package/dist/components/inline-citation/inline-citation.d.ts +46 -0
  141. package/dist/components/inline-citation/inline-citation.js +269 -0
  142. package/dist/components/input/input.d.ts +9 -0
  143. package/dist/components/input/input.js +43 -0
  144. package/dist/components/input-group/input-group.d.ts +42 -0
  145. package/dist/components/input-group/input-group.js +192 -0
  146. package/dist/components/item/item.d.ts +32 -0
  147. package/dist/components/item/item.js +394 -0
  148. package/dist/components/kbd/kbd.d.ts +9 -0
  149. package/dist/components/kbd/kbd.js +75 -0
  150. package/dist/components/label/label.d.ts +6 -0
  151. package/dist/components/label/label.js +40 -0
  152. package/dist/components/link/link.d.ts +21 -0
  153. package/dist/components/link/link.js +126 -0
  154. package/dist/components/listbox/listbox.d.ts +20 -0
  155. package/dist/components/listbox/listbox.js +199 -0
  156. package/dist/components/marker/marker.d.ts +11 -0
  157. package/dist/components/marker/marker.js +88 -0
  158. package/dist/components/menu/menu.d.ts +38 -0
  159. package/dist/components/menu/menu.js +553 -0
  160. package/dist/components/menubar/menubar.d.ts +9 -0
  161. package/dist/components/menubar/menubar.js +47 -0
  162. package/dist/components/message/message.d.ts +44 -0
  163. package/dist/components/message/message.js +328 -0
  164. package/dist/components/message-scroller/message-scroller.d.ts +111 -0
  165. package/dist/components/message-scroller/message-scroller.js +957 -0
  166. package/dist/components/meter/meter.d.ts +8 -0
  167. package/dist/components/meter/meter.js +162 -0
  168. package/dist/components/model-selector/model-selector.d.ts +155 -0
  169. package/dist/components/model-selector/model-selector.js +905 -0
  170. package/dist/components/native-select/native-select.d.ts +27 -0
  171. package/dist/components/native-select/native-select.js +226 -0
  172. package/dist/components/navigation-menu/navigation-menu.d.ts +29 -0
  173. package/dist/components/navigation-menu/navigation-menu.js +318 -0
  174. package/dist/components/not-label.js +9 -0
  175. package/dist/components/note-editor/blocks.d.ts +22 -0
  176. package/dist/components/note-editor/blocks.js +245 -0
  177. package/dist/components/note-editor/diff.d.ts +19 -0
  178. package/dist/components/note-editor/diff.js +64 -0
  179. package/dist/components/note-editor/editor.js +249 -0
  180. package/dist/components/note-editor/note-editor.d.ts +109 -0
  181. package/dist/components/note-editor/note-editor.js +954 -0
  182. package/dist/components/note-editor/parts/comments.d.ts +24 -0
  183. package/dist/components/note-editor/parts/comments.js +337 -0
  184. package/dist/components/note-editor/parts/header.d.ts +25 -0
  185. package/dist/components/note-editor/parts/header.js +263 -0
  186. package/dist/components/note-editor/parts/history.d.ts +56 -0
  187. package/dist/components/note-editor/parts/history.js +409 -0
  188. package/dist/components/note-editor/parts/presence.d.ts +31 -0
  189. package/dist/components/note-editor/parts/presence.js +140 -0
  190. package/dist/components/note-editor/parts/suggestions.d.ts +45 -0
  191. package/dist/components/note-editor/parts/suggestions.js +316 -0
  192. package/dist/components/note-editor/parts/toolbar.d.ts +38 -0
  193. package/dist/components/note-editor/parts/toolbar.js +687 -0
  194. package/dist/components/note-editor/people.d.ts +84 -0
  195. package/dist/components/note-editor/people.js +276 -0
  196. package/dist/components/note-editor/person.d.ts +11 -0
  197. package/dist/components/note-editor/person.js +15 -0
  198. package/dist/components/note-place/note-place.d.ts +42 -0
  199. package/dist/components/note-place/note-place.js +256 -0
  200. package/dist/components/note-status/note-status.d.ts +59 -0
  201. package/dist/components/note-status/note-status.js +380 -0
  202. package/dist/components/number-input/number-input.d.ts +12 -0
  203. package/dist/components/number-input/number-input.js +252 -0
  204. package/dist/components/otp-input/otp-input.d.ts +12 -0
  205. package/dist/components/otp-input/otp-input.js +136 -0
  206. package/dist/components/pagination/pagination.d.ts +23 -0
  207. package/dist/components/pagination/pagination.js +218 -0
  208. package/dist/components/password-input/password-input.d.ts +11 -0
  209. package/dist/components/password-input/password-input.js +117 -0
  210. package/dist/components/plan/plan.d.ts +51 -0
  211. package/dist/components/plan/plan.js +320 -0
  212. package/dist/components/popover/popover.d.ts +16 -0
  213. package/dist/components/popover/popover.js +268 -0
  214. package/dist/components/preferences/preferences.d.ts +5 -0
  215. package/dist/components/preferences/preferences.js +18 -0
  216. package/dist/components/progress/progress.d.ts +8 -0
  217. package/dist/components/progress/progress.js +162 -0
  218. package/dist/components/prompt-input/prompt-input.d.ts +247 -0
  219. package/dist/components/prompt-input/prompt-input.js +1367 -0
  220. package/dist/components/questionnaire/questionnaire.d.ts +174 -0
  221. package/dist/components/questionnaire/questionnaire.js +1628 -0
  222. package/dist/components/queue/queue.d.ts +82 -0
  223. package/dist/components/queue/queue.js +471 -0
  224. package/dist/components/radio/radio.d.ts +7 -0
  225. package/dist/components/radio/radio.js +101 -0
  226. package/dist/components/rating/rating.d.ts +10 -0
  227. package/dist/components/rating/rating.js +95 -0
  228. package/dist/components/reasoning/reasoning.d.ts +50 -0
  229. package/dist/components/reasoning/reasoning.js +233 -0
  230. package/dist/components/resizable/resizable.d.ts +6 -0
  231. package/dist/components/resizable/resizable.js +100 -0
  232. package/dist/components/scroll-area/scroll-area.d.ts +17 -0
  233. package/dist/components/scroll-area/scroll-area.js +211 -0
  234. package/dist/components/segmented-control/segmented-control.d.ts +16 -0
  235. package/dist/components/segmented-control/segmented-control.js +142 -0
  236. package/dist/components/select/select.d.ts +43 -0
  237. package/dist/components/select/select.js +577 -0
  238. package/dist/components/separator/separator.d.ts +4 -0
  239. package/dist/components/separator/separator.js +38 -0
  240. package/dist/components/sheet/sheet.d.ts +24 -0
  241. package/dist/components/sheet/sheet.js +330 -0
  242. package/dist/components/sidebar/sidebar.d.ts +138 -0
  243. package/dist/components/sidebar/sidebar.js +1374 -0
  244. package/dist/components/skeleton/skeleton.d.ts +4 -0
  245. package/dist/components/skeleton/skeleton.js +40 -0
  246. package/dist/components/slider/slider.d.ts +9 -0
  247. package/dist/components/slider/slider.js +193 -0
  248. package/dist/components/sources/sources.d.ts +35 -0
  249. package/dist/components/sources/sources.js +209 -0
  250. package/dist/components/spinner/spinner.d.ts +11 -0
  251. package/dist/components/spinner/spinner.js +59 -0
  252. package/dist/components/stack-trace/parse-stack-trace.d.ts +21 -0
  253. package/dist/components/stack-trace/parse-stack-trace.js +61 -0
  254. package/dist/components/stack-trace/stack-trace.d.ts +79 -0
  255. package/dist/components/stack-trace/stack-trace.js +434 -0
  256. package/dist/components/subagent/subagent.d.ts +71 -0
  257. package/dist/components/subagent/subagent.js +450 -0
  258. package/dist/components/suggestion/suggestion.d.ts +21 -0
  259. package/dist/components/suggestion/suggestion.js +130 -0
  260. package/dist/components/switch/switch.d.ts +6 -0
  261. package/dist/components/switch/switch.js +70 -0
  262. package/dist/components/table/table.d.ts +19 -0
  263. package/dist/components/table/table.js +284 -0
  264. package/dist/components/table-of-contents/spy.js +84 -0
  265. package/dist/components/table-of-contents/table-of-contents.d.ts +92 -0
  266. package/dist/components/table-of-contents/table-of-contents.js +787 -0
  267. package/dist/components/tabs/tabs.d.ts +25 -0
  268. package/dist/components/tabs/tabs.js +273 -0
  269. package/dist/components/task/task.d.ts +40 -0
  270. package/dist/components/task/task.js +262 -0
  271. package/dist/components/terminal/terminal.d.ts +82 -0
  272. package/dist/components/terminal/terminal.js +457 -0
  273. package/dist/components/test-results/test-results.d.ts +127 -0
  274. package/dist/components/test-results/test-results.js +687 -0
  275. package/dist/components/textarea/textarea.d.ts +8 -0
  276. package/dist/components/textarea/textarea.js +43 -0
  277. package/dist/components/time-input/time-input.d.ts +7 -0
  278. package/dist/components/time-input/time-input.js +82 -0
  279. package/dist/components/timeline/timeline.d.ts +19 -0
  280. package/dist/components/timeline/timeline.js +247 -0
  281. package/dist/components/toast/toast.d.ts +12 -0
  282. package/dist/components/toast/toast.js +285 -0
  283. package/dist/components/toggle/toggle.d.ts +15 -0
  284. package/dist/components/toggle/toggle.js +137 -0
  285. package/dist/components/token-input/token-input.d.ts +7 -0
  286. package/dist/components/token-input/token-input.js +117 -0
  287. package/dist/components/tool/tool.d.ts +66 -0
  288. package/dist/components/tool/tool.js +413 -0
  289. package/dist/components/toolbar/toolbar.d.ts +91 -0
  290. package/dist/components/toolbar/toolbar.js +655 -0
  291. package/dist/components/tooltip/tooltip.d.ts +8 -0
  292. package/dist/components/tooltip/tooltip.js +97 -0
  293. package/dist/components/trace/trace.d.ts +31 -0
  294. package/dist/components/trace/trace.js +309 -0
  295. package/dist/components/tree/tree.d.ts +13 -0
  296. package/dist/components/tree/tree.js +258 -0
  297. package/dist/components/trigger-menu/trigger-menu.d.ts +30 -0
  298. package/dist/components/trigger-menu/trigger-menu.js +352 -0
  299. package/dist/components/usage/usage.d.ts +132 -0
  300. package/dist/components/usage/usage.js +1368 -0
  301. package/dist/components/waterfall/waterfall.d.ts +20 -0
  302. package/dist/components/waterfall/waterfall.js +360 -0
  303. package/dist/components/week-strip/week-strip.d.ts +177 -0
  304. package/dist/components/week-strip/week-strip.js +1081 -0
  305. package/dist/core/index.d.ts +7 -0
  306. package/dist/core/index.js +27 -0
  307. package/dist/core/ui-sdk.d.ts +3 -0
  308. package/dist/core/ui-sdk.js +3 -0
  309. package/dist/core/use-primitive-state.d.ts +14 -0
  310. package/dist/core/use-primitive-state.js +25 -0
  311. package/dist/styles/LICENSE-shadcn.md +21 -0
  312. package/dist/styles/color-scheme.css +32 -0
  313. package/dist/styles/components.css +303 -0
  314. package/dist/styles/index.css +41 -0
  315. package/dist/styles/tokens.css +474 -0
  316. package/dist/styles/typeset/shadcn.css +506 -0
  317. package/dist/styles/typeset.css +70 -0
  318. package/dist/styles/utilities.css +555 -0
  319. package/dist/tools/observe/index.d.ts +2 -0
  320. package/dist/tools/observe/index.js +3 -0
  321. package/dist/tools/observe/ui-sdk.d.ts +1 -0
  322. package/dist/tools/observe/ui-sdk.js +2 -0
  323. package/dist/tools/testing/check-agent.d.ts +28 -0
  324. package/dist/tools/testing/check-agent.js +42 -0
  325. package/dist/tools/testing/index.d.ts +4 -0
  326. package/dist/tools/testing/index.js +4 -0
  327. package/dist/tools/testing/ui-sdk.d.ts +1 -0
  328. package/dist/tools/testing/ui-sdk.js +2 -0
  329. package/dist/utilities/cn/index.d.ts +12 -0
  330. package/dist/utilities/cn/index.js +47 -0
  331. package/dist/utilities/color/index.d.ts +2 -0
  332. package/dist/utilities/color/index.js +3 -0
  333. package/dist/utilities/color/ui-sdk.d.ts +1 -0
  334. package/dist/utilities/color/ui-sdk.js +2 -0
  335. package/dist/utilities/date/index.d.ts +2 -0
  336. package/dist/utilities/date/index.js +6 -0
  337. package/dist/utilities/date/ui-sdk.d.ts +1 -0
  338. package/dist/utilities/date/ui-sdk.js +2 -0
  339. package/dist/utilities/image/index.d.ts +2 -0
  340. package/dist/utilities/image/index.js +3 -0
  341. package/dist/utilities/image/ui-sdk.d.ts +1 -0
  342. package/dist/utilities/image/ui-sdk.js +2 -0
  343. package/dist/utilities/mobile/index.d.ts +2 -0
  344. package/dist/utilities/mobile/index.js +1 -0
  345. package/dist/utilities/mobile/ui-sdk.d.ts +2 -0
  346. package/dist/utilities/mobile/ui-sdk.js +1 -0
  347. package/dist/utilities/number/index.d.ts +2 -0
  348. package/dist/utilities/number/index.js +3 -0
  349. package/dist/utilities/number/ui-sdk.d.ts +1 -0
  350. package/dist/utilities/number/ui-sdk.js +2 -0
  351. package/dist/utilities/platform/index.d.ts +3 -0
  352. package/dist/utilities/platform/index.js +14 -0
  353. package/dist/utilities/platform/ui-sdk.d.ts +3 -0
  354. package/dist/utilities/platform/ui-sdk.js +3 -0
  355. package/dist/utilities/storage/index.d.ts +2 -0
  356. package/dist/utilities/storage/index.js +1 -0
  357. package/dist/utilities/storage/ui-sdk.d.ts +2 -0
  358. package/dist/utilities/storage/ui-sdk.js +1 -0
  359. package/dist/utilities/text/index.d.ts +3 -0
  360. package/dist/utilities/text/index.js +3 -0
  361. package/dist/utilities/text/ui-sdk.d.ts +3 -0
  362. package/dist/utilities/text/ui-sdk.js +3 -0
  363. package/package.json +192 -4
  364. package/skills/agent-ready-ui/SKILL.md +229 -0
  365. package/skills/blocks/SKILL.md +262 -0
  366. package/skills/compose-screens/SKILL.md +354 -0
  367. package/skills/note-editor/SKILL.md +493 -0
  368. package/skills/note-status/SKILL.md +295 -0
  369. package/skills/setup/SKILL.md +136 -0
  370. package/skills/theming/SKILL.md +216 -0
  371. package/src/blocks/notes/adapters.ts +77 -0
  372. package/src/blocks/notes/data.ts +508 -0
  373. package/src/blocks/notes/notes-block.tsx +244 -0
  374. package/src/blocks/notes/parts/home.tsx +219 -0
  375. package/src/blocks/notes/parts/no-access.tsx +84 -0
  376. package/src/blocks/notes/parts/note-screen.tsx +412 -0
  377. package/src/blocks/notes/parts/notes-sidebar.tsx +277 -0
  378. package/src/blocks/notes/parts/panels.tsx +393 -0
  379. package/src/blocks/notes/parts/place.ts +15 -0
  380. package/src/blocks/notes/parts/review-dialog.tsx +159 -0
  381. package/src/blocks/notes/parts/share.tsx +172 -0
  382. package/src/blocks/notes/texts.ts +135 -0
  383. package/src/blocks/shell/adapters.ts +69 -0
  384. package/src/blocks/shell/data.ts +281 -0
  385. package/src/blocks/shell/parts/compose.tsx +292 -0
  386. package/src/blocks/shell/parts/home.tsx +203 -0
  387. package/src/blocks/shell/parts/marks.tsx +144 -0
  388. package/src/blocks/shell/parts/rail.tsx +166 -0
  389. package/src/blocks/shell/parts/rooms-column.tsx +326 -0
  390. package/src/blocks/shell/shell-block.tsx +210 -0
  391. package/src/blocks/shell/texts.ts +80 -0
@@ -0,0 +1,77 @@
1
+ import type { NoteBlock, NoteBlockInput } from "abby/note-editor";
2
+ import type { NoteStatus } from "abby/note-status";
3
+ import type { NoteAccess, NotesNote, NotesWorkspace } from "./data.ts";
4
+
5
+ // What an app plugs into the block: where notes are saved, how a review is
6
+ // asked for, what the assistant answers. The block keeps what's on screen and
7
+ // calls these; each returns a promise, and a rejected one shows its error in
8
+ // place (a bar under the header, a line in a dialog) without losing the edit.
9
+
10
+ export type NotesAdapter = {
11
+ /** Creates a note from the home page's title field. Resolves with the note to open. */
12
+ createNote(input: {
13
+ title: string;
14
+ place: string;
15
+ access: NoteAccess;
16
+ template?: string;
17
+ }): Promise<NotesNote>;
18
+ /** Saves a note's blocks, with the ids the editor gave them. */
19
+ saveBlocks(id: string, blocks: NoteBlock[]): Promise<void>;
20
+ saveTitle(id: string, title: string): Promise<void>;
21
+ setStatus(id: string, status: NoteStatus): Promise<void>;
22
+ setPlace(id: string, place: string): Promise<void>;
23
+ /** Asks people to review a note. The app moves it to In review and tells them. */
24
+ requestReview(id: string, input: { reviewers: string[]; message: string }): Promise<void>;
25
+ /** Puts a past version back. Resolves with the blocks the note has now. */
26
+ restoreVersion(id: string, versionId: string): Promise<NoteBlockInput[]>;
27
+ /** Asks the note's owner to let the person in. */
28
+ requestAccess(id: string, message: string): Promise<void>;
29
+ /** Asks the assistant about a note. Resolves with its answer. */
30
+ ask(id: string, question: string): Promise<string>;
31
+ };
32
+
33
+ type MemoryAdapterOptions = {
34
+ /** Makes every save fail, to show what a person sees when saving does. */
35
+ failSaves?: boolean;
36
+ };
37
+
38
+ /**
39
+ * An adapter that keeps nothing: every call resolves at once, as if a server
40
+ * had answered. The stories use it; an app starts from it and replaces each
41
+ * method with a call to its own API.
42
+ */
43
+ export function createMemoryAdapter(
44
+ workspace: NotesWorkspace,
45
+ { failSaves = false }: MemoryAdapterOptions = {},
46
+ ): NotesAdapter {
47
+ const saved = (): Promise<void> =>
48
+ failSaves ? Promise.reject(new Error("The server didn't answer.")) : Promise.resolve();
49
+ let created = 0;
50
+ return {
51
+ createNote: async ({ title, place, access, template }) => {
52
+ created += 1;
53
+ return {
54
+ id: `new-${created}`,
55
+ title,
56
+ place,
57
+ access,
58
+ template,
59
+ status: "draft",
60
+ updated: "now",
61
+ meta: `started by ${workspace.me.name}`,
62
+ blocks: [],
63
+ };
64
+ },
65
+ saveBlocks: saved,
66
+ saveTitle: saved,
67
+ setStatus: saved,
68
+ setPlace: saved,
69
+ requestReview: async () => {},
70
+ restoreVersion: async (id, versionId) => {
71
+ const note = workspace.notes.find((each) => each.id === id);
72
+ return note?.versions?.find((each) => each.id === versionId)?.after ?? note?.blocks ?? [];
73
+ },
74
+ requestAccess: async () => {},
75
+ ask: async () => "I couldn't find anything about that in your notes yet.",
76
+ };
77
+ }
@@ -0,0 +1,508 @@
1
+ import type { NoteBlockInput, NoteComment, NotePresence, NoteSuggestion } from "abby/note-editor";
2
+ import type { NotePlaceArea } from "abby/note-place";
3
+ import type { NotePerson, NoteStatus } from "abby/note-status";
4
+
5
+ // The block's data model and the example workspace its stories show. An app
6
+ // replaces the example with what its adapter loads (see adapters.ts); the
7
+ // types stay.
8
+
9
+ /** Who can read a note: only its author, its area, or people picked one by one. */
10
+ export type NoteAccess = "private" | "area" | "shared";
11
+
12
+ /** A past version of a note: what it was, against the version before it. */
13
+ export type NotesVersion = {
14
+ id: string;
15
+ /** How the header and the history name it: "yesterday, 17:42". */
16
+ label: string;
17
+ before: NoteBlockInput[];
18
+ after: NoteBlockInput[];
19
+ };
20
+
21
+ /** One line of a note's history. */
22
+ export type NotesHistoryEvent = {
23
+ id: string;
24
+ day: string;
25
+ time: string;
26
+ kind: "edit" | "share" | "assistant" | "status" | "create";
27
+ /** The line, with its people in bold: "**Ana** edited «Three bets»". */
28
+ title: string;
29
+ detail?: string;
30
+ quote?: string;
31
+ /** The version this event left behind, which the history can open. */
32
+ version?: string;
33
+ /** Who is still writing, for a live line. */
34
+ live?: NotePerson;
35
+ };
36
+
37
+ /** What the assistant knows about a note: notes it touches and what it found. */
38
+ export type NotesAssistant = {
39
+ related: { title: string; status: NoteStatus; area: string; line: string }[];
40
+ conflict?: string;
41
+ messages: { from: "person" | "assistant"; text: string }[];
42
+ };
43
+
44
+ /** A note that's done and kept: what was saved from it and where it came from. */
45
+ export type NotesMemory = {
46
+ since: string;
47
+ confirmedBy: string;
48
+ saved: { kind: string; title: string; detail: string }[];
49
+ facts: { kind: string; text: string }[];
50
+ origin: string;
51
+ writtenBy: NotePerson[];
52
+ timeline: { date: string; text: string }[];
53
+ };
54
+
55
+ export type NotesNote = {
56
+ id: string;
57
+ title: string;
58
+ /** An area's or a folder's value, as `NotePlaceSelect` gives it. */
59
+ place: string;
60
+ status: NoteStatus;
61
+ access: NoteAccess;
62
+ /** The template it started from, for the meta line. */
63
+ template?: string;
64
+ /** "started by Ana on 4 Nov · 3 people" */
65
+ meta?: string;
66
+ /** How long ago it last changed, in the recent list. */
67
+ updated: string;
68
+ /** The recent list's second line. */
69
+ summary?: string;
70
+ blocks: NoteBlockInput[];
71
+ /** Who is writing in it right now, for the tree's dots. */
72
+ writing?: NotePerson[];
73
+ presence?: NotePresence[];
74
+ comments?: NoteComment[];
75
+ suggestions?: NoteSuggestion[];
76
+ versions?: NotesVersion[];
77
+ history?: NotesHistoryEvent[];
78
+ assistant?: NotesAssistant;
79
+ memory?: NotesMemory;
80
+ /** A note the person can't open: who decides, and in which area. */
81
+ locked?: { owner: string; area: string };
82
+ /** Asked to review it, and by whom. */
83
+ reviewBy?: string;
84
+ };
85
+
86
+ export type NotesWorkspace = {
87
+ me: NotePerson;
88
+ people: NotePerson[];
89
+ areas: NotePlaceArea[];
90
+ notes: NotesNote[];
91
+ /** Today, as the home page writes it. */
92
+ today: string;
93
+ };
94
+
95
+ // The example workspace.
96
+
97
+ const ana: NotePerson = { id: "ana", name: "Ana García" };
98
+ const diego: NotePerson = { id: "diego-ruiz", name: "Diego Ruiz" };
99
+ const marta: NotePerson = { id: "marta", name: "Marta Soler" };
100
+ const lucia: NotePerson = { id: "lucia", name: "Lucía Paredes" };
101
+ const assistant: NotePerson = { id: "assistant", name: "Assistant" };
102
+
103
+ export const areas: NotePlaceArea[] = [
104
+ {
105
+ value: "product",
106
+ label: "Product",
107
+ mark: "bg-chart-1",
108
+ folders: [
109
+ { value: "product/plans", label: "Plans" },
110
+ { value: "product/portugal", label: "Portugal" },
111
+ ],
112
+ },
113
+ { value: "marketing", label: "Marketing", mark: "bg-chart-2" },
114
+ { value: "finance", label: "Finance", mark: "bg-chart-3" },
115
+ { value: "leadership", label: "Leadership", mark: "bg-chart-4" },
116
+ ];
117
+
118
+ export const roadmap: NoteBlockInput[] = [
119
+ { id: "problem", type: "heading-2", text: "Problem" },
120
+ {
121
+ id: "problem-text",
122
+ type: "paragraph",
123
+ text: "Teams keep what they decide in three places and argue about it again every quarter.\nIn 2027 the app has to be the place where it's written once and always found.",
124
+ },
125
+ { id: "bets", type: "heading-2", text: "Three bets" },
126
+ {
127
+ id: "bet-1",
128
+ type: "numbered",
129
+ text: "Shared memory per area, with owners and permissions, in the Team plan at €39",
130
+ },
131
+ {
132
+ id: "bet-2",
133
+ type: "numbered",
134
+ text: "Rooms that start in Slack and go back to Slack, without asking anyone to change apps.",
135
+ },
136
+ {
137
+ id: "bet-3",
138
+ type: "numbered",
139
+ text: "Notes that end up in Memory, with where they came from.",
140
+ },
141
+ { id: "left-out", type: "heading-2", text: "What we left out" },
142
+ ];
143
+
144
+ const roadmapYesterday: NoteBlockInput[] = roadmap.slice(0, 7);
145
+ const roadmapBefore: NoteBlockInput[] = [
146
+ ...roadmap.slice(0, 4),
147
+ { id: "bet-2", type: "numbered", text: "Rooms connected to Slack, like one more channel." },
148
+ ];
149
+
150
+ const payments: NoteBlockInput[] = [
151
+ {
152
+ id: "intro",
153
+ type: "paragraph",
154
+ text: "How we pay suppliers and freelancers. Finance follows it every week, from the invoice to the payment.",
155
+ },
156
+ { id: "steps", type: "heading-2", text: "Steps" },
157
+ {
158
+ id: "s1",
159
+ type: "numbered",
160
+ text: "The invoice reaches invoices@example.com. Marta logs it that day.",
161
+ },
162
+ {
163
+ id: "s2",
164
+ type: "numbered",
165
+ text: "Diego checks it against the order. If it doesn't match, it goes back and the term starts again.",
166
+ },
167
+ { id: "s3", type: "numbered", text: "Suppliers are paid 45 days from the invoice date." },
168
+ { id: "s4", type: "numbered", text: "Freelancers are paid 15 days from the invoice date." },
169
+ {
170
+ id: "s5",
171
+ type: "numbered",
172
+ text: "Before each run, Marta checks cash doesn't drop under 3 months of costs. If it does, Leadership decides.",
173
+ },
174
+ ];
175
+
176
+ export const workspace: NotesWorkspace = {
177
+ me: lucia,
178
+ people: [ana, diego, marta, lucia],
179
+ areas,
180
+ today: "Monday, 9 November",
181
+ notes: [
182
+ {
183
+ id: "base-price",
184
+ title: "Base price 2027",
185
+ place: "finance",
186
+ status: "review",
187
+ access: "area",
188
+ updated: "1 h ago",
189
+ reviewBy: "Marta",
190
+ summary: "Marta asked you to review it",
191
+ blocks: [
192
+ { id: "how", type: "heading-2", text: "How it's worked out" },
193
+ {
194
+ id: "how-text",
195
+ type: "paragraph",
196
+ text: "From the monthly closing cost, reviewed every January with Leadership.",
197
+ },
198
+ ],
199
+ },
200
+ {
201
+ id: "roadmap",
202
+ title: "Roadmap 2027",
203
+ place: "product/plans",
204
+ status: "doing",
205
+ access: "area",
206
+ template: "PRD",
207
+ meta: "started by Ana on 4 Nov · 3 people",
208
+ updated: "now",
209
+ summary: "Ana and Diego are writing now",
210
+ writing: [ana, diego],
211
+ blocks: roadmap,
212
+ presence: [
213
+ {
214
+ ...diego,
215
+ color: "var(--presence-1)",
216
+ cursor: { blockId: "bet-1", offset: "Shared memory per area, with owners".length },
217
+ },
218
+ {
219
+ ...ana,
220
+ color: "var(--presence-2)",
221
+ cursor: { blockId: "bet-3", offset: "Notes that end up in Memory".length },
222
+ },
223
+ ],
224
+ comments: [
225
+ {
226
+ id: "slack",
227
+ blockId: "bet-2",
228
+ quote: "without asking anyone to change apps",
229
+ messages: [
230
+ {
231
+ id: "m1",
232
+ author: marta,
233
+ time: "10:02",
234
+ text: "And the teams that don't use Slack? Finance lives in email.",
235
+ },
236
+ ],
237
+ },
238
+ ],
239
+ suggestions: [
240
+ {
241
+ id: "left-out",
242
+ blockId: "left-out",
243
+ kind: "assistant",
244
+ author: assistant,
245
+ summary: "· you asked for it in the assistant's panel",
246
+ text: "Windows app: stays for 2028, as decided in «Roadmap 2026». Per-seat pricing: Finance prefers per-organization pricing since October.",
247
+ source: "With «Roadmap 2026» and 1 Finance memory",
248
+ },
249
+ ],
250
+ versions: [
251
+ {
252
+ id: "yesterday-1742",
253
+ label: "yesterday, 17:42",
254
+ before: roadmapBefore,
255
+ after: roadmapYesterday,
256
+ },
257
+ ],
258
+ history: [
259
+ {
260
+ id: "h1",
261
+ day: "Today",
262
+ time: "10:14",
263
+ kind: "edit",
264
+ title: "**Ana** writes in «Three bets»",
265
+ detail: "Writing now · 2 changes",
266
+ live: ana,
267
+ },
268
+ {
269
+ id: "h2",
270
+ day: "Today",
271
+ time: "09:31",
272
+ kind: "edit",
273
+ title: "**Diego** edited «Problem»",
274
+ detail: "6 changes",
275
+ },
276
+ {
277
+ id: "h3",
278
+ day: "Yesterday",
279
+ time: "17:42",
280
+ kind: "edit",
281
+ title: "**Ana** edited «Three bets»",
282
+ detail: "4 changes · 3 added · 1 removed",
283
+ version: "yesterday-1742",
284
+ },
285
+ {
286
+ id: "h4",
287
+ day: "Yesterday",
288
+ time: "16:48",
289
+ kind: "share",
290
+ title: "**Ana** shared it with **Marta** (Finance)",
291
+ detail: "Reads · until 30 Nov",
292
+ },
293
+ {
294
+ id: "h5",
295
+ day: "Yesterday",
296
+ time: "16:05",
297
+ kind: "assistant",
298
+ title: "**Assistant** proposed a change in «Problem»",
299
+ detail: "Ana accepted it · 1 change",
300
+ quote: "«In 2027 the app has to be the place where it's written once and always found.»",
301
+ },
302
+ {
303
+ id: "h6",
304
+ day: "Yesterday",
305
+ time: "12:30",
306
+ kind: "status",
307
+ title: "**Moved to In progress** · Ana",
308
+ },
309
+ {
310
+ id: "h7",
311
+ day: "4 Nov",
312
+ time: "11:20",
313
+ kind: "create",
314
+ title: "**Ana** wrote the first draft",
315
+ detail: "14 changes",
316
+ },
317
+ ],
318
+ assistant: {
319
+ related: [
320
+ {
321
+ title: "Roadmap 2026",
322
+ status: "done",
323
+ area: "Product",
324
+ line: "In Memory · Last year's: what was done and what was left out",
325
+ },
326
+ {
327
+ title: "How we onboard a team",
328
+ status: "draft",
329
+ area: "Product",
330
+ line: "Draft · Bet 1 starts here: which area each team goes in",
331
+ },
332
+ ],
333
+ conflict:
334
+ "Clashes with «Base price 2027», from Finance: there the Team plan is €49; here, €39.",
335
+ messages: [
336
+ { from: "person", text: "What did we leave out last year, and why?" },
337
+ {
338
+ from: "assistant",
339
+ text: "In «Roadmap 2026» two things were left out: the Windows app, moved to 2028 so the Mac team wasn't split, and per-seat pricing, which Finance changed to per-organization pricing in October. I left a paragraph in «What we left out»: accept or discard it there.",
340
+ },
341
+ ],
342
+ },
343
+ },
344
+ {
345
+ id: "offline-mac",
346
+ title: "Offline mode in the Mac app",
347
+ place: "product/plans",
348
+ status: "draft",
349
+ access: "private",
350
+ updated: "10:12",
351
+ summary: "Only you · the metrics section is missing",
352
+ blocks: [
353
+ {
354
+ id: "o1",
355
+ type: "paragraph",
356
+ text: "The app keeps what you dictate even with no network, and uploads it when you're back.",
357
+ },
358
+ ],
359
+ },
360
+ {
361
+ id: "portugal-launch",
362
+ title: "Portugal launch plan",
363
+ place: "product/portugal",
364
+ status: "draft",
365
+ access: "private",
366
+ updated: "now",
367
+ blocks: [],
368
+ },
369
+ {
370
+ id: "portugal-prices",
371
+ title: "Prices for Portugal",
372
+ place: "product/portugal",
373
+ status: "draft",
374
+ access: "area",
375
+ updated: "2 days ago",
376
+ blocks: [],
377
+ },
378
+ {
379
+ id: "onboarding",
380
+ title: "How we onboard a team",
381
+ place: "product",
382
+ status: "draft",
383
+ access: "area",
384
+ updated: "3 days ago",
385
+ blocks: [],
386
+ },
387
+ {
388
+ id: "summer-brief",
389
+ title: "Summer brief 2027",
390
+ place: "marketing",
391
+ status: "draft",
392
+ access: "area",
393
+ updated: "yesterday",
394
+ summary: "The assistant drafted it from the Campaigns room",
395
+ blocks: [],
396
+ },
397
+ {
398
+ id: "autumn-campaigns",
399
+ title: "Autumn campaign calendar",
400
+ place: "marketing",
401
+ status: "doing",
402
+ access: "area",
403
+ updated: "Mon",
404
+ summary: "The assistant suggests 2 changes",
405
+ blocks: [],
406
+ },
407
+ {
408
+ id: "brand-tone",
409
+ title: "Brand tone 2027",
410
+ place: "marketing",
411
+ status: "review",
412
+ access: "area",
413
+ updated: "Fri",
414
+ blocks: [],
415
+ },
416
+ {
417
+ id: "payments",
418
+ title: "Paying suppliers",
419
+ place: "finance",
420
+ status: "done",
421
+ access: "area",
422
+ template: "Process",
423
+ meta: "written by Marta and Diego · v1",
424
+ updated: "08/11",
425
+ summary: "In Memory · 3 memories confirmed",
426
+ blocks: payments,
427
+ memory: {
428
+ since: "08/11",
429
+ confirmedBy: "Diego",
430
+ saved: [
431
+ {
432
+ kind: "Document · v1",
433
+ title: "Paying suppliers",
434
+ detail: "Finance › Payments · the whole note",
435
+ },
436
+ ],
437
+ facts: [
438
+ { kind: "Rule · Payments", text: "We pay 45 days from the invoice" },
439
+ { kind: "Rule · Payments", text: "Freelancers are paid in 15 days" },
440
+ { kind: "Fact · Cash", text: "Minimum cash: 3 months" },
441
+ ],
442
+ origin: "Q3 closing room › Suppliers thread",
443
+ writtenBy: [marta, diego],
444
+ timeline: [
445
+ { date: "08/11", text: "Diego confirmed 3 memories and moved it to Memory" },
446
+ { date: "06/11", text: "Marta asked Diego for a review" },
447
+ {
448
+ date: "03/11",
449
+ text: "Marta created it from the Q3 closing room with the Process template",
450
+ },
451
+ ],
452
+ },
453
+ },
454
+ {
455
+ id: "roadmap-2026",
456
+ title: "Roadmap 2026",
457
+ place: "product/plans",
458
+ status: "done",
459
+ access: "area",
460
+ updated: "Jan",
461
+ blocks: [],
462
+ },
463
+ {
464
+ id: "infra-costs",
465
+ title: "Infrastructure costs",
466
+ place: "leadership",
467
+ status: "doing",
468
+ access: "shared",
469
+ updated: "Tue",
470
+ locked: { owner: "Iván Ruiz", area: "DevOps" },
471
+ blocks: [],
472
+ },
473
+ ],
474
+ };
475
+
476
+ /** A workspace with no notes yet: the first day. */
477
+ export const emptyWorkspace: NotesWorkspace = { ...workspace, notes: [] };
478
+
479
+ /** The templates a note can start with, in order. */
480
+ export const templates: { name: string; blocks: NoteBlockInput[] }[] = [
481
+ {
482
+ name: "PRD",
483
+ blocks: [
484
+ { type: "heading-2", text: "Problem" },
485
+ { type: "paragraph", text: "" },
486
+ { type: "heading-2", text: "Goals" },
487
+ { type: "bulleted", text: "" },
488
+ { type: "heading-2", text: "Out of scope" },
489
+ { type: "bulleted", text: "" },
490
+ ],
491
+ },
492
+ {
493
+ name: "Process",
494
+ blocks: [
495
+ { type: "heading-2", text: "When to use it" },
496
+ { type: "paragraph", text: "" },
497
+ { type: "heading-2", text: "Steps" },
498
+ { type: "numbered", text: "" },
499
+ ],
500
+ },
501
+ {
502
+ name: "Document",
503
+ blocks: [
504
+ { type: "heading-2", text: "Summary" },
505
+ { type: "paragraph", text: "" },
506
+ ],
507
+ },
508
+ ];