mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2026-03-13 10:22:08 +08:00
fix(vue): router replace action uses custom animation
This commit is contained in:
@@ -400,6 +400,8 @@ export const createIonRouter = (
|
||||
currentHistoryPosition
|
||||
);
|
||||
|
||||
const routerAnimation = incomingRouteParams.routerAnimation || currentRouteInfo?.routerAnimation || routeInfo.routerAnimation;
|
||||
|
||||
/**
|
||||
* If going from /home to /child, then replacing from
|
||||
* /child to /home, we don't want the route info to
|
||||
@@ -417,8 +419,7 @@ export const createIonRouter = (
|
||||
routeInfo.pushedByRoute = pushedByRoute;
|
||||
routeInfo.routerDirection =
|
||||
currentRouteInfo?.routerDirection || routeInfo.routerDirection;
|
||||
routeInfo.routerAnimation =
|
||||
currentRouteInfo?.routerAnimation || routeInfo.routerAnimation;
|
||||
routeInfo.routerAnimation = routerAnimation;
|
||||
routeInfo.prevRouteLastPathname = currentRouteInfo?.lastPathname;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user