@arbidocs/blocks 0.5.28 → 0.5.29
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/{ConnectedCallDock-TGMZA7MF.js → ConnectedCallDock-FDGMFTS5.js} +13 -13
- package/dist/{ConnectedCallDock-TGMZA7MF.js.map → ConnectedCallDock-FDGMFTS5.js.map} +1 -1
- package/dist/{ConnectedCallDock-JXIUS5EZ.cjs → ConnectedCallDock-ZIX2ZJCD.cjs} +22 -22
- package/dist/{ConnectedCallDock-JXIUS5EZ.cjs.map → ConnectedCallDock-ZIX2ZJCD.cjs.map} +1 -1
- package/dist/{ConnectedCallRoom-XT6RIY3Y.js → ConnectedCallRoom-VJIHEJ4X.js} +13 -13
- package/dist/{ConnectedCallRoom-XT6RIY3Y.js.map → ConnectedCallRoom-VJIHEJ4X.js.map} +1 -1
- package/dist/{ConnectedCallRoom-5MKMJNKB.cjs → ConnectedCallRoom-WZQVXDDW.cjs} +14 -14
- package/dist/{ConnectedCallRoom-5MKMJNKB.cjs.map → ConnectedCallRoom-WZQVXDDW.cjs.map} +1 -1
- package/dist/{ConnectedStreamedWordArtifact-7LZ7JGQO.js → ConnectedNativeDocxComparison-7ZC7BRY4.js} +20 -20
- package/dist/{ConnectedNativeDocxComparison-MTXCZ3AC.js.map → ConnectedNativeDocxComparison-7ZC7BRY4.js.map} +1 -1
- package/dist/{ConnectedNativeDocxComparison-LOPGQS2C.cjs → ConnectedNativeDocxComparison-KSLSDAAP.cjs} +21 -21
- package/dist/{ConnectedNativeDocxComparison-LOPGQS2C.cjs.map → ConnectedNativeDocxComparison-KSLSDAAP.cjs.map} +1 -1
- package/dist/{ConnectedNativeDocxEditor-YPVR3JJA.cjs → ConnectedNativeDocxEditor-5E64Q7FX.cjs} +20 -20
- package/dist/{ConnectedNativeDocxEditor-YPVR3JJA.cjs.map → ConnectedNativeDocxEditor-5E64Q7FX.cjs.map} +1 -1
- package/dist/{ConnectedNativeDocxEditor-564OVLLE.js → ConnectedNativeDocxEditor-B5KDDPRY.js} +18 -18
- package/dist/{ConnectedNativeDocxEditor-564OVLLE.js.map → ConnectedNativeDocxEditor-B5KDDPRY.js.map} +1 -1
- package/dist/{ConnectedStreamedWordArtifact-DZMB2MWZ.cjs → ConnectedStreamedWordArtifact-RLU5VYGO.cjs} +21 -21
- package/dist/ConnectedStreamedWordArtifact-RLU5VYGO.cjs.map +1 -0
- package/dist/{ConnectedNativeDocxComparison-MTXCZ3AC.js → ConnectedStreamedWordArtifact-YCQSIGXL.js} +20 -20
- package/dist/ConnectedStreamedWordArtifact-YCQSIGXL.js.map +1 -0
- package/dist/{NativeDocxEditor-QP5HFNXU.cjs → NativeDocxEditor-JUTTA46L.cjs} +8 -8
- package/dist/{NativeDocxEditor-QP5HFNXU.cjs.map → NativeDocxEditor-JUTTA46L.cjs.map} +1 -1
- package/dist/{NativeDocxEditor-4WPGYK45.js → NativeDocxEditor-PSC3JWWA.js} +4 -4
- package/dist/{NativeDocxEditor-4WPGYK45.js.map → NativeDocxEditor-PSC3JWWA.js.map} +1 -1
- package/dist/{WorkspaceTableView-ULKEXXHS.js → WorkspaceTableView-62PJLX7V.js} +9 -9
- package/dist/{WorkspaceTableView-ULKEXXHS.js.map → WorkspaceTableView-62PJLX7V.js.map} +1 -1
- package/dist/{WorkspaceTableView-NSPR2TZ7.cjs → WorkspaceTableView-BUWRSR42.cjs} +11 -11
- package/dist/{WorkspaceTableView-NSPR2TZ7.cjs.map → WorkspaceTableView-BUWRSR42.cjs.map} +1 -1
- package/dist/agents/index.cjs +438 -438
- package/dist/agents/index.js +13 -13
- package/dist/calls/index.cjs +132 -132
- package/dist/calls/index.js +10 -10
- package/dist/chat/index.cjs +166 -166
- package/dist/chat/index.js +8 -8
- package/dist/{chunk-Q6ETAFB4.js → chunk-3OKBEVP3.js} +3 -3
- package/dist/{chunk-Q6ETAFB4.js.map → chunk-3OKBEVP3.js.map} +1 -1
- package/dist/{chunk-5R243VPF.cjs → chunk-3PQPA5K6.cjs} +14 -14
- package/dist/{chunk-5R243VPF.cjs.map → chunk-3PQPA5K6.cjs.map} +1 -1
- package/dist/{chunk-ZMWRZI66.js → chunk-46XON6PW.js} +4 -4
- package/dist/{chunk-ZMWRZI66.js.map → chunk-46XON6PW.js.map} +1 -1
- package/dist/{chunk-EZLZ3MDU.cjs → chunk-4RMI6D64.cjs} +3 -3
- package/dist/{chunk-EZLZ3MDU.cjs.map → chunk-4RMI6D64.cjs.map} +1 -1
- package/dist/{chunk-AIEXKQVO.cjs → chunk-4S34OHJX.cjs} +4 -4
- package/dist/{chunk-AIEXKQVO.cjs.map → chunk-4S34OHJX.cjs.map} +1 -1
- package/dist/{chunk-55LYXJCV.js → chunk-4UREQY5X.js} +4 -4
- package/dist/{chunk-55LYXJCV.js.map → chunk-4UREQY5X.js.map} +1 -1
- package/dist/{chunk-JR7IJ3F7.cjs → chunk-52GITM4V.cjs} +89 -89
- package/dist/{chunk-JR7IJ3F7.cjs.map → chunk-52GITM4V.cjs.map} +1 -1
- package/dist/{chunk-5PLCEFEP.cjs → chunk-5H37UWWS.cjs} +5 -5
- package/dist/{chunk-5PLCEFEP.cjs.map → chunk-5H37UWWS.cjs.map} +1 -1
- package/dist/{chunk-PUP4IWAO.js → chunk-7FKVJUR4.js} +3 -3
- package/dist/{chunk-PUP4IWAO.js.map → chunk-7FKVJUR4.js.map} +1 -1
- package/dist/{chunk-STD62GEA.cjs → chunk-7U2DNPMZ.cjs} +20 -20
- package/dist/{chunk-STD62GEA.cjs.map → chunk-7U2DNPMZ.cjs.map} +1 -1
- package/dist/{chunk-YNHSM2S4.js → chunk-A634VUNB.js} +4 -4
- package/dist/{chunk-YNHSM2S4.js.map → chunk-A634VUNB.js.map} +1 -1
- package/dist/{chunk-LTPOEQRE.cjs → chunk-CJWZYK5K.cjs} +5 -5
- package/dist/{chunk-LTPOEQRE.cjs.map → chunk-CJWZYK5K.cjs.map} +1 -1
- package/dist/{chunk-V77P7GFU.cjs → chunk-CPJ2B3QQ.cjs} +4 -4
- package/dist/{chunk-V77P7GFU.cjs.map → chunk-CPJ2B3QQ.cjs.map} +1 -1
- package/dist/{chunk-HGUZGMIM.cjs → chunk-CRUCMRFC.cjs} +74 -74
- package/dist/{chunk-HGUZGMIM.cjs.map → chunk-CRUCMRFC.cjs.map} +1 -1
- package/dist/{chunk-MC2L4GKD.js → chunk-DF2GSH4D.js} +4 -4
- package/dist/{chunk-MC2L4GKD.js.map → chunk-DF2GSH4D.js.map} +1 -1
- package/dist/{chunk-R6GVUF3K.js → chunk-DNGA25ZA.js} +4 -4
- package/dist/{chunk-R6GVUF3K.js.map → chunk-DNGA25ZA.js.map} +1 -1
- package/dist/{chunk-THNTNAYI.js → chunk-DV25UPJ7.js} +3 -3
- package/dist/{chunk-THNTNAYI.js.map → chunk-DV25UPJ7.js.map} +1 -1
- package/dist/{chunk-32ZIHUXE.cjs → chunk-EGSSLWNZ.cjs} +3 -3
- package/dist/{chunk-32ZIHUXE.cjs.map → chunk-EGSSLWNZ.cjs.map} +1 -1
- package/dist/{chunk-UNXZLEKB.js → chunk-EJSVRT3G.js} +7 -7
- package/dist/{chunk-UNXZLEKB.js.map → chunk-EJSVRT3G.js.map} +1 -1
- package/dist/{chunk-3DZBJQJV.cjs → chunk-EVYUYVH2.cjs} +6 -6
- package/dist/{chunk-3DZBJQJV.cjs.map → chunk-EVYUYVH2.cjs.map} +1 -1
- package/dist/{chunk-CG5STA76.cjs → chunk-F72ZD5Q2.cjs} +3 -3
- package/dist/{chunk-CG5STA76.cjs.map → chunk-F72ZD5Q2.cjs.map} +1 -1
- package/dist/{chunk-ESJQ6KBW.js → chunk-G3MZ5S2Q.js} +4 -4
- package/dist/{chunk-ESJQ6KBW.js.map → chunk-G3MZ5S2Q.js.map} +1 -1
- package/dist/{chunk-EJB72OPN.js → chunk-H72SWOUS.js} +3 -3
- package/dist/{chunk-EJB72OPN.js.map → chunk-H72SWOUS.js.map} +1 -1
- package/dist/{chunk-SHV6WDCE.cjs → chunk-HT62K3UO.cjs} +4 -4
- package/dist/{chunk-SHV6WDCE.cjs.map → chunk-HT62K3UO.cjs.map} +1 -1
- package/dist/{chunk-OQUSFZDX.js → chunk-JKJI5SRF.js} +3 -3
- package/dist/{chunk-OQUSFZDX.js.map → chunk-JKJI5SRF.js.map} +1 -1
- package/dist/{chunk-XI376C3E.js → chunk-JS7KJRKG.js} +3 -3
- package/dist/{chunk-XI376C3E.js.map → chunk-JS7KJRKG.js.map} +1 -1
- package/dist/{chunk-C44V5BNE.js → chunk-KKBYWVEL.js} +7 -7
- package/dist/{chunk-C44V5BNE.js.map → chunk-KKBYWVEL.js.map} +1 -1
- package/dist/{chunk-O5CAJE65.js → chunk-LU23I2HS.js} +3 -3
- package/dist/{chunk-O5CAJE65.js.map → chunk-LU23I2HS.js.map} +1 -1
- package/dist/{chunk-X3RDL5PB.cjs → chunk-LXB756TN.cjs} +4 -4
- package/dist/{chunk-X3RDL5PB.cjs.map → chunk-LXB756TN.cjs.map} +1 -1
- package/dist/{chunk-FJNW6UJY.cjs → chunk-NML42O7Q.cjs} +3 -3
- package/dist/{chunk-FJNW6UJY.cjs.map → chunk-NML42O7Q.cjs.map} +1 -1
- package/dist/{chunk-KH4AMUXL.js → chunk-OGADWN5L.js} +3 -3
- package/dist/{chunk-KH4AMUXL.js.map → chunk-OGADWN5L.js.map} +1 -1
- package/dist/{chunk-XPHWUZ5H.cjs → chunk-OQCUIN6Z.cjs} +5 -5
- package/dist/{chunk-XPHWUZ5H.cjs.map → chunk-OQCUIN6Z.cjs.map} +1 -1
- package/dist/{chunk-G2MFXYTF.js → chunk-OZRGYS3J.js} +4 -4
- package/dist/{chunk-G2MFXYTF.js.map → chunk-OZRGYS3J.js.map} +1 -1
- package/dist/{chunk-2BR3NO6Z.js → chunk-OZSAQJO4.js} +4 -4
- package/dist/{chunk-2BR3NO6Z.js.map → chunk-OZSAQJO4.js.map} +1 -1
- package/dist/chunk-R3HZBTE3.cjs +18 -0
- package/dist/{chunk-MZRFMRQT.cjs.map → chunk-R3HZBTE3.cjs.map} +1 -1
- package/dist/{chunk-GMZ2XFQQ.js → chunk-S3YRRD54.js} +3 -3
- package/dist/{chunk-GMZ2XFQQ.js.map → chunk-S3YRRD54.js.map} +1 -1
- package/dist/{chunk-ADH5KQZW.cjs → chunk-SN7X7C7H.cjs} +3 -3
- package/dist/{chunk-ADH5KQZW.cjs.map → chunk-SN7X7C7H.cjs.map} +1 -1
- package/dist/{chunk-LY676TYN.cjs → chunk-SQAVWMGV.cjs} +56 -56
- package/dist/{chunk-LY676TYN.cjs.map → chunk-SQAVWMGV.cjs.map} +1 -1
- package/dist/chunk-T3JW5BYG.cjs +18 -0
- package/dist/{chunk-PPDVVPTQ.cjs.map → chunk-T3JW5BYG.cjs.map} +1 -1
- package/dist/{chunk-GNGIOV2R.js → chunk-TY76UEFK.js} +4 -4
- package/dist/{chunk-GNGIOV2R.js.map → chunk-TY76UEFK.js.map} +1 -1
- package/dist/{chunk-2GQDSJKM.js → chunk-UXIMEFEF.js} +8 -8
- package/dist/{chunk-2GQDSJKM.js.map → chunk-UXIMEFEF.js.map} +1 -1
- package/dist/{chunk-ROV3FG3J.js → chunk-W43S7COD.js} +3 -3
- package/dist/{chunk-ROV3FG3J.js.map → chunk-W43S7COD.js.map} +1 -1
- package/dist/{chunk-GU7ZW4HF.cjs → chunk-W5PKYJX5.cjs} +4 -4
- package/dist/{chunk-GU7ZW4HF.cjs.map → chunk-W5PKYJX5.cjs.map} +1 -1
- package/dist/{chunk-BAF32NYR.cjs → chunk-WY626DNG.cjs} +7 -7
- package/dist/{chunk-BAF32NYR.cjs.map → chunk-WY626DNG.cjs.map} +1 -1
- package/dist/{chunk-PU3JXCPL.cjs → chunk-XDFH6ONO.cjs} +12 -12
- package/dist/{chunk-PU3JXCPL.cjs.map → chunk-XDFH6ONO.cjs.map} +1 -1
- package/dist/{chunk-RIKKSHBV.js → chunk-XGUN44A4.js} +6 -6
- package/dist/{chunk-RIKKSHBV.js.map → chunk-XGUN44A4.js.map} +1 -1
- package/dist/{chunk-NIJBQG6G.js → chunk-Z6CAKLA5.js} +3 -3
- package/dist/{chunk-NIJBQG6G.js.map → chunk-Z6CAKLA5.js.map} +1 -1
- package/dist/{chunk-RDNINZPW.cjs → chunk-ZXXXLYZY.cjs} +3 -3
- package/dist/{chunk-RDNINZPW.cjs.map → chunk-ZXXXLYZY.cjs.map} +1 -1
- package/dist/collaboration/index.cjs +9 -9
- package/dist/collaboration/index.js +1 -1
- package/dist/connect/docx.cjs +24 -24
- package/dist/connect/docx.js +20 -20
- package/dist/connect/index.cjs +1016 -1016
- package/dist/connect/index.js +47 -47
- package/dist/connect/viewer.cjs +69 -69
- package/dist/connect/viewer.js +21 -21
- package/dist/docx/index.cjs +51 -51
- package/dist/docx/index.js +4 -4
- package/dist/facts/index.cjs +58 -58
- package/dist/facts/index.js +6 -6
- package/dist/files/index.cjs +237 -237
- package/dist/files/index.js +5 -5
- package/dist/index.cjs +1672 -1672
- package/dist/index.js +26 -26
- package/dist/settings/index.cjs +157 -157
- package/dist/settings/index.js +4 -4
- package/dist/shell/index.cjs +71 -71
- package/dist/shell/index.js +5 -5
- package/dist/site/index.cjs +21 -21
- package/dist/site/index.js +1 -1
- package/dist/studio/index.cjs +10 -10
- package/dist/studio/index.js +9 -9
- package/dist/workflow-canvas/index.cjs +66 -66
- package/dist/workflow-canvas/index.js +16 -16
- package/node_modules/@arbidocs/coedit/package.json +1 -1
- package/package.json +5 -5
- package/dist/ConnectedStreamedWordArtifact-7LZ7JGQO.js.map +0 -1
- package/dist/ConnectedStreamedWordArtifact-DZMB2MWZ.cjs.map +0 -1
- package/dist/chunk-MZRFMRQT.cjs +0 -18
- package/dist/chunk-PPDVVPTQ.cjs +0 -18
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
4
|
var chunkRFIBUWLF_cjs = require('./chunk-RFIBUWLF.cjs');
|
|
5
|
-
var
|
|
6
|
-
var chunkBAF32NYR_cjs = require('./chunk-BAF32NYR.cjs');
|
|
5
|
+
var chunkWY626DNG_cjs = require('./chunk-WY626DNG.cjs');
|
|
7
6
|
var chunkQHWDV2VB_cjs = require('./chunk-QHWDV2VB.cjs');
|
|
8
|
-
var chunk76L6LOP3_cjs = require('./chunk-76L6LOP3.cjs');
|
|
9
7
|
var chunkSIB6C7P7_cjs = require('./chunk-SIB6C7P7.cjs');
|
|
10
8
|
var chunkAHDJXIUB_cjs = require('./chunk-AHDJXIUB.cjs');
|
|
11
9
|
var chunkNIS5TLOM_cjs = require('./chunk-NIS5TLOM.cjs');
|
|
12
|
-
var chunkCQ2YSHIF_cjs = require('./chunk-CQ2YSHIF.cjs');
|
|
13
|
-
var chunkLKK52DEY_cjs = require('./chunk-LKK52DEY.cjs');
|
|
14
10
|
var chunkMEMWZ72Y_cjs = require('./chunk-MEMWZ72Y.cjs');
|
|
11
|
+
var chunkLKK52DEY_cjs = require('./chunk-LKK52DEY.cjs');
|
|
12
|
+
var chunk4RMI6D64_cjs = require('./chunk-4RMI6D64.cjs');
|
|
13
|
+
var chunk76L6LOP3_cjs = require('./chunk-76L6LOP3.cjs');
|
|
14
|
+
var chunkCQ2YSHIF_cjs = require('./chunk-CQ2YSHIF.cjs');
|
|
15
15
|
var chunkAHYSHKPL_cjs = require('./chunk-AHYSHKPL.cjs');
|
|
16
16
|
var chunkULWRNGGE_cjs = require('./chunk-ULWRNGGE.cjs');
|
|
17
17
|
var chunkMHVNT4J3_cjs = require('./chunk-MHVNT4J3.cjs');
|
|
@@ -210,7 +210,7 @@ function toStepField(f) {
|
|
|
210
210
|
}
|
|
211
211
|
var compact = (o) => Object.fromEntries(Object.entries(o).filter(([, v]) => v !== void 0 && v !== ""));
|
|
212
212
|
function placeholders(workflow) {
|
|
213
|
-
return Object.fromEntries(
|
|
213
|
+
return Object.fromEntries(chunk4RMI6D64_cjs.runFields(workflow).map((f) => [f.name, `{{${f.name}}}`]));
|
|
214
214
|
}
|
|
215
215
|
function agentStep(workflow, step, options) {
|
|
216
216
|
const target = step.workflow ? options.resolveWorkflow?.(step.workflow) : void 0;
|
|
@@ -219,11 +219,11 @@ function agentStep(workflow, step, options) {
|
|
|
219
219
|
([, v]) => v !== void 0 && v !== null && v !== ""
|
|
220
220
|
);
|
|
221
221
|
const inputs = { ...placeholders(workflow), ...Object.fromEntries(given) };
|
|
222
|
-
return { skill: null, inputs: null, prompt:
|
|
222
|
+
return { skill: null, inputs: null, prompt: chunk4RMI6D64_cjs.composeStepPrompt(workflow, step, inputs, options) };
|
|
223
223
|
}
|
|
224
224
|
function toPlanSteps(workflow, options = {}) {
|
|
225
225
|
const layout = workflow.run.kind === "steps" ? workflow.run.layout : void 0;
|
|
226
|
-
return
|
|
226
|
+
return chunk4RMI6D64_cjs.workflowSteps(workflow).map((step) => {
|
|
227
227
|
const ui = compact({
|
|
228
228
|
description: step.description,
|
|
229
229
|
icon: step.icon,
|
|
@@ -250,8 +250,8 @@ function toPlanSteps(workflow, options = {}) {
|
|
|
250
250
|
ui,
|
|
251
251
|
// An unfinished signal (still being typed) is not saved: the server would refuse it.
|
|
252
252
|
...step.signals?.some((s) => !isIncompleteSignal(s)) ? { signals: step.signals.filter((s) => !isIncompleteSignal(s)).map(toPlanSignal) } : {},
|
|
253
|
-
...step.assignee &&
|
|
254
|
-
...step.remindAfterHours &&
|
|
253
|
+
...step.assignee && chunk4RMI6D64_cjs.canAssign(step) ? { assignee: toPlanAssignee(step.assignee) } : {},
|
|
254
|
+
...step.remindAfterHours && chunk4RMI6D64_cjs.canAssign(step) ? { remind_after_hours: step.remindAfterHours } : {},
|
|
255
255
|
// A review's fields are what approving it is checked against (the server's `fields`).
|
|
256
256
|
...step.kind === "review" && step.fields?.length ? { fields: step.fields.map(toStepField) } : {},
|
|
257
257
|
...step.kind === "action" ? { action: toPlanAction(step.action) } : {},
|
|
@@ -396,7 +396,7 @@ function workflowFromSkillMarkdown(id, text2) {
|
|
|
396
396
|
var errorMessage = (e) => e instanceof Error ? e.message : typeof e === "string" ? e : "Something went wrong.";
|
|
397
397
|
function firstOpen(steps, states) {
|
|
398
398
|
const open = steps.find((s) => !["done", "skipped"].includes(states[s.id]?.status ?? "pending"));
|
|
399
|
-
return open?.id ?? (steps.length &&
|
|
399
|
+
return open?.id ?? (steps.length && chunk4RMI6D64_cjs.isRunFinished(steps, states) ? null : steps[0]?.id ?? null);
|
|
400
400
|
}
|
|
401
401
|
function useWorkflowView(options) {
|
|
402
402
|
const { steps, states, inputs, setInput, loaded = true } = options;
|
|
@@ -436,11 +436,11 @@ function useWorkflowView(options) {
|
|
|
436
436
|
}),
|
|
437
437
|
[]
|
|
438
438
|
);
|
|
439
|
-
const action = busy ? "wait" :
|
|
439
|
+
const action = busy ? "wait" : chunk4RMI6D64_cjs.nextAction(steps, states, current, actionOptions(options));
|
|
440
440
|
const next = react.useCallback(async () => {
|
|
441
441
|
const { steps: s, states: st, inputs: values } = optionsRef.current;
|
|
442
442
|
const at = s.find((x) => x.id === current);
|
|
443
|
-
const act2 =
|
|
443
|
+
const act2 = chunk4RMI6D64_cjs.nextAction(s, st, current, actionOptions(optionsRef.current));
|
|
444
444
|
if (!at || act2 === "wait" || busy) return;
|
|
445
445
|
setActionError(null);
|
|
446
446
|
if (act2 === "finish") return setCurrent(null);
|
|
@@ -451,7 +451,7 @@ function useWorkflowView(options) {
|
|
|
451
451
|
await (act2 === "start" ? optionsRef.current.start?.() : optionsRef.current.retry?.(at.id));
|
|
452
452
|
return;
|
|
453
453
|
}
|
|
454
|
-
if (Object.keys(
|
|
454
|
+
if (Object.keys(chunk4RMI6D64_cjs.validateStep(at, values)).length > 0) {
|
|
455
455
|
setShowErrors(true);
|
|
456
456
|
return;
|
|
457
457
|
}
|
|
@@ -552,10 +552,10 @@ function useWorkflowView(options) {
|
|
|
552
552
|
inputs,
|
|
553
553
|
setInput,
|
|
554
554
|
stateOf: (id) => states[id],
|
|
555
|
-
phaseOf: (id) =>
|
|
556
|
-
failedUpstreamOf: (id) =>
|
|
555
|
+
phaseOf: (id) => chunk4RMI6D64_cjs.stepPhase(steps, states, id),
|
|
556
|
+
failedUpstreamOf: (id) => chunk4RMI6D64_cjs.failedUpstream(steps, states, id),
|
|
557
557
|
isLocked,
|
|
558
|
-
errors: showErrors && step && !isLocked(step.id) ?
|
|
558
|
+
errors: showErrors && step && !isLocked(step.id) ? chunk4RMI6D64_cjs.validateStep(step, inputs) : {},
|
|
559
559
|
busy,
|
|
560
560
|
actionError,
|
|
561
561
|
isRunning: Object.values(states).some((s) => s.status === "running"),
|
|
@@ -573,11 +573,11 @@ function useWorkflowView(options) {
|
|
|
573
573
|
nameOf: options.nameOf,
|
|
574
574
|
assigneeOf: (id) => {
|
|
575
575
|
const s = steps.find((x) => x.id === id);
|
|
576
|
-
if (!s || !
|
|
577
|
-
return
|
|
576
|
+
if (!s || !chunk4RMI6D64_cjs.canAssign(s)) return void 0;
|
|
577
|
+
return chunk4RMI6D64_cjs.assigneeName(s.assignee, {
|
|
578
578
|
nameOf: options.nameOf,
|
|
579
579
|
inputs,
|
|
580
|
-
fields:
|
|
580
|
+
fields: chunk4RMI6D64_cjs.runFieldsOf(steps),
|
|
581
581
|
announcedTo: states[id]?.announcedTo
|
|
582
582
|
});
|
|
583
583
|
},
|
|
@@ -711,7 +711,7 @@ function StepBarFrame({
|
|
|
711
711
|
}) {
|
|
712
712
|
const l = { ...DEFAULT_STEP_BAR_LABELS, ...labels };
|
|
713
713
|
const box = react.useRef(null);
|
|
714
|
-
const { width } =
|
|
714
|
+
const { width } = chunk4RMI6D64_cjs.useElementSize(box);
|
|
715
715
|
const narrow = width > 0 && width < NARROW_PX;
|
|
716
716
|
const [start, setStart] = react.useState(null);
|
|
717
717
|
react.useEffect(() => setStart(null), [current]);
|
|
@@ -778,7 +778,7 @@ function StepBarFrame({
|
|
|
778
778
|
phase === "blocked" && "opacity-60"
|
|
779
779
|
),
|
|
780
780
|
"aria-hidden": true,
|
|
781
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
781
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(chunk4RMI6D64_cjs.StepBadgeMark, { phase, icon: icon?.(s) })
|
|
782
782
|
}
|
|
783
783
|
),
|
|
784
784
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "min-w-0 flex-1 truncate", title: s.title, children: s.title }),
|
|
@@ -886,7 +886,7 @@ function StepBarFrame({
|
|
|
886
886
|
};
|
|
887
887
|
const running = win.runningHidden;
|
|
888
888
|
const outOfViewChip = (s, kind) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
889
|
-
|
|
889
|
+
chunk4RMI6D64_cjs.StepChip,
|
|
890
890
|
{
|
|
891
891
|
kind: kindOf(s),
|
|
892
892
|
phase: kind === "working" ? "running" : "failed",
|
|
@@ -1059,7 +1059,7 @@ var DEFAULT_WORKFLOW_STEP_PARTS_LABELS = {
|
|
|
1059
1059
|
someone: "someone"
|
|
1060
1060
|
};
|
|
1061
1061
|
var docName = (ref, nameOfDoc) => {
|
|
1062
|
-
const { id, version } =
|
|
1062
|
+
const { id, version } = chunk4RMI6D64_cjs.splitDocRef(ref);
|
|
1063
1063
|
const name = nameOfDoc?.(id) ?? id;
|
|
1064
1064
|
return version ? `${name} \xB7 v${version}` : name;
|
|
1065
1065
|
};
|
|
@@ -1141,7 +1141,7 @@ function SendBackControl({
|
|
|
1141
1141
|
const states = Object.fromEntries(
|
|
1142
1142
|
run.steps.map((s) => [s.id, run.stateOf(s.id) ?? { status: "pending" }])
|
|
1143
1143
|
);
|
|
1144
|
-
const targets =
|
|
1144
|
+
const targets = chunk4RMI6D64_cjs.sendBackTargets(run.steps, states, step.id);
|
|
1145
1145
|
const [open, setOpen] = react.useState(false);
|
|
1146
1146
|
const [to, setTo] = react.useState(targets[0]?.id ?? "");
|
|
1147
1147
|
const [note, setNote] = react.useState("");
|
|
@@ -1231,7 +1231,7 @@ function ApprovalEvidence({
|
|
|
1231
1231
|
/* @__PURE__ */ jsxRuntime.jsxs("p", { className: "flex flex-wrap items-center gap-1.5 text-sm font-medium", children: [
|
|
1232
1232
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ShieldCheck, { className: "size-4 text-primary" }),
|
|
1233
1233
|
approver ? l.approvedBy.replace("{name}", approver) : null,
|
|
1234
|
-
state.at && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs font-normal text-muted-foreground", children: l.approvedAt.replace("{date}",
|
|
1234
|
+
state.at && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs font-normal text-muted-foreground", children: l.approvedAt.replace("{date}", chunk4RMI6D64_cjs.formatDate(state.at)) })
|
|
1235
1235
|
] }),
|
|
1236
1236
|
evidence.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1.5", children: [
|
|
1237
1237
|
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs font-semibold uppercase tracking-wide text-muted-foreground", children: l.approvedWhat }),
|
|
@@ -1264,7 +1264,7 @@ function ApprovalEvidence({
|
|
|
1264
1264
|
] }),
|
|
1265
1265
|
(step.fields ?? []).length > 0 && /* @__PURE__ */ jsxRuntime.jsx("dl", { className: "grid grid-cols-[auto_1fr] gap-x-3 gap-y-0.5 text-xs", children: (step.fields ?? []).map((f) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "contents", children: [
|
|
1266
1266
|
/* @__PURE__ */ jsxRuntime.jsx("dt", { className: "text-muted-foreground", children: f.label }),
|
|
1267
|
-
/* @__PURE__ */ jsxRuntime.jsx("dd", { "data-testid": `${testId}-evidence-field-${f.name}`, children:
|
|
1267
|
+
/* @__PURE__ */ jsxRuntime.jsx("dd", { "data-testid": `${testId}-evidence-field-${f.name}`, children: chunk4RMI6D64_cjs.shownValue(run.inputs[f.name], f, run.nameOf) })
|
|
1268
1268
|
] }, f.name)) })
|
|
1269
1269
|
] });
|
|
1270
1270
|
}
|
|
@@ -1360,7 +1360,7 @@ function ActionStepBody({
|
|
|
1360
1360
|
waiting?.expires_at && phase === "waiting" && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "flex items-center gap-1.5 text-xs text-muted-foreground", children: [
|
|
1361
1361
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Clock, { className: "size-3.5" }),
|
|
1362
1362
|
" ",
|
|
1363
|
-
l.expires.replace("{date}",
|
|
1363
|
+
l.expires.replace("{date}", chunk4RMI6D64_cjs.formatDate(waiting.expires_at))
|
|
1364
1364
|
] }),
|
|
1365
1365
|
phase === "waiting" && mine && !declining && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap gap-2", children: [
|
|
1366
1366
|
actions?.sign && state && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -1518,7 +1518,7 @@ function WorkflowStepBar({
|
|
|
1518
1518
|
const name = `${title} (${l.phases[phase]})`;
|
|
1519
1519
|
if (s.id === DONE)
|
|
1520
1520
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1521
|
-
|
|
1521
|
+
chunk4RMI6D64_cjs.StepChip,
|
|
1522
1522
|
{
|
|
1523
1523
|
inert: true,
|
|
1524
1524
|
kind: "start",
|
|
@@ -1532,17 +1532,17 @@ function WorkflowStepBar({
|
|
|
1532
1532
|
"data-testid": tid("step-done")
|
|
1533
1533
|
}
|
|
1534
1534
|
);
|
|
1535
|
-
const kind =
|
|
1536
|
-
const KindIcon =
|
|
1535
|
+
const kind = chunk4RMI6D64_cjs.stepKindOf(s);
|
|
1536
|
+
const KindIcon = chunk4RMI6D64_cjs.STEP_KIND_ICONS[kind];
|
|
1537
1537
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1538
|
-
|
|
1538
|
+
chunk4RMI6D64_cjs.StepChip,
|
|
1539
1539
|
{
|
|
1540
1540
|
kind,
|
|
1541
1541
|
phase,
|
|
1542
1542
|
icon: icon(s.icon) ?? /* @__PURE__ */ jsxRuntime.jsx(KindIcon, {}),
|
|
1543
1543
|
label: s.title,
|
|
1544
1544
|
current: isCurrent,
|
|
1545
|
-
heading:
|
|
1545
|
+
heading: chunk4RMI6D64_cjs.DEFAULT_STEP_KIND_LABELS[kind],
|
|
1546
1546
|
labelClassName: isCurrent ? STEP_LABEL_CURRENT : ui.cn(STEP_LABEL, STEP_LABEL_MAX),
|
|
1547
1547
|
labelTestId: tid(`step-${s.id}-label`),
|
|
1548
1548
|
onClick: () => run.goTo(s.id),
|
|
@@ -1575,7 +1575,7 @@ function WorkflowStepBar({
|
|
|
1575
1575
|
isSelectable: (id) => id !== DONE,
|
|
1576
1576
|
renderStep: (s) => pill(s),
|
|
1577
1577
|
icon: (s) => s.id === DONE ? doneIcon : icon(s.icon),
|
|
1578
|
-
kindOf: (s) => s.id === DONE ? "start" :
|
|
1578
|
+
kindOf: (s) => s.id === DONE ? "start" : chunk4RMI6D64_cjs.stepKindOf(s),
|
|
1579
1579
|
disabled: run.busy,
|
|
1580
1580
|
labels,
|
|
1581
1581
|
tid,
|
|
@@ -1658,7 +1658,7 @@ function WorkflowRunner({
|
|
|
1658
1658
|
const { steps, step, isComplete, action } = run;
|
|
1659
1659
|
const completion = workflow.run.kind === "steps" ? workflow.run.completion : void 0;
|
|
1660
1660
|
const tid = (suffix) => `${testIdPrefix}-${suffix}`;
|
|
1661
|
-
const levels =
|
|
1661
|
+
const levels = chunk4RMI6D64_cjs.stepLevels(steps);
|
|
1662
1662
|
const icon = (key) => key && renderIcon ? renderIcon(key) : void 0;
|
|
1663
1663
|
const added = step?.kind === "upload" ? (files ?? []).filter((f) => f.addedFor === step.id) : [];
|
|
1664
1664
|
const unread = added.filter((f) => f.status === "processing").length;
|
|
@@ -1666,7 +1666,7 @@ function WorkflowRunner({
|
|
|
1666
1666
|
const sending = added.filter((f) => f.status === "uploading").length;
|
|
1667
1667
|
const unsent = added.filter((f) => f.status === "upload-failed").length;
|
|
1668
1668
|
const uploadHold = step?.kind === "upload" && (sending > 0 || uploading || unsent > 0);
|
|
1669
|
-
const docsWait = !!step &&
|
|
1669
|
+
const docsWait = !!step && chunk4RMI6D64_cjs.waitingDocuments(run.stateOf(step.id)).length > 0;
|
|
1670
1670
|
const nextLabel = sending ? sending === 1 ? l.uploadingFile : l.uploadingFiles.replace("{count}", String(sending)) : uploadHold && uploading ? l.uploadingAny : uploadHold ? unsent === 1 ? l.uploadFailed : l.uploadsFailed.replace("{count}", String(unsent)) : reading ? l.readingFiles.replace("{current}", String(Math.min(added.length - unread + 1, added.length))).replace("{count}", String(added.length)) : action === "start" ? l.start : action === "retry" ? l.retry : action === "finish" ? l.finish : action === "complete" && step?.kind === "review" ? l.approve : action === "complete" && step?.kind === "action" ? l.markSent : action === "wait" && (run.isRunning || run.busy || docsWait) ? l.working : (step && !run.isLocked(step.id) ? step.nextLabel : void 0) ?? l.next;
|
|
1671
1671
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: ui.cn(compact2 ? "space-y-3" : "space-y-6", className), "data-testid": testIdPrefix, children: [
|
|
1672
1672
|
!hideStepBar && /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1698,13 +1698,13 @@ function WorkflowRunner({
|
|
|
1698
1698
|
/* @__PURE__ */ jsxRuntime.jsx(StepNotices, { run, step, l, tid }),
|
|
1699
1699
|
run.phaseOf(step.id) === "blocked" ? /* @__PURE__ */ jsxRuntime.jsx(ui.Card, { className: ui.cn(box, "p-6"), "data-testid": tid(step.id), children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground", "data-testid": tid(`${step.id}-blocked`), children: l.blocked.replace(
|
|
1700
1700
|
"{steps}",
|
|
1701
|
-
|
|
1701
|
+
chunk4RMI6D64_cjs.stepDependencies(steps, step.id).map((d) => steps.find((s) => s.id === d)?.title ?? d).join(", ")
|
|
1702
1702
|
) }) }) : step.kind === "form" ? /* @__PURE__ */ jsxRuntime.jsxs(ui.Card, { className: ui.cn(box, "space-y-4"), "data-testid": tid(step.id), children: [
|
|
1703
1703
|
/* @__PURE__ */ jsxRuntime.jsx(StepHeading, { step, icon: icon(step.icon), testId: tid(`${step.id}-title`) }),
|
|
1704
1704
|
/* @__PURE__ */ jsxRuntime.jsx(SentBackNote, { state: run.stateOf(step.id), l: pl, testId: tid(step.id) }),
|
|
1705
1705
|
/* @__PURE__ */ jsxRuntime.jsx(AssigneeLine, { run, stepId: step.id, l: pl, testId: tid(step.id) }),
|
|
1706
1706
|
/* @__PURE__ */ jsxRuntime.jsx("fieldset", { disabled: run.isLocked(step.id), className: "contents", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1707
|
-
|
|
1707
|
+
chunkWY626DNG_cjs.SchemaForm,
|
|
1708
1708
|
{
|
|
1709
1709
|
fields: step.inputs,
|
|
1710
1710
|
values: run.inputs,
|
|
@@ -1754,11 +1754,11 @@ function WorkflowRunner({
|
|
|
1754
1754
|
] }) : step.kind === "review" ? /* @__PURE__ */ jsxRuntime.jsxs(ui.Card, { className: ui.cn(box, "space-y-4"), "data-testid": tid(step.id), children: [
|
|
1755
1755
|
/* @__PURE__ */ jsxRuntime.jsx(StepHeading, { step, icon: icon(step.icon) }),
|
|
1756
1756
|
/* @__PURE__ */ jsxRuntime.jsx(SentBackNote, { state: run.stateOf(step.id), l: pl, testId: tid(step.id) }),
|
|
1757
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "whitespace-pre-line text-sm text-muted-foreground", children:
|
|
1757
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "whitespace-pre-line text-sm text-muted-foreground", children: chunk4RMI6D64_cjs.reviewInstructions(step, run.inputs) }),
|
|
1758
1758
|
/* @__PURE__ */ jsxRuntime.jsx(AssigneeLine, { run, stepId: step.id, l: pl, testId: tid(step.id) }),
|
|
1759
1759
|
!(run.phaseOf(step.id) === "done" && run.stateOf(step.id)?.by) && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm", "data-testid": tid(`${step.id}-status`), children: run.phaseOf(step.id) === "done" ? l.approved : run.phaseOf(step.id) === "skipped" ? l.skipped : l.awaitingReview }),
|
|
1760
1760
|
(step.fields ?? []).length > 0 && run.phaseOf(step.id) === "ready" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1761
|
-
|
|
1761
|
+
chunkWY626DNG_cjs.SchemaForm,
|
|
1762
1762
|
{
|
|
1763
1763
|
fields: step.fields ?? [],
|
|
1764
1764
|
values: run.inputs,
|
|
@@ -2021,8 +2021,8 @@ function AgentStepBody({
|
|
|
2021
2021
|
}) {
|
|
2022
2022
|
const state = run.stateOf(step.id);
|
|
2023
2023
|
const phase = run.phaseOf(step.id);
|
|
2024
|
-
const pending =
|
|
2025
|
-
const pendingNames = pending.flatMap((ref) => nameOfDoc?.(
|
|
2024
|
+
const pending = chunk4RMI6D64_cjs.waitingDocuments(state);
|
|
2025
|
+
const pendingNames = pending.flatMap((ref) => nameOfDoc?.(chunk4RMI6D64_cjs.splitDocRef(ref).id) ?? []);
|
|
2026
2026
|
const header = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start justify-between gap-3", children: [
|
|
2027
2027
|
/* @__PURE__ */ jsxRuntime.jsx(StepHeading, { step, icon }),
|
|
2028
2028
|
phase === "failed" && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex shrink-0 items-center gap-2", children: run.retry && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -2107,7 +2107,7 @@ function StepNotices({
|
|
|
2107
2107
|
l,
|
|
2108
2108
|
tid
|
|
2109
2109
|
}) {
|
|
2110
|
-
const notStarted = !
|
|
2110
|
+
const notStarted = !chunk4RMI6D64_cjs.isPersonStep(step) && run.needsStart && run.phaseOf(step.id) === "ready";
|
|
2111
2111
|
const failed = run.failedUpstreamOf(step.id);
|
|
2112
2112
|
if (!notStarted && failed.length === 0) return null;
|
|
2113
2113
|
const why = (error) => error ? `: ${error}` : "";
|
|
@@ -2656,7 +2656,7 @@ var asForm = (step) => ({
|
|
|
2656
2656
|
id: step.id,
|
|
2657
2657
|
title: step.title,
|
|
2658
2658
|
description: "",
|
|
2659
|
-
inputs:
|
|
2659
|
+
inputs: chunk4RMI6D64_cjs.stepFields(step),
|
|
2660
2660
|
run: { kind: "operation" },
|
|
2661
2661
|
landing: "chat"
|
|
2662
2662
|
});
|
|
@@ -2675,13 +2675,13 @@ function WorkflowStepAction({
|
|
|
2675
2675
|
onOpenDraft,
|
|
2676
2676
|
onOpenReview
|
|
2677
2677
|
}) {
|
|
2678
|
-
const fields =
|
|
2678
|
+
const fields = chunk4RMI6D64_cjs.stepFields(step);
|
|
2679
2679
|
const [values, setValues] = react.useState(
|
|
2680
2680
|
() => fields.length ? { ...chunk76L6LOP3_cjs.defaultInputs(asForm(step)), ...inputs } : {}
|
|
2681
2681
|
);
|
|
2682
2682
|
const [open, setOpen] = react.useState(null);
|
|
2683
2683
|
const [note, setNote] = react.useState("");
|
|
2684
|
-
const targets =
|
|
2684
|
+
const targets = chunk4RMI6D64_cjs.sendBackTargets(steps, states, step.id);
|
|
2685
2685
|
const [to, setTo] = react.useState(targets[0]?.id ?? "");
|
|
2686
2686
|
const [busy, setBusy] = react.useState(false);
|
|
2687
2687
|
const [error, setError] = react.useState(null);
|
|
@@ -2853,7 +2853,7 @@ function WorkflowStepAction({
|
|
|
2853
2853
|
const errors = chunk76L6LOP3_cjs.validateInputs(asForm(step), values);
|
|
2854
2854
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2 p-1", "data-testid": tid, children: [
|
|
2855
2855
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2856
|
-
|
|
2856
|
+
chunkWY626DNG_cjs.SchemaForm,
|
|
2857
2857
|
{
|
|
2858
2858
|
fields,
|
|
2859
2859
|
values,
|
|
@@ -5132,7 +5132,7 @@ function TaskStartDialog({
|
|
|
5132
5132
|
setSourceOpen(false);
|
|
5133
5133
|
}, [open]);
|
|
5134
5134
|
const textareaRef = react.useRef(null);
|
|
5135
|
-
const mention =
|
|
5135
|
+
const mention = chunk4RMI6D64_cjs.useMentionAutocomplete({
|
|
5136
5136
|
value: prompt,
|
|
5137
5137
|
onValueChange: setPrompt,
|
|
5138
5138
|
candidates: people,
|
|
@@ -6086,12 +6086,12 @@ function taskActivityHeadline(e, labels = DEFAULT_TASK_ACTIVITY_LABELS, agentNam
|
|
|
6086
6086
|
case "step_skipped":
|
|
6087
6087
|
return "Step skipped";
|
|
6088
6088
|
case "step_waiting": {
|
|
6089
|
-
const documents =
|
|
6090
|
-
return documents ?
|
|
6089
|
+
const documents = chunk4RMI6D64_cjs.eventWaitingDocuments(detail);
|
|
6090
|
+
return documents ? chunk4RMI6D64_cjs.waitingForDocumentsText(documents.length) : "Waiting on people";
|
|
6091
6091
|
}
|
|
6092
6092
|
case "step_progress": {
|
|
6093
|
-
const documents =
|
|
6094
|
-
return documents ?
|
|
6093
|
+
const documents = chunk4RMI6D64_cjs.eventWaitingDocuments(detail);
|
|
6094
|
+
return documents ? chunk4RMI6D64_cjs.waitingForDocumentsText(documents.length) : detail.signed ? "Signed" : "Step moved on";
|
|
6095
6095
|
}
|
|
6096
6096
|
case "step_sent_back":
|
|
6097
6097
|
return "Sent the work back";
|
|
@@ -6255,7 +6255,7 @@ function TaskFlow({
|
|
|
6255
6255
|
},
|
|
6256
6256
|
children: /* @__PURE__ */ jsxRuntime.jsx("ol", { className: "flex w-max min-w-full items-center gap-1 py-0.5", children: items.map((item, i) => {
|
|
6257
6257
|
const chip = (props) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
6258
|
-
|
|
6258
|
+
chunk4RMI6D64_cjs.StepChip,
|
|
6259
6259
|
{
|
|
6260
6260
|
kind: "adhoc",
|
|
6261
6261
|
phase: "ready",
|
|
@@ -6309,7 +6309,7 @@ function ThreadActivity({ item, children }) {
|
|
|
6309
6309
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex w-full max-w-xl items-center gap-2", children: [
|
|
6310
6310
|
/* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": true, className: "wf-link", "data-done": done || void 0 }),
|
|
6311
6311
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6312
|
-
|
|
6312
|
+
chunk4RMI6D64_cjs.StepChip,
|
|
6313
6313
|
{
|
|
6314
6314
|
inert: true,
|
|
6315
6315
|
kind,
|
|
@@ -6328,7 +6328,7 @@ function ThreadActivity({ item, children }) {
|
|
|
6328
6328
|
}
|
|
6329
6329
|
),
|
|
6330
6330
|
document && /* @__PURE__ */ jsxRuntime.jsx(
|
|
6331
|
-
|
|
6331
|
+
chunk4RMI6D64_cjs.StepDocumentButton,
|
|
6332
6332
|
{
|
|
6333
6333
|
kind,
|
|
6334
6334
|
name: document.name,
|
|
@@ -6395,7 +6395,7 @@ function ThreadLauncher({
|
|
|
6395
6395
|
const [shared, setShared] = react.useState(false);
|
|
6396
6396
|
const [started, setStarted] = react.useState(null);
|
|
6397
6397
|
const textareaRef = react.useRef(null);
|
|
6398
|
-
const mention =
|
|
6398
|
+
const mention = chunk4RMI6D64_cjs.useMentionAutocomplete({
|
|
6399
6399
|
value: prompt,
|
|
6400
6400
|
onValueChange: setPrompt,
|
|
6401
6401
|
candidates: people,
|
|
@@ -6592,10 +6592,10 @@ function WorkflowRunStatus({
|
|
|
6592
6592
|
testId = "workflow-run-status"
|
|
6593
6593
|
}) {
|
|
6594
6594
|
const l = { ...DEFAULT_WORKFLOW_RUN_STATUS_LABELS, ...labels };
|
|
6595
|
-
const ordered =
|
|
6596
|
-
const phaseOf = (id) => isLoading ? "blocked" :
|
|
6597
|
-
const finished = !isLoading &&
|
|
6598
|
-
const atId = finished || isLoading ? void 0 : activeStepId(
|
|
6595
|
+
const ordered = chunk4RMI6D64_cjs.stepLevels(steps).flat();
|
|
6596
|
+
const phaseOf = (id) => isLoading ? "blocked" : chunk4RMI6D64_cjs.stepPhase(steps, states, id);
|
|
6597
|
+
const finished = !isLoading && chunk4RMI6D64_cjs.isRunFinished(steps, states);
|
|
6598
|
+
const atId = finished || isLoading ? void 0 : activeStepId(chunk4RMI6D64_cjs.stepLevels(steps), phaseOf);
|
|
6599
6599
|
const at = ordered.find((s) => s.id === atId);
|
|
6600
6600
|
const phase = at ? phaseOf(at.id) : "done";
|
|
6601
6601
|
const assignee = at && ["ready", "waiting"].includes(phase) ? assigneeOf?.(at) : void 0;
|
|
@@ -6627,7 +6627,7 @@ function WorkflowRunStatus({
|
|
|
6627
6627
|
"span",
|
|
6628
6628
|
{
|
|
6629
6629
|
className: ui.cn(
|
|
6630
|
-
`wf-kind-${
|
|
6630
|
+
`wf-kind-${chunk4RMI6D64_cjs.stepKindOf(s)}`,
|
|
6631
6631
|
"h-1.5 w-3 shrink-0 rounded-full",
|
|
6632
6632
|
SEGMENT[phaseOf(s.id)],
|
|
6633
6633
|
s.id === atId && "w-5"
|
|
@@ -6673,7 +6673,7 @@ function groupThreadActivity(steps, items) {
|
|
|
6673
6673
|
continue;
|
|
6674
6674
|
}
|
|
6675
6675
|
if (current === void 0) out.before.push(item);
|
|
6676
|
-
else if (
|
|
6676
|
+
else if (chunk4RMI6D64_cjs.isRunFinished(steps, states)) out.after.push(item);
|
|
6677
6677
|
else {
|
|
6678
6678
|
const status = states[current]?.status;
|
|
6679
6679
|
const at = status === "done" || status === "skipped" ? steps.find((s) => !["done", "skipped"].includes(states[s.id]?.status ?? ""))?.id ?? current : current;
|
|
@@ -6696,9 +6696,9 @@ var DEFAULT_WORKFLOW_THREAD_STRIP_LABELS = {
|
|
|
6696
6696
|
after: "After",
|
|
6697
6697
|
beforeSteps: "Before the first step",
|
|
6698
6698
|
afterSteps: "After the last step",
|
|
6699
|
-
kinds:
|
|
6700
|
-
documents:
|
|
6701
|
-
record:
|
|
6699
|
+
kinds: chunk4RMI6D64_cjs.DEFAULT_STEP_KIND_LABELS,
|
|
6700
|
+
documents: chunk4RMI6D64_cjs.DEFAULT_STEP_DOCUMENT_LABELS,
|
|
6701
|
+
record: chunk4RMI6D64_cjs.DEFAULT_STEP_RECORD_LABELS
|
|
6702
6702
|
};
|
|
6703
6703
|
function WorkflowThreadStartedBy({
|
|
6704
6704
|
origin,
|
|
@@ -6829,7 +6829,7 @@ function EntriesChip({
|
|
|
6829
6829
|
const latest = items.at(-1);
|
|
6830
6830
|
return /* @__PURE__ */ jsxRuntime.jsxs(ui.Popover, { children: [
|
|
6831
6831
|
/* @__PURE__ */ jsxRuntime.jsx(ui.PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
6832
|
-
|
|
6832
|
+
chunk4RMI6D64_cjs.StepChip,
|
|
6833
6833
|
{
|
|
6834
6834
|
kind,
|
|
6835
6835
|
phase: "ready",
|
|
@@ -6874,17 +6874,17 @@ function WorkflowThreadStrip({
|
|
|
6874
6874
|
const link = /* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": true, className: "wf-link wf-kind-start max-w-6", "data-done": true });
|
|
6875
6875
|
const [selected, setSelected] = react.useState(null);
|
|
6876
6876
|
const [open, setOpen] = react.useState(null);
|
|
6877
|
-
const phaseOf = (id) =>
|
|
6877
|
+
const phaseOf = (id) => chunk4RMI6D64_cjs.stepPhase(steps, states, id);
|
|
6878
6878
|
const iconOf = (step) => step.icon && renderIcon ? renderIcon(step.icon) : void 0;
|
|
6879
6879
|
const glyphOf = (step) => {
|
|
6880
|
-
const KindIcon =
|
|
6880
|
+
const KindIcon = chunk4RMI6D64_cjs.STEP_KIND_ICONS[chunk4RMI6D64_cjs.stepKindOf(step)];
|
|
6881
6881
|
return iconOf(step) ?? /* @__PURE__ */ jsxRuntime.jsx(KindIcon, {});
|
|
6882
6882
|
};
|
|
6883
6883
|
const waitingOf = (id) => {
|
|
6884
6884
|
const step = steps.find((s) => s.id === id);
|
|
6885
6885
|
const phase = phaseOf(id);
|
|
6886
|
-
const documents =
|
|
6887
|
-
if (documents.length) return
|
|
6886
|
+
const documents = chunk4RMI6D64_cjs.waitingDocuments(states[id]);
|
|
6887
|
+
if (documents.length) return chunk4RMI6D64_cjs.waitingForDocumentsText(documents.length);
|
|
6888
6888
|
const name = step && (phase === "ready" || phase === "waiting") ? assigneeOf?.(step) : void 0;
|
|
6889
6889
|
return name ? l.waitingFor.replace("{name}", name) : void 0;
|
|
6890
6890
|
};
|
|
@@ -6894,8 +6894,8 @@ function WorkflowThreadStrip({
|
|
|
6894
6894
|
const assignee = phase === "ready" || phase === "waiting" ? assigneeOf?.(step) : void 0;
|
|
6895
6895
|
const waiting = waitingOf(step.id);
|
|
6896
6896
|
const sentBack = states[step.id]?.sentBack;
|
|
6897
|
-
const kind =
|
|
6898
|
-
const documents =
|
|
6897
|
+
const kind = chunk4RMI6D64_cjs.stepKindOf(step);
|
|
6898
|
+
const documents = chunk4RMI6D64_cjs.stepDocuments(steps, states, step.id);
|
|
6899
6899
|
const latestDoc = onOpenDocument ? documents.at(-1) : void 0;
|
|
6900
6900
|
const finished = ["done", "skipped", "failed"].includes(phase);
|
|
6901
6901
|
const chip = /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -6908,7 +6908,7 @@ function WorkflowThreadStrip({
|
|
|
6908
6908
|
},
|
|
6909
6909
|
children: [
|
|
6910
6910
|
/* @__PURE__ */ jsxRuntime.jsx(ui.PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
6911
|
-
|
|
6911
|
+
chunk4RMI6D64_cjs.StepChip,
|
|
6912
6912
|
{
|
|
6913
6913
|
kind,
|
|
6914
6914
|
phase,
|
|
@@ -6957,7 +6957,7 @@ function WorkflowThreadStrip({
|
|
|
6957
6957
|
),
|
|
6958
6958
|
sentBack && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "px-1 text-xs text-amber-700 dark:text-amber-300", children: l.sentBack }),
|
|
6959
6959
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6960
|
-
|
|
6960
|
+
chunk4RMI6D64_cjs.StepDocumentCards,
|
|
6961
6961
|
{
|
|
6962
6962
|
refs: documents,
|
|
6963
6963
|
heading: step.kind === "review" ? phase === "done" ? l.documents.approved : l.documents.toApprove : l.documents.produced,
|
|
@@ -6968,7 +6968,7 @@ function WorkflowThreadStrip({
|
|
|
6968
6968
|
}
|
|
6969
6969
|
),
|
|
6970
6970
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6971
|
-
|
|
6971
|
+
chunk4RMI6D64_cjs.StepRecord,
|
|
6972
6972
|
{
|
|
6973
6973
|
step,
|
|
6974
6974
|
state: states[step.id],
|
|
@@ -7000,10 +7000,10 @@ function WorkflowThreadStrip({
|
|
|
7000
7000
|
return latestDoc ? /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "flex min-w-0 items-center", children: [
|
|
7001
7001
|
chip,
|
|
7002
7002
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7003
|
-
|
|
7003
|
+
chunk4RMI6D64_cjs.StepDocumentButton,
|
|
7004
7004
|
{
|
|
7005
7005
|
kind,
|
|
7006
|
-
name: nameOfDoc?.(
|
|
7006
|
+
name: nameOfDoc?.(chunk4RMI6D64_cjs.splitDocRef(latestDoc).id) ?? latestDoc,
|
|
7007
7007
|
onOpen: () => onOpenDocument?.(latestDoc),
|
|
7008
7008
|
testId: `workflow-thread-step-${step.id}-open-document`
|
|
7009
7009
|
}
|
|
@@ -7042,17 +7042,17 @@ function WorkflowThreadStrip({
|
|
|
7042
7042
|
] }),
|
|
7043
7043
|
strays.map((s) => /* @__PURE__ */ jsxRuntime.jsx(SignalPill, { signal: s, l }, `${s.step}-${s.signal}`))
|
|
7044
7044
|
] }) : null;
|
|
7045
|
-
const at = steps.find((s) => s.id === (selected ?? activeStepId(
|
|
7046
|
-
const headingPx = (step) => `${l.kinds[
|
|
7045
|
+
const at = steps.find((s) => s.id === (selected ?? activeStepId(chunk4RMI6D64_cjs.stepLevels(steps), phaseOf)));
|
|
7046
|
+
const headingPx = (step) => `${l.kinds[chunk4RMI6D64_cjs.stepKindOf(step)]} \xB7 ${waitingOf(step.id) ?? ""}`.length * 5.6 - step.title.length * 6.5;
|
|
7047
7047
|
const reserve = {
|
|
7048
|
-
always: (at ? Math.max(0, headingPx(at)) : 0) + steps.filter((s) => grouped.byStep[s.id]?.length).length * BEADS_PX + (onOpenDocument ? steps.filter((s) =>
|
|
7048
|
+
always: (at ? Math.max(0, headingPx(at)) : 0) + steps.filter((s) => grouped.byStep[s.id]?.length).length * BEADS_PX + (onOpenDocument ? steps.filter((s) => chunk4RMI6D64_cjs.stepDocuments(steps, states, s.id).length).length * DOC_BUTTON_PX : 0),
|
|
7049
7049
|
leading: leading ? 150 : 0,
|
|
7050
7050
|
trailing: trailing ? 120 : 0
|
|
7051
7051
|
};
|
|
7052
7052
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: ui.cn("min-w-0 flex-1", className), "data-testid": "workflow-thread-strip", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
7053
7053
|
StepBarFrame,
|
|
7054
7054
|
{
|
|
7055
|
-
levels:
|
|
7055
|
+
levels: chunk4RMI6D64_cjs.stepLevels(steps),
|
|
7056
7056
|
phaseOf,
|
|
7057
7057
|
current: selected,
|
|
7058
7058
|
onSelect: (id) => {
|
|
@@ -7065,7 +7065,7 @@ function WorkflowThreadStrip({
|
|
|
7065
7065
|
trailing,
|
|
7066
7066
|
reservePx: reserve,
|
|
7067
7067
|
icon: glyphOf,
|
|
7068
|
-
kindOf:
|
|
7068
|
+
kindOf: chunk4RMI6D64_cjs.stepKindOf,
|
|
7069
7069
|
labels: { waitingFor: l.waitingFor, ...barLabels },
|
|
7070
7070
|
tid: (suffix) => `workflow-thread-${suffix}`
|
|
7071
7071
|
}
|
|
@@ -7141,11 +7141,11 @@ function compactThreadActivity(events, stepTitleOf) {
|
|
|
7141
7141
|
const count = Math.max(1, entry.recipients.length);
|
|
7142
7142
|
entry.label = `Notified ${count} ${count === 1 ? "user" : "users"}`;
|
|
7143
7143
|
} else if (STEP_LABELS[event.kind]) {
|
|
7144
|
-
const documents =
|
|
7144
|
+
const documents = chunk4RMI6D64_cjs.eventWaitingDocuments(event.detail);
|
|
7145
7145
|
const title = typeof event.detail?.step === "string" ? stepTitleOf?.(event.detail.step) : void 0;
|
|
7146
7146
|
result.push({
|
|
7147
7147
|
event,
|
|
7148
|
-
label: documents ?
|
|
7148
|
+
label: documents ? chunk4RMI6D64_cjs.waitingForDocumentsText(documents.length) : title && STEP_VERBS[event.kind] ? `${title} ${STEP_VERBS[event.kind]}` : STEP_LABELS[event.kind],
|
|
7149
7149
|
recipients: []
|
|
7150
7150
|
});
|
|
7151
7151
|
} else if (["artifact_created", "artifact_edited", "document_added", "document_removed"].includes(
|
|
@@ -7235,7 +7235,7 @@ function TaskRunsDialog({
|
|
|
7235
7235
|
"rounded-full px-2 py-0.5 text-xs font-medium capitalize",
|
|
7236
7236
|
STATUS_STYLE[data.status] ?? "text-muted-foreground"
|
|
7237
7237
|
),
|
|
7238
|
-
children:
|
|
7238
|
+
children: chunkWY626DNG_cjs.workflowRunStatusLabel(data.status)
|
|
7239
7239
|
}
|
|
7240
7240
|
)
|
|
7241
7241
|
},
|
|
@@ -7689,7 +7689,7 @@ function WorkflowComposer({
|
|
|
7689
7689
|
}
|
|
7690
7690
|
),
|
|
7691
7691
|
!noFiles && workflow && fields.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
7692
|
-
|
|
7692
|
+
chunkWY626DNG_cjs.SchemaForm,
|
|
7693
7693
|
{
|
|
7694
7694
|
fields,
|
|
7695
7695
|
values: values.inputs,
|
|
@@ -8322,7 +8322,7 @@ function WorkTaskComposer({
|
|
|
8322
8322
|
)
|
|
8323
8323
|
] }),
|
|
8324
8324
|
workflow && fields.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
8325
|
-
|
|
8325
|
+
chunkWY626DNG_cjs.SchemaForm,
|
|
8326
8326
|
{
|
|
8327
8327
|
fields,
|
|
8328
8328
|
values: values.inputs,
|
|
@@ -10711,5 +10711,5 @@ exports.workflowTaskFields = workflowTaskFields;
|
|
|
10711
10711
|
exports.workflowToComposerValues = workflowToComposerValues;
|
|
10712
10712
|
exports.workflowToSkillMarkdown = workflowToSkillMarkdown;
|
|
10713
10713
|
exports.workflowWhen = workflowWhen;
|
|
10714
|
-
//# sourceMappingURL=chunk-
|
|
10715
|
-
//# sourceMappingURL=chunk-
|
|
10714
|
+
//# sourceMappingURL=chunk-52GITM4V.cjs.map
|
|
10715
|
+
//# sourceMappingURL=chunk-52GITM4V.cjs.map
|