@onekeyfe/extension-bridge-hosted 2.1.15 → 2.1.17-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.
|
@@ -12,7 +12,7 @@ import entries from 'lodash/entries';
|
|
|
12
12
|
import utils from './utils';
|
|
13
13
|
import * as uuid from 'uuid';
|
|
14
14
|
import { JsBridgeBase, consts } from '@onekeyfe/cross-inpage-provider-core';
|
|
15
|
-
const { EXT_PORT_OFFSCREEN_TO_BG, EXT_PORT_CS_TO_BG, EXT_PORT_UI_TO_BG } = consts;
|
|
15
|
+
const { EXT_PORT_OFFSCREEN_TO_BG, EXT_PORT_CS_TO_BG, EXT_PORT_UI_TO_BG, ONEKEY_ALIGN_PRIMARY_ACCOUNT } = consts;
|
|
16
16
|
class JsBridgeExtBackground extends JsBridgeBase {
|
|
17
17
|
constructor(config) {
|
|
18
18
|
super(config);
|
|
@@ -128,7 +128,7 @@ class JsBridgeExtBackground extends JsBridgeBase {
|
|
|
128
128
|
data = yield data({ origin });
|
|
129
129
|
}
|
|
130
130
|
// Send a notification to the port of the specified origin
|
|
131
|
-
if (!targetOrigin || targetOrigin === origin) {
|
|
131
|
+
if (!targetOrigin || targetOrigin === origin || targetOrigin === ONEKEY_ALIGN_PRIMARY_ACCOUNT) {
|
|
132
132
|
// TODO check ports disconnected
|
|
133
133
|
this.requestSync({
|
|
134
134
|
data,
|
|
@@ -41,7 +41,7 @@ const entries_1 = __importDefault(require("lodash/entries"));
|
|
|
41
41
|
const utils_1 = __importDefault(require("./utils"));
|
|
42
42
|
const uuid = __importStar(require("uuid"));
|
|
43
43
|
const cross_inpage_provider_core_1 = require("@onekeyfe/cross-inpage-provider-core");
|
|
44
|
-
const { EXT_PORT_OFFSCREEN_TO_BG, EXT_PORT_CS_TO_BG, EXT_PORT_UI_TO_BG } = cross_inpage_provider_core_1.consts;
|
|
44
|
+
const { EXT_PORT_OFFSCREEN_TO_BG, EXT_PORT_CS_TO_BG, EXT_PORT_UI_TO_BG, ONEKEY_ALIGN_PRIMARY_ACCOUNT } = cross_inpage_provider_core_1.consts;
|
|
45
45
|
class JsBridgeExtBackground extends cross_inpage_provider_core_1.JsBridgeBase {
|
|
46
46
|
constructor(config) {
|
|
47
47
|
super(config);
|
|
@@ -157,7 +157,7 @@ class JsBridgeExtBackground extends cross_inpage_provider_core_1.JsBridgeBase {
|
|
|
157
157
|
data = yield data({ origin });
|
|
158
158
|
}
|
|
159
159
|
// Send a notification to the port of the specified origin
|
|
160
|
-
if (!targetOrigin || targetOrigin === origin) {
|
|
160
|
+
if (!targetOrigin || targetOrigin === origin || targetOrigin === ONEKEY_ALIGN_PRIMARY_ACCOUNT) {
|
|
161
161
|
// TODO check ports disconnected
|
|
162
162
|
this.requestSync({
|
|
163
163
|
data,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@onekeyfe/extension-bridge-hosted",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.17-alpha.0",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"cross-inpage-provider"
|
|
6
6
|
],
|
|
@@ -28,12 +28,12 @@
|
|
|
28
28
|
"start": "tsc --watch"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@onekeyfe/cross-inpage-provider-core": "2.1.
|
|
32
|
-
"@onekeyfe/cross-inpage-provider-types": "2.1.
|
|
31
|
+
"@onekeyfe/cross-inpage-provider-core": "2.1.17-alpha.0",
|
|
32
|
+
"@onekeyfe/cross-inpage-provider-types": "2.1.17-alpha.0",
|
|
33
33
|
"uuid": "^8.3.2"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
36
|
"@types/uuid": "^8.3.4"
|
|
37
37
|
},
|
|
38
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "2f084706f4501f4d8850017cd9586b825db88e5e"
|
|
39
39
|
}
|