diff --git a/app/(site)/@modal/(.)i/image/[...info]/page.tsx b/app/(site)/@modal/(.)i/image/[...info]/page.tsx index 98060c7..4b78c28 100644 --- a/app/(site)/@modal/(.)i/image/[...info]/page.tsx +++ b/app/(site)/@modal/(.)i/image/[...info]/page.tsx @@ -1,4 +1,4 @@ -import { MovieImageModal } from '@/widgets/modal/section' +import { MovieImageModal } from '@/widgets/modal' type Props = { params: { info: [movieId: string, 'poster' | 'backdrop', imageUrl: string] } diff --git a/app/(site)/@modal/(.)i/info/[movieId]/page.tsx b/app/(site)/@modal/(.)i/info/[movieId]/page.tsx index 18068ff..f785bf9 100644 --- a/app/(site)/@modal/(.)i/info/[movieId]/page.tsx +++ b/app/(site)/@modal/(.)i/info/[movieId]/page.tsx @@ -1,4 +1,4 @@ -import { MovieDetailModal } from '@/widgets/modal/section' +import { MovieDetailModal } from '@/widgets/modal' type Props = { params: { diff --git a/app/(site)/i/image/[...info]/page.tsx b/app/(site)/i/image/[...info]/page.tsx index 3c870bd..b690b5f 100644 --- a/app/(site)/i/image/[...info]/page.tsx +++ b/app/(site)/i/image/[...info]/page.tsx @@ -1,4 +1,4 @@ -import { MovieImageModal } from '@/widgets/modal/section' +import { MovieImageModal } from '@/widgets/modal' type Props = { params: { info: [string, 'backdrop' | 'poster', string] } diff --git a/app/(site)/i/info/[movieId]/page.tsx b/app/(site)/i/info/[movieId]/page.tsx index 01c8098..d9dc324 100644 --- a/app/(site)/i/info/[movieId]/page.tsx +++ b/app/(site)/i/info/[movieId]/page.tsx @@ -1,6 +1,6 @@ 'use client' -import { MovieDetailModal } from '@/widgets/modal/section' +import { MovieDetailModal } from '@/widgets/modal' type Props = { params: { diff --git a/app/(site)/layout.tsx b/app/(site)/layout.tsx index 8f1473c..bc1bb64 100644 --- a/app/(site)/layout.tsx +++ b/app/(site)/layout.tsx @@ -1,6 +1,6 @@ import { ReactNode } from 'react' -import { Footer, Header } from '@/widgets/layout/section' +import { Outlet } from '@/widgets/layout' import styles from './layout.module.scss' @@ -13,9 +13,7 @@ export default function Layout({ children, modal }: Props) { return (
{modal} -
- {children} -
) } diff --git a/public/jpg/default-profile-image.jpg b/public/jpg/default-profile-image.jpg new file mode 100644 index 0000000..4fc3d65 Binary files /dev/null and b/public/jpg/default-profile-image.jpg differ diff --git a/src/widgets/detail/ui/DetailMovieContentContainer.tsx b/src/entities/content/ui/DetailMovieContentContainer.tsx similarity index 93% rename from src/widgets/detail/ui/DetailMovieContentContainer.tsx rename to src/entities/content/ui/DetailMovieContentContainer.tsx index 05f64da..68e05f6 100644 --- a/src/widgets/detail/ui/DetailMovieContentContainer.tsx +++ b/src/entities/content/ui/DetailMovieContentContainer.tsx @@ -1,8 +1,8 @@ 'use client' import { generateContents } from '@/entities/mock/generate' -import { OneMovieContent } from '@/entities/movie/ui' import { DetailContentForm } from '@/features/detail/DetailContentForm' +import { OneMovieContent } from '@/widgets/content' import styles from './detail-movie-content-container.module.scss' diff --git a/src/widgets/detail/ui/detail-movie-content-container.module.scss b/src/entities/content/ui/detail-movie-content-container.module.scss similarity index 100% rename from src/widgets/detail/ui/detail-movie-content-container.module.scss rename to src/entities/content/ui/detail-movie-content-container.module.scss diff --git a/src/widgets/detail/ui/index.ts b/src/entities/content/ui/index.ts similarity index 51% rename from src/widgets/detail/ui/index.ts rename to src/entities/content/ui/index.ts index c0a6102..c89c1a5 100644 --- a/src/widgets/detail/ui/index.ts +++ b/src/entities/content/ui/index.ts @@ -1,2 +1 @@ export { DetailMovieContentContainer } from './DetailMovieContentContainer' -export { DetailMovieImageContainer } from './DetailMovieImageContainer' diff --git a/src/entities/mock/data/movie-detail.mock.ts b/src/entities/mock/data/movie-detail.mock.ts index 115399f..513bcc4 100644 --- a/src/entities/mock/data/movie-detail.mock.ts +++ b/src/entities/mock/data/movie-detail.mock.ts @@ -42,13 +42,13 @@ export const movieDetailMock = { production_companies: [ { id: 521, - logo_path: '/kP7t6RwGz2AvvTkvnI1uteEwHet.png', + logo_path: '/kP7t6RwGz2AvvTkvnI1uteEwHet.jpg', name: 'DreamWorks Animation', origin_country: 'US', }, { id: 33, - logo_path: '/8lvHyhjr8oUKOOy2dKXoALWKdp0.png', + logo_path: '/8lvHyhjr8oUKOOy2dKXoALWKdp0.jpg', name: 'Universal Pictures', origin_country: 'US', }, diff --git a/src/widgets/detail/section/TopSection.tsx b/src/entities/movie/ui/DetailMovieBanner.tsx similarity index 93% rename from src/widgets/detail/section/TopSection.tsx rename to src/entities/movie/ui/DetailMovieBanner.tsx index 8099b62..e6caeec 100644 --- a/src/widgets/detail/section/TopSection.tsx +++ b/src/entities/movie/ui/DetailMovieBanner.tsx @@ -10,13 +10,13 @@ import { IMAGE_SIZE } from '@/shared/constants' import { MOVIE_QUERY_KEY } from '@/shared/constants/QUERY_KEY' import { quando } from '@/shared/font/quando' -import styles from './top-section.module.scss' +import styles from './detail-movie-banner.module.scss' type Props = { movieId: string } -export function DetailTopSection({ movieId }: Readonly) { +export function DetailMovieBanner({ movieId }: Readonly) { const queryKey = MOVIE_QUERY_KEY.detail(movieId) as [string, string, string] const { data: result } = useSuspenseQuery({ queryKey: queryKey, diff --git a/src/widgets/detail/ui/DetailMovieImageContainer.tsx b/src/entities/movie/ui/DetailMovieImageContainer.tsx similarity index 95% rename from src/widgets/detail/ui/DetailMovieImageContainer.tsx rename to src/entities/movie/ui/DetailMovieImageContainer.tsx index 0d35e62..9cf808d 100644 --- a/src/widgets/detail/ui/DetailMovieImageContainer.tsx +++ b/src/entities/movie/ui/DetailMovieImageContainer.tsx @@ -3,9 +3,9 @@ import { useSuspenseQuery } from '@tanstack/react-query' import { getImages } from '@/entities/movie/api' -import { OneMovieImage } from '@/entities/movie/ui' import { MOVIE_QUERY_KEY } from '@/shared/constants' import { useDragHandler } from '@/shared/hook' +import { OneMovieImage } from '@/widgets/movie' import styles from './detail-movie-image.container.module.scss' diff --git a/src/widgets/detail/section/MiddleSection.tsx b/src/entities/movie/ui/DetailMovieIntro.tsx similarity index 94% rename from src/widgets/detail/section/MiddleSection.tsx rename to src/entities/movie/ui/DetailMovieIntro.tsx index 62e7e6f..bd007f1 100644 --- a/src/widgets/detail/section/MiddleSection.tsx +++ b/src/entities/movie/ui/DetailMovieIntro.tsx @@ -11,13 +11,13 @@ import { poppins } from '@/shared/font' import { Chip } from '@/shared/ui' import { getDecimal, getHour } from '@/shared/util' -import styles from './middle-section.module.scss' +import styles from './detail-movie-intro-section.module.scss' type Props = { movieId: string } -export function DetailMiddleSection({ movieId }: Readonly) { +export function DetailMovieIntro({ movieId }: Readonly) { const queryKey = MOVIE_QUERY_KEY.detail(movieId) as [string, string, string] const { data: result } = useSuspenseQuery({ queryKey, diff --git a/src/widgets/main/ui/MainMovieBanner.tsx b/src/entities/movie/ui/MainMovieBanner.tsx similarity index 100% rename from src/widgets/main/ui/MainMovieBanner.tsx rename to src/entities/movie/ui/MainMovieBanner.tsx diff --git a/src/widgets/main/ui/MainMovieList.tsx b/src/entities/movie/ui/MainMovieList.tsx similarity index 95% rename from src/widgets/main/ui/MainMovieList.tsx rename to src/entities/movie/ui/MainMovieList.tsx index be97661..0c34c4e 100644 --- a/src/widgets/main/ui/MainMovieList.tsx +++ b/src/entities/movie/ui/MainMovieList.tsx @@ -2,8 +2,8 @@ import { useSuspenseQuery } from '@tanstack/react-query' import Link from 'next/link' import { MoviesResponse } from '@/entities/movie/model' -import { OneMovieCard } from '@/entities/movie/ui' import { useDragHandler } from '@/shared/hook' +import { OneMovieCard } from '@/widgets/movie' import styles from './main-movie-list.module.scss' diff --git a/src/widgets/modal/ui/MovieDetailContent.tsx b/src/entities/movie/ui/MovieDetailContent.tsx similarity index 100% rename from src/widgets/modal/ui/MovieDetailContent.tsx rename to src/entities/movie/ui/MovieDetailContent.tsx diff --git a/src/widgets/list/ui/MovieInfinityList.tsx b/src/entities/movie/ui/MovieInfinityList.tsx similarity index 96% rename from src/widgets/list/ui/MovieInfinityList.tsx rename to src/entities/movie/ui/MovieInfinityList.tsx index d51c400..4c11be9 100644 --- a/src/widgets/list/ui/MovieInfinityList.tsx +++ b/src/entities/movie/ui/MovieInfinityList.tsx @@ -7,7 +7,7 @@ import { useEffect } from 'react' import { useInView } from 'react-intersection-observer' import { MovieRequest, MoviesResponse } from '@/entities/movie/model' -import { OneMovieCard } from '@/entities/movie/ui/OneMovieCard' +import { OneMovieCard } from '@/widgets/movie' import styles from './movie-infinity-list.module.scss' diff --git a/src/widgets/search/section/SearchBottomSection.tsx b/src/entities/movie/ui/SearchInfinityList.tsx similarity index 89% rename from src/widgets/search/section/SearchBottomSection.tsx rename to src/entities/movie/ui/SearchInfinityList.tsx index 8a68cca..5d8c8cd 100644 --- a/src/widgets/search/section/SearchBottomSection.tsx +++ b/src/entities/movie/ui/SearchInfinityList.tsx @@ -6,16 +6,16 @@ import { useEffect } from 'react' import { useInView } from 'react-intersection-observer' import { getMovieSearch } from '@/entities/movie/api' -import { OneMovieSearchCard } from '@/entities/movie/ui/OneMovieSearchCard' import { MOVIE_QUERY_KEY } from '@/shared/constants' +import { OneMovieSearchCard } from '@/widgets/movie' -import styles from './search-bottom-section.module.scss' +import styles from './search-infinity-list.module.scss' type Props = { keyword: string } -export function SearchBottomSection({ keyword }: Readonly) { +export function SearchInfinityList({ keyword }: Readonly) { const { ref, inView } = useInView() const queryKey = MOVIE_QUERY_KEY.search(keyword) as [string, string, keyword: string] const { data, fetchNextPage, isFetching, hasNextPage } = useInfiniteQuery({ diff --git a/src/widgets/detail/section/top-section.module.scss b/src/entities/movie/ui/detail-movie-banner.module.scss similarity index 100% rename from src/widgets/detail/section/top-section.module.scss rename to src/entities/movie/ui/detail-movie-banner.module.scss diff --git a/src/widgets/detail/ui/detail-movie-image.container.module.scss b/src/entities/movie/ui/detail-movie-image.container.module.scss similarity index 100% rename from src/widgets/detail/ui/detail-movie-image.container.module.scss rename to src/entities/movie/ui/detail-movie-image.container.module.scss diff --git a/src/widgets/detail/section/middle-section.module.scss b/src/entities/movie/ui/detail-movie-intro-section.module.scss similarity index 100% rename from src/widgets/detail/section/middle-section.module.scss rename to src/entities/movie/ui/detail-movie-intro-section.module.scss diff --git a/src/entities/movie/ui/index.ts b/src/entities/movie/ui/index.ts index f6e71f4..a820899 100644 --- a/src/entities/movie/ui/index.ts +++ b/src/entities/movie/ui/index.ts @@ -1,4 +1,8 @@ -export { OneMovieCard } from './OneMovieCard' -export { OneMovieContent } from './OneMovieContent' -export { OneMovieImage } from './OneMovieImage' -export { OneMovieSearchCard } from './OneMovieSearchCard' +export { DetailMovieBanner } from './DetailMovieBanner' +export { DetailMovieImageContainer } from './DetailMovieImageContainer' +export { DetailMovieIntro } from './DetailMovieIntro' +export { MainMovieBanner } from './MainMovieBanner' +export { MainMovieList } from './MainMovieList' +export { MovieDetailContent } from './MovieDetailContent' +export { MovieInfinityList } from './MovieInfinityList' +export { SearchInfinityList } from './SearchInfinityList' diff --git a/src/widgets/main/ui/main-movie-banner.module.scss b/src/entities/movie/ui/main-movie-banner.module.scss similarity index 100% rename from src/widgets/main/ui/main-movie-banner.module.scss rename to src/entities/movie/ui/main-movie-banner.module.scss diff --git a/src/widgets/main/ui/main-movie-list.module.scss b/src/entities/movie/ui/main-movie-list.module.scss similarity index 100% rename from src/widgets/main/ui/main-movie-list.module.scss rename to src/entities/movie/ui/main-movie-list.module.scss diff --git a/src/widgets/modal/ui/movie-detail-content.module.scss b/src/entities/movie/ui/movie-detail-content.module.scss similarity index 100% rename from src/widgets/modal/ui/movie-detail-content.module.scss rename to src/entities/movie/ui/movie-detail-content.module.scss diff --git a/src/widgets/list/ui/movie-infinity-list.module.scss b/src/entities/movie/ui/movie-infinity-list.module.scss similarity index 100% rename from src/widgets/list/ui/movie-infinity-list.module.scss rename to src/entities/movie/ui/movie-infinity-list.module.scss diff --git a/src/widgets/search/section/search-bottom-section.module.scss b/src/entities/movie/ui/search-infinity-list.module.scss similarity index 100% rename from src/widgets/search/section/search-bottom-section.module.scss rename to src/entities/movie/ui/search-infinity-list.module.scss diff --git a/src/features/profile/ui/EditButton.tsx b/src/features/profile/ui/EditButton.tsx deleted file mode 100644 index f0efd37..0000000 --- a/src/features/profile/ui/EditButton.tsx +++ /dev/null @@ -1,26 +0,0 @@ -'use client' - -import { Edit } from '@mui/icons-material' -import classNames from 'classnames' -import { motion } from 'framer-motion' -import { ChangeEventHandler } from 'react' - -import styles from './edit-button.module.scss' - -type Props = { - onChange: ChangeEventHandler -} - -export function EditButton({ onChange }: Props) { - return ( - - - - - ) -} diff --git a/src/features/profile/ui/ProfileImageChangeButton.tsx b/src/features/profile/ui/ProfileImageChangeButton.tsx new file mode 100644 index 0000000..3ab5b87 --- /dev/null +++ b/src/features/profile/ui/ProfileImageChangeButton.tsx @@ -0,0 +1,34 @@ +'use client' + +import { Edit } from '@mui/icons-material' +import classNames from 'classnames' +import { motion } from 'framer-motion' + +import { useImageOnChange } from '@/features/profile/hooks' +import { ProfileImage } from '@/shared/ui' + +import styles from './profile-image-changeButton.module.scss' + +type Props = { + profileUrl: string + nickname: string +} + +export function ProfileImageChangeButton({ profileUrl, nickname }: Props) { + const { onChange } = useImageOnChange() + + return ( +
+ + + + + +
+ ) +} diff --git a/src/features/profile/ui/index.ts b/src/features/profile/ui/index.ts new file mode 100644 index 0000000..54a6a7c --- /dev/null +++ b/src/features/profile/ui/index.ts @@ -0,0 +1 @@ +export { ProfileImageChangeButton } from './ProfileImageChangeButton' diff --git a/src/features/profile/ui/edit-button.module.scss b/src/features/profile/ui/profile-image-change-button.module.scss similarity index 100% rename from src/features/profile/ui/edit-button.module.scss rename to src/features/profile/ui/profile-image-change-button.module.scss diff --git a/src/widgets/landing/constants/subtitle.ts b/src/shared/constants/LANDING_TITLE.ts similarity index 97% rename from src/widgets/landing/constants/subtitle.ts rename to src/shared/constants/LANDING_TITLE.ts index 5603561..ce4604c 100644 --- a/src/widgets/landing/constants/subtitle.ts +++ b/src/shared/constants/LANDING_TITLE.ts @@ -1,4 +1,4 @@ -export const subTitleList = [ +export const LANDING_TITLE = [ '최신 영화 소식과 함께, 당신의 다음 영화 여행을 위한 시작점입니다.', '지금 어떤 영화가 뜨고 있는지 확인하고, 영화 팬들과 함께 소통하세요.', '영화의 감동을 함께 나누는 곳, 누구나 즐길 수 있는 영화 커뮤니티입니다.', diff --git a/src/shared/constants/index.ts b/src/shared/constants/index.ts index e254544..f821040 100644 --- a/src/shared/constants/index.ts +++ b/src/shared/constants/index.ts @@ -1,4 +1,5 @@ export { GENRES } from './GENRES' export { IMAGE_SIZE } from './IMAGE_SIZE' +export { LANDING_TITLE } from './LANDING_TITLE' export { MOVIE_QUERY_KEY } from './QUERY_KEY' export { SITE_PATH } from './SITE_PATH' diff --git a/src/shared/util/getImageWithDefault.ts b/src/shared/util/getImageWithDefault.ts new file mode 100644 index 0000000..44376c2 --- /dev/null +++ b/src/shared/util/getImageWithDefault.ts @@ -0,0 +1,5 @@ +export function getImageWithDefault(url: string | null | undefined) { + if (!url) return '/jpg/default-profile-image.jpg' + + return url +} diff --git a/src/shared/util/index.ts b/src/shared/util/index.ts index 5254b62..4373de5 100644 --- a/src/shared/util/index.ts +++ b/src/shared/util/index.ts @@ -1,4 +1,5 @@ export { getDecimal } from './get-decimal' export { getHour } from './get-hours' export { getScrollbarWidth } from './get-scroll-bar-width' +export { getImageWithDefault } from './getImageWithDefault' export { timeAgo } from './time-age' diff --git a/src/views/DetailPage.tsx b/src/views/DetailPage.tsx index 616d3cc..5530e16 100644 --- a/src/views/DetailPage.tsx +++ b/src/views/DetailPage.tsx @@ -1,8 +1,9 @@ import { Suspense } from 'react' +import { DetailMovieContentContainer } from '@/entities/content/ui' +import { DetailMovieBanner, DetailMovieImageContainer, DetailMovieIntro } from '@/entities/movie/ui' import { RQProvider } from '@/shared/ui' -import { DetailBottomSection, DetailMiddleSection, DetailTopSection } from '@/widgets/detail/section' -import { DetailPageSkeleton } from '@/widgets/detail/skeleton' +import { DetailPageSkeleton } from '@/widgets/detail' type Props = { movieId: string @@ -12,9 +13,10 @@ export function DetailPage({ movieId }: Props) { return ( }> - - - + + + + ) diff --git a/src/views/LandingPage.tsx b/src/views/LandingPage.tsx index ee92e18..6071d06 100644 --- a/src/views/LandingPage.tsx +++ b/src/views/LandingPage.tsx @@ -1,5 +1,4 @@ -import { LandingContents } from '@/widgets/landing/section' -import { LandingBackGround } from '@/widgets/landing/ui' +import { LandingBackGround, LandingContents } from '@/widgets/landing' export function LandingPage() { return ( diff --git a/src/views/MainPage.tsx b/src/views/MainPage.tsx index 4e8b287..5582483 100644 --- a/src/views/MainPage.tsx +++ b/src/views/MainPage.tsx @@ -1,4 +1,4 @@ -import { MainBottomSection, MainTopSection } from '@/widgets/main/section' +import { MainBottomSection, MainTopSection } from '@/widgets/main' export function MainPage() { return ( diff --git a/src/views/NotFoundPage.tsx b/src/views/NotFoundPage.tsx index 1661eb0..1169f09 100644 --- a/src/views/NotFoundPage.tsx +++ b/src/views/NotFoundPage.tsx @@ -1,4 +1,4 @@ -import { NotFoundBottom, NotFoundTop } from '@/widgets/not-found/section' +import { NotFoundBottom, NotFoundTop } from '@/widgets/not-found' export function NotFoundPage() { return ( diff --git a/src/views/SearchPage.tsx b/src/views/SearchPage.tsx index 435a032..f972c5e 100644 --- a/src/views/SearchPage.tsx +++ b/src/views/SearchPage.tsx @@ -1,8 +1,8 @@ import { Suspense } from 'react' +import { SearchInfinityList } from '@/entities/movie/ui' import { RQProvider } from '@/shared/ui' -import { SearchBottomSection, SearchTopSection } from '@/widgets/search/section' -import { SearchBottomSkeleton } from '@/widgets/search/skeleton' +import { SearchBottomSkeleton, SearchTopSection } from '@/widgets/search' type Props = { keyword: string @@ -14,7 +14,7 @@ export function SearchPage({ keyword }: Props) { }> - + diff --git a/src/views/listPage.tsx b/src/views/listPage.tsx index 32c56cc..f58ea0c 100644 --- a/src/views/listPage.tsx +++ b/src/views/listPage.tsx @@ -1,6 +1,5 @@ import { MovieType } from '@/entities/movie/model/movie' -import { InfinityListAdapter } from '@/widgets/list/section/InfinityListAdapter' -import { InfinityListHeader } from '@/widgets/list/section/InfinityListHeader' +import { InfinityListAdapter, InfinityListHeader } from '@/widgets/list' type Props = { type: MovieType diff --git a/src/entities/movie/ui/OneMovieContent.tsx b/src/widgets/content/OneMovieContent.tsx similarity index 100% rename from src/entities/movie/ui/OneMovieContent.tsx rename to src/widgets/content/OneMovieContent.tsx diff --git a/src/widgets/content/index.ts b/src/widgets/content/index.ts new file mode 100644 index 0000000..b4d1f40 --- /dev/null +++ b/src/widgets/content/index.ts @@ -0,0 +1 @@ +export { OneMovieContent } from './OneMovieContent' diff --git a/src/entities/movie/ui/one-movie-content.module.scss b/src/widgets/content/one-movie-content.module.scss similarity index 100% rename from src/entities/movie/ui/one-movie-content.module.scss rename to src/widgets/content/one-movie-content.module.scss diff --git a/src/widgets/detail/skeleton/DetailPageSkeleton.tsx b/src/widgets/detail/DetailPageSkeleton.tsx similarity index 93% rename from src/widgets/detail/skeleton/DetailPageSkeleton.tsx rename to src/widgets/detail/DetailPageSkeleton.tsx index 7d2be84..fecd42b 100644 --- a/src/widgets/detail/skeleton/DetailPageSkeleton.tsx +++ b/src/widgets/detail/DetailPageSkeleton.tsx @@ -3,10 +3,10 @@ import { Skeleton } from '@mui/material' import classNames from 'classnames' +import top_styles from '@/entities/movie/ui/detail-movie-banner.module.scss' +import middle_styles from '@/entities/movie/ui/detail-movie-intro-section.module.scss' import { poppins } from '@/shared/font' import { useBlockScroll } from '@/shared/hook/use-block-scroll' -import middle_styles from '@/widgets/detail/section/middle-section.module.scss' -import top_styles from '@/widgets/detail/section/top-section.module.scss' export function DetailPageSkeleton() { useBlockScroll() diff --git a/src/widgets/detail/skeleton/index.ts b/src/widgets/detail/index.ts similarity index 100% rename from src/widgets/detail/skeleton/index.ts rename to src/widgets/detail/index.ts diff --git a/src/widgets/detail/section/BottomSection.tsx b/src/widgets/detail/section/BottomSection.tsx deleted file mode 100644 index f013db7..0000000 --- a/src/widgets/detail/section/BottomSection.tsx +++ /dev/null @@ -1,14 +0,0 @@ -import { DetailMovieContentContainer, DetailMovieImageContainer } from '@/widgets/detail/ui' - -type Props = { - movieId: string -} - -export function DetailBottomSection({ movieId }: Props) { - return ( - <> - - - - ) -} diff --git a/src/widgets/detail/section/index.ts b/src/widgets/detail/section/index.ts deleted file mode 100644 index ddf0b39..0000000 --- a/src/widgets/detail/section/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export { DetailBottomSection } from './BottomSection' -export { DetailMiddleSection } from './MiddleSection' -export { DetailTopSection } from './TopSection' diff --git a/src/widgets/landing/ui/LandingBackGround.tsx b/src/widgets/landing/LandingBackGround.tsx similarity index 100% rename from src/widgets/landing/ui/LandingBackGround.tsx rename to src/widgets/landing/LandingBackGround.tsx diff --git a/src/widgets/landing/LandingContents.tsx b/src/widgets/landing/LandingContents.tsx new file mode 100644 index 0000000..660f412 --- /dev/null +++ b/src/widgets/landing/LandingContents.tsx @@ -0,0 +1,23 @@ +'use client' + +import classNames from 'classnames' +import { motion } from 'framer-motion' + +import { LANDING_TITLE } from '@/shared/constants' +import { poppins } from '@/shared/font' +import { HomeButton } from '@/shared/ui' +import { SubTitle } from '@/widgets/landing/SubTitle' + +import styles from './landing-contents.module.scss' + +export function LandingContents() { + return ( +
+
+ Movie Connect + + +
+
+ ) +} diff --git a/src/widgets/landing/ui/SubTitle.tsx b/src/widgets/landing/SubTitle.tsx similarity index 100% rename from src/widgets/landing/ui/SubTitle.tsx rename to src/widgets/landing/SubTitle.tsx diff --git a/src/widgets/landing/constants/index.ts b/src/widgets/landing/constants/index.ts deleted file mode 100644 index 852a1af..0000000 --- a/src/widgets/landing/constants/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { subTitleList } from './subtitle' diff --git a/src/widgets/landing/ui/index.ts b/src/widgets/landing/index.ts similarity index 64% rename from src/widgets/landing/ui/index.ts rename to src/widgets/landing/index.ts index 137c7a1..7524ab7 100644 --- a/src/widgets/landing/ui/index.ts +++ b/src/widgets/landing/index.ts @@ -1,3 +1,3 @@ -export { GithubIcon } from './GithubIcon' export { LandingBackGround } from './LandingBackGround' +export { LandingContents } from './LandingContents' export { SubTitle } from './SubTitle' diff --git a/src/widgets/landing/ui/landing-back-ground.module.scss b/src/widgets/landing/landing-back-ground.module.scss similarity index 100% rename from src/widgets/landing/ui/landing-back-ground.module.scss rename to src/widgets/landing/landing-back-ground.module.scss diff --git a/src/widgets/landing/section/landing-left-section.module.scss b/src/widgets/landing/landing-contents.module.scss similarity index 56% rename from src/widgets/landing/section/landing-left-section.module.scss rename to src/widgets/landing/landing-contents.module.scss index 47398bc..ce5387c 100644 --- a/src/widgets/landing/section/landing-left-section.module.scss +++ b/src/widgets/landing/landing-contents.module.scss @@ -1,4 +1,16 @@ .container { + display: flex; + width: 100%; + height: 100%; + max-width: 1000px; + align-items: center; + margin: 0 auto; + position: relative; + z-index: 1; + justify-content: space-between; +} + +.box { height: 600px; display: flex; gap: 12px; @@ -17,3 +29,4 @@ display: flex; gap: 10px; } + diff --git a/src/widgets/landing/section/LandingContents.tsx b/src/widgets/landing/section/LandingContents.tsx deleted file mode 100644 index 9b0f35d..0000000 --- a/src/widgets/landing/section/LandingContents.tsx +++ /dev/null @@ -1,12 +0,0 @@ -import { LandingLeftSection } from '@/widgets/landing/section/LandingLeftSection' - -import styles from './landing-contents.module.scss' - -export function LandingContents() { - return ( -
- - {/**/} -
- ) -} diff --git a/src/widgets/landing/section/LandingLeftSection.tsx b/src/widgets/landing/section/LandingLeftSection.tsx deleted file mode 100644 index f09af49..0000000 --- a/src/widgets/landing/section/LandingLeftSection.tsx +++ /dev/null @@ -1,21 +0,0 @@ -'use client' - -import classNames from 'classnames' -import { motion } from 'framer-motion' - -import { poppins } from '@/shared/font' -import { HomeButton } from '@/shared/ui/HomeButton' -import { subTitleList } from '@/widgets/landing/constants/subtitle' -import { SubTitle } from '@/widgets/landing/ui/SubTitle' - -import styles from './landing-left-section.module.scss' - -export function LandingLeftSection() { - return ( -
- Movie Connect - - -
- ) -} diff --git a/src/widgets/landing/section/LandingRightSection.tsx b/src/widgets/landing/section/LandingRightSection.tsx deleted file mode 100644 index b067ab5..0000000 --- a/src/widgets/landing/section/LandingRightSection.tsx +++ /dev/null @@ -1,12 +0,0 @@ -import classNames from 'classnames' - -import styles from './landing-right-section.module.scss' - -export function LandingRightSection() { - return ( -
-
1
-
2
-
- ) -} diff --git a/src/widgets/landing/section/index.ts b/src/widgets/landing/section/index.ts deleted file mode 100644 index 2892ec7..0000000 --- a/src/widgets/landing/section/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export { LandingContents } from './LandingContents' -export { LandingLeftSection } from './LandingLeftSection' -export { LandingRightSection } from './LandingRightSection' diff --git a/src/widgets/landing/section/landing-contents.module.scss b/src/widgets/landing/section/landing-contents.module.scss deleted file mode 100644 index 846125b..0000000 --- a/src/widgets/landing/section/landing-contents.module.scss +++ /dev/null @@ -1,11 +0,0 @@ -.container { - display: flex; - width: 100%; - height: 100%; - max-width: 1000px; - align-items: center; - margin: 0 auto; - position: relative; - z-index: 1; - justify-content: space-between; -} diff --git a/src/widgets/landing/section/landing-right-section.module.scss b/src/widgets/landing/section/landing-right-section.module.scss deleted file mode 100644 index 5793df6..0000000 --- a/src/widgets/landing/section/landing-right-section.module.scss +++ /dev/null @@ -1,15 +0,0 @@ -.container { - display: flex; - align-items: center; - justify-content: center; - gap: 20px; - height: 300px; -} - -.card { - width: 400px; - height: 100%; - max-width: 280px; - max-height: 480px; - border: 2px solid red; -} diff --git a/src/widgets/landing/ui/subtitle.module.scss b/src/widgets/landing/subtitle.module.scss similarity index 100% rename from src/widgets/landing/ui/subtitle.module.scss rename to src/widgets/landing/subtitle.module.scss diff --git a/src/widgets/landing/ui/GithubIcon.tsx b/src/widgets/landing/ui/GithubIcon.tsx deleted file mode 100644 index a2ae5e8..0000000 --- a/src/widgets/landing/ui/GithubIcon.tsx +++ /dev/null @@ -1,16 +0,0 @@ -import { Github } from 'lucide-react' -import Link from 'next/link' - -import styles from './github-icon.module.scss' - -type Props = { - href: string -} - -export function GithubIcon({ href }: Props) { - return ( - - - - ) -} diff --git a/src/widgets/landing/ui/github-icon.module.scss b/src/widgets/landing/ui/github-icon.module.scss deleted file mode 100644 index e711826..0000000 --- a/src/widgets/landing/ui/github-icon.module.scss +++ /dev/null @@ -1,9 +0,0 @@ -.iconBox { - display: flex; - justify-content: center; - align-items: center; - width: 50px; - aspect-ratio: 1/1; - border-radius: 9999px; - background-color: white; -} diff --git a/src/widgets/layout/section/Footer.tsx b/src/widgets/layout/Footer.tsx similarity index 100% rename from src/widgets/layout/section/Footer.tsx rename to src/widgets/layout/Footer.tsx diff --git a/src/widgets/layout/ui/GuestButtons.tsx b/src/widgets/layout/GuestButtons.tsx similarity index 100% rename from src/widgets/layout/ui/GuestButtons.tsx rename to src/widgets/layout/GuestButtons.tsx diff --git a/src/widgets/layout/section/Header.tsx b/src/widgets/layout/Header.tsx similarity index 76% rename from src/widgets/layout/section/Header.tsx rename to src/widgets/layout/Header.tsx index 9ce3a85..472ad43 100644 --- a/src/widgets/layout/section/Header.tsx +++ b/src/widgets/layout/Header.tsx @@ -3,13 +3,12 @@ import classNames from 'classnames' import { useEffect, useState } from 'react' -import { GuestButtons } from '@/widgets/layout/ui/GuestButtons' -import { HeaderNav } from '@/widgets/layout/ui/HeaderNav' -import { HeaderSearchBar } from '@/widgets/layout/ui/HeaderSearchBar' -import { MainLogo } from '@/widgets/layout/ui/MainLogo' -import { UserButton } from '@/widgets/layout/ui/UserButton' - +import { GuestButtons } from './GuestButtons' import styles from './header.module.scss' +import { HeaderNav } from './HeaderNav' +import { HeaderSearchBar } from './HeaderSearchBar' +import { MainLogo } from './MainLogo' +import { UserButton } from './UserButton' export function Header() { const [isHeaderHidden, setIsHeaderHidden] = useState(false) diff --git a/src/widgets/layout/ui/HeaderNav.tsx b/src/widgets/layout/HeaderNav.tsx similarity index 96% rename from src/widgets/layout/ui/HeaderNav.tsx rename to src/widgets/layout/HeaderNav.tsx index 7e37a2e..ef2eed5 100644 --- a/src/widgets/layout/ui/HeaderNav.tsx +++ b/src/widgets/layout/HeaderNav.tsx @@ -8,9 +8,9 @@ import StarIcon from '@mui/icons-material/Star' import StarBorderOutlinedIcon from '@mui/icons-material/StarBorderOutlined' import { SITE_PATH } from '@/shared/constants' -import { NavButton } from '@/widgets/layout/ui/NavButton' import styles from './header-nav.module.scss' +import { NavButton } from './NavButton' export function HeaderNav() { return ( diff --git a/src/widgets/layout/ui/HeaderSearchBar.tsx b/src/widgets/layout/HeaderSearchBar.tsx similarity index 100% rename from src/widgets/layout/ui/HeaderSearchBar.tsx rename to src/widgets/layout/HeaderSearchBar.tsx diff --git a/src/widgets/layout/ui/MainLogo.tsx b/src/widgets/layout/MainLogo.tsx similarity index 100% rename from src/widgets/layout/ui/MainLogo.tsx rename to src/widgets/layout/MainLogo.tsx diff --git a/src/widgets/layout/ui/NavButton.tsx b/src/widgets/layout/NavButton.tsx similarity index 100% rename from src/widgets/layout/ui/NavButton.tsx rename to src/widgets/layout/NavButton.tsx diff --git a/src/widgets/layout/Outlet.tsx b/src/widgets/layout/Outlet.tsx new file mode 100644 index 0000000..2f16777 --- /dev/null +++ b/src/widgets/layout/Outlet.tsx @@ -0,0 +1,14 @@ +import { PropsWithChildren } from 'react' + +import { Footer } from '@/widgets/layout/Footer' +import { Header } from '@/widgets/layout/Header' + +export function Outlet({ children }: PropsWithChildren) { + return ( + <> +
+ {children} +