preserve cart & checkout elment on refersh

This commit is contained in:
2025-12-31 16:23:37 +03:00
parent 71e1d71c96
commit 2416b37069
9 changed files with 46 additions and 34 deletions

View File

@@ -1,6 +1,6 @@
import { useTranslation } from "react-i18next";
import { ProBottomSheet } from "../ProBottomSheet/ProBottomSheet";
import { updateGiftType } from "features/order/orderSlice";
import { updateGiftDetails } from "features/order/orderSlice";
import { useAppDispatch } from "redux/hooks";
import GiftItemsBtnIcon from "components/Icons/GiftItemsBtnIcon";
import GiftBalanceBtnIcon from "components/Icons/GiftBalanceBtnIcon";
@@ -21,8 +21,8 @@ export function GiftTypeBottomSheet({
const { t } = useTranslation();
const dispatch = useAppDispatch();
const handleSave = (value: string) => {
dispatch(updateGiftType(value));
const handleSave = (giftType: string) => {
dispatch(updateGiftDetails({ giftType: giftType }));
onClose();
onSave?.();
};