refactor(onlyRenderVisible): change from nodes to elements #677

This commit is contained in:
moklick
2020-11-14 16:46:14 +01:00
parent 6e0b31d9c1
commit 2420cf3689
7 changed files with 121 additions and 98 deletions
+3 -3
View File
@@ -88,7 +88,7 @@ export interface ReactFlowProps extends Omit<HTMLAttributes<HTMLDivElement>, 'on
multiSelectionKeyCode?: KeyCode;
snapToGrid?: boolean;
snapGrid?: [number, number];
onlyRenderVisibleNodes?: boolean;
onlyRenderVisibleElements?: boolean;
nodesDraggable?: boolean;
nodesConnectable?: boolean;
elementsSelectable?: boolean;
@@ -142,7 +142,7 @@ const ReactFlow = ({
multiSelectionKeyCode = 'Meta',
snapToGrid = false,
snapGrid = [15, 15],
onlyRenderVisibleNodes = true,
onlyRenderVisibleElements = true,
selectNodesOnDrag = true,
nodesDraggable,
nodesConnectable,
@@ -200,7 +200,7 @@ const ReactFlow = ({
onConnectEnd={onConnectEnd}
snapToGrid={snapToGrid}
snapGrid={snapGrid}
onlyRenderVisibleNodes={onlyRenderVisibleNodes}
onlyRenderVisibleElements={onlyRenderVisibleElements}
nodesDraggable={nodesDraggable}
nodesConnectable={nodesConnectable}
elementsSelectable={elementsSelectable}