@getpara/core-sdk 1.0.1 → 1.0.2
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/dist/cjs/ParaCore.js +9 -3
- package/dist/esm/ParaCore.js +9 -3
- package/package.json +3 -3
package/dist/cjs/ParaCore.js
CHANGED
|
@@ -73,7 +73,7 @@ const recovery_js_1 = require("./shares/recovery.js");
|
|
|
73
73
|
const libphonenumber_js_1 = __importDefault(require("libphonenumber-js"));
|
|
74
74
|
const formattingUtils_js_1 = require("./utils/formattingUtils.js");
|
|
75
75
|
const errors_js_1 = require("./errors.js");
|
|
76
|
-
const PARA_CORE_VERSION = '1.0.
|
|
76
|
+
const PARA_CORE_VERSION = '1.0.2';
|
|
77
77
|
function dispatchEvent(type, data, error) {
|
|
78
78
|
typeof window !== 'undefined' &&
|
|
79
79
|
!!window.dispatchEvent &&
|
|
@@ -256,11 +256,17 @@ class ParaCore {
|
|
|
256
256
|
};
|
|
257
257
|
}
|
|
258
258
|
isPortal(envOverride) {
|
|
259
|
-
|
|
259
|
+
var _a;
|
|
260
|
+
if (typeof window === 'undefined')
|
|
261
|
+
return false;
|
|
262
|
+
return (!!((_a = window.location) === null || _a === void 0 ? void 0 : _a.host) &&
|
|
260
263
|
(0, definitions_js_1.getPortalBaseURL)(envOverride ? { env: envOverride } : this.ctx).includes(window.location.host));
|
|
261
264
|
}
|
|
262
265
|
isParaConnect() {
|
|
263
|
-
|
|
266
|
+
var _a;
|
|
267
|
+
if (typeof window === 'undefined')
|
|
268
|
+
return false;
|
|
269
|
+
return !!((_a = window.location) === null || _a === void 0 ? void 0 : _a.host) && (0, definitions_js_1.getParaConnectBaseUrl)(this.ctx).includes(window.location.host);
|
|
264
270
|
}
|
|
265
271
|
requireApiKey() {
|
|
266
272
|
if (!this.ctx.apiKey) {
|
package/dist/esm/ParaCore.js
CHANGED
|
@@ -44,7 +44,7 @@ import { sendRecoveryForShare } from './shares/recovery.js';
|
|
|
44
44
|
import parsePhoneNumberFromString from 'libphonenumber-js';
|
|
45
45
|
import { getCosmosAddress, truncateAddress } from './utils/formattingUtils.js';
|
|
46
46
|
import { TransactionReviewDenied, TransactionReviewError, TransactionReviewTimeout } from './errors.js';
|
|
47
|
-
const PARA_CORE_VERSION = '1.0.
|
|
47
|
+
const PARA_CORE_VERSION = '1.0.2';
|
|
48
48
|
function dispatchEvent(type, data, error) {
|
|
49
49
|
typeof window !== 'undefined' &&
|
|
50
50
|
!!window.dispatchEvent &&
|
|
@@ -220,11 +220,17 @@ export class ParaCore {
|
|
|
220
220
|
};
|
|
221
221
|
}
|
|
222
222
|
isPortal(envOverride) {
|
|
223
|
-
|
|
223
|
+
var _a;
|
|
224
|
+
if (typeof window === 'undefined')
|
|
225
|
+
return false;
|
|
226
|
+
return (!!((_a = window.location) === null || _a === void 0 ? void 0 : _a.host) &&
|
|
224
227
|
getPortalBaseURL(envOverride ? { env: envOverride } : this.ctx).includes(window.location.host));
|
|
225
228
|
}
|
|
226
229
|
isParaConnect() {
|
|
227
|
-
|
|
230
|
+
var _a;
|
|
231
|
+
if (typeof window === 'undefined')
|
|
232
|
+
return false;
|
|
233
|
+
return !!((_a = window.location) === null || _a === void 0 ? void 0 : _a.host) && getParaConnectBaseUrl(this.ctx).includes(window.location.host);
|
|
228
234
|
}
|
|
229
235
|
requireApiKey() {
|
|
230
236
|
if (!this.ctx.apiKey) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@getpara/core-sdk",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"main": "dist/cjs/index.js",
|
|
5
5
|
"module": "dist/esm/index.js",
|
|
6
6
|
"types": "dist/types/index.d.ts",
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"dependencies": {
|
|
10
10
|
"@celo/utils": "^8.0.0",
|
|
11
11
|
"@cosmjs/encoding": "^0.32.4",
|
|
12
|
-
"@getpara/user-management-client": "1.0.
|
|
12
|
+
"@getpara/user-management-client": "1.0.2",
|
|
13
13
|
"@noble/hashes": "^1.5.0",
|
|
14
14
|
"base64url": "^3.0.1",
|
|
15
15
|
"buffer": "6.0.3",
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"types": "./dist/types/index.d.ts"
|
|
41
41
|
}
|
|
42
42
|
},
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "b52cb28fc10a5fda8c49747e98b512d680b5ded0"
|
|
44
44
|
}
|