architwin 1.0.39 → 1.0.40
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/lib/superviz.d.ts +19 -0
- package/lib/superviz.js +337 -0
- package/lib/supervizTypes.js +95 -0
- package/package.json +1 -1
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
declare let isMeetingInitialized: boolean;
|
|
2
|
+
declare function generateMeetingURL(meeting_id?: string): Promise<{
|
|
3
|
+
host: string;
|
|
4
|
+
guest: string;
|
|
5
|
+
meeting_id: string;
|
|
6
|
+
}>;
|
|
7
|
+
declare function createMeeting(spaceId?: any, hostName?: string, title?: string, meetingStart?: any, duration?: number, password?: string): Promise<{
|
|
8
|
+
host: string;
|
|
9
|
+
guest: string;
|
|
10
|
+
meeting_id: any;
|
|
11
|
+
}>;
|
|
12
|
+
declare function getMeeting(meetingId: string): Promise<import("axios").AxiosResponse<any, any>>;
|
|
13
|
+
declare function getSpaceMeetings(spaceId: number): Promise<import("axios").AxiosResponse<any, any>>;
|
|
14
|
+
declare function startMeeting(meetingApiKey: any): Promise<void>;
|
|
15
|
+
declare function getMeetingParticipants(): IMpParticipant[];
|
|
16
|
+
declare function stopMeeting(): Promise<void>;
|
|
17
|
+
declare function isMeetingExists(meetingId: string): Promise<boolean>;
|
|
18
|
+
declare function isMeetingActive(meetingId: string): Promise<boolean>;
|
|
19
|
+
export { isMeetingInitialized, getMeetingParticipants, createMeeting, startMeeting, stopMeeting, generateMeetingURL, getMeeting, getSpaceMeetings, isMeetingExists, isMeetingActive, };
|
package/lib/superviz.js
ADDED
|
@@ -0,0 +1,337 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import SuperVizSdk, { MeetingEvent } from '@superviz/sdk';
|
|
11
|
+
import { MatterportPlugin } from "@superviz/matterport-plugin";
|
|
12
|
+
//import {config,_atwin} from 'architwin'
|
|
13
|
+
import * as atwin from "./architwin";
|
|
14
|
+
import { v4 as uuidv4 } from 'uuid';
|
|
15
|
+
let baseURL = new URL(window.location.href);
|
|
16
|
+
let meetingLink = '';
|
|
17
|
+
let atwinObj;
|
|
18
|
+
let supervizSdk;
|
|
19
|
+
let pluginInstance;
|
|
20
|
+
let meetingInstanceApiKey;
|
|
21
|
+
let isMeetingInitialized = false;
|
|
22
|
+
let _participants = [];
|
|
23
|
+
const currentURL = window.location.href;
|
|
24
|
+
function generateMeetingURL(meeting_id = '') {
|
|
25
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
+
if (meeting_id !== '') {
|
|
27
|
+
let response = yield validateMeetingID(meeting_id);
|
|
28
|
+
if (response.status === "success") {
|
|
29
|
+
const urlSearchParams = baseURL.searchParams;
|
|
30
|
+
if (urlSearchParams.get('meetingId') === null || urlSearchParams.get('role') === null) {
|
|
31
|
+
meetingLink = baseURL + '?meetingId=' + meeting_id;
|
|
32
|
+
let meetingLinks = {
|
|
33
|
+
host: meetingLink + '&role=host',
|
|
34
|
+
guest: meetingLink + '&role=guest',
|
|
35
|
+
meeting_id: meeting_id,
|
|
36
|
+
};
|
|
37
|
+
console.log('=== MEETING LINK ===', meetingLinks);
|
|
38
|
+
return meetingLinks;
|
|
39
|
+
}
|
|
40
|
+
else {
|
|
41
|
+
console.error('Meeting ID and role parameters already exist!');
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
else {
|
|
45
|
+
console.error('Error: Meeting ID is invalid!');
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
else {
|
|
49
|
+
console.error('Meeting ID required!');
|
|
50
|
+
}
|
|
51
|
+
return;
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
function validateMeetingID(meetingId) {
|
|
55
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
56
|
+
try {
|
|
57
|
+
const response = yield atwin._api.get(`/v1/meetings?meeting_id=${meetingId}`);
|
|
58
|
+
if (response.data.status === "success") {
|
|
59
|
+
return response.data;
|
|
60
|
+
}
|
|
61
|
+
else {
|
|
62
|
+
console.error('Error: Meeting ID does not exist or match.');
|
|
63
|
+
return response.data;
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
catch (error) {
|
|
67
|
+
console.error(error);
|
|
68
|
+
}
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
function createMeeting(spaceId, hostName, title, meetingStart, duration, password) {
|
|
72
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
73
|
+
console.log('=== PASSED PARAMETERS ===', spaceId, hostName, title, meetingStart, duration, password);
|
|
74
|
+
let meeting_uid = uuidv4().toString();
|
|
75
|
+
if (atwin._spaceId != '' && atwin._space != null) {
|
|
76
|
+
let payload = {
|
|
77
|
+
space_id: spaceId,
|
|
78
|
+
meeting_id: meeting_uid,
|
|
79
|
+
host_name: hostName,
|
|
80
|
+
title: title,
|
|
81
|
+
meeting_start: meetingStart,
|
|
82
|
+
meeting_status: meetingStart === '' || meetingStart === undefined ? 1 /* MeetingStatus.STARTED */ : 0 /* MeetingStatus.SCHEDULED */,
|
|
83
|
+
duration: duration,
|
|
84
|
+
password: password
|
|
85
|
+
};
|
|
86
|
+
atwin._api.post('/v1/meetings', payload)
|
|
87
|
+
.then((response) => __awaiter(this, void 0, void 0, function* () {
|
|
88
|
+
console.log(response.data);
|
|
89
|
+
if (response.data.status == 'success') {
|
|
90
|
+
let meetingUrls = yield generateMeetingURL(meeting_uid);
|
|
91
|
+
return meetingUrls;
|
|
92
|
+
}
|
|
93
|
+
else {
|
|
94
|
+
console.log('=== Meeting not stored! ===');
|
|
95
|
+
}
|
|
96
|
+
}))
|
|
97
|
+
.catch(error => {
|
|
98
|
+
console.error(error);
|
|
99
|
+
});
|
|
100
|
+
}
|
|
101
|
+
else {
|
|
102
|
+
meetingLink = baseURL + '?meetingId=' + meeting_uid;
|
|
103
|
+
let meetingLinks = {
|
|
104
|
+
host: meetingLink + '&role=host',
|
|
105
|
+
guest: meetingLink + '&role=guest',
|
|
106
|
+
meeting_id: meeting_uid,
|
|
107
|
+
};
|
|
108
|
+
console.log('=== MEETING LINK ===', meetingLinks);
|
|
109
|
+
return meetingLinks;
|
|
110
|
+
}
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
function validateSpaceMeeting(spaceId, meetingId) {
|
|
114
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
115
|
+
try {
|
|
116
|
+
const response = yield atwin._api.get(`/v1/meetings?space_id=${spaceId}&meeting_id=${meetingId}`);
|
|
117
|
+
console.log('=== VALIDATE RESPONSE ===', response.data);
|
|
118
|
+
if (response.data.status === "success") {
|
|
119
|
+
return true;
|
|
120
|
+
}
|
|
121
|
+
else {
|
|
122
|
+
console.error('Error: Space ID and Meeting ID do not exist or match.');
|
|
123
|
+
return false;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
catch (error) {
|
|
127
|
+
console.error(error);
|
|
128
|
+
return false;
|
|
129
|
+
}
|
|
130
|
+
});
|
|
131
|
+
}
|
|
132
|
+
function getMeeting(meetingId) {
|
|
133
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
134
|
+
try {
|
|
135
|
+
const response = yield atwin._api.get(`/v1/meetings?meeting_id=${meetingId}`);
|
|
136
|
+
if (response.status === 200) {
|
|
137
|
+
return response;
|
|
138
|
+
}
|
|
139
|
+
else {
|
|
140
|
+
throw new Error('Request failed with status code ' + response.status);
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
catch (error) {
|
|
144
|
+
console.error(error);
|
|
145
|
+
}
|
|
146
|
+
});
|
|
147
|
+
}
|
|
148
|
+
function getSpaceMeetings(spaceId) {
|
|
149
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
150
|
+
try {
|
|
151
|
+
const response = yield atwin._api.get(`/v1/meetings?space_id=${spaceId}`);
|
|
152
|
+
console.log('getSpaceMeetings response', response);
|
|
153
|
+
if (response.status === 200) {
|
|
154
|
+
return response;
|
|
155
|
+
}
|
|
156
|
+
else {
|
|
157
|
+
throw new Error('Request failed with status code ' + response.status);
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
catch (error) {
|
|
161
|
+
console.error(error);
|
|
162
|
+
}
|
|
163
|
+
});
|
|
164
|
+
}
|
|
165
|
+
function startMeeting(meetingApiKey) {
|
|
166
|
+
var _a, _b;
|
|
167
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
168
|
+
while (!((_b = (_a = atwinObj === null || atwinObj === void 0 ? void 0 : atwinObj.App) === null || _a === void 0 ? void 0 : _a.Phase) === null || _b === void 0 ? void 0 : _b.PLAYING)) {
|
|
169
|
+
console.log('== Wait for _atwin ==');
|
|
170
|
+
yield new Promise(resolve => setTimeout(resolve, 1000));
|
|
171
|
+
atwinObj = atwin._atwin;
|
|
172
|
+
}
|
|
173
|
+
if (currentURL.includes("meetingId")) {
|
|
174
|
+
let meetingIdParam = baseURL.searchParams.get('meetingId');
|
|
175
|
+
let userRole = baseURL.searchParams.get('role');
|
|
176
|
+
if (atwin._spaceId != '' && atwin._space != null) {
|
|
177
|
+
let shouldAtwinMeetingStart = yield preStartChecking(atwin._spaceId, meetingIdParam);
|
|
178
|
+
if (shouldAtwinMeetingStart == true) {
|
|
179
|
+
startMeetingSdk(meetingApiKey, meetingIdParam, userRole);
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
else {
|
|
183
|
+
startMeetingSdk(meetingApiKey, meetingIdParam, userRole);
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
else {
|
|
187
|
+
console.log('=== Meeting ID is required ===');
|
|
188
|
+
return;
|
|
189
|
+
}
|
|
190
|
+
});
|
|
191
|
+
}
|
|
192
|
+
function startMeetingSdk(meetingApiKey, meetingIdParam, userRole) {
|
|
193
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
194
|
+
yield atwinObj.App.state.waitUntil(state => state.phase === atwinObj.App.Phase.PLAYING);
|
|
195
|
+
console.log(`=== Initialize meeting in: Space ID ${atwin._spaceId}, Meeting ID ${meetingIdParam} ===`);
|
|
196
|
+
supervizSdk = yield SuperVizSdk.init(meetingApiKey, {
|
|
197
|
+
group: {
|
|
198
|
+
id: "<GROUP-ID>",
|
|
199
|
+
name: "<GROUP-NAME>"
|
|
200
|
+
},
|
|
201
|
+
participant: {
|
|
202
|
+
id: Date.now().toPrecision(20),
|
|
203
|
+
type: userRole,
|
|
204
|
+
},
|
|
205
|
+
roomId: meetingIdParam,
|
|
206
|
+
defaultAvatars: true,
|
|
207
|
+
enableFollow: true,
|
|
208
|
+
enableGoTo: true,
|
|
209
|
+
enableGather: true,
|
|
210
|
+
debug: true,
|
|
211
|
+
camerasOrientation: 'horizontal',
|
|
212
|
+
camerasPosition: 'left',
|
|
213
|
+
layoutPosition: 'center',
|
|
214
|
+
});
|
|
215
|
+
isMeetingInitialized = true;
|
|
216
|
+
const plugin = new MatterportPlugin(atwinObj);
|
|
217
|
+
atwin.setViewMode('DOLLHOUSE');
|
|
218
|
+
supervizSdk.subscribe(MeetingEvent.MY_PARTICIPANT_JOINED, () => {
|
|
219
|
+
//@ts-ignore
|
|
220
|
+
pluginInstance = supervizSdk.loadPlugin(plugin, {
|
|
221
|
+
avatarConfig: {
|
|
222
|
+
height: 0,
|
|
223
|
+
scale: 1,
|
|
224
|
+
laserOrigin: { x: 0, y: 0, z: 0 },
|
|
225
|
+
},
|
|
226
|
+
isAvatarsEnabled: true,
|
|
227
|
+
isLaserEnabled: true,
|
|
228
|
+
isNameEnabled: true,
|
|
229
|
+
});
|
|
230
|
+
console.log('== PLUGIN LOADED ==');
|
|
231
|
+
atwin.setViewMode('INSIDE');
|
|
232
|
+
});
|
|
233
|
+
supervizSdk.subscribe(MeetingEvent.MEETING_PARTICIPANT_LIST_UPDATE, (participants) => {
|
|
234
|
+
console.log('===MEETING_PARTICIPANT_LIST_UPDATE', participants);
|
|
235
|
+
_participants = participants;
|
|
236
|
+
});
|
|
237
|
+
});
|
|
238
|
+
}
|
|
239
|
+
// return list of participants and add color prop from getParticipantsOn3D()
|
|
240
|
+
function getMeetingParticipants() {
|
|
241
|
+
console.log('===superviz: getParticipants()');
|
|
242
|
+
if (_participants.length === 0)
|
|
243
|
+
return;
|
|
244
|
+
const participantsOn3d = pluginInstance.getParticipantsOn3D();
|
|
245
|
+
for (let p3d of participantsOn3d) {
|
|
246
|
+
const p = _participants.find(i => i.id === p3d.id);
|
|
247
|
+
if (!p) {
|
|
248
|
+
console.error('Participant not found on _participants array from _participantsOn3d', p3d);
|
|
249
|
+
continue;
|
|
250
|
+
}
|
|
251
|
+
p3d.color = p.color;
|
|
252
|
+
}
|
|
253
|
+
console.log('===_participantsOn3d', participantsOn3d);
|
|
254
|
+
return participantsOn3d;
|
|
255
|
+
}
|
|
256
|
+
function stopMeeting() {
|
|
257
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
258
|
+
supervizSdk.destroy();
|
|
259
|
+
});
|
|
260
|
+
}
|
|
261
|
+
//To be added:
|
|
262
|
+
function isMeetingExists(meetingId) {
|
|
263
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
264
|
+
let response = yield getMeeting(meetingId);
|
|
265
|
+
if (response.data.status == "success") {
|
|
266
|
+
return true;
|
|
267
|
+
}
|
|
268
|
+
else {
|
|
269
|
+
return false;
|
|
270
|
+
}
|
|
271
|
+
});
|
|
272
|
+
}
|
|
273
|
+
function isMeetingActive(meetingId) {
|
|
274
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
275
|
+
try {
|
|
276
|
+
const response = yield getMeeting(meetingId);
|
|
277
|
+
return response.data.status === "success" && (response.data.data.meeting_status === 0 || response.data.data.meeting_status === 1);
|
|
278
|
+
}
|
|
279
|
+
catch (error) {
|
|
280
|
+
console.error("== Error: ===", error);
|
|
281
|
+
return false;
|
|
282
|
+
}
|
|
283
|
+
});
|
|
284
|
+
}
|
|
285
|
+
function getMeetingStatus(meetingId) {
|
|
286
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
287
|
+
try {
|
|
288
|
+
const response = yield getMeeting(meetingId);
|
|
289
|
+
if (response.data.status === "success") {
|
|
290
|
+
const meetingStatus = response.data.data.meeting_status;
|
|
291
|
+
if (meetingStatus === 0 || meetingStatus === 1 || meetingStatus === 2 || meetingStatus === 3) {
|
|
292
|
+
return meetingStatus;
|
|
293
|
+
}
|
|
294
|
+
else {
|
|
295
|
+
console.error("=== Invalid meeting status: ===", meetingStatus);
|
|
296
|
+
return;
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
else {
|
|
300
|
+
console.error("=== Error ===", response);
|
|
301
|
+
return;
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
catch (error) {
|
|
305
|
+
console.error("=== Catch Error ===", error);
|
|
306
|
+
return;
|
|
307
|
+
}
|
|
308
|
+
});
|
|
309
|
+
}
|
|
310
|
+
function preStartChecking(spaceId, meetingId) {
|
|
311
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
312
|
+
let validMeeting = yield validateSpaceMeeting(spaceId, meetingId);
|
|
313
|
+
if (validMeeting) {
|
|
314
|
+
return true;
|
|
315
|
+
}
|
|
316
|
+
else {
|
|
317
|
+
return false;
|
|
318
|
+
}
|
|
319
|
+
// let meetingStatus = await getMeetingStatus(meetingId);
|
|
320
|
+
// let meetingData = await getMeeting(meetingId);
|
|
321
|
+
// if (validMeeting) {
|
|
322
|
+
// if (meetingStatus === 0) {
|
|
323
|
+
// const formatMeetingDateTime = new Date(meetingData.data.data.meeting_start);
|
|
324
|
+
// const dateTimeNow = new Date(Date.now());
|
|
325
|
+
// if (dateTimeNow > formatMeetingDateTime) {
|
|
326
|
+
// return true;
|
|
327
|
+
// }
|
|
328
|
+
// } else if (meetingStatus === 1) {
|
|
329
|
+
// return true;
|
|
330
|
+
// } else if (meetingStatus === 2 || 3){
|
|
331
|
+
// return false
|
|
332
|
+
// }
|
|
333
|
+
// }
|
|
334
|
+
// return false;
|
|
335
|
+
});
|
|
336
|
+
}
|
|
337
|
+
export { isMeetingInitialized, getMeetingParticipants, createMeeting, startMeeting, stopMeeting, generateMeetingURL, getMeeting, getSpaceMeetings, isMeetingExists, isMeetingActive, };
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
export var MeetingEvent;
|
|
2
|
+
(function (MeetingEvent) {
|
|
3
|
+
MeetingEvent["MEETING_START"] = "meeting.start";
|
|
4
|
+
MeetingEvent["MEETING_LEAVE"] = "meeting.leave";
|
|
5
|
+
MeetingEvent["MEETING_PARTICIPANT_AMOUNT_UPDATE"] = "meeting.amount-of-participants-update";
|
|
6
|
+
MeetingEvent["MEETING_PARTICIPANT_LIST_UPDATE"] = "meeting.participant-list-update";
|
|
7
|
+
MeetingEvent["MEETING_PARTICIPANT_JOINED"] = "meeting.participant-joined";
|
|
8
|
+
MeetingEvent["MEETING_PARTICIPANT_LEFT"] = "meeting.participant-left";
|
|
9
|
+
MeetingEvent["MEETING_JOIN"] = "meeting.join";
|
|
10
|
+
MeetingEvent["MEETING_PARTICIPANT_PROPERTIES"] = "meeting.participant-properties";
|
|
11
|
+
MeetingEvent["MEETING_HOST_CHANGE"] = "meeting.host-change";
|
|
12
|
+
MeetingEvent["MEETING_GRID_MODE_CHANGE"] = "meeting.grid-mode-change";
|
|
13
|
+
MeetingEvent["MEETING_SAME_PARTICIPANT_ERROR"] = "meeting.same-participant-error";
|
|
14
|
+
MeetingEvent["MEETING_DEVICES_CHANGE"] = "meeting.devices-change";
|
|
15
|
+
MeetingEvent["MEETING_KICK_PARTICIPANTS"] = "meeting.kick-all-participants";
|
|
16
|
+
MeetingEvent["MEETING_STATE_UPDATE"] = "meeting.state-update";
|
|
17
|
+
MeetingEvent["MEETING_CONNECTION_STATUS_CHANGE"] = "meeting.connection-status-change";
|
|
18
|
+
MeetingEvent["MEETING_AVATAR_LIST_UPDATE"] = "meeting.avatar-list-update";
|
|
19
|
+
MeetingEvent["MY_PARTICIPANT_UPDATED"] = "my-participant.update";
|
|
20
|
+
MeetingEvent["MY_PARTICIPANT_LEFT"] = "my-participant.left";
|
|
21
|
+
MeetingEvent["MY_PARTICIPANT_JOINED"] = "my-participant.joined";
|
|
22
|
+
MeetingEvent["HEARTBEAT"] = "heartbeat";
|
|
23
|
+
MeetingEvent["DESTROY"] = "destroy";
|
|
24
|
+
})(MeetingEvent || (MeetingEvent = {}));
|
|
25
|
+
export var FrameEvent;
|
|
26
|
+
(function (FrameEvent) {
|
|
27
|
+
FrameEvent["FRAME_CONFIG"] = "frame.config";
|
|
28
|
+
FrameEvent["FRAME_LOAD"] = "frame.load";
|
|
29
|
+
FrameEvent["FRAME_SIZE_UPDATE"] = "frame.size-update";
|
|
30
|
+
FrameEvent["FRAME_DIMENSIONS_UPDATE"] = "frame.dimensions-update";
|
|
31
|
+
FrameEvent["FRAME_PARENT_SIZE_UPDATE"] = "frame.parent-window-size-update";
|
|
32
|
+
FrameEvent["FRAME_LOCALE_UPDATE"] = "frame.locales-update";
|
|
33
|
+
FrameEvent["FRAME_AVATAR_LIST_UPDATE"] = "frame.avatar-list-update";
|
|
34
|
+
})(FrameEvent || (FrameEvent = {}));
|
|
35
|
+
export var RealtimeEvent;
|
|
36
|
+
(function (RealtimeEvent) {
|
|
37
|
+
RealtimeEvent["REALTIME_JOIN"] = "realtime.join";
|
|
38
|
+
RealtimeEvent["REALTIME_PARTICIPANT_LIST_UPDATE"] = "realtime.participant-list-update";
|
|
39
|
+
RealtimeEvent["REALTIME_HOST_CHANGE"] = "realtime.host-change";
|
|
40
|
+
RealtimeEvent["REALTIME_GRID_MODE_CHANGE"] = "realtime.grid-mode-change";
|
|
41
|
+
RealtimeEvent["REALTIME_WAIT_FOR_HOST"] = "realtime.wait-for-host";
|
|
42
|
+
RealtimeEvent["REALTIME_AUTHENTICATION_FAILED"] = "realtime.authentication-failed";
|
|
43
|
+
RealtimeEvent["REALTIME_GO_TO_PARTICIPANT"] = "realtime.go-to-participant";
|
|
44
|
+
RealtimeEvent["REALTIME_GATHER"] = "realtime.gather";
|
|
45
|
+
RealtimeEvent["REALTIME_FOLLOW_PARTICIPANT"] = "realtime.follow-participant";
|
|
46
|
+
RealtimeEvent["REALTIME_SET_AVATAR"] = "realtime.set-avatar";
|
|
47
|
+
})(RealtimeEvent || (RealtimeEvent = {}));
|
|
48
|
+
export var MeetingControlsEvent;
|
|
49
|
+
(function (MeetingControlsEvent) {
|
|
50
|
+
MeetingControlsEvent["TOGGLE_MEETING_CHAT"] = "meeting-controls.toggle-chat";
|
|
51
|
+
MeetingControlsEvent["TOGGLE_MEETING_SETUP"] = "meeting-controls.toggle-setup";
|
|
52
|
+
MeetingControlsEvent["TOGGLE_MICROPHONE"] = "meeting-controls.toggle-microphone";
|
|
53
|
+
MeetingControlsEvent["TOGGLE_CAM"] = "meeting-controls.toggle-cam";
|
|
54
|
+
MeetingControlsEvent["TOGGLE_SCREENSHARE"] = "meeting-controls.toggle-screenshare";
|
|
55
|
+
MeetingControlsEvent["HANG_UP"] = "hang-up";
|
|
56
|
+
})(MeetingControlsEvent || (MeetingControlsEvent = {}));
|
|
57
|
+
export var MeetingState;
|
|
58
|
+
(function (MeetingState) {
|
|
59
|
+
MeetingState[MeetingState["MEETING_FAILED"] = -1] = "MEETING_FAILED";
|
|
60
|
+
MeetingState[MeetingState["MEETING_DISCONNECTED"] = 0] = "MEETING_DISCONNECTED";
|
|
61
|
+
MeetingState[MeetingState["MEETING_INITIALIZING"] = 1] = "MEETING_INITIALIZING";
|
|
62
|
+
MeetingState[MeetingState["MEETING_READY_TO_JOIN"] = 2] = "MEETING_READY_TO_JOIN";
|
|
63
|
+
MeetingState[MeetingState["MEETING_CONNECTING"] = 3] = "MEETING_CONNECTING";
|
|
64
|
+
MeetingState[MeetingState["MEETING_CONNECTED"] = 4] = "MEETING_CONNECTED";
|
|
65
|
+
MeetingState[MeetingState["MEETING_RECONNECT"] = 5] = "MEETING_RECONNECT";
|
|
66
|
+
MeetingState[MeetingState["FRAME_INITIALIZING"] = 6] = "FRAME_INITIALIZING";
|
|
67
|
+
MeetingState[MeetingState["FRAME_INITIALIZED"] = 7] = "FRAME_INITIALIZED";
|
|
68
|
+
MeetingState[MeetingState["FRAME_UNINITIALIZED"] = 8] = "FRAME_UNINITIALIZED";
|
|
69
|
+
})(MeetingState || (MeetingState = {}));
|
|
70
|
+
export var MeetingConnectionStatus;
|
|
71
|
+
(function (MeetingConnectionStatus) {
|
|
72
|
+
MeetingConnectionStatus[MeetingConnectionStatus["NOT_AVAILABLE"] = 0] = "NOT_AVAILABLE";
|
|
73
|
+
MeetingConnectionStatus[MeetingConnectionStatus["GOOD"] = 1] = "GOOD";
|
|
74
|
+
MeetingConnectionStatus[MeetingConnectionStatus["BAD"] = 2] = "BAD";
|
|
75
|
+
MeetingConnectionStatus[MeetingConnectionStatus["POOR"] = 3] = "POOR";
|
|
76
|
+
MeetingConnectionStatus[MeetingConnectionStatus["DISCONNECTED"] = 4] = "DISCONNECTED";
|
|
77
|
+
MeetingConnectionStatus[MeetingConnectionStatus["RECONNECTING"] = 5] = "RECONNECTING";
|
|
78
|
+
MeetingConnectionStatus[MeetingConnectionStatus["LOST_CONNECTION"] = 6] = "LOST_CONNECTION";
|
|
79
|
+
})(MeetingConnectionStatus || (MeetingConnectionStatus = {}));
|
|
80
|
+
export var DeviceEvent;
|
|
81
|
+
(function (DeviceEvent) {
|
|
82
|
+
DeviceEvent["NO_CAM"] = "devices.no-cam";
|
|
83
|
+
DeviceEvent["NO_DEVICES"] = "devices.no-devices";
|
|
84
|
+
DeviceEvent["DEVICES_BLOCKED"] = "devices.blocked";
|
|
85
|
+
DeviceEvent["DEVICES_CAM_BLOCKED"] = "devices.cam-blocked";
|
|
86
|
+
DeviceEvent["DEVICES_INITIALIZATION_ERROR"] = "devices.inititalization-error";
|
|
87
|
+
DeviceEvent["DEVICES_UNKNOWN_ERROR"] = "devices.unknown-error";
|
|
88
|
+
})(DeviceEvent || (DeviceEvent = {}));
|
|
89
|
+
export var IParticipantType;
|
|
90
|
+
(function (IParticipantType) {
|
|
91
|
+
IParticipantType["HOST"] = "host";
|
|
92
|
+
IParticipantType["GUEST"] = "guest";
|
|
93
|
+
IParticipantType["AUDIENCE"] = "audience";
|
|
94
|
+
})(IParticipantType || (IParticipantType = {}));
|
|
95
|
+
;
|