-
Notifications
You must be signed in to change notification settings - Fork 0
[OD-169] PostImageSelect, PostUpload 리팩토링 #125
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
Merged
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 함수 정의 사이에 ref 변수가 있습니다 순서 조정 부탁드려용 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -13,8 +13,7 @@ import { postIdAtom, userAtom, isPostRepresentativeAtom } from '@recoil/Post/Pos | |
| import { getCurrentUserId } from '@utils/getCurrentUserId'; | ||
|
|
||
| import Left from '@assets/arrow/left.svg'; | ||
| import LikeFill from '@assets/default/like-fill.svg'; | ||
| import Like from '@assets/default/like.svg'; | ||
| import Like from '@components/Icons/Like'; | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 이 부분 외에도 린트를 적용해 수정해야 하는 부분들이 보입니다! 전체적인 점검 부탁드립니닷 |
||
| import Message from '@assets/default/message.svg'; | ||
| import More from '@assets/default/more.svg'; | ||
|
|
||
|
|
@@ -164,10 +163,18 @@ const PostBase: React.FC<PostBaseProps> = ({ onClickMenu }) => { | |
| <UserProfile onClick={handleUserClick}> | ||
| {post?.user && <img src={post.user.profilePictureUrl} alt="profileImg" />} | ||
| </UserProfile> | ||
| <UserName onClick={handleUserClick} $textTheme={{ style: 'body2-medium' }} color={theme.colors.black}> | ||
| <UserName | ||
| onClick={handleUserClick} | ||
| $textTheme={{ style: 'body2-medium' }} | ||
| color={theme.colors.text.primary} | ||
| > | ||
| {user.nickname} | ||
| </UserName> | ||
| <StyledText className="timeAgo" $textTheme={{ style: 'caption2-regular' }} color={theme.colors.gray3}> | ||
| <StyledText | ||
| className="timeAgo" | ||
| $textTheme={{ style: 'caption2-regular' }} | ||
| color={theme.colors.text.tertiary} | ||
| > | ||
| {timeAgo} | ||
| </StyledText> | ||
| <MenuBtn onClick={onClickMenu}> | ||
|
|
@@ -177,16 +184,18 @@ const PostBase: React.FC<PostBaseProps> = ({ onClickMenu }) => { | |
|
|
||
| {!post ? <ImageSkeleton /> : <ImageSwiper images={post.postImages.map((image) => image.url)} />} | ||
|
|
||
| <ClothingInfoList className="post-mode"> | ||
| {post?.postClothings?.map((clothingObj, index) => ( | ||
| <ClothingInfoItem key={index} clothingObj={clothingObj} /> | ||
| ))} | ||
| </ClothingInfoList> | ||
| {post?.postClothings && ( | ||
| <ClothingInfoList className="post-mode"> | ||
| {post.postClothings.map((clothingObj, index) => ( | ||
| <ClothingInfoItem key={index} clothingObj={clothingObj} /> | ||
| ))} | ||
| </ClothingInfoList> | ||
| )} | ||
|
|
||
| <IconRow> | ||
| <IconWrapper> | ||
| <Icon onClick={togglePostLikeStatus}> | ||
| {post?.isPostLike ? <img src={LikeFill} alt="like" /> : <img src={Like} alt="like" />} | ||
| {post?.isPostLike ? <Like isFilled={true} color={theme.colors.brand.primary} /> : <Like />} | ||
| </Icon> | ||
| <span onClick={() => handleLikeCommentOpen('likes')}>{post?.postLikesCount ?? 0}</span> | ||
| </IconWrapper> | ||
|
|
@@ -208,7 +217,7 @@ const PostBase: React.FC<PostBaseProps> = ({ onClickMenu }) => { | |
| onClick={toggleTextDisplay} | ||
| $showFullText={showFullText} | ||
| $textTheme={{ style: 'body4-light' }} | ||
| color={theme.colors.black} | ||
| color={theme.colors.text.primary} | ||
| > | ||
| {post.content} | ||
| </Content> | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
저희가 정한 import문 규칙 상 상대경로가 아래로 가는 것이 맞습니다! 린트 적용해서 수정 부탁드립니당