-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* New : tailwind css 적용 * Refactor : 모달 패딩 제거 * Fix : 모달 컴포넌트 이벤트 버블링 방지 * new: 디테일페이지 퍼블리싱 * new : 클라이언트 패스 추가 * Refactor: 해시태그 컴포넌트 분리 * new : 모달페이지 이동 hooks 추가 * New : 검색페이지 라우트 추가 * Fix : 해시태그 클릭시 모달이 닫히지 않는 버그 수정 * Fix : useRouter Mock 추가
- Loading branch information
1 parent
335a186
commit c852214
Showing
11 changed files
with
230 additions
and
90 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
"use client"; | ||
|
||
import { usePathname } from "next/navigation"; | ||
|
||
export default function Layout({ children }: any) { | ||
const pathname = usePathname(); | ||
return pathname.startsWith("/post/") ? children : null; | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
const SearchPage = ({ | ||
searchParams, | ||
}: { | ||
searchParams?: { [key: string]: string | string[] | undefined }; | ||
}) => { | ||
return <div>{searchParams?.keyword}</div>; | ||
}; | ||
|
||
export default SearchPage; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import { SEARCH_BY_KEYWORD } from "@/const/clientPath"; | ||
import { PostInterface } from "@/types/post/PostInterface"; | ||
import { Box, BoxProps, Typography } from "@mui/material"; | ||
import Link from "next/link"; | ||
|
||
interface TagListInterface extends BoxProps { | ||
tags: PostInterface["tags"]; | ||
} | ||
const PostHashTagList = ({ tags, ...others }: TagListInterface) => { | ||
return ( | ||
<> | ||
{tags?.length > 0 && ( | ||
<Box | ||
data-testid="tags" | ||
sx={{ | ||
pt: 2, | ||
display: "flex", | ||
flexDirection: "row", | ||
gap: "8px", | ||
}} | ||
{...others} | ||
> | ||
{tags.map((tag) => ( | ||
<Link href={SEARCH_BY_KEYWORD(tag)} key={tag}> | ||
<Typography | ||
component={"span"} | ||
variant={"label"} | ||
color="text.secondary" | ||
> | ||
{`#${tag}`} | ||
</Typography> | ||
</Link> | ||
))} | ||
</Box> | ||
)} | ||
</> | ||
); | ||
}; | ||
|
||
export default PostHashTagList; |
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
Oops, something went wrong.