@datatechsolutions/ui 2.11.19 → 2.11.21

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.
@@ -1,8 +1,8 @@
1
1
  "use client";
2
- import { GlassModalShell, ContextMenu, FormInput, FormSelect, FormTextarea, Button, IconButton } from './chunk-46ZM5VJJ.mjs';
2
+ import { GlassModalShell, ContextMenu, FormInput, FormSelect, FormTextarea, Button, IconButton } from './chunk-XKLU32S3.mjs';
3
+ import { useTranslations, I18nProvider, createI18nFromMessages } from './chunk-7VJ7CMMT.mjs';
3
4
  import { GraphNodeHeader, GraphNodeMeta, GraphNodeBadge, GraphNodeIconBubble } from './chunk-OZNTQROP.mjs';
4
5
  import { getAgentTier, createDefaultLogicNodeConfig, applyDagreLayout } from './chunk-TLPPVL3W.mjs';
5
- import { useTranslations, I18nProvider, createI18nFromMessages } from './chunk-7VJ7CMMT.mjs';
6
6
  import { memo, useState, useRef, useCallback, useEffect, lazy, createContext, useMemo, useContext } from 'react';
7
7
  import { Position, NodeResizer, MarkerType, useReactFlow, getBezierPath, BaseEdge, EdgeLabelRenderer, Handle, ReactFlowProvider, useNodesState, useEdgesState, addEdge, BackgroundVariant } from '@xyflow/react';
8
8
  import '@xyflow/react/dist/style.css';
@@ -470,6 +470,24 @@ var MINIMAP_NODE_COLORS = {
470
470
  model_provider: "#64748b",
471
471
  group: "#64748b"
472
472
  };
473
+ var NODE_EXECUTION_ACCENT_COLORS = {
474
+ ...MINIMAP_NODE_COLORS
475
+ };
476
+ function hexToRgb(hexColor) {
477
+ const normalizedHex = hexColor.replace("#", "");
478
+ const parsed = Number.parseInt(normalizedHex, 16);
479
+ if (Number.isNaN(parsed) || normalizedHex.length !== 6) {
480
+ return [99, 102, 241];
481
+ }
482
+ return [parsed >> 16 & 255, parsed >> 8 & 255, parsed & 255];
483
+ }
484
+ function getNodeExecutionAccent(nodeType) {
485
+ return NODE_EXECUTION_ACCENT_COLORS[nodeType ?? ""] ?? NODE_EXECUTION_ACCENT_COLORS.agent;
486
+ }
487
+ function getNodeExecutionAccentRgb(nodeType) {
488
+ const [red, green, blue] = hexToRgb(getNodeExecutionAccent(nodeType));
489
+ return `${red}, ${green}, ${blue}`;
490
+ }
473
491
  var LOGIC_NODE_HANDLE_COLORS = {
474
492
  start: "!bg-green-500",
475
493
  end: "!bg-red-500",
@@ -1172,6 +1190,35 @@ function isModelCompatibleWithFramework(modelId, framework) {
1172
1190
  const provider = modelId.split(".")[0];
1173
1191
  return allowed.includes(provider);
1174
1192
  }
1193
+ var PROVIDER_TYPE_TO_MODEL_PROVIDERS = {
1194
+ aws_bedrock: ["anthropic", "amazon", "meta", "mistral"],
1195
+ openai_api: ["openai"],
1196
+ google_vertex: ["google"],
1197
+ azure_openai: ["openai"],
1198
+ anthropic_api: ["anthropic"],
1199
+ groq: ["meta", "mistral"],
1200
+ mistral: ["mistral"],
1201
+ huggingface: ["meta", "mistral"],
1202
+ ollama: ["meta", "mistral"],
1203
+ // Also handle raw provider names (from ModelProvider.provider field)
1204
+ anthropic: ["anthropic"],
1205
+ amazon: ["anthropic", "amazon", "meta"],
1206
+ google: ["google"],
1207
+ openai: ["openai"],
1208
+ meta: ["meta"]
1209
+ };
1210
+ function isFrameworkCompatibleWithProviders(framework, providerTypes) {
1211
+ const allowed = FRAMEWORK_ALLOWED_PROVIDERS[framework];
1212
+ if (!allowed || allowed === "all") return true;
1213
+ const availableModelProviders = /* @__PURE__ */ new Set();
1214
+ for (const providerType of providerTypes) {
1215
+ const mapped = PROVIDER_TYPE_TO_MODEL_PROVIDERS[providerType];
1216
+ if (mapped) {
1217
+ for (const mp of mapped) availableModelProviders.add(mp);
1218
+ }
1219
+ }
1220
+ return allowed.some((allowedProvider) => availableModelProviders.has(allowedProvider));
1221
+ }
1175
1222
  function getCompatibleModels(models, framework) {
1176
1223
  const allowed = FRAMEWORK_ALLOWED_PROVIDERS[framework];
1177
1224
  if (!allowed || allowed === "all") return models;
@@ -1215,6 +1262,7 @@ function NodeCard({
1215
1262
  return /* @__PURE__ */ jsx(
1216
1263
  "div",
1217
1264
  {
1265
+ "data-workflow-node-type": nodeType,
1218
1266
  className: `group relative ${width} rounded-xl border liquid-surface ${compact ? "min-h-[84px] p-3" : "p-4"} transition-all ${getNodeStateClass(selected, nodeType, customBorder)}${className ? ` ${className}` : ""}`,
1219
1267
  style,
1220
1268
  role,
@@ -1355,17 +1403,48 @@ function WorkflowDynamicHandles({
1355
1403
  }
1356
1404
  function NodeRunningIndicatorComponent({ nodeId }) {
1357
1405
  const nodeResult = useWorkflowStore((state) => state.nodeResults[nodeId]);
1406
+ const containerRef = useRef(null);
1407
+ const [nodeType, setNodeType] = useState("agent");
1408
+ const accentColor = useMemo(() => getNodeExecutionAccent(nodeType), [nodeType]);
1409
+ const accentRgb = useMemo(() => getNodeExecutionAccentRgb(nodeType), [nodeType]);
1410
+ useEffect(() => {
1411
+ const indicatorElement = containerRef.current;
1412
+ if (!indicatorElement) return;
1413
+ const nodeWrapper = indicatorElement.closest(".react-flow__node");
1414
+ if (!nodeWrapper) return;
1415
+ const wrapperClass = Array.from(nodeWrapper.classList).find(
1416
+ (className) => className.startsWith("react-flow__node-") && className !== "react-flow__node"
1417
+ );
1418
+ if (!wrapperClass) return;
1419
+ setNodeType(wrapperClass.replace("react-flow__node-", ""));
1420
+ }, []);
1358
1421
  if (!nodeResult) return null;
1359
1422
  const { status, durationMs } = nodeResult;
1360
- return /* @__PURE__ */ jsxs("div", { className: "absolute -right-1 -top-1 z-10 flex items-center gap-1", children: [
1423
+ return /* @__PURE__ */ jsxs("div", { ref: containerRef, className: "absolute -right-1 -top-1 z-10 flex items-center gap-1", children: [
1361
1424
  status === "pending" && /* @__PURE__ */ jsx("span", { className: "flex h-5 w-5 items-center justify-center rounded-full border border-gray-300 bg-white shadow-sm dark:border-gray-600 dark:bg-gray-800", children: /* @__PURE__ */ jsx("span", { className: "h-2 w-2 rounded-full bg-gray-400 dark:bg-gray-500" }) }),
1362
- status === "running" && /* @__PURE__ */ jsx("span", { className: "flex h-5 w-5 items-center justify-center rounded-full border border-blue-300 bg-white shadow-sm dark:border-blue-600 dark:bg-gray-800", children: /* @__PURE__ */ jsxs("svg", { className: "h-3 w-3 animate-spin text-blue-500", viewBox: "0 0 24 24", fill: "none", children: [
1363
- /* @__PURE__ */ jsx("circle", { className: "opacity-25", cx: "12", cy: "12", r: "10", stroke: "currentColor", strokeWidth: "4" }),
1364
- /* @__PURE__ */ jsx("path", { className: "opacity-75", fill: "currentColor", d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z" })
1365
- ] }) }),
1366
- status === "success" && /* @__PURE__ */ jsx("span", { className: "flex h-5 w-5 items-center justify-center rounded-full border border-green-300 bg-green-50 shadow-sm dark:border-green-600 dark:bg-green-900/30", children: /* @__PURE__ */ jsx("svg", { className: "h-3 w-3 text-green-600 dark:text-green-400", viewBox: "0 0 20 20", fill: "currentColor", children: /* @__PURE__ */ jsx("path", { fillRule: "evenodd", d: "M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z", clipRule: "evenodd" }) }) }),
1425
+ status === "running" && /* @__PURE__ */ jsx(
1426
+ "span",
1427
+ {
1428
+ className: "flex h-5 w-5 items-center justify-center rounded-full border bg-white shadow-sm dark:bg-gray-800",
1429
+ style: {
1430
+ borderColor: `rgba(${accentRgb}, 0.55)`,
1431
+ boxShadow: `0 0 0 1px rgba(${accentRgb}, 0.16), 0 6px 16px rgba(${accentRgb}, 0.18)`
1432
+ },
1433
+ children: /* @__PURE__ */ jsxs("svg", { className: "h-3 w-3 animate-spin", style: { color: accentColor }, viewBox: "0 0 24 24", fill: "none", children: [
1434
+ /* @__PURE__ */ jsx("circle", { className: "opacity-25", cx: "12", cy: "12", r: "10", stroke: "currentColor", strokeWidth: "4" }),
1435
+ /* @__PURE__ */ jsx("path", { className: "opacity-75", fill: "currentColor", d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z" })
1436
+ ] })
1437
+ }
1438
+ ),
1439
+ status === "success" && /* @__PURE__ */ jsx("span", { className: "flex h-5 w-5 items-center justify-center rounded-full border border-emerald-300 bg-emerald-50 shadow-sm dark:border-emerald-600 dark:bg-emerald-900/30", children: /* @__PURE__ */ jsx("svg", { className: "h-3 w-3 text-emerald-600 dark:text-emerald-400", viewBox: "0 0 20 20", fill: "currentColor", children: /* @__PURE__ */ jsx("path", { fillRule: "evenodd", d: "M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z", clipRule: "evenodd" }) }) }),
1367
1440
  status === "error" && /* @__PURE__ */ jsx("span", { className: "flex h-5 w-5 items-center justify-center rounded-full border border-red-300 bg-red-50 shadow-sm dark:border-red-600 dark:bg-red-900/30", children: /* @__PURE__ */ jsx("svg", { className: "h-3 w-3 text-red-600 dark:text-red-400", viewBox: "0 0 20 20", fill: "currentColor", children: /* @__PURE__ */ jsx("path", { fillRule: "evenodd", d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z", clipRule: "evenodd" }) }) }),
1368
- (status === "success" || status === "error") && durationMs !== void 0 && /* @__PURE__ */ jsx("span", { className: "rounded-full bg-gray-100 px-1.5 py-0.5 text-[9px] font-medium text-gray-500 shadow-sm dark:bg-gray-800 dark:text-gray-400", children: durationMs < 1e3 ? `${durationMs}ms` : `${(durationMs / 1e3).toFixed(1)}s` })
1441
+ (status === "success" || status === "error") && durationMs !== void 0 && /* @__PURE__ */ jsx(
1442
+ "span",
1443
+ {
1444
+ className: `rounded-full px-1.5 py-0.5 text-[9px] font-medium shadow-sm ${status === "success" ? "bg-emerald-50 text-emerald-700 dark:bg-emerald-900/20 dark:text-emerald-300" : "bg-gray-100 text-gray-500 dark:bg-gray-800 dark:text-gray-400"}`,
1445
+ children: durationMs < 1e3 ? `${durationMs}ms` : `${(durationMs / 1e3).toFixed(1)}s`
1446
+ }
1447
+ )
1369
1448
  ] });
1370
1449
  }
1371
1450
  var NodeRunningIndicator = memo(NodeRunningIndicatorComponent);
@@ -2690,7 +2769,7 @@ var NoteFlowNode = memo(function NoteFlowNode2({ data, selected }) {
2690
2769
  });
2691
2770
  var DatasourceFlowNode = memo(function DatasourceFlowNode2({ id, data, selected }) {
2692
2771
  const t = useTranslations("agents.workflow");
2693
- const { config, label, onEdit, onRemoveFromCanvas } = data;
2772
+ const { config, label, datasource, readOnly = false, onEdit, onRemoveFromCanvas } = data;
2694
2773
  const isCompact = data.displayMode === "compact";
2695
2774
  if (!config || config.type !== "datasource") {
2696
2775
  return /* @__PURE__ */ jsxs(Fragment, { children: [
@@ -2710,56 +2789,92 @@ var DatasourceFlowNode = memo(function DatasourceFlowNode2({ id, data, selected
2710
2789
  }
2711
2790
  const columnCount = config.selectedColumns?.length ?? 0;
2712
2791
  const filterCount = config.filterVariables ? Object.keys(config.filterVariables).length : 0;
2792
+ const visibleColumns = config.selectedColumns.slice(0, 3);
2793
+ const filterEntries = Object.entries(config.filterVariables ?? {});
2794
+ const content = /* @__PURE__ */ jsxs(NodeCard, { compact: isCompact, selected, nodeType: "datasource", children: [
2795
+ /* @__PURE__ */ jsxs("div", { className: "flex items-start gap-3", children: [
2796
+ /* @__PURE__ */ jsx("div", { className: "flex h-10 w-10 items-center justify-center rounded-xl bg-gradient-to-br from-cyan-500 to-blue-600 shadow-lg", children: /* @__PURE__ */ jsx(ServerStackIcon, { className: "h-5 w-5 text-white" }) }),
2797
+ /* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1", children: [
2798
+ /* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 dark:text-white", children: label }),
2799
+ !isCompact && /* @__PURE__ */ jsxs("p", { className: "mt-0.5 text-xs text-gray-500 dark:text-gray-400", children: [
2800
+ datasource?.name ?? config.datasourceId,
2801
+ " \xB7 ",
2802
+ config.table
2803
+ ] })
2804
+ ] })
2805
+ ] }),
2806
+ /* @__PURE__ */ jsxs(NodeCardMeta, { compact: isCompact, children: [
2807
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [
2808
+ config.dialect && /* @__PURE__ */ jsx(NodeCardBadge, { className: "inline-flex items-center rounded-full px-2 py-0.5 text-[10px] font-semibold bg-cyan-100 text-cyan-700 dark:bg-cyan-900/30 dark:text-cyan-300", children: config.dialect }),
2809
+ readOnly && /* @__PURE__ */ jsx(NodeCardBadge, { className: "inline-flex items-center rounded-full px-2 py-0.5 text-[10px] font-medium bg-slate-100 text-slate-700 dark:bg-slate-500/20 dark:text-slate-300", children: "Sample Data" }),
2810
+ /* @__PURE__ */ jsx(NodeCardBadge, { className: "inline-flex items-center rounded-full px-2 py-0.5 text-[10px] font-medium bg-cyan-100 text-cyan-700 dark:bg-cyan-900/30 dark:text-cyan-300", children: config.table }),
2811
+ /* @__PURE__ */ jsx(NodeCardBadge, { className: "inline-flex items-center rounded-full px-2 py-0.5 text-[10px] font-medium bg-blue-50 text-blue-700 dark:bg-blue-900/25 dark:text-blue-300", children: config.outputVariable }),
2812
+ columnCount > 0 && /* @__PURE__ */ jsxs("span", { className: "text-[10px] text-gray-400 dark:text-gray-500", children: [
2813
+ columnCount,
2814
+ " ",
2815
+ t("datasourceColumns")
2816
+ ] }),
2817
+ config.limit > 0 && /* @__PURE__ */ jsx("span", { className: "text-[10px] text-gray-400 dark:text-gray-500", children: t("datasourceLimit", { count: config.limit }) }),
2818
+ filterCount > 0 && /* @__PURE__ */ jsxs("span", { className: "text-[10px] text-gray-400 dark:text-gray-500", children: [
2819
+ filterCount,
2820
+ " ",
2821
+ t("datasourceFilters")
2822
+ ] })
2823
+ ] }),
2824
+ !isCompact && /* @__PURE__ */ jsxs("div", { className: "mt-2 flex flex-wrap items-center gap-1.5", children: [
2825
+ visibleColumns.map((column) => /* @__PURE__ */ jsx(
2826
+ NodeCardBadge,
2827
+ {
2828
+ className: "inline-flex items-center rounded-full px-2 py-0.5 text-[10px] font-medium bg-white/70 text-slate-600 dark:bg-white/5 dark:text-slate-300",
2829
+ children: column
2830
+ },
2831
+ column
2832
+ )),
2833
+ columnCount > visibleColumns.length && /* @__PURE__ */ jsxs("span", { className: "text-[10px] text-gray-400 dark:text-gray-500", children: [
2834
+ "+",
2835
+ columnCount - visibleColumns.length,
2836
+ " more"
2837
+ ] })
2838
+ ] }),
2839
+ !isCompact && filterEntries.length > 0 && /* @__PURE__ */ jsx("div", { className: "mt-2 flex flex-wrap items-center gap-1.5", children: filterEntries.map(([field, variableName]) => /* @__PURE__ */ jsxs(
2840
+ NodeCardBadge,
2841
+ {
2842
+ className: "inline-flex items-center rounded-full px-2 py-0.5 text-[10px] font-medium bg-cyan-50 text-cyan-700 dark:bg-cyan-900/20 dark:text-cyan-300",
2843
+ children: [
2844
+ field,
2845
+ " \u2192 ",
2846
+ variableName
2847
+ ]
2848
+ },
2849
+ `${field}:${variableName}`
2850
+ )) }),
2851
+ onRemoveFromCanvas && /* @__PURE__ */ jsx(
2852
+ "span",
2853
+ {
2854
+ role: "button",
2855
+ tabIndex: 0,
2856
+ onClick: (event) => {
2857
+ event.stopPropagation();
2858
+ event.preventDefault();
2859
+ onRemoveFromCanvas(id);
2860
+ },
2861
+ className: "nodrag nopan cursor-pointer rounded-lg p-1 opacity-0 transition hover:bg-red-50 group-hover:opacity-100 dark:hover:bg-red-900/20",
2862
+ "aria-label": t("removeFromCanvas"),
2863
+ children: /* @__PURE__ */ jsx(TrashIcon, { className: "h-3.5 w-3.5 text-red-600 dark:text-red-400" })
2864
+ }
2865
+ )
2866
+ ] })
2867
+ ] });
2713
2868
  return /* @__PURE__ */ jsxs(Fragment, { children: [
2714
2869
  /* @__PURE__ */ jsx(NodeRunningIndicator, { nodeId: id }),
2715
2870
  /* @__PURE__ */ jsx(WorkflowHandle, { type: "target", position: Position.Left, id: "left-in", colorClass: "!bg-cyan-400" }),
2716
- /* @__PURE__ */ jsx(
2871
+ readOnly || !onEdit ? /* @__PURE__ */ jsx("div", { className: "w-full", children: content }) : /* @__PURE__ */ jsx(
2717
2872
  "button",
2718
2873
  {
2719
2874
  type: "button",
2720
- onClick: () => onEdit?.(id),
2875
+ onClick: () => onEdit(id),
2721
2876
  className: "w-full text-left",
2722
- children: /* @__PURE__ */ jsxs(NodeCard, { compact: isCompact, selected, nodeType: "datasource", children: [
2723
- /* @__PURE__ */ jsxs("div", { className: "flex items-start gap-3", children: [
2724
- /* @__PURE__ */ jsx("div", { className: "flex h-10 w-10 items-center justify-center rounded-xl bg-gradient-to-br from-cyan-500 to-blue-600 shadow-lg", children: /* @__PURE__ */ jsx(ServerStackIcon, { className: "h-5 w-5 text-white" }) }),
2725
- /* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1", children: [
2726
- /* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 dark:text-white", children: label }),
2727
- !isCompact && /* @__PURE__ */ jsx("p", { className: "mt-0.5 text-xs text-gray-500 dark:text-gray-400", children: config.table ?? config.datasourceId })
2728
- ] })
2729
- ] }),
2730
- /* @__PURE__ */ jsxs(NodeCardMeta, { compact: isCompact, children: [
2731
- /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
2732
- config.dialect && /* @__PURE__ */ jsx(NodeCardBadge, { className: "inline-flex items-center rounded-full px-2 py-0.5 text-[10px] font-semibold bg-cyan-100 text-cyan-700 dark:bg-cyan-900/30 dark:text-cyan-300", children: config.dialect }),
2733
- config.table && /* @__PURE__ */ jsx(NodeCardBadge, { className: "inline-flex items-center rounded-full px-2 py-0.5 text-[10px] font-medium bg-cyan-100 text-cyan-700 dark:bg-cyan-900/30 dark:text-cyan-300", children: config.table }),
2734
- columnCount > 0 && /* @__PURE__ */ jsxs("span", { className: "text-[10px] text-gray-400 dark:text-gray-500", children: [
2735
- columnCount,
2736
- " ",
2737
- t("datasourceColumns")
2738
- ] }),
2739
- config.limit > 0 && /* @__PURE__ */ jsx("span", { className: "text-[10px] text-gray-400 dark:text-gray-500", children: t("datasourceLimit", { count: config.limit }) }),
2740
- filterCount > 0 && /* @__PURE__ */ jsxs("span", { className: "text-[10px] text-gray-400 dark:text-gray-500", children: [
2741
- filterCount,
2742
- " ",
2743
- t("datasourceFilters")
2744
- ] })
2745
- ] }),
2746
- onRemoveFromCanvas && /* @__PURE__ */ jsx(
2747
- "span",
2748
- {
2749
- role: "button",
2750
- tabIndex: 0,
2751
- onClick: (event) => {
2752
- event.stopPropagation();
2753
- event.preventDefault();
2754
- onRemoveFromCanvas(id);
2755
- },
2756
- className: "nodrag nopan cursor-pointer rounded-lg p-1 opacity-0 transition hover:bg-red-50 group-hover:opacity-100 dark:hover:bg-red-900/20",
2757
- "aria-label": t("removeFromCanvas"),
2758
- children: /* @__PURE__ */ jsx(TrashIcon, { className: "h-3.5 w-3.5 text-red-600 dark:text-red-400" })
2759
- }
2760
- )
2761
- ] })
2762
- ] })
2877
+ children: content
2763
2878
  }
2764
2879
  ),
2765
2880
  /* @__PURE__ */ jsx(WorkflowHandle, { type: "source", position: Position.Right, id: "right-out", colorClass: "!bg-cyan-400" })
@@ -6032,6 +6147,28 @@ function WorkflowCanvasInner({
6032
6147
  }
6033
6148
  };
6034
6149
  }
6150
+ if (savedNode.type === "datasource") {
6151
+ const datasourceConfig = savedNode.data.config;
6152
+ const datasourceEntity = datasourceConfig ? entityMap.get(datasourceConfig.datasourceId) : void 0;
6153
+ const extendedNodeData = savedNode.data;
6154
+ return {
6155
+ id: savedNode.id,
6156
+ type: "datasource",
6157
+ position: savedNode.position,
6158
+ data: {
6159
+ config: datasourceConfig,
6160
+ datasource: datasourceEntity ? {
6161
+ id: datasourceEntity.id,
6162
+ name: datasourceEntity.label,
6163
+ dialect: datasourceConfig?.dialect ?? "unknown"
6164
+ } : void 0,
6165
+ label: savedNode.data.label,
6166
+ readOnly: extendedNodeData.readOnly === true,
6167
+ onEdit: extendedNodeData.readOnly === true ? void 0 : handleEditLogicNode,
6168
+ onRemoveFromCanvas: handleRemoveNodeFromCanvas
6169
+ }
6170
+ };
6171
+ }
6035
6172
  if (savedNode.type === "group") {
6036
6173
  const groupConfig = savedNode.data.config;
6037
6174
  const defaultGroupConfig = {
@@ -7411,6 +7548,6 @@ function Workspace({
7411
7548
  ) }) });
7412
7549
  }
7413
7550
 
7414
- export { AgentFlowNode, AgentToolFlowNode, AnswerFlowNode, AnthropicIcon, CATEGORY_COLORS, CATEGORY_PILL_COLORS, CodeFlowNode, CrewAIIcon, DocumentExtractorFlowNode, EndFlowNode, EntityFlowNode, FRAMEWORK_META, GoogleADKIcon, GroupFlowNode, HttpRequestFlowNode, ICON_MAP, IfElseFlowNode, IterationFlowNode, IterationStartFlowNode, KnowledgeBaseFlowNode, LOGIC_ICON_MAP, LOGIC_NODE_BADGE_COLORS, LOGIC_NODE_GRADIENTS, LOGIC_NODE_HANDLE_COLORS, LangChainIcon, ListOperatorFlowNode, LogicNodeModal, MINIMAP_NODE_COLORS, ModelProviderFlowNode, NodeCard, NodeContextMenu, NoteFlowNode, OpenAIIcon, PanelContextMenu, ParameterExtractorFlowNode, QuestionClassifierFlowNode, RuleFlowNode, SelectionContextMenu, StartFlowNode, StrandsIcon, TemplateTransformFlowNode, ToolFlowNode, VariableAggregatorFlowNode, VariableAssignerFlowNode, WorkflowBuilderProvider, WorkflowCanvas, Workspace, getCompatibleModels, getDefaultFrameworkForModel, getEntityBadgeColor, getEntityGradient, getEntityHandleColor, getEntityIcon, getEntityMinimapColor, getFrameworkMeta, isModelCompatibleWithFramework, useModalStore, useWorkflowBuilderClient, useWorkflowBuilderClientOptional, useWorkflowStore };
7415
- //# sourceMappingURL=chunk-LIYKHVLG.mjs.map
7416
- //# sourceMappingURL=chunk-LIYKHVLG.mjs.map
7551
+ export { AgentFlowNode, AgentToolFlowNode, AnswerFlowNode, AnthropicIcon, CATEGORY_COLORS, CATEGORY_PILL_COLORS, CodeFlowNode, CrewAIIcon, DocumentExtractorFlowNode, EndFlowNode, EntityFlowNode, FRAMEWORK_META, GoogleADKIcon, GroupFlowNode, HttpRequestFlowNode, ICON_MAP, IfElseFlowNode, IterationFlowNode, IterationStartFlowNode, KnowledgeBaseFlowNode, LOGIC_ICON_MAP, LOGIC_NODE_BADGE_COLORS, LOGIC_NODE_GRADIENTS, LOGIC_NODE_HANDLE_COLORS, LangChainIcon, ListOperatorFlowNode, LogicNodeModal, MINIMAP_NODE_COLORS, ModelProviderFlowNode, NODE_EXECUTION_ACCENT_COLORS, NodeCard, NodeContextMenu, NoteFlowNode, OpenAIIcon, PanelContextMenu, ParameterExtractorFlowNode, QuestionClassifierFlowNode, RuleFlowNode, SelectionContextMenu, StartFlowNode, StrandsIcon, TemplateTransformFlowNode, ToolFlowNode, VariableAggregatorFlowNode, VariableAssignerFlowNode, WorkflowBuilderProvider, WorkflowCanvas, Workspace, getCompatibleModels, getDefaultFrameworkForModel, getEntityBadgeColor, getEntityGradient, getEntityHandleColor, getEntityIcon, getEntityMinimapColor, getFrameworkMeta, getNodeExecutionAccent, getNodeExecutionAccentRgb, isFrameworkCompatibleWithProviders, isModelCompatibleWithFramework, useModalStore, useWorkflowBuilderClient, useWorkflowBuilderClientOptional, useWorkflowStore };
7552
+ //# sourceMappingURL=chunk-Z3U6JAA7.mjs.map
7553
+ //# sourceMappingURL=chunk-Z3U6JAA7.mjs.map