Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding header #572

Merged
merged 2 commits into from
Jul 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ const CREATE_REPLY_REQUEST = gql`
mutation CreateReplyRequestFromForm($articleId: String!, $reason: String!) {
CreateReplyRequest(articleId: $articleId, reason: $reason) {
id
updatedAt
}
}
`;
Expand Down
18 changes: 17 additions & 1 deletion components/ReplyRequestReason/ReplyRequestReason.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
import { useMutation } from '@apollo/react-hooks';
import { makeStyles } from '@material-ui/core/styles';
import { Box, Button } from '@material-ui/core';
import TimeInfo from 'components/Infos/TimeInfo';
import Link from 'next/link';

Check failure on line 8 in components/ReplyRequestReason/ReplyRequestReason.js

View workflow job for this annotation

GitHub Actions / install-and-test

'Link' is defined but never used

import { ThumbUpIcon, ThumbDownIcon } from 'components/icons';
import Avatar from 'components/AppLayout/Widgets/Avatar';
Expand All @@ -22,6 +24,16 @@
borderTop: `1px solid ${theme.palette.secondary[100]}`,
},
},
header: {
display: 'flex',
alignItems: 'center',
marginBottom: 5,
},
user: {
margin: 0,
marginRight: 5,
fontWeight: 'bold',
},
reason: {
marginTop: 0,
},
Expand Down Expand Up @@ -61,7 +73,7 @@
reason
positiveFeedbackCount
negativeFeedbackCount

updatedAt
user {
id
name
Expand Down Expand Up @@ -113,6 +125,10 @@
<Avatar user={user} size={40} />
</Box>
<Box flex={1} className={classes.reasonBody}>
<Box className={classes.header}>
<p className={classes.user}>{user.id}</p>
<TimeInfo time={replyRequest.updatedAt}/>

Check failure on line 130 in components/ReplyRequestReason/ReplyRequestReason.js

View workflow job for this annotation

GitHub Actions / install-and-test

Insert `·`
</Box>
<p className={classes.reason}>{replyRequestReason}</p>
<Box display="flex" justifyContent="space-between">
<Box display="flex">
Expand Down
Loading