Refactor(types): unify node and edge handling (#3978)
* refactor(types): unify node and edge type behaviour * chore(changelogs): update * chore(examples): cleanup
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
<script lang="ts">
|
||||
import type { ChangeEventHandler } from 'svelte/elements';
|
||||
import { writable } from 'svelte/store';
|
||||
import {
|
||||
SvelteFlow,
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
<script lang="ts">
|
||||
import type { Writable } from 'svelte/store';
|
||||
import { Handle, Position, type NodeProps } from '@xyflow/svelte';
|
||||
import { Handle, Position, type NodeProps, type Node } from '@xyflow/svelte';
|
||||
|
||||
type $$Props = NodeProps;
|
||||
type $$Props = NodeProps<Node<{ colorStore: Writable<string> }>>;
|
||||
|
||||
export let data: { colorStore: Writable<string> };
|
||||
export let data: $$Props['data'];
|
||||
|
||||
const { colorStore } = data;
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user