QRCODE 생성 라이브러리 및 코드 추가 / 티비에서 css깨지는 부분 수정

This commit is contained in:
고동영
2024-03-04 16:01:19 +09:00
parent 9432b10fac
commit cad5bc17d4
7 changed files with 21 additions and 18 deletions

View File

@@ -42,6 +42,7 @@
"axios": "^0.21.1", "axios": "^0.21.1",
"ilib": "^14.3.0", "ilib": "^14.3.0",
"prop-types": "^15.6.2", "prop-types": "^15.6.2",
"qrcode.react": "^3.1.0",
"react": "^16.7.0", "react": "^16.7.0",
"react-dom": "^16.7.0", "react-dom": "^16.7.0",
"react-redux": "^7.2.3", "react-redux": "^7.2.3",
@@ -51,4 +52,4 @@
"browserslist": [ "browserslist": [
"chrome 38" "chrome 38"
] ]
} }

View File

@@ -58,7 +58,7 @@
&.secondDepthLayout { &.secondDepthLayout {
width: 386px; width: 386px;
height: calc(100%); height: 1080px;
opacity: 0.95; opacity: 0.95;
box-shadow: 8px 0 36px rgba(33, 33, 32, 0.08); box-shadow: 8px 0 36px rgba(33, 33, 32, 0.08);
padding-bottom: unset; padding-bottom: unset;

View File

@@ -3,6 +3,7 @@
.Wrap { .Wrap {
margin: 30px 0 0 10px; margin: 30px 0 0 10px;
width: 714px;
height: 560px; height: 560px;
display: flex; display: flex;
.thumbnail { .thumbnail {

View File

@@ -1,5 +1,6 @@
import React, { useCallback, useEffect, useRef, useState } from "react"; import React, { useCallback, useEffect, useRef, useState } from "react";
import QRCode from "qrcode.react";
import { useSelector } from "react-redux"; import { useSelector } from "react-redux";
import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator"; import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator";
@@ -28,6 +29,7 @@ export default function ProductThumbnail() {
const [tabLabel, setTabLabel] = useState(""); const [tabLabel, setTabLabel] = useState("");
const { getScrollTo, scrollTop } = useScrollTo(); const { getScrollTo, scrollTop } = useScrollTo();
console.log("#productData", productData);
const scrollTo = useRef(null); const scrollTo = useRef(null);
const buttonLabel = [ const buttonLabel = [
{ label: $L("DESCRIPTION") }, { label: $L("DESCRIPTION") },
@@ -95,7 +97,7 @@ export default function ProductThumbnail() {
verticalScrollbar="auto" verticalScrollbar="auto"
cbScrollTo={getScrollTo} cbScrollTo={getScrollTo}
> >
<div>{DESCRIPTION}</div> {DESCRIPTION}
</TScroller> </TScroller>
<button className={css.downButton} onClick={scrollToBottom} /> <button className={css.downButton} onClick={scrollToBottom} />
</div> </div>
@@ -123,13 +125,9 @@ export default function ProductThumbnail() {
</SpottableComponent> </SpottableComponent>
))} ))}
</div> </div>
{/* qrcodeUrl */}
<div className={css.qrcode}> <div className={css.qrcode}>
<img <QRCode value={productData?.qrcodeUrl} size={160} />
src={
"https://qt3-m.shoptime.lgappstv.com/purchase?cntryCd=US&patnrId=9&prdtId=LDPH5554S&shopTpNm=product"
}
alt=""
/>
</div> </div>
</div> </div>
</Container> </Container>

View File

@@ -62,8 +62,12 @@
border-radius: 6px; border-radius: 6px;
border: solid 1px #fff; border: solid 1px #fff;
background-image: linear-gradient(to top, #f5f5f5, #fff); background-image: linear-gradient(to top, #f5f5f5, #fff);
margin: 10px 0 0 6px; margin: 10px 0 0 6px;
> canvas {
.size(@w: 160px, @h: 160px);
margin: 16px 16px 16px 16px;
}
} }
} }
@@ -91,14 +95,18 @@
.font(@fontFamily: @baseFontBold, @fontSize: 36px); .font(@fontFamily: @baseFontBold, @fontSize: 36px);
padding-top: 24px; padding-top: 24px;
margin-bottom: 14px; margin-bottom: 14px;
margin-right: 22px;
} }
.starRating { .starRating {
margin-top: 3px; margin-top: 3px;
} }
} }
.tagWrap { .tagWrap {
width: 770px;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center;
flex-direction: row;
} }
} }
.line { .line {
@@ -139,7 +147,7 @@
color: #808080; color: #808080;
text-align: left; text-align: left;
line-height: 1.3; line-height: 1.3;
position: relative; height: 250px;
> div { > div {
padding-right: 75px; padding-right: 75px;

View File

@@ -64,7 +64,7 @@ export default function YouMayLike() {
const onButtonClick = useCallback(() => { const onButtonClick = useCallback(() => {
if (cursorVisible) { if (cursorVisible) {
setExpanded(true); setExpanded((prev) => !prev);
} }
}, [cursorVisible]); }, [cursorVisible]);

View File

@@ -44,18 +44,13 @@
} }
.itemList { .itemList {
padding-left: 60px; padding-left: 60px;
width: 100%;
height: 440px; height: 440px;
> div {
background-color: unset;
}
} }
.arrow { .arrow {
//.position(@position: absolute, @top: auto, @left: auto, @right: auto, @bottom: auto);
.size(@w: 42px,@h: 42px); .size(@w: 42px,@h: 42px);
background-position: center; background-position: center;
//background-size: cover;
background-image: url("../../../../assets/images/icons/ic-arrow-up.svg"); background-image: url("../../../../assets/images/icons/ic-arrow-up.svg");
margin-left: 19px; margin-left: 19px;