@vkontakte/calls-sdk 2.8.11 → 2.8.12-dev.c0dd153e.0
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/calls-sdk.cjs.js +5 -5
- package/calls-sdk.esm.js +359 -338
- package/classes/Conversation.d.ts +3 -0
- package/default/Signaling.d.ts +2 -2
- package/default/SignalingTransport.d.ts +3 -1
- package/enums/HangupType.d.ts +1 -0
- package/package.json +1 -1
- package/static/Params.d.ts +6 -9
- package/types/WebTransport.d.ts +17 -16
|
@@ -58,6 +58,8 @@ export default class Conversation extends EventEmitter {
|
|
|
58
58
|
private _serverTimeOffset;
|
|
59
59
|
private _delayedHangup;
|
|
60
60
|
private _abortController;
|
|
61
|
+
private _registeredPeerReceived;
|
|
62
|
+
private _calleeUnavailableTimer;
|
|
61
63
|
private readonly _onUnload;
|
|
62
64
|
private readonly _audioOutput;
|
|
63
65
|
private readonly _stats;
|
|
@@ -120,6 +122,7 @@ export default class Conversation extends EventEmitter {
|
|
|
120
122
|
private _getConversationParams;
|
|
121
123
|
private _setConversationParams;
|
|
122
124
|
private _buildSignalingEndpoint;
|
|
125
|
+
private _clearCalleeUnavailableWatchdog;
|
|
123
126
|
/**
|
|
124
127
|
* @throws ErrorEvent
|
|
125
128
|
*/
|
package/default/Signaling.d.ts
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import BaseSignaling, { AddParticipantParams } from '../abstract/BaseSignaling';
|
|
2
|
-
import StatsLogger from '../classes/StatsLogger';
|
|
3
2
|
import { ParticipantIdRegistry } from '../classes/ParticipantIdRegistry';
|
|
4
3
|
import { SharingStatReport } from '../classes/screenshare/SharingStatReport';
|
|
5
4
|
import { StatAggregator } from '../classes/stat/StatAggregator';
|
|
6
5
|
import { StatPings } from '../classes/stat/StatPings';
|
|
7
6
|
import { StatSignalingCommands } from '../classes/stat/StatSignalingCommands';
|
|
8
|
-
import
|
|
7
|
+
import StatsLogger from '../classes/StatsLogger';
|
|
9
8
|
import ConversationFeature from '../enums/ConversationFeature';
|
|
10
9
|
import ConversationOption from '../enums/ConversationOption';
|
|
11
10
|
import MediaOption from '../enums/MediaOption';
|
|
12
11
|
import SignalingConnectionType from '../enums/SignalingConnectionType';
|
|
12
|
+
import TransportTopology from '../enums/TransportTopology';
|
|
13
13
|
import UserRole from '../enums/UserRole';
|
|
14
14
|
import { type DebugLogger } from '../static/Debug';
|
|
15
15
|
import { JSONObject } from '../static/Json';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import SignalingConnectionType from '../enums/SignalingConnectionType';
|
|
2
2
|
import { SignalingTransportType } from '../enums/SignalingTransportStat';
|
|
3
|
+
import { DebugLogger } from '../static/Debug';
|
|
3
4
|
export declare enum SignalingTransportFailure {
|
|
4
5
|
EMPTY_ENDPOINT = "EMPTY_ENDPOINT",
|
|
5
6
|
NETWORK_ERROR = "NETWORK_ERROR",
|
|
@@ -38,7 +39,8 @@ export default class SignalingTransport {
|
|
|
38
39
|
private abortSignal;
|
|
39
40
|
private manualClose;
|
|
40
41
|
private currentType;
|
|
41
|
-
|
|
42
|
+
private readonly _debug;
|
|
43
|
+
constructor(debug: DebugLogger | undefined, handlers: SignalingTransportHandlers);
|
|
42
44
|
get readyState(): number | null;
|
|
43
45
|
get type(): SignalingTransportType;
|
|
44
46
|
setEndpoint(endpoint: string): void;
|
package/enums/HangupType.d.ts
CHANGED
|
@@ -16,6 +16,7 @@ declare enum HangupType {
|
|
|
16
16
|
CALLER_IS_BLOCKED = "CALLER_IS_BLOCKED",
|
|
17
17
|
NOT_FRIENDS = "NOT_FRIENDS",
|
|
18
18
|
CALLEE_IS_OFFLINE = "CALLEE_IS_OFFLINE",
|
|
19
|
+
CALLEE_UNAVAILABLE = "CALLEE_UNAVAILABLE",
|
|
19
20
|
CALLER_IS_REJECTED = "CALLER_IS_REJECTED",
|
|
20
21
|
UNKNOWN_ERROR = "UNKNOWN_ERROR",
|
|
21
22
|
UNSUPPORTED = "UNSUPPORTED",
|
package/package.json
CHANGED
package/static/Params.d.ts
CHANGED
|
@@ -100,6 +100,11 @@ export type ParamsObject = {
|
|
|
100
100
|
waitMessageDelay: number;
|
|
101
101
|
/** @hidden */
|
|
102
102
|
waitAnotherTabDelay: number;
|
|
103
|
+
/**
|
|
104
|
+
* Время ожидания регистрации вызываемого абонента после запуска исходящего звонка, ms.
|
|
105
|
+
* Если параметр не задан или равен 0, ожидание не ограничивается.
|
|
106
|
+
*/
|
|
107
|
+
calleeUnavailableWaitingTime?: number;
|
|
103
108
|
/** @hidden */
|
|
104
109
|
debugLog: boolean;
|
|
105
110
|
/** @hidden */
|
|
@@ -480,13 +485,6 @@ export type ParamsObject = {
|
|
|
480
485
|
* _По умолчанию: `false`_
|
|
481
486
|
*/
|
|
482
487
|
webtransport: boolean;
|
|
483
|
-
/**
|
|
484
|
-
* Включить поддержку webtransport для сигналинга в FireFox
|
|
485
|
-
* Отдельная ручка, так как есть проблемы сейчас с FF
|
|
486
|
-
*
|
|
487
|
-
* _По умолчанию: `false`_
|
|
488
|
-
*/
|
|
489
|
-
webtransportFF: boolean;
|
|
490
488
|
/**
|
|
491
489
|
* Ждать подтверждения от бэкенда для команд startStream/stopStream.
|
|
492
490
|
* При включении: reject без соединения, resolve/reject по ответу бэкенда,
|
|
@@ -945,6 +943,7 @@ export default abstract class Params {
|
|
|
945
943
|
static get waitResponseDelay(): number;
|
|
946
944
|
static get waitMessageDelay(): number;
|
|
947
945
|
static get waitAnotherTabDelay(): number;
|
|
946
|
+
static get calleeUnavailableWaitingTime(): number | undefined;
|
|
948
947
|
static get debugLog(): boolean;
|
|
949
948
|
static get forceRelayPolicy(): boolean;
|
|
950
949
|
static set forceRelayPolicy(value: boolean);
|
|
@@ -1025,7 +1024,6 @@ export default abstract class Params {
|
|
|
1025
1024
|
static get enableVideoEffectsFpsDegradation(): boolean;
|
|
1026
1025
|
static get simulcast(): boolean;
|
|
1027
1026
|
static get webtransport(): boolean;
|
|
1028
|
-
static get webtransportFF(): boolean;
|
|
1029
1027
|
static get waitForRecordResponse(): boolean;
|
|
1030
1028
|
static get transparentAudio(): boolean;
|
|
1031
1029
|
static get enableSessionStateUpdates(): boolean;
|
|
@@ -1062,7 +1060,6 @@ export default abstract class Params {
|
|
|
1062
1060
|
switchVideoAtBadNetwork: boolean;
|
|
1063
1061
|
simulcast: boolean;
|
|
1064
1062
|
webtransport: boolean;
|
|
1065
|
-
webtransportFF: boolean;
|
|
1066
1063
|
waitForRecordResponse: boolean;
|
|
1067
1064
|
transparentAudio: boolean;
|
|
1068
1065
|
enableSessionStateUpdates: boolean;
|
package/types/WebTransport.d.ts
CHANGED
|
@@ -1,31 +1,32 @@
|
|
|
1
1
|
import { WebTransportOptions } from '@fails-components/webtransport';
|
|
2
|
+
import { DebugLogger } from '../static/Debug';
|
|
2
3
|
declare class WebTransportEventual {
|
|
4
|
+
static isBrowserSupported(): boolean;
|
|
5
|
+
onopen: ((this: WebTransportEventual, ev: Event) => any) | null;
|
|
6
|
+
onmessage: ((this: WebTransportEventual, ev: MessageEvent) => any) | null;
|
|
7
|
+
onerror: ((this: WebTransportEventual, ev: Event) => any) | null;
|
|
8
|
+
onclose: ((this: WebTransportEventual, ev: CloseEvent) => any) | null;
|
|
9
|
+
readyState: number;
|
|
3
10
|
private webTransport;
|
|
4
|
-
private stream;
|
|
5
11
|
private writer;
|
|
6
|
-
private reader;
|
|
7
12
|
private readonly url;
|
|
8
13
|
private readonly options;
|
|
9
14
|
private readonly compression;
|
|
10
|
-
private closeRequested;
|
|
11
|
-
private closeEventEmitted;
|
|
12
15
|
private encoder;
|
|
13
16
|
private decoder;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
readyState: number;
|
|
19
|
-
constructor(url: string, options?: WebTransportOptions);
|
|
17
|
+
private readonly _debug;
|
|
18
|
+
constructor(url: string, options?: WebTransportOptions, debug?: DebugLogger);
|
|
19
|
+
send(data: string): Promise<void>;
|
|
20
|
+
close(code?: number, reason?: string): void;
|
|
20
21
|
private getCompressionTypeFromUrl;
|
|
21
22
|
private connect;
|
|
22
|
-
private
|
|
23
|
+
private observeClosed;
|
|
23
24
|
private readLoop;
|
|
24
|
-
|
|
25
|
+
private fail;
|
|
26
|
+
private handleStreamError;
|
|
27
|
+
private requestNativeClose;
|
|
28
|
+
private finishClose;
|
|
29
|
+
private emitEvent;
|
|
25
30
|
private createErrorEvent;
|
|
26
|
-
close(code?: number, reason?: string): void;
|
|
27
|
-
private closeConnectedTransport;
|
|
28
|
-
private emitClose;
|
|
29
|
-
static isBrowserSupported(): boolean;
|
|
30
31
|
}
|
|
31
32
|
export { WebTransportEventual as WebTransport };
|