本家モードで列車位置に移動した時に強制的にメニューが展開されていたバグを修正

This commit is contained in:
harukin-expo-dev-env 2025-03-30 02:47:02 +00:00
parent 3eb92564ef
commit 0ae9d59758

16
Top.js
View File

@ -32,20 +32,12 @@ export const Top = () => {
const goToTrainMenu = () => { const goToTrainMenu = () => {
if (Platform.OS === "web") { if (Platform.OS === "web") {
Linking.openURL("https://train.jr-shikoku.co.jp/"); Linking.openURL("https://train.jr-shikoku.co.jp/");
setTimeout(() => { setTimeout(() => navigate("topMenu", { screen: "menu" }), 100);
navigate("topMenu", { screen: "menu" });
}, 100);
return; return;
} }
if (!isFocused()) { if (!isFocused()) navigate("positions", { screen: "Apps" });
navigate("positions", { screen: "Apps" }); else if (mapSwitch == "true") navigate("positions", { screen: "trainMenu" });
} else webview.current?.injectJavaScript(`AccordionClassEvent()`);
else if (mapSwitch == "true") {
navigate("positions", { screen: "trainMenu" });
} else {
webview.current?.injectJavaScript(`AccordionClassEvent()`);
}
return; return;
}; };