Graph Prop: isInteractive (#56)

* feat(props): add isInteractive

* refactor(selection): dont allow if not interactive

* feat(renderer): add class if is interactive

* chore(inactive): add tests

* refactor(inactive): no connection line, no edge selection

closes #49
This commit is contained in:
Moritz
2019-10-23 18:42:17 +02:00
committed by GitHub
parent cf4bd7199a
commit 873fb50b19
28 changed files with 2528 additions and 377 deletions
+14
View File
@@ -99,6 +99,20 @@ export interface NodeComponentProps {
style?: CSSProperties;
}
export interface WrapNodeProps {
id: ElementId;
type: string;
data: any;
selected: boolean;
transform: Transform;
xPos: number;
yPos: number;
isInteractive: boolean;
onClick: (node: Node) => void | undefined;
onNodeDragStop: (node: Node) => void;
style?: CSSProperties;
}
export type FitViewParams = {
padding: number;
};