diff --git a/src/Components/Views/DetailPage/DetailPage.scss b/src/Components/Views/DetailPage/DetailPage.scss index 4056ab5e..a1b2463e 100644 --- a/src/Components/Views/DetailPage/DetailPage.scss +++ b/src/Components/Views/DetailPage/DetailPage.scss @@ -20,7 +20,8 @@ left: 0; right: 0; //font-family: 'Dovemayo_gothic'; - + font-family: 'SUITE-Regular'; + .ImgContainer{ height: 780px; position: relative; @@ -37,7 +38,7 @@ z-index: 100; .TitleBox{ - width: 250px; + width: auto; height: 60px; position: absolute; margin: 0 auto; @@ -46,7 +47,7 @@ //background-color: red; p{ - font-size: 40px; + font-size: 30px; } } .BookimgBox{ @@ -64,7 +65,7 @@ img{ width: 360px; height: auto; - position: absolute; + //position: absolute; margin: auto; left: 0; right: 0; @@ -184,6 +185,26 @@ } } - + .InnerContent{ + width: 900px; + background-color: red; + height: auto; + display: block; + margin: 0 auto; + font-family: 'SUITE-Regular'; + + img{ + width: 900px; + //position: absolute; + display: flex; + margin: 0 auto; + } + + p{ + font-family: 'SUITE-Regular' !important; + background-color: antiquewhite; + } + + } } \ No newline at end of file diff --git a/src/Components/Views/DetailPage/DetailPage.tsx b/src/Components/Views/DetailPage/DetailPage.tsx index 461799ee..2d5567cc 100644 --- a/src/Components/Views/DetailPage/DetailPage.tsx +++ b/src/Components/Views/DetailPage/DetailPage.tsx @@ -1,11 +1,28 @@ import BookCustom from '../../../bookcustom/bookcustom'; import { useEffect, useState } from 'react'; -import './DetailPage.scss'; +import './DetailPage.scss' import { useParams } from 'react-router-dom'; import { getDetail } from '@/Apis/productApi'; -function DetailPage() { - const [detail, setDetail] = useState({} as Product); +function DetailPage(){ + + interface DetailInfo { + detail_image:string, + product_name:string, + retail_price:number, + simple_description:string, + summary_description:string, + product_no:string, + price:number, + price_excluding_tax: string, + selling: string, + description:string + } + const [detail, setDetail] = useState({} as DetailInfo); + const [book, setBook] = useState([]); + + + const { productNo } = useParams(); async function getDetails() { try { @@ -22,70 +39,104 @@ function DetailPage() { })(); }, []); - return ( + + const BuyBook = (detailnum) => { + let Cart = localStorage.getItem('cart'); + + // if(Cart === null) { + // Cart = []; + // } else { + // Cart = JSON.parse(Cart); + // } + + // let datalist = { + // "buy": [] + // ,"rent": [] + // }1 + + + // datalist.buy[1]= productid; + + // buy - [1,2,4,56] + // rent - [1,3,6,7] + // let c = localStorage.getIte(cart); + // c.buy + // Cart.push() + // console.log(detail); + } + + const disableLinkClick = (event) => { + event.preventDefault(); + // You can add any additional handling here if needed + }; + + const modifiedDescription = detail.description + ? detail.description.replace(/]*>/gi, (match) => + match.replace('href', 'data-disabled-href') + ) + : ''; + + return( <> -
-
- + +
+
+ +
+ +
+
+ {detail.product_name}
+
+ +
+
-
-
-

제목입니다.

-
-
- bookimgs -
+
+
+

책모양 아크릴 거울
(대상 도서 포함 3만원 이상 구매 시)

-
-
-

- 책모양 아크릴 거울
- (대상 도서 포함 3만원 이상 구매 시) -

+
+
+ 판매가 + {detail.price} +
+
+ 줄거리 + +

+
+
+
+ 카드 + 무이자 할부 + 소득공제300원
-
-
- 정가 - 22,000 -
-
- 판매가 - 22,000 -
-
- 수량 - 22,000 -
-
- 줄거리 - -

- 더 이상 설명이 필요 없는 20세기 환경학 최고의 고전 [침묵의 - 봄]이 50주년 기념 개정판으로 나왔다. 이번 개정판에는 서문과 - 후기가 완전히 새롭게 단장되었으며, 2002년 출간본에는 - 없던(원서에도 없었음) 찾아보기를 새롭게 추가했다. 그리고 - 편집과 장정도 완전히 바뀌었다. -

-
-
-
- 카드 - 무이자 할부 - 소득공제300원 -
- -
- - -
+
+ + +
+
+
+
+ {/*
+ +
*/} + {/*
+
*/} + + {/*
+ +
*/} -
); }