Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
86 commits
Select commit Hold shift + click to select a range
c99c8cd
feat: setting
YooSeonHo Nov 7, 2022
b5fe24d
Parsing error : Cannot find module 'next/babel 해결
Nov 7, 2022
3fcee9c
Merge pull request #1 from Teample-next-netflix-16th/ch9eri
ch9eri Nov 7, 2022
ffb3188
chore : setting styled-components
YooSeonHo Nov 8, 2022
2466e93
chore : axios set up
YooSeonHo Nov 8, 2022
9e48f50
chore : prettierrc set up
YooSeonHo Nov 8, 2022
0b8fb9e
style : Top Navbar
YooSeonHo Nov 9, 2022
d5c904f
[FEAT] api 파일
Nov 9, 2022
0008b97
feat : api pull and movies page
YooSeonHo Nov 9, 2022
bc52b97
feat: data 출력
Nov 9, 2022
484108c
feat: data 출력 + aapi 업데이트
Nov 9, 2022
06a8c28
feat : change structure and get poster
YooSeonHo Nov 10, 2022
933a044
chore : back to prev struct
YooSeonHo Nov 10, 2022
45e1c13
feat : add movie categories
YooSeonHo Nov 10, 2022
8ca9d5c
feat: previews pososter
Nov 10, 2022
89b53d0
feat: 메인페이지 포스터 전체 출력
Nov 10, 2022
ea65062
feat: 랜덤 이미지 띄우기
Nov 10, 2022
ac27916
chore : temporary push
YooSeonHo Nov 10, 2022
a09a04f
chore: 이미지 크기 수정
Nov 10, 2022
3f851c0
style : footer fin
YooSeonHo Nov 10, 2022
acd70b0
chore: change favicon
Nov 10, 2022
663d68a
feat: content in box
YooSeonHo Nov 10, 2022
e44c4c5
style : change poster size
YooSeonHo Nov 10, 2022
fa7be38
feat: 랜딩화면 연결
Nov 10, 2022
1f330b5
chore: css 수정
Nov 10, 2022
3fcbdab
chore : margin
YooSeonHo Nov 10, 2022
efd845a
chore: 필요없는 css 제거
Nov 10, 2022
8b8da1f
chore : min-width box
YooSeonHo Nov 10, 2022
6d13e8e
chore: 충돌 해결
Nov 10, 2022
fd93590
feat : Mid Buttons
YooSeonHo Nov 10, 2022
ab8c15d
chore: footer pixel 차이 수정
Nov 10, 2022
cf56508
feat: 랜덤 이미지 영화 제목 출력
Nov 10, 2022
46ce6a1
❌ 그라데이션 적용 실패 (아시는 분 ...)
Nov 10, 2022
3c85360
chore : change font color
YooSeonHo Nov 10, 2022
799f007
feat: title 설정
Nov 10, 2022
4a4ce4c
Merge pull request #2 from Teample-next-netflix-16th/ch9eri
ch9eri Nov 10, 2022
f3249d1
Merge branch 'Teample' into YooSeonHo
YooSeonHo Nov 10, 2022
d9ecbc8
Merge pull request #3 from Teample-next-netflix-16th/YooSeonHo
YooSeonHo Nov 10, 2022
f4da084
style : change poster
YooSeonHo Nov 11, 2022
9399521
Merge pull request #4 from Teample-next-netflix-16th/YooSeonHo
YooSeonHo Nov 11, 2022
5d7ef11
style : footer fininsh!!!!!!!!!
YooSeonHo Nov 11, 2022
342fed0
chore : 뒷정리
YooSeonHo Nov 11, 2022
315e796
Merge pull request #5 from Teample-next-netflix-16th/YooSeonHo
YooSeonHo Nov 11, 2022
948e468
fix: img 렌더 에러 해결
Nov 11, 2022
7168b69
vercel 배포
Nov 11, 2022
42b11a8
Merge pull request #7 from Teample-next-netflix-16th/ch9eri
ch9eri Nov 11, 2022
650369a
feat: search page 기본 구조
Nov 16, 2022
642790c
feat: footer link 추가 (Hydration failed ERR)
Nov 16, 2022
806c93a
feat: search list 출력
Nov 16, 2022
593c82d
feat: 단순 검색 기능 구현
Nov 16, 2022
3fdf03f
feat: input의 X버튼 활성화
Nov 16, 2022
4817f4f
style: css 수정
Nov 16, 2022
75e4d2b
fix: 긴 title ...생략 표시
Nov 16, 2022
909deda
fix: rouuter구조 ..
Nov 16, 2022
ae9e18f
feat: detail page
YooSeonHo Nov 16, 2022
22d491f
Merge pull request #10 from Teample-next-netflix-16th/ch9eri
ch9eri Nov 16, 2022
97d97d4
chore : conflict fin zz
YooSeonHo Nov 16, 2022
f4a4857
Merge pull request #11 from Teample-next-netflix-16th/YooSeonHo
ch9eri Nov 16, 2022
3dabb72
chore : install recoil
YooSeonHo Nov 16, 2022
c5446a7
feat: bottom navbar color set
YooSeonHo Nov 17, 2022
148274d
feat: 실시간 검색 기능 ... 해결 중
Nov 17, 2022
989dcfa
chore: 충돌해결
Nov 17, 2022
092d961
chore : before merge
YooSeonHo Nov 17, 2022
4afd007
fix : Link error
YooSeonHo Nov 17, 2022
728a4f0
ERR
Nov 17, 2022
9465134
err
YooSeonHo Nov 17, 2022
37fae06
err
Nov 17, 2022
c1c5d7f
feat : search page
YooSeonHo Nov 17, 2022
0f85216
fix : router
YooSeonHo Nov 17, 2022
5717535
fix : router
YooSeonHo Nov 17, 2022
60af93c
err 해결
Nov 17, 2022
7db110f
Merge pull request #12 from Teample-next-netflix-16th/YooSeonHo
YooSeonHo Nov 17, 2022
36ab23b
feat: search-detail page 연결
Nov 17, 2022
a9cfff7
Merge branch 'Teample' into ch9eri
ch9eri Nov 17, 2022
17bbdf0
Merge pull request #14 from Teample-next-netflix-16th/ch9eri
ch9eri Nov 17, 2022
2a5a10e
search 초기화면 err solve?
Nov 17, 2022
bde3cfb
vercel
Nov 18, 2022
25e594b
chore : merge
YooSeonHo Nov 18, 2022
36610ee
feat : search page fix fin!!!!!!!!!!
YooSeonHo Nov 18, 2022
89787e6
Merge pull request #15 from Teample-next-netflix-16th/YooSeonHo
YooSeonHo Nov 18, 2022
8ef0976
to pull
Nov 18, 2022
dc1059a
pull
Nov 18, 2022
9f7b167
fix: 엑박 해결
Nov 18, 2022
491eca5
Merge pull request #16 from Teample-next-netflix-16th/ch9eri
ch9eri Nov 18, 2022
1a96c67
vercel
Nov 18, 2022
c6fa708
Merge pull request #17 from Teample-next-netflix-16th/ch9eri
ch9eri Nov 18, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions nextflix/.babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"presets": ["next/babel"],
"plugins": [
[
"babel-plugin-styled-components",
{
"ssr": true, // SSR을 위한 설정
"displayName": true, // 클래스명에 컴포넌트 이름을 붙임
"pure": true // dead code elimination (사용되지 않는 속성 제거)
}
]
]
}
3 changes: 3 additions & 0 deletions nextflix/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": ["next/babel", "next/core-web-vitals"]
}
36 changes: 36 additions & 0 deletions nextflix/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.pnpm-debug.log*

# local env files
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
6 changes: 6 additions & 0 deletions nextflix/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"trailingComma": "es5",
"tabWidth": 2,
"semi": true,
"singleQuote": true
}
14 changes: 14 additions & 0 deletions nextflix/.vscode/c_cpp_properties.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"configurations": [
{
"name": "macos-gcc-x64",
"includePath": ["${workspaceFolder}/**"],
"compilerPath": "/usr/bin/clang",
"cStandard": "${default}",
"cppStandard": "${default}",
"intelliSenseMode": "macos-gcc-x64",
"compilerArgs": []
}
],
"version": 4
}
18 changes: 18 additions & 0 deletions nextflix/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "C/C++ Runner: Debug Session",
"type": "cppdbg",
"request": "launch",
"args": [""],
"stopAtEntry": true,
"cwd": "/Users/imchaeli/ch9eri/Documents/채리/CEOS/5주차/next-netflix-16th/nextflix",
"environment": [],
"program": "/Users/imchaeli/ch9eri/Documents/채리/CEOS/5주차/next-netflix-16th/nextflix/build/Debug/outDebug",
"internalConsoleOptions": "openOnSessionStart",
"MIMode": "gdb",
"externalConsole": true
}
]
}
23 changes: 23 additions & 0 deletions nextflix/.vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"C_Cpp_Runner.cCompilerPath": "/usr/bin/clang",
"C_Cpp_Runner.cppCompilerPath": "/usr/bin/clang++",
"C_Cpp_Runner.debuggerPath": "/usr/bin/lldb",
"C_Cpp_Runner.cStandard": "",
"C_Cpp_Runner.cppStandard": "",
"C_Cpp_Runner.msvcBatchPath": "",
"C_Cpp_Runner.warnings": ["-Wall", "-Wextra", "-Wpedantic"],
"C_Cpp_Runner.enableWarnings": true,
"C_Cpp_Runner.warningsAsError": false,
"C_Cpp_Runner.compilerArgs": [],
"C_Cpp_Runner.linkerArgs": [],
"C_Cpp_Runner.includePaths": [],
"C_Cpp_Runner.includeSearch": ["*", "**/*"],
"C_Cpp_Runner.excludeSearch": [
"**/build",
"**/build/**",
"**/.*",
"**/.*/**",
"**/.vscode",
"**/.vscode/**"
]
}
34 changes: 34 additions & 0 deletions nextflix/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app).

## Getting Started

First, run the development server:

```bash
npm run dev
# or
yarn dev
```

Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.

You can start editing the page by modifying `pages/index.js`. The page auto-updates as you edit the file.

[API routes](https://nextjs.org/docs/api-routes/introduction) can be accessed on [http://localhost:3000/api/hello](http://localhost:3000/api/hello). This endpoint can be edited in `pages/api/hello.js`.

The `pages/api` directory is mapped to `/api/*`. Files in this directory are treated as [API routes](https://nextjs.org/docs/api-routes/introduction) instead of React pages.

## Learn More

To learn more about Next.js, take a look at the following resources:

- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.

You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js/) - your feedback and contributions are welcome!

## Deploy on Vercel

The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.

Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details.
83 changes: 83 additions & 0 deletions nextflix/components/ui/Footer/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
import styled from 'styled-components';
import { RiHome2Line, RiSearchLine } from 'react-icons/ri';
import { HiDownload } from 'react-icons/hi';
import { BsList } from 'react-icons/bs';
import { MdOutlineVideoLibrary } from 'react-icons/md';
import { useRouter } from 'next/router';
import { useRecoilState } from 'recoil';
import { NowState } from '../../../states/states';

const BtmNav = styled.footer`
width: 400px;
height: 8vh;
background-color: #121212;
display: flex;
justify-content: space-between;
align-items: center;
z-index: 998;
position: fixed;
bottom: 0;
left: 0;
right: 0;
margin: auto;
`;

const Icon = styled.div`
cursor: pointer;
color: ${(props) => (props.Isnow == props.id ? 'white' : '#8c8787')};
// color : grey;
display: flex;
flex-direction: column;
align-items: center;
margin: auto;
a {
font-size: 10px;
}
:active {
color: white;
}
`;

const Footer = () => {
const routing = { 0: '/home', 1: '/search' };
const [now, setNow] = useRecoilState(NowState);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

오 이런식으로 현재 선택되었는지를 알 수도 있겠네요!! 아직 recoil이 익숙하지 않아서 생각지도 못했어요..
router.pathname 요 방법도 참고해보시면 좋을 것 같아요 -!!


const router = useRouter();

const ChangeNow = (e) => {
setNow(e.currentTarget.id);
router.push(routing[e.currentTarget.id]);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

router.push()를 이용하는 경우 a태그를 만들지 않기 때문에 크롤링되지 않아서 SEO에 불리하다고 하네요!!
근데 Link가 왜 오류가 났을까요...🥲

};
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

우와 각 id 값을 숫자로 주니까 코드가 되게 깔끔해지네요...!


const ChangeIsNow = (e) => {
setNow(e.currentTarget.id);
};
return (
<BtmNav>
<Icon id="0" Isnow={now} onClick={ChangeNow}>
<RiHome2Line size={25} />
<a>Home</a>
</Icon>

<Icon id="1" Isnow={now} onClick={ChangeNow}>
<RiSearchLine size={25} />
<a>Search</a>
</Icon>
<Icon id="2" Isnow={now} onClick={ChangeIsNow}>

<MdOutlineVideoLibrary size={25} />
<a>Coming Soon</a>
</Icon>
<Icon id="3" Isnow={now} onClick={ChangeIsNow}>
<HiDownload size={25} />
<a>Downloads</a>
</Icon>
<Icon id="4" Isnow={now} onClick={ChangeIsNow}>
<BsList size={25} />
<a>More</a>
</Icon>
</BtmNav>
);
};

export default Footer;
Binary file added nextflix/components/ui/Layout/Netflix-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
35 changes: 35 additions & 0 deletions nextflix/components/ui/Layout/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
import styled from 'styled-components';
import Footer from '../Footer';

const Box = styled.div`
position: relative;
display: flex;
width: 400px;
height: 100vh;
background-color: black;
margin: auto;
min-width:375px
min-height: 100%;
padding-bottom: 67px;
`;
const Children = styled.div`
position: absolute;
width: 100%;
height: 100%;
overflow: scroll;
z-index: 997;
padding-bottom: 8vh;
`;

const Layout = ({ children }) => {
return (
<>
<Box>
<Children>{children}</Children>
</Box>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

깔끔하네요...... 🙀

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

완전 깔끔,,,

<Footer />
</>
);
};

export default Layout;
57 changes: 57 additions & 0 deletions nextflix/components/ui/MidBtn/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
import styled from 'styled-components';
import { AiOutlinePlus, AiOutlineInfoCircle } from 'react-icons/ai';
import { BsFillPlayFill } from 'react-icons/bs';

const BtnBox = styled.div`
display: flex;
justify-content: space-evenly;
height: 45px;
margin-top: 10px;
`;

const IconBox = styled.div`
cursor: pointer;
color: #ffffff;
display: flex;
flex-direction: column;
align-items: center;
margin: auto;
a {
font-size: 10px;
}
`;

const PlayBox = styled.div`
display: flex;
align-items: center;
width: 110px;
background-color: #c4c4c4;
border-radius: 5.625px;
color: black;
justify-content: space-evenly;

a {
font-size: 20px;
}
`;

const MidBtn = () => {
return (
<BtnBox>
<IconBox>
<AiOutlinePlus size={25} />
<a>My List</a>
</IconBox>
<PlayBox>
<BsFillPlayFill size={25} className="playBtn" />
<a>Play</a>
</PlayBox>
<IconBox>
<AiOutlineInfoCircle size={25} />
<a>Info</a>
</IconBox>
</BtnBox>
);
};

export default MidBtn;
47 changes: 47 additions & 0 deletions nextflix/components/ui/TopNav/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
import styled from 'styled-components';
import Logo from '../../../public/images/Netflix-logo.png';
import Image from 'next/image';

const TopNavbar = styled.nav`
position: absolute;
margin-top: 10%;
width: 100%;
height: 8%;
display: flex;
justify-content: space-between;
opacity: 100;
margin-left: 10px;
margin-right: 20px;
z-index: 998;

a {
text-align: center;
color: white;
height: 54px;
margin-right: 25px;
font-weight: 400;
font-size: 17.1968px;
cursor: pointer;
margin-top: 10px;
}
`;

const Home = styled.div`
cursor: pointer;
margin-left: 10px;
margin-top: 0px;
`;

const TopNav = () => {
return (
<TopNavbar>
<Home>
<Image src={Logo} alt="netflix logo" width={30} height={40} />
</Home>
<a>TV Shows</a>
<a>Movies</a>
<a>My List</a>
</TopNavbar>
);
};
export default TopNav;
6 changes: 6 additions & 0 deletions nextflix/next.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: true,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

저는 console.log()가 렌더링 2번 되서 아래 글 보고 reactStrictMode false로 바꿨는데 잘 되시나요 ㅠㅠ 나만 그런건가 ㅠㅠ
참고링크

};

module.exports = nextConfig;
Loading