Skip to content
Snippets Groups Projects
Commit ca672e4d authored by Maximilian Giller's avatar Maximilian Giller :squid:
Browse files

Hooked initial loading of graph to Mount-Hook

parent 8e5b0f4d
No related branches found
No related tags found
No related merge requests found
Pipeline #56929 passed
......@@ -12,7 +12,9 @@ import { Link } from "../structures/graph/link";
import { NodeTypesEditor } from "./nodetypeseditor";
import { SpaceManager } from "./spacemanager";
type propTypes = any;
type propTypes = {
spaceId: string;
};
type stateTypes = {
graph: Graph;
visibleLabels: boolean;
......@@ -72,9 +74,13 @@ export class Editor extends React.PureComponent<propTypes, stateTypes> {
keys: {},
graphWidth: 1000,
};
}
// Load initial space
this.loadSpace("space");
componentDidMount() {
if (this.props.spaceId !== undefined) {
// Load initial space
this.loadSpace(this.props.spaceId);
}
}
/**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment