Skip to content

Commit 45b5d6c

Browse files
committed
Fix WebView on new architecture, fix deprecations.
1 parent 1b8fba4 commit 45b5d6c

File tree

5 files changed

+29
-13
lines changed

5 files changed

+29
-13
lines changed

package-lock.json

+14-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
},
1414
"dependencies": {
1515
"@react-native-async-storage/async-storage": "^1.17.10",
16+
"@react-native-clipboard/clipboard": "^1.11.1",
1617
"@react-native-picker/picker": "^2.4.3",
1718
"@react-navigation/bottom-tabs": "^6.3.2",
1819
"@react-navigation/material-top-tabs": "^6.2.2",
@@ -32,7 +33,7 @@
3233
"react-native-tab-view": "^3.1.1",
3334
"react-native-tcp": "github:aprock/react-native-tcp",
3435
"react-native-vector-icons": "^9.2.0",
35-
"react-native-webview": "^11.18.2",
36+
"react-native-webview": "^12.0.0-rc.0",
3637
"semaphore-async-await": "^1.5.1",
3738
"stream-browserify": "^3.0.0",
3839
"zustand": "^4.2.0"

src/components/accounts/MicrosoftLogin.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ const MicrosoftLogin = ({ close }: { close: () => void }) => {
8383
setHtml('<h1>Loading...</h1>')
8484
webview.current.reload()
8585
const suffix = newNavState.url.substring(redirectUrlPrefix.length)
86-
const authCode = suffix.substr(0, suffix.indexOf('&'))
86+
const authCode = suffix.substring(0, suffix.indexOf('&'))
8787
const [msAccessToken, msRefreshToken] = await getMSAuthToken(
8888
authCode,
8989
config.clientId,

src/screens/chat/ChatScreen.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@ import {
1212
ActivityIndicator,
1313
Platform,
1414
Linking,
15-
Clipboard,
1615
ListRenderItem
1716
} from 'react-native'
1817
import Ionicons from 'react-native-vector-icons/Ionicons'
18+
import Clipboard from '@react-native-clipboard/clipboard'
1919
import { NativeStackScreenProps } from '@react-navigation/native-stack'
2020

2121
import {

yarn.lock

+11-6
Original file line numberDiff line numberDiff line change
@@ -1433,6 +1433,11 @@
14331433
dependencies:
14341434
merge-options "^3.0.4"
14351435

1436+
"@react-native-clipboard/clipboard@^1.11.1":
1437+
version "1.11.1"
1438+
resolved "https://registry.npmjs.org/@react-native-clipboard/clipboard/-/clipboard-1.11.1.tgz"
1439+
integrity sha512-nvSIIHzybVWqYxcJE5hpT17ekxAAg383Ggzw5WrYHtkKX61N1AwaKSNmXs5xHV7pmKSOe/yWjtSwxIzfW51I5Q==
1440+
14361441
"@react-native-community/cli-clean@^10.1.1":
14371442
version "10.1.1"
14381443
resolved "https://registry.npmjs.org/@react-native-community/cli-clean/-/cli-clean-10.1.1.tgz"
@@ -6510,15 +6515,15 @@ react-native-vector-icons@^9.2.0:
65106515
prop-types "^15.7.2"
65116516
yargs "^16.1.1"
65126517

6513-
react-native-webview@^11.18.2:
6514-
version "11.26.0"
6515-
resolved "https://registry.npmjs.org/react-native-webview/-/react-native-webview-11.26.0.tgz"
6516-
integrity sha512-4T4CKRm8xlaQDz9h/bCMPGAvtkesrhkRWqCX9FDJEzBToaVUIsV0ZOqtC4w/JSnCtFKKYiaC1ReJtCGv+4mFeQ==
6518+
react-native-webview@^12.0.0-rc.0:
6519+
version "12.0.0-rc.0"
6520+
resolved "https://registry.npmjs.org/react-native-webview/-/react-native-webview-12.0.0-rc.0.tgz"
6521+
integrity sha512-MIDySaWEzpelv0bXEiWoP3fN6WpLet8z5vwgtxVrsNQnXr9oJq68Jaz8Qt3fqYfnUkwCyGOc8097Yg+Stk8vmw==
65176522
dependencies:
65186523
escape-string-regexp "2.0.0"
65196524
invariant "2.2.4"
65206525

6521-
react-native@*, "react-native@^0.0.0-0 || 0.60 - 0.71 || 1000.0.0", react-native@>=0.57, react-native@>=0.60.0, [email protected]:
6526+
react-native@*, "react-native@^0.0.0-0 || 0.60 - 0.71 || 1000.0.0", react-native@>=0.57, react-native@>=0.57.0, react-native@>=0.60.0, [email protected]:
65226527
version "0.71.1"
65236528
resolved "https://registry.npmjs.org/react-native/-/react-native-0.71.1.tgz"
65246529
integrity sha512-bLP5+IBj2IX6tgF9WnC/UL2ZPYkVUPsU4xqZV1jntTC2TH4xyLrvfKACjGlz5nQ3Mx4BmOFqsnMxithm53+6Aw==
@@ -6580,7 +6585,7 @@ [email protected]:
65806585
react-shallow-renderer "^16.15.0"
65816586
scheduler "^0.23.0"
65826587

6583-
react@*, "react@^16.0.0 || ^17.0.0 || ^18.0.0", "react@^16.8.0 || ^17.0.0 || ^18.0.0", react@^18.2.0, react@>=16, react@>=16.8, react@>=17.0.0, [email protected]:
6588+
react@*, "react@^16.0.0 || ^17.0.0 || ^18.0.0", "react@^16.8.0 || ^17.0.0 || ^18.0.0", react@^18.2.0, react@>=16, react@>=16.0, react@>=16.8, react@>=17.0.0, [email protected]:
65846589
version "18.2.0"
65856590
resolved "https://registry.npmjs.org/react/-/react-18.2.0.tgz"
65866591
integrity sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==

0 commit comments

Comments
 (0)