@portkey/onboarding 2.0.3 → 2.0.4-alpha.0
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/commonjs/evokeApp/generate.js +7 -4
- package/dist/commonjs/evokePortkey/evokeByThirdParty.js +5 -2
- package/dist/esm/evokeApp/generate.js +4 -4
- package/dist/esm/evokePortkey/evokeByThirdParty.js +2 -2
- package/dist/types/evokePortkey/evokeByThirdParty.d.ts.map +1 -1
- package/package.json +4 -4
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
2
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
6
|
exports.generateUniversalLink = exports.generateIntent = exports.generateScheme = exports.buildScheme = void 0;
|
|
4
|
-
const query_string_1 = require("query-string");
|
|
7
|
+
const query_string_1 = __importDefault(require("query-string"));
|
|
5
8
|
// Generate basic url scheme
|
|
6
9
|
function buildScheme(config, options) {
|
|
7
10
|
const { path, param } = config;
|
|
@@ -10,7 +13,7 @@ function buildScheme(config, options) {
|
|
|
10
13
|
return customBuildScheme(config, options);
|
|
11
14
|
}
|
|
12
15
|
const { domain, protocol } = scheme;
|
|
13
|
-
return
|
|
16
|
+
return query_string_1.default.stringifyUrl({
|
|
14
17
|
url: `${protocol}://${domain}/${path}`,
|
|
15
18
|
query: param,
|
|
16
19
|
}, { encode: true });
|
|
@@ -53,11 +56,11 @@ function generateUniversalLink(config, options) {
|
|
|
53
56
|
const { domain, pathKey } = universal;
|
|
54
57
|
const { path, param } = config;
|
|
55
58
|
const protocol = 'https';
|
|
56
|
-
const newUniversalLink =
|
|
59
|
+
const newUniversalLink = query_string_1.default.stringifyUrl({
|
|
57
60
|
url: `${protocol}://${domain}/${path}`,
|
|
58
61
|
query: param,
|
|
59
62
|
}, { encode: true });
|
|
60
|
-
const oldUniversalLink =
|
|
63
|
+
const oldUniversalLink = query_string_1.default.stringifyUrl({
|
|
61
64
|
url: `${protocol}://${domain}/${path}`,
|
|
62
65
|
query: pathKey ? Object.assign({ [pathKey]: path }, param) : param,
|
|
63
66
|
}, { encode: true });
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
2
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const query_string_1 = require("query-string");
|
|
6
|
+
const query_string_1 = __importDefault(require("query-string"));
|
|
4
7
|
const constants_1 = require("../constants");
|
|
5
|
-
const evokeByThirdParty = params => Promise.resolve(window.open(`${constants_1.WEB_PAGE}/portkey-download?${
|
|
8
|
+
const evokeByThirdParty = params => Promise.resolve(window.open(`${constants_1.WEB_PAGE}/portkey-download?${query_string_1.default.stringify(params)}`));
|
|
6
9
|
exports.default = evokeByThirdParty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import queryString from 'query-string';
|
|
2
2
|
// Generate basic url scheme
|
|
3
3
|
export function buildScheme(config, options) {
|
|
4
4
|
const { path, param } = config;
|
|
@@ -7,7 +7,7 @@ export function buildScheme(config, options) {
|
|
|
7
7
|
return customBuildScheme(config, options);
|
|
8
8
|
}
|
|
9
9
|
const { domain, protocol } = scheme;
|
|
10
|
-
return stringifyUrl({
|
|
10
|
+
return queryString.stringifyUrl({
|
|
11
11
|
url: `${protocol}://${domain}/${path}`,
|
|
12
12
|
query: param,
|
|
13
13
|
}, { encode: true });
|
|
@@ -47,11 +47,11 @@ export function generateUniversalLink(config, options) {
|
|
|
47
47
|
const { domain, pathKey } = universal;
|
|
48
48
|
const { path, param } = config;
|
|
49
49
|
const protocol = 'https';
|
|
50
|
-
const newUniversalLink = stringifyUrl({
|
|
50
|
+
const newUniversalLink = queryString.stringifyUrl({
|
|
51
51
|
url: `${protocol}://${domain}/${path}`,
|
|
52
52
|
query: param,
|
|
53
53
|
}, { encode: true });
|
|
54
|
-
const oldUniversalLink = stringifyUrl({
|
|
54
|
+
const oldUniversalLink = queryString.stringifyUrl({
|
|
55
55
|
url: `${protocol}://${domain}/${path}`,
|
|
56
56
|
query: pathKey ? Object.assign({ [pathKey]: path }, param) : param,
|
|
57
57
|
}, { encode: true });
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import queryString from 'query-string';
|
|
2
2
|
import { WEB_PAGE } from '../constants/index.js';
|
|
3
|
-
const evokeByThirdParty = params => Promise.resolve(window.open(`${WEB_PAGE}/portkey-download?${stringify(params)}`));
|
|
3
|
+
const evokeByThirdParty = params => Promise.resolve(window.open(`${WEB_PAGE}/portkey-download?${queryString.stringify(params)}`));
|
|
4
4
|
export default evokeByThirdParty;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"evokeByThirdParty.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/evokeByThirdParty.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC,KAAK,WAAW,GAAG;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,UAAU,kBAAkB;IAC1B,iBAAiB,CACf,MAAM,CAAC,EAAE;QACP,MAAM,EAAE,OAAO,CAAC;QAChB,MAAM,EAAE,MAAM,CAAC,wBAAwB,CAAC,QAAQ,CAAC,CAAC;KACnD,GAAG,WAAW,GACd,OAAO,CAAC,GAAG,CAAC,CAAC;IAChB,iBAAiB,CACf,MAAM,CAAC,EAAE;QACP,MAAM,EAAE,UAAU,CAAC;QACnB,MAAM,EAAE,MAAM,CAAC,2BAA2B,CAAC,QAAQ,CAAC,CAAC;KACtD,GAAG,WAAW,GACd,OAAO,CAAC,GAAG,CAAC,CAAC;CACjB;AAED,QAAA,MAAM,iBAAiB,EAAE,kBAAkB,CAAC,mBAAmB,
|
|
1
|
+
{"version":3,"file":"evokeByThirdParty.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/evokeByThirdParty.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC,KAAK,WAAW,GAAG;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,UAAU,kBAAkB;IAC1B,iBAAiB,CACf,MAAM,CAAC,EAAE;QACP,MAAM,EAAE,OAAO,CAAC;QAChB,MAAM,EAAE,MAAM,CAAC,wBAAwB,CAAC,QAAQ,CAAC,CAAC;KACnD,GAAG,WAAW,GACd,OAAO,CAAC,GAAG,CAAC,CAAC;IAChB,iBAAiB,CACf,MAAM,CAAC,EAAE;QACP,MAAM,EAAE,UAAU,CAAC;QACnB,MAAM,EAAE,MAAM,CAAC,2BAA2B,CAAC,QAAQ,CAAC,CAAC;KACtD,GAAG,WAAW,GACd,OAAO,CAAC,GAAG,CAAC,CAAC;CACjB;AAED,QAAA,MAAM,iBAAiB,EAAE,kBAAkB,CAAC,mBAAmB,CACgC,CAAC;AAEhG,eAAe,iBAAiB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@portkey/onboarding",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.4-alpha.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./dist/commonjs/index.js",
|
|
6
6
|
"module": "./dist/esm/index.js",
|
|
@@ -41,10 +41,10 @@
|
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
43
|
"@portkey/detect-provider": "^2.0.0-alpha.2",
|
|
44
|
-
"@portkey/types": "^2.0.
|
|
45
|
-
"@portkey/utils": "^2.0.
|
|
44
|
+
"@portkey/types": "^2.0.4-alpha.0",
|
|
45
|
+
"@portkey/utils": "^2.0.4-alpha.0",
|
|
46
46
|
"bowser": "^2.11.0",
|
|
47
47
|
"query-string": "^7.1.1"
|
|
48
48
|
},
|
|
49
|
-
"gitHead": "
|
|
49
|
+
"gitHead": "0bcc0c55992f9f47a687834eac789d720d3f4228"
|
|
50
50
|
}
|