AutoGPT is the vision of accessible AI for everyone, to use and to build on. Our mission is to provide the tools, so that you can focus on what matters.
fix(frontend): Typing in the NodeKeyValueInput field causes the field to un-focus (#8680)
Zamil Majdycd7dfbb8b336
diff --git a/autogpt_platform/frontend/src/components/node-input-components.tsx b/autogpt_platform/frontend/src/components/node-input-components.tsxindex 3e621d6ad1..9eeb90bbfb 100644--- a/autogpt_platform/frontend/src/components/node-input-components.tsx+++ b/autogpt_platform/frontend/src/components/node-input-components.tsx@@ -404,7 +404,11 @@ const NodeKeyValueInput: FC<{><div>{keyValuePairs.map(({ key, value }, index) => (- <div key={getEntryKey(key)}>+ /*+ The `index` is used as a DOM key instead of the actual `key`+ because the `key` can change with each input, causing the input to lose focus.+ */+ <div key={index}><NodeHandlekeyName={getEntryKey(key)}schema={{ type: "string" }}