quickvo-sdk-js 1.6.53 → 1.6.55

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 @@ export declare class QuickVO {
12
12
  setCallStrategy: (callStrategy: import('./enums').K_callStrategy, mediaTypes?: import('./enums').K_mediaType[]) => Promise<void>;
13
13
  addNotify: (notify: {
14
14
  sn?: string;
15
- event: "onJoinRoom" | "onQuitRoom" | "onPublish" | "onBeforeTokenExpire" | "onTokenExpired" | "onDestroyRoom" | "onCDNPlayUrlAdd" | "onRoomUserSpeech" | "onRoomUsers" | "onRoomNetwork" | "onDevicechange" | "onPeerState" | "onRoomState";
15
+ event: "onJoinRoom" | "onQuitRoom" | "onPublish" | "onBeforeTokenExpire" | "onTokenExpired" | "onDestroyRoom" | "onCDNPlayUrlAdd" | "onRoomUserSpeech" | "onLog" | "onRoomUsers" | "onRoomNetwork" | "onDevicechange" | "onPeerState" | "onRoomState";
16
16
  callback?: (e: any) => void;
17
17
  }) => string;
18
18
  setOptions: (options: Partial<QuickOptions & import('./types').RoomOptions>) => void;
@@ -1,4 +1,4 @@
1
- type NotifyName = 'onRoomUsers' | 'onJoinRoom' | 'onPublish' | 'onQuitRoom' | 'onRoomNetwork' | 'onDevicechange' | 'onCDNPlayUrlAdd' | 'onRoomUserSpeech' | 'onBeforeTokenExpire' | 'onTokenExpired' | 'onPeerState' | 'onRoomState' | 'onDestroyRoom';
1
+ type NotifyName = 'onLog' | 'onRoomUsers' | 'onJoinRoom' | 'onPublish' | 'onQuitRoom' | 'onRoomNetwork' | 'onDevicechange' | 'onCDNPlayUrlAdd' | 'onRoomUserSpeech' | 'onBeforeTokenExpire' | 'onTokenExpired' | 'onPeerState' | 'onRoomState' | 'onDestroyRoom';
2
2
  /**
3
3
  * 广播
4
4
  */
@@ -27,6 +27,7 @@ export declare class CallsWebSocket {
27
27
  } & {
28
28
  close?: (e: any) => void;
29
29
  open?: (e: any) => void;
30
+ log?: (e: any) => void;
30
31
  };
31
32
  /** 日志写入节流:内存缓冲,避免每条消息都读写 localStorage */
32
33
  private _logBuffer;
@@ -0,0 +1,17 @@
1
+ /**
2
+ * 可递归过滤的 JSON 值类型
3
+ */
4
+ type FilterableValue = string | number | boolean | null | undefined | FilterableValue[] | {
5
+ [key: string]: FilterableValue;
6
+ };
7
+ /**
8
+ * 过滤敏感数据,返回新对象(递归处理多层嵌套)
9
+ * - key 为 'sdp' 或 'Sdp' 时,将值设为 ''
10
+ * - key 为 'id' 或 'userId' 且值长度 > 10 时,脱敏为 xxx****xxx(前3后3)
11
+ * - 嵌套对象和数组中的对象会递归处理
12
+ * @param obj 原始对象
13
+ * @returns 新对象,不修改原对象
14
+ */
15
+ declare function filterData<T extends FilterableValue>(obj: T): T;
16
+ export { filterData };
17
+ export type { FilterableValue };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "quickvo-sdk-js",
3
3
  "description": "提供快捷接入单对单、单对多、群体会议、舞台会议等音视频功能。",
4
- "version": "1.6.53",
4
+ "version": "1.6.55",
5
5
  "type": "module",
6
6
  "files": [
7
7
  "dist"