diff --git a/app.config.js b/app.config.js
index 86ed1d8..3784b19 100644
--- a/app.config.js
+++ b/app.config.js
@@ -1,14 +1,19 @@
const withCmakeVersion = require('./plugins/withCmakeVersion')
-const PROJECT_ID = 'c951a6a3-e1d8-4e39-8636-c476da1fe5be'
-const VERSION = '1.0.0'
-const APPNAME = 'duooomi'
-const EXPO_PROJECT = 'duooomi'
-const SCHEME = 'duooomi'
-const EXPO_OWER = 'bowong'
-const ANDROID_ID = 'com.duomi.duooomi'
-const IOS_ID = ANDROID_ID
-const IOS_UNIVERSAL_LINK = 'duooomi.bowong.cn'
+export const PROJECT_ID = 'c951a6a3-e1d8-4e39-8636-c476da1fe5be'
+export const APPNAME = 'duooomi'
+export const EXPO_PROJECT = 'duooomi'
+export const SCHEME = 'duooomi'
+export const EXPO_OWER = 'bowong'
+export const ANDROID_ID = 'com.duomi.duooomi'
+export const IOS_ID = ANDROID_ID
+export const IOS_UNIVERSAL_LINK = 'duooomi.bowong.cn'
+
+// 原生版本,原生代码变更时需要更新此版本号
+export const VERSION = '1.1.0'
+// JavaScript版本,JS代码变更时需要更新此版本号
+export const APP_VERSION = 'dev202601151820'
+
const ALIPAY_SCHEMA = 'alipay2021006119657394'
const ALIPAY_SCHEMA_SANDBOX = 'alipay9021000158673972'
diff --git a/app.constants.js b/app.constants.js
deleted file mode 100644
index e94924a..0000000
--- a/app.constants.js
+++ /dev/null
@@ -1,13 +0,0 @@
-export const PROJECT_ID = 'c951a6a3-e1d8-4e39-8636-c476da1fe5be'
-export const VERSION = '1.0.0'
-export const APPNAME = 'duooomi'
-export const EXPO_PROJECT = 'duooomi'
-export const SCHEME = 'duooomi'
-export const EXPO_OWER = 'bowong'
-export const ANDROID_ID = 'com.duomi.duooomi'
-export const IOS_ID = ANDROID_ID
-export const IOS_UNIVERSAL_LINK = 'duooomi.bowong.cn'
-export const OWNER_ID = 'x3xbTCWf7dbtWu4gGU2TeI054L77xtkt'
-export const APP_VERSION = 'dev202601141820'
-export const ALIPAY_SCHEMA = 'alipay2021006119657394'
-export const ALIPAY_SCHEMA_SANDBOX = '9021000158673972'
diff --git a/app/(tabs)/explore.tsx b/app/(tabs)/explore.tsx
index c355f34..fd4f97c 100644
--- a/app/(tabs)/explore.tsx
+++ b/app/(tabs)/explore.tsx
@@ -9,7 +9,7 @@ import { KeyboardAwareScrollView } from 'react-native-keyboard-controller'
import { imgPicker } from '@/@share/apis'
import { Block, Toast, VideoBox } from '@/@share/components'
-import { APP_VERSION } from '@/app.constants'
+import { APP_VERSION } from '@/app.config'
import { BLE_UUIDS, PROTOCOL_VERSION } from '@/ble'
import { bleManager } from '@/ble/managers/bleManager'
import { ThemedText } from '@/components/themed-text'
@@ -31,10 +31,10 @@ export default observer(function TabTwoScreen() {
discoveredDevices,
loading,
error,
-
- contents,
} = bleStore.state
+ const { galleryList: contents } = bleStore
+
const bleSessionId = bleStore.bleSessionId
const startScan = () => bleManager.startScan()
diff --git a/app/_layout.tsx b/app/_layout.tsx
index cc865eb..f2f92de 100644
--- a/app/_layout.tsx
+++ b/app/_layout.tsx
@@ -3,7 +3,7 @@ import 'react-native-reanimated'
import { DarkTheme, DefaultTheme, ThemeProvider } from '@react-navigation/native'
import * as Sentry from '@sentry/react-native'
-// import { useKeepAwake } from 'expo-keep-awake'
+import { useKeepAwake } from 'expo-keep-awake'
import { Stack, useNavigationContainerRef } from 'expo-router'
import { StatusBar } from 'expo-status-bar'
import { useEffect } from 'react'
@@ -93,6 +93,7 @@ function RootLayout() {
+
)
@@ -101,7 +102,7 @@ function RootLayout() {
function Providers({ children }: { children: React.ReactNode }) {
const colorScheme = useColorScheme()
useUserSession()
- // useKeepAwake()
+ useKeepAwake()
return (
diff --git a/app/auth.tsx b/app/auth.tsx
index afdcb2c..da405dc 100644
--- a/app/auth.tsx
+++ b/app/auth.tsx
@@ -5,7 +5,7 @@ import React, { useCallback, useMemo, useState } from 'react'
import { TextInput } from 'react-native'
import { KeyboardAwareScrollView } from 'react-native-keyboard-controller'
-import { APP_VERSION } from '@/app.constants'
+import { APP_VERSION } from '@/app.config'
import BannerSection from '@/components/BannerSection'
import { emailOtp as emailOtpService, setAuthToken, signIn, signUp } from '@/lib/auth'
import { isValidEmail } from '@/utils'
diff --git a/app/forgotPassword.tsx b/app/forgotPassword.tsx
index 651aba1..fd00e92 100644
--- a/app/forgotPassword.tsx
+++ b/app/forgotPassword.tsx
@@ -1,4 +1,3 @@
-// ...existing code...
import { Ionicons } from '@expo/vector-icons'
import { Block, Text, Toast } from '@share/components'
import { router } from 'expo-router'
diff --git a/app/pointList.native.tsx b/app/pointList.native.tsx
index 0c41fb4..0e7b997 100644
--- a/app/pointList.native.tsx
+++ b/app/pointList.native.tsx
@@ -11,7 +11,7 @@ import { Dimensions, Platform, RefreshControl, ScrollView } from 'react-native'
import { useSafeAreaInsets } from 'react-native-safe-area-context'
import { Block, Img, Text, Toast } from '@/@share/components'
-import { IOS_UNIVERSAL_LINK, SCHEME } from '@/app.constants'
+import { IOS_UNIVERSAL_LINK, SCHEME } from '@/app.config'
import { handleError } from '@/hooks/data/use-error'
import { userBalanceStore } from '@/stores'
import { openUrl } from '@/utils'
@@ -114,10 +114,12 @@ const ChargePage = observer(function ChargePage() {
}
const openWeb = () => {
+ // webview 显示异常
// router.push({
// pathname: '/webview',
// params: {
- // url: 'https://example.com/agreement',
+ // // url: 'http://baidu.com',
+ // url: 'https://mixvideo.bowong.cc/terms',
// title: '付费服务协议',
// },
// })
diff --git a/app/webview.tsx b/app/webview.tsx
index 59a1895..c6c7cd3 100644
--- a/app/webview.tsx
+++ b/app/webview.tsx
@@ -1,6 +1,6 @@
import { Ionicons } from '@expo/vector-icons'
import { Block, Text } from '@share/components'
-import { router, useLocalSearchParams } from 'expo-router'
+import { router, Stack, useLocalSearchParams } from 'expo-router'
import { useRef, useState } from 'react'
import { ActivityIndicator, Alert, Share } from 'react-native'
import { useSafeAreaInsets } from 'react-native-safe-area-context'
@@ -22,9 +22,9 @@ export default function WebViewPage() {
if (!url) {
return (
-
+
- URL参数缺失
+ URL参数缺失
router.back()}>
返回
@@ -118,51 +118,21 @@ export default function WebViewPage() {
}
}
- return (
-
- {/* Header */}
-
-
-
-
-
-
-
- {title || '网页浏览'}
-
-
- {currentUrl}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ const renderHeader = () => (
+
+ router.back()}>
+
+ {title}
+
+
+ )
+ return (
+
+
+
+ {/* Header */}
+ {renderHeader()}
{/* Progress Bar */}
{loading && progress < 1 && (
@@ -184,7 +154,7 @@ export default function WebViewPage() {
setLoading(false)}
onLoadStart={() => setLoading(true)}
onLoadEnd={() => setLoading(false)}
diff --git a/bun.lock b/bun.lock
index 0996c97..d682b2d 100644
--- a/bun.lock
+++ b/bun.lock
@@ -37,6 +37,7 @@
"expo-image-manipulator": "~14.0.8",
"expo-image-picker": "~17.0.8",
"expo-insights": "~0.10.8",
+ "expo-keep-awake": "^15.0.8",
"expo-linear-gradient": "^15.0.8",
"expo-linking": "^8.0.10",
"expo-media-library": "~18.2.0",
@@ -71,6 +72,7 @@
"react-native-svg": "^15.15.1",
"react-native-video": "^6.18.0",
"react-native-web": "~0.21.0",
+ "react-native-webview": "^13.16.0",
"react-native-worklets": "0.5.1",
"tailwind-variants": "^0.2.1",
"twrnc": "^4.11.1",
diff --git a/package.json b/package.json
index dd43f8a..d15b628 100644
--- a/package.json
+++ b/package.json
@@ -65,6 +65,7 @@
"expo-image-manipulator": "~14.0.8",
"expo-image-picker": "~17.0.8",
"expo-insights": "~0.10.8",
+ "expo-keep-awake": "^15.0.8",
"expo-linear-gradient": "^15.0.8",
"expo-linking": "^8.0.10",
"expo-media-library": "~18.2.0",
@@ -99,6 +100,7 @@
"react-native-svg": "^15.15.1",
"react-native-video": "^6.18.0",
"react-native-web": "~0.21.0",
+ "react-native-webview": "^13.16.0",
"react-native-worklets": "0.5.1",
"tailwind-variants": "^0.2.1",
"twrnc": "^4.11.1",