Skip to content

Commit

Permalink
๐Ÿงช Test: ์ฟ ํ‚ค ๋ฌธ์ œ ํ™•์ธ์„ ์œ„ํ•œ ํ…Œ์ŠคํŠธ ๋ฐฐํฌ
Browse files Browse the repository at this point in the history
๐Ÿงช Test: ์ฟ ํ‚ค ๋ฌธ์ œ ํ™•์ธ์„ ์œ„ํ•œ ํ…Œ์ŠคํŠธ ๋ฐฐํฌ
  • Loading branch information
Youngbae1126 authored Mar 5, 2024
2 parents 6520b03 + 9a02900 commit b314988
Show file tree
Hide file tree
Showing 91 changed files with 5,417 additions and 1,391 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,6 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*

localhost-key.pem
localhost.pem
87 changes: 45 additions & 42 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,44 +1,47 @@
{
"name": "fe-test",
"version": "0.1.0",
"private": true,
"dependencies": {
"@testing-library/jest-dom": "^5.14.1",
"@testing-library/react": "^13.0.0",
"@testing-library/user-event": "^13.2.1",
"axios": "^1.6.7",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-hook-form": "^7.49.3",
"react-router-dom": "6",
"react-scripts": "5.0.1",
"styled-components": "^6.1.6",
"styled-reset": "^4.5.1",
"swiper": "^11.0.5",
"web-vitals": "^2.1.0"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
]
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}
"name": "fe-test",
"version": "0.1.0",
"private": true,
"dependencies": {
"@testing-library/jest-dom": "^5.14.1",
"@testing-library/react": "^13.0.0",
"@testing-library/user-event": "^13.2.1",
"axios": "^1.6.7",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-hook-form": "^7.49.3",
"react-router-dom": "6",
"react-scripts": "5.0.1",
"styled-components": "^6.1.6",
"styled-reset": "^4.5.1",
"swiper": "^11.0.5",
"web-vitals": "^2.1.0"
},
"scripts": {
"start": "cross-env HTTPS=true SSL_CRT_FILE=localhost.pem SSL_KEY_FILE=localhost-key.pem react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
]
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"cross-env": "^7.0.3"
}
}
Binary file added public/images/login/login_bg.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
41 changes: 21 additions & 20 deletions public/index.html
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta
name="description"
content="Web site created using create-react-app"
/>
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
<!--
<head>
<meta charset="utf-8" />
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta
name="description"
content="Web site created using create-react-app"
/>
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<!--
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
Expand All @@ -24,12 +24,13 @@
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>React App</title>
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<!--
<title>React App</title>
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<div id="modal"></div>
<!--
This HTML file is a template.
If you open it directly in the browser, you will see an empty page.
Expand All @@ -39,5 +40,5 @@
To begin the development, run `npm start` or `yarn start`.
To create a production bundle, use `npm run build` or `yarn build`.
-->
</body>
</body>
</html>
5 changes: 5 additions & 0 deletions src/App.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
@import url('https://webfontworld.github.io/gmarket/GmarketSans.css');

@font-face {
font-family: 'recipekorea';
src: url('./font/Recipekorea\ ๋ ˆ์ฝ”์ฒด\ FONT.ttf');
}

/* Header */

header {
Expand Down
78 changes: 50 additions & 28 deletions src/App.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
import React, { useEffect, useState } from 'react';
import React, { useEffect } from 'react';
import { BrowserRouter, Route, Routes } from 'react-router-dom';

// PAGES
import Home from './pages/Home';
import Main from './pages/LoginHome';
import Feed from './pages/Feed';
import MyFeed from './pages/MyFeed';
import Search from './pages/Search';
import Mypage from './pages/Mypage';
import BookDetail from './pages/BookDetail';
import Login from './pages/Login';
import Join from './pages/Join';
import Join2 from './pages/Join2';
import Signup2 from './pages/Signup2';
import Signup3 from './pages/Signup3';
import FindUserInfo from './pages/FindUserInfo';
import Registration from './pages/Registration';
import BookList from './pages/BookList';
import SmallCategory from './pages/SmallCategory';
Expand All @@ -21,6 +24,12 @@ import UserInfo from './pages/UserInfo';
import GlobalStyles from './styles/GlobalStyles';
import './App.css';
import ScrollTop from './components/ScrollTop';
import LoginLayout from './components/LoginLayout';
import LoginFindResult from './pages/IdFindResult';
import PasswordFind from './pages/PasswordFind';
import PasswordFindResult from './pages/PasswordFindResult';
import IdFind from './pages/IdFind';
import LoginContextProvider, { LoginContext } from './contexts/LoginContextProvider';

function App() {
// ๋ธŒ๋ผ์šฐ์ € ์ƒˆ๋กœ๊ณ ์นจ ์Šคํฌ๋กค ์ด๋ฒคํŠธ
Expand All @@ -30,35 +39,48 @@ function App() {
};
}, []);

let [category, setCategory] = useState('์†Œ์„ค');

https: return (
<BrowserRouter>
<div className="App">
<GlobalStyles />
<ScrollTop />
<Routes>
<Route path="/" element={<Home />} />
<Route path="/logout" element={<Home />} />
<Route path="/main" element={<Main />} />
<Route path="/feed" element={<Feed />} />
<Route path="/search" element={<Search />} />
<Route path="/mypage" element={<Mypage />} />
<Route path="/edit" element={<Edit />} />
<Route path="/edit/:page" element={<UserInfo />} />
<BrowserRouter>
<LoginContextProvider>
<div className="App">
<GlobalStyles />
<ScrollTop />
<Routes>
<Route path="/" element={<Home />} />
<Route path="/logout" element={<Home />} />
<Route path="/main" element={<Main />} />
<Route path="/feed" element={<Feed />} />
<Route path="/search" element={<Search />} />
<Route path="/mypage" element={<Mypage />} />
<Route path="/myfeed" element={<MyFeed />} />
<Route path="/edit" element={<Edit />} />
<Route path="/edit/:page" element={<UserInfo />} />

<Route path="/login" element={<Login />} />
<Route path="/join" element={<Join />} />
<Route path="/join2" element={<Join2 />} />
<Route path="/test" element={<Registration />} />
<Route element={<LoginLayout />}>
<Route path="/id-find" element={<IdFind />} />
<Route path="/id-find-result" element={<LoginFindResult />} />
<Route path="/password-find" element={<PasswordFind />} />
<Route
path="/password-find-result"
element={<PasswordFindResult />}
/>
</Route>
<Route path="/test" element={<Registration />} />
<Route path="/login" element={<Login />} />
<Route path="/signup" element={<Join />} />
<Route path="/signup/1" element={<Signup2 />} />
<Route path="/signup/2" element={<Signup3 />} />
{/* <Route path="/find/user/info/:page" element={<FindUserInfo />} /> */}
<Route path="/test" element={<Registration />} />

<Route path="/book-detail" element={<BookDetail />} />
<Route path="/book/list/:title" element={<BookList />} />
<Route path="/book/:title/:category" element={<SmallCategory />} />
</Routes>
</div>
</BrowserRouter>
);
<Route path="/book-detail" element={<BookDetail />} />
<Route path="/book/list/:title" element={<BookList />} />
<Route path="/book/:title/:category" element={<SmallCategory />} />
</Routes>
</div>
</LoginContextProvider>
</BrowserRouter>
);
}

export default App;
Binary file added src/assets/Login-Banner.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed src/assets/category-book-img2.png
Binary file not shown.
Binary file removed src/assets/category-book-img3.png
Binary file not shown.
Binary file removed src/assets/category-book-img4.png
Binary file not shown.
Binary file removed src/assets/category-book-img5.png
Binary file not shown.
Binary file removed src/assets/category-book-img6.png
Binary file not shown.
Binary file removed src/assets/category-book-img7.png
Binary file not shown.
Binary file removed src/assets/category-book-img8.png
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/category-book-์–ธ์–ด.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/category-book-์—ญ์‚ฌ.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/category-book-์˜ˆ์ˆ .jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/category-book-์ข…๊ต.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/category-book-์ฒ ํ•™.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/category-book-์ด๋ฅ˜.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/interest_category_art.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/interest_category_general.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/interest_category_history.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/interest_category_language.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/interest_category_literature.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/interest_category_natural-science.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/interest_category_philosophy.png
Binary file added src/assets/interest_category_religion.png
Binary file added src/assets/interest_category_tech.png
17 changes: 13 additions & 4 deletions src/components/BookDetailCard.jsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,21 @@
import { Link } from 'react-router-dom';
import React, { useState, useEffect } from 'react';
import { Link, useSearchParams } from 'react-router-dom';

//COMPONENTS
import HashTag from '../components/HashTag';

//STYLES
import '../styles/BookDetailCard.css';

const BookDetailCard = () => {
const BookDetailCard = ({ title, author }) => {
const [searchParams, setSearchParams] = useSearchParams();
const bookTitle = searchParams.get('title');
// console.log('title:', bookTitle);

// useEffect(() => {
// setSearchParams({ who: 'bb' });
// });

return (
<>
<Link to={'/book-detail'}>
Expand All @@ -17,8 +26,8 @@ const BookDetailCard = () => {
</div>
<div className="bookCard_right_wrapper">
<div className="bookCard_right_up_wrapper">
<div className="right_up_title">์ฑ… ์ œ๋ชฉ</div>
<div className="right_up_author">์ €์ž</div>
<div className="right_up_title">{title}</div>
<div className="right_up_author">{author}</div>
</div>
<div className="bookCard_right_bottom_wrapper">
<HashTag text={'ํ–‰๋ณต'} type="sm-category" />
Expand Down
7 changes: 4 additions & 3 deletions src/components/BookListSlide.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { useState, useEffect } from 'react';
import axios from 'axios';

// COMPONENTS
import Title from './ArrowTitle';
Expand All @@ -7,14 +8,14 @@ import BookCard from './BookCard';
// STYLES
import styles from '../styles/BookListSlide.module.css';

const BookListSlide = ({ bigCategory, title, author }) => {
const BookListSlide = ({ bigCategory, midCategoryTitle, author }) => {
return (
<>
<div className={styles['container']}>
<Title bigCategory={bigCategory} title={title} />
<Title bigCategory={bigCategory} title={midCategoryTitle} />
<div className={styles['slide']}>
<BookCard title={'์ฑ… ์ œ๋ชฉ'} author={author} />
<BookCard title={'์ฑ… ์ œ๋ชฉ'} author={'์ €์ž'} />
<BookCard title={'์ฑ… ์ œ๋ชฉ'} author={author} />
<BookCard title={'์ฑ… ์ œ๋ชฉ'} author={'์ €์ž'} />
<BookCard title={'์ฑ… ์ œ๋ชฉ'} author={'์ €์ž'} />
<BookCard title={'์ฑ… ์ œ๋ชฉ'} author={'์ €์ž'} />
Expand Down
39 changes: 0 additions & 39 deletions src/components/Button.js

This file was deleted.

Loading

0 comments on commit b314988

Please sign in to comment.