aboutsummaryrefslogtreecommitdiff
path: root/src/components/PollCard
diff options
context:
space:
mode:
authorEugene Sokolov <eug-vs@keemail.me>2020-06-30 01:47:27 +0300
committerGitHub <noreply@github.com>2020-06-30 01:47:27 +0300
commit720a32c4cb1697f3a8f90973f28c334551ab87ff (patch)
treec9028ea3ff850774d33cbc510eb19dd0e9f7aade /src/components/PollCard
parentb301bf24c5037403a1e5fc32fc8c10794941b528 (diff)
parente170d04d5d2c8c86d2683f3accb4feb2d94c881a (diff)
downloadwhich-ui-720a32c4cb1697f3a8f90973f28c334551ab87ff.tar.gz
Merge pull request #54 from which-ecosystem/hooks
Use hooks logic
Diffstat (limited to 'src/components/PollCard')
-rw-r--r--src/components/PollCard/PollCard.tsx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/components/PollCard/PollCard.tsx b/src/components/PollCard/PollCard.tsx
index 156315a..2a23522 100644
--- a/src/components/PollCard/PollCard.tsx
+++ b/src/components/PollCard/PollCard.tsx
@@ -13,7 +13,6 @@ import { post } from '../../requests';
interface PropTypes {
initialPoll: Poll;
- navigate: (prefix: string, id: string) => void;
}
const DATE_FORMAT = {
@@ -54,7 +53,7 @@ const useStyles = makeStyles(theme => ({
}
}));
-const PollCard: React.FC<PropTypes> = ({ initialPoll, navigate }) => {
+const PollCard: React.FC<PropTypes> = ({ initialPoll }) => {
const [poll, setPoll] = useState<Poll>(initialPoll);
const classes = useStyles();
const { author, contents: { left, right }, vote } = poll;
@@ -87,7 +86,7 @@ const PollCard: React.FC<PropTypes> = ({ initialPoll, navigate }) => {
return (
<Card className={classes.root}>
- <UserStrip user={author} info={date} navigate={navigate} />
+ <UserStrip user={author} info={date} />
<div className={classes.imagesBlock}>
<CardActionArea onDoubleClick={handleLeft}>
<CardMedia