aboutsummaryrefslogtreecommitdiff
path: root/src/pages/FeedPage/FeedPage.tsx
diff options
context:
space:
mode:
authoreug-vs <eug-vs@keemail.me>2020-07-03 22:44:38 +0300
committereug-vs <eug-vs@keemail.me>2020-07-03 22:44:38 +0300
commit6a216b903899d1481f93ebff40e246f60c4c3e89 (patch)
tree9cae6a4aa2318e36015ef98116096ccd2f03a6e1 /src/pages/FeedPage/FeedPage.tsx
parentf74dedfce4ade65cfe023c973a6c137a56c88ab5 (diff)
downloadwhich-ui-6a216b903899d1481f93ebff40e246f60c4c3e89.tar.gz
feat: adapt all pages to mobile view
Diffstat (limited to 'src/pages/FeedPage/FeedPage.tsx')
-rw-r--r--src/pages/FeedPage/FeedPage.tsx15
1 files changed, 3 insertions, 12 deletions
diff --git a/src/pages/FeedPage/FeedPage.tsx b/src/pages/FeedPage/FeedPage.tsx
index 8149c8c..0b7d44a 100644
--- a/src/pages/FeedPage/FeedPage.tsx
+++ b/src/pages/FeedPage/FeedPage.tsx
@@ -1,24 +1,15 @@
import React, { useState, useEffect } from 'react';
import { Poll } from 'which-types';
-import { makeStyles } from '@material-ui/core/styles';
+import { Container } from '@material-ui/core/';
import Feed from '../../components/Feed/Feed';
import { get } from '../../requests';
import PollSubmission from './PollSubmission';
import { useAuth } from '../../hooks/useAuth';
-
-const useStyles = makeStyles(theme => ({
- root: {
- width: theme.spacing(75),
- margin: '0 auto'
- }
-}));
-
const FeedPage: React.FC = () => {
const [polls, setPolls] = useState<Poll[]>([]);
const { isAuthenticated } = useAuth();
- const classes = useStyles();
useEffect(() => {
get('/feed').then(response => {
@@ -33,10 +24,10 @@ const FeedPage: React.FC = () => {
};
return (
- <div className={classes.root}>
+ <Container maxWidth="sm" disableGutters>
{isAuthenticated() && <PollSubmission addPoll={addPoll} />}
<Feed polls={polls} />
- </div>
+ </Container>
);
};