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

Feat: dialog 컴포넌트 추가 #357

Merged
merged 119 commits into from
Jun 16, 2024
Merged
Changes from 80 commits
Commits
Show all changes
119 commits
Select commit Hold shift + click to select a range
4352b81
fix: export 방식 변경
im-na0 Apr 21, 2024
449696c
style: muation 훅이 객체 반환하도록 변경
im-na0 Apr 21, 2024
36d161b
feat: icon 추가
im-na0 Apr 30, 2024
583b1e3
design: 상세페이지 별점, 성급 정보 섹션 추가, 전체적인 레이아웃 수정
im-na0 Apr 30, 2024
6da0d97
feat: 즉시구매, 가격 제안, 판매 취소, 받은 가격 제안 버튼 추가
im-na0 Apr 30, 2024
8847991
design: Tag 컴포넌트 구현
im-na0 Apr 30, 2024
9d1f398
feat: 요소 접힘-펼침 기능 구현
im-na0 Apr 30, 2024
08502d0
design: 폰트 사이즈 변경
im-na0 Apr 30, 2024
77f46a3
feat: 상세페이지 → 지도 페이지 라우터 추가
im-na0 Apr 30, 2024
840168d
feat: 주소 → 좌표변환 api 추가
im-na0 Apr 30, 2024
164ba21
feat: formatDateAndTime 유틸함수 추가
im-na0 Apr 30, 2024
d638d62
design: theme percentBlue 색상 변경
im-na0 Apr 30, 2024
666eb96
feat: 지도 페이지 구현
im-na0 Apr 30, 2024
9b755be
feat: kakaomap sdk 스크립트 추가
im-na0 Apr 30, 2024
04ba26b
design: ExpandableContent display: block으로 변경
im-na0 Apr 30, 2024
60ba98d
feat: 상세정보조회 서버 인터페이스 업데이트
im-na0 Apr 30, 2024
eb4c37b
feat: 추가정보 섹션 개행마다 잘라서 mapping하도록 구현
im-na0 Apr 30, 2024
1b8c6d1
refactor: tag 컴포넌트 icons prop 제거
im-na0 Apr 30, 2024
b1a36bc
style: path alias 변경에 따른 수정
im-na0 May 2, 2024
0adebec
refactor: styles 디렉터리 분리
im-na0 May 9, 2024
1550d08
feat: 바텀시트 ui 컴포넌트 추가
im-na0 May 9, 2024
8e2f590
doc: 바텀시트 stories 추가
im-na0 May 9, 2024
31c2c22
feat: 버튼 ui 컴포넌트 추가
im-na0 May 9, 2024
867c04b
doc: 버튼 stories 생성
im-na0 May 9, 2024
37fdcf6
feat: polymorphic 컴포넌트 d.ts 추가
im-na0 May 9, 2024
a5ebd15
feat: portal 컴포넌트 추가
im-na0 May 9, 2024
a1d3941
refactor: room nav bar Button 컴포넌트로 교체
im-na0 May 9, 2024
c604cf2
feat: 바텀 네비게이션 개선
Bumang-Cyber May 16, 2024
86335e6
chore: 불필요한 svgr/rollup 라이브러리 제거
Bumang-Cyber May 16, 2024
e3c58d3
design: global style #root 수정
im-na0 May 23, 2024
52271b8
refactor: Header 컴포넌트 text 프로퍼티 추가
im-na0 May 23, 2024
6421b6d
refactor: Layout 컴포넌트 구조 수정 및 bg 프로퍼티 추가
im-na0 May 23, 2024
6877b5a
feat: Typo 컴포넌트 추가
im-na0 May 23, 2024
63661cd
feat: wishlist 페이지 추가
im-na0 May 30, 2024
4b415fe
feat: heart-fill, heart svg 추가
im-na0 May 30, 2024
6d52dd6
feat: Layout 컴포넌트 padding 프로퍼티 추가
im-na0 May 30, 2024
ac0433d
design: 위시리스트 페이지 마크업
im-na0 May 30, 2024
165a692
feat: 찜 조회 api 인터페이스 추가
im-na0 May 30, 2024
200e9c1
design: 위시리스트 상품카드 마크업
im-na0 May 30, 2024
2e9b238
feat: 찜 등록, 삭제 api 및 쿼리 훅 추가
im-na0 May 30, 2024
49c8f97
chore: 더미데이터 업데이트
im-na0 May 30, 2024
b229fe8
chore: msw 등록
im-na0 May 30, 2024
8b74807
design: 가격제안 피봇 → 디자인 수정
im-na0 May 30, 2024
d1c17b8
fix: 로그인 상태에는 토큰을 사용하도록 수정
im-na0 Jun 13, 2024
a9d1255
fix: 잘못된 url로 요청 수정
im-na0 Jun 13, 2024
5beb794
feat: 찜 등록, 삭제, 조회 요청 훅 추가
im-na0 Jun 13, 2024
f101ac3
feat: 상세 페이지 좋아요 버튼 기능 연결
im-na0 Jun 13, 2024
6103415
feat: 상세 페이지 좋아요 버튼 적용
im-na0 Jun 13, 2024
820f4cf
feat: 위시리스트 페이지 Error Boundary & Suspense 적용
im-na0 Jun 13, 2024
f97bd5b
refactor: ProductType 인터페이스 변경
im-na0 Jun 13, 2024
9abcaf2
feat: 찜 조회 페이지 좋아요 버튼 기능 추가
im-na0 Jun 13, 2024
abe48b5
feat: 찜 조회 페이지 좋아요 버튼 적용
im-na0 Jun 13, 2024
f975d94
style: import order 적용
im-na0 Jun 13, 2024
3b077ce
style: path alias 변경에 따른 수정
im-na0 May 2, 2024
2eaab04
feat: wishlist 페이지 추가
im-na0 May 30, 2024
7c4d8de
feat: heart-fill, heart svg 추가
im-na0 May 30, 2024
347f23e
feat: Layout 컴포넌트 padding 프로퍼티 추가
im-na0 May 30, 2024
824e074
design: 위시리스트 페이지 마크업
im-na0 May 30, 2024
8dd47f2
feat: 찜 조회 api 인터페이스 추가
im-na0 May 30, 2024
9374007
design: 위시리스트 상품카드 마크업
im-na0 May 30, 2024
b57e0c2
feat: 찜 등록, 삭제 api 및 쿼리 훅 추가
im-na0 May 30, 2024
419fc2e
chore: 더미데이터 업데이트
im-na0 May 30, 2024
f8f1f40
chore: msw 등록
im-na0 May 30, 2024
319cbb5
design: 가격제안 피봇 → 디자인 수정
im-na0 May 30, 2024
8d3306f
fix: 로그인 상태에는 토큰을 사용하도록 수정
im-na0 Jun 13, 2024
bcc3d76
fix: 잘못된 url로 요청 수정
im-na0 Jun 13, 2024
c22ddda
feat: 찜 등록, 삭제, 조회 요청 훅 추가
im-na0 Jun 13, 2024
b57b6ab
feat: 상세 페이지 좋아요 버튼 기능 연결
im-na0 Jun 13, 2024
085d6a6
feat: 상세 페이지 좋아요 버튼 적용
im-na0 Jun 13, 2024
453b72e
feat: 위시리스트 페이지 Error Boundary & Suspense 적용
im-na0 Jun 13, 2024
f0d2e26
refactor: ProductType 인터페이스 변경
im-na0 Jun 13, 2024
c9348e7
feat: 찜 조회 페이지 좋아요 버튼 기능 추가
im-na0 Jun 13, 2024
49565eb
feat: 찜 조회 페이지 좋아요 버튼 적용
im-na0 Jun 13, 2024
41e3dd8
style: import order 적용
im-na0 Jun 13, 2024
23e21a2
Merge branch 'feature/#351-wishlist' of https://github.com/SCBJ-7/SCB…
im-na0 Jun 13, 2024
5550356
feat: icon 추가
im-na0 Apr 30, 2024
3005dfa
design: 상세페이지 별점, 성급 정보 섹션 추가, 전체적인 레이아웃 수정
im-na0 Apr 30, 2024
6a2f1e5
feat: formatDateAndTime 유틸함수 추가
im-na0 Apr 30, 2024
fa65ab8
feat: heart-fill, heart svg 추가
im-na0 May 30, 2024
fb3a5f1
design: 가격제안 피봇 → 디자인 수정
im-na0 May 30, 2024
72f9000
Merge branch 'feature/#351-wishlist' of https://github.com/SCBJ-7/SCB…
im-na0 Jun 13, 2024
dca23fd
feat: wishlist 페이지 추가
im-na0 May 30, 2024
77ade7f
feat: heart-fill, heart svg 추가
im-na0 May 30, 2024
9a14ab0
feat: Layout 컴포넌트 padding 프로퍼티 추가
im-na0 May 30, 2024
32329aa
design: 위시리스트 페이지 마크업
im-na0 May 30, 2024
5df34ad
feat: 찜 조회 api 인터페이스 추가
im-na0 May 30, 2024
25ea534
design: 위시리스트 상품카드 마크업
im-na0 May 30, 2024
8003d8d
feat: 찜 등록, 삭제 api 및 쿼리 훅 추가
im-na0 May 30, 2024
c739886
chore: 더미데이터 업데이트
im-na0 May 30, 2024
32e1c7d
chore: msw 등록
im-na0 May 30, 2024
082145d
design: 가격제안 피봇 → 디자인 수정
im-na0 May 30, 2024
cbb54d9
feat: dialog ui 컴포넌트 추가
im-na0 May 30, 2024
faeb450
docs: dialog 스토리북 추가
im-na0 May 30, 2024
36784d2
feat: dialog animation 상수 추가
im-na0 May 30, 2024
8878540
chore: 불필요한 로깅 제거
im-na0 May 30, 2024
9bf427e
design: dialog bg 관리 변경
im-na0 Jun 9, 2024
e867b3b
refactor: dialog default props 추가
im-na0 Jun 9, 2024
b6d2681
design: dimmer width, height 제거
im-na0 Jun 9, 2024
8abeb72
feat: mini-alert-dialog 컴포넌트 추가
im-na0 Jun 9, 2024
dd71277
docs: mini-alert-dialog 스토리북 추가
im-na0 Jun 9, 2024
3ea9a0e
design: dialog variants 수정
im-na0 Jun 9, 2024
044ccc6
design: greyScale1 값 변경
im-na0 Jun 9, 2024
c81f562
chore: use-overlay 의존성 추가
im-na0 Jun 9, 2024
c723d6d
chore: package-lock.json 업데이트
im-na0 Jun 13, 2024
7f9e815
fix: conflict 해소
Bumang-Cyber Jun 15, 2024
6b24e2f
Merge pull request #353 from SCBJ-7/feat/#352-navi
Bumang-Cyber Jun 15, 2024
e9855d7
feat: dialog ui 컴포넌트 추가
im-na0 May 30, 2024
1368561
docs: dialog 스토리북 추가
im-na0 May 30, 2024
22f958a
feat: dialog animation 상수 추가
im-na0 May 30, 2024
0e798e1
chore: 불필요한 로깅 제거
im-na0 May 30, 2024
69c0b38
design: dialog bg 관리 변경
im-na0 Jun 9, 2024
1d2b933
refactor: dialog default props 추가
im-na0 Jun 9, 2024
e408630
design: dimmer width, height 제거
im-na0 Jun 9, 2024
86df41c
feat: mini-alert-dialog 컴포넌트 추가
im-na0 Jun 9, 2024
a507ee1
docs: mini-alert-dialog 스토리북 추가
im-na0 Jun 9, 2024
ca42892
design: dialog variants 수정
im-na0 Jun 9, 2024
b81d1a2
design: greyScale1 값 변경
im-na0 Jun 9, 2024
8c8155d
chore: use-overlay 의존성 추가
im-na0 Jun 9, 2024
5302c20
chore: merge conflict 해결
im-na0 Jun 16, 2024
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,746 changes: 1,690 additions & 1,056 deletions package-lock.json

Large diffs are not rendered by default.

19 changes: 10 additions & 9 deletions src/apis/axiosInstance.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,3 @@
import { ResponseError } from "@/components/error/Error";
import {
ACCESS_TOKEN,
BASE_URL,
ERROR_CODE,
REFRESH_TOKEN,
STATUS_CODE,
} from "@/constants/api";
import { PATH } from "@/constants/path";
import axios from "axios";

import { fetchNewToken } from "./fetchNewToken";
@@ -17,6 +8,16 @@ import type {
InternalAxiosRequestConfig,
} from "axios";

import { ResponseError } from "@/components/error/Error";
import {
ACCESS_TOKEN,
BASE_URL,
ERROR_CODE,
REFRESH_TOKEN,
STATUS_CODE,
} from "@/constants/api";
import { PATH } from "@/constants/path";

export const axiosInstance = axios.create({
baseURL: BASE_URL,
timeout: 5000,
9 changes: 4 additions & 5 deletions src/apis/fetchRoom.ts
Original file line number Diff line number Diff line change
@@ -1,20 +1,19 @@
import { ACCESS_TOKEN, BASE_URL, END_POINTS } from "@/constants/api";
import axios from "axios";

import type { ResponseData } from "@/types/responseType";
import type { RoomData } from "@/types/room";

import { ACCESS_TOKEN, BASE_URL, END_POINTS } from "@/constants/api";

export const getRoom = async (
productId: string,
isLoggedIn: boolean,
): Promise<RoomData> => {
const headers: { [key: string]: string } = {};
const headers: Record<string, string> = {};

if (isLoggedIn) {
const accessToken = localStorage.getItem(ACCESS_TOKEN);
if (!accessToken) {
headers["Authorization"] = `Bearer ${accessToken}`;
}
headers["Authorization"] = `${accessToken}`;
}

const { data } = await axios.get<ResponseData<RoomData>>(
20 changes: 20 additions & 0 deletions src/apis/fetchWish.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import type { ResponseData } from "@/types/responseType.ts";
import type { WishDataType } from "@/types/wish.ts";

import { axiosInstance } from "@/apis/axiosInstance.ts";
import { END_POINTS } from "@/constants/api.ts";

export const deleteWish = async (productId: string): Promise<void> => {
return await axiosInstance.delete(`${END_POINTS.WISH(productId)}`);
};

export const postWish = async (productId: string): Promise<void> => {
return await axiosInstance.post(`${END_POINTS.WISH(productId)}`);
};

export const getWish = async (): Promise<WishDataType> => {
const { data } = await axiosInstance.get<ResponseData<WishDataType>>(
`${END_POINTS.WISH_LIST}`,
);
return data.data;
};
File renamed without changes
3 changes: 3 additions & 0 deletions src/assets/icons/heart.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
37 changes: 34 additions & 3 deletions src/components/layout/Layout.style.ts
Original file line number Diff line number Diff line change
@@ -2,15 +2,46 @@ import { styled } from "styled-components";

import type { ColorKeys } from "@/styles/theme.ts";

import { remCalc } from "@/utils/styleFormatter.ts";

export type LayoutStyleProps = {
bg?: ColorKeys;
/**
* padding-top
*/
pt?: number;
/**
* padding-bottom
*/
pb?: number;
/**
* padding-block
*/
paddingBlock?: number;
/**
* padding-inline
*/
paddingInline?: number;
};

export const Wrapper = styled.div.withConfig({
shouldForwardProp: (prop) => prop !== "bg",
})<{ bg: ColorKeys }>`
shouldForwardProp: (prop) =>
!["bg", "pt", "pb", "paddingBlock", "paddingInline"].includes(prop),
})<LayoutStyleProps>`
width: 100%;
min-height: 100%;
max-width: 768px;
min-width: 360px;
position: relative;
margin: 0 auto;

background-color: ${({ theme, bg }) => theme.color[bg]};
background-color: ${({ theme, bg }) =>
bg ? theme.color[bg] : theme.color.white};
padding-top: ${({ pt }) => (pt ? `calc(56px + ${remCalc(pt)})` : undefined)};
padding-bottom: ${({ pb }) =>
pb ? `calc(78px + ${remCalc(pb)})` : undefined};
padding-block: ${({ paddingBlock }) =>
paddingBlock ? remCalc(paddingBlock) : undefined};
padding-inline: ${({ paddingInline }) =>
paddingInline ? remCalc(paddingInline) : undefined};
`;
21 changes: 11 additions & 10 deletions src/components/layout/Layout.tsx
Original file line number Diff line number Diff line change
@@ -5,28 +5,29 @@ import * as S from "./Layout.style";
import BottomNav from "./navBottom/NavBottom";
import { A2HS } from "../A2HS/A2HS";

import { ColorKeys } from "@/styles/theme.ts";
import type { LayoutStyleProps } from "./Layout.style";

import { isMobile } from "@/utils/isMobile";

interface ChildrenProps {
interface ChildrenProps extends LayoutStyleProps {
children: React.ReactNode;
isHeaderOn?: boolean;
isBottomNavOn?: boolean;
bg?: ColorKeys;
}

const Layout = ({
children,
isHeaderOn = false,
isBottomNavOn = false,
bg = "white",
}: ChildrenProps) => {
const Layout = (props: ChildrenProps) => {
const isMobileDevice = isMobile();
const {
isHeaderOn = false,
isBottomNavOn = false,
children,
...rest
} = props;

return (
<>
{isHeaderOn && <Header />}
<S.Wrapper bg={bg}>
<S.Wrapper {...rest}>
{children}
<A2HS />
</S.Wrapper>
5 changes: 3 additions & 2 deletions src/components/layout/navBottom/NavBottom.style.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
import { NavLink } from "react-router-dom";
import styled from "styled-components";

import NavIconHome from "@/assets/icons/NavHome";

export const BottomNavContainer = styled.section<{ $isMobile: boolean }>`
display: flex;
position: fixed;
bottom: 0;

width: 100%;
max-width: 768px;
min-width: 360px;
z-index: 1;
height: ${({ $isMobile }) => ($isMobile ? "78px" : "60px")};
max-width: 768px;

34 changes: 16 additions & 18 deletions src/components/layout/navBottom/NavBottom.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
import IconHomeFill from "@assets/icons/navIcon/icon_home_fill.svg?react";
import IconHomeLine from "@assets/icons/navIcon/icon_home_line.svg?react";
import IconMyFill from "@assets/icons/navIcon/icon_my_fill.svg?react";
import IconMyLine from "@assets/icons/navIcon/icon_my_line.svg?react";
import IconSearchFill from "@assets/icons/navIcon/icon_search_fill.svg?react";
import IconSearchLine from "@assets/icons/navIcon/icon_search_line.svg?react";
import IconTransferWritingFill from "@assets/icons/navIcon/icon_transferWriting_fill.svg?react";
import IconTransferWritingLine from "@assets/icons/navIcon/icon_transferWriting_line.svg?react";
// 찜 페이지용
// import IconWishFill from "@assets/icons/navIcon/icon_wish_fill.svg?react";
// import IconWishLine from "@assets/icons/navIcon/icon_wish_Line.svg?react";
import IconHomeFill from "@/assets/icons/navIcon/icon_home_fill.svg?react";
import IconHomeLine from "@/assets/icons/navIcon/icon_home_line.svg?react";
import IconMyFill from "@/assets/icons/navIcon/icon_my_fill.svg?react";
import IconMyLine from "@/assets/icons/navIcon/icon_my_line.svg?react";
import IconSearchFill from "@/assets/icons/navIcon/icon_search_fill.svg?react";
import IconSearchLine from "@/assets/icons/navIcon/icon_search_line.svg?react";
import IconTransferWritingFill from "@/assets/icons/navIcon/icon_transferWriting_fill.svg?react";
import IconTransferWritingLine from "@/assets/icons/navIcon/icon_transferWriting_line.svg?react";
import IconWishFill from "@/assets/icons/navIcon/icon_wish_fill.svg?react";
import IconWishLine from "@/assets/icons/navIcon/icon_wish_line.svg?react";

import * as S from "./NavBottom.style";
import ToolTip from "./toolTip/ToolTip";
@@ -42,13 +41,12 @@ const BottomNav = ({ isMobile }: BottomNavProps) => {
path: PATH.WRITE_TRANSFER,
icon: [<IconTransferWritingFill />, <IconTransferWritingLine />],
},
// 찜 페이지용
// {
// id: 4,
// name: "찜",
// path: "/wish",
// icon: [<IconWishFill />, <IconWishLine />],
// },
{
id: 4,
name: "찜",
path: PATH.WISHLIST,
icon: [<IconWishFill />, <IconWishLine />],
},
{
id: 5,
name: "마이",
2 changes: 2 additions & 0 deletions src/constants/api.ts
Original file line number Diff line number Diff line change
@@ -32,6 +32,8 @@ export const END_POINTS = {
SEARCH: "/v1/products/search",
CHANGE_NAME: "/v1/members/name",
CHANGE_NUMBER: "/v1/members/phone",
WISH_LIST: "/v1/favorites",
WISH: (productId: string) => `/v1/favorites/${productId}`,
} as const;

export const STATUS_CODE = {
1 change: 1 addition & 0 deletions src/constants/path.ts
Original file line number Diff line number Diff line change
@@ -26,4 +26,5 @@ export const PATH = {
RELOAD: 0,
PAYMENT: (productId: string) => `/payment/${productId}`,
PAYMENT_SUCCESS: (productId: string) => `/payment/${productId}/success`,
WISHLIST: "/wishlist",
} as const;
5 changes: 3 additions & 2 deletions src/hooks/api/useRoomQuery.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { getRoom } from "@/apis/fetchRoom";
import { useSuspenseQuery } from "@tanstack/react-query";
import { calculateDiscount } from "@/utils/calculator";

import type { RoomData } from "@/types/room";
import type { AxiosError } from "axios";

import { getRoom } from "@/apis/fetchRoom";
import { calculateDiscount } from "@/utils/calculator";

interface RoomQueryData {
rawData: RoomData;
discountRate: string;
54 changes: 54 additions & 0 deletions src/hooks/api/useWishQuery.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";

import { deleteWish, getWish, postWish } from "@/apis/fetchWish.ts";

export function useWishQuery() {
return useQuery({
queryKey: ["wish"],
queryFn: getWish,
});
}

export function useDeleteWishMutation() {
const queryClient = useQueryClient();

const { mutate } = useMutation({
mutationFn: deleteWish,
onMutate: async (newLike) => {
await queryClient.cancelQueries({ queryKey: ["wish"] });
const previousWish = queryClient.getQueryData(["wish"]);
queryClient.setQueryData(["wish"], newLike);
return { previousWish };
},
onError: (err, newLike, context) => {
queryClient.setQueryData(["wish"], context?.previousWish);
},
onSettled: () => {
queryClient.invalidateQueries({ queryKey: ["wish"] });
},
});

return { deleteWish: mutate };
}

export function usePostWishMutation() {
const queryClient = useQueryClient();

const { mutate } = useMutation({
mutationFn: postWish,
onMutate: async (newLike) => {
await queryClient.cancelQueries({ queryKey: ["wish"] });
const previousWish = queryClient.getQueryData(["wish"]);
queryClient.setQueryData(["wish"], newLike);
return { previousWish };
},
onError: (err, newLike, context) => {
queryClient.setQueryData(["wish"], context?.previousWish);
},
onSettled: () => {
queryClient.invalidateQueries({ queryKey: ["wish"] });
},
});

return { postWish: mutate };
}
6 changes: 6 additions & 0 deletions src/main.tsx
Original file line number Diff line number Diff line change
@@ -8,6 +8,12 @@ import AppRouter from "./routes/router";
import { GlobalStyle } from "./styles/globalStyle";
import { theme } from "./styles/theme";

import { worker } from "@/mocks/broswer.ts";

if (process.env.NODE_ENV === "development") {
worker.start();
}

const queryClient = new QueryClient({
defaultOptions: {
queries: {
32 changes: 26 additions & 6 deletions src/mocks/data/dummyRoomDetail.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"data": {
"hotelName": "호텔 인 나인 강남",
"hotelImageUrl": [
"https://yaimg.yanolja.com/v5/2023/05/17/12/1280/6464c1e2d8acc7.52423534.jpg",
"https://yaimg.yanolja.com/v5/2022/06/08/18/1280/62a0ead93af4c0.61900529.jpg"
"hotelImageUrlList":[
"ankjdanskdnasd.jpg",
"yjptmpbtpbpe.jpg"
],
"roomName": "스탠다드 더블",
"roomName":"스탠다드 더블",
"checkIn": "2023-12-24T15:00:00",
"checkOut": "2023-12-25T10:00:00",
"originalPrice": 400000,
@@ -22,7 +22,27 @@
"hotelAddress": "서울특별시 강남구 테헤란로 99길 9",
"hotelInfoUrl": "https://place-site.yanolja.com/places/3001615",
"saleStatus": true,
"isSeller": false
"isSeller": false,
"roomAllRating": 4.5,
"hotelLevel": "5성급",
"sellerCommentList": [
"사주세요",
"ㅠㅠ",
"사주세요",
"ㅠㅠ",
"사주세요",
"ㅠㅠ",
"사주세요",
"ㅠㅠ",
"사주세요",
"ㅠㅠ",
"사주세요",
"ㅠㅠ",
"사주세요",
"ㅠㅠ"
],
"facilityInformation": "에어컨\nTV\n냉장고\n커피포트",
"isLike": true
},
"message": "상품 조회에 성공했습니다."
}
}
3 changes: 2 additions & 1 deletion src/mocks/handlers/payment.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { http, HttpResponse } from "msw";

import { BASE_URL, END_POINTS } from "@/constants/api";
import dummyPaymentInfo from "@/mocks/data/dummyPaymentInfo.json";
import dummyPaymentSuccess from "@/mocks/data/dummyPaymentSuccess.json";
import { http, HttpResponse } from "msw";

export const paymentHandler = [
http.get(`${BASE_URL + END_POINTS.PAYMENT(":productId")}`, () => {
3 changes: 2 additions & 1 deletion src/pages/roomDetailPage/RoomDetail.style.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import ArrowSvg from "@/assets/icons/ic_arrow.svg?react";
import { Link } from "react-router-dom";
import styled from "styled-components";

import type { ColorKeys, TypoKeys } from "@/styles/theme";

import ArrowSvg from "@/assets/icons/ic_arrow.svg?react";

export const Container = styled.main`
background-color: ${({ theme }) => theme.color.greyScale7};
padding-bottom: 62px;
Loading