@opentok/client 2.35.0-alpha.25 → 2.35.0-alpha.27

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.
@@ -122,6 +122,16 @@ declare namespace OT {
122
122
  };
123
123
 
124
124
  export type VideoContentHint = "text" | "detail" | "motion" | "";
125
+ export type ScalabilityMode =
126
+ | 'L1T1'
127
+ | 'L1T2'
128
+ | 'L1T3'
129
+ | 'L2T1'
130
+ | 'L2T2'
131
+ | 'L2T3'
132
+ | 'L3T1'
133
+ | 'L3T2'
134
+ | 'L3T3';
125
135
 
126
136
  export type BackgroundBlurFilter = {
127
137
  type: 'backgroundBlur';
@@ -460,6 +470,8 @@ declare namespace OT {
460
470
  setVideoSource(videoSourceId: string): Promise<undefined>;
461
471
  getVideoContentHint(): VideoContentHint;
462
472
  setVideoContentHint(hint: VideoContentHint): void;
473
+ setTargetScalabilityMode(scalabilityMode: ScalabilityMode): void;
474
+ getTargetScalabilityMode(): ScalabilityMode | undefined;
463
475
  getVideoSource(): {deviceId: string | null, type: string | null, track: MediaStreamTrack | null};
464
476
  setStyle<Style extends keyof PublisherStyle>(style: Style, value: PublisherStyle[Style]): void;
465
477
  setStyle(styles: Partial<PublisherStyle>): void;
@@ -586,11 +598,14 @@ declare namespace OT {
586
598
  connection?: Connection;
587
599
  sessionId: string;
588
600
 
589
- connect(token: string, callback: (error?: OTError) => void): void;
590
- disconnect(): void;
601
+ connect: {
602
+ (token: string, callback: (error?: OTError) => void): Session;
603
+ promise: (token: string) => Promise<Session>;
604
+ }
605
+ disconnect(): Promise<void>;
591
606
  disableForceMute(): Promise<void>;
592
- forceDisconnect(connection: Connection, callback: (error?: OTError) => void): void;
593
- forceUnpublish(stream: Stream, callback: (error?: OTError) => void): void;
607
+ forceDisconnect(connection: Connection, callback: (error?: OTError) => void): Promise<void>;
608
+ forceUnpublish(stream: Stream, callback: (error?: OTError) => void): Promise<void>;
594
609
  forceMuteStream(stream: Stream): Promise<void>;
595
610
  forceMuteAll(excludedStreams?: Stream[]): Promise<void>;
596
611
  getPublisherForStream(stream: Stream): Publisher | undefined;
@@ -603,7 +618,7 @@ declare namespace OT {
603
618
  signal(
604
619
  signal: { type?: string, data?: string, to?: Connection, retryAfterReconnect?: boolean },
605
620
  callback?: (error?: OTError) => void
606
- ): void;
621
+ ): Promise<void>;
607
622
 
608
623
  subscribe(
609
624
  stream: Stream,