diff --git a/components/FolderTree.js b/components/FolderTree.js index 0c0c10e..9fd2a6a 100644 --- a/components/FolderTree.js +++ b/components/FolderTree.js @@ -29,6 +29,7 @@ export default function FolderTree(props) { // console.log(currentNode) if (currentNode != null && currentNode.routePath != null) { router.push(currentNode.routePath) + router.reload() } }} sx={{ flexGrow: 1, maxWidth: 400, overflowY: 'auto' }} diff --git a/components/Graph.js b/components/Graph.js index 91258c7..e01ce4e 100644 --- a/components/Graph.js +++ b/components/Graph.js @@ -1,7 +1,7 @@ import React, {useState} from 'react'; // import cytoscape from 'cytoscape'; // import cola from 'cytoscape-cola'; - +import {useRouter} from 'next/router' import CytoscapeComponent from "react-cytoscapejs"; @@ -65,7 +65,7 @@ function Graph({graph}) { }); let myCyRef; - + const router = useRouter() return ( <>