@realsee/live 0.6.11-dev.1 → 0.6.12-alpha.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/dist/index.cjs.js +1 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +18 -8
- package/dist/index.es.js.map +1 -1
- package/dist/live/controller.d.ts +1 -0
- package/dist/live/live.d.ts +12 -0
- package/dist/typings/live/EventType.d.ts +11 -0
- package/dist/utils/RobustWebSocket.d.ts +3 -0
- package/docs/assets/search.js +1 -1
- package/docs/types/EventType.html +1 -1
- package/docs/types/KeyframeTypes.html +1 -1
- package/docs/types/LiveEventType.html +43 -13
- package/package.json +1 -1
|
@@ -5,6 +5,7 @@ import { Subscribe } from '../utils/subscribe';
|
|
|
5
5
|
export type LiveControllerEventMap = {
|
|
6
6
|
stateChange: (state: LiveState, prevState: LiveState) => void;
|
|
7
7
|
message: (message: LiveMsg) => void;
|
|
8
|
+
reconnecting: (detail: RobustWebSocketEventDetail) => void;
|
|
8
9
|
reconnected: (detail: RobustWebSocketEventDetail) => void;
|
|
9
10
|
};
|
|
10
11
|
export declare class LiveController extends Subscribe<LiveControllerEventMap> {
|
package/dist/live/live.d.ts
CHANGED
|
@@ -92,6 +92,18 @@ export declare class Live<KeyframesSnapshot extends Record<string, any>> extends
|
|
|
92
92
|
* 移除带看控制的事件监听
|
|
93
93
|
*/
|
|
94
94
|
private _removeLiveControllerEventListeners;
|
|
95
|
+
/**
|
|
96
|
+
* 重连中事件
|
|
97
|
+
* @param detail
|
|
98
|
+
* @returns
|
|
99
|
+
*/
|
|
100
|
+
private _handleReconnecting;
|
|
101
|
+
/**
|
|
102
|
+
* 重连成功事件
|
|
103
|
+
* @param detail
|
|
104
|
+
* @returns
|
|
105
|
+
*/
|
|
106
|
+
private _handleReconnected;
|
|
95
107
|
/**
|
|
96
108
|
* 带看状态变化
|
|
97
109
|
* @param state
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { RobustWebSocketEventDetail } from '../../utils/RobustWebSocket';
|
|
1
2
|
import { BuiltinMsg, LiveMsg } from './LiveMsg';
|
|
2
3
|
import { LiveState } from './LiveState';
|
|
3
4
|
import { UserInfo } from './UserInfo';
|
|
@@ -61,6 +62,16 @@ export type LiveEventType<KeyframesSnapshot> = {
|
|
|
61
62
|
* @param liveMsg
|
|
62
63
|
*/
|
|
63
64
|
'error'(liveMsg: LiveMsg): void;
|
|
65
|
+
/**
|
|
66
|
+
* 重新连接成功
|
|
67
|
+
* @param detail
|
|
68
|
+
*/
|
|
69
|
+
'reconnected'(detail: RobustWebSocketEventDetail): void;
|
|
70
|
+
/**
|
|
71
|
+
* 重新连接中
|
|
72
|
+
* @param detail
|
|
73
|
+
*/
|
|
74
|
+
'reconnecting'(detail: RobustWebSocketEventDetail): void;
|
|
64
75
|
};
|
|
65
76
|
/**
|
|
66
77
|
* 帧数据类型
|