From c532c284f8aaff8ab1702b06325642f437a9fbb7 Mon Sep 17 00:00:00 2001 From: Christian Moore Date: Fri, 29 Nov 2024 08:20:37 +1100 Subject: [PATCH] Fix focus theft on initial render --- .../src/Tile/subcomponents/GenericTile/GenericTile.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/components/src/Tile/subcomponents/GenericTile/GenericTile.tsx b/packages/components/src/Tile/subcomponents/GenericTile/GenericTile.tsx index 781baabc52e..83c8670ecee 100644 --- a/packages/components/src/Tile/subcomponents/GenericTile/GenericTile.tsx +++ b/packages/components/src/Tile/subcomponents/GenericTile/GenericTile.tsx @@ -65,6 +65,10 @@ export const GenericTile = ({ isMountingRef.current = true }, []) + useEffect(() => { + isMountingRef.current = true + }, []) + useEffect(() => { if (!isMountingRef.current) { if (isFlipped) {