[에너지라벨]

- 피쳐드브랜드쪽 빠진부분을 위한 수정.
This commit is contained in:
junghoon86.park
2025-11-18 14:30:02 +09:00
parent 1b764b34d5
commit e95e4b828f
2 changed files with 63 additions and 28 deletions

View File

@@ -1,28 +1,43 @@
import React, { useCallback, useEffect, useRef } from "react"; import React, {
useCallback,
useEffect,
useRef,
} from 'react';
import { useDispatch, useSelector } from "react-redux"; import {
useDispatch,
useSelector,
} from 'react-redux';
import { Job } from "@enact/core/util"; import { Job } from '@enact/core/util';
import Spotlight from "@enact/spotlight"; import Spotlight from '@enact/spotlight';
import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator"; import SpotlightContainerDecorator
from '@enact/spotlight/SpotlightContainerDecorator';
import { import {
getContainerId, getContainerId,
setContainerLastFocusedElement, setContainerLastFocusedElement,
} from "@enact/spotlight/src/container"; } from '@enact/spotlight/src/container';
import { pushPanel, updatePanel } from "../../../../actions/panelActions"; import {
pushPanel,
updatePanel,
} from '../../../../actions/panelActions';
import TItemCard, { import TItemCard, {
removeDotAndColon, removeDotAndColon,
} from "../../../../components/TItemCard/TItemCard"; } from '../../../../components/TItemCard/TItemCard';
import TVirtualGridList from "../../../../components/TVirtualGridList/TVirtualGridList"; import TItemCardNew from '../../../../components/TItemCard/TItemCard.new';
import useScrollTo from "../../../../hooks/useScrollTo"; import TVirtualGridList
from '../../../../components/TVirtualGridList/TVirtualGridList';
import useScrollTo from '../../../../hooks/useScrollTo';
import { import {
LOG_CONTEXT_NAME, LOG_CONTEXT_NAME,
LOG_MESSAGE_ID, LOG_MESSAGE_ID,
panel_names, panel_names,
} from "../../../../utils/Config"; } from '../../../../utils/Config';
import { getTranslate3dValueByDirection } from "../../../../utils/helperMethods"; import {
import css from "./FeaturedBestSellerList.module.less"; getTranslate3dValueByDirection,
} from '../../../../utils/helperMethods';
import css from './FeaturedBestSellerList.module.less';
const Container = SpotlightContainerDecorator( const Container = SpotlightContainerDecorator(
{ leaveFor: { right: "" }, enterTo: "last-focused" }, { leaveFor: { right: "" }, enterTo: "last-focused" },
@@ -37,6 +52,7 @@ export default function FeaturedBestSellerList({
shelfTitle, shelfTitle,
shelfLocation, shelfLocation,
shelfOrder, shelfOrder,
euEnrgLblInfos,
}) { }) {
const { getScrollTo, scrollLeft } = useScrollTo(); const { getScrollTo, scrollLeft } = useScrollTo();
@@ -137,6 +153,7 @@ export default function FeaturedBestSellerList({
patncNm, patncNm,
brndNm, brndNm,
lgCatNm, lgCatNm,
euEnrgLblInfos,
} = brandBestSellerInfo[index]; } = brandBestSellerInfo[index];
const rankText = const rankText =
rankOrd === 1 rankOrd === 1
@@ -148,7 +165,7 @@ export default function FeaturedBestSellerList({
: rankOrd + "th,"; : rankOrd + "th,";
return ( return (
<TItemCard <TItemCardNew
catNm={lgCatNm} catNm={lgCatNm}
contextName={LOG_CONTEXT_NAME.FEATURED_BRANDS} contextName={LOG_CONTEXT_NAME.FEATURED_BRANDS}
messageId={LOG_MESSAGE_ID.SHELF_CLICK} messageId={LOG_MESSAGE_ID.SHELF_CLICK}
@@ -172,6 +189,7 @@ export default function FeaturedBestSellerList({
firstLabel={rankText} firstLabel={rankText}
label={index * 1 + 1 + " of " + brandBestSellerInfo.length} label={index * 1 + 1 + " of " + brandBestSellerInfo.length}
lastLabel=" go to detail, button" lastLabel=" go to detail, button"
euEnrgLblInfos={euEnrgLblInfos}
{...rest} {...rest}
/> />
); );

View File

@@ -1,28 +1,43 @@
import React, { useCallback, useEffect, useRef } from "react"; import React, {
useCallback,
useEffect,
useRef,
} from 'react';
import { useDispatch, useSelector } from "react-redux"; import {
useDispatch,
useSelector,
} from 'react-redux';
import { Job } from "@enact/core/util"; import { Job } from '@enact/core/util';
import Spotlight from "@enact/spotlight"; import Spotlight from '@enact/spotlight';
import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator"; import SpotlightContainerDecorator
from '@enact/spotlight/SpotlightContainerDecorator';
import { import {
getContainerId, getContainerId,
setContainerLastFocusedElement, setContainerLastFocusedElement,
} from "@enact/spotlight/src/container"; } from '@enact/spotlight/src/container';
import { pushPanel, updatePanel } from "../../../../../actions/panelActions"; import {
pushPanel,
updatePanel,
} from '../../../../../actions/panelActions';
import TItemCard, { import TItemCard, {
removeDotAndColon, removeDotAndColon,
} from "../../../../../components/TItemCard/TItemCard"; } from '../../../../../components/TItemCard/TItemCard';
import TVirtualGridList from "../../../../../components/TVirtualGridList/TVirtualGridList"; import TItemCardNew from '../../../../../components/TItemCard/TItemCard.new';
import useScrollTo from "../../../../../hooks/useScrollTo"; import TVirtualGridList
from '../../../../../components/TVirtualGridList/TVirtualGridList';
import useScrollTo from '../../../../../hooks/useScrollTo';
import { import {
LOG_CONTEXT_NAME, LOG_CONTEXT_NAME,
LOG_MESSAGE_ID, LOG_MESSAGE_ID,
panel_names, panel_names,
} from "../../../../../utils/Config"; } from '../../../../../utils/Config';
import { getTranslate3dValueByDirection } from "../../../../../utils/helperMethods"; import {
import css from "./FeaturedCategoryProductList.module.less"; getTranslate3dValueByDirection,
} from '../../../../../utils/helperMethods';
import css from './FeaturedCategoryProductList.module.less';
const Container = SpotlightContainerDecorator( const Container = SpotlightContainerDecorator(
{ leaveFor: { right: "" }, enterTo: "last-focused" }, { leaveFor: { right: "" }, enterTo: "last-focused" },
@@ -162,10 +177,11 @@ export default function FeaturedCategoryProductList({
prdtNm, prdtNm,
priceInfo, priceInfo,
expsOrd, expsOrd,
euEnrgLblInfos,
} = brandCategoryProductDetailInfo[index]; } = brandCategoryProductDetailInfo[index];
return ( return (
<TItemCard <TItemCardNew
contextName={LOG_CONTEXT_NAME.FEATURED_BRANDS} contextName={LOG_CONTEXT_NAME.FEATURED_BRANDS}
messageId={LOG_MESSAGE_ID.SHELF_CLICK} messageId={LOG_MESSAGE_ID.SHELF_CLICK}
order={expsOrd} order={expsOrd}
@@ -190,6 +206,7 @@ export default function FeaturedCategoryProductList({
brandCategoryProductDetailInfo.length brandCategoryProductDetailInfo.length
} }
lastLabel=" go to detail, button" lastLabel=" go to detail, button"
euEnrgLblInfos={euEnrgLblInfos}
{...rest} {...rest}
/> />
); );