@defcomm/meetingsdk 0.2.4 → 0.2.5
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.d.mts +4 -16
- package/dist/index.d.ts +4 -16
- package/dist/index.js +181 -247
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +181 -247
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -259,6 +259,7 @@ interface SFUClientOptions {
|
|
|
259
259
|
onParticipantJoined?: (participant: ParticipantInfo) => void;
|
|
260
260
|
onParticipantLeft?: (participant: string | ParticipantInfo) => void;
|
|
261
261
|
onParticipantPresence?: (participantId: string, presence: string) => void;
|
|
262
|
+
onParticipantMediaState?: (participantId: string, audioMuted: boolean, videoMuted: boolean) => void;
|
|
262
263
|
onTrackPublished?: (track: TrackInfo) => void;
|
|
263
264
|
onTrackUnpublished?: (track: TrackInfo) => void;
|
|
264
265
|
onRemoteTrack?: (track: MediaStreamTrack, stream: MediaStream, metadata: TrackInfo) => void;
|
|
@@ -272,7 +273,6 @@ interface SFUClientOptions {
|
|
|
272
273
|
onScreenShareStarted?: (participantId: string, track?: TrackInfo) => void;
|
|
273
274
|
onScreenShareStopped?: (participantId: string, trackId?: string) => void;
|
|
274
275
|
onTrackStateChanged?: (track: TrackInfo) => void;
|
|
275
|
-
onParticipantMediaState?: (participantId: string, audioMuted: boolean, videoMuted: boolean) => void;
|
|
276
276
|
onRecordingStarted?: (recording: {
|
|
277
277
|
recording_id: string;
|
|
278
278
|
started_at: string;
|
|
@@ -281,8 +281,6 @@ interface SFUClientOptions {
|
|
|
281
281
|
recording_id: string;
|
|
282
282
|
stopped_at: string;
|
|
283
283
|
}) => void;
|
|
284
|
-
/** Authoritative room snapshot received after join/reconnect/resync. */
|
|
285
|
-
onRoomState?: (state: any) => void;
|
|
286
284
|
onError?: (error: any) => void;
|
|
287
285
|
autoSubscribe?: boolean;
|
|
288
286
|
}
|
|
@@ -296,9 +294,6 @@ declare class SFUClient {
|
|
|
296
294
|
private localStream;
|
|
297
295
|
private screenStream;
|
|
298
296
|
private videoSender;
|
|
299
|
-
private audioMuted;
|
|
300
|
-
private videoMuted;
|
|
301
|
-
private activeRecording;
|
|
302
297
|
private audioSender;
|
|
303
298
|
private screenSender;
|
|
304
299
|
private audioTransceiver;
|
|
@@ -339,12 +334,11 @@ declare class SFUClient {
|
|
|
339
334
|
private trackToSource;
|
|
340
335
|
private localTrackIds;
|
|
341
336
|
private subscriberStatsTimer;
|
|
342
|
-
private roomSyncTimer;
|
|
343
|
-
private roomSyncInFlight;
|
|
344
337
|
private onStateChange;
|
|
345
338
|
private onParticipantJoined;
|
|
346
339
|
private onParticipantLeft;
|
|
347
340
|
private onParticipantPresence;
|
|
341
|
+
private onParticipantMediaState;
|
|
348
342
|
private onTrackPublished;
|
|
349
343
|
private onTrackUnpublished;
|
|
350
344
|
private onRemoteTrack;
|
|
@@ -358,19 +352,15 @@ declare class SFUClient {
|
|
|
358
352
|
private onScreenShareStarted;
|
|
359
353
|
private onScreenShareStopped;
|
|
360
354
|
private onTrackStateChanged;
|
|
361
|
-
private onParticipantMediaState;
|
|
362
355
|
private onRecordingStarted;
|
|
363
356
|
private onRecordingStopped;
|
|
364
|
-
private
|
|
357
|
+
private lastRecordingId;
|
|
365
358
|
private onError;
|
|
366
359
|
private autoSubscribe;
|
|
367
360
|
constructor(options?: SFUClientOptions);
|
|
368
361
|
private heartbeatTimer;
|
|
369
362
|
private startHeartbeat;
|
|
370
363
|
private stopHeartbeat;
|
|
371
|
-
private startRoomStateSync;
|
|
372
|
-
private stopRoomStateSync;
|
|
373
|
-
private syncRoomState;
|
|
374
364
|
private createId;
|
|
375
365
|
private resumeStorageKey;
|
|
376
366
|
private loadResumeToken;
|
|
@@ -407,7 +397,7 @@ declare class SFUClient {
|
|
|
407
397
|
private failJoin;
|
|
408
398
|
private resolveJoin;
|
|
409
399
|
private handleServerMessage;
|
|
410
|
-
private
|
|
400
|
+
private reconcileRoomState;
|
|
411
401
|
private rememberTrack;
|
|
412
402
|
private handleJoined;
|
|
413
403
|
private initializePeerConnections;
|
|
@@ -485,7 +475,6 @@ type MeetingContextValue = {
|
|
|
485
475
|
onEntryRequested: (cb: (req: any) => void) => () => void;
|
|
486
476
|
onEntryResponded: (cb: (payload: any, decision?: any) => void) => () => void;
|
|
487
477
|
onMeetingLeft: (cb: () => void) => () => void;
|
|
488
|
-
onRoomUpdate: (cb: (data: any) => void) => () => void;
|
|
489
478
|
onTrackStateChanged: (cb: (track: any) => void) => () => void;
|
|
490
479
|
onRecordingStarted: (cb: (recording: Recording) => void) => () => void;
|
|
491
480
|
onRecordingStopped: (cb: (recording: any) => void) => () => void;
|
|
@@ -544,7 +533,6 @@ declare const useMeeting: (handlers?: {
|
|
|
544
533
|
onEntryRequested: (cb: (req: any) => void) => () => void;
|
|
545
534
|
onEntryResponded: (cb: (payload: any, decision?: any) => void) => () => void;
|
|
546
535
|
onMeetingLeft: (cb: () => void) => () => void;
|
|
547
|
-
onRoomUpdate: (cb: (data: any) => void) => () => void;
|
|
548
536
|
onTrackStateChanged: (cb: (track: any) => void) => () => void;
|
|
549
537
|
onRecordingStarted: (cb: (recording: Recording) => void) => () => void;
|
|
550
538
|
onRecordingStopped: (cb: (recording: any) => void) => () => void;
|
package/dist/index.d.ts
CHANGED
|
@@ -259,6 +259,7 @@ interface SFUClientOptions {
|
|
|
259
259
|
onParticipantJoined?: (participant: ParticipantInfo) => void;
|
|
260
260
|
onParticipantLeft?: (participant: string | ParticipantInfo) => void;
|
|
261
261
|
onParticipantPresence?: (participantId: string, presence: string) => void;
|
|
262
|
+
onParticipantMediaState?: (participantId: string, audioMuted: boolean, videoMuted: boolean) => void;
|
|
262
263
|
onTrackPublished?: (track: TrackInfo) => void;
|
|
263
264
|
onTrackUnpublished?: (track: TrackInfo) => void;
|
|
264
265
|
onRemoteTrack?: (track: MediaStreamTrack, stream: MediaStream, metadata: TrackInfo) => void;
|
|
@@ -272,7 +273,6 @@ interface SFUClientOptions {
|
|
|
272
273
|
onScreenShareStarted?: (participantId: string, track?: TrackInfo) => void;
|
|
273
274
|
onScreenShareStopped?: (participantId: string, trackId?: string) => void;
|
|
274
275
|
onTrackStateChanged?: (track: TrackInfo) => void;
|
|
275
|
-
onParticipantMediaState?: (participantId: string, audioMuted: boolean, videoMuted: boolean) => void;
|
|
276
276
|
onRecordingStarted?: (recording: {
|
|
277
277
|
recording_id: string;
|
|
278
278
|
started_at: string;
|
|
@@ -281,8 +281,6 @@ interface SFUClientOptions {
|
|
|
281
281
|
recording_id: string;
|
|
282
282
|
stopped_at: string;
|
|
283
283
|
}) => void;
|
|
284
|
-
/** Authoritative room snapshot received after join/reconnect/resync. */
|
|
285
|
-
onRoomState?: (state: any) => void;
|
|
286
284
|
onError?: (error: any) => void;
|
|
287
285
|
autoSubscribe?: boolean;
|
|
288
286
|
}
|
|
@@ -296,9 +294,6 @@ declare class SFUClient {
|
|
|
296
294
|
private localStream;
|
|
297
295
|
private screenStream;
|
|
298
296
|
private videoSender;
|
|
299
|
-
private audioMuted;
|
|
300
|
-
private videoMuted;
|
|
301
|
-
private activeRecording;
|
|
302
297
|
private audioSender;
|
|
303
298
|
private screenSender;
|
|
304
299
|
private audioTransceiver;
|
|
@@ -339,12 +334,11 @@ declare class SFUClient {
|
|
|
339
334
|
private trackToSource;
|
|
340
335
|
private localTrackIds;
|
|
341
336
|
private subscriberStatsTimer;
|
|
342
|
-
private roomSyncTimer;
|
|
343
|
-
private roomSyncInFlight;
|
|
344
337
|
private onStateChange;
|
|
345
338
|
private onParticipantJoined;
|
|
346
339
|
private onParticipantLeft;
|
|
347
340
|
private onParticipantPresence;
|
|
341
|
+
private onParticipantMediaState;
|
|
348
342
|
private onTrackPublished;
|
|
349
343
|
private onTrackUnpublished;
|
|
350
344
|
private onRemoteTrack;
|
|
@@ -358,19 +352,15 @@ declare class SFUClient {
|
|
|
358
352
|
private onScreenShareStarted;
|
|
359
353
|
private onScreenShareStopped;
|
|
360
354
|
private onTrackStateChanged;
|
|
361
|
-
private onParticipantMediaState;
|
|
362
355
|
private onRecordingStarted;
|
|
363
356
|
private onRecordingStopped;
|
|
364
|
-
private
|
|
357
|
+
private lastRecordingId;
|
|
365
358
|
private onError;
|
|
366
359
|
private autoSubscribe;
|
|
367
360
|
constructor(options?: SFUClientOptions);
|
|
368
361
|
private heartbeatTimer;
|
|
369
362
|
private startHeartbeat;
|
|
370
363
|
private stopHeartbeat;
|
|
371
|
-
private startRoomStateSync;
|
|
372
|
-
private stopRoomStateSync;
|
|
373
|
-
private syncRoomState;
|
|
374
364
|
private createId;
|
|
375
365
|
private resumeStorageKey;
|
|
376
366
|
private loadResumeToken;
|
|
@@ -407,7 +397,7 @@ declare class SFUClient {
|
|
|
407
397
|
private failJoin;
|
|
408
398
|
private resolveJoin;
|
|
409
399
|
private handleServerMessage;
|
|
410
|
-
private
|
|
400
|
+
private reconcileRoomState;
|
|
411
401
|
private rememberTrack;
|
|
412
402
|
private handleJoined;
|
|
413
403
|
private initializePeerConnections;
|
|
@@ -485,7 +475,6 @@ type MeetingContextValue = {
|
|
|
485
475
|
onEntryRequested: (cb: (req: any) => void) => () => void;
|
|
486
476
|
onEntryResponded: (cb: (payload: any, decision?: any) => void) => () => void;
|
|
487
477
|
onMeetingLeft: (cb: () => void) => () => void;
|
|
488
|
-
onRoomUpdate: (cb: (data: any) => void) => () => void;
|
|
489
478
|
onTrackStateChanged: (cb: (track: any) => void) => () => void;
|
|
490
479
|
onRecordingStarted: (cb: (recording: Recording) => void) => () => void;
|
|
491
480
|
onRecordingStopped: (cb: (recording: any) => void) => () => void;
|
|
@@ -544,7 +533,6 @@ declare const useMeeting: (handlers?: {
|
|
|
544
533
|
onEntryRequested: (cb: (req: any) => void) => () => void;
|
|
545
534
|
onEntryResponded: (cb: (payload: any, decision?: any) => void) => () => void;
|
|
546
535
|
onMeetingLeft: (cb: () => void) => () => void;
|
|
547
|
-
onRoomUpdate: (cb: (data: any) => void) => () => void;
|
|
548
536
|
onTrackStateChanged: (cb: (track: any) => void) => () => void;
|
|
549
537
|
onRecordingStarted: (cb: (recording: Recording) => void) => () => void;
|
|
550
538
|
onRecordingStopped: (cb: (recording: any) => void) => () => void;
|