@hysc/meeting 10.5.7 → 10.5.9

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/index.d.mts CHANGED
@@ -1,7 +1,8 @@
1
+ import * as BCClient from '@hysc/core';
2
+ import BCClient__default, { ShareMediaOptions, Player, BCUser, AudioPlayer, SMConfig } from '@hysc/core';
1
3
  import * as lodash_es from 'lodash-es';
2
4
  import * as _hysc_brtc from '@hysc/brtc';
3
5
  import { LocalStream, RemoteStream, Device, SubscribeOptions, VideoProfile, AudioHint, StreamCodecOption } from '@hysc/brtc';
4
- import BCClient, { ShareMediaOptions, Player, BCUser, AudioPlayer, SMConfig } from '@hysc/core';
5
6
  import { BehaviorSubject, Subject } from 'rxjs';
6
7
  import { BoomError } from '@hysc/utils';
7
8
  export { Logger } from '@hysc/utils';
@@ -28,6 +29,25 @@ declare type audioOffWatcherValue = {
28
29
  selfopenaudio: boolean;
29
30
  };
30
31
 
32
+ /**
33
+ * @name: index.ts
34
+ * @author: yangliye
35
+ * @date: 2022-04-25 13:42
36
+ * @description:index.ts
37
+ * @update: 2022-04-25 13:42
38
+ */
39
+
40
+ /** 举手相关操作 */
41
+ interface RaiseHandsParams {
42
+ raiseHandsType: 0 | 1 | 2 | 3 | 4;
43
+ raiseHands: boolean;
44
+ raiseInfo?: {
45
+ userId: string;
46
+ raiseHandTime: number;
47
+ type: 'raiseHandsAudio' | 'raiseHandsVideo' | 'raiseHand';
48
+ };
49
+ }
50
+
31
51
  /**
32
52
  * @name: BMSpeaker
33
53
  * @author: liuxinghai
@@ -123,12 +143,12 @@ declare class BMMessageInfo {
123
143
 
124
144
  declare class BMChatVM {
125
145
  messageList: Array<BMMessageInfo>;
126
- boomCore: BCClient;
146
+ boomCore: BCClient__default;
127
147
  userVM: BMUserVM;
128
148
  bmRoom: BMRoom;
129
149
  messageListWatcher: BehaviorSubject<Array<BMMessageInfo>>;
130
150
  hasDangerMessageWatcher: Subject<boolean>;
131
- constructor(boomCore: BCClient, userVM: BMUserVM, bmRoom: BMRoom);
151
+ constructor(boomCore: BCClient__default, userVM: BMUserVM, bmRoom: BMRoom);
132
152
  /**
133
153
  * 发送聊天消息
134
154
  * @param talkMsg 聊天信息
@@ -905,7 +925,7 @@ declare class BMUserVM {
905
925
  signalList: Map<string, BMUser>;
906
926
  /** 大房间,普通参会者列表 */
907
927
  commonUserList: Map<string, BMUser>;
908
- boomCore: BCClient;
928
+ boomCore: BCClient__default;
909
929
  room: BMRoom;
910
930
  /** 嘉宾及以上列表 */
911
931
  userListWatcher: BehaviorSubject<BMUser[]>;
@@ -919,7 +939,7 @@ declare class BMUserVM {
919
939
  getForceUserWatcher: BehaviorSubject<boolean>;
920
940
  localUser: BMUser;
921
941
  commTimer: number;
922
- constructor(boomCore: BCClient, localUser: BMUser, room: BMRoom);
942
+ constructor(boomCore: BCClient__default, localUser: BMUser, room: BMRoom);
923
943
  handleUserRoleChange(info: ChangeIsGuest): Promise<void>;
924
944
  /**
925
945
  * 添加用户, 并返回已添加的用户对象
@@ -1003,6 +1023,7 @@ declare class BMUserVM {
1003
1023
  private sortCommonUsers;
1004
1024
  private sortSignalUsers;
1005
1025
  private static filterUsers;
1026
+ private static filterUser;
1006
1027
  /**
1007
1028
  * 排序变化之后的处理逻辑
1008
1029
  */
@@ -1036,6 +1057,19 @@ declare class BMUserVM {
1036
1057
  userList: BMUser[];
1037
1058
  total: number;
1038
1059
  }>;
1060
+ /**
1061
+ * 获取观众列表
1062
+ * @param page
1063
+ * @param pageSize
1064
+ * @param mode
1065
+ */
1066
+ getAudiencesList(page: number, pageSize: number, mode?: 'map' | 'array'): Promise<{
1067
+ userList: Map<string, BMUser>;
1068
+ total: number;
1069
+ } | {
1070
+ userList: BMUser[];
1071
+ total: number;
1072
+ }>;
1039
1073
  getUsersList(page: number, pageSize: number, permission?: string, waitRoom?: boolean): Promise<{
1040
1074
  userList: BMUser[];
1041
1075
  total: number;
@@ -1356,13 +1390,13 @@ interface AudioProfileInfo {
1356
1390
  }
1357
1391
  declare class BMRoomVM {
1358
1392
  roomInfo: BMRoomInfo;
1359
- boomCore: BCClient;
1393
+ boomCore: BCClient__default;
1360
1394
  userVM: BMUserVM;
1361
1395
  giveLikeListWatcher: Subject<Array<giveLikeItem>>;
1362
1396
  giveLikeList: Array<giveLikeItem>;
1363
1397
  private room;
1364
1398
  tipQueueObj: any;
1365
- constructor(boomCore: BCClient, userVM: any, roomInfo: BMRoomInfo);
1399
+ constructor(boomCore: BCClient__default, userVM: any, roomInfo: BMRoomInfo);
1366
1400
  initWithRoom(room: BMRoom): void;
1367
1401
  /**
1368
1402
  * 踢出用户
@@ -1425,9 +1459,15 @@ declare class BMRoomVM {
1425
1459
  * @param raise 举手还是放下举手 true/false
1426
1460
  */
1427
1461
  raiseHands(type: 'audio' | 'video' | 'raiseHand', raise: boolean): Promise<void>;
1462
+ /**
1463
+ * 举手相关操作-customMessage信令发送
1464
+ * @param type 视频还是音频举手 audio/video
1465
+ * @param raise 举手还是放下举手 true/false
1466
+ */
1467
+ raiseHandsByCustomMessage(type: 'audio' | 'video' | 'raiseHand', raise: boolean, userId: string): Promise<boolean>;
1428
1468
  /**
1429
1469
  * 主持人处理举手操作
1430
- * @param raiseHandsType 0 音视频 1 音频 2 视频 3 单纯的举手
1470
+ * @param raiseHandsType 0 音视频 1 音频 2 视频 3 单纯的举手 4:通过sendCustomMessage去举手
1431
1471
  * @param raiseHands true 同意 false 拒绝
1432
1472
  * @param uid 指定的用户Id
1433
1473
  * @description 如果不指定用户ID就是广播处理所有的举手的人员
@@ -1721,7 +1761,7 @@ declare class BMRoom {
1721
1761
  chatVM: BMChatVM;
1722
1762
  bmStreamVm: BMStreamModelVM;
1723
1763
  observes: any;
1724
- boomCore: BCClient;
1764
+ boomCore: BCClient__default;
1725
1765
  videoDevices: Device[];
1726
1766
  audioDevices: Device[];
1727
1767
  audioOutputDevices: Device[];
@@ -1763,10 +1803,7 @@ declare class BMRoom {
1763
1803
  audioDevicesWatcher: Subject<Device[]>;
1764
1804
  videoDevicesWatcher: Subject<Device[]>;
1765
1805
  audioOutputDevicesWatcher: Subject<Device[]>;
1766
- raiseHandleRespWatcher: Subject<{
1767
- raiseHandsType: 0 | 1 | 2 | 3;
1768
- raiseHands: boolean;
1769
- }>;
1806
+ raiseHandleRespWatcher: Subject<RaiseHandsParams>;
1770
1807
  enableAudienceSpeakingWatcher: Subject<boolean>;
1771
1808
  deviceChangeWatcher: Subject<boolean>;
1772
1809
  mediaPermission: MediaPermission;
@@ -2420,7 +2457,7 @@ declare class BMRoom {
2420
2457
  queryBrtcStreams(uids: string[]): Promise<_hysc_brtc.RemoteStream[]>;
2421
2458
  handleAddStreams(streams: SingleRemoteStream[]): void;
2422
2459
  getForceUser(forceId: string): Promise<void>;
2423
- queryBloudUsers(uids: string[], forceUpdateSort?: boolean): Promise<void>;
2460
+ queryBloudUsers(uids: string[], forceUpdateSort?: boolean, forceGetStream?: boolean): Promise<Map<string, BCClient.BCUser>>;
2424
2461
  getVersion(): string;
2425
2462
  }
2426
2463
 
package/dist/index.d.ts CHANGED
@@ -1,7 +1,8 @@
1
+ import * as BCClient from '@hysc/core';
2
+ import BCClient__default, { ShareMediaOptions, Player, BCUser, AudioPlayer, SMConfig } from '@hysc/core';
1
3
  import * as lodash_es from 'lodash-es';
2
4
  import * as _hysc_brtc from '@hysc/brtc';
3
5
  import { LocalStream, RemoteStream, Device, SubscribeOptions, VideoProfile, AudioHint, StreamCodecOption } from '@hysc/brtc';
4
- import BCClient, { ShareMediaOptions, Player, BCUser, AudioPlayer, SMConfig } from '@hysc/core';
5
6
  import { BehaviorSubject, Subject } from 'rxjs';
6
7
  import { BoomError } from '@hysc/utils';
7
8
  export { Logger } from '@hysc/utils';
@@ -28,6 +29,25 @@ declare type audioOffWatcherValue = {
28
29
  selfopenaudio: boolean;
29
30
  };
30
31
 
32
+ /**
33
+ * @name: index.ts
34
+ * @author: yangliye
35
+ * @date: 2022-04-25 13:42
36
+ * @description:index.ts
37
+ * @update: 2022-04-25 13:42
38
+ */
39
+
40
+ /** 举手相关操作 */
41
+ interface RaiseHandsParams {
42
+ raiseHandsType: 0 | 1 | 2 | 3 | 4;
43
+ raiseHands: boolean;
44
+ raiseInfo?: {
45
+ userId: string;
46
+ raiseHandTime: number;
47
+ type: 'raiseHandsAudio' | 'raiseHandsVideo' | 'raiseHand';
48
+ };
49
+ }
50
+
31
51
  /**
32
52
  * @name: BMSpeaker
33
53
  * @author: liuxinghai
@@ -123,12 +143,12 @@ declare class BMMessageInfo {
123
143
 
124
144
  declare class BMChatVM {
125
145
  messageList: Array<BMMessageInfo>;
126
- boomCore: BCClient;
146
+ boomCore: BCClient__default;
127
147
  userVM: BMUserVM;
128
148
  bmRoom: BMRoom;
129
149
  messageListWatcher: BehaviorSubject<Array<BMMessageInfo>>;
130
150
  hasDangerMessageWatcher: Subject<boolean>;
131
- constructor(boomCore: BCClient, userVM: BMUserVM, bmRoom: BMRoom);
151
+ constructor(boomCore: BCClient__default, userVM: BMUserVM, bmRoom: BMRoom);
132
152
  /**
133
153
  * 发送聊天消息
134
154
  * @param talkMsg 聊天信息
@@ -905,7 +925,7 @@ declare class BMUserVM {
905
925
  signalList: Map<string, BMUser>;
906
926
  /** 大房间,普通参会者列表 */
907
927
  commonUserList: Map<string, BMUser>;
908
- boomCore: BCClient;
928
+ boomCore: BCClient__default;
909
929
  room: BMRoom;
910
930
  /** 嘉宾及以上列表 */
911
931
  userListWatcher: BehaviorSubject<BMUser[]>;
@@ -919,7 +939,7 @@ declare class BMUserVM {
919
939
  getForceUserWatcher: BehaviorSubject<boolean>;
920
940
  localUser: BMUser;
921
941
  commTimer: number;
922
- constructor(boomCore: BCClient, localUser: BMUser, room: BMRoom);
942
+ constructor(boomCore: BCClient__default, localUser: BMUser, room: BMRoom);
923
943
  handleUserRoleChange(info: ChangeIsGuest): Promise<void>;
924
944
  /**
925
945
  * 添加用户, 并返回已添加的用户对象
@@ -1003,6 +1023,7 @@ declare class BMUserVM {
1003
1023
  private sortCommonUsers;
1004
1024
  private sortSignalUsers;
1005
1025
  private static filterUsers;
1026
+ private static filterUser;
1006
1027
  /**
1007
1028
  * 排序变化之后的处理逻辑
1008
1029
  */
@@ -1036,6 +1057,19 @@ declare class BMUserVM {
1036
1057
  userList: BMUser[];
1037
1058
  total: number;
1038
1059
  }>;
1060
+ /**
1061
+ * 获取观众列表
1062
+ * @param page
1063
+ * @param pageSize
1064
+ * @param mode
1065
+ */
1066
+ getAudiencesList(page: number, pageSize: number, mode?: 'map' | 'array'): Promise<{
1067
+ userList: Map<string, BMUser>;
1068
+ total: number;
1069
+ } | {
1070
+ userList: BMUser[];
1071
+ total: number;
1072
+ }>;
1039
1073
  getUsersList(page: number, pageSize: number, permission?: string, waitRoom?: boolean): Promise<{
1040
1074
  userList: BMUser[];
1041
1075
  total: number;
@@ -1356,13 +1390,13 @@ interface AudioProfileInfo {
1356
1390
  }
1357
1391
  declare class BMRoomVM {
1358
1392
  roomInfo: BMRoomInfo;
1359
- boomCore: BCClient;
1393
+ boomCore: BCClient__default;
1360
1394
  userVM: BMUserVM;
1361
1395
  giveLikeListWatcher: Subject<Array<giveLikeItem>>;
1362
1396
  giveLikeList: Array<giveLikeItem>;
1363
1397
  private room;
1364
1398
  tipQueueObj: any;
1365
- constructor(boomCore: BCClient, userVM: any, roomInfo: BMRoomInfo);
1399
+ constructor(boomCore: BCClient__default, userVM: any, roomInfo: BMRoomInfo);
1366
1400
  initWithRoom(room: BMRoom): void;
1367
1401
  /**
1368
1402
  * 踢出用户
@@ -1425,9 +1459,15 @@ declare class BMRoomVM {
1425
1459
  * @param raise 举手还是放下举手 true/false
1426
1460
  */
1427
1461
  raiseHands(type: 'audio' | 'video' | 'raiseHand', raise: boolean): Promise<void>;
1462
+ /**
1463
+ * 举手相关操作-customMessage信令发送
1464
+ * @param type 视频还是音频举手 audio/video
1465
+ * @param raise 举手还是放下举手 true/false
1466
+ */
1467
+ raiseHandsByCustomMessage(type: 'audio' | 'video' | 'raiseHand', raise: boolean, userId: string): Promise<boolean>;
1428
1468
  /**
1429
1469
  * 主持人处理举手操作
1430
- * @param raiseHandsType 0 音视频 1 音频 2 视频 3 单纯的举手
1470
+ * @param raiseHandsType 0 音视频 1 音频 2 视频 3 单纯的举手 4:通过sendCustomMessage去举手
1431
1471
  * @param raiseHands true 同意 false 拒绝
1432
1472
  * @param uid 指定的用户Id
1433
1473
  * @description 如果不指定用户ID就是广播处理所有的举手的人员
@@ -1721,7 +1761,7 @@ declare class BMRoom {
1721
1761
  chatVM: BMChatVM;
1722
1762
  bmStreamVm: BMStreamModelVM;
1723
1763
  observes: any;
1724
- boomCore: BCClient;
1764
+ boomCore: BCClient__default;
1725
1765
  videoDevices: Device[];
1726
1766
  audioDevices: Device[];
1727
1767
  audioOutputDevices: Device[];
@@ -1763,10 +1803,7 @@ declare class BMRoom {
1763
1803
  audioDevicesWatcher: Subject<Device[]>;
1764
1804
  videoDevicesWatcher: Subject<Device[]>;
1765
1805
  audioOutputDevicesWatcher: Subject<Device[]>;
1766
- raiseHandleRespWatcher: Subject<{
1767
- raiseHandsType: 0 | 1 | 2 | 3;
1768
- raiseHands: boolean;
1769
- }>;
1806
+ raiseHandleRespWatcher: Subject<RaiseHandsParams>;
1770
1807
  enableAudienceSpeakingWatcher: Subject<boolean>;
1771
1808
  deviceChangeWatcher: Subject<boolean>;
1772
1809
  mediaPermission: MediaPermission;
@@ -2420,7 +2457,7 @@ declare class BMRoom {
2420
2457
  queryBrtcStreams(uids: string[]): Promise<_hysc_brtc.RemoteStream[]>;
2421
2458
  handleAddStreams(streams: SingleRemoteStream[]): void;
2422
2459
  getForceUser(forceId: string): Promise<void>;
2423
- queryBloudUsers(uids: string[], forceUpdateSort?: boolean): Promise<void>;
2460
+ queryBloudUsers(uids: string[], forceUpdateSort?: boolean, forceGetStream?: boolean): Promise<Map<string, BCClient.BCUser>>;
2424
2461
  getVersion(): string;
2425
2462
  }
2426
2463