Skip to content

Commit 0bdaed1

Browse files
Merge pull request #291 from dreamyPatisiel/dev
fix: comment style 수정
2 parents 7f91518 + 716fe60 commit 0bdaed1

2 files changed

Lines changed: 41 additions & 41 deletions

File tree

components/common/comments/CommentHeader.tsx

Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -39,55 +39,55 @@ export default function CommentHeader({
3939
const { isMobile } = useMediaQueryContext();
4040

4141
return (
42-
<div className='flex justify-between'>
43-
<div className={`flex ${isMobile ? 'flex-col gap-2' : 'items-center gap-4'}`}>
44-
<span className={`flex ${isMobile ? 'gap-[0.4rem] mb-[1rem]' : ''}`}>
45-
{isBestComment && (
46-
<Tag
47-
color='secondary'
48-
status='main'
49-
size='basic'
50-
content='Best'
51-
className={`w-fit font-bold ${isMobile ? '' : 'mr-[1.6rem]'}`}
52-
/>
53-
)}
54-
{isCommentAuthor && isMobile && (
42+
<div className={`flex ${isMobile ? 'flex-col' : ''}`}>
43+
<div className={`${isMobile ? 'flex gap-[0.4rem] mb-[1rem]' : ''}`}>
44+
{isBestComment && (
45+
<Tag
46+
color='secondary'
47+
status='main'
48+
size='basic'
49+
content='Best'
50+
className={`w-fit font-bold ${isMobile ? '' : 'mr-[1.6rem]'}`}
51+
/>
52+
)}
53+
{isCommentAuthor && isMobile && (
54+
<Tag
55+
color='secondary'
56+
status='line'
57+
size='basic'
58+
content='내가 썼어요'
59+
className='w-fit font-bold'
60+
/>
61+
)}
62+
</div>
63+
64+
<div className='flex justify-between w-full'>
65+
<div className={`flex ${isMobile ? 'flex-col gap-2' : 'items-center gap-4'}`}>
66+
<span className={`flex items-center`}>
67+
{isCommentOfPickAuthor ? (
68+
<Image src={writerIcon} alt={'작성자 아이콘'} className='mr-[0.8rem]' />
69+
) : null}
70+
<NicknameWithMaskedEmail author={author} maskedEmail={maskedEmail} textSize='p2' />
71+
</span>
72+
<time className={`p2 text-gray300`}>{formatISOtoDate(createdAt || '')}</time>
73+
74+
{isCommentAuthor && !isMobile && (
5575
<Tag
5676
color='secondary'
5777
status='line'
58-
size='basic'
78+
size='small'
5979
content='내가 썼어요'
6080
className='w-fit font-bold'
6181
/>
6282
)}
63-
</span>
64-
65-
<span className={`flex items-center`}>
66-
{isCommentOfPickAuthor ? (
67-
<Image src={writerIcon} alt={'작성자 아이콘'} className='mr-[0.8rem]' />
68-
) : null}
69-
<NicknameWithMaskedEmail author={author} maskedEmail={maskedEmail} textSize='p2' />
70-
</span>
71-
<time className={`text-gray300 ${isMobile ? '' : 'mx-[1.6rem]'}`}>
72-
{formatISOtoDate(createdAt || '')}
73-
</time>
83+
</div>
7484

75-
{isCommentAuthor && !isMobile && (
76-
<Tag
77-
color='secondary'
78-
status='line'
79-
size='small'
80-
content='내가 썼어요'
81-
className='w-fit font-bold'
82-
/>
85+
{isDeleted || isEditActived || moreButtonList.length === 0 ? null : (
86+
<span className='mr-[1rem]'>
87+
<MoreButton moreButtonList={moreButtonList} type='small' />
88+
</span>
8389
)}
8490
</div>
85-
86-
{isDeleted || isEditActived || moreButtonList.length === 0 ? null : (
87-
<span className='mr-[1rem]'>
88-
<MoreButton moreButtonList={moreButtonList} type='small' />
89-
</span>
90-
)}
9191
</div>
9292
);
9393
}

pages/pickpickpick/[id]/components/Comment.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ export default function Comment({
272272
<div
273273
id={`comment-${pickCommentId}`}
274274
ref={commentRef}
275-
className={`flex flex-col gap-[2.4rem] pt-[2.4rem] pb-[3.2rem] px-[1.6rem]
275+
className={`flex flex-col gap-[1.6rem] pt-[2.4rem] pb-[3.2rem] px-[1.6rem]
276276
${isSubComment && (isMobile ? 'px-[1.6rem]' : 'px-[3.2rem]')}
277277
${commentContainerStyle()}
278278
${commentId === String(pickCommentId) ? 'comment-item' : ''}
@@ -309,7 +309,7 @@ export default function Comment({
309309
parentCommentAuthor={getPickParentCommentAuthor()}
310310
/>
311311

312-
<div className='mr-0 flex gap-[0.8rem]'>
312+
<div className='mr-0 flex gap-[0.8rem] mt-[0.8rem]'>
313313
<ReplyButton
314314
isActived={isReplyActived}
315315
setIsActived={setIsReplyActived}

0 commit comments

Comments
 (0)