@burdenoff/fluidgrids-fe-sdk 2026.801.1 → 2026.801.2

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.
@@ -20,6 +20,8 @@ var useFlowStore = create()((set, get) => ({
20
20
  edges: [],
21
21
  nodes: [],
22
22
  ndv: null,
23
+ quickConfig: null,
24
+ pendingConnection: null,
23
25
  sidebar: {
24
26
  active: "none",
25
27
  panels: {
@@ -67,6 +69,8 @@ var useFlowStore = create()((set, get) => ({
67
69
  edges: [],
68
70
  nodes: [],
69
71
  ndv: null,
72
+ quickConfig: null,
73
+ pendingConnection: null,
70
74
  sidebar: {
71
75
  active: "none",
72
76
  panels: {
@@ -79,24 +83,50 @@ var useFlowStore = create()((set, get) => ({
79
83
  }));
80
84
  },
81
85
  ndv: {
86
+ // Opening the full NDV supersedes the floating quick-config panel — the
87
+ // two edit the same node data, so only one should be visible at a time.
82
88
  open: (node) => set((state) => ({
83
- workflow: { ...state.workflow, ndv: node }
89
+ workflow: { ...state.workflow, ndv: node, quickConfig: null }
84
90
  })),
85
91
  close: () => set((state) => ({
86
92
  workflow: { ...state.workflow, ndv: null }
87
93
  }))
88
94
  },
95
+ quickConfig: {
96
+ open: (node) => set((state) => ({
97
+ workflow: { ...state.workflow, quickConfig: node }
98
+ })),
99
+ close: () => set((state) => ({
100
+ workflow: { ...state.workflow, quickConfig: null }
101
+ }))
102
+ },
103
+ pendingConnection: {
104
+ start: (connection) => set((state) => ({
105
+ workflow: {
106
+ ...state.workflow,
107
+ pendingConnection: connection,
108
+ sidebar: { ...state.workflow.sidebar, active: "store-browse" }
109
+ }
110
+ })),
111
+ clear: () => set((state) => ({
112
+ workflow: { ...state.workflow, pendingConnection: null }
113
+ }))
114
+ },
89
115
  sidebar: {
116
+ // Leaving the store panel abandons any armed "+" attach mode — the
117
+ // pending handle would otherwise silently capture a later insert.
90
118
  setActivePanel: (panel) => set((state) => ({
91
119
  workflow: {
92
120
  ...state.workflow,
93
- sidebar: { ...state.workflow.sidebar, active: panel }
121
+ sidebar: { ...state.workflow.sidebar, active: panel },
122
+ ...panel !== "store-browse" ? { pendingConnection: null } : {}
94
123
  }
95
124
  })),
96
125
  showNodePropertiesOf: (node) => {
97
126
  set((state) => ({
98
127
  workflow: {
99
128
  ...state.workflow,
129
+ pendingConnection: null,
100
130
  sidebar: {
101
131
  ...state.workflow.sidebar,
102
132
  active: "node-properties",
@@ -162,7 +192,10 @@ var useFlowStore = create()((set, get) => ({
162
192
  set((state) => ({
163
193
  workflow: {
164
194
  ...state.workflow,
165
- nodes: state.workflow.nodes.filter((n) => n.id !== node.id)
195
+ nodes: state.workflow.nodes.filter((n) => n.id !== node.id),
196
+ // Drop any UI state pointing at the removed node.
197
+ ...state.workflow.quickConfig?.nodeId === node.id ? { quickConfig: null } : {},
198
+ ...state.workflow.pendingConnection?.nodeId === node.id ? { pendingConnection: null } : {}
166
199
  }
167
200
  }));
168
201
  }
@@ -301,5 +334,5 @@ if (typeof window !== "undefined" && import.meta.env?.DEV) {
301
334
  }
302
335
 
303
336
  export { useFlowStore };
304
- //# sourceMappingURL=chunk-KU64CCSV.js.map
305
- //# sourceMappingURL=chunk-KU64CCSV.js.map
337
+ //# sourceMappingURL=chunk-WSBRI47P.js.map
338
+ //# sourceMappingURL=chunk-WSBRI47P.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/builder/stores/flow-store.ts"],"names":[],"mappings":";;;;;AAkLA,IAAM,IAAA,GAAc;AAAA,EAClB,EAAE,KAAA,EAAO,WAAA,EAAa,KAAA,EAAO,WAAA,EAAa,OAAO,SAAA,EAAU;AAAA,EAC3D,EAAE,KAAA,EAAO,SAAA,EAAW,KAAA,EAAO,SAAA,EAAW,OAAO,SAAA,EAAU;AAAA,EACvD,EAAE,KAAA,EAAO,MAAA,EAAQ,KAAA,EAAO,MAAA,EAAQ,OAAO,SAAA,EAAU;AAAA,EACjD,EAAE,KAAA,EAAO,KAAA,EAAO,KAAA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,MAAM,EAAC;AAAA,YACP,aAAA,EAAe,IAAA;AAAA,YACf,cAAc,EAAC;AAAA,YACf,gBAAgB;AAAC;AACnB,SACF,CAAE,CAAA;AAAA,MACJ,CAAA;AAAA,MACA,mBAAmB,MAAM;AACvB,QAAA,GAAA,CAAI,CAAC,KAAA,MAAW;AAAA,UACd,SAAA,EAAW;AAAA,YACT,GAAG,KAAA,CAAM,SAAA;AAAA,YACT,WAAA,EAAa,KAAA;AAAA,YACb,eAAA,EAAiB;AAAA;AACnB,SACF,CAAE,CAAA;AAAA,MACJ;AAAA;AACF;AAEJ,CAAA,CAAE;AAIF,IAAI,OAAO,MAAA,KAAW,WAAA,IAAe,MAAA,CAAA,IAAA,CAAY,KAAK,GAAA,EAAK;AACzD,EAAC,OAA8C,aAAA,GAAgB,YAAA;AACjE","file":"chunk-WSBRI47P.js","sourcesContent":["import { nanoid } from \"nanoid/non-secure\";\nimport {\n addEdge,\n applyEdgeChanges,\n applyNodeChanges,\n type Connection,\n type Edge,\n type EdgeChange,\n type Node,\n type NodeChange,\n} from \"@xyflow/react\";\nimport { create } from \"zustand\";\nimport { produce } from \"immer\";\nimport type {\n ExtendedNodeType,\n FlowNode,\n FlowEdge,\n EdgeCondition,\n EdgeMapping,\n} from \"../../types/node\";\nimport type { Tag } from \"../../types/workflow\";\nimport type { ExecutionLog } from \"../../types/execution\";\n\n// Node execution state for visual display\nexport interface NodeExecutionState {\n status: \"idle\" | \"running\" | \"success\" | \"error\";\n itemCount?: number;\n error?: string;\n}\n\n// Execution state for step execution feature\ninterface ExecutionState {\n isExecuting: boolean;\n executingNodeId: string | null;\n currentRunId: string | null;\n logs: ExecutionLog[];\n selectedLogId: string | null;\n panelExpanded: boolean;\n nodeStatuses: Record<string, \"idle\" | \"running\" | \"success\" | \"error\">;\n nodeItemCounts: Record<string, number>;\n}\n\ninterface CustomEdgeProps extends Edge {\n condition?: EdgeCondition;\n mapping?: EdgeMapping;\n}\n\ninterface State {\n nodes: Node[];\n edges: CustomEdgeProps[];\n /** Node currently open in the n8n-style 3-pane Node Detail View modal. */\n ndv?: { nodeId: string; type: ExtendedNodeType } | null;\n /**\n * Node currently open in the single-click floating quick-config panel\n * (Make-style popup near the node). `anchor` is the screen position captured\n * when the panel was opened.\n */\n quickConfig?: {\n nodeId: string;\n type: ExtendedNodeType;\n anchor?: { x: number; y: number };\n } | null;\n /**\n * Source handle awaiting attachment via the Node Store (the n8n-style \"+\"\n * button on an output handle). While set, clicking an operation in the\n * store panel creates the node and wires it to this handle.\n */\n pendingConnection?: { nodeId: string; handleId: string } | null;\n sidebar: {\n active: \"node-properties\" | \"store-browse\" | \"none\";\n panels: {\n nodeProperties: {\n selectedNode: { id: string; type: ExtendedNodeType } | null | undefined;\n };\n };\n };\n}\n\ninterface Actions {\n actions: {\n saveWorkflow: () => {\n id: string;\n name: string;\n version: string;\n alias?: string;\n dbId?: string;\n status?: string;\n nodes: Node[];\n edges: Edge[];\n };\n setWorkflow: (workflow: Partial<IFlowState[\"workflow\"]>) => void;\n resetWorkflow: () => void;\n nodes: {\n onNodesChange: (changes: NodeChange[]) => void;\n setNodes: (nodes: Node[]) => void;\n deleteNode: (node: Node) => void;\n };\n edges: {\n onEdgesChange: (changes: EdgeChange[]) => void;\n onConnect: (connection: Connection) => void;\n setEdges: (edges: Edge[]) => void;\n deleteEdge: (edge: Edge) => void;\n };\n ndv: {\n open: (node: { nodeId: string; type: ExtendedNodeType }) => void;\n close: () => void;\n };\n quickConfig: {\n open: (node: {\n nodeId: string;\n type: ExtendedNodeType;\n anchor?: { x: number; y: number };\n }) => void;\n close: () => void;\n };\n pendingConnection: {\n /** Arm attach mode for a source handle and open the Node Store panel. */\n start: (connection: { nodeId: string; handleId: string }) => void;\n clear: () => void;\n };\n sidebar: {\n setActivePanel: (\n panel: \"node-properties\" | \"store-browse\" | \"none\",\n ) => void;\n showNodePropertiesOf: (node: {\n id: string;\n type: ExtendedNodeType;\n block?: string;\n }) => void;\n panels: {\n nodeProperties: {\n setSelectedNode: (\n node: { id: string; type: ExtendedNodeType } | undefined | null,\n ) => void;\n };\n tags: {\n setTags: (tags: Tag[]) => void;\n createTag: (tag: Tag) => void;\n deleteTag: (tag: Tag) => void;\n updateTag: (tag: Tag, newTag: Tag) => void;\n };\n };\n };\n };\n}\n\nexport interface IFlowState {\n tags: Tag[];\n workflow: {\n id: string;\n workflowKey: string;\n name: string;\n version: string;\n alias?: string;\n /** Database row ID (used for updateWorkflowDefinition) */\n dbId?: string;\n /** Current workflow status: DRAFT | ACTIVE | ARCHIVED | DEPRECATED */\n status?: string;\n } & State;\n execution: ExecutionState;\n actions: Actions[\"actions\"] & {\n execution: {\n startExecution: (nodeId: string, runId: string) => void;\n addLog: (log: ExecutionLog) => void;\n updateLog: (logId: string, updates: Partial<ExecutionLog>) => void;\n setNodeStatus: (\n nodeId: string,\n status: \"idle\" | \"running\" | \"success\" | \"error\",\n ) => void;\n setNodeItemCount: (nodeId: string, count: number) => void;\n selectLog: (logId: string | null) => void;\n togglePanel: () => void;\n clearLogs: () => void;\n completeExecution: () => void;\n };\n };\n}\n\nconst TAGS: Tag[] = [\n { value: \"marketing\", label: \"Marketing\", color: \"#ef4444\" },\n { value: \"support\", label: \"Support\", color: \"#ef4444\" },\n { value: \"lead\", label: \"Lead\", color: \"#eab308\" },\n { value: \"new\", label: \"New\", color: \"#22c55e\" },\n];\n\nexport const useFlowStore = create<IFlowState>()((set, get) => ({\n tags: TAGS,\n workflow: {\n id: nanoid(),\n workflowKey: \"\",\n name: \"\",\n version: \"\",\n alias: \"\",\n edges: [],\n nodes: [],\n ndv: null,\n quickConfig: null,\n pendingConnection: null,\n sidebar: {\n active: \"none\",\n panels: {\n nodeProperties: {\n selectedNode: null,\n },\n },\n },\n },\n execution: {\n isExecuting: false,\n executingNodeId: null,\n currentRunId: null,\n logs: [],\n selectedLogId: null,\n panelExpanded: false,\n nodeStatuses: {},\n nodeItemCounts: {},\n },\n actions: {\n saveWorkflow: () => {\n const { workflow } = get();\n const { id, name, version, alias, dbId, status, nodes, edges } = workflow;\n set({ workflow });\n return { id, name, version, alias, dbId, status, nodes, edges };\n },\n setWorkflow: (workflow: Partial<IFlowState[\"workflow\"]>) => {\n set((state) => ({\n workflow: {\n ...state.workflow,\n ...workflow,\n },\n }));\n },\n resetWorkflow: () => {\n set(() => ({\n workflow: {\n id: nanoid(),\n workflowKey: \"\",\n name: \"\",\n version: \"\",\n alias: \"\",\n dbId: undefined,\n status: undefined,\n edges: [],\n nodes: [],\n ndv: null,\n quickConfig: null,\n pendingConnection: null,\n sidebar: {\n active: \"none\",\n panels: {\n nodeProperties: {\n selectedNode: null,\n },\n },\n },\n },\n }));\n },\n ndv: {\n // Opening the full NDV supersedes the floating quick-config panel — the\n // two edit the same node data, so only one should be visible at a time.\n open: (node: { nodeId: string; type: ExtendedNodeType }) =>\n set((state) => ({\n workflow: { ...state.workflow, ndv: node, quickConfig: null },\n })),\n close: () =>\n set((state) => ({\n workflow: { ...state.workflow, ndv: null },\n })),\n },\n quickConfig: {\n open: (node: {\n nodeId: string;\n type: ExtendedNodeType;\n anchor?: { x: number; y: number };\n }) =>\n set((state) => ({\n workflow: { ...state.workflow, quickConfig: node },\n })),\n close: () =>\n set((state) => ({\n workflow: { ...state.workflow, quickConfig: null },\n })),\n },\n pendingConnection: {\n start: (connection: { nodeId: string; handleId: string }) =>\n set((state) => ({\n workflow: {\n ...state.workflow,\n pendingConnection: connection,\n sidebar: { ...state.workflow.sidebar, active: \"store-browse\" },\n },\n })),\n clear: () =>\n set((state) => ({\n workflow: { ...state.workflow, pendingConnection: null },\n })),\n },\n sidebar: {\n // Leaving the store panel abandons any armed \"+\" attach mode — the\n // pending handle would otherwise silently capture a later insert.\n setActivePanel: (panel: \"node-properties\" | \"store-browse\" | \"none\") =>\n set((state) => ({\n workflow: {\n ...state.workflow,\n sidebar: { ...state.workflow.sidebar, active: panel },\n ...(panel !== \"store-browse\" ? { pendingConnection: null } : {}),\n },\n })),\n showNodePropertiesOf: (node: { id: string; type: ExtendedNodeType }) => {\n set((state) => ({\n workflow: {\n ...state.workflow,\n pendingConnection: null,\n sidebar: {\n ...state.workflow.sidebar,\n active: \"node-properties\",\n panels: {\n ...state.workflow.sidebar.panels,\n nodeProperties: {\n ...state.workflow.sidebar.panels.nodeProperties,\n selectedNode: node,\n },\n },\n },\n },\n }));\n },\n panels: {\n nodeProperties: {\n setSelectedNode: (\n node: { id: string; type: ExtendedNodeType } | undefined | null,\n ) =>\n set((state) => ({\n workflow: {\n ...state.workflow,\n sidebar: {\n ...state.workflow.sidebar,\n panels: {\n ...state.workflow.sidebar.panels,\n nodeProperties: {\n ...state.workflow.sidebar.panels.nodeProperties,\n selectedNode: node,\n },\n },\n },\n },\n })),\n },\n tags: {\n setTags: (tags: Tag[]) => set({ tags }),\n createTag: (tag: Tag) =>\n set((state) => ({\n tags: [...state.tags, tag],\n })),\n updateTag: (tag: Tag, newTag: Tag) =>\n set((state) => ({\n tags: state.tags.map((f) => (f.value === tag.value ? newTag : f)),\n })),\n deleteTag: (tag: Tag) =>\n set((state) => ({\n tags: state.tags.filter((f) => f.value !== tag.value),\n })),\n },\n },\n },\n nodes: {\n onNodesChange: (changes) => {\n set((state) =>\n produce(state, (draft) => {\n const updatedNodes = applyNodeChanges(\n changes,\n draft.workflow.nodes,\n );\n draft.workflow.nodes = updatedNodes;\n }),\n );\n },\n setNodes: (nodes) => {\n set({ workflow: { ...get().workflow, nodes } });\n },\n deleteNode: (node: Node) => {\n set((state) => ({\n workflow: {\n ...state.workflow,\n nodes: state.workflow.nodes.filter((n) => n.id !== node.id),\n // Drop any UI state pointing at the removed node.\n ...(state.workflow.quickConfig?.nodeId === node.id\n ? { quickConfig: null }\n : {}),\n ...(state.workflow.pendingConnection?.nodeId === node.id\n ? { pendingConnection: null }\n : {}),\n },\n }));\n },\n },\n edges: {\n onEdgesChange: (changes) => {\n set((state) =>\n produce(state, (draft) => {\n const updatedEdges = applyEdgeChanges(\n changes,\n draft.workflow.edges,\n );\n draft.workflow.edges = updatedEdges;\n }),\n );\n },\n onConnect: (connection) => {\n const edge = { ...connection, id: nanoid(), type: \"deletable\" } as Edge;\n set({\n workflow: {\n ...get().workflow,\n edges: addEdge(edge, get().workflow.edges),\n },\n });\n },\n setEdges: (edges) => {\n set({ workflow: { ...get().workflow, edges } });\n },\n deleteEdge: (edge: Edge) => {\n set((state) => ({\n workflow: {\n ...state.workflow,\n edges: state.workflow.edges.filter((e) => e.id !== edge.id),\n },\n }));\n },\n },\n execution: {\n startExecution: (nodeId: string, runId: string) => {\n set((state) => ({\n execution: {\n ...state.execution,\n isExecuting: true,\n executingNodeId: nodeId,\n currentRunId: runId,\n panelExpanded: true,\n nodeStatuses: {\n ...state.execution.nodeStatuses,\n [nodeId]: \"running\",\n },\n },\n }));\n },\n addLog: (log: ExecutionLog) => {\n set((state) => ({\n execution: {\n ...state.execution,\n logs: [...state.execution.logs, log],\n selectedLogId: log.id,\n },\n }));\n },\n updateLog: (logId: string, updates: Partial<ExecutionLog>) => {\n set((state) => ({\n execution: {\n ...state.execution,\n logs: state.execution.logs.map((log) =>\n log.id === logId ? { ...log, ...updates } : log,\n ),\n },\n }));\n },\n setNodeStatus: (\n nodeId: string,\n status: \"idle\" | \"running\" | \"success\" | \"error\",\n ) => {\n set((state) => ({\n execution: {\n ...state.execution,\n nodeStatuses: {\n ...state.execution.nodeStatuses,\n [nodeId]: status,\n },\n },\n }));\n },\n setNodeItemCount: (nodeId: string, count: number) => {\n set((state) => ({\n execution: {\n ...state.execution,\n nodeItemCounts: {\n ...state.execution.nodeItemCounts,\n [nodeId]: count,\n },\n },\n }));\n },\n selectLog: (logId: string | null) => {\n set((state) => ({\n execution: {\n ...state.execution,\n selectedLogId: logId,\n },\n }));\n },\n togglePanel: () => {\n set((state) => ({\n execution: {\n ...state.execution,\n panelExpanded: !state.execution.panelExpanded,\n },\n }));\n },\n clearLogs: () => {\n set((state) => ({\n execution: {\n ...state.execution,\n logs: [],\n selectedLogId: null,\n nodeStatuses: {},\n nodeItemCounts: {},\n },\n }));\n },\n completeExecution: () => {\n set((state) => ({\n execution: {\n ...state.execution,\n isExecuting: false,\n executingNodeId: null,\n },\n }));\n },\n },\n },\n}));\n\n// Dev-only debug handle so the store can be inspected/driven from the browser\n// console or automated tests. No-op in production builds.\nif (typeof window !== \"undefined\" && import.meta.env?.DEV) {\n (window as unknown as Record<string, unknown>).__fgFlowStore = useFlowStore;\n}\n"]}
@@ -1,6 +1,6 @@
1
1
  import { getGlobalStoreClient } from './chunk-BQXHJIER.js';
2
2
  import { GetMyNodeInstallationsDocument } from './chunk-PNOA7CQV.js';
3
- import { useFlowStore } from './chunk-KU64CCSV.js';
3
+ import { useFlowStore } from './chunk-WSBRI47P.js';
4
4
  import { SdkPermissionGate, FLUIDGRIDS_PERMISSIONS } from './chunk-UIY2HBWA.js';
5
5
  import { NodeEndpointConfigsDocument, NodeManifestDocument, throwIfResultError, UpdateWorkflowDefinitionDocument, CreateWorkflowDefinitionDocument, CreateWorkflowVersionDocument, TriggerWorkflowDocument, describeOperationError, WorkflowRunDocument } from './chunk-XEYNX7YJ.js';
6
6
  import { waitForFluidGridsClient, getFluidGridsClient } from './chunk-5BDQNSP3.js';
@@ -409,6 +409,7 @@ var NodeCard = React.forwardRef(
409
409
  top: -15,
410
410
  transform: hovered ? "translateY(0)" : "translateY(4px)"
411
411
  },
412
+ onClick: (e) => e.stopPropagation(),
412
413
  onDoubleClick: (e) => e.stopPropagation(),
413
414
  children: [
414
415
  onSettings && /* @__PURE__ */ jsx(ToolbarButton2, { title: "Configure", onClick: onSettings, children: /* @__PURE__ */ jsx(Icon, { icon: "lucide:sliders-horizontal", className: "size-4" }) }),
@@ -617,13 +618,8 @@ function CustomHandle({
617
618
  }
618
619
  ) });
619
620
  }
620
- var TONE_COLORS = {
621
- success: "var(--color-status-success-text)",
622
- error: "var(--color-status-error-text)",
623
- warning: "var(--color-status-warning-text)",
624
- info: "#3b82f6",
625
- neutral: "var(--muted-foreground, #6b7280)"
626
- };
621
+
622
+ // src/builder/components/flow-builder/components/blocks/nodes/node/handle-spec.ts
627
623
  function isDynamicSpec(spec) {
628
624
  return !!spec && !Array.isArray(spec) && typeof spec.fromStateRecord === "string";
629
625
  }
@@ -641,6 +637,98 @@ function resolveOutputHandles(data) {
641
637
  if (spec.length === 0) return DEFAULT_HANDLES;
642
638
  return spec;
643
639
  }
640
+ var DEFAULT_INPUT_HANDLES = [{ id: "target", label: "" }];
641
+ function resolveInputHandles(data) {
642
+ const nodeData = data?.nodeData;
643
+ const spec = nodeData?.inputHandles ?? nodeData?.operations?.inputHandles;
644
+ if (!Array.isArray(spec) || spec.length === 0) return DEFAULT_INPUT_HANDLES;
645
+ return spec;
646
+ }
647
+ function outputHandlesSpacerHeight(count) {
648
+ return count > 2 ? (count - 2) * 26 : 0;
649
+ }
650
+ var TONE_COLORS = {
651
+ success: "var(--color-status-success-text)",
652
+ error: "var(--color-status-error-text)",
653
+ warning: "var(--color-status-warning-text)",
654
+ info: "#3b82f6",
655
+ neutral: "var(--muted-foreground, #6b7280)"
656
+ };
657
+ function HandlePlusStub({
658
+ nodeId,
659
+ handleId,
660
+ color,
661
+ isConnectable,
662
+ isOnlyHandle,
663
+ anchor
664
+ }) {
665
+ const startAttach = useFlowStore((s) => s.actions.pendingConnection.start);
666
+ const isArmedHere = useFlowStore(
667
+ (s) => s.workflow.pendingConnection?.nodeId === nodeId && s.workflow.pendingConnection?.handleId === handleId
668
+ );
669
+ const hasOutgoing = useStore(
670
+ (s) => s.edges.some(
671
+ (e) => e.source === nodeId && (e.sourceHandle === handleId || isOnlyHandle && (e.sourceHandle === null || e.sourceHandle === void 0))
672
+ )
673
+ );
674
+ if (hasOutgoing || isConnectable === false) return null;
675
+ const containerStyle = anchor === "card" ? {
676
+ left: "100%",
677
+ top: "50%",
678
+ transform: "translateY(-50%)",
679
+ marginLeft: 12
680
+ } : { left: 12, top: 0, transform: "translateY(-50%)" };
681
+ return /* @__PURE__ */ jsxs(
682
+ "div",
683
+ {
684
+ className: "nodrag nopan absolute flex items-center",
685
+ style: { ...containerStyle, pointerEvents: "none", zIndex: 5 },
686
+ children: [
687
+ /* @__PURE__ */ jsx(
688
+ "div",
689
+ {
690
+ style: {
691
+ width: 22,
692
+ borderTop: `2px dashed ${color}`,
693
+ opacity: 0.5
694
+ }
695
+ }
696
+ ),
697
+ /* @__PURE__ */ jsx(
698
+ "button",
699
+ {
700
+ type: "button",
701
+ title: "Add next node",
702
+ "aria-label": `Add next node from ${handleId}`,
703
+ "data-testid": `handle-plus-${nodeId}-${handleId}`,
704
+ onClick: (e) => {
705
+ e.stopPropagation();
706
+ startAttach({ nodeId, handleId });
707
+ },
708
+ onDoubleClick: (e) => e.stopPropagation(),
709
+ onMouseDown: (e) => e.stopPropagation(),
710
+ className: "cursor-pointer transition-transform hover:scale-110",
711
+ style: {
712
+ pointerEvents: "all",
713
+ width: 22,
714
+ height: 22,
715
+ borderRadius: "50%",
716
+ display: "flex",
717
+ alignItems: "center",
718
+ justifyContent: "center",
719
+ border: `2px solid ${color}`,
720
+ background: isArmedHere ? color : "var(--card, #fff)",
721
+ color: isArmedHere ? "var(--card, #fff)" : color,
722
+ boxShadow: isArmedHere ? `0 0 0 4px color-mix(in srgb, ${color} 22%, transparent)` : `0 0 0 3px color-mix(in srgb, ${color} 10%, transparent)`,
723
+ transition: "transform .12s ease, background .12s ease, color .12s ease"
724
+ },
725
+ children: /* @__PURE__ */ jsx(Icon, { icon: "mdi:plus", className: "size-3.5" })
726
+ }
727
+ )
728
+ ]
729
+ }
730
+ );
731
+ }
644
732
  function OutputHandles({
645
733
  nodeId,
646
734
  handles,
@@ -657,16 +745,30 @@ function OutputHandles({
657
745
  }, [nodeId, signature, updateNodeInternals]);
658
746
  if (handles.length === 1) {
659
747
  const handle = handles[0];
660
- return /* @__PURE__ */ jsx(
661
- CustomHandle,
662
- {
663
- type: "source",
664
- id: handle.id,
665
- position: Position.Right,
666
- isConnectable,
667
- accent: handle.tone ? TONE_COLORS[handle.tone] : accent
668
- }
669
- );
748
+ const color = handle.tone ? TONE_COLORS[handle.tone] : accent;
749
+ return /* @__PURE__ */ jsxs(Fragment, { children: [
750
+ /* @__PURE__ */ jsx(
751
+ CustomHandle,
752
+ {
753
+ type: "source",
754
+ id: handle.id,
755
+ position: Position.Right,
756
+ isConnectable,
757
+ accent: color
758
+ }
759
+ ),
760
+ /* @__PURE__ */ jsx(
761
+ HandlePlusStub,
762
+ {
763
+ nodeId,
764
+ handleId: handle.id,
765
+ color,
766
+ isConnectable,
767
+ isOnlyHandle: true,
768
+ anchor: "card"
769
+ }
770
+ )
771
+ ] });
670
772
  }
671
773
  const total = handles.length;
672
774
  return /* @__PURE__ */ jsx(Fragment, { children: handles.map((handle, index) => {
@@ -692,16 +794,21 @@ function OutputHandles({
692
794
  "span",
693
795
  {
694
796
  className: "pointer-events-none absolute whitespace-nowrap text-[10px] font-medium leading-none",
695
- style: {
696
- color,
697
- left: "100%",
698
- marginLeft: 16,
699
- top: "50%",
700
- transform: "translateY(-50%)"
701
- },
797
+ style: { color, left: 12, bottom: 8 },
702
798
  title: handle.label,
703
799
  children: handle.label
704
800
  }
801
+ ),
802
+ /* @__PURE__ */ jsx(
803
+ HandlePlusStub,
804
+ {
805
+ nodeId,
806
+ handleId: handle.id,
807
+ color,
808
+ isConnectable,
809
+ isOnlyHandle: false,
810
+ anchor: "point"
811
+ }
705
812
  )
706
813
  ]
707
814
  },
@@ -709,13 +816,6 @@ function OutputHandles({
709
816
  );
710
817
  }) });
711
818
  }
712
- var DEFAULT_INPUT_HANDLES = [{ id: "target", label: "" }];
713
- function resolveInputHandles(data) {
714
- const nodeData = data?.nodeData;
715
- const spec = nodeData?.inputHandles ?? nodeData?.operations?.inputHandles;
716
- if (!Array.isArray(spec) || spec.length === 0) return DEFAULT_INPUT_HANDLES;
717
- return spec;
718
- }
719
819
  function InputHandles({
720
820
  nodeId,
721
821
  handles,
@@ -784,9 +884,6 @@ function InputHandles({
784
884
  );
785
885
  }) });
786
886
  }
787
- function outputHandlesSpacerHeight(count) {
788
- return count > 2 ? (count - 2) * 26 : 0;
789
- }
790
887
  function LogicNodeCard({
791
888
  title,
792
889
  subtitle,
@@ -801,6 +898,7 @@ function LogicNodeCard({
801
898
  inputHandles,
802
899
  outputHandles,
803
900
  isConnectable,
901
+ onClick,
804
902
  onDoubleClick,
805
903
  onSettings,
806
904
  onExecute,
@@ -817,6 +915,7 @@ function LogicNodeCard({
817
915
  className: "w-48",
818
916
  "data-selected": selected,
819
917
  selected,
918
+ onClick,
820
919
  onDoubleClick,
821
920
  executionStatus,
822
921
  itemCount,
@@ -10187,9 +10286,10 @@ function SubNodeComponent({
10187
10286
  ] })
10188
10287
  );
10189
10288
  }
10289
+ var SINGLE_CLICK_DELAY_MS = 230;
10190
10290
  var getNodeMetadata = (value) => {
10191
10291
  function NodeComponent(props) {
10192
- const { id, isConnectable, selected, data } = props;
10292
+ const { id, isConnectable, selected, data, dragging } = props;
10193
10293
  const { edges, nodeLookup } = useStore(({ edges: edges2, nodeLookup: nodeLookup2 }) => ({
10194
10294
  edges: edges2,
10195
10295
  nodeLookup: nodeLookup2
@@ -10252,7 +10352,46 @@ var getNodeMetadata = (value) => {
10252
10352
  deleteNode(id);
10253
10353
  };
10254
10354
  const openNdv = useFlowStore((s) => s.actions.ndv.open);
10355
+ const openQuickConfig = useFlowStore((s) => s.actions.quickConfig.open);
10356
+ const { getNode, flowToScreenPosition } = useReactFlow();
10357
+ const clickTimerRef = useRef(null);
10358
+ const wasDraggedRef = useRef(false);
10359
+ useEffect(() => {
10360
+ if (dragging) wasDraggedRef.current = true;
10361
+ }, [dragging]);
10362
+ useEffect(
10363
+ () => () => {
10364
+ if (clickTimerRef.current !== null)
10365
+ window.clearTimeout(clickTimerRef.current);
10366
+ },
10367
+ []
10368
+ );
10369
+ const handleCardClick = useCallback(() => {
10370
+ if (wasDraggedRef.current) {
10371
+ wasDraggedRef.current = false;
10372
+ return;
10373
+ }
10374
+ if (clickTimerRef.current !== null)
10375
+ window.clearTimeout(clickTimerRef.current);
10376
+ clickTimerRef.current = window.setTimeout(() => {
10377
+ clickTimerRef.current = null;
10378
+ const current = getNode(id);
10379
+ const anchor = current ? flowToScreenPosition({
10380
+ x: current.position.x + (current.measured?.width ?? 288) + 24,
10381
+ y: current.position.y
10382
+ }) : void 0;
10383
+ openQuickConfig({
10384
+ nodeId: id,
10385
+ type: value?.type,
10386
+ anchor
10387
+ });
10388
+ }, SINGLE_CLICK_DELAY_MS);
10389
+ }, [getNode, flowToScreenPosition, id, openQuickConfig]);
10255
10390
  const handleOpenNdv = useCallback(() => {
10391
+ if (clickTimerRef.current !== null) {
10392
+ window.clearTimeout(clickTimerRef.current);
10393
+ clickTimerRef.current = null;
10394
+ }
10256
10395
  openNdv({ nodeId: id, type: value?.type });
10257
10396
  }, [id, openNdv]);
10258
10397
  const handleExecuteStep = useCallback(() => {
@@ -10327,6 +10466,7 @@ var getNodeMetadata = (value) => {
10327
10466
  inputHandles,
10328
10467
  outputHandles,
10329
10468
  isConnectable: typeof isConnectable === "boolean" ? isConnectable : void 0,
10469
+ onClick: handleCardClick,
10330
10470
  onDoubleClick: handleOpenNdv,
10331
10471
  onSettings: handleOpenNdv,
10332
10472
  onExecute: handleExecuteStep,
@@ -10349,6 +10489,7 @@ var getNodeMetadata = (value) => {
10349
10489
  {
10350
10490
  "data-selected": selected,
10351
10491
  selected,
10492
+ onClick: handleCardClick,
10352
10493
  onDoubleClick: handleOpenNdv,
10353
10494
  executionStatus,
10354
10495
  itemCount,
@@ -10722,6 +10863,6 @@ function registerWorkflowNodeTypes(workflowNodes) {
10722
10863
  }
10723
10864
  }
10724
10865
 
10725
- export { AVAILABLE_NODES, ConfigSchemaForm, ConnectionFormDialog, ConnectionSelector, NODES, NODES_METADATA, NODE_CONFIGS, NODE_OPERATION_DRAG_DATA_FORMAT, NODE_TYPES, NODE_TYPE_DRAG_DATA_FORMAT, NodePropertyPanel, ProviderPicker, STICKY_NOTE_TYPE, buildStickyNode, ensureNodeConfigsLoaded, fetchNodeManifest, getNodeDetail, getNodeMetadata, getProviderForm, isNodeConfigsInitialized, listCustomBlocks, mergeStickyNotes, onNodeTypesUpdate, refetchStoreNodes, registerCustomBlock, registerWorkflowNodeTypes, resolveUiSpec, stripSubmitActions, useConnection, useConnectionDialog, useConnections, useConnectionsByProvider, useCreateConnection, useInitiateOAuth, useInsertNode, useNodeExecution, useProviderByKey, useProviderCatalog, useProviders, useSaveWorkflow };
10726
- //# sourceMappingURL=chunk-IVKT244I.js.map
10727
- //# sourceMappingURL=chunk-IVKT244I.js.map
10866
+ export { AVAILABLE_NODES, ConfigSchemaForm, ConnectionFormDialog, ConnectionSelector, NODES, NODES_METADATA, NODE_CONFIGS, NODE_OPERATION_DRAG_DATA_FORMAT, NODE_TYPES, NODE_TYPE_DRAG_DATA_FORMAT, NodePropertyPanel, ProviderPicker, STICKY_NOTE_TYPE, buildStickyNode, ensureNodeConfigsLoaded, fetchNodeManifest, getNodeDetail, getNodeMetadata, getProviderForm, isNodeConfigsInitialized, listCustomBlocks, mergeStickyNotes, nodeAccent, onNodeTypesUpdate, refetchStoreNodes, registerCustomBlock, registerWorkflowNodeTypes, resolveInputHandles, resolveUiSpec, stripSubmitActions, useConnection, useConnectionDialog, useConnections, useConnectionsByProvider, useCreateConnection, useInitiateOAuth, useInsertNode, useNodeExecution, useProviderByKey, useProviderCatalog, useProviders, useSaveWorkflow };
10867
+ //# sourceMappingURL=chunk-XBMHUJYN.js.map
10868
+ //# sourceMappingURL=chunk-XBMHUJYN.js.map