Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Design: 로고, 파비콘, 공통문구, 사이드바 업데이트 #79

Merged
merged 3 commits into from
Nov 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Vite + React + TS</title>
<title>Hey놀자</title>
</head>
<body>
<div id="root"></div>
Expand Down
9 changes: 8 additions & 1 deletion public/vite.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions src/assets/svg/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions src/components/Category/CategoryBanner/index.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ describe("CategoryBanner", () => {
const wrapper = createRecoilWrapper();
const onChange = jest.fn();

const firstText = "거기어때?";
const firstText = "Hey 놀자!";
const secondText = "지금 둘러보세요.";

render(
Expand All @@ -30,7 +30,7 @@ describe("CategoryBanner", () => {
const onChange = jest.fn();
const user = userEvent;

const firstText = "거기어때?";
const firstText = "Hey 놀자!";
const secondText = "지금 둘러보세요.";

render(
Expand Down
15 changes: 3 additions & 12 deletions src/components/Common/Common.styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -193,13 +193,13 @@ export const SidebarWrapper = styled.div`

export const NavButton = styled.button`
display: block;

padding: 0.5rem;

outline: none;
appearance: none;
border: none;
background-color: #e6e6e6;
border-radius:20rem;
background-color: #fff;

color: white;
box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
Expand Down Expand Up @@ -229,13 +229,4 @@ export const NavButton = styled.button`
font-weight: 600;
text-align: center;
color: black;
`;

export const RecentlyViewedItem = styled.div`
padding: 1rem;

width: 4rem;
height: 6rem;

font-size: 0.8rem;
`;
`;
4 changes: 2 additions & 2 deletions src/components/Common/Header.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as Styled from "./Common.styles";
import Logo from "../../assets/image/logo.png";
import Logo from "../../assets/svg/logo.svg";
import SearchIcon from "../../assets/svg/search-icon.svg";
import CartIcon from "../../assets/svg/cart-icon.svg";
import UserIcon from "../../assets/svg/user-icon.svg";
Expand All @@ -15,7 +15,7 @@ const Header = () => {
return (
<Styled.headerContainer>
<a href="/">
<img src={Logo} alt="logo" style={{ width: "8em", height: "1.5em" }} />
<img src={Logo} alt="logo" />
</a>{" "}
<Styled.headerWrapper>
<button onClick={handleLogin}>
Expand Down
1 change: 0 additions & 1 deletion src/components/Common/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ function Sidebar() {
return (
<Styled.SidebarContainer>
<Styled.SidebarWrapper>
<Styled.RecentlyViewedItem>방금 본 숙소</Styled.RecentlyViewedItem>
<Styled.NavButton onClick={scrollToTop}>
<img src={ScrollToTopIcon} onClick={scrollToTop} />
TOP
Expand Down
4 changes: 4 additions & 0 deletions src/components/MyPage/MyOrder/MyOrderList/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,15 @@ import * as Styled from "./MyOrderList.styles";
import { useGetMyOrder } from "../../../../hooks/usePayment";
import MyOrderItemWrapper from "../MyOrderItemWrapper";
import { MyOrderListProps } from "./MyOrderList.type";
import Sidebar from "../../../Common/Sidebar";

const MyOrderList = () => {
const { data } = useGetMyOrder(); // 결제 이력 데이터 요청
console.log(data?.data.data);

return (
<>
<Sidebar />
<Styled.MyOrderList>
{data?.data.data.length > 0? (
data?.data.data
Expand All @@ -31,6 +34,7 @@ const MyOrderList = () => {
<div>아직 결제 완료한 숙소가 없어요!</div>
)}
</Styled.MyOrderList>
</>
);
};

Expand Down
1 change: 0 additions & 1 deletion src/hooks/usePayment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import { useMutation, useQuery } from "@tanstack/react-query";
export const usePayment = (orderId: number) => {
return useMutation({
mutationFn: (data: { payment_type: string }) => {
console.log(data);
return axios.post(`/api/v1/payments/${orderId}`, { data });
},
});
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Category/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const Category = () => {
return (
<Styled.CategoryContainer>
<CategoryBanner
firstText="거기어때?"
firstText="Hey 놀자!"
secondText="지금 둘러보세요."
searchFn={handleClickSearch}
/>
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Main/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const Main = () => {
<Sidebar />
<Styled.Container>
<Styled.Banner>
거기어때?
Hey 놀자!
<br /> 지금 둘러보세요. 👀
</Styled.Banner>

Expand Down