From b7a2a7191cd7963ac83d495a2755fc8cc842a885 Mon Sep 17 00:00:00 2001 From: mrshmllow Date: Tue, 20 Sep 2022 22:14:15 +1000 Subject: [PATCH] minimize lazyout shift on switchers --- components/LocaleSwitcher/IconLocaleSwitcher.tsx | 2 +- components/ThemeSwitcher/IconThemeSwitcher.tsx | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/components/LocaleSwitcher/IconLocaleSwitcher.tsx b/components/LocaleSwitcher/IconLocaleSwitcher.tsx index 353ca80..bf62339 100644 --- a/components/LocaleSwitcher/IconLocaleSwitcher.tsx +++ b/components/LocaleSwitcher/IconLocaleSwitcher.tsx @@ -18,7 +18,7 @@ const IconLocaleSwitcher = () => { }, []); if (!mounted) { - return null; + return ; } const changeLocale = (locale: string) => { diff --git a/components/ThemeSwitcher/IconThemeSwitcher.tsx b/components/ThemeSwitcher/IconThemeSwitcher.tsx index ed68530..c3a5270 100644 --- a/components/ThemeSwitcher/IconThemeSwitcher.tsx +++ b/components/ThemeSwitcher/IconThemeSwitcher.tsx @@ -15,7 +15,7 @@ const IconThemeSwitcher = () => { }, []); if (!mounted) { - return null; + return ; } const changeTheme = (theme: string) => { @@ -46,6 +46,7 @@ const IconThemeSwitcher = () => {