@polyv/socket 2.2.0-rc-20251113.1 → 2.3.0-rc-20251204.1
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/index.cjs.js +11 -11
- package/index.es.d.ts +57 -0
- package/index.es.js +1968 -1943
- package/index.umd.js +11 -11
- package/package.json +1 -1
package/index.es.d.ts
CHANGED
|
@@ -19,6 +19,10 @@ declare interface ChannelInfo {
|
|
|
19
19
|
* 场次号
|
|
20
20
|
*/
|
|
21
21
|
sessionId?: string;
|
|
22
|
+
/**
|
|
23
|
+
* 是否指定场次
|
|
24
|
+
*/
|
|
25
|
+
inTargetSession: boolean;
|
|
22
26
|
/**
|
|
23
27
|
* 保利威账号 id
|
|
24
28
|
*/
|
|
@@ -37,6 +41,11 @@ export declare interface ChannelInfoOptions {
|
|
|
37
41
|
* 场次号
|
|
38
42
|
*/
|
|
39
43
|
sessionId?: string;
|
|
44
|
+
/**
|
|
45
|
+
* 是否指定场次
|
|
46
|
+
* @default false
|
|
47
|
+
*/
|
|
48
|
+
inTargetSession?: boolean;
|
|
40
49
|
/**
|
|
41
50
|
* 保利威账号 id
|
|
42
51
|
*/
|
|
@@ -56,7 +65,17 @@ declare class ChannelModule extends SocketModuleBase {
|
|
|
56
65
|
* 保利威账号 id
|
|
57
66
|
*/
|
|
58
67
|
private __accountId?;
|
|
68
|
+
/**
|
|
69
|
+
* 是否指定场次
|
|
70
|
+
*/
|
|
71
|
+
private __inTargetSession;
|
|
72
|
+
/**
|
|
73
|
+
* 讲师信息
|
|
74
|
+
*/
|
|
75
|
+
private __teacherInfo?;
|
|
59
76
|
constructor(plvSocket: PolyvSocket);
|
|
77
|
+
private __onTeacherInfo;
|
|
78
|
+
getTeacherInfo(): TeacherInfo | undefined;
|
|
60
79
|
getChannelInfo(): Promise<ChannelInfo>;
|
|
61
80
|
/**
|
|
62
81
|
* 更新场次信息
|
|
@@ -285,6 +304,7 @@ export declare class PolyvSocket {
|
|
|
285
304
|
* @returns 是否特殊身份
|
|
286
305
|
*/
|
|
287
306
|
isSpecialUserType(userType: SocketUserType | unknown, actor?: string): boolean;
|
|
307
|
+
currentIsSpecialUser(): boolean;
|
|
288
308
|
/**
|
|
289
309
|
* 判断是否为当前用户
|
|
290
310
|
* @param userId 用户 id
|
|
@@ -309,6 +329,10 @@ export declare interface PolyvSocketConfig {
|
|
|
309
329
|
* 用户信息
|
|
310
330
|
*/
|
|
311
331
|
userInfo: UserInfo | (() => UserInfo);
|
|
332
|
+
/**
|
|
333
|
+
* 讲师信息
|
|
334
|
+
*/
|
|
335
|
+
teacherInfo?: TeacherInfo;
|
|
312
336
|
/**
|
|
313
337
|
* 域名信息
|
|
314
338
|
*/
|
|
@@ -576,6 +600,28 @@ export declare interface StatisticsParams {
|
|
|
576
600
|
param5?: string;
|
|
577
601
|
}
|
|
578
602
|
|
|
603
|
+
/**
|
|
604
|
+
* 讲师信息
|
|
605
|
+
*/
|
|
606
|
+
export declare interface TeacherInfo {
|
|
607
|
+
/**
|
|
608
|
+
* 用户 id
|
|
609
|
+
*/
|
|
610
|
+
userId: string;
|
|
611
|
+
/**
|
|
612
|
+
* 用户昵称
|
|
613
|
+
*/
|
|
614
|
+
nick: string;
|
|
615
|
+
/**
|
|
616
|
+
* 用户头像
|
|
617
|
+
*/
|
|
618
|
+
pic: string;
|
|
619
|
+
/**
|
|
620
|
+
* 头衔
|
|
621
|
+
*/
|
|
622
|
+
actor?: string;
|
|
623
|
+
}
|
|
624
|
+
|
|
579
625
|
declare interface TrackEventData {
|
|
580
626
|
/** 事件名 */
|
|
581
627
|
event_id: string;
|
|
@@ -586,7 +632,14 @@ declare interface TrackEventData {
|
|
|
586
632
|
}
|
|
587
633
|
|
|
588
634
|
declare interface UpdateSessionOptions {
|
|
635
|
+
/**
|
|
636
|
+
* 场次号
|
|
637
|
+
*/
|
|
589
638
|
sessionId?: string;
|
|
639
|
+
/**
|
|
640
|
+
* 是否指定场次
|
|
641
|
+
*/
|
|
642
|
+
inTargetSession?: boolean;
|
|
590
643
|
}
|
|
591
644
|
|
|
592
645
|
/**
|
|
@@ -621,6 +674,10 @@ export declare interface UserInfo {
|
|
|
621
674
|
* 用户登录方式
|
|
622
675
|
*/
|
|
623
676
|
authType?: string;
|
|
677
|
+
/**
|
|
678
|
+
* 分组 id
|
|
679
|
+
*/
|
|
680
|
+
groupId?: string;
|
|
624
681
|
/**
|
|
625
682
|
* 微信 unionId
|
|
626
683
|
*/
|