@burdenoff/fluidgrids-fe-sdk 2026.1111.11 → 2026.1111.13
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/{ExecutionDetailPage-DFjVF9B6.js → ExecutionDetailPage-CDkJeeu2.js} +9 -10
- package/dist/{FailureTriagePanel-CR1BzOrM.js → FailureTriagePanel-BHiduL7A.js} +1 -1
- package/dist/{FluidGridsProvider-DpTTWDNQ.js → FluidGridsProvider-CDZjKmfD.js} +1 -2
- package/dist/{HistoryPage-CfefCOUa.js → HistoryPage-DnVGN_72.js} +3 -3
- package/dist/{InsightsPage-Cbf0cdbC.js → InsightsPage-CGRpZtGu.js} +4 -4
- package/dist/{ManagedAiPolicyAuthority-BO67oJlr.js → ManagedAiPolicyAuthority-DbJBledZ.js} +6 -6
- package/dist/{MissingNodesInstallModal-DuOtLV6V.js → MissingNodesInstallModal-Ca4f--lw.js} +2 -2
- package/dist/{NodesPage-C4KtAasX.js → NodesPage-ClvhUfbh.js} +2 -2
- package/dist/{PublishCustomNodeAction-C3fEmWnC.js → PublishCustomNodeAction-D2F7oN0S.js} +1 -1
- package/dist/{TemplateConfigurationModal-DwJi6alN.js → TemplateConfigurationModal-ChQsXf0-.js} +2 -2
- package/dist/{TemplateDetailPanel-Cpzjif1n.js → TemplateDetailPanel-C0YiVdub.js} +2 -2
- package/dist/{TemplatesPage-B3fjphKN.js → TemplatesPage-QXtq6mI3.js} +113 -504
- package/dist/{VersionDiffDialog-ExN-CN6f.js → VersionDiffDialog-Dq2xlPFI.js} +1 -1
- package/dist/{WorkflowProposalCard-DuXQI7UY.js → WorkflowProposalCard-8Vr56kQa.js} +1 -1
- package/dist/{WorkflowSearchRedirect-D4JvOvoT.js → WorkflowSearchRedirect-B4nHALJg.js} +10 -11
- package/dist/{WorkflowShareDialog-ByCefHCP.js → WorkflowShareDialog-ByTSWwwR.js} +2 -2
- package/dist/{WorkflowsList-XPY9rJpX.js → WorkflowsList-B9F2e8M6.js} +5 -6
- package/dist/{agent-form-CzG3vX_q.js → agent-form-BvMWhQ42.js} +1 -1
- package/dist/{agentTools-ZSPi5eH3.js → agentTools-C0g2OWvI.js} +2 -2
- package/dist/canvasNoteTools-BUWY18XK.js +136 -0
- package/dist/{codec-client-DiFkc0yn.js → codec-client-DstqyzTN.js} +1 -1
- package/dist/executions.js +1 -1
- package/dist/{flow-builder-BjF8QGp5.js → flow-builder-BvCQAGDR.js} +1552 -785
- package/dist/history.js +1 -1
- package/dist/{index-BES5GtJJ.d.ts → index-CLqh2u28.d.ts} +73 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +447 -26
- package/dist/{node-detail-view-Cfcpoa28.js → node-detail-view-CPD_NSZc.js} +6 -6
- package/dist/{node-endpoint-configs-DVo9nUOe.js → node-endpoint-configs-DHFGA5MQ.js} +17 -3
- package/dist/nodes.js +1 -1
- package/dist/observability.d.ts +1 -1
- package/dist/observability.js +1 -1
- package/dist/{quick-config-panel-DSEO6BGC.js → quick-config-panel-DHkYGaCL.js} +2 -2
- package/dist/settings.js +1 -1
- package/dist/templates.js +1 -1
- package/dist/{useAgentDefinitions-BVTONKpB.js → useAgentDefinitions-NFtLytDR.js} +1 -1
- package/dist/{useExecutions-C84_O9Qv.js → useExecutions-BqoD7XWi.js} +2 -2
- package/dist/{useObservability--XT0i9Lc.js → useObservability-Cs-5_NHh.js} +2 -2
- package/dist/{useRunHistory-B0IcKx_P.js → useRunHistory-CEL-CIz-.js} +2 -2
- package/dist/{useWorkflows-CDNmiA8o.js → useWorkflows-Bwpvfdgv.js} +2 -2
- package/dist/workflow-builder.js +2 -2
- package/dist/workflows-list.js +1 -1
- package/package.json +1 -1
- package/dist/rolldown-runtime-hDbaFkMy.js +0 -18
- package/dist/template-input-applicator-C0p6hE4K.js +0 -84
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
|
|
3
|
-
import { Dr as WorkflowDefinitionDocument,
|
|
3
|
+
import { Bi as describeOperationError, Dr as WorkflowDefinitionDocument, Oi as getFluidGridsClient, Ui as throwIfResultError, bi as WorkflowVersionDiffDocument } from "./node-endpoint-configs-DHFGA5MQ.js";
|
|
4
4
|
import { t as canvasFromDefinition } from "./definition-canvas--3MPHoP-.js";
|
|
5
5
|
import { memo, useCallback, useEffect, useMemo, useRef, useState } from "react";
|
|
6
6
|
import { Background, Controls, Handle, MiniMap, Position, ReactFlow, ReactFlowProvider } from "@xyflow/react";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { B as DataTablesTagsDocument, Bn as TagFluidgridsEntityDocument, Cn as RunWorkflowTestsDocument, Dn as SearchFluidgridsTagsDocument, Gr as WorkflowProposalDocument, Gt as ProposeWorkflowChangeDocument,
|
|
2
|
+
import { B as DataTablesTagsDocument, Bn as TagFluidgridsEntityDocument, Cn as RunWorkflowTestsDocument, Dn as SearchFluidgridsTagsDocument, Gr as WorkflowProposalDocument, Gt as ProposeWorkflowChangeDocument, I as CreateWorkflowTestCaseDocument, L as CreateWorkflowTestCaseFromRunDocument, O as CreateFluidgridsTagDocument, Oi as getFluidGridsClient, S as CancelWorkflowProposalDocument, Ui as throwIfResultError, Vi as isForbiddenError, Wt as ProposeRunFixDocument, X as DeleteWorkflowTestCaseDocument, Xt as RejectWorkflowProposalDocument, dr as UpdateWorkflowTestCaseDocument, er as UntagFluidgridsEntityDocument, f as AvailableFluidgridsTagsDocument, gi as WorkflowTestRunDocument, hi as WorkflowTestCasesDocument, l as ApplyWorkflowProposalDocument, qi as getFluidGridsConfig, tn as ReplaceFluidgridsEntityTagsDocument, vi as WorkflowTestRunsDocument, vt as FluidgridsEntityTagsDocument } from "./node-endpoint-configs-DHFGA5MQ.js";
|
|
3
3
|
import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
|
|
4
4
|
import { $F as WorkflowTestRunSource, $u as ErrorType, QF as WorkflowTestExpectedStatus, ZF as WorkflowTestAssertionOperator, eI as WorkflowTestRunStatus } from "./graphql-types-XcDLtFwU.js";
|
|
5
5
|
import { a as notifyFluidGridsAiCreditsUpdated } from "./aiCreditsBridge-BuE92tKo.js";
|
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { Ct as classifyCreateRefusal, Dt as useSaveStatusStore, G as paramsFromOperation, Jt as codeBuildIdOf, On as useCanvasEdges, P as createConfiguredNode, Qt as workflowFingerprint, Sn as BILLING_PLANS_PATH, Wt as rememberRevision, f as refetchStoreNodes, l as ensureNodeTypesLoaded, m as registerWorkflowNodeTypes, n as FluidGridsProvider, o as NODE_CONFIGS, p as registerNodeManifests, sn as resolveNodeOperation, xt as blankWorkflowCreateInput } from "./FluidGridsProvider-DpTTWDNQ.js";
|
|
2
|
+
import { Dr as WorkflowDefinitionDocument, Oi as getFluidGridsClient, Ui as throwIfResultError, oa as __exportAll, qi as getFluidGridsConfig } from "./node-endpoint-configs-DHFGA5MQ.js";
|
|
3
|
+
import { Ct as classifyCreateRefusal, Dt as useSaveStatusStore, G as paramsFromOperation, Jt as codeBuildIdOf, On as useCanvasEdges, P as createConfiguredNode, Qt as workflowFingerprint, Sn as BILLING_PLANS_PATH, Wt as rememberRevision, f as refetchStoreNodes, l as ensureNodeTypesLoaded, m as registerWorkflowNodeTypes, n as FluidGridsProvider, o as NODE_CONFIGS, p as registerNodeManifests, sn as resolveNodeOperation, xt as blankWorkflowCreateInput } from "./FluidGridsProvider-CDZjKmfD.js";
|
|
5
4
|
import { F as mergeStickyNotes, H as useFlowStore } from "./node-operation-selection--oy-yEq_.js";
|
|
6
5
|
import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
|
|
7
|
-
import {
|
|
6
|
+
import { H as useInstalledNodes, R as buildNodeCheck, St as Input, gt as Card, h as useWorkflowReloadStore, ht as FluidGridsMark, m as releaseLeaseKeptForReload, mt as useNodeSelectedEvent, t as FlowBuilderPage, z as buildRequiredNodeTypes } from "./flow-builder-BvCQAGDR.js";
|
|
8
7
|
import { t as cn } from "./cn-QqidFIgr.js";
|
|
9
|
-
import { i as Button } from "./PublishCustomNodeAction-
|
|
10
|
-
import { l as useLazyWorkflowDefinition, m as useWorkflowDefinition, n as useCreateWorkflow } from "./useWorkflows-
|
|
11
|
-
import { O as CreateWorkflowRefusalDialog } from "./WorkflowShareDialog-
|
|
8
|
+
import { i as Button } from "./PublishCustomNodeAction-D2F7oN0S.js";
|
|
9
|
+
import { l as useLazyWorkflowDefinition, m as useWorkflowDefinition, n as useCreateWorkflow } from "./useWorkflows-Bwpvfdgv.js";
|
|
10
|
+
import { O as CreateWorkflowRefusalDialog } from "./WorkflowShareDialog-ByTSWwwR.js";
|
|
12
11
|
import { c as withoutGuidedTourIntent, l as decideMissingWorkflow, o as isGuidedTourIntent, s as pickGuidedTour, u as isCreateIntent } from "./firstWorkflow-C_h0KMB2.js";
|
|
13
12
|
import { t as canvasFromDefinition } from "./definition-canvas--3MPHoP-.js";
|
|
14
13
|
import { n as registerLiveCanvasHandler } from "./liveCanvas-D5ytXDp8.js";
|
|
@@ -1627,7 +1626,7 @@ function GuidedTourStarter({ ready }) {
|
|
|
1627
1626
|
}
|
|
1628
1627
|
|
|
1629
1628
|
// src/builder/app/workflow/work/page.tsx
|
|
1630
|
-
const LazyMissingNodesInstallModal = lazy(() => import("./MissingNodesInstallModal-
|
|
1629
|
+
const LazyMissingNodesInstallModal = lazy(() => import("./MissingNodesInstallModal-Ca4f--lw.js").then((m) => ({ default: m.MissingNodesInstallModal })));
|
|
1631
1630
|
function WorkflowItem({ readonly = false }) {
|
|
1632
1631
|
if (readonly) {
|
|
1633
1632
|
const queryParams = new URLSearchParams(window.location.search);
|
|
@@ -1697,9 +1696,9 @@ function WorkflowItem({ readonly = false }) {
|
|
|
1697
1696
|
setInstalling(true);
|
|
1698
1697
|
setInstallErrors([]);
|
|
1699
1698
|
try {
|
|
1700
|
-
const { getGlobalStoreClient } = await import("./FluidGridsProvider-
|
|
1701
|
-
const { InstallWorkflowNodeDocument } = await import("./FluidGridsProvider-
|
|
1702
|
-
const { getFluidGridsConfig } = await import("./node-endpoint-configs-
|
|
1699
|
+
const { getGlobalStoreClient } = await import("./FluidGridsProvider-CDZjKmfD.js").then((n) => n.dr);
|
|
1700
|
+
const { InstallWorkflowNodeDocument } = await import("./FluidGridsProvider-CDZjKmfD.js").then((n) => n._);
|
|
1701
|
+
const { getFluidGridsConfig } = await import("./node-endpoint-configs-DHFGA5MQ.js").then((n) => n.Ki);
|
|
1703
1702
|
const storeClient = getGlobalStoreClient();
|
|
1704
1703
|
const cfg = getFluidGridsConfig();
|
|
1705
1704
|
for (let i = 0; i < nodesToInstall.length; i++) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { Nn as ShareWorkflowDocument,
|
|
3
|
-
import { gn as emitUpgradeClicked, ln as useFluidGridsAnalytics, vn as emitWorkflowLimitHit, wn as WORKFLOWS_QUOTA_NAME } from "./FluidGridsProvider-
|
|
2
|
+
import { Bi as describeOperationError, Nn as ShareWorkflowDocument, Oi as getFluidGridsClient, Ui as throwIfResultError, ft as ExportWorkflowCodeDocument, ui as WorkflowSharingDocument } from "./node-endpoint-configs-DHFGA5MQ.js";
|
|
3
|
+
import { gn as emitUpgradeClicked, ln as useFluidGridsAnalytics, vn as emitWorkflowLimitHit, wn as WORKFLOWS_QUOTA_NAME } from "./FluidGridsProvider-CDZjKmfD.js";
|
|
4
4
|
import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
|
|
5
5
|
import { CF as WorkflowExportFormat, Fd as FidelityLevel, JF as WorkflowShareRole, hF as WorkflowAccess, nI as WorkflowVisibility, qF as WorkflowSharePrincipalType } from "./graphql-types-XcDLtFwU.js";
|
|
6
6
|
import { useCallback, useEffect, useMemo, useRef, useState } from "react";
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { C as readProjectArchive, D as workflowNameFromFile, E as typeScriptModuleFile, O as CreateWorkflowRefusalDialog, S as primaryImportModule, T as typeScriptImportSource, _ as importFileKind, a as downloadWorkflowExport, c as canShareWorkflow, d as MAX_IMPORT_ARCHIVE_BYTES, f as MAX_IMPORT_SOURCE_BYTES, g as importAcceptAttribute, k as QuotaExhaustedDialog, l as CODE_EXPORT_FORMATS, m as checkTypeScriptImport, o as parseWorkflowImport, p as assertImportByteSize, r as useExportWorkflowAs, s as canEditWorkflow, t as WorkflowShareDialog, u as ImportSourceError } from "./WorkflowShareDialog-ByCefHCP.js";
|
|
2
|
+
import { c as useImportWorkflow, h as useWorkflowDefinitions, l as useLazyWorkflowDefinition, n as useCreateWorkflow, o as useDeleteWorkflow, s as useDuplicateWorkflow, u as usePreviewN8nImport } from "./useWorkflows-Bwpvfdgv.js";
|
|
3
|
+
import { Bn as FLUIDGRIDS_FLAGS, Dn as isQuotaExhaustedFailure, Jn as useFluidGridsFlag, Sn as BILLING_PLANS_PATH, t as FluidGridsContext, wt as createThenOpen } from "./FluidGridsProvider-CDZjKmfD.js";
|
|
4
|
+
import { C as readProjectArchive, D as workflowNameFromFile, E as typeScriptModuleFile, O as CreateWorkflowRefusalDialog, S as primaryImportModule, T as typeScriptImportSource, _ as importFileKind, a as downloadWorkflowExport, c as canShareWorkflow, d as MAX_IMPORT_ARCHIVE_BYTES, f as MAX_IMPORT_SOURCE_BYTES, g as importAcceptAttribute, k as QuotaExhaustedDialog, l as CODE_EXPORT_FORMATS, m as checkTypeScriptImport, o as parseWorkflowImport, p as assertImportByteSize, r as useExportWorkflowAs, s as canEditWorkflow, t as WorkflowShareDialog, u as ImportSourceError } from "./WorkflowShareDialog-ByTSWwwR.js";
|
|
6
5
|
import { H as useFlowStore } from "./node-operation-selection--oy-yEq_.js";
|
|
7
6
|
import { CF as WorkflowExportFormat, gF as WorkflowAccessFilter, hI as FLUIDGRIDS_PERMISSIONS, vI as SdkPermissionButton, xI as useFluidGridsPermission, yI as SdkPermissionGate } from "./graphql-types-XcDLtFwU.js";
|
|
8
7
|
import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
|
|
9
|
-
import { $t as RenameWorkflowFolderDocument, Et as MoveWorkflowFolderDocument, K as DeleteWorkflowFolderDocument, M as CreateWorkflowFolderDocument, N as CreateWorkflowProjectDocument,
|
|
10
|
-
import { a as useExecutions } from "./useExecutions-
|
|
8
|
+
import { $t as RenameWorkflowFolderDocument, Bi as describeOperationError, Et as MoveWorkflowFolderDocument, K as DeleteWorkflowFolderDocument, M as CreateWorkflowFolderDocument, N as CreateWorkflowProjectDocument, Oi as getFluidGridsClient, Pr as WorkflowFoldersDocument, Ui as throwIfResultError, Ur as WorkflowProjectsDocument, _ as BulkMoveWorkflowsToFolderDocument, en as RenameWorkflowProjectDocument, g as BulkDeleteWorkflowsDocument, h as BulkAssignWorkflowsToProjectDocument, oa as __exportAll, q as DeleteWorkflowProjectDocument } from "./node-endpoint-configs-DHFGA5MQ.js";
|
|
9
|
+
import { a as useExecutions } from "./useExecutions-BqoD7XWi.js";
|
|
11
10
|
import { a as firstWorkflowProgress, i as builderPathFor, r as GUIDED_TOUR_STATE } from "./firstWorkflow-C_h0KMB2.js";
|
|
12
11
|
import { n as useFluidGridsPageControls } from "./pageControlsBridge-0pX9s-3k.js";
|
|
13
12
|
import { i as workflowsListControls } from "./pageControlSpecs-DZJ9K37m.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { C as CodecServerSettingsDocument, Cr as WorkflowBatchOperationsDocument, D as CreateActivityPauseRuleDocument, F as CreateWorkflowSignalTokenDocument, H as DeleteActivityPauseRuleDocument, In as StartBatchExportDocument, Ln as StartBatchOperationDocument, Lt as PauseActivityDocument, P as CreateWorkflowSearchAttributeDocument, Qn as UnpauseWorkflowScheduleDocument, Rn as StartBatchTerminateDocument, Tr as WorkflowCodeBundleSdkDocument,
|
|
2
|
+
import { Bi as describeOperationError, C as CodecServerSettingsDocument, Cr as WorkflowBatchOperationsDocument, D as CreateActivityPauseRuleDocument, F as CreateWorkflowSignalTokenDocument, H as DeleteActivityPauseRuleDocument, In as StartBatchExportDocument, Ln as StartBatchOperationDocument, Lt as PauseActivityDocument, Oi as getFluidGridsClient, P as CreateWorkflowSearchAttributeDocument, Qn as UnpauseWorkflowScheduleDocument, Rn as StartBatchTerminateDocument, Tr as WorkflowCodeBundleSdkDocument, Ui as throwIfResultError, Y as DeleteWorkflowSearchAttributeDocument, Yn as TriggerWorkflowScheduleDocument, Zn as UnpauseActivityDocument, Zr as WorkflowRunHistoryArchiveDocument, _r as WorkflowActivityPauseRulesDocument, ai as WorkflowScheduleDescribeDocument, an as ResetWorkflowRunToLastCleanTaskDocument, d as ArchiveSettingsDocument, fi as WorkflowSignalTokensDocument, fr as UpsertWorkflowRunSearchAttributesDocument, in as ResetWorkflowRunDocument, li as WorkflowSearchAttributesDocument, mn as RunControlFieldsDocument, ni as WorkflowRunUpdateDocument, nr as UpdateArchiveSettingsDocument, p as BackfillWorkflowScheduleDocument, pt as FailActivityByIdDocument, qt as QueryWorkflowRunDocument, rn as ResetActivityDocument, rr as UpdateCodecServerSettingsDocument, tr as UpdateActivityOptionsDocument, un as RevokeWorkflowSignalTokenDocument, ur as UpdateWorkflowRunDocument, v as CancelBatchOperationDocument, w as CompleteActivityByIdDocument, xr as WorkflowBatchOperationDocument, zt as PauseWorkflowScheduleDocument } from "./node-endpoint-configs-DHFGA5MQ.js";
|
|
3
3
|
import { useCallback, useEffect, useRef, useState } from "react";
|
|
4
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
5
|
import { Label, Textarea } from "@burdenoff/fe-libs/ui";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { Dt as useSaveStatusStore, G as paramsFromOperation, K as selectedOperationOf, P as createConfiguredNode, U as nodeTitle, V as fixedParameterState, h as registryNodeData, o as NODE_CONFIGS, u as isNodeConfigsInitialized, ut as autosaveAllowedFor, vt as isFlowComplete } from "./FluidGridsProvider-
|
|
2
|
+
import { Dt as useSaveStatusStore, G as paramsFromOperation, K as selectedOperationOf, P as createConfiguredNode, U as nodeTitle, V as fixedParameterState, h as registryNodeData, o as NODE_CONFIGS, u as isNodeConfigsInitialized, ut as autosaveAllowedFor, vt as isFlowComplete } from "./FluidGridsProvider-CDZjKmfD.js";
|
|
3
3
|
import { E as resolveOutputHandles, H as useFlowStore, T as resolveInputHandles } from "./node-operation-selection--oy-yEq_.js";
|
|
4
|
-
import {
|
|
4
|
+
import { I as computeAttachPosition, Ot as isNodeTypeHiddenFromPalette } from "./flow-builder-BvCQAGDR.js";
|
|
5
5
|
import { AgentToolError, defineAgentTool } from "@burdenoff/fe-libs/shared/agent-tools";
|
|
6
6
|
import { z } from "zod";
|
|
7
7
|
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { g as notesKeyOf, v as useAgentMarksStore, y as toPlainText } from "./flow-builder-BvCQAGDR.js";
|
|
3
|
+
import { G as paramsFromOperation, K as selectedOperationOf, U as nodeTitle } from "./FluidGridsProvider-CDZjKmfD.js";
|
|
4
|
+
import { H as useFlowStore } from "./node-operation-selection--oy-yEq_.js";
|
|
5
|
+
import { AgentToolError, defineAgentTool } from "@burdenoff/fe-libs/shared/agent-tools";
|
|
6
|
+
import { z } from "zod";
|
|
7
|
+
|
|
8
|
+
// src/builder/agentNotes/canvasNoteTools.ts
|
|
9
|
+
const MAX_NOTES_LISTED = 20;
|
|
10
|
+
function workflow() {
|
|
11
|
+
return useFlowStore.getState().workflow;
|
|
12
|
+
}
|
|
13
|
+
function dataOf(node) {
|
|
14
|
+
return node.data && typeof node.data === "object" ? node.data : {};
|
|
15
|
+
}
|
|
16
|
+
const nodeRef = z.string().trim().min(1).max(100).describe("A node id from fg_canvas_read, or the node's exact title.");
|
|
17
|
+
/** A node by id, else by exact title (case-insensitive) when that is unique. */
|
|
18
|
+
function resolveNode(ref) {
|
|
19
|
+
const nodes = workflow().nodes;
|
|
20
|
+
const byId = nodes.find((node) => node.id === ref);
|
|
21
|
+
if (byId) return byId;
|
|
22
|
+
const wanted = ref.toLowerCase();
|
|
23
|
+
const byTitle = nodes.filter((node) => nodeTitle(node).toLowerCase() === wanted);
|
|
24
|
+
if (byTitle.length === 1 && byTitle[0]) return byTitle[0];
|
|
25
|
+
if (byTitle.length > 1) throw new AgentToolError("INVALID_INPUT", `${byTitle.length} nodes are titled "${ref.slice(0, 40)}": ${byTitle.slice(0, 6).map((node) => node.id).join(", ")}. Use the node id.`);
|
|
26
|
+
throw new AgentToolError("NOT_FOUND", `No node "${ref.slice(0, 40)}" on the canvas. Use fg_canvas_read for ids.`, { retryable: true });
|
|
27
|
+
}
|
|
28
|
+
/** The parameter names a node's operation has. */
|
|
29
|
+
function parameterNames(node) {
|
|
30
|
+
return paramsFromOperation(selectedOperationOf(dataOf(node), node.type)).map((parameter) => parameter.name);
|
|
31
|
+
}
|
|
32
|
+
function summary(note, liveIds) {
|
|
33
|
+
return {
|
|
34
|
+
number: note.number,
|
|
35
|
+
nodeId: note.nodeId,
|
|
36
|
+
node: note.nodeLabel,
|
|
37
|
+
...note.paramKey ? { param: note.paramKey } : {},
|
|
38
|
+
kind: note.kind,
|
|
39
|
+
message: toPlainText(note.message, 120),
|
|
40
|
+
resolved: note.resolved,
|
|
41
|
+
...liveIds.has(note.nodeId) ? {} : { orphaned: true }
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
function createCanvasNoteTools(options = {}) {
|
|
45
|
+
const focus = async (nodeId) => {
|
|
46
|
+
if (!options.focusNode) return false;
|
|
47
|
+
const done = await options.focusNode(nodeId);
|
|
48
|
+
if (done) useAgentMarksStore.getState().actions.flashNode(nodeId);
|
|
49
|
+
return done;
|
|
50
|
+
};
|
|
51
|
+
return [
|
|
52
|
+
defineAgentTool({
|
|
53
|
+
name: "fg_canvas_annotate",
|
|
54
|
+
title: "Pin a note on a node",
|
|
55
|
+
description: "Pins a numbered note on a node of the workflow open in the builder, to show the person what to change or check there (they resolve it). It does not change the workflow. Use kind fix for something they must change, info for an explanation. Name the parameter with param when the note is about one field.",
|
|
56
|
+
input: z.strictObject({
|
|
57
|
+
node: nodeRef,
|
|
58
|
+
message: z.string().trim().min(1).max(280).describe("What to do or know, in one or two plain sentences. No markdown."),
|
|
59
|
+
kind: z.enum(["fix", "info"]).default("fix").describe("fix: the person must change something; info: an explanation."),
|
|
60
|
+
param: z.string().trim().min(1).max(80).optional().describe("A parameter name of the node the note is about; an unknown one lists the valid names."),
|
|
61
|
+
focus: z.boolean().default(true).describe("Bring the node into view (default true).")
|
|
62
|
+
}),
|
|
63
|
+
annotations: {
|
|
64
|
+
readOnly: true,
|
|
65
|
+
untrustedContent: true
|
|
66
|
+
},
|
|
67
|
+
execute: async ({ node: ref, message, kind, param, focus: bringIntoView }) => {
|
|
68
|
+
const node = resolveNode(ref);
|
|
69
|
+
if (param) {
|
|
70
|
+
const names = parameterNames(node);
|
|
71
|
+
if (!names.includes(param)) throw new AgentToolError("INVALID_INPUT", names.length > 0 ? `No parameter "${param.slice(0, 40)}". Parameters: ${names.slice(0, 20).join(", ")}.` : "This node has no parameters; leave param out.");
|
|
72
|
+
}
|
|
73
|
+
const key = notesKeyOf(workflow());
|
|
74
|
+
const note = useAgentMarksStore.getState().actions.addNote({
|
|
75
|
+
workflowKey: key,
|
|
76
|
+
nodeId: node.id,
|
|
77
|
+
nodeLabel: nodeTitle(node),
|
|
78
|
+
paramKey: param ?? null,
|
|
79
|
+
kind,
|
|
80
|
+
message
|
|
81
|
+
});
|
|
82
|
+
if (!note) throw new AgentToolError("CONFLICT", `This workflow already has ${20} notes. Ask the person to resolve some, or clear them with fg_ui_clear_marks.`);
|
|
83
|
+
const focused = bringIntoView ? await focus(node.id) : false;
|
|
84
|
+
return {
|
|
85
|
+
noteNumber: note.number,
|
|
86
|
+
nodeId: node.id,
|
|
87
|
+
node: note.nodeLabel,
|
|
88
|
+
...note.paramKey ? { param: note.paramKey } : {},
|
|
89
|
+
focused
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
}),
|
|
93
|
+
defineAgentTool({
|
|
94
|
+
name: "fg_canvas_notes",
|
|
95
|
+
title: "List the notes on the canvas",
|
|
96
|
+
description: "Lists the notes you pinned on the open workflow: number, node, parameter, message, whether the person resolved it, and orphaned when its node was deleted.",
|
|
97
|
+
input: z.strictObject({}),
|
|
98
|
+
annotations: {
|
|
99
|
+
readOnly: true,
|
|
100
|
+
untrustedContent: true
|
|
101
|
+
},
|
|
102
|
+
execute: () => {
|
|
103
|
+
const current = workflow();
|
|
104
|
+
const key = notesKeyOf(current);
|
|
105
|
+
const liveIds = new Set(current.nodes.map((node) => node.id));
|
|
106
|
+
const notes = useAgentMarksStore.getState().notes.filter((note) => note.workflowKey === key);
|
|
107
|
+
return {
|
|
108
|
+
total: notes.length,
|
|
109
|
+
open: notes.filter((note) => !note.resolved).length,
|
|
110
|
+
notes: notes.slice(0, MAX_NOTES_LISTED).map((note) => summary(note, liveIds))
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
}),
|
|
114
|
+
defineAgentTool({
|
|
115
|
+
name: "fg_canvas_focus_node",
|
|
116
|
+
title: "Show a node",
|
|
117
|
+
description: "Pans and zooms the builder canvas to one node and briefly highlights it, so the person can see it. It does not change the workflow.",
|
|
118
|
+
input: z.strictObject({ node: nodeRef }),
|
|
119
|
+
annotations: {
|
|
120
|
+
readOnly: true,
|
|
121
|
+
untrustedContent: true
|
|
122
|
+
},
|
|
123
|
+
execute: async ({ node: ref }) => {
|
|
124
|
+
const node = resolveNode(ref);
|
|
125
|
+
if (!await focus(node.id)) throw new AgentToolError("CONFLICT", "The canvas is not ready yet. Try again in a moment.", { retryable: true });
|
|
126
|
+
return {
|
|
127
|
+
nodeId: node.id,
|
|
128
|
+
node: nodeTitle(node),
|
|
129
|
+
focused: true
|
|
130
|
+
};
|
|
131
|
+
}
|
|
132
|
+
})
|
|
133
|
+
];
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
export { createCanvasNoteTools };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
2
|
+
import { Oi as getFluidGridsClient, Ui as throwIfResultError } from "./node-endpoint-configs-DHFGA5MQ.js";
|
|
3
3
|
import { r as useTr } from "./TranslationBridge-Da-TPgQm.js";
|
|
4
4
|
import { useCallback, useEffect, useState } from "react";
|
|
5
5
|
import { cn } from "@burdenoff/fe-libs/utils";
|
package/dist/executions.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { t as ExecutionDetailPage, y as ExecutionsListPage } from "./ExecutionDetailPage-
|
|
2
|
+
import { t as ExecutionDetailPage, y as ExecutionsListPage } from "./ExecutionDetailPage-CDkJeeu2.js";
|
|
3
3
|
|
|
4
4
|
export { ExecutionDetailPage, ExecutionsListPage };
|