Refactor IOView component to use UpdateAccordion() function

This commit is contained in:
anovazzi1 2024-01-30 15:39:51 -03:00
commit 0c153f6ab5

View file

@ -48,7 +48,6 @@ export default function IOView(): JSX.Element {
return <NewChatView />; return <NewChatView />;
break; break;
case "TextInput": case "TextInput":
console.log("rodoussss");
return <IOInputField inputId={id!} inputType={type} />; return <IOInputField inputId={id!} inputType={type} />;
default: default:
//create empty view output screen //create empty view output screen
@ -105,7 +104,7 @@ export default function IOView(): JSX.Element {
</button> </button>
)} )}
</div> </div>
{inputs {UpdateAccordion()
.filter((input) => input.type !== "ChatInput") .filter((input) => input.type !== "ChatInput")
.map((input, index) => { .map((input, index) => {
const node: NodeType = nodes.find((node) => node.id === input.id)!; const node: NodeType = nodes.find((node) => node.id === input.id)!;