use generics across the library
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
import type { Snippet } from 'svelte';
|
||||
import { type SvelteFlowRestProps } from '$lib/store/types';
|
||||
import { toPxString } from '$lib/utils';
|
||||
import type { Node, Edge, NodeTypes } from '$lib/types';
|
||||
import type { Node, Edge } from '$lib/types';
|
||||
|
||||
let {
|
||||
width,
|
||||
|
||||
@@ -45,9 +45,9 @@ import type { EdgeEvents, NodeEvents, NodeSelectionEvents, PaneEvents } from '$l
|
||||
export type SvelteFlowProps<
|
||||
NodeType extends Node = Node,
|
||||
EdgeType extends Edge = Edge
|
||||
> = NodeEvents &
|
||||
NodeSelectionEvents &
|
||||
EdgeEvents &
|
||||
> = NodeEvents<NodeType> &
|
||||
NodeSelectionEvents<NodeType> &
|
||||
EdgeEvents<EdgeType> &
|
||||
PaneEvents & {
|
||||
/** The id of the flow
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user