@datatechsolutions/ui 2.11.4 → 2.11.6

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,9 +1,9 @@
1
1
  "use client";
2
2
  import '../chunk-JB6RNAD2.mjs';
3
3
  export { topologicalSortAgents, validateWorkflowGraph } from '../chunk-BLNXRUC4.mjs';
4
- import { Workspace, useModalStore, WorkspaceModal, CATEGORY_COLORS, CATEGORY_PILL_COLORS, ICON_MAP, WorkflowCanvas, getEntityIcon, getEntityGradient, useWorkflowStore, LOGIC_ICON_MAP, LOGIC_NODE_GRADIENTS, getFrameworkMeta, getCompatibleModels, isModelCompatibleWithFramework, FRAMEWORK_META } from '../chunk-BHKBEP2Y.mjs';
5
- export { AgentFlowNode, AgentToolFlowNode, AnswerFlowNode, AnthropicIcon, CodeFlowNode, CrewAIIcon, DocumentExtractorFlowNode, EndFlowNode, EntityFlowNode, FRAMEWORK_META, GoogleADKIcon, GroupFlowNode, HttpRequestFlowNode, IfElseFlowNode, IterationFlowNode, IterationStartFlowNode, KnowledgeBaseFlowNode, LOGIC_ICON_MAP, LOGIC_NODE_BADGE_COLORS, LOGIC_NODE_GRADIENTS, LOGIC_NODE_HANDLE_COLORS, LangChainIcon, ListOperatorFlowNode, LogicNodeModal, MINIMAP_NODE_COLORS, NodeCard, NodeContextMenu, NoteFlowNode, OpenAIIcon, PanelContextMenu, ParameterExtractorFlowNode, QuestionClassifierFlowNode, RuleFlowNode, SelectionContextMenu, StartFlowNode, StrandsIcon, TemplateTransformFlowNode, ToolFlowNode, VariableAggregatorFlowNode, VariableAssignerFlowNode, WorkflowBuilderProvider, Workspace, WorkspaceModal, getCompatibleModels, getDefaultFrameworkForModel, getEntityBadgeColor, getEntityGradient, getEntityHandleColor, getEntityIcon, getEntityMinimapColor, getFrameworkMeta, isModelCompatibleWithFramework, useModalStore, useWorkflowBuilderClient, useWorkflowBuilderClientOptional, useWorkflowStore } from '../chunk-BHKBEP2Y.mjs';
6
- import { FormInput, FormTextarea, Button, GlassFormModal, Input, DynamicIslandConfirm } from '../chunk-F6EBSQF6.mjs';
4
+ import { Workspace, useModalStore, CATEGORY_COLORS, CATEGORY_PILL_COLORS, ICON_MAP, WorkflowCanvas, getEntityIcon, getEntityGradient, useWorkflowStore, LOGIC_ICON_MAP, LOGIC_NODE_GRADIENTS, getFrameworkMeta, getCompatibleModels, isModelCompatibleWithFramework, FRAMEWORK_META } from '../chunk-TM2UUOQO.mjs';
5
+ export { AgentFlowNode, AgentToolFlowNode, AnswerFlowNode, AnthropicIcon, CodeFlowNode, CrewAIIcon, DocumentExtractorFlowNode, EndFlowNode, EntityFlowNode, FRAMEWORK_META, GoogleADKIcon, GroupFlowNode, HttpRequestFlowNode, IfElseFlowNode, IterationFlowNode, IterationStartFlowNode, KnowledgeBaseFlowNode, LOGIC_ICON_MAP, LOGIC_NODE_BADGE_COLORS, LOGIC_NODE_GRADIENTS, LOGIC_NODE_HANDLE_COLORS, LangChainIcon, ListOperatorFlowNode, LogicNodeModal, MINIMAP_NODE_COLORS, NodeCard, NodeContextMenu, NoteFlowNode, OpenAIIcon, PanelContextMenu, ParameterExtractorFlowNode, QuestionClassifierFlowNode, RuleFlowNode, SelectionContextMenu, StartFlowNode, StrandsIcon, TemplateTransformFlowNode, ToolFlowNode, VariableAggregatorFlowNode, VariableAssignerFlowNode, WorkflowBuilderProvider, Workspace, getCompatibleModels, getDefaultFrameworkForModel, getEntityBadgeColor, getEntityGradient, getEntityHandleColor, getEntityIcon, getEntityMinimapColor, getFrameworkMeta, isModelCompatibleWithFramework, useModalStore, useWorkflowBuilderClient, useWorkflowBuilderClientOptional, useWorkflowStore } from '../chunk-TM2UUOQO.mjs';
6
+ import { GlassModalShell, Button, FormInput, FormTextarea, GlassFormModal, Input, DynamicIslandConfirm } from '../chunk-46ZM5VJJ.mjs';
7
7
  import '../chunk-QWG2FMUN.mjs';
8
8
  import '../chunk-D2JF6C3E.mjs';
9
9
  export { GraphNodeBadge, GraphNodeHeader, GraphNodeIconBubble, GraphNodeMeta } from '../chunk-OZNTQROP.mjs';
@@ -284,7 +284,12 @@ function AgentCapabilityCard({ elo, setElo, models, selectedModelId, setSelected
284
284
  step: "50",
285
285
  value: elo,
286
286
  onChange: handleEloChange,
287
- className: "relative z-10 h-5 w-full cursor-pointer appearance-none bg-transparent [&::-webkit-slider-thumb]:h-4 [&::-webkit-slider-thumb]:w-4 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:border-2 [&::-webkit-slider-thumb]:border-white [&::-webkit-slider-thumb]:shadow-lg dark:[&::-webkit-slider-thumb]:border-gray-900"
287
+ "aria-label": t("agentDrawer.capabilityRating"),
288
+ "aria-valuemin": 800,
289
+ "aria-valuemax": 2400,
290
+ "aria-valuenow": elo,
291
+ "aria-valuetext": `${elo} ELO \u2014 ${t(`agentDrawer.tier${tierInfo.tierKey.charAt(0).toUpperCase()}${tierInfo.tierKey.slice(1)}`)}`,
292
+ className: "relative z-10 h-5 w-full cursor-pointer appearance-none bg-transparent focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-blue-500 focus-visible:ring-offset-2 [&::-webkit-slider-thumb]:h-4 [&::-webkit-slider-thumb]:w-4 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:border-2 [&::-webkit-slider-thumb]:border-white [&::-webkit-slider-thumb]:shadow-lg dark:[&::-webkit-slider-thumb]:border-gray-900"
288
293
  }
289
294
  ),
290
295
  /* @__PURE__ */ jsx("style", { children: `input[type="range"]::-webkit-slider-thumb { background: ${elo < 1200 ? "#06b6d4" : elo < 1600 ? "#ec4899" : elo < 2e3 ? "#f59e0b" : "#10b981"}; box-shadow: 0 0 6px ${elo < 1200 ? "rgba(6,182,212,0.5)" : elo < 1600 ? "rgba(236,72,153,0.5)" : elo < 2e3 ? "rgba(245,158,11,0.5)" : "rgba(16,185,129,0.5)"}; }` })
@@ -329,16 +334,18 @@ function AgentCapabilityCard({ elo, setElo, models, selectedModelId, setSelected
329
334
  /* @__PURE__ */ jsx("span", { className: `text-[10px] font-semibold ${tierInfo.color}`, children: t(`agentDrawer.${tierInfo.autonomyKey}`) })
330
335
  ] }),
331
336
  /* @__PURE__ */ jsx("div", { className: "flex gap-1", children: [
332
- { level: 25, label: "Low" },
333
- { level: 50, label: "Med" },
334
- { level: 75, label: "High" },
335
- { level: 100, label: "Full" }
336
- ].map(({ level }) => /* @__PURE__ */ jsx(
337
+ { level: 25, labelKey: "autonomyLow" },
338
+ { level: 50, labelKey: "autonomyMedium" },
339
+ { level: 75, labelKey: "autonomyHigh" },
340
+ { level: 100, labelKey: "autonomyFull" }
341
+ ].map(({ level, labelKey }) => /* @__PURE__ */ jsx(
337
342
  "button",
338
343
  {
339
344
  type: "button",
340
345
  onClick: () => handleAutonomyClick(level),
341
- className: `h-2 flex-1 rounded-full transition-all ${level <= tierInfo.autonomyPercent ? `bg-gradient-to-r ${tierInfo.barColor} hover:opacity-80` : "bg-gray-200 hover:bg-gray-300 dark:bg-gray-700 dark:hover:bg-gray-600"}`
346
+ "aria-label": t(`agentDrawer.${labelKey}`),
347
+ "aria-pressed": level <= tierInfo.autonomyPercent,
348
+ className: `h-2 flex-1 rounded-full transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-blue-500 ${level <= tierInfo.autonomyPercent ? `bg-gradient-to-r ${tierInfo.barColor} hover:opacity-80` : "bg-gray-200 hover:bg-gray-300 dark:bg-gray-700 dark:hover:bg-gray-600"}`
342
349
  },
343
350
  level
344
351
  )) }),
@@ -361,7 +368,7 @@ function ConfigTab({ agent, models, t, selectedModelId, setSelectedModelId, sele
361
368
  setPromptText(event.target.value);
362
369
  markDirty();
363
370
  }, []);
364
- const handleSave = useCallback(() => {
371
+ useCallback(() => {
365
372
  markSaved();
366
373
  }, [markSaved]);
367
374
  const temperaturePercent = temperature * 100;
@@ -465,7 +472,12 @@ function ConfigTab({ agent, models, t, selectedModelId, setSelectedModelId, sele
465
472
  step: "0.05",
466
473
  value: temperature,
467
474
  onChange: handleTemperatureChange,
468
- className: "relative z-10 h-5 w-full cursor-pointer appearance-none bg-transparent [&::-webkit-slider-thumb]:h-5 [&::-webkit-slider-thumb]:w-5 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:border-2 [&::-webkit-slider-thumb]:border-white [&::-webkit-slider-thumb]:shadow-lg dark:[&::-webkit-slider-thumb]:border-gray-900",
475
+ "aria-label": t("agentDrawer.temperature"),
476
+ "aria-valuemin": 0,
477
+ "aria-valuemax": 1,
478
+ "aria-valuenow": temperature,
479
+ "aria-valuetext": `${temperature.toFixed(2)} \u2014 ${isPrecise ? t("agentDrawer.precise") : isBalanced ? t("agentDrawer.balanced") : t("agentDrawer.creative")}`,
480
+ className: "relative z-10 h-5 w-full cursor-pointer appearance-none bg-transparent focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-blue-500 focus-visible:ring-offset-2 [&::-webkit-slider-thumb]:h-5 [&::-webkit-slider-thumb]:w-5 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:border-2 [&::-webkit-slider-thumb]:border-white [&::-webkit-slider-thumb]:shadow-lg dark:[&::-webkit-slider-thumb]:border-gray-900",
469
481
  style: {
470
482
  // Thumb color based on temperature zone
471
483
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
@@ -489,21 +501,9 @@ function ConfigTab({ agent, models, t, selectedModelId, setSelectedModelId, sele
489
501
  /* @__PURE__ */ jsxs("div", { children: [
490
502
  /* @__PURE__ */ jsxs("div", { className: "mb-1 flex items-center justify-between", children: [
491
503
  /* @__PURE__ */ jsx("label", { className: "text-xs font-medium text-gray-500 dark:text-gray-400", children: t("agentDrawer.systemPrompt") }),
492
- /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
493
- /* @__PURE__ */ jsxs("span", { className: "text-[10px] text-gray-400 dark:text-gray-500", children: [
494
- promptText.length,
495
- " chars"
496
- ] }),
497
- dirty && /* @__PURE__ */ jsx(
498
- "button",
499
- {
500
- type: "button",
501
- onClick: handleSave,
502
- className: "rounded-md bg-gradient-to-r from-indigo-500 to-purple-500 px-2.5 py-1 text-[10px] font-semibold text-white shadow-sm transition-all hover:from-indigo-600 hover:to-purple-600",
503
- children: t("agentDrawer.save")
504
- }
505
- ),
506
- !dirty && promptText.length > 0 && /* @__PURE__ */ jsx("span", { className: "text-[10px] font-medium text-emerald-500", children: t("agentDrawer.saved") })
504
+ /* @__PURE__ */ jsxs("span", { className: "text-[10px] text-gray-400 dark:text-gray-500", children: [
505
+ promptText.length,
506
+ " chars"
507
507
  ] })
508
508
  ] }),
509
509
  /* @__PURE__ */ jsx(
@@ -547,7 +547,7 @@ function ResultsTab({ agentId, t }) {
547
547
  ] })
548
548
  ] });
549
549
  }
550
- function AgentDrawer({ onSaved }) {
550
+ function AgentModal({ onSaved }) {
551
551
  const t = useTranslations("agents.workflow");
552
552
  const activeModal = useModalStore((s) => s.activeModal);
553
553
  const agentData = useModalStore((s) => s.agentData);
@@ -593,8 +593,32 @@ function AgentDrawer({ onSaved }) {
593
593
  },
594
594
  tab
595
595
  )) });
596
+ const footer = /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between", children: [
597
+ /* @__PURE__ */ jsx("div", { role: "status", "aria-live": "polite", className: "text-xs", children: dirty ? /* @__PURE__ */ jsx("span", { className: "text-amber-500 dark:text-amber-400", children: t("agentDrawer.unsavedChanges") }) : /* @__PURE__ */ jsx("span", { className: "text-emerald-500 dark:text-emerald-400", children: t("agentDrawer.saved") }) }),
598
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
599
+ /* @__PURE__ */ jsx(
600
+ "button",
601
+ {
602
+ type: "button",
603
+ onClick: handleClose,
604
+ className: "rounded-lg border border-gray-200/50 px-4 py-2 text-xs font-medium text-gray-600 transition-colors hover:bg-gray-100/50 dark:border-white/10 dark:text-gray-300 dark:hover:bg-white/5",
605
+ children: t("agentDrawer.cancel")
606
+ }
607
+ ),
608
+ /* @__PURE__ */ jsx(
609
+ "button",
610
+ {
611
+ type: "button",
612
+ onClick: handleMarkSaved,
613
+ disabled: !dirty,
614
+ className: `rounded-lg px-4 py-2 text-xs font-semibold text-white shadow-sm transition-all ${dirty ? "bg-gradient-to-r from-indigo-500 to-purple-500 hover:from-indigo-600 hover:to-purple-600" : "cursor-not-allowed bg-gray-300 dark:bg-gray-700"}`,
615
+ children: t("agentDrawer.save")
616
+ }
617
+ )
618
+ ] })
619
+ ] });
596
620
  return /* @__PURE__ */ jsxs(
597
- WorkspaceModal,
621
+ GlassModalShell,
598
622
  {
599
623
  open,
600
624
  onClose: handleClose,
@@ -602,7 +626,11 @@ function AgentDrawer({ onSaved }) {
602
626
  subtitle: agent.role ?? "",
603
627
  gradient: "from-indigo-500 to-purple-600",
604
628
  icon: /* @__PURE__ */ jsx(CpuChipIcon, { className: "h-6 w-6 text-white" }),
605
- tabs,
629
+ label: isCreateMode ? t("agentDrawer.createAgent") : t("agentDrawer.editAgent"),
630
+ headerActions: tabs,
631
+ footer,
632
+ maxWidth: "2xl",
633
+ closeLabel: t("agentDrawer.close"),
606
634
  children: [
607
635
  /* @__PURE__ */ jsx(AgentProfileHeader, { agent, models, t, selectedModelId, setSelectedModelId, selectedFramework, temperature, setTemperature, elo, setElo, onChanged: markDirty }),
608
636
  activeTab === "config" ? /* @__PURE__ */ jsx(ConfigTab, { agent, models, t, selectedModelId, setSelectedModelId, selectedFramework, setSelectedFramework: (fw) => setSelectedFramework(fw), temperature, setTemperature, dirty, markDirty, markSaved: handleMarkSaved }) : /* @__PURE__ */ jsx(ResultsTab, { agentId: agent.agentId, t })
@@ -621,7 +649,7 @@ var useSubworkflowStore = create((set) => ({
621
649
  retryCount: 0,
622
650
  dirty: false,
623
651
  // Actions
624
- openDrawer: (tool) => set({
652
+ openModal: (tool) => set({
625
653
  tool,
626
654
  open: true,
627
655
  name: tool.name ?? "",
@@ -685,6 +713,7 @@ function ConfigSection({ title, icon: Icon, defaultOpen = true, children }) {
685
713
  {
686
714
  type: "button",
687
715
  onClick: () => setOpen(!open),
716
+ "aria-expanded": open,
688
717
  className: "flex w-full items-center gap-2 px-4 py-2.5 text-left hover:bg-white/5",
689
718
  children: [
690
719
  open ? /* @__PURE__ */ jsx(ChevronDownIcon, { className: "h-3 w-3 text-gray-400" }) : /* @__PURE__ */ jsx(ChevronRightIcon, { className: "h-3 w-3 text-gray-400" }),
@@ -696,7 +725,7 @@ function ConfigSection({ title, icon: Icon, defaultOpen = true, children }) {
696
725
  open && /* @__PURE__ */ jsx("div", { className: "px-4 pb-3", children })
697
726
  ] });
698
727
  }
699
- function SubworkflowDrawer({ onSaved, onMaximize }) {
728
+ function SubworkflowModal({ onSaved, onMaximize }) {
700
729
  const t = useTranslations("agents.workflow");
701
730
  const tool = useSubworkflowStore((s) => s.tool);
702
731
  const open = useSubworkflowStore((s) => s.open);
@@ -752,16 +781,42 @@ function SubworkflowDrawer({ onSaved, onMaximize }) {
752
781
  const endConfig = endNode?.data?.config;
753
782
  const inputVariables = (startConfig?.inputVariables ?? []).map((v) => ({ name: v, type: "string" }));
754
783
  const outputVariables = (endConfig?.outputVariables ?? []).map((v) => ({ name: v, type: "string" }));
784
+ const footer = /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between", children: [
785
+ /* @__PURE__ */ jsx("div", { role: "status", "aria-live": "polite", className: "text-xs", children: dirty ? /* @__PURE__ */ jsx("span", { className: "text-amber-500 dark:text-amber-400", children: t("subworkflowDrawer.unsavedChanges") }) : /* @__PURE__ */ jsx("span", { className: "text-emerald-500 dark:text-emerald-400", children: t("subworkflowDrawer.saved") }) }),
786
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
787
+ /* @__PURE__ */ jsx(
788
+ "button",
789
+ {
790
+ type: "button",
791
+ onClick: closeModal,
792
+ className: "rounded-lg border border-gray-200/50 px-4 py-2 text-xs font-medium text-gray-600 transition-colors hover:bg-gray-100/50 dark:border-white/10 dark:text-gray-300 dark:hover:bg-white/5",
793
+ children: t("subworkflowDrawer.cancel")
794
+ }
795
+ ),
796
+ /* @__PURE__ */ jsx(
797
+ "button",
798
+ {
799
+ type: "button",
800
+ onClick: handleSave,
801
+ disabled: isCreateMode && !name.trim(),
802
+ className: `rounded-lg px-4 py-2 text-xs font-semibold text-white shadow-sm transition-all ${dirty ? "bg-gradient-to-r from-teal-500 to-cyan-500 hover:from-teal-600 hover:to-cyan-600" : "cursor-not-allowed bg-gray-300 dark:bg-gray-700"}`,
803
+ children: isCreateMode ? t("subworkflowDrawer.create") : t("subworkflowDrawer.save")
804
+ }
805
+ )
806
+ ] })
807
+ ] });
755
808
  return /* @__PURE__ */ jsx(
756
- WorkspaceModal,
809
+ GlassModalShell,
757
810
  {
758
811
  open,
759
812
  onClose: closeModal,
760
813
  title: isCreateMode ? t("subworkflowDrawer.createTitle") : name,
761
814
  subtitle: t("subworkflowDrawer.subworkflow"),
815
+ label: isCreateMode ? t("subworkflowDrawer.new") : t("subworkflowDrawer.edit"),
762
816
  gradient: "from-teal-500 to-cyan-600",
763
817
  icon: /* @__PURE__ */ jsx(ArrowPathRoundedSquareIcon, { className: "h-6 w-6 text-white" }),
764
- maxWidth: "max-w-6xl",
818
+ maxWidth: "6xl",
819
+ footer,
765
820
  children: /* @__PURE__ */ jsxs("div", { className: "flex h-[80vh] min-h-[600px]", children: [
766
821
  /* @__PURE__ */ jsxs("div", { className: "flex w-72 flex-shrink-0 flex-col overflow-y-auto border-r border-white/10", children: [
767
822
  isCreateMode ? /* @__PURE__ */ jsxs("div", { className: "border-b border-white/10 bg-gradient-to-br from-teal-500/15 via-cyan-500/8 to-transparent px-4 py-4 dark:from-teal-500/8 dark:via-cyan-500/4", children: [
@@ -840,7 +895,12 @@ function SubworkflowDrawer({ onSaved, onMaximize }) {
840
895
  step: "1000",
841
896
  value: timeoutMs,
842
897
  onChange: (event) => setTimeoutMs(parseInt(event.target.value, 10)),
843
- className: "h-3 w-full cursor-pointer appearance-none rounded-full bg-gray-200 dark:bg-gray-700 [&::-webkit-slider-thumb]:h-3 [&::-webkit-slider-thumb]:w-3 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:bg-teal-500"
898
+ "aria-label": t("subworkflowDrawer.timeout"),
899
+ "aria-valuemin": 1,
900
+ "aria-valuemax": 30,
901
+ "aria-valuenow": timeoutMs / 1e3,
902
+ "aria-valuetext": `${(timeoutMs / 1e3).toFixed(0)} seconds`,
903
+ className: "h-3 w-full cursor-pointer appearance-none rounded-full bg-gray-200 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-teal-500 dark:bg-gray-700 [&::-webkit-slider-thumb]:h-3 [&::-webkit-slider-thumb]:w-3 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:bg-teal-500"
844
904
  }
845
905
  )
846
906
  ] }),
@@ -861,16 +921,7 @@ function SubworkflowDrawer({ onSaved, onMaximize }) {
861
921
  )) })
862
922
  ] })
863
923
  ] }),
864
- /* @__PURE__ */ jsx("div", { className: "mt-auto border-t border-white/10 px-4 py-3", children: dirty ? /* @__PURE__ */ jsx(
865
- "button",
866
- {
867
- type: "button",
868
- onClick: handleSave,
869
- disabled: isCreateMode && !name.trim(),
870
- className: "w-full rounded-lg bg-gradient-to-r from-teal-500 to-cyan-500 py-2 text-xs font-semibold text-white shadow-sm transition-all hover:from-teal-600 hover:to-cyan-600 disabled:cursor-not-allowed disabled:opacity-40",
871
- children: isCreateMode ? t("subworkflowDrawer.create") : t("subworkflowDrawer.save")
872
- }
873
- ) : /* @__PURE__ */ jsx("div", { className: "text-center text-[10px] font-medium text-emerald-500", children: t("subworkflowDrawer.saved") }) })
924
+ /* @__PURE__ */ jsx("div", { className: "mt-auto" })
874
925
  ] }),
875
926
  /* @__PURE__ */ jsx("div", { className: "flex-1", children: /* @__PURE__ */ jsx(
876
927
  WorkflowCanvas,
@@ -887,6 +938,42 @@ function SubworkflowDrawer({ onSaved, onMaximize }) {
887
938
  }
888
939
  );
889
940
  }
941
+ var LEGACY_WIDTH_MAP = {
942
+ "max-w-xl": "xl",
943
+ "max-w-2xl": "2xl",
944
+ "max-w-4xl": "4xl",
945
+ "max-w-6xl": "6xl",
946
+ "max-w-full": "full"
947
+ };
948
+ function WorkspaceModal({
949
+ open,
950
+ onClose,
951
+ title,
952
+ subtitle,
953
+ icon,
954
+ gradient = "from-gray-400 to-gray-500",
955
+ maxWidth = "2xl",
956
+ tabs,
957
+ children
958
+ }) {
959
+ const resolvedSize = LEGACY_WIDTH_MAP[maxWidth] ?? maxWidth;
960
+ return /* @__PURE__ */ jsxs(
961
+ GlassModalShell,
962
+ {
963
+ open,
964
+ onClose,
965
+ title,
966
+ subtitle,
967
+ icon,
968
+ gradient,
969
+ maxWidth: resolvedSize,
970
+ children: [
971
+ tabs,
972
+ children
973
+ ]
974
+ }
975
+ );
976
+ }
890
977
  function PipelineSettingsModal({ onSave }) {
891
978
  const t = useTranslations("agents.workflow");
892
979
  const activeModal = useModalStore((s) => s.activeModal);
@@ -915,16 +1002,45 @@ function PipelineSettingsModal({ onSave }) {
915
1002
  setIsSaving(false);
916
1003
  }
917
1004
  };
1005
+ const footer = /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-end gap-2", children: [
1006
+ /* @__PURE__ */ jsx(
1007
+ "button",
1008
+ {
1009
+ type: "button",
1010
+ onClick: closeModal,
1011
+ className: "rounded-lg border border-gray-200/50 px-4 py-2 text-xs font-medium text-gray-600 transition-colors hover:bg-gray-100/50 dark:border-white/10 dark:text-gray-300 dark:hover:bg-white/5",
1012
+ children: t("cancel")
1013
+ }
1014
+ ),
1015
+ /* @__PURE__ */ jsxs(
1016
+ Button,
1017
+ {
1018
+ type: "submit",
1019
+ form: "pipeline-settings-form",
1020
+ color: "ios-glass-blue",
1021
+ loading: isSaving,
1022
+ loadingText: t("saving"),
1023
+ children: [
1024
+ /* @__PURE__ */ jsx(CheckIcon, { className: "h-4 w-4" }),
1025
+ t("saveSettings")
1026
+ ]
1027
+ }
1028
+ )
1029
+ ] });
918
1030
  return /* @__PURE__ */ jsx(
919
- WorkspaceModal,
1031
+ GlassModalShell,
920
1032
  {
921
1033
  open,
922
1034
  onClose: closeModal,
923
1035
  title: t("pipelineSettings"),
924
1036
  subtitle: t("pipelineSettingsSubtitle"),
1037
+ label: t("settings"),
925
1038
  icon: /* @__PURE__ */ jsx(Cog6ToothIcon, { className: "h-5 w-5 text-white" }),
926
1039
  gradient: "from-indigo-500 to-purple-600",
927
- children: /* @__PURE__ */ jsxs("form", { onSubmit: handleSubmit, className: "space-y-6", children: [
1040
+ maxWidth: "md",
1041
+ footer,
1042
+ onSubmit: handleSubmit,
1043
+ children: /* @__PURE__ */ jsxs("form", { id: "pipeline-settings-form", onSubmit: handleSubmit, className: "space-y-6", children: [
928
1044
  /* @__PURE__ */ jsx(
929
1045
  FormInput,
930
1046
  {
@@ -944,21 +1060,7 @@ function PipelineSettingsModal({ onSave }) {
944
1060
  placeholder: t("pipelineDescriptionPlaceholder"),
945
1061
  rows: 4
946
1062
  }
947
- ),
948
- /* @__PURE__ */ jsx("div", { className: "pt-2", children: /* @__PURE__ */ jsxs(
949
- Button,
950
- {
951
- type: "submit",
952
- color: "ios-glass-blue",
953
- fullWidth: true,
954
- loading: isSaving,
955
- loadingText: t("saving"),
956
- children: [
957
- /* @__PURE__ */ jsx(CheckIcon, { className: "h-4 w-4" }),
958
- t("saveSettings")
959
- ]
960
- }
961
- ) })
1063
+ )
962
1064
  ] })
963
1065
  }
964
1066
  );
@@ -2951,6 +3053,6 @@ function useHelpLines() {
2951
3053
  };
2952
3054
  }
2953
3055
 
2954
- export { AgentDrawer, AmazonNovaIcon, AnthropicModelIcon, AutoSaveWorkspace, DslExportModal, DslImportModal, DynamicIslandConfirm2 as DynamicIslandConfirm, MetaLlamaIcon, NodePalette, PipelineSettingsModal, PreviewPanel, RunInputDialog, RunPanel, SaveStatusBadge, SubworkflowDrawer, VariableInspector, VersionHistoryPanel, WorkflowListBar, getModelIcon, useCanRedo, useCanUndo, useCanvasShortcuts, useClipboard, useContextMenu, useEditingNodeId, useHasCopied, useHelpLines, useIsRunning, useNodeResults, useSelectedNodeCount, useSubworkflowStore, useUndoRedo };
3056
+ export { AgentModal, AmazonNovaIcon, AnthropicModelIcon, AutoSaveWorkspace, DslExportModal, DslImportModal, DynamicIslandConfirm2 as DynamicIslandConfirm, MetaLlamaIcon, NodePalette, PipelineSettingsModal, PreviewPanel, RunInputDialog, RunPanel, SaveStatusBadge, SubworkflowModal, VariableInspector, VersionHistoryPanel, WorkflowListBar, WorkspaceModal, getModelIcon, useCanRedo, useCanUndo, useCanvasShortcuts, useClipboard, useContextMenu, useEditingNodeId, useHasCopied, useHelpLines, useIsRunning, useNodeResults, useSelectedNodeCount, useSubworkflowStore, useUndoRedo };
2955
3057
  //# sourceMappingURL=index.mjs.map
2956
3058
  //# sourceMappingURL=index.mjs.map