[SHOPTIME-3562] Hot Picks 랜딩 홈배너 진입 후 최상단 Hot Picks 진입 시 포커싱 상이

[수정파일]

  1. HotPicksPanel.jsx

[수정내용]

  1. currentPage가 0이 들어가면 false로 인식하여 의도한대로 동작하지 않음 undefined로 수정
This commit is contained in:
고동영
2024-09-11 15:32:48 +09:00
parent 3a2589d66f
commit a4bb4f364a

View File

@@ -278,7 +278,7 @@ const HotPicksPanel = ({ panelInfo, isOnTop, spotlightId }) => {
useEffect(() => {
if (
themeCurationInfoData &&
!panelInfo?.currentPage &&
panelInfo?.currentPage === undefined &&
!panelInfo?.currentSpot
) {
const { curationId, patnrId } = panelInfo;
@@ -302,7 +302,12 @@ const HotPicksPanel = ({ panelInfo, isOnTop, spotlightId }) => {
setCurrentPage(matchData.length > 0 ? lastIndex : 0);
}
}
}, [panelInfo, themeCurationInfoData]);
}, [
panelInfo,
panelInfo.currentPage,
panelInfo.currentSpot,
themeCurationInfoData,
]);
useEffect(() => {
let props = { logTpNo: LOG_TP_NO.CURATION.HOT_PICKS };