diff --git a/react/src/components/CustomQuery.tsx b/react/src/components/CustomQuery.tsx index 72e67f3..c852ed4 100644 --- a/react/src/components/CustomQuery.tsx +++ b/react/src/components/CustomQuery.tsx @@ -362,6 +362,12 @@ function CustomQueryPage() { [] ); const [openPanel, setOpenPanel] = useState(false); + const [renderVisualization, setRenderVisualization] = useState(true); + + const handleRenderVisualizationToggle = () => { + setRenderVisualization(!renderVisualization); + }; + const initialNodes = []; const initialEdges = []; @@ -377,7 +383,7 @@ function CustomQueryPage() { }).then((response) => { return response.json() }).then(json => { - if (!json.data.hasOwnProperty("__schema")) { // only update response data if it's not a schema info response + if (!json.data.hasOwnProperty("__schema") && renderVisualization) { // only update response data if it's not a schema info response // clearArray(initialEdges) // clearArray(initialNodes) @@ -407,10 +413,13 @@ function CustomQueryPage() { <>
- 📖 🐛 BookWorm + + 📖 🐛 BookWorm
+