From f6bb137ccf414ba36610c0ceea598c95683dce60 Mon Sep 17 00:00:00 2001
From: eug-vs <eug-vs@keemail.me>
Date: Fri, 3 Jul 2020 23:00:04 +0300
Subject: refactor: use mui-breakpoints

---
 src/pages/Page.tsx | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

(limited to 'src/pages/Page.tsx')

diff --git a/src/pages/Page.tsx b/src/pages/Page.tsx
index 4c46ea8..91b7214 100644
--- a/src/pages/Page.tsx
+++ b/src/pages/Page.tsx
@@ -1,7 +1,6 @@
 import React from 'react';
 import { makeStyles } from '@material-ui/core/styles';
 import { SnackbarProvider } from 'notistack';
-import { isMobile } from 'react-device-detect';
 
 import ProfilePage from './ProfilePage/ProfilePage';
 import FeedPage from './FeedPage/FeedPage';
@@ -13,7 +12,12 @@ import { useNavigate } from '../hooks/useNavigate';
 
 const useStyles = makeStyles(theme => ({
   root: {
-    margin: isMobile ? theme.spacing(2) : theme.spacing(15, 5, 5, 8)
+    [theme.breakpoints.down('sm')]: {
+      margin: theme.spacing(2)
+    },
+    [theme.breakpoints.up('md')]: {
+      margin: theme.spacing(15, 5, 5, 8)
+    }
   }
 }));
 
-- 
cgit v1.2.3

