Fix vertex iteration bug and add component metadata

This commit is contained in:
Gabriel Luiz Freitas Almeida 2024-03-11 18:09:33 -03:00
commit 4d45f47698
6 changed files with 15 additions and 5 deletions

View file

@ -75,7 +75,11 @@ export default function GenericNode({
// This one should run only once
// first check if data.type in NATIVE_CATEGORIES
// if not return
if (!NATIVE_CATEGORIES.includes(types[data.type]) || !data.node?.template?.code?.value) return;
if (
!NATIVE_CATEGORIES.includes(types[data.type]) ||
!data.node?.template?.code?.value
)
return;
const thisNodeTemplate = templates[data.type].template;
// if the template does not have a code key
// return
@ -110,7 +114,7 @@ export default function GenericNode({
updateNodeInternals(data.id);
},
[data.id, data.node, setNode,setIsOutdated]
[data.id, data.node, setNode, setIsOutdated]
);
if (!data.node!.template) {

View file

@ -386,7 +386,7 @@ export function getCurlCode(
-H 'Content-Type: application/json'\\${
!isAuth ? `\n -H 'x-api-key: <your api key>'\\` : ""
}
-d '{"inputs": ${inputs}, "tweaks": ${
-d '{"inputs": [${inputs}], "tweaks": ${
tweak && tweak.length > 0
? buildTweakObject(tweak)
: JSON.stringify(tweaks, null, 2)