mirror of
https://github.com/stan-smith/FossFLOW.git
synced 2025-12-26 16:09:10 -05:00
feat: resets window cursor when Isoflow is unmounted
This commit is contained in:
@@ -12,7 +12,7 @@ import {
|
||||
IsoflowProps,
|
||||
InitialScene
|
||||
} from 'src/types';
|
||||
import { sceneToSceneInput } from 'src/utils';
|
||||
import { sceneToSceneInput, setWindowCursor } from 'src/utils';
|
||||
import { useSceneStore, SceneProvider } from 'src/stores/sceneStore';
|
||||
import { GlobalStyles } from 'src/styles/GlobalStyles';
|
||||
import { Renderer } from 'src/components/Renderer/Renderer';
|
||||
@@ -53,6 +53,12 @@ const App = ({
|
||||
uiActions.setEditorMode(editorMode);
|
||||
}, [initialScene?.zoom, editorMode, sceneActions, uiActions]);
|
||||
|
||||
useEffect(() => {
|
||||
return () => {
|
||||
setWindowCursor('default');
|
||||
};
|
||||
}, []);
|
||||
|
||||
useEffect(() => {
|
||||
if (!initialScene || prevInitialScene.current === initialScene) return;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user