aboutsummaryrefslogtreecommitdiffstats
path: root/packages/website/ts/style/media.ts
diff options
context:
space:
mode:
authorFrancesco Agosti <francesco.agosti93@gmail.com>2018-07-04 05:43:02 +0800
committerGitHub <noreply@github.com>2018-07-04 05:43:02 +0800
commit0900e0c85e76a34301ad5a336d2b195ed595aef7 (patch)
treea5031f90ed81a0758712ad9478c1d9201692f08b /packages/website/ts/style/media.ts
parentd91b30faef0e53072757dfd5fea86db10dcf838f (diff)
parent32c25a20341964498c3594758aa02908c98dbfc0 (diff)
downloaddexon-sol-tools-0900e0c85e76a34301ad5a336d2b195ed595aef7.tar
dexon-sol-tools-0900e0c85e76a34301ad5a336d2b195ed595aef7.tar.gz
dexon-sol-tools-0900e0c85e76a34301ad5a336d2b195ed595aef7.tar.bz2
dexon-sol-tools-0900e0c85e76a34301ad5a336d2b195ed595aef7.tar.lz
dexon-sol-tools-0900e0c85e76a34301ad5a336d2b195ed595aef7.tar.xz
dexon-sol-tools-0900e0c85e76a34301ad5a336d2b195ed595aef7.tar.zst
dexon-sol-tools-0900e0c85e76a34301ad5a336d2b195ed595aef7.zip
Merge pull request #811 from 0xProject/feature/website/onboarding-polish-2
Add Hotjar, and other small improvements
Diffstat (limited to 'packages/website/ts/style/media.ts')
-rw-r--r--packages/website/ts/style/media.ts14
1 files changed, 14 insertions, 0 deletions
diff --git a/packages/website/ts/style/media.ts b/packages/website/ts/style/media.ts
new file mode 100644
index 000000000..3c992eb9f
--- /dev/null
+++ b/packages/website/ts/style/media.ts
@@ -0,0 +1,14 @@
+import { css } from 'ts/style/theme';
+import { ScreenWidths } from 'ts/types';
+
+const generateMediaWrapper = (screenWidth: ScreenWidths) => (...args: any[]) => css`
+ @media (max-width: ${screenWidth}) {
+ ${css.apply(css, args)};
+ }
+`;
+
+export const media = {
+ small: generateMediaWrapper(ScreenWidths.Sm),
+ medium: generateMediaWrapper(ScreenWidths.Md),
+ large: generateMediaWrapper(ScreenWidths.Lg),
+};