aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/ui/toggle/index.tsx
diff options
context:
space:
mode:
authorLibravatar Vijay A <vraravam@users.noreply.github.com>2023-05-28 13:48:21 +0530
committerLibravatar Vijay A <vraravam@users.noreply.github.com>2023-05-28 13:48:21 +0530
commit99ca310c73024b51fed1f3077375eed7827f2c20 (patch)
tree2bd15986f448129a2291acba90ccc6bf68a233e0 /src/components/ui/toggle/index.tsx
parentDisable in-app auto-updates for portable windows installation (fixes #1088) (... (diff)
downloadferdium-app-99ca310c73024b51fed1f3077375eed7827f2c20.tar.gz
ferdium-app-99ca310c73024b51fed1f3077375eed7827f2c20.tar.zst
ferdium-app-99ca310c73024b51fed1f3077375eed7827f2c20.zip
Fix issues reported by sonarqube linter
Diffstat (limited to 'src/components/ui/toggle/index.tsx')
-rw-r--r--src/components/ui/toggle/index.tsx9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/components/ui/toggle/index.tsx b/src/components/ui/toggle/index.tsx
index 828941886..48f68943b 100644
--- a/src/components/ui/toggle/index.tsx
+++ b/src/components/ui/toggle/index.tsx
@@ -16,10 +16,11 @@ interface IProps
16 className?: string; 16 className?: string;
17} 17}
18 18
19const buttonTransition: string = 19const buttonTransition: string = window?.matchMedia(
20 window && window.matchMedia('(prefers-reduced-motion: no-preference)') 20 '(prefers-reduced-motion: no-preference)',
21 ? 'all .5s' 21)
22 : 'none'; 22 ? 'all .5s'
23 : 'none';
23 24
24const styles = (theme: Theme) => ({ 25const styles = (theme: Theme) => ({
25 toggle: { 26 toggle: {