feat(svelte): add snapGrid

This commit is contained in:
moklick
2023-03-14 15:43:14 +01:00
parent ae244526bd
commit 9c7bd6dc68
7 changed files with 36 additions and 16 deletions
@@ -26,6 +26,7 @@
export let edgeTypes: $$Props['edgeTypes'] = undefined;
export let selectionKey: $$Props['selectionKey'] = undefined;
export let selectionMode: $$Props['selectionMode'] = undefined;
export let snapGrid: $$Props['snapGrid'] = undefined;
export let deleteKey: $$Props['deleteKey'] = undefined;
export let connectionRadius: $$Props['connectionRadius'] = undefined;
export let connectionLineType: $$Props['connectionLineType'] = undefined;
@@ -56,6 +57,7 @@
connectionLineType,
connectionRadius,
selectionMode,
snapGrid,
isValidConnection
};
@@ -4,7 +4,8 @@ import type {
NodeOrigin,
OnConnectStartParams,
Viewport,
SelectionMode
SelectionMode,
SnapGrid
} from '@reactflow/system';
import type {
@@ -29,6 +30,7 @@ export type SvelteFlowProps = {
initialViewport?: Viewport;
connectionRadius?: number;
selectionMode?: SelectionMode;
snapGrid?: SnapGrid;
class?: string;
style?: string;