Merge pull request 'Added navigate' (#266) from Print-token into main
Reviewed-on: Pozomind/pozo-retail-app#266
This commit is contained in:
commit
e0eecd67b7
|
|
@ -33,7 +33,7 @@ const isCapacitor = () => !!window.Capacitor?.isNativePlatform?.();
|
|||
const HOME_PAGES = [
|
||||
'/landing-page/home',
|
||||
'/home/landing-page/home',
|
||||
'app-page/home', // android minimize
|
||||
'/app-page/home', // android minimize
|
||||
];
|
||||
|
||||
const LOGIN_PAGES = ['signin', 'login', 'auth'];
|
||||
|
|
@ -127,7 +127,7 @@ const AppRoutes = () => {
|
|||
console.log('🔙 Back pressed:', currentPath);
|
||||
|
||||
// 🏠 Home page → minimize
|
||||
if (HOME_PAGES.some((p) => currentPath.includes(p))) {
|
||||
if (HOME_PAGES?.some((p) => currentPath?.startsWith(p))) {
|
||||
if (isCapacitor()) {
|
||||
await CapacitorApp.minimizeApp();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue