-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feat/backend integration bookmark (#83)
* feat: 북마크 생성 백엔드 연결 및 변수명 직관적으로 변경 수정사항 - 북마크 생성 백엔드 연결 - api.js의 좋아요 생성 변수명 변경 (postHeart -> createLike) - PostPage의 handleHeart <-> handleHeart 변수명 변경 * feat: 좋아요 및 북마크한 게시물의 색상 변화가 유지되도록 수정 수정사항 - 사용자가 좋아요 및 북마크한 게시물의 색상 변화, 즉 상태가 유지되도록 수정 * fix: 서버 데이터 구조 변경에 따른 북마크한 글 조회 오류 수정 수정사항 - 모든 북마크 조회 api 서버 데이터 구조가 바뀜에 따라, 북마크한 글 조회를 할 수 있게 조건부로 수정 * style: Prettier & ESLint 적용
- Loading branch information
Showing
6 changed files
with
155 additions
and
58 deletions.
There are no files selected for viewing
This file contains 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 |
---|---|---|
@@ -1,20 +1,26 @@ | ||
import * as React from "react"; | ||
import Svg, { Path } from "react-native-svg"; | ||
|
||
const IconBookmark = (props) => ( | ||
<Svg | ||
xmlns="http://www.w3.org/2000/svg" | ||
width={16} | ||
height={17} | ||
fill="none" | ||
{...props} | ||
> | ||
<Path | ||
fill="#CDCFD5" | ||
fillRule="evenodd" | ||
d="M10.451 7.146h-4.57a.5.5 0 0 1 0-1h4.57a.5.5 0 0 1 0 1Zm3.028 2.015-.002-1.374c0-5.063-.793-5.953-5.31-5.953-4.517 0-5.31.89-5.31 5.953L2.853 9.16c-.006 3.75-.009 5.154.564 5.726.185.186.431.28.73.28.637 0 1.345-.604 2.095-1.245.664-.567 1.417-1.21 1.924-1.21.507 0 1.26.643 1.923 1.21.75.64 1.458 1.245 2.095 1.245.3 0 .545-.094.73-.28.573-.572.57-1.976.565-5.726Z" | ||
clipRule="evenodd" | ||
/> | ||
</Svg> | ||
); | ||
import { CustomTheme } from "@styles/CustomTheme"; | ||
|
||
const IconBookmark = ({ props, active }) => { | ||
const color = active ? CustomTheme.pointYellow : CustomTheme.borderColor; | ||
return ( | ||
<Svg | ||
xmlns="http://www.w3.org/2000/svg" | ||
width={16} | ||
height={17} | ||
fill="none" | ||
{...props} | ||
> | ||
<Path | ||
fill={color} | ||
fillRule="evenodd" | ||
d="M10.451 7.146h-4.57a.5.5 0 0 1 0-1h4.57a.5.5 0 0 1 0 1Zm3.028 2.015-.002-1.374c0-5.063-.793-5.953-5.31-5.953-4.517 0-5.31.89-5.31 5.953L2.853 9.16c-.006 3.75-.009 5.154.564 5.726.185.186.431.28.73.28.637 0 1.345-.604 2.095-1.245.664-.567 1.417-1.21 1.924-1.21.507 0 1.26.643 1.923 1.21.75.64 1.458 1.245 2.095 1.245.3 0 .545-.094.73-.28.573-.572.57-1.976.565-5.726Z" | ||
clipRule="evenodd" | ||
/> | ||
</Svg> | ||
); | ||
}; | ||
|
||
export default IconBookmark; |
This file contains 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 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 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 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 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