diff --git a/src/screens/PaymentResultScreen.tsx b/src/screens/PaymentResultScreen.tsx index 842ac46..710b95c 100644 --- a/src/screens/PaymentResultScreen.tsx +++ b/src/screens/PaymentResultScreen.tsx @@ -1,4 +1,4 @@ -import type { PaymentStackScreenComponentProps } from "@/navigations/Types"; +import type { MainStackScreenComponentProps } from "@/navigations/Types"; import BeasyLogoIcon from "@components/BeasyLogoIcon"; import Button from "@components/Button"; import GoBackIconButton from "@components/GoBackIconButton"; @@ -6,12 +6,13 @@ import BackgroundDefault from "@components/backgrounds/BackgroundDefault"; import Box from "@components/bases/Box"; import Text from "@components/bases/Text"; import { LOG } from "@logger"; +import { CommonActions } from "@react-navigation/native"; // import { Text } from "react-native"; import { SafeAreaView, useSafeAreaInsets } from "react-native-safe-area-context"; const log = LOG.extend("PaymentResultScreen"); -const PaymentResultScreen: PaymentStackScreenComponentProps<"paymentResultScreen"> = ({ +const PaymentResultScreen: MainStackScreenComponentProps<"paymentResultScreen"> = ({ route, navigation, }) => { @@ -35,7 +36,16 @@ const PaymentResultScreen: PaymentStackScreenComponentProps<"paymentResultScreen mb={"m"} > - navigation.goBack()} /> + { + navigation.dispatch( + CommonActions.reset({ + index: 1, + routes: [{ name: "appBottomTabsNavigator" }], + }), + ); + }} + />