@vkontakte/calls-sdk 2.6.2-beta.16 → 2.6.2-beta.18
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/CallsSDK.d.ts +9 -3
- package/abstract/BaseApi.d.ts +6 -2
- package/abstract/BaseSignaling.d.ts +2 -0
- package/calls-sdk.cjs.js +7 -7
- package/calls-sdk.esm.js +7 -7
- package/classes/Conversation.d.ts +3 -1
- package/default/Api.d.ts +6 -2
- package/default/Signaling.d.ts +2 -0
- package/enums/ConversationFeature.d.ts +2 -1
- package/enums/SignalingCommandType.d.ts +1 -0
- package/package.json +1 -1
- package/types/SignalingMessage.d.ts +2 -0
|
@@ -38,6 +38,7 @@ export declare type ConversationData = {
|
|
|
38
38
|
*/
|
|
39
39
|
acceptTime: number | null;
|
|
40
40
|
features: ConversationFeature[];
|
|
41
|
+
featuresPerRole?: Partial<Record<ConversationFeature, UserRole[]>> | null;
|
|
41
42
|
/**
|
|
42
43
|
* ID звонка
|
|
43
44
|
*/
|
|
@@ -108,7 +109,7 @@ export default class Conversation extends EventEmitter {
|
|
|
108
109
|
static current(): Conversation | null;
|
|
109
110
|
static hangupAfterInit(): void;
|
|
110
111
|
static id(): string | null;
|
|
111
|
-
onStart(opponentIds: OkUserId[], opponentType: CallType, mediaOptions: MediaOption[], payload?: string, joiningAllowed?: boolean, requireAuthToJoin?: boolean): Promise<ConversationData>;
|
|
112
|
+
onStart(opponentIds: OkUserId[], opponentType: CallType, mediaOptions: MediaOption[], payload?: string, joiningAllowed?: boolean, requireAuthToJoin?: boolean, onlyAdminCanShareMovie?: boolean): Promise<ConversationData>;
|
|
112
113
|
onJoin(joinArgs: {
|
|
113
114
|
conversationId?: string;
|
|
114
115
|
mediaOptions: MediaOption[];
|
|
@@ -220,6 +221,7 @@ export default class Conversation extends EventEmitter {
|
|
|
220
221
|
private _checkAdminRole;
|
|
221
222
|
grantRoles(participantId: CompositeUserId, roles: UserRole[], revoke: boolean): Promise<void>;
|
|
222
223
|
muteParticipant(participantId: ParticipantId | null, muteStates: MuteStates, requestedMedia?: MediaOption[]): Promise<void>;
|
|
224
|
+
enableFeatureForRoles(feature: ConversationFeature, roles: UserRole[]): Promise<void>;
|
|
223
225
|
pinParticipant(participantId: ParticipantId, unpin: boolean): Promise<void>;
|
|
224
226
|
updateMediaModifiers(mediaModifiers: MediaModifiers): Promise<void>;
|
|
225
227
|
changeOptions(changes: {
|
package/default/Api.d.ts
CHANGED
|
@@ -16,8 +16,12 @@ export default class Api extends BaseApi {
|
|
|
16
16
|
log(items: LogItem[]): void;
|
|
17
17
|
init(): void;
|
|
18
18
|
joinConversation(conversationId: string, isVideo?: boolean, chatId?: string): Promise<ConversationResponse>;
|
|
19
|
-
createConversation(conversationId: string, payload?: string, requireAuthToJoin?: boolean
|
|
20
|
-
|
|
19
|
+
createConversation(conversationId: string, payload?: string, requireAuthToJoin?: boolean, { onlyAdminCanShareMovie }?: {
|
|
20
|
+
onlyAdminCanShareMovie?: boolean;
|
|
21
|
+
}): Promise<ConversationResponse>;
|
|
22
|
+
startConversation(conversationId: string, ids?: OkUserId[], type?: CallType, isVideo?: boolean, payload?: string, joiningAllowed?: boolean, requireAuthToJoin?: boolean, { onlyAdminCanShareMovie }?: {
|
|
23
|
+
onlyAdminCanShareMovie?: boolean;
|
|
24
|
+
}): Promise<ConversationResponse>;
|
|
21
25
|
private _preareStartConversationData;
|
|
22
26
|
private _startConversation;
|
|
23
27
|
createJoinLink(conversationId: string): Promise<{
|
package/default/Signaling.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import BaseSignaling, { AddParticipantParams } from '../abstract/BaseSignaling';
|
|
|
2
2
|
import { ParticipantIdRegistry } from '../classes/ParticipantIdRegistry';
|
|
3
3
|
import { PerfStatReport } from '../classes/transport/PerfStatReporter';
|
|
4
4
|
import { TransportTopology } from '../classes/transport/Transport';
|
|
5
|
+
import ConversationFeature from '../enums/ConversationFeature';
|
|
5
6
|
import ConversationOption from '../enums/ConversationOption';
|
|
6
7
|
import MediaOption from '../enums/MediaOption';
|
|
7
8
|
import RecordRole from '../enums/RecordRole';
|
|
@@ -112,6 +113,7 @@ export default class Signaling extends BaseSignaling {
|
|
|
112
113
|
customData(data: JSONObject, participantId: ParticipantId | null): Promise<SignalingMessage>;
|
|
113
114
|
grantRoles(participantId: CompositeUserId, roles: UserRole[], revoke: boolean): Promise<SignalingMessage>;
|
|
114
115
|
muteParticipant(participantId: ParticipantId | null, muteStates: MuteStates, requestedMedia: MediaOption[]): Promise<SignalingMessage>;
|
|
116
|
+
enableFeatureForRoles(feature: ConversationFeature, roles: UserRole[]): Promise<SignalingMessage>;
|
|
115
117
|
pinParticipant(participantId: ParticipantId, unpin: boolean): Promise<SignalingMessage>;
|
|
116
118
|
updateMediaModifiers(mediaModifiers: MediaModifiers): Promise<SignalingMessage>;
|
|
117
119
|
changeOptions(changes: {
|
|
@@ -24,6 +24,7 @@ declare enum SignalingCommandType {
|
|
|
24
24
|
CUSTOM_DATA = "custom-data",
|
|
25
25
|
GRANT_ROLES = "grant-roles",
|
|
26
26
|
MUTE_PARTICIPANT = "mute-participant",
|
|
27
|
+
ENABLE_FEATURE_FOR_ROLES = "enable-feature-for-roles",
|
|
27
28
|
PIN_PARTICIPANT = "pin-participant",
|
|
28
29
|
UPDATE_MEDIA_MODIFIERS = "update-media-modifiers",
|
|
29
30
|
CHANGE_OPTIONS = "change-options",
|
package/package.json
CHANGED
|
@@ -74,6 +74,7 @@ declare namespace SignalingMessage {
|
|
|
74
74
|
multichatId: string | null;
|
|
75
75
|
tamtamMultichatId: string | null;
|
|
76
76
|
recordInfo: RecordInfo | null;
|
|
77
|
+
featuresPerRole?: Partial<Record<ConversationFeature, UserRole[]>> | null;
|
|
77
78
|
pinnedParticipantId: ParticipantId | null;
|
|
78
79
|
options: ConversationOption[];
|
|
79
80
|
muteStates?: MuteStates;
|
|
@@ -188,6 +189,7 @@ declare namespace SignalingMessage {
|
|
|
188
189
|
}
|
|
189
190
|
export interface FeatureSetChanged extends Notification {
|
|
190
191
|
features: ConversationFeature[];
|
|
192
|
+
featuresPerRole?: Partial<Record<ConversationFeature, UserRole[]>> | null;
|
|
191
193
|
}
|
|
192
194
|
export interface MultipartyChatCreated extends Notification {
|
|
193
195
|
chatId: string;
|