@dynamic-labs/react-native-extension 4.19.0 → 4.19.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.cjs +9 -1
- package/index.js +9 -1
- package/package.json +5 -5
package/index.cjs
CHANGED
|
@@ -14,7 +14,7 @@ var expoLinking = require('expo-linking');
|
|
|
14
14
|
var expoWebBrowser = require('expo-web-browser');
|
|
15
15
|
var expoSecureStore = require('expo-secure-store');
|
|
16
16
|
|
|
17
|
-
var version = "4.19.
|
|
17
|
+
var version = "4.19.1";
|
|
18
18
|
|
|
19
19
|
function _extends() {
|
|
20
20
|
return _extends = Object.assign ? Object.assign.bind() : function (n) {
|
|
@@ -152,6 +152,13 @@ const WebView = ({
|
|
|
152
152
|
[]);
|
|
153
153
|
const blockAndReloadWebView = react.useCallback(() => {
|
|
154
154
|
var _a;
|
|
155
|
+
/**
|
|
156
|
+
* Should not reload the webview if it is already blocked
|
|
157
|
+
* and loading a new page
|
|
158
|
+
*/
|
|
159
|
+
if (core.messageTransport.isBlocked()) {
|
|
160
|
+
return;
|
|
161
|
+
}
|
|
155
162
|
/**
|
|
156
163
|
* iOS and Android both may trigger this event when the webview
|
|
157
164
|
* is removed due to memory pressure.
|
|
@@ -163,6 +170,7 @@ const WebView = ({
|
|
|
163
170
|
core.messageTransport.block();
|
|
164
171
|
(_a = webViewRef.current) === null || _a === void 0 ? void 0 : _a.reload();
|
|
165
172
|
}, [core, webViewRef]);
|
|
173
|
+
react.useEffect(() => core.messageTransport.recoveryManager.onRecoveryRequested(blockAndReloadWebView), [core, blockAndReloadWebView]);
|
|
166
174
|
return /*#__PURE__*/jsxRuntime.jsx(reactNativeWebview.WebView, {
|
|
167
175
|
ref: webViewRef,
|
|
168
176
|
source: {
|
package/index.js
CHANGED
|
@@ -10,7 +10,7 @@ import { createURL, openURL } from 'expo-linking';
|
|
|
10
10
|
import { openAuthSessionAsync } from 'expo-web-browser';
|
|
11
11
|
import { getItemAsync, deleteItemAsync, setItemAsync } from 'expo-secure-store';
|
|
12
12
|
|
|
13
|
-
var version = "4.19.
|
|
13
|
+
var version = "4.19.1";
|
|
14
14
|
|
|
15
15
|
function _extends() {
|
|
16
16
|
return _extends = Object.assign ? Object.assign.bind() : function (n) {
|
|
@@ -148,6 +148,13 @@ const WebView = ({
|
|
|
148
148
|
[]);
|
|
149
149
|
const blockAndReloadWebView = useCallback(() => {
|
|
150
150
|
var _a;
|
|
151
|
+
/**
|
|
152
|
+
* Should not reload the webview if it is already blocked
|
|
153
|
+
* and loading a new page
|
|
154
|
+
*/
|
|
155
|
+
if (core.messageTransport.isBlocked()) {
|
|
156
|
+
return;
|
|
157
|
+
}
|
|
151
158
|
/**
|
|
152
159
|
* iOS and Android both may trigger this event when the webview
|
|
153
160
|
* is removed due to memory pressure.
|
|
@@ -159,6 +166,7 @@ const WebView = ({
|
|
|
159
166
|
core.messageTransport.block();
|
|
160
167
|
(_a = webViewRef.current) === null || _a === void 0 ? void 0 : _a.reload();
|
|
161
168
|
}, [core, webViewRef]);
|
|
169
|
+
useEffect(() => core.messageTransport.recoveryManager.onRecoveryRequested(blockAndReloadWebView), [core, blockAndReloadWebView]);
|
|
162
170
|
return /*#__PURE__*/jsx(WebView$1, {
|
|
163
171
|
ref: webViewRef,
|
|
164
172
|
source: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/react-native-extension",
|
|
3
|
-
"version": "4.19.
|
|
3
|
+
"version": "4.19.1",
|
|
4
4
|
"main": "./index.cjs",
|
|
5
5
|
"module": "./index.js",
|
|
6
6
|
"types": "./src/index.d.ts",
|
|
@@ -15,10 +15,10 @@
|
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
17
|
"@turnkey/react-native-passkey-stamper": "0.2.15",
|
|
18
|
-
"@dynamic-labs/assert-package-version": "4.19.
|
|
19
|
-
"@dynamic-labs/client": "4.19.
|
|
20
|
-
"@dynamic-labs/logger": "4.19.
|
|
21
|
-
"@dynamic-labs/message-transport": "4.19.
|
|
18
|
+
"@dynamic-labs/assert-package-version": "4.19.1",
|
|
19
|
+
"@dynamic-labs/client": "4.19.1",
|
|
20
|
+
"@dynamic-labs/logger": "4.19.1",
|
|
21
|
+
"@dynamic-labs/message-transport": "4.19.1"
|
|
22
22
|
},
|
|
23
23
|
"peerDependencies": {
|
|
24
24
|
"react": ">=18.0.0 <20.0.0",
|