@portkey/onboarding 2.0.0-alpha.8 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/commonjs/constants/index.d.ts +9 -0
- package/dist/commonjs/constants/index.js +13 -4
- package/dist/commonjs/evokePortkey/checkPortkeyExtension.js +3 -1
- package/dist/commonjs/evokePortkey/evokePortkeyApp.js +7 -5
- package/dist/commonjs/evokePortkey/index.d.ts +24 -4
- package/dist/commonjs/evokePortkey/types.d.ts +8 -4
- package/dist/esm/constants/index.d.ts +9 -0
- package/dist/esm/constants/index.js +12 -3
- package/dist/esm/evokePortkey/checkPortkeyExtension.js +4 -2
- package/dist/esm/evokePortkey/evokePortkeyApp.js +8 -6
- package/dist/esm/evokePortkey/index.d.ts +24 -4
- package/dist/esm/evokePortkey/types.d.ts +8 -4
- package/dist/types/constants/index.d.ts +9 -0
- package/dist/types/constants/index.d.ts.map +1 -1
- package/dist/types/evokePortkey/checkPortkeyExtension.d.ts.map +1 -1
- package/dist/types/evokePortkey/evokePortkeyApp.d.ts.map +1 -1
- package/dist/types/evokePortkey/index.d.ts +24 -4
- package/dist/types/evokePortkey/index.d.ts.map +1 -1
- package/dist/types/evokePortkey/types.d.ts +8 -4
- package/dist/types/evokePortkey/types.d.ts.map +1 -1
- package/package.json +4 -4
@@ -2,9 +2,18 @@ export declare const APP_DOWNLOAD_URL: {
|
|
2
2
|
APP_STORE: string;
|
3
3
|
CHROME_STORE: string;
|
4
4
|
};
|
5
|
+
export declare const PORTKEY_V2_DOWNLOAD_URL: {
|
6
|
+
APP_STORE: string;
|
7
|
+
CHROME_STORE: string;
|
8
|
+
};
|
5
9
|
export declare const EXTENSION_DOWNLOAD_URL: {
|
6
10
|
CHROME: string;
|
7
11
|
EDGE: string;
|
8
12
|
DEFAULT: string;
|
9
13
|
};
|
14
|
+
export declare const EXTENSION_V2_DOWNLOAD_URL: {
|
15
|
+
CHROME: string;
|
16
|
+
EDGE: string;
|
17
|
+
DEFAULT: string;
|
18
|
+
};
|
10
19
|
export declare const WEB_PAGE = "https://openlogin.portkey.finance";
|
@@ -1,15 +1,24 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.WEB_PAGE = exports.EXTENSION_DOWNLOAD_URL = exports.APP_DOWNLOAD_URL = void 0;
|
3
|
+
exports.WEB_PAGE = exports.EXTENSION_V2_DOWNLOAD_URL = exports.EXTENSION_DOWNLOAD_URL = exports.PORTKEY_V2_DOWNLOAD_URL = exports.APP_DOWNLOAD_URL = void 0;
|
4
4
|
exports.APP_DOWNLOAD_URL = {
|
5
5
|
APP_STORE: 'https://apps.apple.com/us/app/portkey-ca-wallet-crypto-nft/id6445808228',
|
6
6
|
CHROME_STORE: 'https://play.google.com/store/apps/details?id=com.portkey.did',
|
7
7
|
};
|
8
|
+
exports.PORTKEY_V2_DOWNLOAD_URL = {
|
9
|
+
APP_STORE: 'https://apps.apple.com/us/app/portkey-wallet/id6473827308',
|
10
|
+
CHROME_STORE: 'https://play.google.com/store/apps/details?id=com.portkey.finance',
|
11
|
+
};
|
8
12
|
exports.EXTENSION_DOWNLOAD_URL = {
|
9
|
-
CHROME: 'https://
|
10
|
-
EDGE: 'https://
|
13
|
+
CHROME: 'https://chromewebstore.google.com/detail/hpjiiechbbhefmpggegmahejiiphbmij',
|
14
|
+
EDGE: 'https://chromewebstore.google.com/detail/hpjiiechbbhefmpggegmahejiiphbmij',
|
15
|
+
DEFAULT: 'https://portkey.finance/download',
|
16
|
+
};
|
17
|
+
exports.EXTENSION_V2_DOWNLOAD_URL = {
|
18
|
+
CHROME: 'https://chromewebstore.google.com/detail/iglbgmakmggfkoidiagnhknlndljlolb',
|
19
|
+
EDGE: 'https://chromewebstore.google.com/detail/iglbgmakmggfkoidiagnhknlndljlolb',
|
11
20
|
DEFAULT: 'https://portkey.finance/download',
|
12
21
|
};
|
13
22
|
exports.WEB_PAGE = 'https://openlogin.portkey.finance';
|
14
23
|
// export const WEB_PAGE = 'https://openlogin-test.portkey.finance';
|
15
|
-
// export const WEB_PAGE = 'http://192.168.11.
|
24
|
+
// export const WEB_PAGE = 'http://192.168.11.230:3001';
|
@@ -36,8 +36,10 @@ const checkPortkeyExtension = (params) => __awaiter(void 0, void 0, void 0, func
|
|
36
36
|
const _window = window;
|
37
37
|
if (yield isPortkeyProvider())
|
38
38
|
return true;
|
39
|
+
const version = params === null || params === void 0 ? void 0 : params.version;
|
40
|
+
const downloadUrl = version !== 'v1' ? constants_1.EXTENSION_V2_DOWNLOAD_URL : constants_1.EXTENSION_DOWNLOAD_URL;
|
39
41
|
const browserName = (0, utils_1.detectBrowserName)();
|
40
|
-
const downloadURL =
|
42
|
+
const downloadURL = downloadUrl[browserName] || downloadUrl.DEFAULT;
|
41
43
|
_window.open(downloadURL, openTarget);
|
42
44
|
return false;
|
43
45
|
});
|
@@ -3,19 +3,21 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const utils_1 = require("@portkey/utils");
|
4
4
|
const evokeApp_1 = require("../evokeApp");
|
5
5
|
const constants_1 = require("../constants");
|
6
|
-
const evokePortkeyApp = ({ domain, custom, action, timeout = 4000, customFailureCallback, onStatusChange, }) => {
|
6
|
+
const evokePortkeyApp = ({ domain, custom, action, timeout = 4000, customFailureCallback, onStatusChange, version, }) => {
|
7
|
+
const downloadUrl = version !== 'v1' ? constants_1.PORTKEY_V2_DOWNLOAD_URL : constants_1.APP_DOWNLOAD_URL;
|
8
|
+
const scheme = version !== 'v1' ? utils_1.scheme.DID_APP_SCHEMA : utils_1.scheme.V1_DID_APP_SCHEMA;
|
7
9
|
const callLib = new evokeApp_1.EvokeApp({
|
8
10
|
scheme: {
|
9
|
-
protocol:
|
11
|
+
protocol: scheme,
|
10
12
|
domain: domain || (window === null || window === void 0 ? void 0 : window.location.host),
|
11
13
|
},
|
12
14
|
timeout,
|
13
|
-
appStore:
|
14
|
-
fallback:
|
15
|
+
appStore: downloadUrl.APP_STORE,
|
16
|
+
fallback: downloadUrl.CHROME_STORE,
|
15
17
|
logFunc: onStatusChange,
|
16
18
|
buildScheme: (config, options) => {
|
17
19
|
return utils_1.scheme.formatScheme({
|
18
|
-
scheme
|
20
|
+
scheme,
|
19
21
|
action: action,
|
20
22
|
domain: options.scheme.domain,
|
21
23
|
custom: config.param,
|
@@ -1,10 +1,30 @@
|
|
1
1
|
export * from './types';
|
2
2
|
export declare const evokePortkey: {
|
3
3
|
app: {
|
4
|
-
(params:
|
5
|
-
|
6
|
-
|
7
|
-
|
4
|
+
(params: {
|
5
|
+
domain?: string | undefined;
|
6
|
+
action: "login";
|
7
|
+
custom: any;
|
8
|
+
version?: "v1" | undefined;
|
9
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
10
|
+
(params: {
|
11
|
+
domain?: string | undefined;
|
12
|
+
action: "linkDapp";
|
13
|
+
custom: import("@portkey/utils/dist/commonjs/scheme").LinkDappData;
|
14
|
+
version?: "v1" | undefined;
|
15
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
16
|
+
(params: {
|
17
|
+
domain?: string | undefined;
|
18
|
+
action: "addContact";
|
19
|
+
custom: string;
|
20
|
+
version?: "v1" | undefined;
|
21
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
22
|
+
(params: {
|
23
|
+
domain?: string | undefined;
|
24
|
+
action: "addGroup";
|
25
|
+
custom: string;
|
26
|
+
version?: "v1" | undefined;
|
27
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
8
28
|
};
|
9
29
|
extension: (params?: import("./types").IEvokeExtensionProps | undefined) => Promise<boolean>;
|
10
30
|
thirdParty: {
|
@@ -6,16 +6,20 @@ export interface IBaseEvokeAppOption {
|
|
6
6
|
customFailureCallback?: () => void;
|
7
7
|
onStatusChange?: EvokeAppOptions['logFunc'];
|
8
8
|
}
|
9
|
+
export type TVersion = {
|
10
|
+
version?: string;
|
11
|
+
};
|
9
12
|
export type EvokePortkeyByLogin = PartialOption<Omit<schemeUtils.ILoginHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
10
13
|
export type EvokePortkeyByLinkDapp = PartialOption<Omit<schemeUtils.ILinkDappHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
11
14
|
export type EvokePortkeyByAddContact = PartialOption<Omit<schemeUtils.IAddContactHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
12
15
|
export type EvokePortkeyByAddGroup = PartialOption<Omit<schemeUtils.IAddGroupHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
13
16
|
export interface IEvokePortkeyApp {
|
14
|
-
evokePortkeyApp(params: EvokePortkeyByLogin): void;
|
15
|
-
evokePortkeyApp(params: EvokePortkeyByLinkDapp): void;
|
16
|
-
evokePortkeyApp(params: EvokePortkeyByAddContact): void;
|
17
|
-
evokePortkeyApp(params: EvokePortkeyByAddGroup): void;
|
17
|
+
evokePortkeyApp(params: EvokePortkeyByLogin & TVersion): void;
|
18
|
+
evokePortkeyApp(params: EvokePortkeyByLinkDapp & TVersion): void;
|
19
|
+
evokePortkeyApp(params: EvokePortkeyByAddContact & TVersion): void;
|
20
|
+
evokePortkeyApp(params: EvokePortkeyByAddGroup & TVersion): void;
|
18
21
|
}
|
19
22
|
export interface IEvokeExtensionProps {
|
20
23
|
openTarget?: '_self' | '_blank';
|
24
|
+
version?: string;
|
21
25
|
}
|
@@ -2,9 +2,18 @@ export declare const APP_DOWNLOAD_URL: {
|
|
2
2
|
APP_STORE: string;
|
3
3
|
CHROME_STORE: string;
|
4
4
|
};
|
5
|
+
export declare const PORTKEY_V2_DOWNLOAD_URL: {
|
6
|
+
APP_STORE: string;
|
7
|
+
CHROME_STORE: string;
|
8
|
+
};
|
5
9
|
export declare const EXTENSION_DOWNLOAD_URL: {
|
6
10
|
CHROME: string;
|
7
11
|
EDGE: string;
|
8
12
|
DEFAULT: string;
|
9
13
|
};
|
14
|
+
export declare const EXTENSION_V2_DOWNLOAD_URL: {
|
15
|
+
CHROME: string;
|
16
|
+
EDGE: string;
|
17
|
+
DEFAULT: string;
|
18
|
+
};
|
10
19
|
export declare const WEB_PAGE = "https://openlogin.portkey.finance";
|
@@ -2,11 +2,20 @@ export const APP_DOWNLOAD_URL = {
|
|
2
2
|
APP_STORE: 'https://apps.apple.com/us/app/portkey-ca-wallet-crypto-nft/id6445808228',
|
3
3
|
CHROME_STORE: 'https://play.google.com/store/apps/details?id=com.portkey.did',
|
4
4
|
};
|
5
|
+
export const PORTKEY_V2_DOWNLOAD_URL = {
|
6
|
+
APP_STORE: 'https://apps.apple.com/us/app/portkey-wallet/id6473827308',
|
7
|
+
CHROME_STORE: 'https://play.google.com/store/apps/details?id=com.portkey.finance',
|
8
|
+
};
|
5
9
|
export const EXTENSION_DOWNLOAD_URL = {
|
6
|
-
CHROME: 'https://
|
7
|
-
EDGE: 'https://
|
10
|
+
CHROME: 'https://chromewebstore.google.com/detail/hpjiiechbbhefmpggegmahejiiphbmij',
|
11
|
+
EDGE: 'https://chromewebstore.google.com/detail/hpjiiechbbhefmpggegmahejiiphbmij',
|
12
|
+
DEFAULT: 'https://portkey.finance/download',
|
13
|
+
};
|
14
|
+
export const EXTENSION_V2_DOWNLOAD_URL = {
|
15
|
+
CHROME: 'https://chromewebstore.google.com/detail/iglbgmakmggfkoidiagnhknlndljlolb',
|
16
|
+
EDGE: 'https://chromewebstore.google.com/detail/iglbgmakmggfkoidiagnhknlndljlolb',
|
8
17
|
DEFAULT: 'https://portkey.finance/download',
|
9
18
|
};
|
10
19
|
export const WEB_PAGE = 'https://openlogin.portkey.finance';
|
11
20
|
// export const WEB_PAGE = 'https://openlogin-test.portkey.finance';
|
12
|
-
// export const WEB_PAGE = 'http://192.168.11.
|
21
|
+
// export const WEB_PAGE = 'http://192.168.11.230:3001';
|
@@ -8,7 +8,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
8
8
|
});
|
9
9
|
};
|
10
10
|
import { detectBrowserName } from '../utils/index.js';
|
11
|
-
import { EXTENSION_DOWNLOAD_URL } from '../constants/index.js';
|
11
|
+
import { EXTENSION_DOWNLOAD_URL, EXTENSION_V2_DOWNLOAD_URL } from '../constants/index.js';
|
12
12
|
import detectProvider from '@portkey/detect-provider';
|
13
13
|
/**
|
14
14
|
* This method is used to check if the provided object is a Portkey provider.
|
@@ -31,8 +31,10 @@ const checkPortkeyExtension = (params) => __awaiter(void 0, void 0, void 0, func
|
|
31
31
|
const _window = window;
|
32
32
|
if (yield isPortkeyProvider())
|
33
33
|
return true;
|
34
|
+
const version = params === null || params === void 0 ? void 0 : params.version;
|
35
|
+
const downloadUrl = version !== 'v1' ? EXTENSION_V2_DOWNLOAD_URL : EXTENSION_DOWNLOAD_URL;
|
34
36
|
const browserName = detectBrowserName();
|
35
|
-
const downloadURL =
|
37
|
+
const downloadURL = downloadUrl[browserName] || downloadUrl.DEFAULT;
|
36
38
|
_window.open(downloadURL, openTarget);
|
37
39
|
return false;
|
38
40
|
});
|
@@ -1,19 +1,21 @@
|
|
1
1
|
import { scheme as schemeUtils } from '@portkey/utils';
|
2
2
|
import { EvokeApp } from '../evokeApp/index.js';
|
3
|
-
import { APP_DOWNLOAD_URL } from '../constants/index.js';
|
4
|
-
const evokePortkeyApp = ({ domain, custom, action, timeout = 4000, customFailureCallback, onStatusChange, }) => {
|
3
|
+
import { APP_DOWNLOAD_URL, PORTKEY_V2_DOWNLOAD_URL } from '../constants/index.js';
|
4
|
+
const evokePortkeyApp = ({ domain, custom, action, timeout = 4000, customFailureCallback, onStatusChange, version, }) => {
|
5
|
+
const downloadUrl = version !== 'v1' ? PORTKEY_V2_DOWNLOAD_URL : APP_DOWNLOAD_URL;
|
6
|
+
const scheme = version !== 'v1' ? schemeUtils.DID_APP_SCHEMA : schemeUtils.V1_DID_APP_SCHEMA;
|
5
7
|
const callLib = new EvokeApp({
|
6
8
|
scheme: {
|
7
|
-
protocol:
|
9
|
+
protocol: scheme,
|
8
10
|
domain: domain || (window === null || window === void 0 ? void 0 : window.location.host),
|
9
11
|
},
|
10
12
|
timeout,
|
11
|
-
appStore:
|
12
|
-
fallback:
|
13
|
+
appStore: downloadUrl.APP_STORE,
|
14
|
+
fallback: downloadUrl.CHROME_STORE,
|
13
15
|
logFunc: onStatusChange,
|
14
16
|
buildScheme: (config, options) => {
|
15
17
|
return schemeUtils.formatScheme({
|
16
|
-
scheme
|
18
|
+
scheme,
|
17
19
|
action: action,
|
18
20
|
domain: options.scheme.domain,
|
19
21
|
custom: config.param,
|
@@ -1,10 +1,30 @@
|
|
1
1
|
export * from './types.js';
|
2
2
|
export declare const evokePortkey: {
|
3
3
|
app: {
|
4
|
-
(params:
|
5
|
-
|
6
|
-
|
7
|
-
|
4
|
+
(params: {
|
5
|
+
domain?: string | undefined;
|
6
|
+
action: "login";
|
7
|
+
custom: any;
|
8
|
+
version?: "v1" | undefined;
|
9
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
10
|
+
(params: {
|
11
|
+
domain?: string | undefined;
|
12
|
+
action: "linkDapp";
|
13
|
+
custom: import("@portkey/utils/dist/commonjs/scheme").LinkDappData;
|
14
|
+
version?: "v1" | undefined;
|
15
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
16
|
+
(params: {
|
17
|
+
domain?: string | undefined;
|
18
|
+
action: "addContact";
|
19
|
+
custom: string;
|
20
|
+
version?: "v1" | undefined;
|
21
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
22
|
+
(params: {
|
23
|
+
domain?: string | undefined;
|
24
|
+
action: "addGroup";
|
25
|
+
custom: string;
|
26
|
+
version?: "v1" | undefined;
|
27
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
8
28
|
};
|
9
29
|
extension: (params?: import("./types").IEvokeExtensionProps | undefined) => Promise<boolean>;
|
10
30
|
thirdParty: {
|
@@ -6,16 +6,20 @@ export interface IBaseEvokeAppOption {
|
|
6
6
|
customFailureCallback?: () => void;
|
7
7
|
onStatusChange?: EvokeAppOptions['logFunc'];
|
8
8
|
}
|
9
|
+
export type TVersion = {
|
10
|
+
version?: string;
|
11
|
+
};
|
9
12
|
export type EvokePortkeyByLogin = PartialOption<Omit<schemeUtils.ILoginHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
10
13
|
export type EvokePortkeyByLinkDapp = PartialOption<Omit<schemeUtils.ILinkDappHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
11
14
|
export type EvokePortkeyByAddContact = PartialOption<Omit<schemeUtils.IAddContactHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
12
15
|
export type EvokePortkeyByAddGroup = PartialOption<Omit<schemeUtils.IAddGroupHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
13
16
|
export interface IEvokePortkeyApp {
|
14
|
-
evokePortkeyApp(params: EvokePortkeyByLogin): void;
|
15
|
-
evokePortkeyApp(params: EvokePortkeyByLinkDapp): void;
|
16
|
-
evokePortkeyApp(params: EvokePortkeyByAddContact): void;
|
17
|
-
evokePortkeyApp(params: EvokePortkeyByAddGroup): void;
|
17
|
+
evokePortkeyApp(params: EvokePortkeyByLogin & TVersion): void;
|
18
|
+
evokePortkeyApp(params: EvokePortkeyByLinkDapp & TVersion): void;
|
19
|
+
evokePortkeyApp(params: EvokePortkeyByAddContact & TVersion): void;
|
20
|
+
evokePortkeyApp(params: EvokePortkeyByAddGroup & TVersion): void;
|
18
21
|
}
|
19
22
|
export interface IEvokeExtensionProps {
|
20
23
|
openTarget?: '_self' | '_blank';
|
24
|
+
version?: string;
|
21
25
|
}
|
@@ -2,10 +2,19 @@ export declare const APP_DOWNLOAD_URL: {
|
|
2
2
|
APP_STORE: string;
|
3
3
|
CHROME_STORE: string;
|
4
4
|
};
|
5
|
+
export declare const PORTKEY_V2_DOWNLOAD_URL: {
|
6
|
+
APP_STORE: string;
|
7
|
+
CHROME_STORE: string;
|
8
|
+
};
|
5
9
|
export declare const EXTENSION_DOWNLOAD_URL: {
|
6
10
|
CHROME: string;
|
7
11
|
EDGE: string;
|
8
12
|
DEFAULT: string;
|
9
13
|
};
|
14
|
+
export declare const EXTENSION_V2_DOWNLOAD_URL: {
|
15
|
+
CHROME: string;
|
16
|
+
EDGE: string;
|
17
|
+
DEFAULT: string;
|
18
|
+
};
|
10
19
|
export declare const WEB_PAGE = "https://openlogin.portkey.finance";
|
11
20
|
//# sourceMappingURL=index.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/constants/index.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB;;;CAG5B,CAAC;
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/constants/index.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB;;;CAG5B,CAAC;AAEF,eAAO,MAAM,uBAAuB;;;CAGnC,CAAC;AAEF,eAAO,MAAM,sBAAsB;;;;CAIlC,CAAC;AAEF,eAAO,MAAM,yBAAyB;;;;CAIrC,CAAC;AAEF,eAAO,MAAM,QAAQ,sCAAsC,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"checkPortkeyExtension.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/checkPortkeyExtension.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAC;AAe/C,QAAA,MAAM,qBAAqB,YAAmB,oBAAoB,
|
1
|
+
{"version":3,"file":"checkPortkeyExtension.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/checkPortkeyExtension.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAC;AAe/C,QAAA,MAAM,qBAAqB,YAAmB,oBAAoB,qBAcjE,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"evokePortkeyApp.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/evokePortkeyApp.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAE3C,QAAA,MAAM,eAAe,EAAE,gBAAgB,CAAC,iBAAiB,
|
1
|
+
{"version":3,"file":"evokePortkeyApp.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/evokePortkeyApp.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAE3C,QAAA,MAAM,eAAe,EAAE,gBAAgB,CAAC,iBAAiB,CAmCxD,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
@@ -1,10 +1,30 @@
|
|
1
1
|
export * from './types';
|
2
2
|
export declare const evokePortkey: {
|
3
3
|
app: {
|
4
|
-
(params:
|
5
|
-
|
6
|
-
|
7
|
-
|
4
|
+
(params: {
|
5
|
+
domain?: string | undefined;
|
6
|
+
action: "login";
|
7
|
+
custom: any;
|
8
|
+
version?: "v1" | undefined;
|
9
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
10
|
+
(params: {
|
11
|
+
domain?: string | undefined;
|
12
|
+
action: "linkDapp";
|
13
|
+
custom: import("@portkey/utils/dist/commonjs/scheme").LinkDappData;
|
14
|
+
version?: "v1" | undefined;
|
15
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
16
|
+
(params: {
|
17
|
+
domain?: string | undefined;
|
18
|
+
action: "addContact";
|
19
|
+
custom: string;
|
20
|
+
version?: "v1" | undefined;
|
21
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
22
|
+
(params: {
|
23
|
+
domain?: string | undefined;
|
24
|
+
action: "addGroup";
|
25
|
+
custom: string;
|
26
|
+
version?: "v1" | undefined;
|
27
|
+
} & import("./types").IBaseEvokeAppOption & import("./types").TVersion): void;
|
8
28
|
};
|
9
29
|
extension: (params?: import("./types").IEvokeExtensionProps | undefined) => Promise<boolean>;
|
10
30
|
thirdParty: {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/index.ts"],"names":[],"mappings":"AAGA,cAAc,SAAS,CAAC;AACxB,eAAO,MAAM,YAAY
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/index.ts"],"names":[],"mappings":"AAGA,cAAc,SAAS,CAAC;AACxB,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAiC,CAAC"}
|
@@ -6,17 +6,21 @@ export interface IBaseEvokeAppOption {
|
|
6
6
|
customFailureCallback?: () => void;
|
7
7
|
onStatusChange?: EvokeAppOptions['logFunc'];
|
8
8
|
}
|
9
|
+
export type TVersion = {
|
10
|
+
version?: string;
|
11
|
+
};
|
9
12
|
export type EvokePortkeyByLogin = PartialOption<Omit<schemeUtils.ILoginHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
10
13
|
export type EvokePortkeyByLinkDapp = PartialOption<Omit<schemeUtils.ILinkDappHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
11
14
|
export type EvokePortkeyByAddContact = PartialOption<Omit<schemeUtils.IAddContactHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
12
15
|
export type EvokePortkeyByAddGroup = PartialOption<Omit<schemeUtils.IAddGroupHandleSchemeParams, 'scheme'>, 'domain'> & IBaseEvokeAppOption;
|
13
16
|
export interface IEvokePortkeyApp {
|
14
|
-
evokePortkeyApp(params: EvokePortkeyByLogin): void;
|
15
|
-
evokePortkeyApp(params: EvokePortkeyByLinkDapp): void;
|
16
|
-
evokePortkeyApp(params: EvokePortkeyByAddContact): void;
|
17
|
-
evokePortkeyApp(params: EvokePortkeyByAddGroup): void;
|
17
|
+
evokePortkeyApp(params: EvokePortkeyByLogin & TVersion): void;
|
18
|
+
evokePortkeyApp(params: EvokePortkeyByLinkDapp & TVersion): void;
|
19
|
+
evokePortkeyApp(params: EvokePortkeyByAddContact & TVersion): void;
|
20
|
+
evokePortkeyApp(params: EvokePortkeyByAddGroup & TVersion): void;
|
18
21
|
}
|
19
22
|
export interface IEvokeExtensionProps {
|
20
23
|
openTarget?: '_self' | '_blank';
|
24
|
+
version?: string;
|
21
25
|
}
|
22
26
|
//# sourceMappingURL=types.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,MAAM,IAAI,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAEvD,MAAM,WAAW,mBAAmB;IAClC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,qBAAqB,CAAC,EAAE,MAAM,IAAI,CAAC;IACnC,cAAc,CAAC,EAAE,eAAe,CAAC,SAAS,CAAC,CAAC;CAC7C;
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/evokePortkey/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,MAAM,IAAI,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAEvD,MAAM,WAAW,mBAAmB;IAClC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,qBAAqB,CAAC,EAAE,MAAM,IAAI,CAAC;IACnC,cAAc,CAAC,EAAE,eAAe,CAAC,SAAS,CAAC,CAAC;CAC7C;AACD,MAAM,MAAM,QAAQ,GAAG;IAAE,OAAO,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAC5C,MAAM,MAAM,mBAAmB,GAAG,aAAa,CAAC,IAAI,CAAC,WAAW,CAAC,wBAAwB,EAAE,QAAQ,CAAC,EAAE,QAAQ,CAAC,GAC7G,mBAAmB,CAAC;AACtB,MAAM,MAAM,sBAAsB,GAAG,aAAa,CAAC,IAAI,CAAC,WAAW,CAAC,2BAA2B,EAAE,QAAQ,CAAC,EAAE,QAAQ,CAAC,GACnH,mBAAmB,CAAC;AAEtB,MAAM,MAAM,wBAAwB,GAAG,aAAa,CAClD,IAAI,CAAC,WAAW,CAAC,6BAA6B,EAAE,QAAQ,CAAC,EACzD,QAAQ,CACT,GACC,mBAAmB,CAAC;AAEtB,MAAM,MAAM,sBAAsB,GAAG,aAAa,CAAC,IAAI,CAAC,WAAW,CAAC,2BAA2B,EAAE,QAAQ,CAAC,EAAE,QAAQ,CAAC,GACnH,mBAAmB,CAAC;AAEtB,MAAM,WAAW,gBAAgB;IAC/B,eAAe,CAAC,MAAM,EAAE,mBAAmB,GAAG,QAAQ,GAAG,IAAI,CAAC;IAC9D,eAAe,CAAC,MAAM,EAAE,sBAAsB,GAAG,QAAQ,GAAG,IAAI,CAAC;IACjE,eAAe,CAAC,MAAM,EAAE,wBAAwB,GAAG,QAAQ,GAAG,IAAI,CAAC;IACnE,eAAe,CAAC,MAAM,EAAE,sBAAsB,GAAG,QAAQ,GAAG,IAAI,CAAC;CAClE;AAED,MAAM,WAAW,oBAAoB;IACnC,UAAU,CAAC,EAAE,OAAO,GAAG,QAAQ,CAAC;IAChC,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@portkey/onboarding",
|
3
|
-
"version": "2.0.0
|
3
|
+
"version": "2.0.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.0
|
45
|
-
"@portkey/utils": "^2.0.0
|
44
|
+
"@portkey/types": "^2.0.0",
|
45
|
+
"@portkey/utils": "^2.0.0",
|
46
46
|
"bowser": "^2.11.0",
|
47
47
|
"query-string": "^7.1.1"
|
48
48
|
},
|
49
|
-
"gitHead": "
|
49
|
+
"gitHead": "e013eef2cecb70ee697103ddd748307627b3e167"
|
50
50
|
}
|