Merge commit 'cf57f29e62ceff066426e04ae1ca79d2b65b1cf2'

This commit is contained in:
harukin-DeskMini 2022-11-21 00:06:58 +09:00
commit 151edd5fff
5 changed files with 41 additions and 56 deletions

2
App.js
View File

@ -6,7 +6,7 @@ import {
} from "@react-navigation/stack";
import { createBottomTabNavigator } from "@react-navigation/bottom-tabs";
import { AntDesign, Ionicons } from "@expo/vector-icons";
import { ToastAndroid, Platform, UIManager } from "react-native";
import { Platform, UIManager } from "react-native";
import { UpdateAsync } from "./UpdateAsync.js";
import Apps from "./Apps";
import tndView from "./ndView";

View File

@ -152,13 +152,16 @@ export default function Apps(props) {
}
}}
onMessage={(event) => {
if (!originalStationList) {
alert("駅名標データを取得中...");
return;
}
if (event.nativeEvent.data.includes("PopUpMenu")) {
const selectedStationPDFAddress = event.nativeEvent.data
.split(",")[3]
.replace("'", "")
.replace("'", "");
if (!originalStationList) alert("originalStationListがありません");
const findStationEachLine = (selectLine) => {
let NearStation = selectLine.filter(
(d) => d.StationTimeTable == selectedStationPDFAddress
@ -199,6 +202,7 @@ export default function Apps(props) {
navigate("trainbase", { info: event.nativeEvent.data });
}}
injectedJavaScript={injectJavascript}
onTouchMove={() => StationBoardAcSR.current?.hide()}
/>
<TouchableOpacity
onPress={() =>

View File

@ -5,21 +5,32 @@ export const UpdateAsync = () =>
Updates.checkForUpdateAsync()
.then((update) => {
if (!update.isAvailable) return;
ToastAndroid.showWithGravityAndOffset(
"アプリのデータを更新しています。",
ToastAndroid.LONG,
ToastAndroid.BOTTOM,
25,
50
);
Updates.fetchUpdateAsync().then(() => Updates.reloadAsync());
if (Platform.OS == "ios") {
alert("アプリのデータを更新しています。");
} else {
ToastAndroid.showWithGravityAndOffset(
"アプリのデータを更新しています。",
ToastAndroid.LONG,
ToastAndroid.BOTTOM,
25,
50
);
}
Updates.fetchUpdateAsync().then(Updates.reloadAsync);
return;
})
.catch((e) =>
ToastAndroid.showWithGravityAndOffset(
e.toString(),
ToastAndroid.LONG,
ToastAndroid.BOTTOM,
25,
50
)
);
.catch((e) => {
Platform.OS == "ios"
? alert(e.toString())
: ToastAndroid.showWithGravityAndOffset(
e.toString(),
ToastAndroid.LONG,
ToastAndroid.BOTTOM,
25,
50
);
return;
})
.finally(() => {
return;
});

View File

@ -1,43 +1,12 @@
import React, { Component, useRef, useState, useEffect } from "react";
import {
StatusBar,
Platform,
View,
LayoutAnimation,
ScrollView,
Linking,
Text,
TouchableOpacity,
} from "react-native";
import Image from "react-native-remote-svg";
import Constants from "expo-constants";
import { List, ListItem } from "native-base";
import Icon from "react-native-vector-icons/Entypo";
import * as Location from "expo-location";
import React from "react";
import { View, ScrollView, Linking } from "react-native";
import StatusbarDetect from "../../StatusbarDetect";
var Status = StatusbarDetect();
import { useNavigation } from "@react-navigation/native";
import AutoHeightImage from "react-native-auto-height-image";
import {
widthPercentageToDP as wp,
heightPercentageToDP as hp,
} from "react-native-responsive-screen";
import {
FontAwesome,
Fontisto,
Foundation,
Ionicons,
MaterialCommunityIcons,
} from "@expo/vector-icons";
import * as WebBrowser from "expo-web-browser";
import { FontAwesome, Foundation, Ionicons } from "@expo/vector-icons";
import ActionSheet from "react-native-actions-sheet";
import LottieView from "lottie-react-native";
import SvgUri from "react-native-svg-uri";
import Sign from "../../components/駅名表/Sign";
import { UsefulBox } from "../atom/UsefulBox";
import { TicketBox } from "../atom/TicketBox";
import { TextBox } from "../atom/TextBox";
export const StationDeteilView = (props) => {
const { StationBoardAcSR, currentStation, originalStationList } = props;
@ -49,6 +18,7 @@ export const StationDeteilView = (props) => {
CustomHeaderComponent={() => {}}
>
<View
key={currentStation}
style={{
backgroundColor: "white",
borderRadius: 5,
@ -68,7 +38,7 @@ export const StationDeteilView = (props) => {
}}
/>
</View>
<ScrollView>
<View>
{currentStation && (
<Sign
currentStation={currentStation}
@ -116,7 +86,7 @@ export const StationDeteilView = (props) => {
)}
</View>
)}
</ScrollView>
</View>
</View>
</ActionSheet>
);

View File

@ -102,7 +102,7 @@ export default function Setting(props) {
textAlignVertical: "center",
}}
>
内部バージョン: 4.4.2
内部バージョン: 4.4.2.1
</Text>
<View style={{ flex: 1 }} />
</View>