feat: testing on how to flatten tree structures
This commit is contained in:
@ -53,7 +53,7 @@
|
||||
|
||||
<div class="wrapper" data-node-id={node.id}>
|
||||
<div class="content">
|
||||
{node.type} / {node.id}
|
||||
{node.type.split("/").pop()}
|
||||
</div>
|
||||
<div
|
||||
class="click-target"
|
||||
|
@ -5,17 +5,17 @@
|
||||
|
||||
export let node: Node;
|
||||
export let input: NodeInput;
|
||||
export let id: string;
|
||||
export let label: string;
|
||||
|
||||
const graph = getGraphManager();
|
||||
|
||||
let value = node?.props?.[id] ?? input.value;
|
||||
let value = node?.props?.[label] ?? input.value;
|
||||
|
||||
$: if (node?.props?.[id] !== value) {
|
||||
node.props = { ...node.props, [id]: value };
|
||||
$: if (node?.props?.[label] !== value) {
|
||||
node.props = { ...node.props, [label]: value };
|
||||
graph.execute();
|
||||
}
|
||||
</script>
|
||||
|
||||
<label for="asd">{id}</label>
|
||||
<label for="asd">{label}</label>
|
||||
<Input {input} bind:value />
|
||||
|
@ -69,7 +69,7 @@
|
||||
>
|
||||
{#key id && graphId}
|
||||
<div class="content" class:disabled={$inputSockets.has(socketId)}>
|
||||
<NodeInput {node} {input} {id} />
|
||||
<NodeInput {node} {input} label={input?.title || id} />
|
||||
</div>
|
||||
|
||||
{#if node?.tmp?.type?.inputs?.[id]?.internal !== true}
|
||||
|
Reference in New Issue
Block a user