mirror of
https://github.com/supabase/supabase.git
synced 2026-10-19 08:09:11 +03:00
Run fitView after 50 milliseconds because it didn't run in some cases.
This commit is contained in:
1 parent
a976286e71
commit
5affe6aaf1
1 file changed
+1
-1
@@ -46,7 +46,7 @@ const SchemaFlowHandler = ({ content }: SchemaGraphProps) => {
|
||||
getGraphDataFromTables(tables).then(({ nodes, edges }) => {
|
||||
reactFlowInstance.setNodes(nodes)
|
||||
reactFlowInstance.setEdges(edges)
|
||||
setTimeout(() => reactFlowInstance.fitView({}), 10)
|
||||
setTimeout(() => reactFlowInstance.fitView({}), 50)
|
||||
})
|
||||
}, [tables, resolvedTheme, reactFlowInstance])
|
||||
|
||||
|
||||
Reference in new issue
Block a user