1- import { StatusBar } from 'expo-status-bar' ;
2- import { Platform , StyleSheet } from 'react-native' ;
1+ import { AppI18n } from "@/localize" ;
2+ import { APP_THEME } from "@/theme" ;
3+ import { StatusBar } from "expo-status-bar" ;
4+ import { Platform , StyleSheet , Linking , Pressable } from "react-native" ;
35
4- import { Text , View } from ' ../components/Themed' ;
6+ import { Text , View } from " ../components/Themed" ;
57
68export default function ModalScreen ( ) {
9+ const latestVersionUrl =
10+ "https://github.com/xianshenglu/cloudflare-ip-tester-app/releases/latest/download/app-universal-release-signed.apk" ;
711 return (
812 < View style = { styles . container } >
9- < Text style = { styles . title } > Modal </ Text >
13+ < Text style = { styles . title } > Help </ Text >
1014 < View
1115 style = { styles . separator }
1216 lightColor = "#eee"
1317 darkColor = "rgba(255,255,255,0.1)"
1418 />
1519 { /* <TestPage path="/screens/ModalScreen.tsx" /> */ }
20+ < Pressable onPress = { ( ) => Linking . openURL ( latestVersionUrl ) } >
21+ < Text style = { { color : APP_THEME . colors . primary , fontSize : 16 } } >
22+ { AppI18n . t ( "update.downloadLatestVersion" ) }
23+ </ Text >
24+ </ Pressable >
1625
1726 { /* Use a light status bar on iOS to account for the black space above the modal */ }
1827 < StatusBar style = { Platform . OS === "ios" ? "light" : "auto" } />
@@ -23,16 +32,16 @@ export default function ModalScreen() {
2332const styles = StyleSheet . create ( {
2433 container : {
2534 flex : 1 ,
26- alignItems : ' center' ,
27- justifyContent : ' center' ,
35+ alignItems : " center" ,
36+ justifyContent : " center" ,
2837 } ,
2938 title : {
3039 fontSize : 20 ,
31- fontWeight : ' bold' ,
40+ fontWeight : " bold" ,
3241 } ,
3342 separator : {
3443 marginVertical : 30 ,
3544 height : 1 ,
36- width : ' 80%' ,
45+ width : " 80%" ,
3746 } ,
3847} ) ;
0 commit comments