Input
diff --git a/space_flow/src/CustomNodes/ChatOutputNode/index.tsx b/space_flow/src/CustomNodes/ChatOutputNode/index.tsx
index 069308f96..b284f27ea 100644
--- a/space_flow/src/CustomNodes/ChatOutputNode/index.tsx
+++ b/space_flow/src/CustomNodes/ChatOutputNode/index.tsx
@@ -2,23 +2,29 @@ import { ChatBubbleBottomCenterTextIcon } from "@heroicons/react/24/outline";
import { Handle, Position } from "reactflow";
import Input from "../../components/inputComponent";
import { snakeToNormalCase } from "../../utils";
+import Tooltip from "../../components/TooltipComponent";
export default function ChatOutputNode({ data }) {
-
- return (
-
+ return (
+
+
+ targetHandle === sourceHandle ||
+ data.types[targetHandle] === sourceHandle ||
+ sourceHandle === "str"
+ }
position={Position.Left}
id="str"
className="ml-1 bg-transparent border-solid border-l-8 border-l-white border-y-transparent border-y-8 border-r-0 rounded-none"
>
-
- Output
-
-
-
- );
+
-}
\ No newline at end of file
+
+ Output
+
+
+
+ );
+}
diff --git a/space_flow/src/CustomNodes/GenericNode/index.tsx b/space_flow/src/CustomNodes/GenericNode/index.tsx
index 0f155e423..3df3fe8b2 100644
--- a/space_flow/src/CustomNodes/GenericNode/index.tsx
+++ b/space_flow/src/CustomNodes/GenericNode/index.tsx
@@ -34,9 +34,17 @@ export default function GenericNode({ data }) {
type="source"
position={Position.Left}
id={data.node.template[t].type}
+ isValidConnection={({ sourceHandle, targetHandle }) =>
+ targetHandle === sourceHandle ||
+ data.types[targetHandle] === sourceHandle ||
+ sourceHandle === "str"
+ }
className="ml-1 bg-transparent border-solid border-l-8 border-y-transparent border-y-8 border-r-0 rounded-none"
- style={{borderLeftColor: nodeColors[data.type], marginTop: ((idx*30)-50) + "px"}}
- >
+ style={{
+ borderLeftColor: nodeColors[data.type],
+ marginTop: idx * 30 - 50 + "px",
+ }}
+ >
))}
@@ -48,14 +56,20 @@ export default function GenericNode({ data }) {