From 4fbf27d4d4460bbb45f329f720d347ebe570f240 Mon Sep 17 00:00:00 2001 From: Samir Reddigari Date: Sat, 2 May 2020 15:30:28 -0400 Subject: [PATCH] fix(ui): disable node config input if using flow override --- .../src/components/CustomNode/NodeConfig.js | 23 ++++++++----------- 1 file changed, 9 insertions(+), 14 deletions(-) diff --git a/front-end/src/components/CustomNode/NodeConfig.js b/front-end/src/components/CustomNode/NodeConfig.js index 992d47f..67c8f94 100644 --- a/front-end/src/components/CustomNode/NodeConfig.js +++ b/front-end/src/components/CustomNode/NodeConfig.js @@ -251,20 +251,15 @@ function SimpleInput(props) { }, [value, keyName, onChange, type]); - if (props.type === "textarea") { - return ( - - ) - - } else { - return ( - - ) - } + const extraProps = props.type === "textarea" + ? {as: "textarea", rows: props.rows || 7} + : {type: props.type}; + return ( + + ) }