@1agh/maude 2.0.8 → 2.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 (401) hide show
  1. package/README.md +2 -1
  2. package/apps/hub/src/project-transactions/kernel.mjs +13 -7
  3. package/apps/studio/access/closure.ts +86 -10
  4. package/apps/studio/access/filters.ts +18 -1
  5. package/apps/studio/access/request.ts +8 -0
  6. package/apps/studio/acp/design-write-verb.ts +12 -2
  7. package/apps/studio/acp/env.ts +7 -2
  8. package/apps/studio/acp/index.ts +15 -4
  9. package/apps/studio/acp/login-state.ts +22 -5
  10. package/apps/studio/acp/may-scope.ts +38 -1
  11. package/apps/studio/acp/plugin-bootstrap.ts +13 -1
  12. package/apps/studio/acp/probe.ts +11 -4
  13. package/apps/studio/actions/agents.ts +110 -28
  14. package/apps/studio/actions/canvas-keys.ts +4 -2
  15. package/apps/studio/actions/ctx.ts +3 -0
  16. package/apps/studio/actions/defs/annotation.ts +84 -2
  17. package/apps/studio/actions/defs/app.ts +28 -1
  18. package/apps/studio/actions/defs/edit.ts +13 -0
  19. package/apps/studio/actions/defs/export.ts +12 -0
  20. package/apps/studio/actions/defs/sync.ts +18 -0
  21. package/apps/studio/actions/defs/video.ts +9 -0
  22. package/apps/studio/actions/documents.ts +6 -1
  23. package/apps/studio/actions/keymap.gen.ts +147 -9
  24. package/apps/studio/actions/menu.ts +5 -1
  25. package/apps/studio/actions/types.ts +4 -2
  26. package/apps/studio/actions/verbs.ts +9 -0
  27. package/apps/studio/actions.manifest.json +300 -45
  28. package/apps/studio/actions.parity.json +19 -1
  29. package/apps/studio/ai/save-hold.ts +2 -1
  30. package/apps/studio/ai/write-claim-scope.ts +7 -1
  31. package/apps/studio/ai/write-claim.ts +154 -3
  32. package/apps/studio/annotations/ai-read.ts +42 -6
  33. package/apps/studio/annotations/ai-write.ts +145 -2
  34. package/apps/studio/annotations/board-ops.ts +34 -3
  35. package/apps/studio/annotations/checklist-ops.ts +374 -0
  36. package/apps/studio/annotations/elements/checkitem.model.ts +129 -0
  37. package/apps/studio/annotations/elements/sticky.model.ts +54 -2
  38. package/apps/studio/annotations/ops.ts +30 -0
  39. package/apps/studio/annotations/registry.ts +9 -1
  40. package/apps/studio/annotations/templates.ts +4 -2
  41. package/apps/studio/annotations/text-steps.ts +114 -10
  42. package/apps/studio/annotations/ui/checklist-wire.ts +129 -0
  43. package/apps/studio/annotations/ui/checklist.tsx +429 -0
  44. package/apps/studio/annotations/ui/element-node.tsx +48 -2
  45. package/apps/studio/annotations/ui/template-place.ts +11 -1
  46. package/apps/studio/annotations/v1-adapter.ts +22 -3
  47. package/apps/studio/annotations-context-toolbar.tsx +12 -0
  48. package/apps/studio/annotations-layer.tsx +442 -49
  49. package/apps/studio/annotations-model.ts +4 -2
  50. package/apps/studio/api.ts +148 -21
  51. package/apps/studio/artboard-live-gate.tsx +54 -17
  52. package/apps/studio/artboard-still-persist.ts +166 -0
  53. package/apps/studio/artboard-still-raster.ts +6 -2
  54. package/apps/studio/artboard-still.ts +390 -20
  55. package/apps/studio/asset-added.ts +154 -0
  56. package/apps/studio/asset-details.ts +46 -3
  57. package/apps/studio/asset-origins.ts +5 -3
  58. package/apps/studio/asset-trash.ts +6 -1
  59. package/apps/studio/bin/_agent-browser-safe.mjs +3 -4
  60. package/apps/studio/bin/_annotate-post.mjs +14 -5
  61. package/apps/studio/bin/_audio-search.mjs +8 -2
  62. package/apps/studio/bin/_curl-local.mjs +7 -4
  63. package/apps/studio/bin/_desktop-locate.sh +145 -0
  64. package/apps/studio/bin/_ds-check-live.mjs +2 -1
  65. package/apps/studio/bin/_exports.mjs +38 -2
  66. package/apps/studio/bin/_history.mjs +79 -8
  67. package/apps/studio/bin/_import-asset.mjs +14 -9
  68. package/apps/studio/bin/_import-figma.mjs +510 -98
  69. package/apps/studio/bin/_index-cli.mjs +10 -21
  70. package/apps/studio/bin/_ingest-footage.mjs +24 -6
  71. package/apps/studio/bin/_media-probe.mjs +232 -0
  72. package/apps/studio/bin/_perf-probe-open.mjs +6 -0
  73. package/apps/studio/bin/_perf-probe-safari.mjs +6 -0
  74. package/apps/studio/bin/_perf-probe-studio.mjs +6 -1
  75. package/apps/studio/bin/_perf-probe.mjs +8 -3
  76. package/apps/studio/bin/_perf-sweep-shared.mjs +789 -0
  77. package/apps/studio/bin/_perf-sweep.mjs +240 -0
  78. package/apps/studio/bin/_record-shot.sh +33 -8
  79. package/apps/studio/bin/_screenshot-playwright.mjs +45 -2
  80. package/apps/studio/bin/_studio-verb.mjs +8 -3
  81. package/apps/studio/bin/_thumb-route.mjs +21 -0
  82. package/apps/studio/bin/_thumbs-playwright.mjs +83 -1
  83. package/apps/studio/bin/_transcribe.mjs +22 -6
  84. package/apps/studio/bin/_unsynced-refs.mjs +22 -0
  85. package/apps/studio/bin/_url-guard.mjs +120 -5
  86. package/apps/studio/bin/_url-guard.sh +29 -7
  87. package/apps/studio/bin/_video-limits.mjs +104 -0
  88. package/apps/studio/bin/_video-playwright.mjs +119 -19
  89. package/apps/studio/bin/_video-proxy.mjs +130 -0
  90. package/apps/studio/bin/_write-claim.mjs +38 -16
  91. package/apps/studio/bin/annotate.mjs +12 -2
  92. package/apps/studio/bin/canvas-rects.sh +19 -4
  93. package/apps/studio/bin/chat-open.sh +7 -1
  94. package/apps/studio/bin/draw-proof.sh +6 -2
  95. package/apps/studio/bin/generate.sh +32 -10
  96. package/apps/studio/bin/handoff.sh +2 -2
  97. package/apps/studio/bin/perf.sh +96 -15
  98. package/apps/studio/bin/photo-adjust.sh +6 -3
  99. package/apps/studio/bin/photo-bg-remove.sh +2 -2
  100. package/apps/studio/bin/prep.sh +21 -4
  101. package/apps/studio/bin/read-annotations.mjs +3 -0
  102. package/apps/studio/bin/runtime-health.sh +27 -1
  103. package/apps/studio/bin/screenshot.sh +152 -12
  104. package/apps/studio/bin/server-up.sh +64 -6
  105. package/apps/studio/bin/smoke.sh +43 -8
  106. package/apps/studio/bin/to-lottie.sh +3 -2
  107. package/apps/studio/bin/video-proxy.sh +27 -0
  108. package/apps/studio/bin/visual-sanity.sh +3 -1
  109. package/apps/studio/bridge/dgn-protocol.ts +157 -1
  110. package/apps/studio/bridge/mode-shows.ts +8 -6
  111. package/apps/studio/bridge/still-webp.ts +233 -0
  112. package/apps/studio/build.ts +18 -0
  113. package/apps/studio/canvas-build.ts +93 -11
  114. package/apps/studio/canvas-comment-mount.tsx +53 -8
  115. package/apps/studio/canvas-edit.ts +34 -1
  116. package/apps/studio/canvas-lib-module.ts +210 -0
  117. package/apps/studio/canvas-lib.tsx +3 -12
  118. package/apps/studio/canvas-pipeline.ts +111 -5
  119. package/apps/studio/canvas-shell.tsx +8 -11
  120. package/apps/studio/canvas-theme-pill.tsx +5 -3
  121. package/apps/studio/check/index.ts +12 -5
  122. package/apps/studio/check/video.ts +18 -2
  123. package/apps/studio/client/app.jsx +65 -7
  124. package/apps/studio/client/clipboard-relay.ts +193 -16
  125. package/apps/studio/client/comments-overlay.css +18 -0
  126. package/apps/studio/client/export-center.jsx +30 -0
  127. package/apps/studio/client/generate-dialog.jsx +49 -4
  128. package/apps/studio/client/github.js +7 -0
  129. package/apps/studio/client/home/HomeAccountsRow.jsx +221 -0
  130. package/apps/studio/client/home/HomeConnection.jsx +111 -0
  131. package/apps/studio/client/home/home-accounts-model.js +110 -1
  132. package/apps/studio/client/home/home-api.js +9 -2
  133. package/apps/studio/client/home/home-app.jsx +126 -13
  134. package/apps/studio/client/home/home-model.js +69 -1
  135. package/apps/studio/client/home/home-where-model.js +105 -0
  136. package/apps/studio/client/home/home.css +239 -1
  137. package/apps/studio/client/hooks/use-canvas-bridge.jsx +173 -98
  138. package/apps/studio/client/hooks/use-palette-and-panels.jsx +5 -1
  139. package/apps/studio/client/hooks/use-tabs.jsx +11 -4
  140. package/apps/studio/client/panels/DiffView.jsx +7 -1
  141. package/apps/studio/client/panels/TeamProjects.jsx +137 -134
  142. package/apps/studio/client/panels/chat-context.js +2 -0
  143. package/apps/studio/client/panels/slash-commands.gen.js +13 -13
  144. package/apps/studio/client/selection-scope.js +16 -9
  145. package/apps/studio/client/share-link.js +12 -0
  146. package/apps/studio/client/shell/viewport.jsx +11 -1
  147. package/apps/studio/client/shell-events.js +8 -0
  148. package/apps/studio/client/styles/3-kit-maude-v2.css +16 -0
  149. package/apps/studio/client/styles/_index.css +4 -0
  150. package/apps/studio/client/v2/ai/Feed.jsx +1 -1
  151. package/apps/studio/client/v2/ai/OfferCard.jsx +34 -0
  152. package/apps/studio/client/v2/ai/activity-line.js +54 -1
  153. package/apps/studio/client/v2/ai/ai-offer.js +21 -1
  154. package/apps/studio/client/v2/ai/run-model.js +3 -1
  155. package/apps/studio/client/v2/annotations/vote-store.js +28 -4
  156. package/apps/studio/client/v2/assets/asset-drop-session.js +37 -2
  157. package/apps/studio/client/v2/assets/canvas-drop-catcher.jsx +7 -5
  158. package/apps/studio/client/v2/assets/details-model.js +1 -1
  159. package/apps/studio/client/v2/assets/details.jsx +5 -0
  160. package/apps/studio/client/v2/assets/tile-drag.js +11 -7
  161. package/apps/studio/client/v2/comments/comments-panel.jsx +22 -3
  162. package/apps/studio/client/v2/create/duplicate-done.js +6 -2
  163. package/apps/studio/client/v2/diagnostics/diagnostics-host.jsx +1 -0
  164. package/apps/studio/client/v2/diagnostics/diagnostics-model.js +32 -2
  165. package/apps/studio/client/v2/diagnostics/diagnostics-sheet.jsx +35 -8
  166. package/apps/studio/client/v2/diagnostics/diagnostics.css +34 -0
  167. package/apps/studio/client/v2/diagnostics/sync-details/sync-details-model.js +113 -3
  168. package/apps/studio/client/v2/diagnostics/sync-details/sync-details.jsx +343 -6
  169. package/apps/studio/client/v2/diagnostics/sync-details/unsynced-refs.js +55 -0
  170. package/apps/studio/client/v2/ds/review.css +1 -1
  171. package/apps/studio/client/v2/export/exports-model.js +7 -0
  172. package/apps/studio/client/v2/export/exports-panel.jsx +1 -0
  173. package/apps/studio/client/v2/export/job-row.jsx +32 -2
  174. package/apps/studio/client/v2/handoff/ready-card.jsx +1 -1
  175. package/apps/studio/client/v2/history/compare-view.jsx +1 -0
  176. package/apps/studio/client/v2/inspector/css-write.js +6 -1
  177. package/apps/studio/client/v2/inspector/frame.jsx +28 -4
  178. package/apps/studio/client/v2/inspector/kinds/clip-model.js +51 -0
  179. package/apps/studio/client/v2/inspector/kinds/clip.jsx +75 -2
  180. package/apps/studio/client/v2/inspector/model.js +21 -0
  181. package/apps/studio/client/v2/inspector/sections/fill.jsx +12 -3
  182. package/apps/studio/client/v2/inspector/sections/recent-colours.js +8 -5
  183. package/apps/studio/client/v2/inspector/view-mode.jsx +11 -1
  184. package/apps/studio/client/v2/link-server/LinkServerDialog.jsx +492 -0
  185. package/apps/studio/client/v2/link-server/LinkServerHost.jsx +42 -0
  186. package/apps/studio/client/v2/link-server/link-server-api.js +142 -0
  187. package/apps/studio/client/v2/link-server/link-server-model.js +438 -0
  188. package/apps/studio/client/v2/link-server/link-server.css +109 -0
  189. package/apps/studio/client/v2/onboarding/AdvancedSheets.jsx +31 -86
  190. package/apps/studio/client/v2/onboarding/onboarding-model.js +1 -18
  191. package/apps/studio/client/v2/preview/link-follow.js +4 -2
  192. package/apps/studio/client/v2/preview/preview-chrome-host.jsx +16 -6
  193. package/apps/studio/client/v2/search/help-model.js +2 -0
  194. package/apps/studio/client/v2/search/search-keywords.js +3 -2
  195. package/apps/studio/client/v2/settings/account.jsx +4 -2
  196. package/apps/studio/client/v2/settings/advanced-section.jsx +344 -137
  197. package/apps/studio/client/v2/settings/connection-row.jsx +3 -59
  198. package/apps/studio/client/v2/settings/connections-section.jsx +118 -425
  199. package/apps/studio/client/v2/settings/general-section.jsx +155 -24
  200. package/apps/studio/client/v2/settings/project-sync-settings.jsx +4 -3
  201. package/apps/studio/client/v2/settings/reset-section.jsx +14 -3
  202. package/apps/studio/client/v2/settings/settings-card.jsx +142 -0
  203. package/apps/studio/client/v2/settings/settings-cards.js +220 -0
  204. package/apps/studio/client/v2/settings/settings-handlers.js +7 -6
  205. package/apps/studio/client/v2/settings/settings-model.js +100 -31
  206. package/apps/studio/client/v2/settings/settings-sheet.jsx +25 -6
  207. package/apps/studio/client/v2/settings/settings.css +374 -64
  208. package/apps/studio/client/v2/settings/this-project-card.jsx +730 -0
  209. package/apps/studio/client/v2/settings/this-project-model.js +172 -0
  210. package/apps/studio/client/v2/settings/use-connections.js +3 -2
  211. package/apps/studio/client/v2/settings/use-open-card.js +37 -0
  212. package/apps/studio/client/v2/share/share-sheet.jsx +28 -11
  213. package/apps/studio/client/v2/shell/api-session-boot.js +6 -0
  214. package/apps/studio/client/v2/shell/api-session.js +126 -0
  215. package/apps/studio/client/v2/shell/connection-state.js +197 -0
  216. package/apps/studio/client/v2/shell/floating-panels.css +31 -1
  217. package/apps/studio/client/v2/shell/image-pick.js +61 -8
  218. package/apps/studio/client/v2/shell/menu-aim.js +43 -0
  219. package/apps/studio/client/v2/shell/menu-runner.js +25 -7
  220. package/apps/studio/client/v2/shell/occlusion-insets.js +18 -1
  221. package/apps/studio/client/v2/shell/project-account-bus.js +36 -0
  222. package/apps/studio/client/v2/shell/project-account-card.jsx +357 -148
  223. package/apps/studio/client/v2/shell/project-account-model.js +272 -149
  224. package/apps/studio/client/v2/shell/project-account-toast.js +66 -0
  225. package/apps/studio/client/v2/shell/project-account.css +237 -0
  226. package/apps/studio/client/v2/shell/project-pill.jsx +52 -6
  227. package/apps/studio/client/v2/shell/share-cluster-host.jsx +166 -83
  228. package/apps/studio/client/v2/shell/shell-parity.js +3 -2
  229. package/apps/studio/client/v2/shell/shell-parity.json +71 -36
  230. package/apps/studio/client/v2/shell/still-bridge.js +194 -0
  231. package/apps/studio/client/v2/shell/still-store.js +319 -0
  232. package/apps/studio/client/v2/shell/use-account.js +2 -0
  233. package/apps/studio/client/v2/shell/use-tool-panels.js +2 -1
  234. package/apps/studio/client/v2/signin/use-signin.js +1 -1
  235. package/apps/studio/client/v2/timeline/Timeline.jsx +15 -0
  236. package/apps/studio/client/v2/timeline/frame-handle-model.js +142 -0
  237. package/apps/studio/client/v2/timeline/frame-handle.jsx +151 -0
  238. package/apps/studio/clip-ops.ts +126 -8
  239. package/apps/studio/cloud/endpoints.ts +29 -4
  240. package/apps/studio/collab/ai-activity.ts +10 -8
  241. package/apps/studio/collab/awareness-bridge.ts +34 -9
  242. package/apps/studio/collab/index.ts +3 -0
  243. package/apps/studio/collab/registry.ts +41 -10
  244. package/apps/studio/comment-reattach.ts +149 -0
  245. package/apps/studio/comments/mine-stamp.ts +15 -7
  246. package/apps/studio/comments/ops.ts +52 -8
  247. package/apps/studio/comments-overlay.tsx +146 -9
  248. package/apps/studio/dist/client.bundle.js +892 -885
  249. package/apps/studio/dist/comment-mount.js +2 -2
  250. package/apps/studio/dist/styles.css +1 -1
  251. package/apps/studio/dom-selection.ts +87 -18
  252. package/apps/studio/ds/board/directions.css +8 -0
  253. package/apps/studio/ds/board/outline.tsx +16 -0
  254. package/apps/studio/ds/canvas-check.ts +6 -0
  255. package/apps/studio/edit-ops/clip/reframe.ts +19 -3
  256. package/apps/studio/edit-ops/clip-carry.ts +602 -0
  257. package/apps/studio/edit-ops/clipboard.ts +318 -23
  258. package/apps/studio/edit-ops/dispatch.ts +20 -2
  259. package/apps/studio/edit-ops/scope-names.ts +249 -40
  260. package/apps/studio/edit-ops/slot-defaults.ts +3 -0
  261. package/apps/studio/edit-ops/types.ts +6 -0
  262. package/apps/studio/editing/align-bar.tsx +33 -9
  263. package/apps/studio/editing/artboard-actions.ts +5 -0
  264. package/apps/studio/editing/artboard-menu.tsx +6 -2
  265. package/apps/studio/editing/click-to-type.ts +1 -1
  266. package/apps/studio/editing/clip-words.ts +48 -0
  267. package/apps/studio/editing/clipboard.ts +21 -6
  268. package/apps/studio/editing/declared-background.ts +25 -0
  269. package/apps/studio/editing/index.tsx +3 -0
  270. package/apps/studio/editing/object-keys.ts +4 -4
  271. package/apps/studio/editing/object-menu.tsx +13 -3
  272. package/apps/studio/editing/pen/points.tsx +61 -0
  273. package/apps/studio/editing/text-in-place.tsx +11 -0
  274. package/apps/studio/editing/video-frame-handle.tsx +425 -0
  275. package/apps/studio/exporters/capture-prepass.ts +374 -0
  276. package/apps/studio/exporters/degraded.ts +148 -0
  277. package/apps/studio/exporters/hub-render-door.ts +28 -2
  278. package/apps/studio/exporters/index.ts +3 -1
  279. package/apps/studio/exporters/job-budget.ts +93 -0
  280. package/apps/studio/exporters/jobs.ts +215 -28
  281. package/apps/studio/exporters/parity-check.ts +254 -0
  282. package/apps/studio/exporters/remote.ts +209 -15
  283. package/apps/studio/exporters/svg-inline.ts +87 -0
  284. package/apps/studio/exporters/video-render-lib.ts +88 -26
  285. package/apps/studio/exporters/video.ts +29 -6
  286. package/apps/studio/figma/assets.ts +58 -43
  287. package/apps/studio/figma/codegen-fonts.ts +100 -0
  288. package/apps/studio/figma/fig-decode.ts +390 -25
  289. package/apps/studio/figma/fig-kiwi.ts +18 -4
  290. package/apps/studio/figma/fig-vector.ts +59 -3
  291. package/apps/studio/figma/sanitize.ts +2 -0
  292. package/apps/studio/figma/style-map.ts +293 -48
  293. package/apps/studio/figma/to-artboard.ts +455 -69
  294. package/apps/studio/figma/to-strokes.ts +44 -11
  295. package/apps/studio/figma/types.ts +13 -0
  296. package/apps/studio/footage/schema.ts +3 -3
  297. package/apps/studio/generation/adapters/elevenlabs.ts +7 -1
  298. package/apps/studio/generation/adapters/groq.ts +8 -1
  299. package/apps/studio/generation/spend.ts +312 -0
  300. package/apps/studio/generation/types.ts +12 -0
  301. package/apps/studio/handoff/run.ts +1 -1
  302. package/apps/studio/handoff/targets.ts +2 -2
  303. package/apps/studio/handoff/write-scopes.ts +1 -1
  304. package/apps/studio/history/describe-annotations.ts +4 -0
  305. package/apps/studio/home/accounts.ts +30 -11
  306. package/apps/studio/home/cloud.ts +6 -1
  307. package/apps/studio/home/create-local.ts +32 -3
  308. package/apps/studio/home/hub-health.ts +76 -0
  309. package/apps/studio/home/routes.ts +15 -4
  310. package/apps/studio/http.ts +438 -86
  311. package/apps/studio/imported-module-ids.ts +91 -0
  312. package/apps/studio/inspect.ts +2 -0
  313. package/apps/studio/migrate/hub.ts +8 -1
  314. package/apps/studio/notifications.tsx +47 -5
  315. package/apps/studio/paths.ts +10 -1
  316. package/apps/studio/port.ts +3 -2
  317. package/apps/studio/preview/preview-camera.tsx +15 -382
  318. package/apps/studio/readiness.ts +10 -1
  319. package/apps/studio/release-build.ts +51 -0
  320. package/apps/studio/routes/agent.ts +188 -9
  321. package/apps/studio/routes/ai.ts +43 -11
  322. package/apps/studio/routes/annotations.ts +27 -1
  323. package/apps/studio/routes/assets.ts +18 -1
  324. package/apps/studio/routes/canvas-origin.ts +12 -9
  325. package/apps/studio/routes/cloud-move.ts +15 -0
  326. package/apps/studio/routes/edit.ts +3 -0
  327. package/apps/studio/routes/export.ts +51 -0
  328. package/apps/studio/routes/generate.ts +42 -12
  329. package/apps/studio/routes/hub-link-folder.ts +334 -0
  330. package/apps/studio/routes/hub-signin.ts +78 -1
  331. package/apps/studio/routes/index.ts +9 -1
  332. package/apps/studio/routes/shell.ts +217 -5
  333. package/apps/studio/routes/sync.ts +136 -8
  334. package/apps/studio/routes/votes.ts +2 -1
  335. package/apps/studio/schema/annotations.v2.schema.json +143 -1
  336. package/apps/studio/schema/beats.v1.schema.json +1 -1
  337. package/apps/studio/schema/edl.v1.schema.json +1 -1
  338. package/apps/studio/schema/formats.ts +3 -3
  339. package/apps/studio/schema/transcript.v1.schema.json +1 -1
  340. package/apps/studio/server.ts +142 -43
  341. package/apps/studio/shell/api-key.ts +503 -0
  342. package/apps/studio/shell/attest.ts +59 -0
  343. package/apps/studio/shell/capture-url.ts +20 -0
  344. package/apps/studio/shell/cli-yield.ts +276 -0
  345. package/apps/studio/shell/clip-transfer.ts +302 -0
  346. package/apps/studio/shell/key-file.ts +108 -0
  347. package/apps/studio/shell/server-json.ts +75 -0
  348. package/apps/studio/shell/worktree.ts +19 -0
  349. package/apps/studio/spoof-chars.ts +9 -0
  350. package/apps/studio/studio-page-host.ts +1 -1
  351. package/apps/studio/sync/accepted-cold-start.ts +144 -8
  352. package/apps/studio/sync/accepted-link.ts +76 -29
  353. package/apps/studio/sync/action-stage.ts +575 -44
  354. package/apps/studio/sync/adopt-held.ts +85 -0
  355. package/apps/studio/sync/ctl-heal.ts +58 -0
  356. package/apps/studio/sync/file-ledger.ts +38 -4
  357. package/apps/studio/sync/file-membership.ts +16 -1
  358. package/apps/studio/sync/file-plane.ts +289 -22
  359. package/apps/studio/sync/held-deletes.ts +86 -5
  360. package/apps/studio/sync/hub-link.ts +8 -0
  361. package/apps/studio/sync/index.ts +196 -12
  362. package/apps/studio/sync/journal-client.ts +50 -4
  363. package/apps/studio/sync/link-consent.ts +22 -75
  364. package/apps/studio/sync/link-survey.ts +252 -0
  365. package/apps/studio/sync/local-kernel.ts +296 -8
  366. package/apps/studio/sync/projection.ts +22 -3
  367. package/apps/studio/sync/seed-progress.ts +12 -0
  368. package/apps/studio/sync/source-recovery.ts +59 -3
  369. package/apps/studio/sync/status.ts +19 -2
  370. package/apps/studio/sync/unsynced-refs.ts +397 -0
  371. package/apps/studio/sync/writer-registry.ts +20 -0
  372. package/apps/studio/thumbs/service.ts +4 -1
  373. package/apps/studio/tool-palette.tsx +23 -0
  374. package/apps/studio/ui-prefs.ts +40 -0
  375. package/apps/studio/use-agent-presence.tsx +2 -2
  376. package/apps/studio/use-canvas-keys.ts +6 -1
  377. package/apps/studio/video/format-ids.ts +2 -2
  378. package/apps/studio/video/inject.ts +31 -0
  379. package/apps/studio/video/media-risk.ts +58 -0
  380. package/apps/studio/video/object-fit.ts +137 -0
  381. package/apps/studio/video/provider-transcript.ts +141 -0
  382. package/apps/studio/whats-new.json +137 -0
  383. package/apps/studio/workspace-mode.ts +1 -0
  384. package/apps/studio/ws.ts +5 -0
  385. package/cli/commands/design.mjs +119 -8
  386. package/cli/lib/bash-guard.mjs +366 -6
  387. package/cli/lib/confine-read.mjs +1 -0
  388. package/cli/lib/design-help.gen.mjs +3 -2
  389. package/cli/lib/design-hook.mjs +387 -81
  390. package/cli/lib/design-link.mjs +16 -1
  391. package/cli/lib/design-open.mjs +49 -3
  392. package/cli/lib/desktop-locate.mjs +770 -0
  393. package/cli/lib/handoff.mjs +1 -1
  394. package/cli/lib/hook-state.mjs +291 -0
  395. package/cli/lib/pkg-root.mjs +65 -13
  396. package/cli/lib/studio-locate.mjs +59 -16
  397. package/package.json +15 -8
  398. package/plugins/design/templates/_shell.html +13 -0
  399. package/apps/studio/client/v2/onboarding/HubSheet.jsx +0 -212
  400. package/apps/studio/client/v2/shell/account-card-model.js +0 -114
  401. package/apps/studio/client/v2/shell/account-card.jsx +0 -189
@@ -33,6 +33,8 @@ import {
33
33
  openTeamServerSignIn,
34
34
  } from '../github.js';
35
35
  import { reasonProps } from '../v2/access/disabled-reason.js';
36
+ import { projectLinkApi } from '../v2/link-server/link-server-api.js';
37
+ import { LinkServerDialog } from '../v2/link-server/LinkServerDialog.jsx';
36
38
  import { SIGNIN_WORDS } from '../v2/signin/signin-model.js';
37
39
 
38
40
  const api = async (path, init) => {
@@ -149,10 +151,9 @@ function ErrorLine({ text }) {
149
151
  );
150
152
  }
151
153
 
152
- // `serverOnly` (V2-4.7a): Settings › Connections › “Add a team server…” opens just the address +
153
- // Sign in (issue #204: the server's own page signs you in) — the recents and the cloud list have their own homes. The same form,
154
- // the same handler, the same consent path (opening a project still goes through the switch).
155
- export default function TeamProjects({ variant = 'door', initialServer = '', serverOnly = false }) {
154
+ // 2.1.1 T5: Settings' “Add a team server…” (the old `serverOnly` form) is the one "Link your server" dialog
155
+ // now (v2/link-server/) — `TeamProjectsDialog serverOnly` hands over to it below.
156
+ export default function TeamProjects({ variant = 'door', initialServer = '' }) {
156
157
  const [recents, setRecents] = useState(null);
157
158
  const [cloud, setCloud] = useState({
158
159
  state: 'loading',
@@ -367,7 +368,7 @@ export default function TeamProjects({ variant = 'door', initialServer = '', ser
367
368
  </div>
368
369
  )}
369
370
 
370
- {!serverOnly && recents && recents.length > 0 && (
371
+ {recents && recents.length > 0 && (
371
372
  <section className="tp-section" aria-label="Recent team projects">
372
373
  <div className="ob-section-label">On this computer</div>
373
374
  <div className="ob-repolist">
@@ -405,142 +406,140 @@ export default function TeamProjects({ variant = 'door', initialServer = '', ser
405
406
  </section>
406
407
  )}
407
408
 
408
- {!serverOnly && (
409
- <section className="tp-section" aria-label="Maude Cloud">
410
- <div className="ob-section-label">Maude Cloud</div>
411
- {cloud.state === 'loading' && <div className="ob-foot-note">Checking your sign-in…</div>}
412
- {cloud.state === 'out' && !device && (
413
- <button
414
- type="button"
415
- className="ob-repo"
416
- onClick={startCloudSignIn}
417
- data-testid="team-cloud-signin"
418
- >
419
- <span className="ob-repo-icon">
420
- <Spark size={15} />
409
+ <section className="tp-section" aria-label="Maude Cloud">
410
+ <div className="ob-section-label">Maude Cloud</div>
411
+ {cloud.state === 'loading' && <div className="ob-foot-note">Checking your sign-in…</div>}
412
+ {cloud.state === 'out' && !device && (
413
+ <button
414
+ type="button"
415
+ className="ob-repo"
416
+ onClick={startCloudSignIn}
417
+ data-testid="team-cloud-signin"
418
+ >
419
+ <span className="ob-repo-icon">
420
+ <Spark size={15} />
421
+ </span>
422
+ <span className="ob-repo-tx">
423
+ <span className="ob-repo-name">Sign in to Maude Cloud</span>
424
+ <span className="ob-repo-meta">See the projects you were invited to</span>
425
+ </span>
426
+ <span className="ob-repo-go">
427
+ <Icon name="arrow-right" size={15} /> Sign in
428
+ </span>
429
+ </button>
430
+ )}
431
+ {device && (
432
+ <div className="tp-device" data-testid="team-cloud-device">
433
+ <span className="ob-field-label">{SIGNIN_WORDS.codeCheck}</span>
434
+ <div className="gi-code">
435
+ <span className="gi-code-val" data-testid="team-cloud-code">
436
+ {device.userCode}
421
437
  </span>
422
- <span className="ob-repo-tx">
423
- <span className="ob-repo-name">Sign in to Maude Cloud</span>
424
- <span className="ob-repo-meta">See the projects you were invited to</span>
438
+ <button
439
+ type="button"
440
+ className="btn btn--ghost gi-code-copy"
441
+ onClick={() =>
442
+ navigator.clipboard?.writeText(device.userCode).then(
443
+ () => {
444
+ setCopied(true);
445
+ setTimeout(() => setCopied(false), 1500);
446
+ },
447
+ () => {}
448
+ )
449
+ }
450
+ aria-label="Copy the code"
451
+ >
452
+ <Icon name="copy" size={15} /> {copied ? 'Copied' : 'Copy'}
453
+ </button>
454
+ </div>
455
+ {device.verificationUrl && isDisplayableUrl(device.verificationUrl, cloud.url) && (
456
+ <span className="ob-foot-note">
457
+ If your browser didn’t open, go to{' '}
458
+ <span className="gi-dc-url">{device.verificationUrl}</span>
425
459
  </span>
426
- <span className="ob-repo-go">
427
- <Icon name="arrow-right" size={15} /> Sign in
460
+ )}
461
+ <div className="ob-form-actions">
462
+ <span className="gi-dc-status" aria-live="polite">
463
+ <span className="gi-pulse" aria-hidden="true" /> Waiting for you to confirm…
428
464
  </span>
429
- </button>
430
- )}
431
- {device && (
432
- <div className="tp-device" data-testid="team-cloud-device">
433
- <span className="ob-field-label">{SIGNIN_WORDS.codeCheck}</span>
434
- <div className="gi-code">
435
- <span className="gi-code-val" data-testid="team-cloud-code">
436
- {device.userCode}
437
- </span>
438
- <button
439
- type="button"
440
- className="btn btn--ghost gi-code-copy"
441
- onClick={() =>
442
- navigator.clipboard?.writeText(device.userCode).then(
443
- () => {
444
- setCopied(true);
445
- setTimeout(() => setCopied(false), 1500);
446
- },
447
- () => {}
448
- )
449
- }
450
- aria-label="Copy the code"
451
- >
452
- <Icon name="copy" size={15} /> {copied ? 'Copied' : 'Copy'}
453
- </button>
454
- </div>
455
- {device.verificationUrl && isDisplayableUrl(device.verificationUrl, cloud.url) && (
456
- <span className="ob-foot-note">
457
- If your browser didn’t open, go to{' '}
458
- <span className="gi-dc-url">{device.verificationUrl}</span>
459
- </span>
460
- )}
461
- <div className="ob-form-actions">
462
- <span className="gi-dc-status" aria-live="polite">
463
- <span className="gi-pulse" aria-hidden="true" /> Waiting for you to confirm…
464
- </span>
465
- <button type="button" className="btn btn--ghost" onClick={cancelCloudSignIn}>
466
- Cancel
467
- </button>
468
- </div>
465
+ <button type="button" className="btn btn--ghost" onClick={cancelCloudSignIn}>
466
+ Cancel
467
+ </button>
469
468
  </div>
470
- )}
471
- {cloud.state === 'in' && (
472
- <>
473
- {projects === null && <div className="ob-foot-note">Loading your projects…</div>}
474
- {Array.isArray(projects) && projects.length === 0 && (
475
- <div className="ob-foot-note" data-testid="team-cloud-empty">
476
- You aren’t in any project yet. Ask whoever runs your team’s project to invite{' '}
477
- {cloud.email || 'you'}.
478
- </div>
479
- )}
480
- {Array.isArray(projects) && projects.length > 0 && (
481
- <div className="ob-repolist">
482
- {projects.map((p) => {
483
- const k = `cloud:${p.id}`;
484
- if (p.role === 'viewer') {
485
- return (
486
- <button
487
- type="button"
488
- key={p.id}
489
- className="ob-repo"
490
- onClick={() => openExternal(shareViewUrl(p.url, p.id))}
491
- data-testid={`team-cloud-project-${p.id}`}
492
- title="Viewing works in the browser. Editing in the app needs the member role — ask whoever runs the project."
493
- >
494
- <span className="ob-repo-icon">
495
- <Icon name="globe" size={15} />
496
- </span>
497
- <span className="ob-repo-tx">
498
- <span className="ob-repo-name">{p.name || p.id}</span>
499
- <span className="ob-repo-meta">viewer · opens in your browser</span>
500
- </span>
501
- <span className="ob-repo-go">
502
- <Icon name="external" size={15} /> View
503
- </span>
504
- </button>
505
- );
506
- }
469
+ </div>
470
+ )}
471
+ {cloud.state === 'in' && (
472
+ <>
473
+ {projects === null && <div className="ob-foot-note">Loading your projects…</div>}
474
+ {Array.isArray(projects) && projects.length === 0 && (
475
+ <div className="ob-foot-note" data-testid="team-cloud-empty">
476
+ You aren’t in any project yet. Ask whoever runs your team’s project to invite{' '}
477
+ {cloud.email || 'you'}.
478
+ </div>
479
+ )}
480
+ {Array.isArray(projects) && projects.length > 0 && (
481
+ <div className="ob-repolist">
482
+ {projects.map((p) => {
483
+ const k = `cloud:${p.id}`;
484
+ if (p.role === 'viewer') {
507
485
  return (
508
486
  <button
509
487
  type="button"
510
488
  key={p.id}
511
489
  className="ob-repo"
512
- disabled={!!busy}
513
- onClick={() => openCloud(p)}
490
+ onClick={() => openExternal(shareViewUrl(p.url, p.id))}
514
491
  data-testid={`team-cloud-project-${p.id}`}
492
+ title="Viewing works in the browser. Editing in the app needs the member role — ask whoever runs the project."
515
493
  >
516
494
  <span className="ob-repo-icon">
517
- <Spark size={15} />
495
+ <Icon name="globe" size={15} />
518
496
  </span>
519
497
  <span className="ob-repo-tx">
520
498
  <span className="ob-repo-name">{p.name || p.id}</span>
521
- <span className="ob-repo-meta">
522
- {p.role}
523
- {p.stateLabel ? ` · ${p.stateLabel}` : ''}
524
- </span>
499
+ <span className="ob-repo-meta">viewer · opens in your browser</span>
525
500
  </span>
526
501
  <span className="ob-repo-go">
527
- {busy === k ? (
528
- <Icon name="spinner" size={16} className="ob-spin" />
529
- ) : (
530
- <>
531
- <Icon name="arrow-right" size={15} /> Open
532
- </>
533
- )}
502
+ <Icon name="external" size={15} /> View
534
503
  </span>
535
504
  </button>
536
505
  );
537
- })}
538
- </div>
539
- )}
540
- </>
541
- )}
542
- </section>
543
- )}
506
+ }
507
+ return (
508
+ <button
509
+ type="button"
510
+ key={p.id}
511
+ className="ob-repo"
512
+ disabled={!!busy}
513
+ onClick={() => openCloud(p)}
514
+ data-testid={`team-cloud-project-${p.id}`}
515
+ >
516
+ <span className="ob-repo-icon">
517
+ <Spark size={15} />
518
+ </span>
519
+ <span className="ob-repo-tx">
520
+ <span className="ob-repo-name">{p.name || p.id}</span>
521
+ <span className="ob-repo-meta">
522
+ {p.role}
523
+ {p.stateLabel ? ` · ${p.stateLabel}` : ''}
524
+ </span>
525
+ </span>
526
+ <span className="ob-repo-go">
527
+ {busy === k ? (
528
+ <Icon name="spinner" size={16} className="ob-spin" />
529
+ ) : (
530
+ <>
531
+ <Icon name="arrow-right" size={15} /> Open
532
+ </>
533
+ )}
534
+ </span>
535
+ </button>
536
+ );
537
+ })}
538
+ </div>
539
+ )}
540
+ </>
541
+ )}
542
+ </section>
544
543
 
545
544
  <section className="tp-section" aria-label="Your team's server">
546
545
  <div className="ob-section-label">Your team’s own server</div>
@@ -622,13 +621,21 @@ export default function TeamProjects({ variant = 'door', initialServer = '', ser
622
621
  );
623
622
  }
624
623
 
625
- /** The same picker as a dialog — from the project switcher. */
626
- export function TeamProjectsDialog({
627
- onClose,
628
- initialServer = '',
629
- title = 'Open a team project',
630
- serverOnly = false,
631
- }) {
624
+ /** The same picker as a dialog — from the project switcher. `serverOnly` (Settings' “Add a team server…”)
625
+ * is the one "Link your server" dialog since 2.1.1 T5. */
626
+ export function TeamProjectsDialog(props) {
627
+ if (props.serverOnly)
628
+ return (
629
+ <LinkServerDialog
630
+ api={projectLinkApi()}
631
+ initialUrl={props.initialServer || ''}
632
+ onClose={props.onClose}
633
+ />
634
+ );
635
+ return <TeamProjectsPicker {...props} />;
636
+ }
637
+
638
+ function TeamProjectsPicker({ onClose, initialServer = '', title = 'Open a team project' }) {
632
639
  const ref = useRef(null);
633
640
  useEffect(() => {
634
641
  const prev = document.activeElement;
@@ -649,11 +656,7 @@ export function TeamProjectsDialog({
649
656
  <div className="tp-dialog-head">
650
657
  <div>
651
658
  <h2 id="tp-dialog-title">{title}</h2>
652
- <p>
653
- {serverOnly
654
- ? 'Sign in to your team’s own server. Its projects open in their own copy on this computer.'
655
- : 'Projects you were added to open in their own copy on this computer.'}
656
- </p>
659
+ <p>Projects you were added to open in their own copy on this computer.</p>
657
660
  </div>
658
661
  <button
659
662
  type="button"
@@ -665,7 +668,7 @@ export function TeamProjectsDialog({
665
668
  <Icon name="x" size={14} />
666
669
  </button>
667
670
  </div>
668
- <TeamProjects variant="dialog" initialServer={initialServer} serverOnly={serverOnly} />
671
+ <TeamProjects variant="dialog" initialServer={initialServer} />
669
672
  </div>
670
673
  </div>
671
674
  );
@@ -178,6 +178,8 @@ export function buildChatContext({ canvas, selected, scope } = {}) {
178
178
  count: els.length,
179
179
  stale,
180
180
  runScope: runScopeOf({ canvas, scope }),
181
+ // the canvas this send froze on (the offer card's "Put them in a section" scopes to it when the ask had no stickies)
182
+ canvas,
181
183
  // S4.15 — the stickies this ask is about, for the offer card's validation (client/v2/ai/ai-offer.js)
182
184
  ...(scope?.kind === 'annotations' && Array.isArray(scope.ids) && scope.ids.length
183
185
  ? {
@@ -1,4 +1,4 @@
1
- // GENERATED by scripts/gen-plugin-surfaces.mjs from plugins/design/commands/*.md frontmatter
1
+ // GENERATED by scripts/gen-plugin-surfaces.mjs from plugins/{design,design-video}/commands/*.md
2
2
  // — DO NOT EDIT BY HAND. Run: node scripts/gen-plugin-surfaces.mjs
3
3
  // `name` is Claude Code's canonical slash form (`<plugin>:<verb>`). `argHint` is the command's
4
4
  // `argument-hint`, cut to whole groups within 48 characters.
@@ -110,12 +110,6 @@ export const STATIC_COMMANDS = [
110
110
  'Set the order, skipped artboards and speaker notes for Present, then open the canvas in Present.',
111
111
  argHint: '<canvas> [--order a,b,c] [--skip x,y] …',
112
112
  },
113
- {
114
- name: 'design:reel',
115
- description:
116
- 'Analyze raw footage and create a directed video cut with graphics, audio and captions.',
117
- argHint: '<Name> [<folder-path>] "<brief>" [--from-canvas] …',
118
- },
119
113
  {
120
114
  name: 'design:rollback',
121
115
  description: 'Go back to an earlier version of the active canvas, from Version history.',
@@ -146,11 +140,6 @@ export const STATIC_COMMANDS = [
146
140
  description:
147
141
  "Work with the project's design systems: where each stands, the default for new canvases, switching canvases, outside changes, moving a system folder onto its Design system canvas, importing tokens.",
148
142
  },
149
- {
150
- name: 'design:to-lottie',
151
- description: 'Export animation keyframes to a verified Lottie artifact for web and mobile.',
152
- argHint: '"<animated mark | IR handle | canvas>" …',
153
- },
154
143
  {
155
144
  name: 'design:to-rn',
156
145
  description: 'Create a React Native SVG animation fallback for light motion.',
@@ -163,7 +152,18 @@ export const STATIC_COMMANDS = [
163
152
  argHint: '[list | move <canvas> | restore <id | canvas>]',
164
153
  },
165
154
  {
166
- name: 'design:video-analyze',
155
+ name: 'design-video:reel',
156
+ description:
157
+ 'Analyze raw footage and create a directed video cut with graphics, audio and captions.',
158
+ argHint: '<Name> [<folder-path>] "<brief>" [--from-canvas] …',
159
+ },
160
+ {
161
+ name: 'design-video:to-lottie',
162
+ description: 'Export animation keyframes to a verified Lottie artifact for web and mobile.',
163
+ argHint: '"<animated mark | IR handle | canvas>" …',
164
+ },
165
+ {
166
+ name: 'design-video:video-analyze',
167
167
  description:
168
168
  'Analyze video picture and sound using scene-aware keyframes and audio transcription.',
169
169
  argHint: '<clip|folder> [--from-canvas] …',
@@ -149,22 +149,29 @@ export function restoreAfterLoad(selected, file) {
149
149
  /**
150
150
  * S2.25 G1 — the key a rename is kept under: a write may give a text an authored name (`data-cd-id="jedeme-v-zelenem"`
151
151
  * for what was the content-hash id `42612cfe`), after which the id the shell holds names nothing in the canvas.
152
+ * Keyed by the CANVAS too: content-hash ids are structural, so two canvases built alike share them, and a name
153
+ * written on one canvas sent every later restore on the other to an id it does not have — the canvas resolved
154
+ * nothing, never re-sent its selection, and the inspector kept the values from before a teammate's restore
155
+ * (surface rows L18.history.preview-restore, 2026-11-08).
152
156
  */
153
- export const renameKey = (artboardId, id) => `${artboardId ?? ''}\u0000${id}`;
154
- /** The id `id` was renamed to by a write, or `id` itself. */
155
- const renamedId = (renames, artboardId, id) => renames?.get(renameKey(artboardId, id)) ?? id;
157
+ export const renameKey = (file, artboardId, id) =>
158
+ `${file ?? ''}\u0000${artboardId ?? ''}\u0000${id}`;
159
+ /** The id `id` on `file` was renamed to by a write, or `id` itself. */
160
+ const renamedId = (renames, file, artboardId, id) =>
161
+ renames?.get(renameKey(file, artboardId, id)) ?? id;
156
162
 
157
163
  /**
158
- * S2.25 G1 — what a successful edit-op renamed: its `targets` against the `refs` it answered with ("the targets as
159
- * written: same order, every element an authored id"), as `[renameKey, newId]` pairs. Only the ids that differ.
164
+ * S2.25 G1 — what a successful edit-op on `file` renamed: its `targets` against the `refs` it answered with ("the
165
+ * targets as written: same order, every element an authored id"), as `[renameKey, newId]` pairs. Only the ids
166
+ * that differ.
160
167
  */
161
- export function renamesOf(targets, refs) {
168
+ export function renamesOf(file, targets, refs) {
162
169
  const out = [];
163
- if (!Array.isArray(targets) || !Array.isArray(refs)) return out;
170
+ if (!file || !Array.isArray(targets) || !Array.isArray(refs)) return out;
164
171
  targets.forEach((t, i) => {
165
172
  const r = refs[i];
166
173
  if (t?.element && r?.element && t.element !== r.element)
167
- out.push([renameKey(t.artboard, t.element), r.element]);
174
+ out.push([renameKey(file, t.artboard, t.element), r.element]);
168
175
  });
169
176
  return out;
170
177
  }
@@ -183,7 +190,7 @@ export function restorePostOf(selected, file, renames, now = Date.now()) {
183
190
  }
184
191
  return {
185
192
  dgn: 'select-by-id',
186
- id: renamedId(renames, back.sel.artboardId, back.sel.id),
193
+ id: renamedId(renames, file, back.sel.artboardId, back.sel.id),
187
194
  artboardId: back.sel.artboardId ?? null,
188
195
  index: back.sel.index ?? 0,
189
196
  };
@@ -14,6 +14,18 @@ export function normalizeOpenPath(raw, designRel = '.design') {
14
14
  return rel.split('/').some((s) => s === '' || s === '.' || s === '..') ? null : rel;
15
15
  }
16
16
 
17
+ /**
18
+ * What the Share sheet opens on: the canvas at `path`, or — with no canvas — nothing, unless the ask is about the
19
+ * PROJECT (`{ project: true }`: Move to Maude Cloud, Connect), which gets the project's own sheet (2.1.1 T7: from
20
+ * Diagnostics › Sync with no canvas open, "Create project on Maude Cloud" did nothing).
21
+ * @returns {{ path: string, rel: string|null, label: string } | null}
22
+ */
23
+ export function shareTargetFor(path, designRel = '.design', opts = {}) {
24
+ const rel = normalizeOpenPath(path, designRel);
25
+ if (rel) return { path, rel, label: path.split('/').pop() || path };
26
+ return opts?.project ? { path: '', rel: null, label: '' } : null;
27
+ }
28
+
17
29
  /** Decode a URL value exactly once, then validate. */
18
30
  export function normalizeOpenParam(raw, designRel = '.design') {
19
31
  if (typeof raw !== 'string') return null;
@@ -38,6 +38,9 @@ import { crashGuard, subscribeCrashGuard } from '../v2/shell/canvas-crash-guard.
38
38
  import { TooHeavyCanvas } from '../v2/shell/too-heavy-card.jsx';
39
39
  import { OpeningSkeleton } from '../v2/shell/opening-skeleton.jsx';
40
40
 
41
+ // The canvas frame's own geometry (#169 item 4): the `.viewport > iframe` rule, restated on the element.
42
+ const FRAME_STYLE = { position: 'absolute', inset: 0, width: '100%', height: '100%', border: 0 };
43
+
41
44
  export function Viewport({
42
45
  tabs,
43
46
  activePath,
@@ -285,6 +288,14 @@ export function Viewport({
285
288
  }}
286
289
  src={stableSrc(t.path)}
287
290
  title={`Canvas: ${t.path}`}
291
+ // #169 item 4 — the frame carries its own size, so its first layout is the stage size even if the
292
+ // shell stylesheet (`.viewport > iframe`, in `@layer shell`) has not applied yet: without it the
293
+ // browser lays the frame out at the 300x150 iframe default plus the 2px default border (304x154).
294
+ // Same values as the rule; `display` stays with the stylesheet (it tracks `.active`).
295
+ width="100%"
296
+ height="100%"
297
+ frameBorder="0"
298
+ style={FRAME_STYLE}
288
299
  className={t.path === activePath ? 'active' : ''}
289
300
  data-path={t.path}
290
301
  data-testid={t.path === activePath ? 'canvas-frame' : undefined}
@@ -312,7 +323,6 @@ export function Viewport({
312
323
  role,
313
324
  viewing,
314
325
  canvasTab,
315
- dsPreview,
316
326
  })}
317
327
  />
318
328
  )}
@@ -10,6 +10,8 @@
10
10
  // + "Opened from <name>'s link — <canvas>.")
11
11
  // shell://opened-existing {name} toast "<name> is open in this window."
12
12
  // shell://tabs-restored {count} toast "<count> tabs reopened. Each one starts when you open it."
13
+ // shell://branch-changed {was, now} #206 §6: toast "This folder switched from <was> to <now>." (a terminal
14
+ // asked for this tab after a `git checkout` under it)
13
15
  // take_link_opened {name} toast "Opened <name> from a link." (a link opened this NEW tab)
14
16
  //
15
17
  // Rust emits tabs-restored while the restored front tab is still on its splash, before this page
@@ -74,6 +76,7 @@ export function invitedByAuthor(from, author) {
74
76
 
75
77
  export const openedExistingWords = (name) => `${name} is open in this window.`;
76
78
  export const linkOpenedWords = (name) => `Opened ${name} from a link.`;
79
+ export const branchChangedWords = (was, now) => `This folder switched from ${was} to ${now}.`;
77
80
  export const tabsRestoredWords = (count) =>
78
81
  `${count} tabs reopened. Each one starts when you open it.`;
79
82
 
@@ -216,6 +219,11 @@ export function startShellEvents({ invoke, listen, toast, onNavigate }) {
216
219
  });
217
220
  sub('shell://tabs-restored', restored);
218
221
  sub('shell://navigate', navigate);
222
+ sub('shell://branch-changed', (p) => {
223
+ const was = cleanName(p?.was);
224
+ const now = cleanName(p?.now);
225
+ if (alive && was && now) toast(branchChangedWords(was, now), true, undefined, TOP_PILL);
226
+ });
219
227
  const linkOpened = (p) => {
220
228
  const name = cleanName(p?.name);
221
229
  if (alive && name) toast(linkOpenedWords(name), true, undefined, LINK_PILL);
@@ -238,6 +238,22 @@
238
238
  gap: 2px;
239
239
  padding: var(--space-1) var(--space-1) 2px;
240
240
  }
241
+ /* #170 R29: the body eases open (it mounts on open, so this runs once per opening) instead of snapping in */
242
+ @media (prefers-reduced-motion: no-preference) {
243
+ :where(.maude) .k-adv-body {
244
+ animation: k-adv-open var(--dur-soft) var(--ease-out);
245
+ }
246
+ }
247
+ @keyframes k-adv-open {
248
+ from {
249
+ opacity: 0;
250
+ transform: translateY(-4px);
251
+ }
252
+ to {
253
+ opacity: 1;
254
+ transform: none;
255
+ }
256
+ }
241
257
 
242
258
  /* ─── Switch (_components.css .switch) — Phase 8 C1-kit: ONE switch ───
243
259
  The shell had four (Canvases `.lp-switch` 30×18 with an fg-0 knob — black in light; Settings
@@ -64,6 +64,8 @@
64
64
  @import url("../v2/present/video-present.css");
65
65
  /* V2-4.3a — the Share cluster, top-right. */
66
66
  @import url("../v2/shell/share-cluster.css");
67
+ /* 2.1.1 T2/T4 — the account chip face, the avatar menu and Switch account. */
68
+ @import url("../v2/shell/project-account.css");
67
69
  /* S3.9 - Preview's own islands: the PreviewBar and the zoom readout. */
68
70
  @import url("../v2/preview/preview.css");
69
71
  /* S8.2 — the Export sheet (client/v2/export/). */
@@ -184,6 +186,8 @@
184
186
  @import url("../v2/signin/signin.css");
185
187
  /* S6.9 — the five Advanced sheets: hub, folder or GitHub, Connect AI, the maude command, Figma (client/v2/onboarding/). */
186
188
  @import url("../v2/onboarding/onboarding.css");
189
+ /* 2.1.1 T5 — the one "Link your server" dialog (client/v2/link-server/). */
190
+ @import url("../v2/link-server/link-server.css");
187
191
  @import url("./5-utilities.css");
188
192
  /* S3.7a — the Present follower page (follow bar, Live, watching; the audience window has no chrome). */
189
193
  @import url("../v2/present/follow.css");
@@ -504,7 +504,7 @@ export function ContinuationBubble({ parts: rawParts, viewMode }) {
504
504
  verbose={forceExpand}
505
505
  />
506
506
  ) : g.part?.type === 'text' ? (
507
- <ChatText key={`t-${i}`} text={g.part.text} />
507
+ <ChatText key={`t-${i}`} text={stripOffer(g.part.text)} />
508
508
  ) : g.part?.type === 'reasoning' ? (
509
509
  <ChatReasoning key={`r-${i}`} text={g.part.text} />
510
510
  ) : g.part?.type === 'tool-call' ? (
@@ -14,6 +14,7 @@ import { useEffect, useMemo, useSyncExternalStore } from 'react';
14
14
  import { Spark } from './icons.jsx';
15
15
  import {
16
16
  askedAnnotations,
17
+ askedCanvas,
17
18
  OFFER_WORDS,
18
19
  parseOffer,
19
20
  seenTargetsFor,
@@ -83,6 +84,26 @@ export function acceptOffer({ offer, ask, send = sendAskSelection, mode = shellM
83
84
  return !!sent;
84
85
  }
85
86
 
87
+ /**
88
+ * "Put them in a section" (15 an-ai-write): the notes AI just wrote, gathered into one section. The same send
89
+ * path as "Make these changes", with those notes as the scope; the design is not touched, so the shell stays in
90
+ * Preview. Fewer than two notes have nothing to gather.
91
+ */
92
+ export function putInSection({ offer, ask, send = sendAskSelection, sentFrom = askedCanvas() }) {
93
+ const wrote = Array.isArray(offer?.wrote) ? offer.wrote : [];
94
+ if (wrote.length < 2) return false;
95
+ return !!send({
96
+ text: OFFER_WORDS.section,
97
+ scope: annotationsScope({
98
+ // a review asked with no selection has no `ask`: the canvas the turn was sent from (frozen) stands in
99
+ file: ask?.file ?? sentFrom ?? undefined,
100
+ ids: wrote,
101
+ artboards: ask?.artboards,
102
+ kinds: { sticky: wrote.length },
103
+ }),
104
+ });
105
+ }
106
+
86
107
  export function OfferSlot({ parts, status }) {
87
108
  const id = useMessage((m) => m.id);
88
109
  const latestId = useThread((t) => t.messages[t.messages.length - 1]?.id);
@@ -117,6 +138,9 @@ export function OfferSlot({ parts, status }) {
117
138
  const make = () => {
118
139
  if (acceptOffer({ offer, ask })) fold(id);
119
140
  };
141
+ const gather = () => {
142
+ if (putInSection({ offer, ask })) fold(id);
143
+ };
120
144
  const leaves = leavesLine(offer.leaves.length);
121
145
  return (
122
146
  // biome-ignore lint/a11y/useSemanticElements: a labelled card of offers, not a form fieldset — a fieldset would bring its own border and min-width
@@ -151,6 +175,16 @@ export function OfferSlot({ parts, status }) {
151
175
  >
152
176
  {OFFER_WORDS.secondary}
153
177
  </button>
178
+ {offer.wrote?.length > 1 ? (
179
+ <button
180
+ type="button"
181
+ className="btn btn--sm"
182
+ data-testid="ai-offer-section"
183
+ onClick={gather}
184
+ >
185
+ {OFFER_WORDS.section}
186
+ </button>
187
+ ) : null}
154
188
  <button
155
189
  type="button"
156
190
  className="btn btn--sm btn--primary"