@dev.fast/whiteboard 0.3.5-preview.20261023.136 → 0.4.1-preview.20261026.137

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 (58) hide show
  1. package/dist/{account-alias-2yTAxoBx.js → account-alias-BpH8VvTR.js} +2 -2
  2. package/dist/agent-cli-DFWrNoGJ.js +2 -0
  3. package/dist/{agent-cli-CHNDd4Ga.js → agent-cli-DckMzOU_.js} +6 -6
  4. package/dist/{agent-client-Dc0vHFJt.js → agent-client-D4FSEDX4.js} +3 -3
  5. package/dist/{authoring-tools-D8EkIDjm.js → authoring-tools-DmIJZq0b.js} +21 -8
  6. package/dist/{background-server-DHWHzpo5.js → background-server-B1uwDQTr.js} +2 -2
  7. package/dist/{background-server-DyWnPJyZ.js → background-server-BPZ3GQan.js} +1 -1
  8. package/dist/build-info.json +1 -1
  9. package/dist/{cli-runner-DFBaVGij.js → cli-runner-DVEDbjXo.js} +17 -17
  10. package/dist/{cli-qZomwJmK.js → cli-tWBQpq27.js} +1 -1
  11. package/dist/cli.js +2 -2
  12. package/dist/{client-p9WB8Sj0.js → client-C8vT0mhW.js} +3 -3
  13. package/dist/{fuzzy-match-CfSxqzBF.js → fuzzy-match-BNLXmpbv.js} +2 -2
  14. package/dist/{headless-host-dwlqhqMY.js → headless-host-B63e2z2j.js} +1 -1
  15. package/dist/{headless-host-DJhcab6r.js → headless-host-Dl9g9Fvd.js} +37 -17
  16. package/dist/{lens-selection-9byzEgvU.js → lens-selection-EuZdag4Q.js} +1 -1
  17. package/dist/{local-data-DHedfhxw.js → local-data-C0OJttzT.js} +92 -63
  18. package/dist/{mcp-Br-r_wwR.js → mcp-D74cFQNM.js} +17 -8
  19. package/dist/profile-CAn8Qdeh.js +2 -0
  20. package/dist/{profile-D9wdlPgw.js → profile-DS1F6PBF.js} +1 -1
  21. package/dist/{remote-attach-DSGpTOJ4.js → remote-attach-DTByuwBs.js} +3 -3
  22. package/dist/{remote-language-server-Dx13Mg2m.js → remote-language-server-DQfg07BB.js} +1 -1
  23. package/dist/{remote-uninstall-Dp2o3qz0.js → remote-uninstall-aXApHJPy.js} +3 -3
  24. package/dist/{request-origin-CNSLVn7x.js → request-origin-BIBW432J.js} +12 -3
  25. package/dist/{review-app-launcher-BZAnR8Vp.js → review-app-launcher-Brn60fPu.js} +2 -2
  26. package/dist/{review-telemetry-BM-_KdLi.js → review-telemetry-ChlsTRPN.js} +2 -2
  27. package/dist/server/desktop-host.js +44 -10
  28. package/dist/{server-discovery-DKLIOgg3.js → server-discovery-BchUrwFW.js} +1 -1
  29. package/dist/sharing/index.d.ts +53 -3
  30. package/dist/sharing/index.js +1 -1
  31. package/dist/{src-DYHVzX3b.js → src-DEOc8bvC.js} +63 -2
  32. package/dist/{stored-document-migration-DEt8iwem.js → stored-document-migration-BCFx07Bq.js} +52 -11
  33. package/dist/{thread-state-CO97FUqK.js → thread-state-CbLB0jUA.js} +1 -1
  34. package/dist/{tool-failure-C1L1vJyz.js → tool-failure-DlU9hn7_.js} +2 -2
  35. package/instructions/animation.md +345 -0
  36. package/instructions/authoring.md +2 -2
  37. package/package.json +5 -5
  38. package/src/fixtures/blocks/animation.json +19 -0
  39. package/src/review-api/authoring-tools.ts +17 -6
  40. package/src/review-api/blocks/animation.ts +98 -0
  41. package/src/review-api/blocks/index.ts +3 -0
  42. package/src/review-api/blocks/sequence.ts +3 -1
  43. package/src/review-api/comparison-coverage.ts +120 -89
  44. package/src/review-api/component-reference.ts +16 -0
  45. package/src/review-api/document-text.ts +11 -0
  46. package/src/review-api/document.ts +26 -5
  47. package/src/review-api/http.ts +31 -2
  48. package/src/review-api/instructions.ts +11 -2
  49. package/src/review-api/local-data.ts +21 -4
  50. package/src/review-api/mcp.ts +22 -14
  51. package/src/review-preferences.ts +43 -0
  52. package/src/server/desktop-server.ts +24 -0
  53. package/src/server/review-server-core.ts +2 -0
  54. package/src/server/structural-comparisons.ts +5 -11
  55. package/src/server/structural-diff.ts +8 -2
  56. package/src/ui-telemetry-events.ts +9 -0
  57. package/dist/agent-cli-Cn4-16XA.js +0 -2
  58. package/dist/profile-BopGMZUh.js +0 -2
@@ -1,11 +1,11 @@
1
1
  import { n as isJsonObject } from "./src-X9phtB2j.js";
2
- import { E as ReviewCliInstallStampSchema } from "./src-DYHVzX3b.js";
2
+ import { E as ReviewCliInstallStampSchema } from "./src-DEOc8bvC.js";
3
3
  import { G as removeAgentTraceHook, H as AGENT_TRACE_HOOK_AGENTS, I as disableAllTraceRepositories, L as enableTraceRepository, Q as readStoreAuth, R as listTraceRepositoryRoots, U as describeTraceHookOwners, W as installHarnessHooks, Y as traceScope, g as disableTraceMachine, h as configureTraceMachine, rt as StoreClient, v as traceMachineEnabled, y as traceMachineStatus, z as traceRepositoryStatus } from "./src-Z1x4-Qmb.js";
4
4
  import { I as writeFileAtomicAsync, L as writePrivateJsonAtomic, N as devReviewHome, j as withFileLock } from "./s3-config-CjcLyFV5.js";
5
5
  import { i as readReviewPackageVersion } from "./package-paths-BeYHYjeR.js";
6
6
  import { n as reviewDesktopStateDir } from "./review-home-paths-CG-sb9Cw.js";
7
7
  import { n as isFile, t as isDirectory } from "./fs-utils-BMPLt0cr.js";
8
- import { c as findExecutable, s as executableCommand } from "./fuzzy-match-CfSxqzBF.js";
8
+ import { c as findExecutable, s as executableCommand } from "./fuzzy-match-BNLXmpbv.js";
9
9
  import { createHash } from "node:crypto";
10
10
  import { constants } from "node:fs";
11
11
  import { access, chmod, lstat, mkdir, readFile, rm, stat, writeFile } from "node:fs/promises";
@@ -0,0 +1,2 @@
1
+ import { n as runReviewAgentCli } from "./agent-cli-DckMzOU_.js";
2
+ export { runReviewAgentCli };
@@ -1,13 +1,13 @@
1
1
  import { n as isJsonObject, u as parseJsonText } from "./src-X9phtB2j.js";
2
2
  import { v as traceMachineEnabled } from "./src-Z1x4-Qmb.js";
3
- import { a as toolResultText, i as connectReviewInstance, s as ReviewApiError } from "./agent-client-Dc0vHFJt.js";
3
+ import { a as toolResultText, i as connectReviewInstance, s as ReviewApiError } from "./agent-client-D4FSEDX4.js";
4
4
  import { N as devReviewHome } from "./s3-config-CjcLyFV5.js";
5
5
  import { n as readBuildCommit } from "./package-paths-BeYHYjeR.js";
6
6
  import "./review-home-paths-CG-sb9Cw.js";
7
- import { b as selectReviewInstance, u as REVIEW_INSTANCE_ENV } from "./server-discovery-DKLIOgg3.js";
8
- import { n as reviewSessionAgent } from "./review-telemetry-BM-_KdLi.js";
9
- import { a as REVIEW_VIA_HEADER, i as REVIEW_THREAD_HEADER, n as REVIEW_AGENT_HEADER, t as ASK_THREAD_ENV } from "./request-origin-CNSLVn7x.js";
10
- import { i as publicTool, n as RECOVERY, r as callPublicTool, t as toolFailure } from "./tool-failure-C1L1vJyz.js";
7
+ import { b as selectReviewInstance, u as REVIEW_INSTANCE_ENV } from "./server-discovery-BchUrwFW.js";
8
+ import { n as reviewSessionAgent } from "./review-telemetry-ChlsTRPN.js";
9
+ import { a as REVIEW_VIA_HEADER, i as REVIEW_THREAD_HEADER, n as REVIEW_AGENT_HEADER, t as ASK_THREAD_ENV } from "./request-origin-BIBW432J.js";
10
+ import { i as publicTool, n as RECOVERY, r as callPublicTool, t as toolFailure } from "./tool-failure-DlU9hn7_.js";
11
11
  import { existsSync } from "node:fs";
12
12
  import path from "node:path";
13
13
  //#region src/review-api/install-update.ts
@@ -44,7 +44,7 @@ async function runReviewAgentCli(input) {
44
44
  [REVIEW_THREAD_HEADER, thread ?? ""]
45
45
  ]);
46
46
  if (mode === "mcp") {
47
- const { serveReviewMcp } = await import("./mcp-Br-r_wwR.js");
47
+ const { serveReviewMcp } = await import("./mcp-D74cFQNM.js");
48
48
  exitOnInstallUpdate(input.stderr);
49
49
  await serveReviewMcp(async (key, agentKind) => {
50
50
  const connected = await connectReviewInstance(key ? {
@@ -1,7 +1,7 @@
1
1
  import { d as isBooleanValue, f as isNumberValue, m as isStringValue, u as parseJsonText } from "./src-X9phtB2j.js";
2
- import "./src-DYHVzX3b.js";
2
+ import "./src-DEOc8bvC.js";
3
3
  import { t as ReviewInputError } from "./input-error-OLgB_h31.js";
4
- import { b as selectReviewInstance, c as reviewServerStateDir, d as ReviewInstanceUnavailableError, i as readReviewServerDiscovery, l as serverNotReady, m as healthyReviewInstance, s as reviewServerIsHealthy, y as reviewInstanceUnavailable } from "./server-discovery-DKLIOgg3.js";
4
+ import { b as selectReviewInstance, c as reviewServerStateDir, d as ReviewInstanceUnavailableError, i as readReviewServerDiscovery, l as serverNotReady, m as healthyReviewInstance, s as reviewServerIsHealthy, y as reviewInstanceUnavailable } from "./server-discovery-BchUrwFW.js";
5
5
  //#region ../review-protocol/src/review-api-client.ts
6
6
  const defaultRequest = (url, init) => fetch(url, init);
7
7
  /** A non-2xx reply; the status tells a caller whether retrying can help. */
@@ -259,7 +259,7 @@ async function connectReviewInstance(env = process.env, headers = {}, options =
259
259
  const selection = await selectReviewInstance({ env });
260
260
  const discovery = healthyReviewInstance(selection);
261
261
  if (!discovery) {
262
- const { ensureServerWithoutDesktop } = await import("./background-server-DyWnPJyZ.js");
262
+ const { ensureServerWithoutDesktop } = await import("./background-server-BPZ3GQan.js");
263
263
  const server = await ensureServerWithoutDesktop({
264
264
  selection,
265
265
  env,
@@ -1,6 +1,6 @@
1
1
  import { n as isJsonObject } from "./src-X9phtB2j.js";
2
- import { c as activityBeginSchema, l as activityEndSchema, n as uploadSchema, r as commandSchema, u as activityUpdateSchema } from "./local-data-DHedfhxw.js";
3
- import { L as publishedEditSchema, N as pathTargetSchema } from "./stored-document-migration-DEt8iwem.js";
2
+ import { c as activityBeginSchema, l as activityEndSchema, n as uploadSchema, r as commandSchema, u as activityUpdateSchema } from "./local-data-C0OJttzT.js";
3
+ import { L as publishedEdits, N as pathTargetSchema } from "./stored-document-migration-BCFx07Bq.js";
4
4
  import { t as ReviewInputError } from "./input-error-OLgB_h31.js";
5
5
  import { t as findReviewPackageRoot } from "./package-paths-BeYHYjeR.js";
6
6
  import { z } from "zod";
@@ -69,6 +69,8 @@ const readQuerySchemas = {
69
69
  };
70
70
  //#endregion
71
71
  //#region src/review-api/component-reference.ts
72
+ /** The animation component, shown only while Animations are on. */
73
+ const ANIMATION = ["- animation {title, html, frames: {key, title, label?, caption?, duration? (ms)}[] (1 to 60), code?: {name: anchor}, height?: \"auto\" (default) | number (120 to 1200 CSS px), pins?}; declare every possible frame", "Use an animation for change over time that a static diagram cannot show: state before and after, a cache filling, data changing as a request crosses layers. It can sit in design beside the diagram, or replace it when the motion is the point. If nothing changes between frames, use a sequence or flow_diagram instead: their steps and nodes link to code. Read session_get_instructions({topic:\"animation\"}) before writing one."];
72
74
  /** Every component's fields, for session_get_instructions: the edit tool's
73
75
  * description must stay short enough that clients don't cut it off. */
74
76
  const COMPONENT_REFERENCE = [
@@ -97,11 +99,17 @@ const COMPONENT_REFERENCE = [
97
99
  "- store {label, storage: relational|document, collections: {key: {label, fields: {key: field}, source?: anchor of its schema declaration}}, dataStoreKind?: database|objectStore|bucket|artifactStore|fileStore}",
98
100
  "- field {label, dataType, nullable?, primaryKey?, references?: {store, collection, field}, fields?: {key: field}}",
99
101
  "- useCase {label, summary?, operations: operation[] (1 or more)}; operation {kind: read|write, actor, store, collection, label, source: anchor, field?, detail?, pins?}, naming declared keys",
102
+ ...ANIMATION,
100
103
  "",
101
104
  "Example (replace its path and lines with verified ones): {\"type\":\"sequence\",\"title\":\"Request\",\"actors\":{\"a\":\"Client\",\"b\":\"Server\"},\"steps\":[{\"from\":\"a\",\"to\":\"b\",\"label\":\"Send\",\"source\":\"head/src/app.ts#L10-L20\"}]}"
102
105
  ].join("\n");
106
+ /** Keep disabled experimental components out of agent guidance. */
107
+ function componentReference(animationsEnabled) {
108
+ return animationsEnabled ? COMPONENT_REFERENCE : COMPONENT_REFERENCE.split("\n").filter((line) => !ANIMATION.includes(line)).join("\n");
109
+ }
103
110
  const instructionsQuerySchema = z.strictObject({ topic: z.enum([
104
111
  "authoring",
112
+ "animation",
105
113
  "file-lenses",
106
114
  "trace-archaeology"
107
115
  ]).default("authoring") });
@@ -119,12 +127,13 @@ function read(root, name) {
119
127
  return content;
120
128
  }
121
129
  async function renderInstructions(topic, context, root = findReviewPackageRoot(import.meta.url)) {
130
+ if (topic === "animation" && !context.animationsEnabled) throw new ReviewInputError("Animation authoring is disabled. Enable Animations in Settings under Experimental Features.", 409);
122
131
  if (topic === "trace-archaeology" && !context.traceEnabled) return "Trace capture is off on this machine, so no agent traces are available. It can be turned on in Whiteboard Desktop Settings under Experimental Features.";
123
132
  if (topic !== "authoring") return read(root, topic);
124
133
  const more = [...context.traceEnabled ? ["- Why code exists / past agent sessions: `session_get_instructions({topic:\"trace-archaeology\"})`"] : []];
125
134
  return [
126
135
  await read(root, "authoring"),
127
- COMPONENT_REFERENCE,
136
+ componentReference(context.animationsEnabled === true),
128
137
  ...context.traceEnabled ? ["## Traces\n\nAt the end, run `whiteboard trace list --session <sessionId> --json`, which covers every commit in the review. If it lists no sessions, there are no traces to quote: skip this step. Otherwise read `session_get_instructions({topic:\"trace-archaeology\"})` and rewrite as much as possible of the what/why, design, and requirements sections in terms of literal trace quotes from the user."] : [],
129
138
  ...more.length ? [`## More guidance\n\n${more.join("\n")}`] : []
130
139
  ].join("\n\n");
@@ -146,9 +155,9 @@ const REVIEW_STATUS_TOOL = {
146
155
  //#endregion
147
156
  //#region src/review-api/authoring-tools.ts
148
157
  /** The host publishes its input schemas, except where agents write less than
149
- * the host accepts (publishedEditSchema, publishedLensEditSchema) or name a
158
+ * the host accepts (publishedEdits, publishedLensEditSchema) or name a
150
159
  * checkout by path (pathTargetSchema); adapters validate nothing. */
151
- function authoringTools(traceEnabled = false) {
160
+ function authoringTools(traceEnabled = false, animationsEnabled = false) {
152
161
  const id = z.string().min(1);
153
162
  const review = { reviewId: id };
154
163
  const [image, trace] = uploadSchema.options;
@@ -163,7 +172,7 @@ function authoringTools(traceEnabled = false) {
163
172
  });
164
173
  const descriptions = {
165
174
  create: "Create a whiteboard. target names its repository by the checkout's path, and what it shows: {kind:\"project\"} for a plan in that repository's project with no change; {kind:\"worktree\", base?} for the saved files in the checkout, uncommitted ones included and untracked ones left out (git add -N a new file to include it), against base, by default the repository's default branch, from the merge base of base and HEAD, which follows rebases; {kind:\"commits\", head, base?} for immutable commits (omitted base means source at head with no diff; supply the parent to review introduced changes); {kind:\"pullRequest\", pullRequest} for a GitHub PR by URL or number, fetched into that checkout and pinned at the PR head and GitHub diff base. For a branch stacked on another, pass the branch below it as base. Group plan implementations or a PR stack under one project-target overview with parentId, and order its children with dependsOn; Git bases do not set these relationships. Revisions are resolved on acceptance. With a PR and no title the PR's title is used. When the existing review for that PR is in Trash, creation reports its ID; restore it with review_lifecycle state:\"active\" before continuing. When an active review for that PR exists, it is returned instead, reporting whether its head moved and whether an agent is working on it; update it in place, move its target with review_set_target, or create a separate review with reuseExisting:false. The result carries review, as review_list shows it, with its target and repositoryPath, so no follow-up read is needed before diffing. When Desktop is available the review opens there and the result reports opened, softwareMapEnabled and environmentIssues, as review_open does; set open:false to author in the background without taking over Desktop. parentId and dependsOn set its place among the project's reviews, as review_set_parent and review_set_dependencies do; projectId files it in another project, by project.id from review_list.",
166
- set_target: "Move the review to a new target (the same targets review_create takes), such as the commits after a rebase or amend, or commits or a PR for a board that had none. The document and component IDs are kept. Revisions are resolved on acceptance. Returns warnings for retained source ranges in files the new commits changed, to verify, and resources that no longer match; fix them with review_edit. Earlier versions keep their source. A PR target names the PR; other targets keep it within the same repository and clear it across repositories.",
175
+ set_target: "Move the review to a new target (the same targets review_create takes), such as the commits after a rebase or amend, or commits or a PR for a board that had none. The document and component IDs are kept. Revisions are resolved on acceptance. Returns warnings for retained source ranges in files the new commits changed, to verify, and resources that no longer match; fix them with review_edit. Earlier versions keep their source. A PR target names the PR; other targets keep it within the same repository and clear it across repositories. To refresh a PR review, pass its PR target again: a commits target with its branch names pins their tips, not the PR's diff base.",
167
176
  edit: [
168
177
  "Edit one document component. content is one component, named by its type; each type's fields are in the Components section of session_get_instructions.",
169
178
  "Anchors are head/path#L10-L20 or base/path#L7, or diff/path#L84-R90 for a range across sides, with repository-relative paths and 1-based inclusive lines. pins {head, base?} say which commits of the whiteboard's repository anchors quote: a step, frame, attachment or operation without pins uses its block's, and a block without them the review's.",
@@ -194,7 +203,11 @@ function authoringTools(traceEnabled = false) {
194
203
  return [
195
204
  REVIEW_STATUS_TOOL,
196
205
  tool("capabilities", "Discover whether Desktop is available and optional software-map generation is enabled. Read before authoring.", z.strictObject({}), "GET", "/capabilities"),
197
- tool("get_instructions", "Read Whiteboard's guidance before creating or editing a review. The default topic gives the authoring workflow; \"file-lenses\" covers Diff-view file lenses." + (traceEnabled ? " Call review_get_instructions({topic:\"trace-archaeology\"}) for why code exists, what an agent was thinking, or whether an agent solved this before." : ""), instructionsQuerySchema.partial(), "GET", "/instructions"),
206
+ tool("get_instructions", "Read Whiteboard's guidance before creating or editing a review. The default topic gives the authoring workflow; \"file-lenses\" covers Diff-view file lenses." + (traceEnabled ? " Call review_get_instructions({topic:\"trace-archaeology\"}) for why code exists, what an agent was thinking, or whether an agent solved this before." : ""), instructionsQuerySchema.extend({ topic: animationsEnabled ? instructionsQuerySchema.shape.topic : z.enum([
207
+ "authoring",
208
+ "file-lenses",
209
+ "trace-archaeology"
210
+ ]).default("authoring") }).partial(), "GET", "/instructions"),
198
211
  tool("activity_begin", "Show that you are working on a review: the reader sees your focus and your courier drawing your edits, and the review reads as finished only once every agent has ended. Returns an activityId: pass it to session_edit and session_lens_edit so your courier draws them, and to review_activity_update and review_activity_end. Nothing is locked; other agents can work on the review too. The activity expires after 3 minutes without an edit or update.", activityBeginSchema.extend(review), "POST", "/:reviewId/activity/begin"),
199
212
  tool("activity_update", "Change your focus, or keep your activity alive during long reads or pauses; an edit carrying your activityId already keeps it alive. Omitted focus preserves it and null clears it. Fails once the activity has expired: begin a new one.", activityUpdateSchema.extend(review), "POST", "/:reviewId/activity/update"),
200
213
  tool("activity_end", "End your activity when your part is finished: readers treat a review with content and no live activity as ready. Ending it creates no document version. Ending twice, or an expired activity, changes nothing.", activityEndSchema.extend(review), "POST", "/:reviewId/activity/end"),
@@ -208,7 +221,7 @@ function authoringTools(traceEnabled = false) {
208
221
  open: z.boolean().optional()
209
222
  },
210
223
  ...type === "set_target" && { target: pathTargetSchema },
211
- ...type === "edit" && { edit: publishedEditSchema }
224
+ ...type === "edit" && { edit: publishedEdits(animationsEnabled) }
212
225
  }), "POST", "/commands", type);
213
226
  }),
214
227
  tool("list", "List saved reviews.", z.strictObject({}), "GET", ""),
@@ -1,8 +1,8 @@
1
1
  import "./src-Z1x4-Qmb.js";
2
2
  import { D as liveLockOwner, k as processIsAlive } from "./s3-config-CjcLyFV5.js";
3
3
  import { t as findReviewPackageRoot } from "./package-paths-BeYHYjeR.js";
4
- import { a as readReviewServerHealth, c as reviewServerStateDir, i as readReviewServerDiscovery, n as desktopOwnsHome, p as desktopUsesHome, r as headlessServerLockPath } from "./server-discovery-DKLIOgg3.js";
5
- import { t as desktopApplicationInstalled } from "./review-app-launcher-BZAnR8Vp.js";
4
+ import { a as readReviewServerHealth, c as reviewServerStateDir, i as readReviewServerDiscovery, n as desktopOwnsHome, p as desktopUsesHome, r as headlessServerLockPath } from "./server-discovery-BchUrwFW.js";
5
+ import { t as desktopApplicationInstalled } from "./review-app-launcher-Brn60fPu.js";
6
6
  import { mkdir, open, readFile, realpath, stat } from "node:fs/promises";
7
7
  import path from "node:path";
8
8
  import { spawn } from "node:child_process";
@@ -1,2 +1,2 @@
1
- import { a as headlessServerOwner, c as stopBackgroundServer, i as ensureServerWithoutDesktop, r as ensureBackgroundServer } from "./background-server-DHWHzpo5.js";
1
+ import { a as headlessServerOwner, c as stopBackgroundServer, i as ensureServerWithoutDesktop, r as ensureBackgroundServer } from "./background-server-B1uwDQTr.js";
2
2
  export { ensureBackgroundServer, ensureServerWithoutDesktop, headlessServerOwner, stopBackgroundServer };
@@ -1 +1 @@
1
- {"version":"0.3.5-preview.20261023.136","commit":"3fb855e33dc96595fdae83b3d4532e7a3fbeee58","dirty":true,"builtAt":"2026-10-23T16:53:05.685Z"}
1
+ {"version":"0.4.1-preview.20261026.137","commit":"46629c2739b7efbdb10cd7a98cfacb315e8d7ae0","dirty":true,"builtAt":"2026-10-26T17:52:50.758Z"}
@@ -1,19 +1,19 @@
1
1
  import { D as __commonJSMin, E as setLocalVcsCommandObserver, O as __require, k as __toESM } from "./src-X9ZebeOD.js";
2
2
  import { c as jsonString, n as isJsonObject, u as parseJsonText } from "./src-X9phtB2j.js";
3
- import { S as REVIEW_REMOTE_ATTACH_END, b as REVIEW_REMOTE_AGENT_IDS, h as REVIEW_CLI_INSTALL_TARGET_LABELS, l as boardTitle, x as REVIEW_REMOTE_ATTACH_BEGIN } from "./src-DYHVzX3b.js";
3
+ import { S as REVIEW_REMOTE_ATTACH_END, b as REVIEW_REMOTE_AGENT_IDS, h as REVIEW_CLI_INSTALL_TARGET_LABELS, l as boardTitle, x as REVIEW_REMOTE_ATTACH_BEGIN } from "./src-DEOc8bvC.js";
4
4
  import { $ as runStoreLogin, A as loadS3TraceStorage, B as readTraceUserConfig, C as runTraceDeny, D as runTraceStoreInfo, E as runTraceStoreDelete, F as resolveTraceRepositoryTarget, J as traceHomeDir, K as resolveTraceCommand, M as selectTraceStorage, O as describeSelection, P as requireTraceConsent, Q as readStoreAuth, S as runTraceAllow, T as runTraceSessions, V as HOSTED_CAPTURE_SCOPE_DESCRIPTION, X as DEFAULT_STORE_ORIGIN, Y as traceScope, _ as readLegacyCaptureSettings, a as runTracePull$1, at as emitJsonEvent, c as runTraceEnable, ct as jsonRequestedInArgv, d as runTraceStatus, et as runStoreLogout, f as runTraceSync, i as runTraceList$1, it as withStoreAuthorization, l as runTraceInstallMachine, m as runTraceHook, n as resolveTraceReadStorage, nt as StoreApiError, o as runTraceShow, ot as failWithJsonError, p as runTraceGitHook, r as runTraceBlame, rt as StoreClient, s as runTraceDisable, st as humanStream, t as registerTraceCommands, tt as runStoreWhoami, u as runTraceRepair, v as traceMachineEnabled, w as runTraceOnboard, y as traceMachineStatus, z as traceRepositoryStatus } from "./src-Z1x4-Qmb.js";
5
- import { o as ReviewApiClient, s as ReviewApiError } from "./agent-client-Dc0vHFJt.js";
5
+ import { o as ReviewApiClient, s as ReviewApiError } from "./agent-client-D4FSEDX4.js";
6
6
  import { C as s3ProfileSchema, E as writeTraceConfigFile, N as devReviewHome, P as normalizeStoreOrigin, S as readTraceConfigFile, T as sameS3Profile, _ as emptyTraceConfig, c as resolveS3Setup, g as currentStore, h as TraceConfigurationError, i as isS3MockMode, n as clearTraceEnvCache, o as readTraceEnvFile, p as traceSettingsPath, w as s3Store } from "./s3-config-CjcLyFV5.js";
7
7
  import { t as errorMessage } from "./error-message-OtiDonty.js";
8
8
  import { i as readReviewPackageVersion, r as readBuildInfo, t as findReviewPackageRoot } from "./package-paths-BeYHYjeR.js";
9
9
  import { t as resolveReviewRoot } from "./runtime-C6_1K-3Z.js";
10
10
  import "./review-home-paths-CG-sb9Cw.js";
11
- import { a as readReviewServerHealth, b as selectReviewInstance, c as reviewServerStateDir, d as ReviewInstanceUnavailableError, f as clearDefaultReviewInstance, g as requireHealthyReviewDesktop, h as readDefaultReviewInstance, i as readReviewServerDiscovery, l as serverNotReady, m as healthyReviewInstance, p as desktopUsesHome, t as DESKTOP_TAKEOVER_SIGNAL, u as REVIEW_INSTANCE_ENV, x as writeDefaultReviewInstance, y as reviewInstanceUnavailable } from "./server-discovery-DKLIOgg3.js";
12
- import { t as ReviewTelemetry } from "./review-telemetry-BM-_KdLi.js";
13
- import { t as fuzzyRank } from "./fuzzy-match-CfSxqzBF.js";
14
- import { _ as isInstallTarget, a as isOwnedShim, f as windowsInstallerCommand, g as ALL_INSTALL_TARGETS, h as detectConnectAgents, m as connectAgent, o as pathShimPath, p as scanLegacySkills, t as aliasInstallationToAccount, v as connectPrompts } from "./account-alias-2yTAxoBx.js";
15
- import { n as focusReviewDesktop, r as runReviewAppLaunch } from "./review-app-launcher-BZAnR8Vp.js";
16
- import { t as reviewAgentCliHelp } from "./agent-cli-CHNDd4Ga.js";
11
+ import { a as readReviewServerHealth, b as selectReviewInstance, c as reviewServerStateDir, d as ReviewInstanceUnavailableError, f as clearDefaultReviewInstance, g as requireHealthyReviewDesktop, h as readDefaultReviewInstance, i as readReviewServerDiscovery, l as serverNotReady, m as healthyReviewInstance, p as desktopUsesHome, t as DESKTOP_TAKEOVER_SIGNAL, u as REVIEW_INSTANCE_ENV, x as writeDefaultReviewInstance, y as reviewInstanceUnavailable } from "./server-discovery-BchUrwFW.js";
12
+ import { t as ReviewTelemetry } from "./review-telemetry-ChlsTRPN.js";
13
+ import { t as fuzzyRank } from "./fuzzy-match-BNLXmpbv.js";
14
+ import { _ as isInstallTarget, a as isOwnedShim, f as windowsInstallerCommand, g as ALL_INSTALL_TARGETS, h as detectConnectAgents, m as connectAgent, o as pathShimPath, p as scanLegacySkills, t as aliasInstallationToAccount, v as connectPrompts } from "./account-alias-BpH8VvTR.js";
15
+ import { n as focusReviewDesktop, r as runReviewAppLaunch } from "./review-app-launcher-Brn60fPu.js";
16
+ import { t as reviewAgentCliHelp } from "./agent-cli-DckMzOU_.js";
17
17
  import { existsSync, mkdirSync, renameSync, writeFileSync } from "node:fs";
18
18
  import { realpath } from "node:fs/promises";
19
19
  import path from "node:path";
@@ -4334,7 +4334,7 @@ async function runReviewCli(input) {
4334
4334
  if (!Number.isInteger(port) || port < 0 || port > 65535) throw new ReviewCliUsageError("--port must be an integer between 0 and 65535.");
4335
4335
  const stateDir = reviewServerStateDir(authoringEnv(options.stateDir));
4336
4336
  if (options.detach) {
4337
- const { ensureBackgroundServer } = await import("./background-server-DyWnPJyZ.js");
4337
+ const { ensureBackgroundServer } = await import("./background-server-BPZ3GQan.js");
4338
4338
  const { discovery, started } = await ensureBackgroundServer({
4339
4339
  stateDir,
4340
4340
  env,
@@ -4356,7 +4356,7 @@ async function runReviewCli(input) {
4356
4356
  process.once("SIGINT", stop);
4357
4357
  process.once("SIGTERM", stop);
4358
4358
  process.once(DESKTOP_TAKEOVER_SIGNAL, takeover);
4359
- const { HeadlessServerBusyError, runHeadlessServer } = await import("./headless-host-dwlqhqMY.js");
4359
+ const { HeadlessServerBusyError, runHeadlessServer } = await import("./headless-host-B63e2z2j.js");
4360
4360
  try {
4361
4361
  await runHeadlessServer({
4362
4362
  stateDir,
@@ -4393,7 +4393,7 @@ async function runReviewCli(input) {
4393
4393
  configureJsonOutput(serverCommand.command("stop").description("Stop a background server started by --detach, the CLI, or Desktop").option("--state-dir <path>", "directory selected when starting the server"), "plain").action(async (_options, command) => {
4394
4394
  const options = command.optsWithGlobals();
4395
4395
  const stateDir = reviewServerStateDir(authoringEnv(options.stateDir));
4396
- const { headlessServerOwner, stopBackgroundServer } = await import("./background-server-DyWnPJyZ.js");
4396
+ const { headlessServerOwner, stopBackgroundServer } = await import("./background-server-BPZ3GQan.js");
4397
4397
  const owner = await headlessServerOwner(stateDir);
4398
4398
  const discovery = await readReviewServerDiscovery(stateDir);
4399
4399
  if (owner === void 0) {
@@ -4421,7 +4421,7 @@ async function runReviewCli(input) {
4421
4421
  if (!existsSync(path.join(stateDir, "review-api.db"))) throw new Error(`No saved reviews in ${stateDir}, so there is no server id to reset. Check --state-dir.`);
4422
4422
  const inUse = `A Whiteboard server is using ${stateDir}. Stop it first, then run whiteboard server reset-id again.`;
4423
4423
  if (await desktopUsesHome(stateDir, env)) return refuse(inUse, options.json);
4424
- const [{ openReviewProfile }, { withHeadlessServerLock }] = await Promise.all([import("./profile-BopGMZUh.js"), import("./headless-host-dwlqhqMY.js")]);
4424
+ const [{ openReviewProfile }, { withHeadlessServerLock }] = await Promise.all([import("./profile-CAn8Qdeh.js"), import("./headless-host-B63e2z2j.js")]);
4425
4425
  const reset = await withHeadlessServerLock(await realpath(stateDir), async () => {
4426
4426
  const local = await openReviewProfile(stateDir, { manageWorkspaces: false });
4427
4427
  try {
@@ -4443,7 +4443,7 @@ async function runReviewCli(input) {
4443
4443
  configureJsonOutput(remote.command("attach").description("Start a background server if none is healthy and report how to reach it").option("--state-dir <path>", "directory for saved reviews and server discovery").option("--groups <groups>", "comma-separated optional extension groups the Desktop has enabled, such as go").option("--replace", "stop a running server of another version that the CLI or Desktop started, and start this one"), "plain").action(async (_options, command) => {
4444
4444
  const options = command.optsWithGlobals();
4445
4445
  const stateDir = reviewServerStateDir(authoringEnv(options.stateDir));
4446
- const { remoteAttach } = await import("./remote-attach-DSGpTOJ4.js");
4446
+ const { remoteAttach } = await import("./remote-attach-DTByuwBs.js");
4447
4447
  let attach;
4448
4448
  try {
4449
4449
  attach = await remoteAttach({
@@ -4485,7 +4485,7 @@ async function runReviewCli(input) {
4485
4485
  configureJsonOutput(remote.command("uninstall").description("Remove what Whiteboard Desktop installed on this host, stopping a server it started").addOption(new Option("--keep-reviews", "leave the saved reviews in place").conflicts("deleteReviews")).addOption(new Option("--delete-reviews", "also delete the saved reviews")).option("--state-dir <path>", "directory for saved reviews and server discovery"), "plain").action(async (_options, command) => {
4486
4486
  const options = command.optsWithGlobals();
4487
4487
  const stateDir = reviewServerStateDir(authoringEnv(options.stateDir));
4488
- const { remoteUninstall } = await import("./remote-uninstall-Dp2o3qz0.js");
4488
+ const { remoteUninstall } = await import("./remote-uninstall-aXApHJPy.js");
4489
4489
  let deleteReviews = options.deleteReviews ? true : options.keepReviews ? false : void 0;
4490
4490
  if (deleteReviews === void 0 && !options.json && input.stdin?.isTTY) {
4491
4491
  const prompt = createInterface$1({
@@ -4707,14 +4707,14 @@ async function runReviewCli(input) {
4707
4707
  command.showHelpAfterError(false).error("Markdown review migration is no longer supported. Ask your agent to migrate your old Whiteboard reviews.");
4708
4708
  });
4709
4709
  configureJsonOutput(configureJsonOutput(program.command("share").description("Upload an immutable review snapshot and return its share link"), "plain").option("--review <id>", "review ID").option("--version <number>", "Saved version to share").option("--preview", "Open the share link in Whiteboard Preview by default").option("--request-id <uuid>", "Reuse this ID when retrying the same immutable upload").action(async (options) => {
4710
- const { runShareCli } = await import("./cli-qZomwJmK.js");
4710
+ const { runShareCli } = await import("./cli-tWBQpq27.js");
4711
4711
  state.exitCode = await runShareCli({
4712
4712
  ...input,
4713
4713
  ...options,
4714
4714
  env: authoringEnv()
4715
4715
  });
4716
4716
  }).command("revoke <share-id>").description("Revoke future downloads of a share"), "plain").action(async (shareId, options) => {
4717
- const { runShareCli } = await import("./cli-qZomwJmK.js");
4717
+ const { runShareCli } = await import("./cli-tWBQpq27.js");
4718
4718
  state.exitCode = await runShareCli({
4719
4719
  ...input,
4720
4720
  ...options,
@@ -4795,7 +4795,7 @@ async function runReviewCli(input) {
4795
4795
  return commands;
4796
4796
  } });
4797
4797
  for (const [name, description] of [["api", "Call a JSON review authoring tool on the running server"], ["mcp", "Serve the JSON review authoring tools over stdio MCP"]]) configureOutput(program.command(name).description(description).argument("[args...]", "tool name and JSON input").allowUnknownOption().allowExcessArguments().helpOption(false).passThroughOptions().addHelpText("after", `\n${reviewAgentCliHelp}`), "plain").action(async (args) => {
4798
- const { runReviewAgentCli } = await import("./agent-cli-Cn4-16XA.js");
4798
+ const { runReviewAgentCli } = await import("./agent-cli-DFWrNoGJ.js");
4799
4799
  state.exitCode = await runReviewAgentCli({
4800
4800
  ...input,
4801
4801
  env: authoringEnv(),
@@ -1,4 +1,4 @@
1
- import { r as connectReviewApi } from "./agent-client-Dc0vHFJt.js";
1
+ import { r as connectReviewApi } from "./agent-client-D4FSEDX4.js";
2
2
  import { randomUUID } from "node:crypto";
3
3
  import { z } from "zod";
4
4
  //#region src/sharing/cli.ts
package/dist/cli.js CHANGED
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { a as jsonNumber, c as jsonString, o as jsonObject, u as parseJsonText } from "./src-X9phtB2j.js";
3
- import "./src-DYHVzX3b.js";
3
+ import "./src-DEOc8bvC.js";
4
4
  import { existsSync, readFileSync, readdirSync, realpathSync } from "node:fs";
5
5
  import path from "node:path";
6
6
  import os from "node:os";
@@ -17,7 +17,7 @@ async function runCli(effectivePath) {
17
17
  `);
18
18
  return 1;
19
19
  }
20
- const { runReviewCli } = await import("./cli-runner-DFBaVGij.js");
20
+ const { runReviewCli } = await import("./cli-runner-DVEDbjXo.js");
21
21
  return runReviewCli({
22
22
  argv,
23
23
  cliPaths: {
@@ -1,8 +1,8 @@
1
1
  import { f as gitAt } from "./src-X9ZebeOD.js";
2
2
  import { n as isJsonObject, u as parseJsonText } from "./src-X9phtB2j.js";
3
- import "./src-DYHVzX3b.js";
4
- import { f as sourceAnchors } from "./lens-selection-9byzEgvU.js";
5
- import { B as resourceReferences, D as boardRepositoryId, I as pinsSchema, J as checkReferences, K as sourceReferences, R as readsAtBoardPins, S as anchorPins, b as textIncludesQuote, c as traceSchema, et as lensSchema, j as elements, k as documentSchema, lt as parseMarkdown, n as migrateStoredDocument, r as migrateStoredLenses, s as softwareModelDataSchema, st as markdownNodes, t as liftFileLenses, tt as lensSelections, u as pullRequestUrl, z as resourceReference } from "./stored-document-migration-DEt8iwem.js";
3
+ import "./src-DEOc8bvC.js";
4
+ import { f as sourceAnchors } from "./lens-selection-EuZdag4Q.js";
5
+ import { B as resourceReferences, D as boardRepositoryId, I as pinsSchema, J as checkReferences, K as sourceReferences, R as readsAtBoardPins, S as anchorPins, b as textIncludesQuote, c as traceSchema, et as lensSchema, j as elements, k as documentSchema, lt as parseMarkdown, n as migrateStoredDocument, r as migrateStoredLenses, s as softwareModelDataSchema, st as markdownNodes, t as liftFileLenses, tt as lensSelections, u as pullRequestUrl, z as resourceReference } from "./stored-document-migration-BCFx07Bq.js";
6
6
  import { t as ReviewInputError } from "./input-error-OLgB_h31.js";
7
7
  import { createHash, randomUUID } from "node:crypto";
8
8
  import { z } from "zod";
@@ -1,7 +1,7 @@
1
1
  import "./src-Z1x4-Qmb.js";
2
2
  import { N as devReviewHome } from "./s3-config-CjcLyFV5.js";
3
- import { n as askAgentIds } from "./thread-state-CO97FUqK.js";
4
- import { t as ASK_THREAD_ENV } from "./request-origin-CNSLVn7x.js";
3
+ import { n as askAgentIds } from "./thread-state-CbLB0jUA.js";
4
+ import { t as ASK_THREAD_ENV } from "./request-origin-BIBW432J.js";
5
5
  import { createRequire } from "node:module";
6
6
  import { constants } from "node:fs";
7
7
  import { access, chmod, mkdir, readFile, rename, stat, writeFile } from "node:fs/promises";
@@ -1,2 +1,2 @@
1
- import { i as withHeadlessServerLock, n as runHeadlessServer, r as takeOverServerHome, t as HeadlessServerBusyError } from "./headless-host-DJhcab6r.js";
1
+ import { i as withHeadlessServerLock, n as runHeadlessServer, r as takeOverServerHome, t as HeadlessServerBusyError } from "./headless-host-Dl9g9Fvd.js";
2
2
  export { HeadlessServerBusyError, runHeadlessServer, takeOverServerHome, withHeadlessServerLock };
@@ -1,23 +1,23 @@
1
1
  import { b as resolveRepoContext, d as git, r as defaultBranch, w as runVcs } from "./src-X9ZebeOD.js";
2
2
  import { c as jsonString, m as isStringValue, n as isJsonObject, p as isObjectValue, u as parseJsonText } from "./src-X9phtB2j.js";
3
- import { a as sharedReviewId, c as verifyShareRepository, d as validateShareSources, f as StreamLimitError, h as shareIdSchema, l as exportShare, m as parseShareLink, n as ShareClient, p as readBoundedStream, r as SharePreflightError, s as readShareRepository, t as ShareAuthError, u as referenceCommits } from "./client-p9WB8Sj0.js";
4
- import { d as textualRows, f as invalidateStructuralComparisons, h as readGitHubPullRequests, i as inspectSnapshot, m as diffrMissingError, p as diffrExecutable, r as commandSchema } from "./local-data-DHedfhxw.js";
5
- import { N as reviewDiffrSummarizerInputSchema, O as ReviewFeedbackContactSchema, P as decodeStructuralDiffEvent, a as parseReviewVerbRequest, c as boardIconKind, i as parseReviewDesktopVerbResult, j as ReviewOnboardingRunRequestSchema, k as ReviewFeedbackSchema, l as boardTitle, m as REVIEW_CLIENT_REMOTE, p as REVIEW_CLIENT_HEADER, y as REVIEW_HOST_HEADER } from "./src-DYHVzX3b.js";
3
+ import { a as sharedReviewId, c as verifyShareRepository, d as validateShareSources, f as StreamLimitError, h as shareIdSchema, l as exportShare, m as parseShareLink, n as ShareClient, p as readBoundedStream, r as SharePreflightError, s as readShareRepository, t as ShareAuthError, u as referenceCommits } from "./client-C8vT0mhW.js";
4
+ import { d as textualRows, f as invalidateStructuralComparisons, h as readGitHubPullRequests, i as inspectSnapshot, m as diffrMissingError, p as diffrExecutable, r as commandSchema } from "./local-data-C0OJttzT.js";
5
+ import { F as decodeStructuralDiffEvent, N as reviewDiffrSummarizerInputSchema, O as ReviewFeedbackContactSchema, a as parseReviewVerbRequest, c as boardIconKind, i as parseReviewDesktopVerbResult, j as ReviewOnboardingRunRequestSchema, k as ReviewFeedbackSchema, l as boardTitle, m as REVIEW_CLIENT_REMOTE, p as REVIEW_CLIENT_HEADER, y as REVIEW_HOST_HEADER } from "./src-DEOc8bvC.js";
6
6
  import { $ as runStoreLogin, M as selectTraceStorage, N as TraceStorageDeniedError, Q as readStoreAuth, X as DEFAULT_STORE_ORIGIN, Z as clearStoreAuth, b as listReviewTraceSessions, j as resolveTraceStorage, k as isTraceStorageConfigured, q as shellQuote, v as traceMachineEnabled, x as loadReviewAgentTrace } from "./src-Z1x4-Qmb.js";
7
- import { _ as scopedCoverage, h as emptyCoverage, i as anchorSelection, l as resolveDiffSelection, m as coverageSources, n as SelectionUnavailableError, o as comparisonKey, s as formatAnchor, u as selectionKey, v as subtractIntervals, y as unionIntervals } from "./lens-selection-9byzEgvU.js";
8
- import { D as boardRepositoryId, E as boardLinks, G as selectionReferences, S as anchorPins, X as stepSources, Z as UNCATEGORIZED_LENS_ID, f as sourceBranchName, it as fileLineRangeSchema, j as elements, l as pullRequestKey, p as pullRequestProvider, tt as lensSelections } from "./stored-document-migration-DEt8iwem.js";
7
+ import { _ as scopedCoverage, h as emptyCoverage, i as anchorSelection, l as resolveDiffSelection, m as coverageSources, n as SelectionUnavailableError, o as comparisonKey, s as formatAnchor, u as selectionKey, v as subtractIntervals, y as unionIntervals } from "./lens-selection-EuZdag4Q.js";
8
+ import { D as boardRepositoryId, E as boardLinks, G as selectionReferences, S as anchorPins, X as stepSources, Z as UNCATEGORIZED_LENS_ID, f as sourceBranchName, it as fileLineRangeSchema, j as elements, l as pullRequestKey, p as pullRequestProvider, tt as lensSelections } from "./stored-document-migration-BCFx07Bq.js";
9
9
  import { t as ReviewInputError } from "./input-error-OLgB_h31.js";
10
10
  import { A as processStartIdentity, L as writePrivateJsonAtomic, N as devReviewHome, h as TraceConfigurationError, i as isS3MockMode, j as withFileLock } from "./s3-config-CjcLyFV5.js";
11
11
  import { t as errorMessage } from "./error-message-OtiDonty.js";
12
12
  import { i as readReviewPackageVersion, n as readBuildCommit, t as findReviewPackageRoot } from "./package-paths-BeYHYjeR.js";
13
13
  import "./review-home-paths-CG-sb9Cw.js";
14
- import { _ as reviewInstanceIdentity, n as desktopOwnsHome, o as reviewServerDiscoveryPath, p as desktopUsesHome, r as headlessServerLockPath, t as DESKTOP_TAKEOVER_SIGNAL } from "./server-discovery-DKLIOgg3.js";
15
- import { c as askPicksSchema, d as selectionMarkdown, l as askQuestionSchema, n as askAgentIds, r as askChoiceKinds, s as askPermissionsSchema, t as applyAskChange, u as AgentSelectionSchema } from "./thread-state-CO97FUqK.js";
16
- import { t as openReviewProfile } from "./profile-D9wdlPgw.js";
17
- import { c as REVIEW_APP_SESSION_ID_HEADER, d as sanitizeUiTelemetryEvent, f as cleanTelemetryText, o as reviewRequestOrigin, r as REVIEW_PERSON_HEADER, s as BUNDLE_FRAME_PATTERN, t as ASK_THREAD_ENV, u as isReportableCleanedMessage } from "./request-origin-CNSLVn7x.js";
18
- import { a as defaultAskPermissions, i as askAgents, l as launchAskAgent, n as askAgentSettings, o as detectAskAgents, r as askAgentTakesMcp, t as fuzzyRank } from "./fuzzy-match-CfSxqzBF.js";
19
- import { a as inspectQuerySchema, i as renderInstructions, o as queryAnchor, r as instructionsQuerySchema, s as readQuerySchemas, t as authoringTools } from "./authoring-tools-D8EkIDjm.js";
20
- import { a as headlessServerOwner, c as stopBackgroundServer, o as recordedBackgroundServer } from "./background-server-DHWHzpo5.js";
14
+ import { _ as reviewInstanceIdentity, n as desktopOwnsHome, o as reviewServerDiscoveryPath, p as desktopUsesHome, r as headlessServerLockPath, t as DESKTOP_TAKEOVER_SIGNAL } from "./server-discovery-BchUrwFW.js";
15
+ import { c as askPicksSchema, d as selectionMarkdown, l as askQuestionSchema, n as askAgentIds, r as askChoiceKinds, s as askPermissionsSchema, t as applyAskChange, u as AgentSelectionSchema } from "./thread-state-CbLB0jUA.js";
16
+ import { t as openReviewProfile } from "./profile-DS1F6PBF.js";
17
+ import { c as REVIEW_APP_SESSION_ID_HEADER, d as sanitizeUiTelemetryEvent, f as cleanTelemetryText, o as reviewRequestOrigin, r as REVIEW_PERSON_HEADER, s as BUNDLE_FRAME_PATTERN, t as ASK_THREAD_ENV, u as isReportableCleanedMessage } from "./request-origin-BIBW432J.js";
18
+ import { a as defaultAskPermissions, i as askAgents, l as launchAskAgent, n as askAgentSettings, o as detectAskAgents, r as askAgentTakesMcp, t as fuzzyRank } from "./fuzzy-match-BNLXmpbv.js";
19
+ import { a as inspectQuerySchema, i as renderInstructions, o as queryAnchor, r as instructionsQuerySchema, s as readQuerySchemas, t as authoringTools } from "./authoring-tools-DmIJZq0b.js";
20
+ import { a as headlessServerOwner, c as stopBackgroundServer, o as recordedBackgroundServer } from "./background-server-B1uwDQTr.js";
21
21
  import crypto$1, { createHash, randomBytes, randomUUID } from "node:crypto";
22
22
  import { z } from "zod";
23
23
  import { existsSync, mkdirSync, writeFileSync } from "node:fs";
@@ -3136,6 +3136,14 @@ function documentText(snapshot, targetId, full = false, relations) {
3136
3136
  }
3137
3137
  for (const edge of element.edges) detail(`[${edge.id}] ${edge.from} → ${edge.to}${edge.label ? `: ${edge.label}` : ""}`);
3138
3138
  break;
3139
+ case "animation":
3140
+ for (const [index, frame] of element.frames.entries()) detail(`Frame ${index + 1} [${frame.key}]: ${frame.title}${frame.caption ? ` — ${frame.caption}` : ""}`);
3141
+ for (const [name, anchor] of Object.entries(element.code)) detail(`Code ${name}: ${anchor}`);
3142
+ if (detailed) code(depth + 1, {
3143
+ language: "html",
3144
+ text: element.html
3145
+ });
3146
+ break;
3139
3147
  case "software_map": detail(`Map: ${element.mapVersionId}${element.focusElementId ? `, focus: ${element.focusElementId}` : ""}`);
3140
3148
  }
3141
3149
  };
@@ -3638,7 +3646,7 @@ const remoteCaller = (context) => context.req.header(REVIEW_CLIENT_HEADER) === R
3638
3646
  function createReviewApi(store, data, open, shared, capabilities = () => ({
3639
3647
  desktopAvailable: Boolean(open),
3640
3648
  softwareMapEnabled: false
3641
- }), traceEnabled = async () => false, status = () => ({}), hooks = {}, ask) {
3649
+ }), traceEnabled = async () => false, status = () => ({}), hooks = {}, ask, animationsEnabled = () => false) {
3642
3650
  const app = new Hono();
3643
3651
  app.onError((error, context) => {
3644
3652
  if (error instanceof HttpJsonError) return context.json({ error: error.message }, error.statusCode);
@@ -3729,10 +3737,13 @@ function createReviewApi(store, data, open, shared, capabilities = () => ({
3729
3737
  };
3730
3738
  app.get("/", (context) => context.json(catalog()));
3731
3739
  app.get("/feedback-eligibility", (context) => context.json({ eligible: store.feedbackEligible() }));
3732
- const instructionContext = async () => ({ traceEnabled: await traceEnabled() });
3740
+ const instructionContext = async () => ({
3741
+ traceEnabled: await traceEnabled(),
3742
+ animationsEnabled: animationsEnabled()
3743
+ });
3733
3744
  app.get("/authoring", async (context) => {
3734
3745
  const instructions = await instructionContext();
3735
- return context.json(authoringTools(instructions.traceEnabled));
3746
+ return context.json(authoringTools(instructions.traceEnabled, instructions.animationsEnabled));
3736
3747
  });
3737
3748
  app.get("/instructions", async (context) => {
3738
3749
  const { topic } = instructionsQuerySchema.parse(context.req.query());
@@ -3786,7 +3797,10 @@ function createReviewApi(store, data, open, shared, capabilities = () => ({
3786
3797
  ...status(),
3787
3798
  desktopAvailable: (await capabilities()).desktopAvailable
3788
3799
  }));
3789
- app.get("/capabilities", async (context) => context.json(await capabilities()));
3800
+ app.get("/capabilities", async (context) => context.json({
3801
+ ...await capabilities(),
3802
+ animationsEnabled: animationsEnabled()
3803
+ }));
3790
3804
  app.get("/:id/activity", (context) => {
3791
3805
  const id = context.req.param("id");
3792
3806
  readReview(id);
@@ -4721,6 +4735,12 @@ function createReviewApi(store, data, open, shared, capabilities = () => ({
4721
4735
  const register = async (path) => data ? data.register(path) : store.registerRepository(path);
4722
4736
  const request = withBoardRepository(await locateRepositories(await pullRequestTargets(body, register, (id) => store.read(id)), register), (id) => store.has(id) ? store.read(id) : void 0);
4723
4737
  const input = commandSchema.parse(request);
4738
+ if (!animationsEnabled() && input.operation.type === "edit") {
4739
+ const { edit, reviewId } = input.operation;
4740
+ const incoming = "content" in edit ? elements([edit.content]) : [];
4741
+ const target = "targetId" in edit ? elements(readReview(reviewId).document).find((element) => element.id === edit.targetId) : void 0;
4742
+ if (incoming.some((element) => element.type === "animation") || target?.type === "animation") throw new ReviewInputError("Animation authoring is disabled. Enable Animations in Settings under Experimental Features to edit animations. Existing animations can still be viewed.", 409);
4743
+ }
4724
4744
  const command = sharedCommandSchema.safeParse(input);
4725
4745
  if (command.success && command.data.operation.reviewId?.startsWith("shared-")) {
4726
4746
  const parsed = commandSchema.parse(input);
@@ -5096,7 +5116,7 @@ function createWhiteboardCore(input) {
5096
5116
  const api = createReviewApi(store, data, callbacks.open, shared, callbacks.capabilities, () => traceMachineEnabled(), input.status, input.hooks, askThreads && {
5097
5117
  threads: askThreads,
5098
5118
  agents: async () => detectAskAgents(await ask?.env)
5099
- });
5119
+ }, input.animations);
5100
5120
  if (!shared) mountSharingPublisher(api, store, data);
5101
5121
  return {
5102
5122
  app,
@@ -1,4 +1,4 @@
1
- import "./src-DYHVzX3b.js";
1
+ import "./src-DEOc8bvC.js";
2
2
  import { z } from "zod";
3
3
  //#region src/viewed-coverage.ts
4
4
  const coverageSchema = z.object({