@blocklet/sdk 1.16.25 → 1.16.26-beta-a18a668e

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/lib/config.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  /// <reference types="node" />
2
2
  import EventEmitter from 'events';
3
3
  import { TComponentInternalInfo } from '@blocklet/meta/lib/blocklet';
4
- declare const events: EventEmitter;
4
+ declare const events: EventEmitter<[never]>;
5
5
  declare const Events: {
6
6
  componentAdded: string;
7
7
  componentUpdated: string;
@@ -117,7 +117,7 @@ declare const _default: {
117
117
  initialized?: boolean;
118
118
  };
119
119
  components: TComponents;
120
- events: EventEmitter;
120
+ events: EventEmitter<[never]>;
121
121
  Events: {
122
122
  componentAdded: string;
123
123
  componentUpdated: string;
@@ -25,10 +25,10 @@ declare const doSendMail: (receiver: string | string[], notification: TNotificat
25
25
  * @returns
26
26
  */
27
27
  declare const broadcast: (notification: TNotificationInput, options?: TSendOptions) => Promise<any>;
28
- export declare const on: (event: string, cb?: $TSFixMe) => EventEmitter;
28
+ export declare const on: (event: string, cb?: $TSFixMe) => EventEmitter<[never]>;
29
29
  export declare const off: any;
30
30
  export declare const _message: {
31
- on: (event: string, cb: $TSFixMe) => EventEmitter;
31
+ on: (event: string, cb: $TSFixMe) => EventEmitter<[never]>;
32
32
  off: any;
33
33
  };
34
34
  export { doSendToUser as sendToUser };
@@ -40,10 +40,10 @@ declare const _default: {
40
40
  sendToRelay: (topic: string, event: string, data: any) => Promise<any>;
41
41
  sendToMail: (receiver: string | string[], notification: TNotification, options?: TSendOptions) => Promise<any>;
42
42
  broadcast: (notification: TNotificationInput, options?: TSendOptions) => Promise<any>;
43
- on: (event: string, cb?: any) => EventEmitter;
43
+ on: (event: string, cb?: any) => EventEmitter<[never]>;
44
44
  off: any;
45
45
  _message: {
46
- on: (event: string, cb: any) => EventEmitter;
46
+ on: (event: string, cb: any) => EventEmitter<[never]>;
47
47
  off: any;
48
48
  };
49
49
  };
@@ -32,6 +32,7 @@ const pick_1 = __importDefault(require("lodash/pick"));
32
32
  const JWT = __importStar(require("@arcblock/jwt"));
33
33
  const constant_1 = __importDefault(require("@abtnode/constant"));
34
34
  const channel_1 = require("@blocklet/meta/lib/channel");
35
+ const did_1 = require("@arcblock/did");
35
36
  const index_1 = require("../validators/index");
36
37
  const constants_1 = require("./constants");
37
38
  const version_1 = require("../version");
@@ -72,7 +73,7 @@ const sendToUser = async (receiver, notification, { appDid, appSk, type }, port
72
73
  type,
73
74
  token: JWT.sign(appDid, appSk),
74
75
  },
75
- receiver,
76
+ receiver: Array.isArray(receiver) ? receiver.map(did_1.toAddress) : (0, did_1.toAddress)(receiver),
76
77
  notification,
77
78
  options: opt,
78
79
  },
package/lib/version.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- declare const version = "1.16.25";
1
+ declare const version = "1.16.26";
2
2
  export { version };
3
3
  declare const _default: {
4
4
  version: string;
package/lib/version.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.version = void 0;
4
- const version = '1.16.25';
4
+ const version = '1.16.26';
5
5
  exports.version = version;
6
6
  exports.default = { version };
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "1.16.25",
6
+ "version": "1.16.26-beta-a18a668e",
7
7
  "description": "graphql client to read/write data on abt node",
8
8
  "main": "lib/index.js",
9
9
  "typings": "lib/index.d.ts",
@@ -27,24 +27,24 @@
27
27
  "author": "linchen1987 <linchen.1987@foxmail.com> (http://github.com/linchen1987)",
28
28
  "license": "Apache-2.0",
29
29
  "dependencies": {
30
- "@abtnode/client": "1.16.25",
31
- "@abtnode/constant": "1.16.25",
32
- "@arcblock/did": "1.18.113",
33
- "@arcblock/did-auth": "1.18.113",
34
- "@arcblock/jwt": "1.18.113",
35
- "@arcblock/ws": "1.18.113",
36
- "@blocklet/constant": "1.16.25",
37
- "@blocklet/env": "1.16.25",
38
- "@blocklet/meta": "1.16.25",
30
+ "@abtnode/client": "1.16.26-beta-a18a668e",
31
+ "@abtnode/constant": "1.16.26-beta-a18a668e",
32
+ "@arcblock/did": "1.18.114",
33
+ "@arcblock/did-auth": "1.18.114",
34
+ "@arcblock/jwt": "1.18.114",
35
+ "@arcblock/ws": "1.18.114",
36
+ "@blocklet/constant": "1.16.26-beta-a18a668e",
37
+ "@blocklet/env": "1.16.26-beta-a18a668e",
38
+ "@blocklet/meta": "1.16.26-beta-a18a668e",
39
39
  "@did-connect/authenticator": "^2.2.1",
40
40
  "@did-connect/handler": "^2.2.1",
41
41
  "@nedb/core": "^2.1.5",
42
- "@ocap/mcrypto": "1.18.113",
43
- "@ocap/wallet": "1.18.113",
42
+ "@ocap/mcrypto": "1.18.114",
43
+ "@ocap/wallet": "1.18.114",
44
44
  "axios": "^0.27.2",
45
45
  "cheerio": "^1.0.0-rc.12",
46
46
  "fs-extra": "^11.2.0",
47
- "joi": "17.11.0",
47
+ "joi": "17.12.2",
48
48
  "json-stable-stringify": "^1.0.1",
49
49
  "lodash": "^4.17.21",
50
50
  "lru-cache": "^6.0.0",
@@ -63,7 +63,7 @@
63
63
  "@types/jest": "^29.5.11",
64
64
  "@types/json-stable-stringify": "^1.0.34",
65
65
  "@types/lodash": "^4.14.186",
66
- "@types/node": "^18.11.0",
66
+ "@types/node": "^20.12.2",
67
67
  "@typescript-eslint/eslint-plugin": "^5.40.1",
68
68
  "@typescript-eslint/parser": "^5.40.1",
69
69
  "detect-port": "^1.5.1",
@@ -76,5 +76,5 @@
76
76
  "ts-node": "^10.9.1",
77
77
  "typescript": "^5.0.4"
78
78
  },
79
- "gitHead": "8752b9a0caa8745e16e1de8db4ef696b713ffb4d"
79
+ "gitHead": "837064f7169e099bdcedfd1c8cb636a575e771de"
80
80
  }