6.0 update init
22
Apps.js
@ -18,7 +18,7 @@ export function AppContainer() {
|
|||||||
name,
|
name,
|
||||||
options: {
|
options: {
|
||||||
tabBarLabel: label,
|
tabBarLabel: label,
|
||||||
headerTransparent: true,
|
headerShown: false,
|
||||||
gestureEnabled: true,
|
gestureEnabled: true,
|
||||||
tabBarIcon: initIcon(icon, iconFamily),
|
tabBarIcon: initIcon(icon, iconFamily),
|
||||||
tabBarBadge,
|
tabBarBadge,
|
||||||
@ -27,27 +27,31 @@ export function AppContainer() {
|
|||||||
});
|
});
|
||||||
const [fontLoaded, error] = useFonts({
|
const [fontLoaded, error] = useFonts({
|
||||||
"JR-Nishi": require("./assets/fonts/jr-nishi.otf"),
|
"JR-Nishi": require("./assets/fonts/jr-nishi.otf"),
|
||||||
"Zou": require("./assets/fonts/DelaGothicOne-Regular.ttf"),
|
Zou: require("./assets/fonts/DelaGothicOne-Regular.ttf"),
|
||||||
});
|
});
|
||||||
return (
|
return (
|
||||||
<NavigationContainer name="Root" style={{ flex: 1 }} ref={navigationRef}>
|
<NavigationContainer ref={navigationRef}>
|
||||||
<Tab.Navigator
|
<Tab.Navigator
|
||||||
tabBarOptions={{ keyboardHidesTabBar: Platform.OS === "android" }}
|
tabBarOptions={{ keyboardHidesTabBar: Platform.OS === "android" }}
|
||||||
initialRouteName="menuPage"
|
initialRouteName="topMenu"
|
||||||
|
screenOptions={{
|
||||||
|
animation: "shift",
|
||||||
|
tabBarVariant: "uikit",
|
||||||
|
}}
|
||||||
lazy={false}
|
lazy={false}
|
||||||
>
|
>
|
||||||
<Tab.Screen
|
<Tab.Screen
|
||||||
{...getTabProps("login", "位置情報", "barchart", "AntDesign")}
|
{...getTabProps("positions", "走行位置", "barchart", "AntDesign")}
|
||||||
children={(props) => <Top {...props} navigationRef={navigationRef} />}
|
component={Top}
|
||||||
/>
|
/>
|
||||||
<Tab.Screen
|
<Tab.Screen
|
||||||
{...getTabProps("menuPage", "リンク", "radio", "Ionicons")}
|
{...getTabProps("topMenu", "トップメニュー", "radio", "Ionicons")}
|
||||||
component={MenuPage}
|
component={MenuPage}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Tab.Screen
|
<Tab.Screen
|
||||||
{...getTabProps(
|
{...getTabProps(
|
||||||
"home",
|
"information",
|
||||||
"運行情報",
|
"運行情報",
|
||||||
"train",
|
"train",
|
||||||
"Ionicons",
|
"Ionicons",
|
||||||
@ -57,7 +61,7 @@ export function AppContainer() {
|
|||||||
color: "white",
|
color: "white",
|
||||||
}
|
}
|
||||||
)}
|
)}
|
||||||
children={(props) => <TNDView {...props} />}
|
children={TNDView}
|
||||||
/>
|
/>
|
||||||
</Tab.Navigator>
|
</Tab.Navigator>
|
||||||
</NavigationContainer>
|
</NavigationContainer>
|
||||||
|
18
MenuPage.js
@ -1,8 +1,6 @@
|
|||||||
import React, { useEffect } from "react";
|
import React, { useEffect } from "react";
|
||||||
import {
|
import { createStackNavigator } from "@react-navigation/stack";
|
||||||
createStackNavigator,
|
import { CommonActions } from "@react-navigation/native";
|
||||||
TransitionPresets,
|
|
||||||
} from "@react-navigation/stack";
|
|
||||||
import { AS } from "./storageControl";
|
import { AS } from "./storageControl";
|
||||||
import TrainBase from "./components/trainbaseview";
|
import TrainBase from "./components/trainbaseview";
|
||||||
import HowTo from "./howto";
|
import HowTo from "./howto";
|
||||||
@ -20,7 +18,8 @@ export function MenuPage() {
|
|||||||
const { favoriteStation, setFavoriteStation } = useFavoriteStation();
|
const { favoriteStation, setFavoriteStation } = useFavoriteStation();
|
||||||
const { getCurrentTrain } = useCurrentTrain();
|
const { getCurrentTrain } = useCurrentTrain();
|
||||||
const navigation = useNavigation();
|
const navigation = useNavigation();
|
||||||
const { addListener } = navigation;
|
const { addListener, dispatch } = navigation;
|
||||||
|
dispatch(CommonActions.preload("positions"));
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
AS.getItem("startPage")
|
AS.getItem("startPage")
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
@ -67,13 +66,8 @@ export function MenuPage() {
|
|||||||
/>
|
/>
|
||||||
<Stack.Screen
|
<Stack.Screen
|
||||||
name="trainbase"
|
name="trainbase"
|
||||||
options={{ ...optionData, gestureResponseDistance: { vertical: 300 } }}
|
options={{ ...optionData }}
|
||||||
children={(props) => <TrainBase {...props} />}
|
component={TrainBase}
|
||||||
/>
|
|
||||||
<Stack.Screen
|
|
||||||
name="currentTrainIDList"
|
|
||||||
options={{ ...optionData, gestureResponseDistance: { vertical: 300 } }}
|
|
||||||
component={CurrentTrainListView}
|
|
||||||
/>
|
/>
|
||||||
<Stack.Screen
|
<Stack.Screen
|
||||||
name="AllTrainIDList"
|
name="AllTrainIDList"
|
||||||
|
59
Top.js
@ -1,8 +1,6 @@
|
|||||||
import React, { useEffect, useRef, useState } from "react";
|
import React, { useEffect } from "react";
|
||||||
import {
|
import { createStackNavigator } from "@react-navigation/stack";
|
||||||
createStackNavigator,
|
import { useNavigation } from "@react-navigation/native";
|
||||||
TransitionPresets,
|
|
||||||
} from "@react-navigation/stack";
|
|
||||||
import Apps from "./components/Apps";
|
import Apps from "./components/Apps";
|
||||||
import TrainBase from "./components/trainbaseview";
|
import TrainBase from "./components/trainbaseview";
|
||||||
import HowTo from "./howto";
|
import HowTo from "./howto";
|
||||||
@ -10,91 +8,76 @@ import News from "./components/news";
|
|||||||
import TrainMenu from "./components/trainMenu";
|
import TrainMenu from "./components/trainMenu";
|
||||||
import FavoriteList from "./components/FavoriteList";
|
import FavoriteList from "./components/FavoriteList";
|
||||||
import { optionData } from "./lib/stackOption";
|
import { optionData } from "./lib/stackOption";
|
||||||
import { useNavigation } from "@react-navigation/native";
|
|
||||||
import { useCurrentTrain } from "./stateBox/useCurrentTrain";
|
import { useCurrentTrain } from "./stateBox/useCurrentTrain";
|
||||||
import { useTrainMenu } from "./stateBox/useTrainMenu";
|
import { useTrainMenu } from "./stateBox/useTrainMenu";
|
||||||
import { AS } from "./storageControl";
|
import { AS } from "./storageControl";
|
||||||
import { news } from "./config/newsUpdate";
|
import { news } from "./config/newsUpdate";
|
||||||
const Stack = createStackNavigator();
|
const Stack = createStackNavigator();
|
||||||
export const Top = ({ navigationRef }) => {
|
export const Top = () => {
|
||||||
const { webview } = useCurrentTrain();
|
const { webview } = useCurrentTrain();
|
||||||
const { navigate, addListener } = useNavigation();
|
const { navigate, addListener, isFocused } = useNavigation();
|
||||||
|
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
//ニュース表示
|
//ニュース表示
|
||||||
AS.getItem("status")
|
AS.getItem("status")
|
||||||
.then((d) => {
|
.then((d) => {
|
||||||
if (d != news) navigate("news");
|
if (d != news) navigate("positions", { screen: "news" });
|
||||||
})
|
})
|
||||||
.catch(() => navigate("news"));
|
.catch(() => navigate("positions", { screen: "news" }));
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//地図用
|
//地図用
|
||||||
const { injectJavaScript, setInjectJavaScript, mapSwitch } = useTrainMenu();
|
const { injectJavaScript, mapSwitch } = useTrainMenu();
|
||||||
|
|
||||||
const goToFavoriteList = () => navigate("favoriteList");
|
const goToFavoriteList = () =>
|
||||||
|
navigate("positions", { screen: "favoriteList" });
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const unsubscribe = addListener("tabLongPress", goToFavoriteList);
|
const unsubscribe = addListener("tabLongPress", goToFavoriteList);
|
||||||
return unsubscribe;
|
return unsubscribe;
|
||||||
}, [{ navigate, addListener }]);
|
}, []);
|
||||||
|
|
||||||
const goToTrainMenu = () => {
|
const goToTrainMenu = () => {
|
||||||
if (navigationRef.current?.getCurrentRoute().name == "Apps") {
|
if (!isFocused()) {
|
||||||
|
navigate("positions", { screen: "Apps" });
|
||||||
|
}
|
||||||
if (mapSwitch == "true") {
|
if (mapSwitch == "true") {
|
||||||
navigate("trainMenu");
|
navigate("positions", { screen: "trainMenu" });
|
||||||
setInjectJavaScript("");
|
|
||||||
} else {
|
} else {
|
||||||
webview.current?.injectJavaScript(`AccordionClassEvent()`);
|
webview.current?.injectJavaScript(`AccordionClassEvent()`);
|
||||||
}
|
}
|
||||||
} else {
|
return;
|
||||||
if (mapSwitch == "true") {
|
|
||||||
if (injectJavaScript) {
|
|
||||||
webview.current?.injectJavaScript(injectJavaScript);
|
|
||||||
setInjectJavaScript("");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
navigate("Apps");
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const unsubscribe = addListener("tabPress", goToTrainMenu);
|
const unsubscribe = addListener("tabPress", goToTrainMenu);
|
||||||
return unsubscribe;
|
return unsubscribe;
|
||||||
}, [{ navigate, addListener }, mapSwitch, injectJavaScript]);
|
}, [addListener, mapSwitch, injectJavaScript]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Stack.Navigator>
|
<Stack.Navigator detachInactiveScreens={false}>
|
||||||
<Stack.Screen
|
<Stack.Screen
|
||||||
name="Apps"
|
name="Apps"
|
||||||
options={{
|
options={{
|
||||||
headerShown: false,
|
headerShown: false,
|
||||||
gestureEnabled: true,
|
gestureEnabled: true,
|
||||||
headerTransparent: true,
|
headerTransparent: true,
|
||||||
|
detachPreviousScreen: false,
|
||||||
}}
|
}}
|
||||||
component={Apps}
|
component={Apps}
|
||||||
/>
|
/>
|
||||||
<Stack.Screen
|
<Stack.Screen
|
||||||
name="trainbase"
|
name="trainbase"
|
||||||
options={{
|
options={{ ...optionData }}
|
||||||
title: "トレインビジョン",
|
|
||||||
gestureEnabled: true,
|
|
||||||
...TransitionPresets.SlideFromRightIOS,
|
|
||||||
}}
|
|
||||||
component={TrainBase}
|
component={TrainBase}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Stack.Screen name="howto" options={optionData} component={HowTo} />
|
<Stack.Screen name="howto" options={optionData} component={HowTo} />
|
||||||
<Stack.Screen name="news" options={optionData} component={News} />
|
<Stack.Screen name="news" options={optionData} component={News} />
|
||||||
|
|
||||||
<Stack.Screen
|
<Stack.Screen
|
||||||
name="trainMenu"
|
name="trainMenu"
|
||||||
options={optionData}
|
options={optionData}
|
||||||
component={TrainMenu}
|
component={TrainMenu}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Stack.Screen
|
<Stack.Screen
|
||||||
name="favoriteList"
|
name="favoriteList"
|
||||||
options={{ ...optionData, gestureEnabled: false }}
|
options={{ ...optionData, gestureEnabled: false }}
|
||||||
|
49
app.json
@ -2,9 +2,16 @@
|
|||||||
"expo": {
|
"expo": {
|
||||||
"name": "JR四国運行状況",
|
"name": "JR四国運行状況",
|
||||||
"slug": "jrshikoku",
|
"slug": "jrshikoku",
|
||||||
"privacy": "public",
|
|
||||||
"platforms": ["ios", "android"],
|
"platforms": ["ios", "android"],
|
||||||
"plugins": [
|
"plugins": [
|
||||||
|
"expo-localization",
|
||||||
|
[
|
||||||
|
"expo-video",
|
||||||
|
{
|
||||||
|
"supportsBackgroundPlayback": true,
|
||||||
|
"supportsPictureInPicture": true
|
||||||
|
}
|
||||||
|
],
|
||||||
[
|
[
|
||||||
"react-native-android-widget",
|
"react-native-android-widget",
|
||||||
{
|
{
|
||||||
@ -34,14 +41,39 @@
|
|||||||
{
|
{
|
||||||
"locationWhenInUsePermission": "この位置情報は、リンク画面で現在地側近の駅情報を取得するのに使用されます。"
|
"locationWhenInUsePermission": "この位置情報は、リンク画面で現在地側近の駅情報を取得するのに使用されます。"
|
||||||
}
|
}
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"expo-alternate-app-icons",
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"name": "EF65",
|
||||||
|
"ios": {
|
||||||
|
"light":"./assets/icons/ef65_rp0.png",
|
||||||
|
"dark":"./assets/icons/ef65_rp0.png",
|
||||||
|
"tinted":"./assets/icons/ef65_rp0.png"
|
||||||
|
},
|
||||||
|
"android": {
|
||||||
|
"foregroundImage": "./assets/icons/ef65_rp0.png",
|
||||||
|
"backgroundColor": "#001413"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "8000NN",
|
||||||
|
"ios": "./assets/icons/s8000nn.png",
|
||||||
|
"android": {
|
||||||
|
"foregroundImage": "./assets/icons/s8000nn.png",
|
||||||
|
"backgroundColor": "#001413"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
"version": "5.0",
|
"version": "6.0",
|
||||||
"orientation": "default",
|
"orientation": "default",
|
||||||
"icon": "./assets/icon.png",
|
"icon": "./assets/icons/s8000nn.png",
|
||||||
"splash": {
|
"splash": {
|
||||||
"image": "./assets/splash.png",
|
"image": "./assets/splash.png",
|
||||||
"resizeMode": "contain",
|
"resizeMode": "vertical",
|
||||||
"backgroundColor": "#00b8ff"
|
"backgroundColor": "#00b8ff"
|
||||||
},
|
},
|
||||||
"updates": {
|
"updates": {
|
||||||
@ -64,13 +96,18 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"entitlements": {
|
"entitlements": {
|
||||||
"com.apple.developer.nfc.readersession.formats": ["TAG"]
|
"com.apple.developer.nfc.readersession.formats": [
|
||||||
|
"TAG"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"android": {
|
"android": {
|
||||||
"package": "jrshikokuinfo.xprocess.hrkn",
|
"package": "jrshikokuinfo.xprocess.hrkn",
|
||||||
"versionCode": 22,
|
"versionCode": 22,
|
||||||
"permissions": ["ACCESS_FINE_LOCATION", "NFC"],
|
"permissions": [
|
||||||
|
"ACCESS_FINE_LOCATION",
|
||||||
|
"NFC"
|
||||||
|
],
|
||||||
"googleServicesFile": "./google-services.json",
|
"googleServicesFile": "./google-services.json",
|
||||||
"config": {
|
"config": {
|
||||||
"googleMaps": {
|
"googleMaps": {
|
||||||
|
BIN
assets/icons/ef210a.png
Normal file
After Width: | Height: | Size: 483 B |
BIN
assets/icons/ef65_rp0.png
Normal file
After Width: | Height: | Size: 505 B |
BIN
assets/icons/s1000.png
Normal file
After Width: | Height: | Size: 455 B |
BIN
assets/icons/s1200n.png
Normal file
After Width: | Height: | Size: 934 B |
BIN
assets/icons/s1500.png
Normal file
After Width: | Height: | Size: 541 B |
BIN
assets/icons/s185_mrt.png
Normal file
After Width: | Height: | Size: 803 B |
BIN
assets/icons/s185cm.png
Normal file
After Width: | Height: | Size: 550 B |
BIN
assets/icons/s185iyor.png
Normal file
After Width: | Height: | Size: 1004 B |
BIN
assets/icons/s185iyoy.png
Normal file
After Width: | Height: | Size: 1.9 KiB |
BIN
assets/icons/s185mm1.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
assets/icons/s185to_ai.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
assets/icons/s185tu.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
assets/icons/s185ym1.png
Normal file
After Width: | Height: | Size: 2.4 KiB |
BIN
assets/icons/s2000_asi.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
assets/icons/s2002a.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
assets/icons/s2600.png
Normal file
After Width: | Height: | Size: 1.9 KiB |
BIN
assets/icons/s2700.png
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
assets/icons/s2700apr.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
assets/icons/s2700apy.png
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
assets/icons/s32kpuy1.png
Normal file
After Width: | Height: | Size: 630 B |
BIN
assets/icons/s32s.png
Normal file
After Width: | Height: | Size: 564 B |
BIN
assets/icons/s32tht.png
Normal file
After Width: | Height: | Size: 544 B |
BIN
assets/icons/s32to4.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
assets/icons/s40.png
Normal file
After Width: | Height: | Size: 562 B |
BIN
assets/icons/s5001.png
Normal file
After Width: | Height: | Size: 1.7 KiB |
BIN
assets/icons/s5001k.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
assets/icons/s54s.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
assets/icons/s54to0ys.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
assets/icons/s6000p.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
assets/icons/s7000.png
Normal file
After Width: | Height: | Size: 483 B |
BIN
assets/icons/s7200.png
Normal file
After Width: | Height: | Size: 504 B |
BIN
assets/icons/s8000ap.png
Normal file
After Width: | Height: | Size: 592 B |
BIN
assets/icons/s8000nn.png
Normal file
After Width: | Height: | Size: 1005 B |
BIN
assets/icons/s8000no.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
assets/icons/s8000nr.png
Normal file
After Width: | Height: | Size: 1.0 KiB |
BIN
assets/icons/s8600.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
assets/icons/tosa9640.png
Normal file
After Width: | Height: | Size: 448 B |
BIN
assets/icons/tosa9640jgr.png
Normal file
After Width: | Height: | Size: 531 B |
BIN
assets/icons/w213w.png
Normal file
After Width: | Height: | Size: 567 B |
BIN
assets/icons/w285.png
Normal file
After Width: | Height: | Size: 939 B |
@ -9,9 +9,6 @@ import { trainPosition } from "../../../lib/trainPositionTextArray";
|
|||||||
import { TrainPositionDataPush } from "../../発車時刻表/LED_inside_Component/TrainPositionDataPush";
|
import { TrainPositionDataPush } from "../../発車時刻表/LED_inside_Component/TrainPositionDataPush";
|
||||||
import { getStationID } from "../../../lib/eachTrainInfoCoreLib/getStationData";
|
import { getStationID } from "../../../lib/eachTrainInfoCoreLib/getStationData";
|
||||||
import { useStationList } from "../../../stateBox/useStationList";
|
import { useStationList } from "../../../stateBox/useStationList";
|
||||||
import { lineList } from "../../../lib/getStationList";
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
export const TrainDataView = ({
|
export const TrainDataView = ({
|
||||||
currentTrainData,
|
currentTrainData,
|
||||||
@ -21,7 +18,6 @@ export const TrainDataView = ({
|
|||||||
mode = 0,
|
mode = 0,
|
||||||
navigate,
|
navigate,
|
||||||
}) => {
|
}) => {
|
||||||
|
|
||||||
const { stationList } = useStationList();
|
const { stationList } = useStationList();
|
||||||
|
|
||||||
const { width, height } = useWindowDimensions();
|
const { width, height } = useWindowDimensions();
|
||||||
@ -62,7 +58,8 @@ export const TrainDataView = ({
|
|||||||
const [descInput, setDescInput] = useState("");
|
const [descInput, setDescInput] = useState("");
|
||||||
const [stationInput, setStationInput] = useState("");
|
const [stationInput, setStationInput] = useState("");
|
||||||
const [stationNumberInput, setStationNumberInput] = useState("");
|
const [stationNumberInput, setStationNumberInput] = useState("");
|
||||||
return (<>
|
return (
|
||||||
|
<>
|
||||||
<TrainPositionDataPush
|
<TrainPositionDataPush
|
||||||
dialog={dialog}
|
dialog={dialog}
|
||||||
setDialog={setDialog}
|
setDialog={setDialog}
|
||||||
@ -73,7 +70,11 @@ export const TrainDataView = ({
|
|||||||
descInput={descInput}
|
descInput={descInput}
|
||||||
setPosInput={setPosInput}
|
setPosInput={setPosInput}
|
||||||
setDescInput={setDescInput}
|
setDescInput={setDescInput}
|
||||||
station={{Station_JP:trainPositionText(currentTrainData),StationNumber:currentPosition[0]}} />
|
station={{
|
||||||
|
Station_JP: trainPositionText(currentTrainData),
|
||||||
|
StationNumber: currentPosition[0],
|
||||||
|
}}
|
||||||
|
/>
|
||||||
<View
|
<View
|
||||||
style={{
|
style={{
|
||||||
flexDirection: "row",
|
flexDirection: "row",
|
||||||
@ -89,7 +90,10 @@ export const TrainDataView = ({
|
|||||||
onLongPress={() => {
|
onLongPress={() => {
|
||||||
const { isBetween, Pos } = trainPosition(currentTrainData);
|
const { isBetween, Pos } = trainPosition(currentTrainData);
|
||||||
if (isBetween === true) {
|
if (isBetween === true) {
|
||||||
if (platformNumber == undefined && platformDescription == undefined)
|
if (
|
||||||
|
platformNumber == undefined &&
|
||||||
|
platformDescription == undefined
|
||||||
|
)
|
||||||
return;
|
return;
|
||||||
setStationInput(`${Pos.from}→${Pos.to}間`);
|
setStationInput(`${Pos.from}→${Pos.to}間`);
|
||||||
setStationNumberInput(
|
setStationNumberInput(
|
||||||
@ -108,7 +112,7 @@ export const TrainDataView = ({
|
|||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
onPress={() => {
|
onPress={() => {
|
||||||
if(!onLine) return;
|
if (!onLine) return;
|
||||||
const test = [];
|
const test = [];
|
||||||
Object.keys(mapsStationData).forEach((d) => {
|
Object.keys(mapsStationData).forEach((d) => {
|
||||||
mapsStationData[d].forEach((x) => {
|
mapsStationData[d].forEach((x) => {
|
||||||
@ -123,7 +127,7 @@ export const TrainDataView = ({
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
if (!test.length) return;
|
if (!test.length) return;
|
||||||
navigate("Apps");
|
navigate("positions", { screen: "Apps" });
|
||||||
inject(
|
inject(
|
||||||
`MoveDisplayStation('${test[0].line}_${test[0].station.MyStation}_${test[0].station.Station_JP}');document.getElementById("disp").insertAdjacentHTML("afterbegin", "<div />");`
|
`MoveDisplayStation('${test[0].line}_${test[0].station.MyStation}_${test[0].station.Station_JP}');document.getElementById("disp").insertAdjacentHTML("afterbegin", "<div />");`
|
||||||
);
|
);
|
||||||
|
@ -13,7 +13,7 @@ export const TrainViewIcon: FC<Props> = ({ data, navigate, from }) => {
|
|||||||
const [isTrainView, setIsTrainView] = useState(false);
|
const [isTrainView, setIsTrainView] = useState(false);
|
||||||
//トレインビュー表示対象(特急、マリン)かを判定
|
//トレインビュー表示対象(特急、マリン)かを判定
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (!data.limited) return;
|
if (!data.limited) return () => {};
|
||||||
setIsTrainView(
|
setIsTrainView(
|
||||||
getType(data.limited.split(":")[0]) &&
|
getType(data.limited.split(":")[0]) &&
|
||||||
!data.limited.split(":")[1].match("サンポート")
|
!data.limited.split(":")[1].match("サンポート")
|
||||||
|
@ -20,7 +20,7 @@ import { useNavigation } from "@react-navigation/native";
|
|||||||
import { BigButton } from "./atom/BigButton";
|
import { BigButton } from "./atom/BigButton";
|
||||||
import { Switch } from "react-native-elements";
|
import { Switch } from "react-native-elements";
|
||||||
export default function AllTrainDiagramView() {
|
export default function AllTrainDiagramView() {
|
||||||
const { navigate } = useNavigation();
|
const { goBack, navigate } = useNavigation();
|
||||||
const { keyList, allTrainDiagram } = useAllTrainDiagram();
|
const { keyList, allTrainDiagram } = useAllTrainDiagram();
|
||||||
const [input, setInput] = useState(""); // 文字入力
|
const [input, setInput] = useState(""); // 文字入力
|
||||||
const [keyBoardVisible, setKeyBoardVisible] = useState(false);
|
const [keyBoardVisible, setKeyBoardVisible] = useState(false);
|
||||||
@ -206,7 +206,7 @@ export default function AllTrainDiagramView() {
|
|||||||
</View>
|
</View>
|
||||||
</KeyboardAvoidingView>
|
</KeyboardAvoidingView>
|
||||||
<BigButton
|
<BigButton
|
||||||
onPress={() => navigate("menu")}
|
onPress={goBack}
|
||||||
string="閉じる"
|
string="閉じる"
|
||||||
style={{
|
style={{
|
||||||
display:
|
display:
|
||||||
|
@ -4,12 +4,12 @@ import { useCurrentTrain } from "../stateBox/useCurrentTrain";
|
|||||||
import { useNavigation } from "@react-navigation/native";
|
import { useNavigation } from "@react-navigation/native";
|
||||||
import { BigButton } from "./atom/BigButton";
|
import { BigButton } from "./atom/BigButton";
|
||||||
export default function CurrentTrainListView() {
|
export default function CurrentTrainListView() {
|
||||||
const { navigate } = useNavigation();
|
const { goBack } = useNavigation();
|
||||||
const { currentTrain } = useCurrentTrain();
|
const { currentTrain } = useCurrentTrain();
|
||||||
return (
|
return (
|
||||||
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
||||||
{currentTrain && currentTrain.map((d) => <Text>{d.num}</Text>)}
|
{currentTrain && currentTrain.map((d) => <Text>{d.num}</Text>)}
|
||||||
<BigButton onPress={() => navigate("menu")} string="閉じる" />
|
<BigButton onPress={goBack} string="閉じる" />
|
||||||
</View>
|
</View>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import React from "react";
|
import React, { useEffect } from "react";
|
||||||
import { View, Text, TouchableOpacity, ScrollView } from "react-native";
|
import { View, Text, ScrollView } from "react-native";
|
||||||
|
|
||||||
import Icon from "react-native-vector-icons/Entypo";
|
import Icon from "react-native-vector-icons/Entypo";
|
||||||
import { useFavoriteStation } from "../stateBox/useFavoriteStation";
|
import { useFavoriteStation } from "../stateBox/useFavoriteStation";
|
||||||
@ -11,9 +11,18 @@ import { BigButton } from "./atom/BigButton";
|
|||||||
export default function FavoriteList() {
|
export default function FavoriteList() {
|
||||||
const { favoriteStation } = useFavoriteStation();
|
const { favoriteStation } = useFavoriteStation();
|
||||||
const { webview } = useCurrentTrain();
|
const { webview } = useCurrentTrain();
|
||||||
const { navigate, goBack } = useNavigation();
|
const { navigate, addListener, goBack, canGoBack } = useNavigation();
|
||||||
const { mapsStationData: stationData } = useTrainMenu();
|
const { mapsStationData: stationData } = useTrainMenu();
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
const unsubscribe = addListener("tabPress", goToTrainMenu);
|
||||||
|
return unsubscribe;
|
||||||
|
}, [{ navigate, addListener }]);
|
||||||
|
|
||||||
|
const goToTrainMenu = (e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
goBack();
|
||||||
|
};
|
||||||
return (
|
return (
|
||||||
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
||||||
<Text
|
<Text
|
||||||
@ -50,7 +59,8 @@ export default function FavoriteList() {
|
|||||||
`MoveDisplayStation('${lineName}_${currentStation[0].MyStation}_${currentStation[0].Station_JP}');
|
`MoveDisplayStation('${lineName}_${currentStation[0].MyStation}_${currentStation[0].Station_JP}');
|
||||||
document.getElementById("disp").insertAdjacentHTML("afterbegin", "<div />");`
|
document.getElementById("disp").insertAdjacentHTML("afterbegin", "<div />");`
|
||||||
);
|
);
|
||||||
navigate("Apps");
|
goBack();
|
||||||
|
if (canGoBack()) goBack();
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<View
|
<View
|
||||||
|
@ -8,7 +8,6 @@ import {
|
|||||||
import Icon from "react-native-vector-icons/Entypo";
|
import Icon from "react-native-vector-icons/Entypo";
|
||||||
import { TextBox } from "../atom/TextBox";
|
import { TextBox } from "../atom/TextBox";
|
||||||
import { TicketBox } from "../atom/TicketBox";
|
import { TicketBox } from "../atom/TicketBox";
|
||||||
import { ListItem } from "native-base";
|
|
||||||
|
|
||||||
export const FixedContentBottom = (props) => {
|
export const FixedContentBottom = (props) => {
|
||||||
return (
|
return (
|
||||||
@ -249,11 +248,20 @@ export const FixedContentBottom = (props) => {
|
|||||||
name: "しこくたぬきのぽんちゃん 【四国家サポーターズクラブ】",
|
name: "しこくたぬきのぽんちゃん 【四国家サポーターズクラブ】",
|
||||||
},
|
},
|
||||||
].map((d) => (
|
].map((d) => (
|
||||||
<ListItem onPress={() => Linking.openURL(d.url)}>
|
<TouchableOpacity
|
||||||
|
onPress={() => Linking.openURL(d.url)}
|
||||||
|
style={{
|
||||||
|
flexDirection: "row",
|
||||||
|
padding: 5,
|
||||||
|
alignItems: "center",
|
||||||
|
borderBottomWidth: 1,
|
||||||
|
borderBottomColor: "white",
|
||||||
|
}}
|
||||||
|
>
|
||||||
<Text>{d.name}</Text>
|
<Text>{d.name}</Text>
|
||||||
<View style={{ flex: 1 }} />
|
<View style={{ flex: 1 }} />
|
||||||
<Icon name="chevron-right" size={20} />
|
<Icon name="chevron-right" size={20} />
|
||||||
</ListItem>
|
</TouchableOpacity>
|
||||||
))}
|
))}
|
||||||
</View>
|
</View>
|
||||||
</View>
|
</View>
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
import React, { FC, useState } from "react";
|
import React, { FC, useState } from "react";
|
||||||
import { View, Text, TouchableOpacity } from "react-native";
|
import { View, Text, TouchableOpacity } from "react-native";
|
||||||
import { Pagination } from "react-native-snap-carousel";
|
|
||||||
import { useInterval } from "../../lib/useInterval";
|
import { useInterval } from "../../lib/useInterval";
|
||||||
|
|
||||||
import lineColorList from "../../assets/originData/lineColorList";
|
import lineColorList from "../../assets/originData/lineColorList";
|
||||||
@ -27,50 +26,12 @@ type StationPaginationProps = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
export const Paginations: FC<StationPaginationProps> = (props) => {
|
export const Paginations: FC<StationPaginationProps> = (props) => {
|
||||||
const {
|
const { entries, setSelectedCurrentStation } = props;
|
||||||
entries,
|
|
||||||
activeSlide,
|
|
||||||
carouselRef,
|
|
||||||
setSelectedCurrentStation,
|
|
||||||
dotButton,
|
|
||||||
} = props;
|
|
||||||
return (
|
return (
|
||||||
<Pagination
|
|
||||||
dotsLength={entries.length}
|
|
||||||
activeDotIndex={activeSlide}
|
|
||||||
carouselRef={carouselRef}
|
|
||||||
containerStyle={{ paddingVertical: 0 }}
|
|
||||||
dotStyle={{
|
|
||||||
width: 12,
|
|
||||||
height: 12,
|
|
||||||
borderRadius: 6,
|
|
||||||
backgroundColor: "#0099CC",
|
|
||||||
}}
|
|
||||||
inactiveDotStyle={
|
|
||||||
{
|
|
||||||
// Define styles for inactive dots here
|
|
||||||
}
|
|
||||||
}
|
|
||||||
tappableDots={true}
|
|
||||||
inactiveDotOpacity={0.4}
|
|
||||||
inactiveDotScale={0.8}
|
|
||||||
inactiveDotElement={
|
|
||||||
dotButton && (
|
|
||||||
<StationNumberMaker
|
<StationNumberMaker
|
||||||
currentStations={entries}
|
currentStations={entries}
|
||||||
setSelectedCurrentStation={setSelectedCurrentStation}
|
setSelectedCurrentStation={setSelectedCurrentStation}
|
||||||
/>
|
/>
|
||||||
)
|
|
||||||
}
|
|
||||||
dotElement={
|
|
||||||
dotButton && (
|
|
||||||
<StationNumberMaker
|
|
||||||
currentStations={entries}
|
|
||||||
setSelectedCurrentStation={setSelectedCurrentStation}
|
|
||||||
/>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
/>
|
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
type StationNumberMakerProps = {
|
type StationNumberMakerProps = {
|
||||||
|
@ -1,17 +1,19 @@
|
|||||||
import React from "react";
|
import React from "react";
|
||||||
import { View, Text, TouchableOpacity, ScrollView } from "react-native";
|
import { View, Text, TouchableOpacity, ScrollView } from "react-native";
|
||||||
|
import { useNavigation } from "@react-navigation/native";
|
||||||
import { useFavoriteStation } from "../../stateBox/useFavoriteStation";
|
import { useFavoriteStation } from "../../stateBox/useFavoriteStation";
|
||||||
import { CheckBox } from "react-native-elements";
|
import { CheckBox } from "react-native-elements";
|
||||||
import { FavoriteSettingsItem } from "./FavoliteSettings/FavoiliteSettingsItem";
|
import { FavoriteSettingsItem } from "./FavoliteSettings/FavoiliteSettingsItem";
|
||||||
|
|
||||||
export const FavoriteSettings = ({ navigate }) => {
|
export const FavoriteSettings = () => {
|
||||||
const { favoriteStation, setFavoriteStation } = useFavoriteStation();
|
const { favoriteStation, setFavoriteStation } = useFavoriteStation();
|
||||||
|
const { goBack } = useNavigation();
|
||||||
return (
|
return (
|
||||||
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
||||||
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
||||||
<View style={{ flex: 1 }}>
|
<View style={{ flex: 1 }}>
|
||||||
<TouchableOpacity
|
<TouchableOpacity
|
||||||
onPress={() => navigate("settingTopPage")}
|
onPress={goBack}
|
||||||
style={{
|
style={{
|
||||||
flexDirection: "column",
|
flexDirection: "column",
|
||||||
flex: 1,
|
flex: 1,
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
import React from "react";
|
import React from "react";
|
||||||
import { View, Text, TouchableOpacity, ScrollView } from "react-native";
|
import { View, Text, TouchableOpacity, ScrollView } from "react-native";
|
||||||
|
import { useNavigation } from "@react-navigation/native";
|
||||||
import { SwitchArea } from "../atom/SwitchArea";
|
import { SwitchArea } from "../atom/SwitchArea";
|
||||||
import { CheckBox } from "react-native-elements";
|
import { CheckBox } from "react-native-elements";
|
||||||
import { TripleSwitchArea } from "../atom/TripleSwitchArea";
|
import { TripleSwitchArea } from "../atom/TripleSwitchArea";
|
||||||
@ -21,12 +22,13 @@ export const LayoutSettings = ({
|
|||||||
headerSize,
|
headerSize,
|
||||||
setHeaderSize,
|
setHeaderSize,
|
||||||
}) => {
|
}) => {
|
||||||
|
const { goBack } = useNavigation();
|
||||||
return (
|
return (
|
||||||
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
||||||
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
||||||
<View style={{ flex: 1 }}>
|
<View style={{ flex: 1 }}>
|
||||||
<TouchableOpacity
|
<TouchableOpacity
|
||||||
onPress={() => navigate("settingTopPage")}
|
onPress={goBack}
|
||||||
style={{
|
style={{
|
||||||
flexDirection: "column",
|
flexDirection: "column",
|
||||||
flex: 1,
|
flex: 1,
|
||||||
|
@ -1,12 +1,15 @@
|
|||||||
import React, { useEffect, useState } from "react";
|
import React, { useEffect, useState } from "react";
|
||||||
import { View, Text, TouchableOpacity, ScrollView,Clipboard } from "react-native";
|
import { View, Text, TouchableOpacity, ScrollView,Clipboard } from "react-native";
|
||||||
|
//import * as Clipboard from 'expo-clipboard';
|
||||||
|
|
||||||
import { CheckBox } from "react-native-elements";
|
import { CheckBox } from "react-native-elements";
|
||||||
import { AS } from "../../storageControl";
|
import { AS } from "../../storageControl";
|
||||||
import { useNotification } from "../../stateBox/useNotifications";
|
import { useNotification } from "../../stateBox/useNotifications";
|
||||||
|
import { useNavigation } from "@react-navigation/native";
|
||||||
|
|
||||||
export const NotificationSettings = ({ navigate }) => {
|
export const NotificationSettings = () => {
|
||||||
const { expoPushToken } = useNotification();
|
const { expoPushToken } = useNotification();
|
||||||
|
const { goBack } = useNavigation();
|
||||||
const [traInfoEX, setTraInfoEX] = useState(false);
|
const [traInfoEX, setTraInfoEX] = useState(false);
|
||||||
const [informations, setInformations] = useState(false);
|
const [informations, setInformations] = useState(false);
|
||||||
const [strangeTrain, setStrangeTrain] = useState(false);
|
const [strangeTrain, setStrangeTrain] = useState(false);
|
||||||
@ -21,9 +24,7 @@ export const NotificationSettings = ({ navigate }) => {
|
|||||||
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
||||||
<View style={{ flex: 1 }}>
|
<View style={{ flex: 1 }}>
|
||||||
<TouchableOpacity
|
<TouchableOpacity
|
||||||
onPress={() => {
|
onPress={goBack}
|
||||||
navigate("settingTopPage");
|
|
||||||
}}
|
|
||||||
style={{
|
style={{
|
||||||
flexDirection: "column",
|
flexDirection: "column",
|
||||||
flex: 1,
|
flex: 1,
|
||||||
@ -40,7 +41,7 @@ export const NotificationSettings = ({ navigate }) => {
|
|||||||
padding: 10,
|
padding: 10,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
< 設定/送信
|
< 設定
|
||||||
</Text>
|
</Text>
|
||||||
<View style={{ flex: 1 }} />
|
<View style={{ flex: 1 }} />
|
||||||
</TouchableOpacity>
|
</TouchableOpacity>
|
||||||
@ -79,7 +80,7 @@ export const NotificationSettings = ({ navigate }) => {
|
|||||||
AS.setItem("traInfoEX", traInfoEX.toString()),
|
AS.setItem("traInfoEX", traInfoEX.toString()),
|
||||||
AS.setItem("informations", informations.toString()),
|
AS.setItem("informations", informations.toString()),
|
||||||
AS.setItem("strangeTrain", strangeTrain.toString()),
|
AS.setItem("strangeTrain", strangeTrain.toString()),
|
||||||
]).then(()=>alert("通知の設定を保存、登録しました"));
|
]).then(() => alert("通知の設定を保存、登録しました"));
|
||||||
});
|
});
|
||||||
}}
|
}}
|
||||||
style={{
|
style={{
|
||||||
@ -120,9 +121,10 @@ export const NotificationSettings = ({ navigate }) => {
|
|||||||
setBool={setStrangeTrain}
|
setBool={setStrangeTrain}
|
||||||
str="怪レい列車"
|
str="怪レい列車"
|
||||||
/>
|
/>
|
||||||
<Text style={{fontWeight: "bold", padding: 10 }} onPress={()=>{
|
<Text
|
||||||
Clipboard.setString(expoPushToken);
|
style={{ fontWeight: "bold", padding: 10 }}
|
||||||
}}>
|
onPress={() => Clipboard.setStringAsync(expoPushToken)}
|
||||||
|
>
|
||||||
通知を受け取りたい項目を選択してください。チェックボックスを選び、右上の「登録実行」を押すと設定が反映され、通知が届くようになります。
|
通知を受け取りたい項目を選択してください。チェックボックスを選び、右上の「登録実行」を押すと設定が反映され、通知が届くようになります。
|
||||||
</Text>
|
</Text>
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
|
@ -10,6 +10,7 @@ import {
|
|||||||
} from "react-native";
|
} from "react-native";
|
||||||
import * as Updates from "expo-updates";
|
import * as Updates from "expo-updates";
|
||||||
import { useWindowDimensions } from "react-native";
|
import { useWindowDimensions } from "react-native";
|
||||||
|
import { useNavigation } from "@react-navigation/native";
|
||||||
import { ListItem } from "native-base";
|
import { ListItem } from "native-base";
|
||||||
import { SwitchArea } from "../atom/SwitchArea";
|
import { SwitchArea } from "../atom/SwitchArea";
|
||||||
import { useNotification } from "../../stateBox/useNotifications";
|
import { useNotification } from "../../stateBox/useNotifications";
|
||||||
@ -17,7 +18,6 @@ import { useNotification } from "../../stateBox/useNotifications";
|
|||||||
const versionCode = "5.6.0.2";
|
const versionCode = "5.6.0.2";
|
||||||
|
|
||||||
export const SettingTopPage = ({
|
export const SettingTopPage = ({
|
||||||
navigate,
|
|
||||||
testNFC,
|
testNFC,
|
||||||
startPage,
|
startPage,
|
||||||
setStartPage,
|
setStartPage,
|
||||||
@ -25,12 +25,13 @@ export const SettingTopPage = ({
|
|||||||
}) => {
|
}) => {
|
||||||
const { width } = useWindowDimensions();
|
const { width } = useWindowDimensions();
|
||||||
const { expoPushToken } = useNotification();
|
const { expoPushToken } = useNotification();
|
||||||
|
const navigation = useNavigation();
|
||||||
return (
|
return (
|
||||||
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
||||||
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
||||||
<View style={{ flex: 1 }}>
|
<View style={{ flex: 1 }}>
|
||||||
<TouchableOpacity
|
<TouchableOpacity
|
||||||
onPress={() => navigate("menu")}
|
onPress={() => navigation.goBack()}
|
||||||
style={{
|
style={{
|
||||||
flexDirection: "column",
|
flexDirection: "column",
|
||||||
flex: 1,
|
flex: 1,
|
||||||
@ -120,7 +121,7 @@ export const SettingTopPage = ({
|
|||||||
/>
|
/>
|
||||||
<ListItem
|
<ListItem
|
||||||
style={{ flexDirection: "row" }}
|
style={{ flexDirection: "row" }}
|
||||||
onPress={() => navigate("FavoriteSettings")}
|
onPress={() => navigation.navigate("setting",{screen:"FavoriteSettings"})}
|
||||||
>
|
>
|
||||||
<Text
|
<Text
|
||||||
style={{
|
style={{
|
||||||
@ -148,7 +149,7 @@ export const SettingTopPage = ({
|
|||||||
</ListItem>
|
</ListItem>
|
||||||
<ListItem
|
<ListItem
|
||||||
style={{ flexDirection: "row" }}
|
style={{ flexDirection: "row" }}
|
||||||
onPress={() => navigate("NotificationSettings")}
|
onPress={() => navigation.navigate("setting",{screen:"NotificationSettings"})}
|
||||||
disabled={expoPushToken == ""}
|
disabled={expoPushToken == ""}
|
||||||
>
|
>
|
||||||
<Text
|
<Text
|
||||||
@ -177,7 +178,7 @@ export const SettingTopPage = ({
|
|||||||
</ListItem>
|
</ListItem>
|
||||||
<ListItem
|
<ListItem
|
||||||
style={{ flexDirection: "row" }}
|
style={{ flexDirection: "row" }}
|
||||||
onPress={() => navigate("LayoutSettings")}
|
onPress={() => navigation.navigate("setting",{screen:"LayoutSettings"})}
|
||||||
>
|
>
|
||||||
<Text
|
<Text
|
||||||
style={{
|
style={{
|
||||||
@ -206,7 +207,7 @@ export const SettingTopPage = ({
|
|||||||
{Platform.OS === "android" ? (
|
{Platform.OS === "android" ? (
|
||||||
<ListItem
|
<ListItem
|
||||||
style={{ flexDirection: "row" }}
|
style={{ flexDirection: "row" }}
|
||||||
onPress={() => navigate("WidgetSettings")}
|
onPress={() => navigation.navigate("setting",{screen:"WidgetSettings"})}
|
||||||
>
|
>
|
||||||
<Text
|
<Text
|
||||||
style={{
|
style={{
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
import React, { useEffect, useState } from "react";
|
import React, { useEffect, useState } from "react";
|
||||||
import { View, Text, TouchableOpacity, ScrollView } from "react-native";
|
import { View, Text, TouchableOpacity, ScrollView } from "react-native";
|
||||||
import { SwitchArea } from "../atom/SwitchArea";
|
import { useNavigation } from "@react-navigation/native";
|
||||||
import { CheckBox } from "react-native-elements";
|
import { CheckBox } from "react-native-elements";
|
||||||
import { TripleSwitchArea } from "../atom/TripleSwitchArea";
|
|
||||||
import { getWidgetInfo, WidgetPreview } from "react-native-android-widget";
|
import { getWidgetInfo, WidgetPreview } from "react-native-android-widget";
|
||||||
import { getDelayData } from "../AndroidWidget/TraInfoEXWidget";
|
import { getDelayData } from "../AndroidWidget/TraInfoEXWidget";
|
||||||
import { getInfoString } from "../AndroidWidget/InfoWidget";
|
import { getInfoString } from "../AndroidWidget/InfoWidget";
|
||||||
@ -12,6 +11,7 @@ import { ListItem } from "native-base";
|
|||||||
|
|
||||||
export const WidgetSettings = ({ navigate }) => {
|
export const WidgetSettings = ({ navigate }) => {
|
||||||
const { JR_shikoku_train_info, Info_Widget } = nameToWidget;
|
const { JR_shikoku_train_info, Info_Widget } = nameToWidget;
|
||||||
|
const { goBack } = useNavigation();
|
||||||
const [time, setTime] = useState();
|
const [time, setTime] = useState();
|
||||||
const [delayString, setDelayString] = useState();
|
const [delayString, setDelayString] = useState();
|
||||||
const [trainInfo, setTrainInfo] = useState();
|
const [trainInfo, setTrainInfo] = useState();
|
||||||
@ -42,7 +42,7 @@ export const WidgetSettings = ({ navigate }) => {
|
|||||||
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
<View style={{ backgroundColor: "#0099CC", flexDirection: "row" }}>
|
||||||
<View style={{ flex: 1 }}>
|
<View style={{ flex: 1 }}>
|
||||||
<TouchableOpacity
|
<TouchableOpacity
|
||||||
onPress={() => navigate("settingTopPage")}
|
onPress={goBack}
|
||||||
style={{
|
style={{
|
||||||
flexDirection: "column",
|
flexDirection: "column",
|
||||||
flex: 1,
|
flex: 1,
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
import React, { FC } from "react";
|
import React, { FC } from "react";
|
||||||
import { Marker } from "react-native-maps";
|
import { Marker } from "react-native-maps";
|
||||||
|
import { useNavigation } from "@react-navigation/native";
|
||||||
type Props = {
|
type Props = {
|
||||||
index: number;
|
index: number;
|
||||||
indexBase: number;
|
indexBase: number;
|
||||||
@ -12,6 +13,7 @@ type Props = {
|
|||||||
|
|
||||||
export const MapPin: FC<Props> = (props) => {
|
export const MapPin: FC<Props> = (props) => {
|
||||||
const { index, indexBase, latlng, D, d, navigate, webview } = props;
|
const { index, indexBase, latlng, D, d, navigate, webview } = props;
|
||||||
|
const {goBack} = useNavigation();
|
||||||
return (
|
return (
|
||||||
<Marker
|
<Marker
|
||||||
key={index + indexBase}
|
key={index + indexBase}
|
||||||
@ -24,7 +26,7 @@ export const MapPin: FC<Props> = (props) => {
|
|||||||
`MoveDisplayStation('${d}_${D.MyStation}_${D.Station_JP}');
|
`MoveDisplayStation('${d}_${D.MyStation}_${D.Station_JP}');
|
||||||
document.getElementById("disp").insertAdjacentHTML("afterbegin", "<div />");`
|
document.getElementById("disp").insertAdjacentHTML("afterbegin", "<div />");`
|
||||||
);
|
);
|
||||||
if (navigate) navigate("Apps");
|
if (navigate) goBack();
|
||||||
}}
|
}}
|
||||||
image={require("../../assets/reccha-small.png")}
|
image={require("../../assets/reccha-small.png")}
|
||||||
></Marker>
|
></Marker>
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
import React, { useRef, useState, useEffect, useLayoutEffect } from "react";
|
import React, { useRef, useState, useEffect, useLayoutEffect } from "react";
|
||||||
import { View, Text, TouchableOpacity, Linking } from "react-native";
|
import { View, Text, TouchableOpacity, Linking } from "react-native";
|
||||||
import MapView, { Marker } from "react-native-maps";
|
import MapView from "react-native-maps";
|
||||||
import { MaterialCommunityIcons, Ionicons } from "@expo/vector-icons";
|
|
||||||
import { useCurrentTrain } from "../stateBox/useCurrentTrain";
|
import { useCurrentTrain } from "../stateBox/useCurrentTrain";
|
||||||
import { useNavigation } from "@react-navigation/native";
|
import { useNavigation } from "@react-navigation/native";
|
||||||
import lineColorList from "../assets/originData/lineColorList";
|
import lineColorList from "../assets/originData/lineColorList";
|
||||||
@ -15,7 +14,7 @@ import { MapsButton } from "./TrainMenu/MapsButton";
|
|||||||
export default function TrainMenu({ style }) {
|
export default function TrainMenu({ style }) {
|
||||||
const { webview } = useCurrentTrain();
|
const { webview } = useCurrentTrain();
|
||||||
const mapRef = useRef();
|
const mapRef = useRef();
|
||||||
const { navigate } = useNavigation();
|
const { navigate, goBack } = useNavigation();
|
||||||
const [stationPin, setStationPin] = useState([]);
|
const [stationPin, setStationPin] = useState([]);
|
||||||
const {
|
const {
|
||||||
selectedLine,
|
selectedLine,
|
||||||
@ -36,10 +35,9 @@ export default function TrainMenu({ style }) {
|
|||||||
).split(",");
|
).split(",");
|
||||||
if (latlng.length == 0) return null;
|
if (latlng.length == 0) return null;
|
||||||
if (index == 0 && stationPin.length > 0) {
|
if (index == 0 && stationPin.length > 0) {
|
||||||
setInjectJavaScript(
|
webview.current
|
||||||
`MoveDisplayStation('${d}_${D.MyStation}_${D.Station_JP}');
|
?.injectJavaScript(`MoveDisplayStation('${d}_${D.MyStation}_${D.Station_JP}');
|
||||||
document.getElementById("disp").insertAdjacentHTML("afterbegin", "<div />");`
|
document.getElementById("disp").insertAdjacentHTML("afterbegin", "<div />");`);
|
||||||
);
|
|
||||||
}
|
}
|
||||||
stationPinData.push({ D, d, latlng, indexBase: 0, index });
|
stationPinData.push({ D, d, latlng, indexBase: 0, index });
|
||||||
});
|
});
|
||||||
@ -82,7 +80,7 @@ export default function TrainMenu({ style }) {
|
|||||||
d={d}
|
d={d}
|
||||||
navigate={navigate}
|
navigate={navigate}
|
||||||
webview={webview}
|
webview={webview}
|
||||||
key={D.StationNumber+d}
|
key={D.StationNumber + d}
|
||||||
/>
|
/>
|
||||||
))}
|
))}
|
||||||
</MapView>
|
</MapView>
|
||||||
@ -201,7 +199,7 @@ export default function TrainMenu({ style }) {
|
|||||||
)}
|
)}
|
||||||
<MapsButton
|
<MapsButton
|
||||||
onPress={() => {
|
onPress={() => {
|
||||||
navigate("Apps");
|
goBack();
|
||||||
webview.current?.injectJavaScript(injectJavaScript);
|
webview.current?.injectJavaScript(injectJavaScript);
|
||||||
}}
|
}}
|
||||||
top={0}
|
top={0}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import React, { useRef } from "react";
|
import React from "react";
|
||||||
import { StatusBar, Platform, View } from "react-native";
|
import { StatusBar, Platform, View } from "react-native";
|
||||||
import { WebView } from "react-native-webview";
|
import { WebView } from "react-native-webview";
|
||||||
import { MaterialCommunityIcons } from "@expo/vector-icons";
|
import { MaterialCommunityIcons } from "@expo/vector-icons";
|
||||||
@ -6,21 +6,19 @@ import { useNavigation } from "@react-navigation/native";
|
|||||||
import { BigButton } from "./atom/BigButton";
|
import { BigButton } from "./atom/BigButton";
|
||||||
|
|
||||||
export default function TrainBase({ route }) {
|
export default function TrainBase({ route }) {
|
||||||
const { info, from } = route.params;
|
const { info } = route.params;
|
||||||
const { navigate } = useNavigation();
|
const { goBack } = useNavigation();
|
||||||
const webview = useRef();
|
|
||||||
const jss = `document.getElementById('Footer').style.display = 'none';
|
const jss = `document.getElementById('Footer').style.display = 'none';
|
||||||
${
|
${
|
||||||
Platform.OS == "ios" &&
|
Platform.OS == "ios"
|
||||||
`document.getElementsByTagName("html")[0].style['font-size'] = '11px';`
|
? `document.getElementsByTagName("html")[0].style['font-size'] = '11px';`
|
||||||
|
: ""
|
||||||
}`;
|
}`;
|
||||||
//const jss = `alert("ほげ")`;
|
|
||||||
return (
|
return (
|
||||||
<View style={{ height: "100%" }}>
|
<View style={{ height: "100%" }}>
|
||||||
{Platform.OS == "ios" && <StatusBar barStyle="dark-content" />}
|
{Platform.OS == "ios" && <StatusBar barStyle="dark-content" />}
|
||||||
<WebView
|
<WebView
|
||||||
//useWebKit={true}
|
useWebKit={true}
|
||||||
ref={webview}
|
|
||||||
source={{ uri: "https://train.jr-shikoku.co.jp/" + info }}
|
source={{ uri: "https://train.jr-shikoku.co.jp/" + info }}
|
||||||
originWhitelist={[
|
originWhitelist={[
|
||||||
"https://train.jr-shikoku.co.jp",
|
"https://train.jr-shikoku.co.jp",
|
||||||
@ -30,20 +28,15 @@ export default function TrainBase({ route }) {
|
|||||||
javaScriptEnabled={true}
|
javaScriptEnabled={true}
|
||||||
injectedJavaScript={jss}
|
injectedJavaScript={jss}
|
||||||
setSupportMultipleWindows={false}
|
setSupportMultipleWindows={false}
|
||||||
onMessage={(event) => {}}
|
|
||||||
/>
|
/>
|
||||||
{(from == "LED" || from == "LED2" || from == "AllTrainIDList") && (
|
|
||||||
<BigButton
|
<BigButton
|
||||||
style={{ borderColor: "black" }}
|
style={{ borderColor: "black" }}
|
||||||
tS={{ color: "black" }}
|
tS={{ color: "black" }}
|
||||||
string="閉じる"
|
string="閉じる"
|
||||||
onPress={() =>
|
onPress={goBack}
|
||||||
navigate(from == "AllTrainIDList" ? "AllTrainIDList" : "menu")
|
|
||||||
}
|
|
||||||
>
|
>
|
||||||
<MaterialCommunityIcons name="close" color="black" size={30} />
|
<MaterialCommunityIcons name="close" color="black" size={30} />
|
||||||
</BigButton>
|
</BigButton>
|
||||||
)}
|
|
||||||
</View>
|
</View>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
7
howto.js
@ -7,12 +7,11 @@ export default ({ navigation: { navigate }, route }) => {
|
|||||||
const { info, goTo, useShow } = route.params;
|
const { info, goTo, useShow } = route.params;
|
||||||
const { goBack } = useNavigation();
|
const { goBack } = useNavigation();
|
||||||
const onExit = () => {
|
const onExit = () => {
|
||||||
if(goTo != "NearTrainDiagramView") {
|
if (goTo != "NearTrainDiagramView") {
|
||||||
navigate(goTo || "Apps");
|
//navigate(goTo || "Apps");
|
||||||
useShow && useShow();
|
useShow && useShow();
|
||||||
} else {
|
|
||||||
goBack();
|
|
||||||
}
|
}
|
||||||
|
goBack();
|
||||||
};
|
};
|
||||||
return (
|
return (
|
||||||
<View style={styles}>
|
<View style={styles}>
|
||||||
|
@ -6,13 +6,13 @@ export const initIcon = (name: name, type:type) => {
|
|||||||
switch (type) {
|
switch (type) {
|
||||||
case "Ionicons":
|
case "Ionicons":
|
||||||
return ({ focused, color, size }) => (
|
return ({ focused, color, size }) => (
|
||||||
<Ionicons name={name} size={32} color={focused ? "#0099CC" : "black"} />
|
<Ionicons name={name} size={30} color={focused ? "#0099CC" : "black"} />
|
||||||
);
|
);
|
||||||
case "AntDesign":
|
case "AntDesign":
|
||||||
return ({ focused, color, size }) => (
|
return ({ focused, color, size }) => (
|
||||||
<AntDesign
|
<AntDesign
|
||||||
name={name}
|
name={name}
|
||||||
size={32}
|
size={30}
|
||||||
color={focused ? "#0099CC" : "black"}
|
color={focused ? "#0099CC" : "black"}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
85
menu.js
@ -1,5 +1,5 @@
|
|||||||
import React, { useRef, useState, useEffect } from "react";
|
import React, { useRef, useState, useEffect } from "react";
|
||||||
import Carousel, { Pagination } from "react-native-snap-carousel";
|
import Carousel from "react-native-reanimated-carousel";
|
||||||
import {
|
import {
|
||||||
Platform,
|
Platform,
|
||||||
View,
|
View,
|
||||||
@ -8,6 +8,7 @@ import {
|
|||||||
Text,
|
Text,
|
||||||
TouchableOpacity,
|
TouchableOpacity,
|
||||||
LayoutAnimation,
|
LayoutAnimation,
|
||||||
|
Dimensions,
|
||||||
} from "react-native";
|
} from "react-native";
|
||||||
import Constants from "expo-constants";
|
import Constants from "expo-constants";
|
||||||
import * as Location from "expo-location";
|
import * as Location from "expo-location";
|
||||||
@ -32,7 +33,7 @@ import { SheetManager } from "react-native-actions-sheet";
|
|||||||
import { useTrainDelayData } from "./stateBox/useTrainDelayData";
|
import { useTrainDelayData } from "./stateBox/useTrainDelayData";
|
||||||
import { useNavigation } from "@react-navigation/native";
|
import { useNavigation } from "@react-navigation/native";
|
||||||
import { useStationList } from "./stateBox/useStationList";
|
import { useStationList } from "./stateBox/useStationList";
|
||||||
import { Paginations } from "./components/Menu/StationPagination";
|
import { StationNumber } from "./components/Menu/StationPagination";
|
||||||
import lineColorList from "./assets/originData/lineColorList";
|
import lineColorList from "./assets/originData/lineColorList";
|
||||||
import { AS } from "./storageControl";
|
import { AS } from "./storageControl";
|
||||||
|
|
||||||
@ -118,13 +119,13 @@ export default function Menu({ getCurrentTrain }) {
|
|||||||
const count = selectedCurrentStation - 1;
|
const count = selectedCurrentStation - 1;
|
||||||
setSelectedCurrentStation(count);
|
setSelectedCurrentStation(count);
|
||||||
}
|
}
|
||||||
}, [selectedCurrentStation, currentStation, favoriteStation]);
|
}, [selectedCurrentStation, currentStation, allStationData]);
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (!carouselRef.current) return;
|
if (!carouselRef.current) return;
|
||||||
if (carouselRef.current?._itemToSnapTo != selectedCurrentStation) {
|
carouselRef?.current.scrollTo({
|
||||||
carouselRef.current.snapToItem(0);
|
count: selectedCurrentStation - carouselRef.current.getCurrentIndex(),
|
||||||
carouselRef.current.snapToItem(selectedCurrentStation);
|
animated: true,
|
||||||
}
|
});
|
||||||
}, [selectedCurrentStation]);
|
}, [selectedCurrentStation]);
|
||||||
|
|
||||||
//全列車ダイヤリストを作成するuseEffect
|
//全列車ダイヤリストを作成するuseEffect
|
||||||
@ -174,10 +175,11 @@ export default function Menu({ getCurrentTrain }) {
|
|||||||
});
|
});
|
||||||
AS.setItem(
|
AS.setItem(
|
||||||
"CarouselSettings/activeDotSettings",
|
"CarouselSettings/activeDotSettings",
|
||||||
!dotButton ? "true": "false"
|
!dotButton ? "true" : "false"
|
||||||
);
|
);
|
||||||
setDotButton(!dotButton);
|
setDotButton(!dotButton);
|
||||||
}
|
};
|
||||||
|
const width = Dimensions.get("window").width;
|
||||||
return (
|
return (
|
||||||
<View
|
<View
|
||||||
style={{
|
style={{
|
||||||
@ -191,41 +193,67 @@ export default function Menu({ getCurrentTrain }) {
|
|||||||
<ScrollView>
|
<ScrollView>
|
||||||
<TopMenuButton />
|
<TopMenuButton />
|
||||||
{originalStationList.length != 0 && allStationData.length != 0 && (
|
{originalStationList.length != 0 && allStationData.length != 0 && (
|
||||||
<>
|
<View style={{ flex: 1, paddingTop: 10 }}>
|
||||||
<Carousel
|
<Carousel
|
||||||
ref={carouselRef}
|
ref={carouselRef}
|
||||||
layout={"default"}
|
|
||||||
data={originalStationList && allStationData}
|
data={originalStationList && allStationData}
|
||||||
sliderWidth={wp("100%")}
|
height={(wp("80%") / 20) * 9 + 10}
|
||||||
itemWidth={wp("80%")}
|
pagingEnabled={true}
|
||||||
enableMomentum
|
snapEnabled={true}
|
||||||
callbackOffsetMargin={1000}
|
loop={false}
|
||||||
activeAnimationOptions={0.3}
|
width={width}
|
||||||
|
style={{ width: width, alignContent: "center" }}
|
||||||
|
mode="parallax"
|
||||||
|
modeConfig={{
|
||||||
|
parallaxScrollingScale: 1,
|
||||||
|
parallaxScrollingOffset: 100,
|
||||||
|
parallaxAdjacentItemScale: 0.8,
|
||||||
|
}}
|
||||||
onSnapToItem={setSelectedCurrentStation}
|
onSnapToItem={setSelectedCurrentStation}
|
||||||
renderItem={({ item }) => {
|
renderItem={({ item, index }) => {
|
||||||
return (
|
return (
|
||||||
<View
|
<View
|
||||||
style={{ marginVertical: 10 }}
|
style={{
|
||||||
|
backgroundColor: "#0000",
|
||||||
|
width: width,
|
||||||
|
flexDirection: "row",
|
||||||
|
marginLeft: 0,
|
||||||
|
marginRight: 0,
|
||||||
|
}}
|
||||||
key={item[0].StationNumber}
|
key={item[0].StationNumber}
|
||||||
>
|
>
|
||||||
|
<View style={{ flex: 1 }} />
|
||||||
<Sign
|
<Sign
|
||||||
currentStation={item}
|
currentStation={item}
|
||||||
isCurrentStation={item == currentStation}
|
isCurrentStation={item == currentStation}
|
||||||
oP={oPSign}
|
oP={oPSign}
|
||||||
oLP={oLPSign}
|
oLP={oLPSign}
|
||||||
/>
|
/>
|
||||||
|
<View style={{ flex: 1 }} />
|
||||||
</View>
|
</View>
|
||||||
);
|
);
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
<Paginations
|
<View
|
||||||
entries={allStationData}
|
style={{
|
||||||
activeSlide={selectedCurrentStation}
|
flexDirection: "row",
|
||||||
carouselRef={carouselRef}
|
justifyContent: "center",
|
||||||
setSelectedCurrentStation={setSelectedCurrentStation}
|
alignContent: "center",
|
||||||
dotButton={dotButton}
|
alignItems: "center",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{originalStationList &&
|
||||||
|
allStationData.map((d, index) => {
|
||||||
|
return (
|
||||||
|
<StationNumber
|
||||||
|
currentStation={d}
|
||||||
|
active={index == selectedCurrentStation}
|
||||||
|
onPress={() => setSelectedCurrentStation(index)}
|
||||||
/>
|
/>
|
||||||
</>
|
);
|
||||||
|
})}
|
||||||
|
</View>
|
||||||
|
</View>
|
||||||
)}
|
)}
|
||||||
{allStationData.length != 0 &&
|
{allStationData.length != 0 &&
|
||||||
originalStationList.length != 0 &&
|
originalStationList.length != 0 &&
|
||||||
@ -362,10 +390,13 @@ const JRSTraInfoBox = () => {
|
|||||||
/>
|
/>
|
||||||
</View>
|
</View>
|
||||||
) : delayData ? (
|
) : delayData ? (
|
||||||
delayData.map((d,index,array) => {
|
delayData.map((d, index, array) => {
|
||||||
let data = d.split(" ");
|
let data = d.split(" ");
|
||||||
return (
|
return (
|
||||||
<View style={{ flexDirection: "row" }} key={data[1] + "key"+index}>
|
<View
|
||||||
|
style={{ flexDirection: "row" }}
|
||||||
|
key={data[1] + "key" + index}
|
||||||
|
>
|
||||||
<Text style={{ flex: 15, fontSize: 18 }}>
|
<Text style={{ flex: 15, fontSize: 18 }}>
|
||||||
{data[0].replace("\n", "")}
|
{data[0].replace("\n", "")}
|
||||||
</Text>
|
</Text>
|
||||||
|
71
package.json
@ -8,54 +8,63 @@
|
|||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@expo/ngrok": "^4.1.0",
|
"@expo/ngrok": "^4.1.0",
|
||||||
"@expo/vector-icons": "^14.0.0",
|
"@expo/vector-icons": "^14.0.2",
|
||||||
"@react-native-async-storage/async-storage": "1.21.0",
|
"@react-native-async-storage/async-storage": "1.23.1",
|
||||||
"@react-native-community/masked-view": "0.1.10",
|
"@react-native-masked-view/masked-view": "0.3.2",
|
||||||
"@react-navigation/bottom-tabs": "^5.11.11",
|
"@react-navigation/bottom-tabs": "^7.2.0",
|
||||||
"@react-navigation/native": "^5.9.4",
|
"@react-navigation/native": "^7.0.14",
|
||||||
"@react-navigation/stack": "^5.14.5",
|
"@react-navigation/stack": "^7.1.1",
|
||||||
"dayjs": "^1.11.9",
|
"dayjs": "^1.11.9",
|
||||||
"eas-cli": "^5.9.1",
|
"expo": "^52.0.0",
|
||||||
"expo": "^50.0.11",
|
"expo-alternate-app-icons": "^1.3.0",
|
||||||
"expo-dev-client": "~3.3.9",
|
"expo-clipboard": "~7.0.1",
|
||||||
"expo-device": "~5.9.3",
|
"expo-constants": "~17.0.4",
|
||||||
"expo-font": "~11.10.3",
|
"expo-dev-client": "~5.0.9",
|
||||||
"expo-location": "~16.5.5",
|
"expo-device": "~7.0.2",
|
||||||
"expo-notifications": "~0.27.6",
|
"expo-font": "~13.0.3",
|
||||||
"expo-screen-orientation": "~6.4.1",
|
"expo-haptics": "~14.0.1",
|
||||||
"expo-sharing": "~11.10.0",
|
"expo-intent-launcher": "~12.0.2",
|
||||||
"expo-updates": "~0.24.11",
|
"expo-linear-gradient": "~14.0.2",
|
||||||
"expo-web-browser": "~12.8.2",
|
"expo-linking": "~7.0.4",
|
||||||
|
"expo-localization": "~16.0.1",
|
||||||
|
"expo-location": "~18.0.5",
|
||||||
|
"expo-notifications": "~0.29.12",
|
||||||
|
"expo-screen-orientation": "~8.0.4",
|
||||||
|
"expo-sharing": "~13.0.1",
|
||||||
|
"expo-status-bar": "~2.0.1",
|
||||||
|
"expo-updates": "~0.26.12",
|
||||||
|
"expo-video": "~2.0.5",
|
||||||
|
"expo-web-browser": "~14.0.2",
|
||||||
"firebase": "8.2.3",
|
"firebase": "8.2.3",
|
||||||
"lottie-react-native": "6.5.1",
|
"lottie-react-native": "7.1.0",
|
||||||
"native-base": "^2.15.2",
|
"native-base": "^2.15.2",
|
||||||
"npm": "^7.18.1",
|
|
||||||
"pushy-react-native": "^1.0.18",
|
"pushy-react-native": "^1.0.18",
|
||||||
"react": "18.2.0",
|
"react": "18.3.1",
|
||||||
"react-native": "0.73.4",
|
"react-native": "0.76.6",
|
||||||
"react-native-actions-sheet": "0.8.21",
|
"react-native-actions-sheet": "0.8.21",
|
||||||
"react-native-android-widget": "^0.11.2",
|
"react-native-android-widget": "^0.15.1",
|
||||||
"react-native-auto-height-image": "^3.2.4",
|
"react-native-auto-height-image": "^3.2.4",
|
||||||
"react-native-elements": "^3.4.2",
|
"react-native-elements": "^3.4.2",
|
||||||
"react-native-gesture-handler": "~2.14.0",
|
"react-native-gesture-handler": "~2.20.2",
|
||||||
"react-native-maps": "1.10.0",
|
"react-native-maps": "1.18.0",
|
||||||
"react-native-reanimated": "~3.6.2",
|
"react-native-reanimated": "~3.16.1",
|
||||||
|
"react-native-reanimated-carousel": "^3.5.1",
|
||||||
"react-native-remote-svg": "^2.0.6",
|
"react-native-remote-svg": "^2.0.6",
|
||||||
"react-native-responsive-screen": "^1.4.2",
|
"react-native-responsive-screen": "^1.4.2",
|
||||||
"react-native-router-flux": "^4.3.1",
|
"react-native-router-flux": "^4.3.1",
|
||||||
"react-native-safe-area-context": "4.8.2",
|
"react-native-safe-area-context": "4.12.0",
|
||||||
"react-native-screens": "~3.29.0",
|
"react-native-screens": "~4.4.0",
|
||||||
"react-native-snap-carousel": "^3.9.1",
|
"react-native-snap-carousel": "^3.9.1",
|
||||||
"react-native-storage": "^1.0.1",
|
"react-native-storage": "^1.0.1",
|
||||||
"react-native-svg": "14.1.0",
|
"react-native-svg": "15.8.0",
|
||||||
"react-native-svg-uri": "^1.2.3",
|
"react-native-svg-uri": "^1.2.3",
|
||||||
"react-native-vector-icons": "^8.1.0",
|
"react-native-vector-icons": "^8.1.0",
|
||||||
"react-native-view-shot": "3.8.0",
|
"react-native-view-shot": "~4.0.3",
|
||||||
"react-native-webview": "13.6.4",
|
"react-native-webview": "13.12.5",
|
||||||
"typescript": "^5.3.0"
|
"typescript": "^5.3.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"babel-preset-expo": "^10.0.0"
|
"babel-preset-expo": "~12.0.0"
|
||||||
},
|
},
|
||||||
"private": true
|
"private": true
|
||||||
}
|
}
|
||||||
|
@ -42,7 +42,9 @@ export const TrainMenuProvider = ({ children }) => {
|
|||||||
const [mapsStationData, setMapsStationData] = useState(undefined);
|
const [mapsStationData, setMapsStationData] = useState(undefined);
|
||||||
const [injectJavaScript, setInjectJavaScript] = useState();
|
const [injectJavaScript, setInjectJavaScript] = useState();
|
||||||
|
|
||||||
useEffect(() => getStationList2().then(setMapsStationData), []);
|
useEffect(() => {
|
||||||
|
getStationList2().then(setMapsStationData);
|
||||||
|
}, []);
|
||||||
|
|
||||||
//画面表示関連
|
//画面表示関連
|
||||||
const [iconSetting, setIconSetting] = useState(undefined);
|
const [iconSetting, setIconSetting] = useState(undefined);
|
||||||
|