aboutsummaryrefslogtreecommitdiffstats
path: root/packages/website/ts/utils
diff options
context:
space:
mode:
authorfragosti <francesco.agosti93@gmail.com>2018-07-03 08:26:48 +0800
committerfragosti <francesco.agosti93@gmail.com>2018-07-03 08:26:48 +0800
commita5231df6d9d8c9b89431df2e4674f46d307f6d80 (patch)
treead34f5ebe57f30c912d2f021f3298c22220dd6b9 /packages/website/ts/utils
parent73e81c62fb2e902cb7252410fe162e8f2ba2596b (diff)
downloaddexon-0x-contracts-a5231df6d9d8c9b89431df2e4674f46d307f6d80.tar.gz
dexon-0x-contracts-a5231df6d9d8c9b89431df2e4674f46d307f6d80.tar.zst
dexon-0x-contracts-a5231df6d9d8c9b89431df2e4674f46d307f6d80.zip
Add media query abstraction around ScreenWidths and stop relayer grid hover effect on mobile
Diffstat (limited to 'packages/website/ts/utils')
-rw-r--r--packages/website/ts/utils/utils.ts7
1 files changed, 2 insertions, 5 deletions
diff --git a/packages/website/ts/utils/utils.ts b/packages/website/ts/utils/utils.ts
index 726e1815f..73dacc1d6 100644
--- a/packages/website/ts/utils/utils.ts
+++ b/packages/website/ts/utils/utils.ts
@@ -27,9 +27,6 @@ import { configs } from 'ts/utils/configs';
import { constants } from 'ts/utils/constants';
import * as u2f from 'ts/vendor/u2f_api';
-const LG_MIN_EM = 64;
-const MD_MIN_EM = 52;
-
const isDogfood = (): boolean => _.includes(window.location.href, configs.DOMAIN_DOGFOOD);
export const utils = {
@@ -134,9 +131,9 @@ export const utils = {
// This logic mirrors the CSS media queries in BassCSS for the `lg-`, `md-` and `sm-` CSS
// class prefixes. Do not edit these.
- if (widthInEm > LG_MIN_EM) {
+ if (widthInEm > ScreenWidths.Lg) {
return ScreenWidths.Lg;
- } else if (widthInEm > MD_MIN_EM) {
+ } else if (widthInEm > ScreenWidths.Md) {
return ScreenWidths.Md;
} else {
return ScreenWidths.Sm;