[components] modify, TabLayout.jsx, TabItemSub.jsx

This commit is contained in:
younghoon100.park
2024-07-14 23:50:30 +09:00
parent 708ba0d42c
commit 01e8b16c1c
2 changed files with 54 additions and 41 deletions

View File

@@ -4,45 +4,51 @@ import React, {
useMemo,
useRef,
useState,
} from "react";
} from 'react';
import classNames from "classnames";
import { useDispatch, useSelector } from "react-redux";
import classNames from 'classnames';
import {
useDispatch,
useSelector,
} from 'react-redux';
//아이콘
import { Job } from "@enact/core/util";
import { Job } from '@enact/core/util';
//enact
import Skinnable from "@enact/sandstone/Skinnable";
import Spotlight from "@enact/spotlight";
import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator";
import { Cancelable } from "@enact/ui/Cancelable";
import Skinnable from '@enact/sandstone/Skinnable';
import Spotlight from '@enact/spotlight';
import SpotlightContainerDecorator
from '@enact/spotlight/SpotlightContainerDecorator';
import { Cancelable } from '@enact/ui/Cancelable';
import shoptimeFullIconRuc from "../../../assets/images/icons/ic-lnb-logo-shoptime-ruc.png";
import shoptimeFullIconRuc
from '../../../assets/images/icons/ic-lnb-logo-shoptime-ruc.png';
//이미지
import shoptimeFullIcon from "../../../assets/images/icons/ic-lnb-logo-shoptime@3x.png";
import { gnbOpened } from "../../actions/commonActions";
import shoptimeFullIcon
from '../../../assets/images/icons/ic-lnb-logo-shoptime@3x.png';
import { gnbOpened } from '../../actions/commonActions';
import {
checkEnterThroughGNB,
updateSpotlightId,
} from "../../actions/homeActions";
import { resetPanels } from "../../actions/panelActions";
import useLogService from "../../hooks/useLogService";
import usePrevious from "../../hooks/usePrevious";
import useScrollTo from "../../hooks/useScrollTo";
import { panel_names } from "../../utils/Config";
import { SpotlightIds } from "../../utils/SpotlightIds";
import TScroller from "../TScroller/TScroller";
import CategoryIcon from "./iconComponents/CategoryIcon";
import FeaturedBrandIcon from "./iconComponents/FeaturedBrandIcon";
import HomeIcon from "./iconComponents/HomeIcon";
import HotPicksIcon from "./iconComponents/HotPicksIcon";
import MyPageIcon from "./iconComponents/MyPageIcon";
import OnSaleIcon from "./iconComponents/OnSaleIcon";
import SearchIcon from "./iconComponents/SearchIcon";
import TrendingNowIcon from "./iconComponents/TrendingNowIcon";
import TabItem from "./TabItem";
import TabItemSub from "./TabItemSub";
import css from "./TabLayout.module.less";
} from '../../actions/homeActions';
import { resetPanels } from '../../actions/panelActions';
import useLogService from '../../hooks/useLogService';
import usePrevious from '../../hooks/usePrevious';
import useScrollTo from '../../hooks/useScrollTo';
import { panel_names } from '../../utils/Config';
import { SpotlightIds } from '../../utils/SpotlightIds';
import TScroller from '../TScroller/TScroller';
import CategoryIcon from './iconComponents/CategoryIcon';
import FeaturedBrandIcon from './iconComponents/FeaturedBrandIcon';
import HomeIcon from './iconComponents/HomeIcon';
import HotPicksIcon from './iconComponents/HotPicksIcon';
import MyPageIcon from './iconComponents/MyPageIcon';
import OnSaleIcon from './iconComponents/OnSaleIcon';
import SearchIcon from './iconComponents/SearchIcon';
import TrendingNowIcon from './iconComponents/TrendingNowIcon';
import TabItem from './TabItem';
import TabItemSub from './TabItemSub';
import css from './TabLayout.module.less';
const Container = SpotlightContainerDecorator(
{ enterTo: "default-element" },
@@ -518,7 +524,6 @@ export default function TabLayout({ topPanelName, onTabActivated, panelInfo }) {
}
if (target) {
setSelectedSubItemId(null);
dispatch(resetPanels(target));
deActivateTab();
panelSwitching.current = true;