summaryrefslogtreecommitdiffstats
path: root/src/components/ui/button/index.tsx
diff options
context:
space:
mode:
authorLibravatar Santhosh Chinnasamy <csesanthosh15@gmail.com>2022-05-16 11:35:34 +0530
committerLibravatar Vijay Aravamudhan <vraravam@users.noreply.github.com>2022-05-16 06:20:11 -0500
commitbbde4a9d54d9c7dc03f34ca4113061a605dd5040 (patch)
tree240f6a34a6b772fb3e04d9bf96b1f36bc4cf7cca /src/components/ui/button/index.tsx
parent6.0.0-nightly.37 [skip ci] (diff)
downloadferdium-app-bbde4a9d54d9c7dc03f34ca4113061a605dd5040.tar.gz
ferdium-app-bbde4a9d54d9c7dc03f34ca4113061a605dd5040.tar.zst
ferdium-app-bbde4a9d54d9c7dc03f34ca4113061a605dd5040.zip
remove duplicate Button component
Diffstat (limited to 'src/components/ui/button/index.tsx')
-rw-r--r--src/components/ui/button/index.tsx12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/components/ui/button/index.tsx b/src/components/ui/button/index.tsx
index 11369dcbd..822ddf48f 100644
--- a/src/components/ui/button/index.tsx
+++ b/src/components/ui/button/index.tsx
@@ -35,7 +35,11 @@ interface IProps extends IFormField, WithStylesProps<typeof styles> {
35let buttonTransition: string = 'none'; 35let buttonTransition: string = 'none';
36let loaderContainerTransition: string = 'none'; 36let loaderContainerTransition: string = 'none';
37 37
38if (window && window.matchMedia('(prefers-reduced-motion: no-preference)')) { 38if (
39 typeof window !== 'undefined' &&
40 window &&
41 window.matchMedia('(prefers-reduced-motion: no-preference)')
42) {
39 buttonTransition = 'background .5s, opacity 0.3s'; 43 buttonTransition = 'background .5s, opacity 0.3s';
40 loaderContainerTransition = 'all 0.3s'; 44 loaderContainerTransition = 'all 0.3s';
41} 45}
@@ -259,6 +263,6 @@ class ButtonComponent extends Component<IProps> {
259 } 263 }
260} 264}
261 265
262export const Button = injectStyle(styles, { injectTheme: true })( 266const Button = injectStyle(styles, { injectTheme: true })(ButtonComponent);
263 ButtonComponent, 267
264); 268export default Button;