@arbidocs/blocks 0.4.73 → 0.4.75

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 (104) hide show
  1. package/README.md +2 -1
  2. package/dist/agents/index.cjs +255 -254
  3. package/dist/agents/index.js +5 -4
  4. package/dist/agents/workflows/WorkflowRunner.d.ts +20 -4
  5. package/dist/agents/workflows/WorkflowStepBar.d.ts +23 -0
  6. package/dist/agents/workflows/run.d.ts +1 -0
  7. package/dist/agents/workflows/types.d.ts +2 -0
  8. package/dist/chat/index.cjs +124 -124
  9. package/dist/chat/index.js +3 -3
  10. package/dist/{chunk-3SFFTSOI.cjs → chunk-7CVF3DK2.cjs} +5 -5
  11. package/dist/{chunk-3SFFTSOI.cjs.map → chunk-7CVF3DK2.cjs.map} +1 -1
  12. package/dist/{chunk-V3L5DONY.cjs → chunk-B4SRYJLM.cjs} +31 -2
  13. package/dist/chunk-B4SRYJLM.cjs.map +1 -0
  14. package/dist/{chunk-IUR565UW.cjs → chunk-F4LUD3YC.cjs} +49 -48
  15. package/dist/chunk-F4LUD3YC.cjs.map +1 -0
  16. package/dist/{chunk-WOYUXVVQ.cjs → chunk-HITAN7JF.cjs} +4 -4
  17. package/dist/{chunk-WOYUXVVQ.cjs.map → chunk-HITAN7JF.cjs.map} +1 -1
  18. package/dist/{chunk-3VQYJBOI.js → chunk-HOXKR26S.js} +31 -4
  19. package/dist/chunk-HOXKR26S.js.map +1 -0
  20. package/dist/{chunk-KJ3QEKOJ.cjs → chunk-IPGKTUF7.cjs} +7 -33
  21. package/dist/chunk-IPGKTUF7.cjs.map +1 -0
  22. package/dist/{chunk-IA7RTPT3.cjs → chunk-IXALYQT7.cjs} +2 -200
  23. package/dist/chunk-IXALYQT7.cjs.map +1 -0
  24. package/dist/{chunk-QDNXEB3T.js → chunk-LT2UORRG.js} +7 -6
  25. package/dist/chunk-LT2UORRG.js.map +1 -0
  26. package/dist/{chunk-ORA2XE7U.js → chunk-MK6NJQGF.js} +3 -3
  27. package/dist/{chunk-ORA2XE7U.js.map → chunk-MK6NJQGF.js.map} +1 -1
  28. package/dist/chunk-NUNKSZKU.js +203 -0
  29. package/dist/chunk-NUNKSZKU.js.map +1 -0
  30. package/dist/{chunk-6OL5S7MJ.cjs → chunk-NYBIKDWI.cjs} +5 -2
  31. package/dist/chunk-NYBIKDWI.cjs.map +1 -0
  32. package/dist/{chunk-GTNUQBXI.cjs → chunk-P2RBE3FD.cjs} +254 -102
  33. package/dist/chunk-P2RBE3FD.cjs.map +1 -0
  34. package/dist/{chunk-D46ZAPEE.js → chunk-R3PDNQYT.js} +5 -2
  35. package/dist/chunk-R3PDNQYT.js.map +1 -0
  36. package/dist/{chunk-G5DP27DU.js → chunk-UIWLDSTF.js} +3 -29
  37. package/dist/chunk-UIWLDSTF.js.map +1 -0
  38. package/dist/chunk-V4ISCZJ7.cjs +207 -0
  39. package/dist/chunk-V4ISCZJ7.cjs.map +1 -0
  40. package/dist/{chunk-VRPRAU3J.js → chunk-WJEKRSPH.js} +3 -3
  41. package/dist/{chunk-VRPRAU3J.js.map → chunk-WJEKRSPH.js.map} +1 -1
  42. package/dist/{chunk-2P3T23C7.js → chunk-YWYVIQ7T.js} +256 -104
  43. package/dist/chunk-YWYVIQ7T.js.map +1 -0
  44. package/dist/{chunk-BUHKUKKB.js → chunk-ZPLG7QYF.js} +4 -199
  45. package/dist/chunk-ZPLG7QYF.js.map +1 -0
  46. package/dist/connect/index.cjs +96 -37
  47. package/dist/connect/index.cjs.map +1 -1
  48. package/dist/connect/index.js +81 -22
  49. package/dist/connect/index.js.map +1 -1
  50. package/dist/connection/ConnectedWorkflowRunner.d.ts +5 -1
  51. package/dist/connection/useWorkflowThread.d.ts +4 -0
  52. package/dist/databases/DatabaseColumnDialog.d.ts +43 -0
  53. package/dist/databases/DatabaseList.d.ts +28 -0
  54. package/dist/databases/DatabaseTable.d.ts +38 -0
  55. package/dist/databases/DatabaseToolbar.d.ts +38 -0
  56. package/dist/databases/NewDatabaseDialog.d.ts +25 -0
  57. package/dist/databases/SelectCellEditor.d.ts +6 -0
  58. package/dist/databases/SelectChip.d.ts +4 -0
  59. package/dist/databases/column-types.d.ts +58 -0
  60. package/dist/databases/databaseColumns.d.ts +28 -0
  61. package/dist/databases/index.cjs +1081 -0
  62. package/dist/databases/index.cjs.map +1 -0
  63. package/dist/databases/index.d.ts +13 -0
  64. package/dist/databases/index.js +1055 -0
  65. package/dist/databases/index.js.map +1 -0
  66. package/dist/facts/index.cjs +7 -6
  67. package/dist/facts/index.cjs.map +1 -1
  68. package/dist/facts/index.js +3 -2
  69. package/dist/facts/index.js.map +1 -1
  70. package/dist/files/index.cjs +14 -13
  71. package/dist/files/index.cjs.map +1 -1
  72. package/dist/files/index.js +4 -2
  73. package/dist/files/index.js.map +1 -1
  74. package/dist/index.cjs +632 -631
  75. package/dist/index.cjs.map +1 -1
  76. package/dist/index.js +12 -11
  77. package/dist/index.js.map +1 -1
  78. package/dist/settings/index.cjs +1 -1
  79. package/dist/settings/index.js +1 -1
  80. package/dist/shell/ActionCluster.d.ts +3 -1
  81. package/dist/shell/index.cjs +45 -45
  82. package/dist/shell/index.js +1 -1
  83. package/dist/studio/index.cjs +4 -4
  84. package/dist/studio/index.js +3 -3
  85. package/dist/workflow-canvas/StepInspector.d.ts +11 -0
  86. package/dist/workflow-canvas/WorkflowCanvas.d.ts +6 -2
  87. package/dist/workflow-canvas/index.cjs +202 -91
  88. package/dist/workflow-canvas/index.cjs.map +1 -1
  89. package/dist/workflow-canvas/index.js +170 -59
  90. package/dist/workflow-canvas/index.js.map +1 -1
  91. package/dist/workflow-canvas/viewport.d.ts +47 -0
  92. package/package.json +9 -4
  93. package/dist/chunk-2P3T23C7.js.map +0 -1
  94. package/dist/chunk-3VQYJBOI.js.map +0 -1
  95. package/dist/chunk-6OL5S7MJ.cjs.map +0 -1
  96. package/dist/chunk-BUHKUKKB.js.map +0 -1
  97. package/dist/chunk-D46ZAPEE.js.map +0 -1
  98. package/dist/chunk-G5DP27DU.js.map +0 -1
  99. package/dist/chunk-GTNUQBXI.cjs.map +0 -1
  100. package/dist/chunk-IA7RTPT3.cjs.map +0 -1
  101. package/dist/chunk-IUR565UW.cjs.map +0 -1
  102. package/dist/chunk-KJ3QEKOJ.cjs.map +0 -1
  103. package/dist/chunk-QDNXEB3T.js.map +0 -1
  104. package/dist/chunk-V3L5DONY.cjs.map +0 -1
@@ -2,6 +2,7 @@
2
2
  'use strict';
3
3
 
4
4
  var chunk7UTB4PHM_cjs = require('./chunk-7UTB4PHM.cjs');
5
+ var chunkPPCATBOY_cjs = require('./chunk-PPCATBOY.cjs');
5
6
  var react = require('react');
6
7
 
7
8
  function useMentionAutocomplete({
@@ -72,7 +73,35 @@ function useMentionAutocomplete({
72
73
  textareaProps: { onSelect: readCaret }
73
74
  };
74
75
  }
76
+ function useElementSize(ref) {
77
+ const [size, setSize] = react.useState({ width: 0, height: 0 });
78
+ react.useLayoutEffect(() => {
79
+ const el = ref.current;
80
+ if (!el) return;
81
+ const measure = () => {
82
+ const rect = el.getBoundingClientRect();
83
+ setSize(
84
+ (prev) => prev.width === rect.width && prev.height === rect.height ? prev : { width: rect.width, height: rect.height }
85
+ );
86
+ };
87
+ measure();
88
+ window.addEventListener("resize", measure);
89
+ const stopObserving = chunkPPCATBOY_cjs.observeResize(el, measure);
90
+ return () => {
91
+ window.removeEventListener("resize", measure);
92
+ stopObserving();
93
+ };
94
+ }, [ref]);
95
+ return size;
96
+ }
97
+ function rootFontSizePx() {
98
+ if (typeof document === "undefined") return 16;
99
+ const size = parseFloat(getComputedStyle(document.documentElement).fontSize);
100
+ return Number.isFinite(size) && size > 0 ? size : 16;
101
+ }
75
102
 
103
+ exports.rootFontSizePx = rootFontSizePx;
104
+ exports.useElementSize = useElementSize;
76
105
  exports.useMentionAutocomplete = useMentionAutocomplete;
77
- //# sourceMappingURL=chunk-V3L5DONY.cjs.map
78
- //# sourceMappingURL=chunk-V3L5DONY.cjs.map
106
+ //# sourceMappingURL=chunk-B4SRYJLM.cjs.map
107
+ //# sourceMappingURL=chunk-B4SRYJLM.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/chat/useMentionAutocomplete.ts","../src/lib/useElementSize.ts"],"names":["useState","useEffect","useMemo","findMentionQuery","filterMentionCandidates","useCallback","insertMention","useListKeyNav","useLayoutEffect","observeResize"],"mappings":"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","file":"chunk-B4SRYJLM.cjs","sourcesContent":["import {\n useCallback,\n useEffect,\n useMemo,\n useState,\n type RefObject,\n type SyntheticEvent,\n} from 'react'\nimport { useListKeyNav, type UseListKeyNav } from '../lib/useListKeyNav'\nimport {\n filterMentionCandidates,\n findMentionQuery,\n insertMention,\n type MentionCandidate,\n} from './mentions'\n\nexport interface UseMentionAutocompleteOptions {\n /** The draft. */\n value: string\n /** Writes the draft (the same setter the composer uses). */\n onValueChange: (next: string) => void\n /** Who can be mentioned: workspace members and the assistant. */\n candidates: ReadonlyArray<MentionCandidate>\n /** The composer textarea; read for the caret and refocused after a pick. */\n textareaRef: RefObject<HTMLTextAreaElement | null>\n}\n\nexport interface UseMentionAutocomplete {\n isOpen: boolean\n /** Filtered candidates for the `@query` at the caret. */\n items: MentionCandidate[]\n /** Keyboard navigation; call `nav.handleKeyDown` first in the textarea's `onKeyDown`. */\n nav: UseListKeyNav\n /** Insert a candidate in place of the `@query`. */\n pick: (candidate: MentionCandidate) => void\n /** Wrap the composer's `onValueChange` with this so the caret is tracked as the user types. */\n onValueChange: (next: string) => void\n /** Spread onto the textarea (via `textareaProps`): tracks caret moves (clicks, arrows). */\n textareaProps: { onSelect: (event: SyntheticEvent<HTMLTextAreaElement>) => void }\n}\n\n/**\n * Headless `@mention` autocomplete for a textarea: finds the `@query` at the caret, filters the\n * candidates, and on pick replaces the query with `@<label> `. Pair with {@link MentionMenu}.\n */\nexport function useMentionAutocomplete({\n value,\n onValueChange,\n candidates,\n textareaRef,\n}: UseMentionAutocompleteOptions): UseMentionAutocomplete {\n const [caret, setCaret] = useState<number | null>(null)\n // Escape dismisses the menu for the `@` it was opened at, until the user starts another one.\n const [dismissedAt, setDismissedAt] = useState<number | null>(null)\n\n // The draft can change from outside (cleared on send, restored on error): once the dismissed\n // `@` is gone, re-arm so the next `@` there opens the menu again.\n useEffect(() => {\n if (dismissedAt !== null && value[dismissedAt] !== '@') setDismissedAt(null)\n }, [value, dismissedAt])\n\n const match = useMemo(() => {\n if (caret === null) return null\n const query = findMentionQuery(value, Math.min(caret, value.length))\n // A completed recipient followed by a space is no longer an autocomplete query.\n return query && candidates.some((candidate) => query.query === `${candidate.label} `)\n ? null\n : query\n }, [value, caret, candidates])\n const items = useMemo(\n () => (match ? filterMentionCandidates(candidates, match.query) : []),\n [match, candidates]\n )\n const isOpen = !!match && items.length > 0 && dismissedAt !== match.start\n\n const readCaret = useCallback(() => {\n const ta = textareaRef.current\n setCaret(ta ? ta.selectionStart : null)\n }, [textareaRef])\n\n const pick = useCallback(\n (candidate: MentionCandidate) => {\n if (!match || caret === null) return\n const next = insertMention(value, match.start, Math.min(caret, value.length), candidate.label)\n onValueChange(next.text)\n setCaret(next.caret)\n // The inserted `@<label> ` is complete: keep the menu shut for this `@`.\n setDismissedAt(match.start)\n requestAnimationFrame(() => {\n const ta = textareaRef.current\n if (!ta) return\n ta.focus()\n ta.setSelectionRange(next.caret, next.caret)\n })\n },\n [match, caret, value, onValueChange, textareaRef]\n )\n\n const nav = useListKeyNav({\n open: isOpen,\n items,\n onPick: pick,\n onDismiss: () => setDismissedAt(match?.start ?? null),\n resetKey: match?.query,\n })\n\n const handleValueChange = useCallback(\n (next: string) => {\n onValueChange(next)\n const ta = textareaRef.current\n setCaret(ta ? ta.selectionStart : next.length)\n // Deleting text (or the `@` itself) re-arms the menu: the user is editing that mention.\n if (dismissedAt !== null && (next.length < value.length || next[dismissedAt] !== '@')) {\n setDismissedAt(null)\n }\n },\n [onValueChange, textareaRef, dismissedAt, value]\n )\n\n return {\n isOpen,\n items,\n nav,\n pick,\n onValueChange: handleValueChange,\n textareaProps: { onSelect: readCaret },\n }\n}\n","import { useLayoutEffect, useState, type RefObject } from 'react'\nimport { observeResize } from './observe-resize'\n\nexport interface ElementSize {\n width: number\n height: number\n}\n\n/**\n * The border-box size of an element, kept current with a ResizeObserver. It is measured before\n * the first paint (layout effect), so a layout that depends on it never flashes the wrong mode.\n * Window resize is listened to as well (a no-ResizeObserver engine, jsdom, still re-measures).\n */\nexport function useElementSize<T extends HTMLElement>(ref: RefObject<T | null>): ElementSize {\n const [size, setSize] = useState<ElementSize>({ width: 0, height: 0 })\n useLayoutEffect(() => {\n const el = ref.current\n if (!el) return\n const measure = () => {\n const rect = el.getBoundingClientRect()\n setSize((prev) =>\n prev.width === rect.width && prev.height === rect.height\n ? prev\n : { width: rect.width, height: rect.height }\n )\n }\n measure()\n window.addEventListener('resize', measure)\n const stopObserving = observeResize(el, measure)\n return () => {\n window.removeEventListener('resize', measure)\n stopObserving()\n }\n }, [ref])\n return size\n}\n\n/** The root font size in px (what `rem` means), 16 when it cannot be read. */\nexport function rootFontSizePx(): number {\n if (typeof document === 'undefined') return 16\n const size = parseFloat(getComputedStyle(document.documentElement).fontSize)\n return Number.isFinite(size) && size > 0 ? size : 16\n}\n"]}
@@ -3,16 +3,17 @@
3
3
 
4
4
  var chunkYJQVLVBJ_cjs = require('./chunk-YJQVLVBJ.cjs');
5
5
  var chunkZW6FPIFC_cjs = require('./chunk-ZW6FPIFC.cjs');
6
- var chunkGTNUQBXI_cjs = require('./chunk-GTNUQBXI.cjs');
6
+ var chunkP2RBE3FD_cjs = require('./chunk-P2RBE3FD.cjs');
7
7
  var chunk7RGLTF76_cjs = require('./chunk-7RGLTF76.cjs');
8
8
  var chunk3AFWGEDJ_cjs = require('./chunk-3AFWGEDJ.cjs');
9
9
  var chunkVFUWWH52_cjs = require('./chunk-VFUWWH52.cjs');
10
- var chunkIA7RTPT3_cjs = require('./chunk-IA7RTPT3.cjs');
10
+ var chunkV4ISCZJ7_cjs = require('./chunk-V4ISCZJ7.cjs');
11
11
  var chunk2EI7NCUA_cjs = require('./chunk-2EI7NCUA.cjs');
12
+ var chunkIXALYQT7_cjs = require('./chunk-IXALYQT7.cjs');
12
13
  var chunkZ5VUZ6YD_cjs = require('./chunk-Z5VUZ6YD.cjs');
13
14
  var chunk7D737FLE_cjs = require('./chunk-7D737FLE.cjs');
14
15
  var chunkOB5F4577_cjs = require('./chunk-OB5F4577.cjs');
15
- var chunkV3L5DONY_cjs = require('./chunk-V3L5DONY.cjs');
16
+ var chunkB4SRYJLM_cjs = require('./chunk-B4SRYJLM.cjs');
16
17
  var chunk7UTB4PHM_cjs = require('./chunk-7UTB4PHM.cjs');
17
18
  var chunkFX3K6LNZ_cjs = require('./chunk-FX3K6LNZ.cjs');
18
19
  var chunkC54XEN5T_cjs = require('./chunk-C54XEN5T.cjs');
@@ -144,7 +145,7 @@ function WorkflowConfigDialog({
144
145
  }) {
145
146
  const l = { ...DEFAULT_WORKFLOW_CONFIG_DIALOG_LABELS, ...labels };
146
147
  const initialKey = JSON.stringify(initialInputs ?? {});
147
- const seedKey = JSON.stringify({ ...chunkGTNUQBXI_cjs.defaultInputs(workflow), ...JSON.parse(initialKey) });
148
+ const seedKey = JSON.stringify({ ...chunkP2RBE3FD_cjs.defaultInputs(workflow), ...JSON.parse(initialKey) });
148
149
  const seed = react.useMemo(() => JSON.parse(seedKey), [seedKey]);
149
150
  const [inputs, setInputs] = useControllableState(inputsProp, seed, onInputsChange);
150
151
  const [agentId, setAgentId] = useControllableState(
@@ -156,7 +157,7 @@ function WorkflowConfigDialog({
156
157
  if (open && inputsProp === void 0) setInputs(seed);
157
158
  }, [open, seed]);
158
159
  const setField = (name, value) => setInputs({ ...inputs, [name]: value });
159
- const errors = chunkGTNUQBXI_cjs.validateInputs(workflow, inputs);
160
+ const errors = chunkP2RBE3FD_cjs.validateInputs(workflow, inputs);
160
161
  const valid = Object.keys(errors).length === 0;
161
162
  const visibleErrors = Object.fromEntries(
162
163
  Object.entries(errors).filter(([, e]) => e !== "required")
@@ -169,7 +170,7 @@ function WorkflowConfigDialog({
169
170
  const blockedByScope = matchedCount !== null && matchedCount === 0 && Boolean(workflow.requiresFiles);
170
171
  const showAgent = workflow.run.kind === "prompt" && workflow.options?.agent !== false && agents !== void 0 && agents.length > 0;
171
172
  const launch = (values) => {
172
- Promise.resolve(onLaunch(chunkGTNUQBXI_cjs.buildLaunch(workflow, values, agentId))).catch(() => {
173
+ Promise.resolve(onLaunch(chunkP2RBE3FD_cjs.buildLaunch(workflow, values, agentId))).catch(() => {
173
174
  });
174
175
  };
175
176
  const submit = () => {
@@ -247,7 +248,7 @@ function WorkflowConfigDialog({
247
248
  }
248
249
  ) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
249
250
  /* @__PURE__ */ jsxRuntime.jsx(
250
- chunkGTNUQBXI_cjs.SchemaForm,
251
+ chunkP2RBE3FD_cjs.SchemaForm,
251
252
  {
252
253
  fields,
253
254
  values: inputs,
@@ -325,7 +326,7 @@ function resolveScopeInputs(workflow, inputs, scopeSource) {
325
326
  for (const field of workflow.inputs) {
326
327
  if (field.type !== "scope") continue;
327
328
  const raw = inputs[field.name];
328
- const scope = chunkGTNUQBXI_cjs.isWorkflowScope(raw) ? raw : { folders: [], labels: [] };
329
+ const scope = chunkP2RBE3FD_cjs.isWorkflowScope(raw) ? raw : { folders: [], labels: [] };
329
330
  next[field.name] = { ...scope, documents: scopeSource.resolveDocuments(scope) };
330
331
  }
331
332
  return next;
@@ -367,9 +368,9 @@ function WorkflowLauncher({
367
368
  };
368
369
  const select = (workflow) => {
369
370
  if (workflow.run.kind === "operation" && workflow.inputs.length === 0) {
370
- const inputs = chunkGTNUQBXI_cjs.defaultInputs(workflow);
371
- if (Object.keys(chunkGTNUQBXI_cjs.validateInputs(workflow, inputs)).length === 0) {
372
- Promise.resolve(onLaunch(chunkGTNUQBXI_cjs.buildLaunch(workflow, inputs, void 0))).catch(() => {
371
+ const inputs = chunkP2RBE3FD_cjs.defaultInputs(workflow);
372
+ if (Object.keys(chunkP2RBE3FD_cjs.validateInputs(workflow, inputs)).length === 0) {
373
+ Promise.resolve(onLaunch(chunkP2RBE3FD_cjs.buildLaunch(workflow, inputs, void 0))).catch(() => {
373
374
  });
374
375
  return;
375
376
  }
@@ -519,7 +520,7 @@ function workflowToSkillMarkdown(workflow) {
519
520
  if (workflow.landing !== "chat") lines.push(`landing: ${workflow.landing}`);
520
521
  if (workflow.requiresFiles) lines.push("requires_files: true");
521
522
  if (workflow.inputs.length > 0) {
522
- lines.push(`inputs: ${JSON.stringify(workflow.inputs.map(chunkGTNUQBXI_cjs.fieldToFrontmatter))}`);
523
+ lines.push(`inputs: ${JSON.stringify(workflow.inputs.map(chunkP2RBE3FD_cjs.fieldToFrontmatter))}`);
523
524
  }
524
525
  lines.push("---", "", run.promptTemplate.trim(), "");
525
526
  return lines.join("\n");
@@ -541,11 +542,11 @@ function workflowFromSkillMarkdown(id, text) {
541
542
  } else if (value === "true" || value === "false") frontmatter[key] = value === "true";
542
543
  else frontmatter[key] = value;
543
544
  }
544
- return chunkGTNUQBXI_cjs.workflowFromFrontmatter(id, frontmatter, body);
545
+ return chunkP2RBE3FD_cjs.workflowFromFrontmatter(id, frontmatter, body);
545
546
  }
546
547
  function useWorkflowPreview(workflow, { answer = "{prompt}", delayMs = 400, resolveWorkflow, compose } = {}) {
547
- const steps = chunkGTNUQBXI_cjs.workflowSteps(workflow);
548
- const [inputs, setInputs] = react.useState(() => chunkGTNUQBXI_cjs.initialRunInputs(workflow));
548
+ const steps = chunkP2RBE3FD_cjs.workflowSteps(workflow);
549
+ const [inputs, setInputs] = react.useState(() => chunkP2RBE3FD_cjs.initialRunInputs(workflow));
549
550
  const [states, setStates] = react.useState({});
550
551
  const set = (id, state) => setStates((s) => ({ ...s, [id]: state }));
551
552
  const timers = react.useRef(/* @__PURE__ */ new Map());
@@ -566,10 +567,10 @@ function useWorkflowPreview(workflow, { answer = "{prompt}", delayMs = 400, reso
566
567
  }, []);
567
568
  react.useEffect(() => {
568
569
  if (Object.values(states).some((s) => s.status === "running")) return;
569
- const next = steps.find((s) => s.kind === "agent" && chunkGTNUQBXI_cjs.stepPhase(steps, states, s.id) === "ready");
570
+ const next = steps.find((s) => s.kind === "agent" && chunkP2RBE3FD_cjs.stepPhase(steps, states, s.id) === "ready");
570
571
  if (!next || next.kind !== "agent") return;
571
- const prompt = chunkGTNUQBXI_cjs.composeStepPrompt(workflow, next, inputs, { resolveWorkflow, compose });
572
- set(next.id, { status: "running" });
572
+ const prompt = chunkP2RBE3FD_cjs.composeStepPrompt(workflow, next, inputs, { resolveWorkflow, compose });
573
+ set(next.id, { status: "running", startedAt: (/* @__PURE__ */ new Date()).toISOString() });
573
574
  timers.current.set(
574
575
  next.id,
575
576
  setTimeout(() => {
@@ -578,7 +579,7 @@ function useWorkflowPreview(workflow, { answer = "{prompt}", delayMs = 400, reso
578
579
  }, delayMs)
579
580
  );
580
581
  }, [states, steps, workflow]);
581
- return chunkGTNUQBXI_cjs.useWorkflowView({
582
+ return chunkP2RBE3FD_cjs.useWorkflowView({
582
583
  steps,
583
584
  states,
584
585
  inputs,
@@ -3882,7 +3883,7 @@ function TaskTable(props) {
3882
3883
  testId: "task-list-empty"
3883
3884
  }
3884
3885
  ) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "min-h-0 flex-1", children: /* @__PURE__ */ jsxRuntime.jsx(
3885
- chunkIA7RTPT3_cjs.GridView,
3886
+ chunkIXALYQT7_cjs.GridView,
3886
3887
  {
3887
3888
  testId: "task-grid",
3888
3889
  gridId: props.gridId ?? "tasks-grid-v4",
@@ -3908,7 +3909,7 @@ function TaskTable(props) {
3908
3909
  }
3909
3910
  ) }),
3910
3911
  /* @__PURE__ */ jsxRuntime.jsx(
3911
- chunkIA7RTPT3_cjs.SelectionBar,
3912
+ chunkV4ISCZJ7_cjs.SelectionBar,
3912
3913
  {
3913
3914
  count: selectedTasks.length,
3914
3915
  onClear: clearSelection,
@@ -3916,7 +3917,7 @@ function TaskTable(props) {
3916
3917
  children: (isCompact) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
3917
3918
  props.selectionActions?.(selectedTasks, isCompact, clearSelection),
3918
3919
  props.onMarkDoneMany && /* @__PURE__ */ jsxRuntime.jsx(
3919
- chunkIA7RTPT3_cjs.SelectionBarAction,
3920
+ chunkV4ISCZJ7_cjs.SelectionBarAction,
3920
3921
  {
3921
3922
  icon: lucideReact.CheckCheck,
3922
3923
  label: l.markDoneMany,
@@ -3931,7 +3932,7 @@ function TaskTable(props) {
3931
3932
  }
3932
3933
  ),
3933
3934
  props.onDeleteMany && /* @__PURE__ */ jsxRuntime.jsx(
3934
- chunkIA7RTPT3_cjs.SelectionBarAction,
3935
+ chunkV4ISCZJ7_cjs.SelectionBarAction,
3935
3936
  {
3936
3937
  icon: lucideReact.Trash2,
3937
3938
  label: l.deleteMany,
@@ -4308,10 +4309,10 @@ function TaskInbox(p) {
4308
4309
  }),
4309
4310
  roots.filter((t) => !t.workflow_ext_id || !workflowIds.has(t.workflow_ext_id)).sort(order).map((t) => renderTask(t))
4310
4311
  ] }) }),
4311
- /* @__PURE__ */ jsxRuntime.jsx(chunkIA7RTPT3_cjs.SelectionBar, { count: selectedTasks.length, onClear: clearSelection, children: (isCompact) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
4312
+ /* @__PURE__ */ jsxRuntime.jsx(chunkV4ISCZJ7_cjs.SelectionBar, { count: selectedTasks.length, onClear: clearSelection, children: (isCompact) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
4312
4313
  p.selectionActions?.(selectedTasks, isCompact, clearSelection),
4313
4314
  p.onMarkDoneMany && /* @__PURE__ */ jsxRuntime.jsx(
4314
- chunkIA7RTPT3_cjs.SelectionBarAction,
4315
+ chunkV4ISCZJ7_cjs.SelectionBarAction,
4315
4316
  {
4316
4317
  icon: lucideReact.CheckCheck,
4317
4318
  label: l.markDoneMany,
@@ -4325,7 +4326,7 @@ function TaskInbox(p) {
4325
4326
  }
4326
4327
  ),
4327
4328
  p.onDeleteMany && /* @__PURE__ */ jsxRuntime.jsx(
4328
- chunkIA7RTPT3_cjs.SelectionBarAction,
4329
+ chunkV4ISCZJ7_cjs.SelectionBarAction,
4329
4330
  {
4330
4331
  icon: lucideReact.Trash2,
4331
4332
  label: l.deleteMany,
@@ -4583,7 +4584,7 @@ function ConversationListView(p) {
4583
4584
  }
4584
4585
  ),
4585
4586
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "min-h-0 flex-1", children: /* @__PURE__ */ jsxRuntime.jsx(
4586
- chunkIA7RTPT3_cjs.GridView,
4587
+ chunkIXALYQT7_cjs.GridView,
4587
4588
  {
4588
4589
  testId: "threads-grid",
4589
4590
  items: rows,
@@ -4613,7 +4614,7 @@ function ConversationListView(p) {
4613
4614
  }
4614
4615
  }
4615
4616
  ) }),
4616
- p.selectionActions && /* @__PURE__ */ jsxRuntime.jsx(chunkIA7RTPT3_cjs.SelectionBar, { count: selectedRows.length, onClear: () => setSelected(/* @__PURE__ */ new Set()), children: (compact) => p.selectionActions?.(selectedRows, compact, () => setSelected(/* @__PURE__ */ new Set())) })
4617
+ p.selectionActions && /* @__PURE__ */ jsxRuntime.jsx(chunkV4ISCZJ7_cjs.SelectionBar, { count: selectedRows.length, onClear: () => setSelected(/* @__PURE__ */ new Set()), children: (compact) => p.selectionActions?.(selectedRows, compact, () => setSelected(/* @__PURE__ */ new Set())) })
4617
4618
  ] });
4618
4619
  }
4619
4620
  var NO_PEOPLE = [];
@@ -4640,7 +4641,7 @@ function TaskStartDialog({
4640
4641
  setSourceOpen(false);
4641
4642
  }, [open]);
4642
4643
  const textareaRef = react.useRef(null);
4643
- const mention = chunkV3L5DONY_cjs.useMentionAutocomplete({
4644
+ const mention = chunkB4SRYJLM_cjs.useMentionAutocomplete({
4644
4645
  value: prompt,
4645
4646
  onValueChange: setPrompt,
4646
4647
  candidates: people,
@@ -4991,7 +4992,7 @@ function workflowTaskFields(workflow, inputs, name, context) {
4991
4992
  }
4992
4993
  const typed = name?.trim();
4993
4994
  if (workflow.options?.agent === false) {
4994
- const message = chunkGTNUQBXI_cjs.composeWorkflowPrompt(workflow, inputs, context);
4995
+ const message = chunkP2RBE3FD_cjs.composeWorkflowPrompt(workflow, inputs, context);
4995
4996
  return { name: typed || message, prompt: "", skill_ref: null, skill_inputs: null };
4996
4997
  }
4997
4998
  const derived = typed || deriveWorkflowName(workflow, inputs);
@@ -5005,7 +5006,7 @@ function workflowTaskFields(workflow, inputs, name, context) {
5005
5006
  }
5006
5007
  return {
5007
5008
  name: derived,
5008
- prompt: chunkGTNUQBXI_cjs.composeWorkflowPrompt(workflow, inputs, context),
5009
+ prompt: chunkP2RBE3FD_cjs.composeWorkflowPrompt(workflow, inputs, context),
5009
5010
  skill_ref: null,
5010
5011
  // The files a run is bound to travel in the saved inputs, whatever the template: the server binds
5011
5012
  // the run to the ids listed under any input's `documents`.
@@ -6101,7 +6102,7 @@ function WorkflowsTable(props) {
6101
6102
  testId: "workflow-list-empty"
6102
6103
  }
6103
6104
  ) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "min-h-0 flex-1", children: /* @__PURE__ */ jsxRuntime.jsx(
6104
- chunkIA7RTPT3_cjs.GridView,
6105
+ chunkIXALYQT7_cjs.GridView,
6105
6106
  {
6106
6107
  testId: "workflow-grid",
6107
6108
  gridId: props.gridId ?? "workflows-grid-v2",
@@ -6122,10 +6123,10 @@ function WorkflowsTable(props) {
6122
6123
  gridOptions: GRID_OPTIONS
6123
6124
  }
6124
6125
  ) }),
6125
- !props.content && /* @__PURE__ */ jsxRuntime.jsx(chunkIA7RTPT3_cjs.SelectionBar, { count: selected.length, onClear: clearSelection, children: (isCompact) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
6126
+ !props.content && /* @__PURE__ */ jsxRuntime.jsx(chunkV4ISCZJ7_cjs.SelectionBar, { count: selected.length, onClear: clearSelection, children: (isCompact) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
6126
6127
  props.onToggleActiveMany && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
6127
6128
  /* @__PURE__ */ jsxRuntime.jsx(
6128
- chunkIA7RTPT3_cjs.SelectionBarAction,
6129
+ chunkV4ISCZJ7_cjs.SelectionBarAction,
6129
6130
  {
6130
6131
  icon: lucideReact.Play,
6131
6132
  label: l.makeActive,
@@ -6139,7 +6140,7 @@ function WorkflowsTable(props) {
6139
6140
  }
6140
6141
  ),
6141
6142
  /* @__PURE__ */ jsxRuntime.jsx(
6142
- chunkIA7RTPT3_cjs.SelectionBarAction,
6143
+ chunkV4ISCZJ7_cjs.SelectionBarAction,
6143
6144
  {
6144
6145
  icon: lucideReact.Workflow,
6145
6146
  label: l.makePaused,
@@ -6154,7 +6155,7 @@ function WorkflowsTable(props) {
6154
6155
  )
6155
6156
  ] }),
6156
6157
  props.onDeleteMany && /* @__PURE__ */ jsxRuntime.jsx(
6157
- chunkIA7RTPT3_cjs.SelectionBarAction,
6158
+ chunkV4ISCZJ7_cjs.SelectionBarAction,
6158
6159
  {
6159
6160
  icon: lucideReact.Trash2,
6160
6161
  label: l.delete,
@@ -6474,7 +6475,7 @@ function groupThreadActivity(steps, items) {
6474
6475
  continue;
6475
6476
  }
6476
6477
  if (current === void 0) out.before.push(item);
6477
- else if (chunkGTNUQBXI_cjs.isRunFinished(steps, states)) out.after.push(item);
6478
+ else if (chunkP2RBE3FD_cjs.isRunFinished(steps, states)) out.after.push(item);
6478
6479
  else {
6479
6480
  const status = states[current]?.status;
6480
6481
  const at = status === "done" || status === "skipped" ? steps.find((s) => !["done", "skipped"].includes(states[s.id]?.status ?? ""))?.id ?? current : current;
@@ -6547,7 +6548,7 @@ function WorkflowThreadStrip({
6547
6548
  chevron
6548
6549
  ] }, item.id)),
6549
6550
  steps.map((step, i) => {
6550
- const phase = chunkGTNUQBXI_cjs.stepPhase(steps, states, step.id);
6551
+ const phase = chunkP2RBE3FD_cjs.stepPhase(steps, states, step.id);
6551
6552
  const happened = grouped.byStep[step.id] ?? [];
6552
6553
  const chip = /* @__PURE__ */ jsxRuntime.jsxs(
6553
6554
  "span",
@@ -6834,7 +6835,7 @@ function TaskRunsDialog({
6834
6835
  /* @__PURE__ */ jsxRuntime.jsx(ui.DialogDescription, { children: l.description })
6835
6836
  ] }),
6836
6837
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "min-h-0 flex-1", children: /* @__PURE__ */ jsxRuntime.jsx(
6837
- chunkIA7RTPT3_cjs.GridView,
6838
+ chunkIXALYQT7_cjs.GridView,
6838
6839
  {
6839
6840
  testId: chunkMHVNT4J3_cjs.testIdOr(testIds?.list, { testId: "task-runs-list" }),
6840
6841
  gridId: "workflow-runs",
@@ -7036,7 +7037,7 @@ function defaultTaskComposerValues(workflows, initial) {
7036
7037
  return {
7037
7038
  assignee: "me",
7038
7039
  workflowId,
7039
- inputs: workflow ? { ...chunkGTNUQBXI_cjs.defaultInputs(workflow), ...initial?.inputs } : { ...initial?.inputs },
7040
+ inputs: workflow ? { ...chunkP2RBE3FD_cjs.defaultInputs(workflow), ...initial?.inputs } : { ...initial?.inputs },
7040
7041
  when: "manual",
7041
7042
  runAt: "",
7042
7043
  rrule: "",
@@ -7145,7 +7146,7 @@ function WorkflowComposer({
7145
7146
  return !docs?.length;
7146
7147
  })
7147
7148
  );
7148
- const whatMissing = !workflow || Object.keys(chunkGTNUQBXI_cjs.validateInputs({ ...workflow, inputs: fields }, values.inputs)).length > 0;
7149
+ const whatMissing = !workflow || Object.keys(chunkP2RBE3FD_cjs.validateInputs({ ...workflow, inputs: fields }, values.inputs)).length > 0;
7149
7150
  const runAtPast = values.when === "once" && values.runAt !== "" && values.runAt !== initialValues?.runAt && new Date(values.runAt).getTime() <= Date.now();
7150
7151
  const whenMissing = missingWhen(values, runAtPast);
7151
7152
  const scheduled = values.when !== "now" && values.when !== "manual";
@@ -7157,7 +7158,7 @@ function WorkflowComposer({
7157
7158
  setValues({
7158
7159
  ...values,
7159
7160
  workflowId: next,
7160
- inputs: def ? chunkGTNUQBXI_cjs.defaultInputs(def) : {},
7161
+ inputs: def ? chunkP2RBE3FD_cjs.defaultInputs(def) : {},
7161
7162
  ...def?.documentAction ? { access: "standing" } : {}
7162
7163
  });
7163
7164
  };
@@ -7295,7 +7296,7 @@ function WorkflowComposer({
7295
7296
  }
7296
7297
  ),
7297
7298
  !noFiles && workflow && fields.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
7298
- chunkGTNUQBXI_cjs.SchemaForm,
7299
+ chunkP2RBE3FD_cjs.SchemaForm,
7299
7300
  {
7300
7301
  fields,
7301
7302
  values: values.inputs,
@@ -7734,7 +7735,7 @@ function WorkTaskComposer({
7734
7735
  }, [open]);
7735
7736
  const workflow = workflows.find((w) => w.id === values.workflowId);
7736
7737
  const fields = workflow?.inputs ?? [];
7737
- const errors = workflow ? chunkGTNUQBXI_cjs.validateInputs({ ...workflow, inputs: fields }, values.inputs) : {};
7738
+ const errors = workflow ? chunkP2RBE3FD_cjs.validateInputs({ ...workflow, inputs: fields }, values.inputs) : {};
7738
7739
  const hasWork = configOpen && Boolean(workflow) && Object.keys(errors).length === 0;
7739
7740
  const unattended = hasWork && values.when !== "now" && values.when !== "manual";
7740
7741
  const canConfigure = !isEdit || seed.assignee === "agent";
@@ -7742,7 +7743,7 @@ function WorkTaskComposer({
7742
7743
  const set = (key, value) => setValues({ ...values, [key]: value });
7743
7744
  const pickWorkflow = (id2) => {
7744
7745
  const next = workflows.find((w) => w.id === id2);
7745
- setValues({ ...values, workflowId: id2, inputs: next ? chunkGTNUQBXI_cjs.defaultInputs(next) : {} });
7746
+ setValues({ ...values, workflowId: id2, inputs: next ? chunkP2RBE3FD_cjs.defaultInputs(next) : {} });
7746
7747
  };
7747
7748
  const openConfigure = () => {
7748
7749
  setConfigOpen(true);
@@ -7928,7 +7929,7 @@ function WorkTaskComposer({
7928
7929
  )
7929
7930
  ] }),
7930
7931
  workflow && fields.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
7931
- chunkGTNUQBXI_cjs.SchemaForm,
7932
+ chunkP2RBE3FD_cjs.SchemaForm,
7932
7933
  {
7933
7934
  fields,
7934
7935
  values: values.inputs,
@@ -10109,5 +10110,5 @@ exports.workflowToComposerValues = workflowToComposerValues;
10109
10110
  exports.workflowToSkillMarkdown = workflowToSkillMarkdown;
10110
10111
  exports.workflowTriggerType = workflowTriggerType;
10111
10112
  exports.workflowWhen = workflowWhen;
10112
- //# sourceMappingURL=chunk-IUR565UW.cjs.map
10113
- //# sourceMappingURL=chunk-IUR565UW.cjs.map
10113
+ //# sourceMappingURL=chunk-F4LUD3YC.cjs.map
10114
+ //# sourceMappingURL=chunk-F4LUD3YC.cjs.map