@deskwork/core 0.12.1 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/doctor/repair.d.ts.map +1 -1
- package/dist/doctor/repair.js +91 -4
- package/dist/doctor/repair.js.map +1 -1
- package/dist/doctor/validate.d.ts +1 -1
- package/dist/doctor/validate.d.ts.map +1 -1
- package/dist/doctor/validate.js +43 -0
- package/dist/doctor/validate.js.map +1 -1
- package/dist/entry/annotations.d.ts +42 -0
- package/dist/entry/annotations.d.ts.map +1 -0
- package/dist/entry/annotations.js +121 -0
- package/dist/entry/annotations.js.map +1 -0
- package/dist/iterate/history.d.ts +42 -0
- package/dist/iterate/history.d.ts.map +1 -0
- package/dist/iterate/history.js +64 -0
- package/dist/iterate/history.js.map +1 -0
- package/dist/review/pipeline.d.ts.map +1 -1
- package/dist/review/pipeline.js +11 -1
- package/dist/review/pipeline.js.map +1 -1
- package/dist/schema/draft-annotation.d.ts +171 -0
- package/dist/schema/draft-annotation.d.ts.map +1 -0
- package/dist/schema/draft-annotation.js +87 -0
- package/dist/schema/draft-annotation.js.map +1 -0
- package/dist/schema/entry.d.ts +12 -12
- package/dist/schema/journal-events.d.ts +291 -20
- package/dist/schema/journal-events.d.ts.map +1 -1
- package/dist/schema/journal-events.js +17 -0
- package/dist/schema/journal-events.js.map +1 -1
- package/package.json +9 -1
|
@@ -56,8 +56,8 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
56
56
|
shortformWorkflows?: Record<string, string> | undefined;
|
|
57
57
|
}>;
|
|
58
58
|
}, "strip", z.ZodTypeAny, {
|
|
59
|
-
at: string;
|
|
60
59
|
kind: "entry-created";
|
|
60
|
+
at: string;
|
|
61
61
|
entryId: string;
|
|
62
62
|
entry: {
|
|
63
63
|
uuid: string;
|
|
@@ -78,8 +78,8 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
78
78
|
shortformWorkflows?: Record<string, string> | undefined;
|
|
79
79
|
};
|
|
80
80
|
}, {
|
|
81
|
-
at: string;
|
|
82
81
|
kind: "entry-created";
|
|
82
|
+
at: string;
|
|
83
83
|
entryId: string;
|
|
84
84
|
entry: {
|
|
85
85
|
uuid: string;
|
|
@@ -106,14 +106,14 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
106
106
|
sourcePath: z.ZodString;
|
|
107
107
|
targetStage: z.ZodEnum<["Ideas", "Planned", "Outlining", "Drafting", "Final", "Published", "Blocked", "Cancelled"]>;
|
|
108
108
|
}, "strip", z.ZodTypeAny, {
|
|
109
|
-
at: string;
|
|
110
109
|
kind: "entry-ingested";
|
|
110
|
+
at: string;
|
|
111
111
|
entryId: string;
|
|
112
112
|
sourcePath: string;
|
|
113
113
|
targetStage: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
114
114
|
}, {
|
|
115
|
-
at: string;
|
|
116
115
|
kind: "entry-ingested";
|
|
116
|
+
at: string;
|
|
117
117
|
entryId: string;
|
|
118
118
|
sourcePath: string;
|
|
119
119
|
targetStage: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
@@ -125,18 +125,18 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
125
125
|
version: z.ZodNumber;
|
|
126
126
|
markdown: z.ZodString;
|
|
127
127
|
}, "strip", z.ZodTypeAny, {
|
|
128
|
-
version: number;
|
|
129
|
-
at: string;
|
|
130
128
|
kind: "iteration";
|
|
129
|
+
at: string;
|
|
131
130
|
entryId: string;
|
|
132
131
|
stage: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
132
|
+
version: number;
|
|
133
133
|
markdown: string;
|
|
134
134
|
}, {
|
|
135
|
-
version: number;
|
|
136
|
-
at: string;
|
|
137
135
|
kind: "iteration";
|
|
136
|
+
at: string;
|
|
138
137
|
entryId: string;
|
|
139
138
|
stage: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
139
|
+
version: number;
|
|
140
140
|
markdown: string;
|
|
141
141
|
}>, z.ZodObject<{
|
|
142
142
|
kind: z.ZodLiteral<"annotation">;
|
|
@@ -172,8 +172,8 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
172
172
|
end: number;
|
|
173
173
|
};
|
|
174
174
|
text: string;
|
|
175
|
-
anchor?: string | undefined;
|
|
176
175
|
category?: string | undefined;
|
|
176
|
+
anchor?: string | undefined;
|
|
177
177
|
disposition?: "addressed" | "deferred" | "wontfix" | undefined;
|
|
178
178
|
dispositionReason?: string | undefined;
|
|
179
179
|
}, {
|
|
@@ -185,17 +185,17 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
185
185
|
end: number;
|
|
186
186
|
};
|
|
187
187
|
text: string;
|
|
188
|
-
anchor?: string | undefined;
|
|
189
188
|
category?: string | undefined;
|
|
189
|
+
anchor?: string | undefined;
|
|
190
190
|
disposition?: "addressed" | "deferred" | "wontfix" | undefined;
|
|
191
191
|
dispositionReason?: string | undefined;
|
|
192
192
|
}>;
|
|
193
193
|
}, "strip", z.ZodTypeAny, {
|
|
194
|
-
version: number;
|
|
195
|
-
at: string;
|
|
196
194
|
kind: "annotation";
|
|
195
|
+
at: string;
|
|
197
196
|
entryId: string;
|
|
198
197
|
stage: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
198
|
+
version: number;
|
|
199
199
|
annotation: {
|
|
200
200
|
type: "comment";
|
|
201
201
|
createdAt: string;
|
|
@@ -205,17 +205,17 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
205
205
|
end: number;
|
|
206
206
|
};
|
|
207
207
|
text: string;
|
|
208
|
-
anchor?: string | undefined;
|
|
209
208
|
category?: string | undefined;
|
|
209
|
+
anchor?: string | undefined;
|
|
210
210
|
disposition?: "addressed" | "deferred" | "wontfix" | undefined;
|
|
211
211
|
dispositionReason?: string | undefined;
|
|
212
212
|
};
|
|
213
213
|
}, {
|
|
214
|
-
version: number;
|
|
215
|
-
at: string;
|
|
216
214
|
kind: "annotation";
|
|
215
|
+
at: string;
|
|
217
216
|
entryId: string;
|
|
218
217
|
stage: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
218
|
+
version: number;
|
|
219
219
|
annotation: {
|
|
220
220
|
type: "comment";
|
|
221
221
|
createdAt: string;
|
|
@@ -225,8 +225,8 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
225
225
|
end: number;
|
|
226
226
|
};
|
|
227
227
|
text: string;
|
|
228
|
-
anchor?: string | undefined;
|
|
229
228
|
category?: string | undefined;
|
|
229
|
+
anchor?: string | undefined;
|
|
230
230
|
disposition?: "addressed" | "deferred" | "wontfix" | undefined;
|
|
231
231
|
dispositionReason?: string | undefined;
|
|
232
232
|
};
|
|
@@ -238,15 +238,15 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
238
238
|
from: z.ZodNullable<z.ZodEnum<["in-review", "iterating", "approved"]>>;
|
|
239
239
|
to: z.ZodNullable<z.ZodEnum<["in-review", "iterating", "approved"]>>;
|
|
240
240
|
}, "strip", z.ZodTypeAny, {
|
|
241
|
-
at: string;
|
|
242
241
|
kind: "review-state-change";
|
|
242
|
+
at: string;
|
|
243
243
|
entryId: string;
|
|
244
244
|
stage: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
245
245
|
from: "in-review" | "iterating" | "approved" | null;
|
|
246
246
|
to: "in-review" | "iterating" | "approved" | null;
|
|
247
247
|
}, {
|
|
248
|
-
at: string;
|
|
249
248
|
kind: "review-state-change";
|
|
249
|
+
at: string;
|
|
250
250
|
entryId: string;
|
|
251
251
|
stage: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
252
252
|
from: "in-review" | "iterating" | "approved" | null;
|
|
@@ -260,21 +260,292 @@ export declare const JournalEventSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
260
260
|
reason: z.ZodOptional<z.ZodString>;
|
|
261
261
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
262
262
|
}, "strip", z.ZodTypeAny, {
|
|
263
|
-
at: string;
|
|
264
263
|
kind: "stage-transition";
|
|
264
|
+
at: string;
|
|
265
265
|
entryId: string;
|
|
266
266
|
from: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
267
267
|
to: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
268
268
|
reason?: string | undefined;
|
|
269
269
|
metadata?: Record<string, unknown> | undefined;
|
|
270
270
|
}, {
|
|
271
|
-
at: string;
|
|
272
271
|
kind: "stage-transition";
|
|
272
|
+
at: string;
|
|
273
273
|
entryId: string;
|
|
274
274
|
from: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
275
275
|
to: "Ideas" | "Planned" | "Outlining" | "Drafting" | "Final" | "Published" | "Blocked" | "Cancelled";
|
|
276
276
|
reason?: string | undefined;
|
|
277
277
|
metadata?: Record<string, unknown> | undefined;
|
|
278
|
+
}>, z.ZodObject<{
|
|
279
|
+
kind: z.ZodLiteral<"entry-annotation">;
|
|
280
|
+
at: z.ZodString;
|
|
281
|
+
entryId: z.ZodString;
|
|
282
|
+
annotation: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
283
|
+
type: z.ZodLiteral<"comment">;
|
|
284
|
+
version: z.ZodNumber;
|
|
285
|
+
range: z.ZodObject<{
|
|
286
|
+
start: z.ZodNumber;
|
|
287
|
+
end: z.ZodNumber;
|
|
288
|
+
}, "strip", z.ZodTypeAny, {
|
|
289
|
+
start: number;
|
|
290
|
+
end: number;
|
|
291
|
+
}, {
|
|
292
|
+
start: number;
|
|
293
|
+
end: number;
|
|
294
|
+
}>;
|
|
295
|
+
text: z.ZodString;
|
|
296
|
+
category: z.ZodOptional<z.ZodEnum<["voice-drift", "missing-receipt", "tutorial-framing", "saas-vocabulary", "fake-authority", "structural", "other"]>>;
|
|
297
|
+
anchor: z.ZodOptional<z.ZodString>;
|
|
298
|
+
createdAt: z.ZodString;
|
|
299
|
+
workflowId: z.ZodString;
|
|
300
|
+
id: z.ZodString;
|
|
301
|
+
}, "strip", z.ZodTypeAny, {
|
|
302
|
+
type: "comment";
|
|
303
|
+
createdAt: string;
|
|
304
|
+
version: number;
|
|
305
|
+
id: string;
|
|
306
|
+
range: {
|
|
307
|
+
start: number;
|
|
308
|
+
end: number;
|
|
309
|
+
};
|
|
310
|
+
text: string;
|
|
311
|
+
workflowId: string;
|
|
312
|
+
category?: "voice-drift" | "missing-receipt" | "tutorial-framing" | "saas-vocabulary" | "fake-authority" | "structural" | "other" | undefined;
|
|
313
|
+
anchor?: string | undefined;
|
|
314
|
+
}, {
|
|
315
|
+
type: "comment";
|
|
316
|
+
createdAt: string;
|
|
317
|
+
version: number;
|
|
318
|
+
id: string;
|
|
319
|
+
range: {
|
|
320
|
+
start: number;
|
|
321
|
+
end: number;
|
|
322
|
+
};
|
|
323
|
+
text: string;
|
|
324
|
+
workflowId: string;
|
|
325
|
+
category?: "voice-drift" | "missing-receipt" | "tutorial-framing" | "saas-vocabulary" | "fake-authority" | "structural" | "other" | undefined;
|
|
326
|
+
anchor?: string | undefined;
|
|
327
|
+
}>, z.ZodObject<{
|
|
328
|
+
type: z.ZodLiteral<"edit">;
|
|
329
|
+
beforeVersion: z.ZodNumber;
|
|
330
|
+
afterMarkdown: z.ZodString;
|
|
331
|
+
diff: z.ZodString;
|
|
332
|
+
createdAt: z.ZodString;
|
|
333
|
+
workflowId: z.ZodString;
|
|
334
|
+
id: z.ZodString;
|
|
335
|
+
}, "strip", z.ZodTypeAny, {
|
|
336
|
+
type: "edit";
|
|
337
|
+
createdAt: string;
|
|
338
|
+
id: string;
|
|
339
|
+
workflowId: string;
|
|
340
|
+
beforeVersion: number;
|
|
341
|
+
afterMarkdown: string;
|
|
342
|
+
diff: string;
|
|
343
|
+
}, {
|
|
344
|
+
type: "edit";
|
|
345
|
+
createdAt: string;
|
|
346
|
+
id: string;
|
|
347
|
+
workflowId: string;
|
|
348
|
+
beforeVersion: number;
|
|
349
|
+
afterMarkdown: string;
|
|
350
|
+
diff: string;
|
|
351
|
+
}>, z.ZodObject<{
|
|
352
|
+
type: z.ZodLiteral<"approve">;
|
|
353
|
+
version: z.ZodNumber;
|
|
354
|
+
createdAt: z.ZodString;
|
|
355
|
+
workflowId: z.ZodString;
|
|
356
|
+
id: z.ZodString;
|
|
357
|
+
}, "strip", z.ZodTypeAny, {
|
|
358
|
+
type: "approve";
|
|
359
|
+
createdAt: string;
|
|
360
|
+
version: number;
|
|
361
|
+
id: string;
|
|
362
|
+
workflowId: string;
|
|
363
|
+
}, {
|
|
364
|
+
type: "approve";
|
|
365
|
+
createdAt: string;
|
|
366
|
+
version: number;
|
|
367
|
+
id: string;
|
|
368
|
+
workflowId: string;
|
|
369
|
+
}>, z.ZodObject<{
|
|
370
|
+
type: z.ZodLiteral<"reject">;
|
|
371
|
+
version: z.ZodNumber;
|
|
372
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
373
|
+
createdAt: z.ZodString;
|
|
374
|
+
workflowId: z.ZodString;
|
|
375
|
+
id: z.ZodString;
|
|
376
|
+
}, "strip", z.ZodTypeAny, {
|
|
377
|
+
type: "reject";
|
|
378
|
+
createdAt: string;
|
|
379
|
+
version: number;
|
|
380
|
+
id: string;
|
|
381
|
+
workflowId: string;
|
|
382
|
+
reason?: string | undefined;
|
|
383
|
+
}, {
|
|
384
|
+
type: "reject";
|
|
385
|
+
createdAt: string;
|
|
386
|
+
version: number;
|
|
387
|
+
id: string;
|
|
388
|
+
workflowId: string;
|
|
389
|
+
reason?: string | undefined;
|
|
390
|
+
}>, z.ZodObject<{
|
|
391
|
+
type: z.ZodLiteral<"resolve">;
|
|
392
|
+
commentId: z.ZodString;
|
|
393
|
+
resolved: z.ZodBoolean;
|
|
394
|
+
createdAt: z.ZodString;
|
|
395
|
+
workflowId: z.ZodString;
|
|
396
|
+
id: z.ZodString;
|
|
397
|
+
}, "strip", z.ZodTypeAny, {
|
|
398
|
+
type: "resolve";
|
|
399
|
+
createdAt: string;
|
|
400
|
+
id: string;
|
|
401
|
+
workflowId: string;
|
|
402
|
+
commentId: string;
|
|
403
|
+
resolved: boolean;
|
|
404
|
+
}, {
|
|
405
|
+
type: "resolve";
|
|
406
|
+
createdAt: string;
|
|
407
|
+
id: string;
|
|
408
|
+
workflowId: string;
|
|
409
|
+
commentId: string;
|
|
410
|
+
resolved: boolean;
|
|
411
|
+
}>, z.ZodObject<{
|
|
412
|
+
type: z.ZodLiteral<"address">;
|
|
413
|
+
commentId: z.ZodString;
|
|
414
|
+
version: z.ZodNumber;
|
|
415
|
+
disposition: z.ZodEnum<["addressed", "deferred", "wontfix"]>;
|
|
416
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
417
|
+
createdAt: z.ZodString;
|
|
418
|
+
workflowId: z.ZodString;
|
|
419
|
+
id: z.ZodString;
|
|
420
|
+
}, "strip", z.ZodTypeAny, {
|
|
421
|
+
type: "address";
|
|
422
|
+
createdAt: string;
|
|
423
|
+
version: number;
|
|
424
|
+
id: string;
|
|
425
|
+
disposition: "addressed" | "deferred" | "wontfix";
|
|
426
|
+
workflowId: string;
|
|
427
|
+
commentId: string;
|
|
428
|
+
reason?: string | undefined;
|
|
429
|
+
}, {
|
|
430
|
+
type: "address";
|
|
431
|
+
createdAt: string;
|
|
432
|
+
version: number;
|
|
433
|
+
id: string;
|
|
434
|
+
disposition: "addressed" | "deferred" | "wontfix";
|
|
435
|
+
workflowId: string;
|
|
436
|
+
commentId: string;
|
|
437
|
+
reason?: string | undefined;
|
|
438
|
+
}>]>;
|
|
439
|
+
}, "strip", z.ZodTypeAny, {
|
|
440
|
+
kind: "entry-annotation";
|
|
441
|
+
at: string;
|
|
442
|
+
entryId: string;
|
|
443
|
+
annotation: {
|
|
444
|
+
type: "comment";
|
|
445
|
+
createdAt: string;
|
|
446
|
+
version: number;
|
|
447
|
+
id: string;
|
|
448
|
+
range: {
|
|
449
|
+
start: number;
|
|
450
|
+
end: number;
|
|
451
|
+
};
|
|
452
|
+
text: string;
|
|
453
|
+
workflowId: string;
|
|
454
|
+
category?: "voice-drift" | "missing-receipt" | "tutorial-framing" | "saas-vocabulary" | "fake-authority" | "structural" | "other" | undefined;
|
|
455
|
+
anchor?: string | undefined;
|
|
456
|
+
} | {
|
|
457
|
+
type: "edit";
|
|
458
|
+
createdAt: string;
|
|
459
|
+
id: string;
|
|
460
|
+
workflowId: string;
|
|
461
|
+
beforeVersion: number;
|
|
462
|
+
afterMarkdown: string;
|
|
463
|
+
diff: string;
|
|
464
|
+
} | {
|
|
465
|
+
type: "approve";
|
|
466
|
+
createdAt: string;
|
|
467
|
+
version: number;
|
|
468
|
+
id: string;
|
|
469
|
+
workflowId: string;
|
|
470
|
+
} | {
|
|
471
|
+
type: "reject";
|
|
472
|
+
createdAt: string;
|
|
473
|
+
version: number;
|
|
474
|
+
id: string;
|
|
475
|
+
workflowId: string;
|
|
476
|
+
reason?: string | undefined;
|
|
477
|
+
} | {
|
|
478
|
+
type: "resolve";
|
|
479
|
+
createdAt: string;
|
|
480
|
+
id: string;
|
|
481
|
+
workflowId: string;
|
|
482
|
+
commentId: string;
|
|
483
|
+
resolved: boolean;
|
|
484
|
+
} | {
|
|
485
|
+
type: "address";
|
|
486
|
+
createdAt: string;
|
|
487
|
+
version: number;
|
|
488
|
+
id: string;
|
|
489
|
+
disposition: "addressed" | "deferred" | "wontfix";
|
|
490
|
+
workflowId: string;
|
|
491
|
+
commentId: string;
|
|
492
|
+
reason?: string | undefined;
|
|
493
|
+
};
|
|
494
|
+
}, {
|
|
495
|
+
kind: "entry-annotation";
|
|
496
|
+
at: string;
|
|
497
|
+
entryId: string;
|
|
498
|
+
annotation: {
|
|
499
|
+
type: "comment";
|
|
500
|
+
createdAt: string;
|
|
501
|
+
version: number;
|
|
502
|
+
id: string;
|
|
503
|
+
range: {
|
|
504
|
+
start: number;
|
|
505
|
+
end: number;
|
|
506
|
+
};
|
|
507
|
+
text: string;
|
|
508
|
+
workflowId: string;
|
|
509
|
+
category?: "voice-drift" | "missing-receipt" | "tutorial-framing" | "saas-vocabulary" | "fake-authority" | "structural" | "other" | undefined;
|
|
510
|
+
anchor?: string | undefined;
|
|
511
|
+
} | {
|
|
512
|
+
type: "edit";
|
|
513
|
+
createdAt: string;
|
|
514
|
+
id: string;
|
|
515
|
+
workflowId: string;
|
|
516
|
+
beforeVersion: number;
|
|
517
|
+
afterMarkdown: string;
|
|
518
|
+
diff: string;
|
|
519
|
+
} | {
|
|
520
|
+
type: "approve";
|
|
521
|
+
createdAt: string;
|
|
522
|
+
version: number;
|
|
523
|
+
id: string;
|
|
524
|
+
workflowId: string;
|
|
525
|
+
} | {
|
|
526
|
+
type: "reject";
|
|
527
|
+
createdAt: string;
|
|
528
|
+
version: number;
|
|
529
|
+
id: string;
|
|
530
|
+
workflowId: string;
|
|
531
|
+
reason?: string | undefined;
|
|
532
|
+
} | {
|
|
533
|
+
type: "resolve";
|
|
534
|
+
createdAt: string;
|
|
535
|
+
id: string;
|
|
536
|
+
workflowId: string;
|
|
537
|
+
commentId: string;
|
|
538
|
+
resolved: boolean;
|
|
539
|
+
} | {
|
|
540
|
+
type: "address";
|
|
541
|
+
createdAt: string;
|
|
542
|
+
version: number;
|
|
543
|
+
id: string;
|
|
544
|
+
disposition: "addressed" | "deferred" | "wontfix";
|
|
545
|
+
workflowId: string;
|
|
546
|
+
commentId: string;
|
|
547
|
+
reason?: string | undefined;
|
|
548
|
+
};
|
|
278
549
|
}>]>;
|
|
279
550
|
export type JournalEvent = z.infer<typeof JournalEventSchema>;
|
|
280
551
|
//# sourceMappingURL=journal-events.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"journal-events.d.ts","sourceRoot":"","sources":["../../src/schema/journal-events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"journal-events.d.ts","sourceRoot":"","sources":["../../src/schema/journal-events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AA4ExB,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAQ7B,CAAC;AAEH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
import { EntrySchema } from "./entry.js";
|
|
3
3
|
import { AnnotationSchema } from "./annotation.js";
|
|
4
|
+
import { DraftAnnotationSchema } from "./draft-annotation.js";
|
|
4
5
|
const StageEnum = z.enum(['Ideas', 'Planned', 'Outlining', 'Drafting', 'Final', 'Published', 'Blocked', 'Cancelled']);
|
|
5
6
|
const ReviewStateEnum = z.enum(['in-review', 'iterating', 'approved']);
|
|
6
7
|
const EntryCreatedEvent = z.object({
|
|
@@ -49,6 +50,21 @@ const StageTransitionEvent = z.object({
|
|
|
49
50
|
reason: z.string().optional(),
|
|
50
51
|
metadata: z.record(z.string(), z.unknown()).optional(),
|
|
51
52
|
});
|
|
53
|
+
/**
|
|
54
|
+
* Phase 34a: entry-keyed annotation event. Distinct from `AnnotationEvent`
|
|
55
|
+
* (which uses the lighter `AnnotationSchema` and is keyed on
|
|
56
|
+
* `(entryId, stage, version)`), this event carries the full
|
|
57
|
+
* `DraftAnnotation` shape used by the longform review surface, keyed
|
|
58
|
+
* on `entryId` only. The two stores intentionally do not interoperate
|
|
59
|
+
* — see `entry/annotations.ts` and the api.ts header for the split
|
|
60
|
+
* contract.
|
|
61
|
+
*/
|
|
62
|
+
const EntryAnnotationEvent = z.object({
|
|
63
|
+
kind: z.literal('entry-annotation'),
|
|
64
|
+
at: z.string().datetime(),
|
|
65
|
+
entryId: z.string().uuid(),
|
|
66
|
+
annotation: DraftAnnotationSchema,
|
|
67
|
+
});
|
|
52
68
|
export const JournalEventSchema = z.discriminatedUnion('kind', [
|
|
53
69
|
EntryCreatedEvent,
|
|
54
70
|
EntryIngestedEvent,
|
|
@@ -56,5 +72,6 @@ export const JournalEventSchema = z.discriminatedUnion('kind', [
|
|
|
56
72
|
AnnotationEvent,
|
|
57
73
|
ReviewStateChangeEvent,
|
|
58
74
|
StageTransitionEvent,
|
|
75
|
+
EntryAnnotationEvent,
|
|
59
76
|
]);
|
|
60
77
|
//# sourceMappingURL=journal-events.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"journal-events.js","sourceRoot":"","sources":["../../src/schema/journal-events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AACzC,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"journal-events.js","sourceRoot":"","sources":["../../src/schema/journal-events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AACzC,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACnD,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAE9D,MAAM,SAAS,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,UAAU,EAAE,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,WAAW,CAAC,CAAC,CAAC;AACtH,MAAM,eAAe,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,WAAW,EAAE,WAAW,EAAE,UAAU,CAAC,CAAC,CAAC;AAEvE,MAAM,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC;IACjC,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,eAAe,CAAC;IAChC,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACzB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE;IAC1B,KAAK,EAAE,WAAW;CACnB,CAAC,CAAC;AAEH,MAAM,kBAAkB,GAAG,CAAC,CAAC,MAAM,CAAC;IAClC,IAAI,EAAE,CAAC,CAAC,OAAO,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": "module",
|
|
5
5
|
"description": "Editorial calendar + review pipeline library — shared by @deskwork/cli and @deskwork/studio",
|
|
6
6
|
"homepage": "https://github.com/audiocontrol-org/deskwork#readme",
|
|
@@ -92,10 +92,18 @@
|
|
|
92
92
|
"types": "./dist/iterate/iterate.d.ts",
|
|
93
93
|
"default": "./dist/iterate/iterate.js"
|
|
94
94
|
},
|
|
95
|
+
"./iterate/history": {
|
|
96
|
+
"types": "./dist/iterate/history.d.ts",
|
|
97
|
+
"default": "./dist/iterate/history.js"
|
|
98
|
+
},
|
|
95
99
|
"./calendar/regenerate": {
|
|
96
100
|
"types": "./dist/calendar/regenerate.d.ts",
|
|
97
101
|
"default": "./dist/calendar/regenerate.js"
|
|
98
102
|
},
|
|
103
|
+
"./entry/annotations": {
|
|
104
|
+
"types": "./dist/entry/annotations.d.ts",
|
|
105
|
+
"default": "./dist/entry/annotations.js"
|
|
106
|
+
},
|
|
99
107
|
"./entry/approve": {
|
|
100
108
|
"types": "./dist/entry/approve.d.ts",
|
|
101
109
|
"default": "./dist/entry/approve.js"
|