[지라 이슈 없음] For code convention

Changed files:
1. Favorites.jsx
This commit is contained in:
younghoon100.park
2024-10-08 14:24:19 +09:00
parent 2ac8b3bb36
commit 42b52a803a

View File

@@ -6,6 +6,7 @@ import Spotlight from "@enact/spotlight";
import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator"; import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator";
import { setContainerLastFocusedElement } from "@enact/spotlight/src/container"; import { setContainerLastFocusedElement } from "@enact/spotlight/src/container";
import { sendLogMyPageMyDelete } from "../../../../actions/logActions";
import { import {
clearFavorites, clearFavorites,
deleteMyFavorite, deleteMyFavorite,
@@ -27,15 +28,18 @@ import { $L } from "../../../../utils/helperMethods";
import { SpotlightIds } from "../../../../utils/SpotlightIds"; import { SpotlightIds } from "../../../../utils/SpotlightIds";
import MyPageItemCard, { SIZES } from "../../MyPageItemCard/MyPageItemCard"; import MyPageItemCard, { SIZES } from "../../MyPageItemCard/MyPageItemCard";
import css from "../Favorites/Favorites.module.less"; import css from "../Favorites/Favorites.module.less";
import { sendLogMyPageMyDelete } from "../../../../actions/logActions";
const HeaderButtonContainer = SpotlightContainerDecorator("div"); const HeaderButtonContainer = SpotlightContainerDecorator("div");
const ContainerBasic = SpotlightContainerDecorator({ enterTo: null }, "div"); const ContainerBasic = SpotlightContainerDecorator({ enterTo: null }, "div");
export default function Favorites({ title, panelInfo, isOnTop }) { export default function Favorites({ title, panelInfo, isOnTop }) {
const dispatch = useDispatch(); const dispatch = useDispatch();
const favoritesDatas = useSelector((state) => state.myPage.favoriteData.favorites); const favoritesDatas = useSelector(
const showLoadingPanel = useSelector((state) => state.common.appStatus.showLoadingPanel); (state) => state.myPage.favoriteData.favorites
);
const showLoadingPanel = useSelector(
(state) => state.common.appStatus.showLoadingPanel
);
const [activeDelete, setActiveDelete] = useState(false); const [activeDelete, setActiveDelete] = useState(false);
const [selectedItems, setSelectedItems] = useState({}); const [selectedItems, setSelectedItems] = useState({});
const [selectAll, setSelectAll] = useState(false); const [selectAll, setSelectAll] = useState(false);
@@ -134,9 +138,11 @@ export default function Favorites({ title, panelInfo, isOnTop }) {
if (productList.length > 0 || showList.length > 0) { if (productList.length > 0 || showList.length > 0) {
dispatch(deleteMyFavorite({ productList, showList })); dispatch(deleteMyFavorite({ productList, showList }));
dispatch(sendLogMyPageMyDelete({ dispatch(
cnt: `${productList.length + showList.length}`, sendLogMyPageMyDelete({
})); cnt: `${productList.length + showList.length}`,
})
);
} }
} }
setActiveDelete((prev) => !prev); setActiveDelete((prev) => !prev);