livekit-client 1.9.1 → 1.9.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (106) hide show
  1. package/dist/livekit-client.esm.mjs +3338 -3037
  2. package/dist/livekit-client.esm.mjs.map +1 -1
  3. package/dist/livekit-client.umd.js +1 -1
  4. package/dist/livekit-client.umd.js.map +1 -1
  5. package/dist/src/api/SignalClient.d.ts +98 -97
  6. package/dist/src/api/SignalClient.d.ts.map +1 -1
  7. package/dist/src/connectionHelper/ConnectionCheck.d.ts +25 -24
  8. package/dist/src/connectionHelper/ConnectionCheck.d.ts.map +1 -1
  9. package/dist/src/connectionHelper/checks/Checker.d.ts +58 -58
  10. package/dist/src/connectionHelper/checks/publishAudio.d.ts +5 -5
  11. package/dist/src/connectionHelper/checks/publishVideo.d.ts +5 -5
  12. package/dist/src/connectionHelper/checks/reconnect.d.ts +5 -5
  13. package/dist/src/connectionHelper/checks/turn.d.ts +5 -5
  14. package/dist/src/connectionHelper/checks/webrtc.d.ts +5 -5
  15. package/dist/src/connectionHelper/checks/websocket.d.ts +5 -5
  16. package/dist/src/index.d.ts +34 -31
  17. package/dist/src/index.d.ts.map +1 -1
  18. package/dist/src/logger.d.ts +25 -25
  19. package/dist/src/options.d.ts +98 -98
  20. package/dist/src/proto/google/protobuf/timestamp.d.ts +145 -145
  21. package/dist/src/proto/livekit_models.d.ts +2300 -2300
  22. package/dist/src/proto/livekit_rtc.d.ts +14032 -14032
  23. package/dist/src/room/DefaultReconnectPolicy.d.ts +7 -7
  24. package/dist/src/room/DeviceManager.d.ts +8 -8
  25. package/dist/src/room/PCTransport.d.ts +37 -37
  26. package/dist/src/room/PCTransport.d.ts.map +1 -1
  27. package/dist/src/room/RTCEngine.d.ts +126 -120
  28. package/dist/src/room/RTCEngine.d.ts.map +1 -1
  29. package/dist/src/room/ReconnectPolicy.d.ts +23 -23
  30. package/dist/src/room/RegionUrlProvider.d.ts +13 -13
  31. package/dist/src/room/Room.d.ts +232 -229
  32. package/dist/src/room/Room.d.ts.map +1 -1
  33. package/dist/src/room/defaults.d.ts +7 -7
  34. package/dist/src/room/defaults.d.ts.map +1 -1
  35. package/dist/src/room/errors.d.ts +42 -42
  36. package/dist/src/room/events.d.ts +455 -455
  37. package/dist/src/room/participant/LocalParticipant.d.ts +170 -170
  38. package/dist/src/room/participant/LocalParticipant.d.ts.map +1 -1
  39. package/dist/src/room/participant/Participant.d.ts +93 -93
  40. package/dist/src/room/participant/ParticipantTrackPermission.d.ts +25 -25
  41. package/dist/src/room/participant/RemoteParticipant.d.ts +52 -51
  42. package/dist/src/room/participant/RemoteParticipant.d.ts.map +1 -1
  43. package/dist/src/room/participant/publishUtils.d.ts +19 -18
  44. package/dist/src/room/participant/publishUtils.d.ts.map +1 -1
  45. package/dist/src/room/stats.d.ts +66 -66
  46. package/dist/src/room/timers.d.ts +12 -12
  47. package/dist/src/room/track/LocalAudioTrack.d.ts +24 -24
  48. package/dist/src/room/track/LocalAudioTrack.d.ts.map +1 -1
  49. package/dist/src/room/track/LocalTrack.d.ts +43 -43
  50. package/dist/src/room/track/LocalTrackPublication.d.ts +37 -37
  51. package/dist/src/room/track/LocalVideoTrack.d.ts +53 -53
  52. package/dist/src/room/track/LocalVideoTrack.d.ts.map +1 -1
  53. package/dist/src/room/track/RemoteAudioTrack.d.ts +52 -52
  54. package/dist/src/room/track/RemoteAudioTrack.d.ts.map +1 -1
  55. package/dist/src/room/track/RemoteTrack.d.ts +14 -14
  56. package/dist/src/room/track/RemoteTrackPublication.d.ts +60 -60
  57. package/dist/src/room/track/RemoteVideoTrack.d.ts +52 -52
  58. package/dist/src/room/track/RemoteVideoTrack.d.ts.map +1 -1
  59. package/dist/src/room/track/Track.d.ts +124 -124
  60. package/dist/src/room/track/TrackPublication.d.ts +67 -67
  61. package/dist/src/room/track/create.d.ts +23 -23
  62. package/dist/src/room/track/create.d.ts.map +1 -1
  63. package/dist/src/room/track/options.d.ts +255 -247
  64. package/dist/src/room/track/options.d.ts.map +1 -1
  65. package/dist/src/room/track/types.d.ts +22 -22
  66. package/dist/src/room/track/utils.d.ts +13 -13
  67. package/dist/src/room/types.d.ts +25 -25
  68. package/dist/src/room/utils.d.ts +86 -85
  69. package/dist/src/room/utils.d.ts.map +1 -1
  70. package/dist/src/test/MockMediaStreamTrack.d.ts +25 -25
  71. package/dist/src/test/mocks.d.ts +10 -10
  72. package/dist/src/version.d.ts +2 -2
  73. package/dist/ts4.2/src/api/SignalClient.d.ts +1 -0
  74. package/dist/ts4.2/src/connectionHelper/ConnectionCheck.d.ts +2 -1
  75. package/dist/ts4.2/src/index.d.ts +8 -6
  76. package/dist/ts4.2/src/room/PCTransport.d.ts +1 -1
  77. package/dist/ts4.2/src/room/RTCEngine.d.ts +7 -1
  78. package/dist/ts4.2/src/room/Room.d.ts +3 -0
  79. package/dist/ts4.2/src/room/defaults.d.ts +1 -1
  80. package/dist/ts4.2/src/room/participant/LocalParticipant.d.ts +4 -4
  81. package/dist/ts4.2/src/room/participant/RemoteParticipant.d.ts +2 -1
  82. package/dist/ts4.2/src/room/participant/publishUtils.d.ts +2 -1
  83. package/dist/ts4.2/src/room/track/LocalAudioTrack.d.ts +1 -1
  84. package/dist/ts4.2/src/room/track/LocalVideoTrack.d.ts +1 -1
  85. package/dist/ts4.2/src/room/track/RemoteAudioTrack.d.ts +1 -1
  86. package/dist/ts4.2/src/room/track/create.d.ts +1 -1
  87. package/dist/ts4.2/src/room/track/options.d.ts +10 -2
  88. package/dist/ts4.2/src/room/utils.d.ts +1 -0
  89. package/package.json +12 -12
  90. package/src/api/SignalClient.ts +19 -16
  91. package/src/connectionHelper/ConnectionCheck.ts +2 -1
  92. package/src/index.ts +13 -8
  93. package/src/room/PCTransport.ts +9 -5
  94. package/src/room/RTCEngine.ts +44 -4
  95. package/src/room/Room.ts +87 -42
  96. package/src/room/defaults.ts +6 -4
  97. package/src/room/participant/LocalParticipant.ts +10 -9
  98. package/src/room/participant/RemoteParticipant.ts +2 -1
  99. package/src/room/participant/publishUtils.ts +7 -5
  100. package/src/room/track/LocalAudioTrack.ts +2 -1
  101. package/src/room/track/LocalVideoTrack.ts +3 -2
  102. package/src/room/track/RemoteAudioTrack.ts +2 -1
  103. package/src/room/track/RemoteVideoTrack.ts +4 -8
  104. package/src/room/track/create.ts +2 -2
  105. package/src/room/track/options.ts +23 -7
  106. package/src/room/utils.ts +15 -2
@@ -1,26 +1,26 @@
1
- import type RemoteParticipant from './participant/RemoteParticipant';
2
- export type SimulationOptions = {
3
- publish?: {
4
- audio?: boolean;
5
- video?: boolean;
6
- useRealTracks?: boolean;
7
- };
8
- participants?: {
9
- count?: number;
10
- aspectRatios?: Array<number>;
11
- audio?: boolean;
12
- video?: boolean;
13
- };
14
- };
15
- export type DataPublishOptions = {
16
- /** the participants who will receive the message, will be sent to every one if empty */
17
- destination?: RemoteParticipant[] | string[];
18
- /** the topic under which the message gets published */
19
- topic?: string;
20
- };
21
- export type LiveKitReactNativeInfo = {
22
- platform: 'ios' | 'android' | 'windows' | 'macos' | 'web' | 'native';
23
- devicePixelRatio: number;
24
- };
25
- export type SimulationScenario = 'signal-reconnect' | 'speaker' | 'node-failure' | 'server-leave' | 'migration' | 'resume-reconnect' | 'force-tcp' | 'force-tls' | 'full-reconnect';
1
+ import type RemoteParticipant from './participant/RemoteParticipant';
2
+ export type SimulationOptions = {
3
+ publish?: {
4
+ audio?: boolean;
5
+ video?: boolean;
6
+ useRealTracks?: boolean;
7
+ };
8
+ participants?: {
9
+ count?: number;
10
+ aspectRatios?: Array<number>;
11
+ audio?: boolean;
12
+ video?: boolean;
13
+ };
14
+ };
15
+ export type DataPublishOptions = {
16
+ /** the participants who will receive the message, will be sent to every one if empty */
17
+ destination?: RemoteParticipant[] | string[];
18
+ /** the topic under which the message gets published */
19
+ topic?: string;
20
+ };
21
+ export type LiveKitReactNativeInfo = {
22
+ platform: 'ios' | 'android' | 'windows' | 'macos' | 'web' | 'native';
23
+ devicePixelRatio: number;
24
+ };
25
+ export type SimulationScenario = 'signal-reconnect' | 'speaker' | 'node-failure' | 'server-leave' | 'migration' | 'resume-reconnect' | 'force-tcp' | 'force-tls' | 'full-reconnect';
26
26
  //# sourceMappingURL=types.d.ts.map
@@ -1,86 +1,87 @@
1
- import { ClientInfo } from '../proto/livekit_models';
2
- import type LocalAudioTrack from './track/LocalAudioTrack';
3
- import type RemoteAudioTrack from './track/RemoteAudioTrack';
4
- export declare const ddExtensionURI = "https://aomediacodec.github.io/av1-rtp-spec/#dependency-descriptor-rtp-header-extension";
5
- export declare function unpackStreamId(packed: string): string[];
6
- export declare function sleep(duration: number): Promise<void>;
7
- /** @internal */
8
- export declare function supportsTransceiver(): boolean;
9
- /** @internal */
10
- export declare function supportsAddTrack(): boolean;
11
- export declare function supportsAdaptiveStream(): boolean;
12
- export declare function supportsDynacast(): boolean;
13
- export declare function supportsAV1(): boolean;
14
- export declare function supportsVP9(): boolean;
15
- export declare function isSVCCodec(codec?: string): boolean;
16
- export declare function supportsSetSinkId(elm?: HTMLMediaElement): boolean;
17
- export declare function supportsSetCodecPreferences(transceiver: RTCRtpTransceiver): boolean;
18
- export declare function isBrowserSupported(): boolean;
19
- export declare function isFireFox(): boolean;
20
- export declare function isSafari(): boolean;
21
- export declare function isMobile(): boolean;
22
- export declare function isWeb(): boolean;
23
- export declare function isReactNative(): boolean;
24
- export declare function isCloud(serverUrl: URL): boolean;
25
- export declare function getReactNativeOs(): string | undefined;
26
- export declare function getDevicePixelRatio(): number;
27
- export declare function compareVersions(v1: string, v2: string): number;
28
- export declare const getResizeObserver: () => ResizeObserver;
29
- export declare const getIntersectionObserver: () => IntersectionObserver;
30
- export interface ObservableMediaElement extends HTMLMediaElement {
31
- handleResize: (entry: ResizeObserverEntry) => void;
32
- handleVisibilityChanged: (entry: IntersectionObserverEntry) => void;
33
- }
34
- export declare function getClientInfo(): ClientInfo;
35
- export declare function getEmptyVideoStreamTrack(): MediaStreamTrack;
36
- export declare function createDummyVideoStreamTrack(width?: number, height?: number, enabled?: boolean, paintContent?: boolean): MediaStreamTrack;
37
- export declare function getEmptyAudioStreamTrack(): MediaStreamTrack;
38
- export declare class Future<T> {
39
- promise: Promise<T>;
40
- resolve?: (arg: T) => void;
41
- reject?: (e: any) => void;
42
- onFinally?: () => void;
43
- constructor(futureBase?: (resolve: (arg: T) => void, reject: (e: any) => void) => void, onFinally?: () => void);
44
- }
45
- export type AudioAnalyserOptions = {
46
- /**
47
- * If set to true, the analyser will use a cloned version of the underlying mediastreamtrack, which won't be impacted by muting the track.
48
- * Useful for local tracks when implementing things like "seems like you're muted, but trying to speak".
49
- * Defaults to false
50
- */
51
- cloneTrack?: boolean;
52
- /**
53
- * see https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/fftSize
54
- */
55
- fftSize?: number;
56
- /**
57
- * see https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/smoothingTimeConstant
58
- */
59
- smoothingTimeConstant?: number;
60
- /**
61
- * see https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/minDecibels
62
- */
63
- minDecibels?: number;
64
- /**
65
- * see https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/maxDecibels
66
- */
67
- maxDecibels?: number;
68
- };
69
- /**
70
- * Creates and returns an analyser web audio node that is attached to the provided track.
71
- * Additionally returns a convenience method `calculateVolume` to perform instant volume readings on that track.
72
- * Call the returned `cleanup` function to close the audioContext that has been created for the instance of this helper
73
- */
74
- export declare function createAudioAnalyser(track: LocalAudioTrack | RemoteAudioTrack, options?: AudioAnalyserOptions): {
75
- calculateVolume: () => number;
76
- analyser: AnalyserNode;
77
- cleanup: () => void;
78
- };
79
- export declare class Mutex {
80
- private _locking;
81
- private _locks;
82
- constructor();
83
- isLocked(): boolean;
84
- lock(): Promise<() => void>;
85
- }
1
+ import { ClientInfo } from '../proto/livekit_models';
2
+ import type LocalAudioTrack from './track/LocalAudioTrack';
3
+ import type RemoteAudioTrack from './track/RemoteAudioTrack';
4
+ export declare const ddExtensionURI = "https://aomediacodec.github.io/av1-rtp-spec/#dependency-descriptor-rtp-header-extension";
5
+ export declare function unpackStreamId(packed: string): string[];
6
+ export declare function sleep(duration: number): Promise<void>;
7
+ /** @internal */
8
+ export declare function supportsTransceiver(): boolean;
9
+ /** @internal */
10
+ export declare function supportsAddTrack(): boolean;
11
+ export declare function supportsAdaptiveStream(): boolean;
12
+ export declare function supportsDynacast(): boolean;
13
+ export declare function supportsAV1(): boolean;
14
+ export declare function supportsVP9(): boolean;
15
+ export declare function isSVCCodec(codec?: string): boolean;
16
+ export declare function supportsSetSinkId(elm?: HTMLMediaElement): boolean;
17
+ export declare function supportsSetCodecPreferences(transceiver: RTCRtpTransceiver): boolean;
18
+ export declare function isBrowserSupported(): boolean;
19
+ export declare function isFireFox(): boolean;
20
+ export declare function isChromiumBased(): boolean;
21
+ export declare function isSafari(): boolean;
22
+ export declare function isMobile(): boolean;
23
+ export declare function isWeb(): boolean;
24
+ export declare function isReactNative(): boolean;
25
+ export declare function isCloud(serverUrl: URL): boolean;
26
+ export declare function getReactNativeOs(): string | undefined;
27
+ export declare function getDevicePixelRatio(): number;
28
+ export declare function compareVersions(v1: string, v2: string): number;
29
+ export declare const getResizeObserver: () => ResizeObserver;
30
+ export declare const getIntersectionObserver: () => IntersectionObserver;
31
+ export interface ObservableMediaElement extends HTMLMediaElement {
32
+ handleResize: (entry: ResizeObserverEntry) => void;
33
+ handleVisibilityChanged: (entry: IntersectionObserverEntry) => void;
34
+ }
35
+ export declare function getClientInfo(): ClientInfo;
36
+ export declare function getEmptyVideoStreamTrack(): MediaStreamTrack;
37
+ export declare function createDummyVideoStreamTrack(width?: number, height?: number, enabled?: boolean, paintContent?: boolean): MediaStreamTrack;
38
+ export declare function getEmptyAudioStreamTrack(): MediaStreamTrack;
39
+ export declare class Future<T> {
40
+ promise: Promise<T>;
41
+ resolve?: (arg: T) => void;
42
+ reject?: (e: any) => void;
43
+ onFinally?: () => void;
44
+ constructor(futureBase?: (resolve: (arg: T) => void, reject: (e: any) => void) => void, onFinally?: () => void);
45
+ }
46
+ export type AudioAnalyserOptions = {
47
+ /**
48
+ * If set to true, the analyser will use a cloned version of the underlying mediastreamtrack, which won't be impacted by muting the track.
49
+ * Useful for local tracks when implementing things like "seems like you're muted, but trying to speak".
50
+ * Defaults to false
51
+ */
52
+ cloneTrack?: boolean;
53
+ /**
54
+ * see https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/fftSize
55
+ */
56
+ fftSize?: number;
57
+ /**
58
+ * see https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/smoothingTimeConstant
59
+ */
60
+ smoothingTimeConstant?: number;
61
+ /**
62
+ * see https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/minDecibels
63
+ */
64
+ minDecibels?: number;
65
+ /**
66
+ * see https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/maxDecibels
67
+ */
68
+ maxDecibels?: number;
69
+ };
70
+ /**
71
+ * Creates and returns an analyser web audio node that is attached to the provided track.
72
+ * Additionally returns a convenience method `calculateVolume` to perform instant volume readings on that track.
73
+ * Call the returned `cleanup` function to close the audioContext that has been created for the instance of this helper
74
+ */
75
+ export declare function createAudioAnalyser(track: LocalAudioTrack | RemoteAudioTrack, options?: AudioAnalyserOptions): {
76
+ calculateVolume: () => number;
77
+ analyser: AnalyserNode;
78
+ cleanup: () => void;
79
+ };
80
+ export declare class Mutex {
81
+ private _locking;
82
+ private _locks;
83
+ constructor();
84
+ isLocked(): boolean;
85
+ lock(): Promise<() => void>;
86
+ }
86
87
  //# sourceMappingURL=utils.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/room/utils.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAkB,MAAM,yBAAyB,CAAC;AAErE,OAAO,KAAK,eAAe,MAAM,yBAAyB,CAAC;AAC3D,OAAO,KAAK,gBAAgB,MAAM,0BAA0B,CAAC;AAK7D,eAAO,MAAM,cAAc,4FACgE,CAAC;AAE5F,wBAAgB,cAAc,CAAC,MAAM,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;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF;;;;GAIG;AACH,wBAAgB,mBAAmB,CACjC,KAAK,EAAE,eAAe,GAAG,gBAAgB,EACzC,OAAO,CAAC,EAAE,oBAAoB;;;;EA+C/B;AAED,qBAAa,KAAK;IAChB,OAAO,CAAC,QAAQ,CAAgB;IAEhC,OAAO,CAAC,MAAM,CAAS;;IAOvB,QAAQ;IAIR,IAAI,kBAGoB,IAAI;CAgB7B"}
@@ -1,26 +1,26 @@
1
- export default class MockMediaStreamTrack implements MediaStreamTrack {
2
- contentHint: string;
3
- enabled: boolean;
4
- id: string;
5
- kind: string;
6
- label: string;
7
- muted: boolean;
8
- onended: ((this: MediaStreamTrack, ev: Event) => any) | null;
9
- onmute: ((this: MediaStreamTrack, ev: Event) => any) | null;
10
- onunmute: ((this: MediaStreamTrack, ev: Event) => any) | null;
11
- readyState: MediaStreamTrackState;
12
- isolated: boolean;
13
- onisolationchange: ((this: MediaStreamTrack, ev: Event) => any) | null;
14
- applyConstraints(constraints?: MediaTrackConstraints): Promise<void>;
15
- clone(): MediaStreamTrack;
16
- getCapabilities(): MediaTrackCapabilities;
17
- getConstraints(): MediaTrackConstraints;
18
- getSettings(): MediaTrackSettings;
19
- stop(): void;
20
- addEventListener<K extends keyof MediaStreamTrackEventMap>(type: K, listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
21
- addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
22
- removeEventListener<K extends keyof MediaStreamTrackEventMap>(type: K, listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
23
- removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
24
- dispatchEvent(event: Event): boolean;
25
- }
1
+ export default class MockMediaStreamTrack implements MediaStreamTrack {
2
+ contentHint: string;
3
+ enabled: boolean;
4
+ id: string;
5
+ kind: string;
6
+ label: string;
7
+ muted: boolean;
8
+ onended: ((this: MediaStreamTrack, ev: Event) => any) | null;
9
+ onmute: ((this: MediaStreamTrack, ev: Event) => any) | null;
10
+ onunmute: ((this: MediaStreamTrack, ev: Event) => any) | null;
11
+ readyState: MediaStreamTrackState;
12
+ isolated: boolean;
13
+ onisolationchange: ((this: MediaStreamTrack, ev: Event) => any) | null;
14
+ applyConstraints(constraints?: MediaTrackConstraints): Promise<void>;
15
+ clone(): MediaStreamTrack;
16
+ getCapabilities(): MediaTrackCapabilities;
17
+ getConstraints(): MediaTrackConstraints;
18
+ getSettings(): MediaTrackSettings;
19
+ stop(): void;
20
+ addEventListener<K extends keyof MediaStreamTrackEventMap>(type: K, listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
21
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
22
+ removeEventListener<K extends keyof MediaStreamTrackEventMap>(type: K, listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
23
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
24
+ dispatchEvent(event: Event): boolean;
25
+ }
26
26
  //# sourceMappingURL=MockMediaStreamTrack.d.ts.map
@@ -1,11 +1,11 @@
1
- import { SignalClient } from '../api/SignalClient';
2
- import RTCEngine from '../room/RTCEngine';
3
- declare const mocks: {
4
- SignalClient: jest.MockedClass<typeof SignalClient>;
5
- RTCEngine: jest.MockedClass<typeof RTCEngine>;
6
- MockLocalVideoTrack: {
7
- stop: jest.Mock<any, any, any>;
8
- };
9
- };
10
- export default mocks;
1
+ import { SignalClient } from '../api/SignalClient';
2
+ import RTCEngine from '../room/RTCEngine';
3
+ declare const mocks: {
4
+ SignalClient: jest.MockedClass<typeof SignalClient>;
5
+ RTCEngine: jest.MockedClass<typeof RTCEngine>;
6
+ MockLocalVideoTrack: {
7
+ stop: jest.Mock<any, any, any>;
8
+ };
9
+ };
10
+ export default mocks;
11
11
  //# sourceMappingURL=mocks.d.ts.map
@@ -1,3 +1,3 @@
1
- export declare const version: string;
2
- export declare const protocolVersion = 9;
1
+ export declare const version: string;
2
+ export declare const protocolVersion = 9;
3
3
  //# sourceMappingURL=version.d.ts.map
@@ -83,6 +83,7 @@ export declare class SignalClient {
83
83
  sendRequest(message: SignalMessage, fromQueue?: boolean): Promise<void>;
84
84
  private handleSignalResponse;
85
85
  setReconnected(): void;
86
+ private handleOnClose;
86
87
  private handleWSError;
87
88
  /**
88
89
  * Resets the ping timeout and starts a new timeout.
@@ -1,5 +1,6 @@
1
1
  import type TypedEmitter from 'typed-emitter';
2
- import { CheckInfo, CheckStatus, Checker, InstantiableCheck } from './checks/Checker';
2
+ import { CheckStatus, Checker } from './checks/Checker';
3
+ import type { CheckInfo, InstantiableCheck } from './checks/Checker';
3
4
  export type { CheckInfo, CheckStatus };
4
5
  declare const ConnectionCheck_base: new () => TypedEmitter<ConnectionCheckCallbacks>;
5
6
  export declare class ConnectionCheck extends ConnectionCheck_base {
@@ -14,20 +14,22 @@ import LocalVideoTrack from './room/track/LocalVideoTrack';
14
14
  import RemoteAudioTrack from './room/track/RemoteAudioTrack';
15
15
  import RemoteTrack from './room/track/RemoteTrack';
16
16
  import RemoteTrackPublication from './room/track/RemoteTrackPublication';
17
- import type RemoteVideoTrack, { ElementInfo } from './room/track/RemoteVideoTrack';
17
+ import type { ElementInfo } from './room/track/RemoteVideoTrack';
18
+ import RemoteVideoTrack from './room/track/RemoteVideoTrack';
18
19
  import { TrackPublication } from './room/track/TrackPublication';
19
20
  import type { LiveKitReactNativeInfo } from './room/types';
20
21
  import type { AudioAnalyserOptions } from './room/utils';
21
- import { createAudioAnalyser, getEmptyAudioStreamTrack, getEmptyVideoStreamTrack, isBrowserSupported, supportsAV1, supportsAdaptiveStream, supportsDynacast } from './room/utils';
22
+ import { createAudioAnalyser, getEmptyAudioStreamTrack, getEmptyVideoStreamTrack, isBrowserSupported, supportsAV1, supportsAdaptiveStream, supportsDynacast, supportsVP9 } from './room/utils';
23
+ export * from './connectionHelper/ConnectionCheck';
22
24
  export * from './options';
23
25
  export * from './room/errors';
24
26
  export * from './room/events';
25
- export type { DataPublishOptions, SimulationScenario } from './room/types';
27
+ export * from './room/track/Track';
26
28
  export * from './room/track/create';
27
29
  export * from './room/track/options';
28
- export * from './room/track/Track';
29
30
  export * from './room/track/types';
31
+ export type { DataPublishOptions, SimulationScenario } from './room/types';
30
32
  export * from './version';
31
- export * from './connectionHelper/ConnectionCheck';
32
- export { setLogLevel, setLogExtension, getEmptyAudioStreamTrack, getEmptyVideoStreamTrack, isBrowserSupported, supportsAdaptiveStream, supportsDynacast, supportsAV1, createAudioAnalyser, AudioAnalyserOptions, LogLevel, Room, ConnectionState, RoomState, DataPacket_Kind, DisconnectReason, Participant, RemoteParticipant, LocalParticipant, LocalAudioTrack, LocalVideoTrack, LocalTrack, LocalTrackPublication, RemoteTrack, RemoteAudioTrack, RemoteVideoTrack, RemoteTrackPublication, ParticipantTrackPermission, TrackPublication, VideoQuality, ConnectionQuality, ElementInfo, DefaultReconnectPolicy, CriticalTimers, LiveKitReactNativeInfo, };
33
+ export { setLogLevel, setLogExtension, getEmptyAudioStreamTrack, getEmptyVideoStreamTrack, isBrowserSupported, supportsAdaptiveStream, supportsDynacast, supportsAV1, supportsVP9, createAudioAnalyser, LogLevel, Room, ConnectionState, RoomState, DataPacket_Kind, DisconnectReason, Participant, RemoteParticipant, LocalParticipant, LocalAudioTrack, LocalVideoTrack, LocalTrack, LocalTrackPublication, RemoteTrack, RemoteAudioTrack, RemoteVideoTrack, RemoteTrackPublication, TrackPublication, VideoQuality, ConnectionQuality, DefaultReconnectPolicy, CriticalTimers, };
34
+ export type { ElementInfo, ParticipantTrackPermission, AudioAnalyserOptions, LiveKitReactNativeInfo, };
33
35
  //# sourceMappingURL=index.d.ts.map
@@ -20,7 +20,7 @@ export default class PCTransport extends EventEmitter {
20
20
  remoteStereoMids: string[];
21
21
  remoteNackMids: string[];
22
22
  onOffer?: (offer: RTCSessionDescriptionInit) => void;
23
- constructor(config?: RTCConfiguration);
23
+ constructor(config?: RTCConfiguration, mediaConstraints?: Record<string, unknown>);
24
24
  get isICEConnected(): boolean;
25
25
  addIceCandidate(candidate: RTCIceCandidateInit): Promise<void>;
26
26
  setRemoteDescription(sd: RTCSessionDescriptionInit): Promise<void>;
@@ -1,5 +1,6 @@
1
1
  import type TypedEventEmitter from 'typed-emitter';
2
- import { SignalClient, SignalOptions } from '../api/SignalClient';
2
+ import { SignalClient } from '../api/SignalClient';
3
+ import type { SignalOptions } from '../api/SignalClient';
3
4
  import type { InternalRoomOptions } from '../options';
4
5
  import { DataPacket, DataPacket_Kind, DisconnectReason, SpeakerInfo, TrackInfo, UserPacket } from '../proto/livekit_models';
5
6
  import { AddTrackRequest, JoinResponse } from '../proto/livekit_rtc';
@@ -18,6 +19,10 @@ export default class RTCEngine extends RTCEngine_base {
18
19
  rtcConfig: RTCConfiguration;
19
20
  peerConnectionTimeout: number;
20
21
  fullReconnectOnNext: boolean;
22
+ /**
23
+ * @internal
24
+ */
25
+ latestJoinResponse?: JoinResponse;
21
26
  get isClosed(): boolean;
22
27
  private lossyDC?;
23
28
  private lossyDCSub?;
@@ -91,6 +96,7 @@ export default class RTCEngine extends RTCEngine_base {
91
96
  */
92
97
  ensureDataTransportConnected(kind: DataPacket_Kind, subscriber?: boolean): Promise<void>;
93
98
  private ensurePublisherConnected;
99
+ verifyTransport(): boolean;
94
100
  /** @internal */
95
101
  negotiate(): Promise<void>;
96
102
  dataChannelForKind(kind: DataPacket_Kind, sub?: boolean): RTCDataChannel | undefined;
@@ -56,6 +56,7 @@ declare class Room extends Room_base {
56
56
  private connectFuture?;
57
57
  private disconnectLock;
58
58
  private cachedParticipantSids;
59
+ private connectionReconcileInterval?;
59
60
  /**
60
61
  * Creates a new Room, the primary construct for a LiveKit session.
61
62
  * @param options
@@ -170,6 +171,8 @@ declare class Room extends Room_base {
170
171
  * subscription settings.
171
172
  */
172
173
  private updateSubscriptions;
174
+ private registerConnectionReconcile;
175
+ private clearConnectionReconcile;
173
176
  private setAndEmitConnectionState;
174
177
  private emitWhenConnected;
175
178
  private onLocalParticipantMetadataChanged;
@@ -1,5 +1,5 @@
1
1
  import type { InternalRoomConnectOptions, InternalRoomOptions } from '../options';
2
- import { AudioCaptureOptions, TrackPublishDefaults, VideoCaptureOptions } from './track/options';
2
+ import type { AudioCaptureOptions, TrackPublishDefaults, VideoCaptureOptions } from './track/options';
3
3
  export declare const publishDefaults: TrackPublishDefaults;
4
4
  export declare const audioDefaults: AudioCaptureOptions;
5
5
  export declare const videoDefaults: VideoCaptureOptions;
@@ -6,10 +6,10 @@ import type RTCEngine from '../RTCEngine';
6
6
  import LocalTrack from '../track/LocalTrack';
7
7
  import LocalTrackPublication from '../track/LocalTrackPublication';
8
8
  import { Track } from '../track/Track';
9
- import { AudioCaptureOptions, BackupVideoCodec, CreateLocalTracksOptions, ScreenShareCaptureOptions, TrackPublishOptions, VideoCaptureOptions } from '../track/options';
9
+ import type { AudioCaptureOptions, BackupVideoCodec, CreateLocalTracksOptions, ScreenShareCaptureOptions, TrackPublishOptions, VideoCaptureOptions } from '../track/options';
10
10
  import type { DataPublishOptions } from '../types';
11
11
  import Participant from './Participant';
12
- import { ParticipantTrackPermission } from './ParticipantTrackPermission';
12
+ import type { ParticipantTrackPermission } from './ParticipantTrackPermission';
13
13
  import RemoteParticipant from './RemoteParticipant';
14
14
  export default class LocalParticipant extends Participant {
15
15
  audioTracks: Map<string, LocalTrackPublication>;
@@ -41,13 +41,13 @@ export default class LocalParticipant extends Participant {
41
41
  private handleDisconnected;
42
42
  /**
43
43
  * Sets and updates the metadata of the local participant.
44
- * Note: this requires `CanUpdateOwnMetadata` permission encoded in the token.
44
+ * Note: this requires `canUpdateOwnMetadata` permission encoded in the token.
45
45
  * @param metadata
46
46
  */
47
47
  setMetadata(metadata: string): void;
48
48
  /**
49
49
  * Sets and updates the name of the local participant.
50
- * Note: this requires `CanUpdateOwnMetadata` permission encoded in the token.
50
+ * Note: this requires `canUpdateOwnMetadata` permission encoded in the token.
51
51
  * @param metadata
52
52
  */
53
53
  setName(name: string): void;
@@ -4,7 +4,8 @@ import RemoteTrackPublication from '../track/RemoteTrackPublication';
4
4
  import { Track } from '../track/Track';
5
5
  import type { AudioOutputOptions } from '../track/options';
6
6
  import type { AdaptiveStreamSettings } from '../track/types';
7
- import Participant, { ParticipantEventCallbacks } from './Participant';
7
+ import Participant from './Participant';
8
+ import type { ParticipantEventCallbacks } from './Participant';
8
9
  export default class RemoteParticipant extends Participant {
9
10
  audioTracks: Map<string, RemoteTrackPublication>;
10
11
  videoTracks: Map<string, RemoteTrackPublication>;
@@ -1,6 +1,7 @@
1
1
  import LocalAudioTrack from '../track/LocalAudioTrack';
2
2
  import LocalVideoTrack from '../track/LocalVideoTrack';
3
- import { BackupVideoCodec, TrackPublishOptions, VideoCodec, VideoEncoding, VideoPreset } from '../track/options';
3
+ import { VideoPreset } from '../track/options';
4
+ import type { BackupVideoCodec, TrackPublishOptions, VideoCodec, VideoEncoding } from '../track/options';
4
5
  /** @internal */
5
6
  export declare function mediaTrackToLocalTrack(mediaStreamTrack: MediaStreamTrack, constraints?: MediaTrackConstraints): LocalVideoTrack | LocalAudioTrack;
6
7
  export declare const presets169: VideoPreset[];
@@ -1,4 +1,4 @@
1
- import { AudioSenderStats } from '../stats';
1
+ import type { AudioSenderStats } from '../stats';
2
2
  import LocalTrack from './LocalTrack';
3
3
  import type { AudioCaptureOptions } from './options';
4
4
  export default class LocalAudioTrack extends LocalTrack {
@@ -1,7 +1,7 @@
1
1
  import type { SignalClient } from '../../api/SignalClient';
2
2
  import { VideoLayer, VideoQuality } from '../../proto/livekit_models';
3
3
  import type { SubscribedCodec, SubscribedQuality } from '../../proto/livekit_rtc';
4
- import { VideoSenderStats } from '../stats';
4
+ import type { VideoSenderStats } from '../stats';
5
5
  import LocalTrack from './LocalTrack';
6
6
  import type { VideoCaptureOptions, VideoCodec } from './options';
7
7
  export declare class SimulcastTrackInfo {
@@ -1,4 +1,4 @@
1
- import { AudioReceiverStats } from '../stats';
1
+ import type { AudioReceiverStats } from '../stats';
2
2
  import RemoteTrack from './RemoteTrack';
3
3
  import type { AudioOutputOptions } from './options';
4
4
  export default class RemoteAudioTrack extends RemoteTrack {
@@ -1,7 +1,7 @@
1
1
  import LocalAudioTrack from './LocalAudioTrack';
2
2
  import type LocalTrack from './LocalTrack';
3
3
  import LocalVideoTrack from './LocalVideoTrack';
4
- import { AudioCaptureOptions, CreateLocalTracksOptions, ScreenShareCaptureOptions, VideoCaptureOptions } from './options';
4
+ import type { AudioCaptureOptions, CreateLocalTracksOptions, ScreenShareCaptureOptions, VideoCaptureOptions } from './options';
5
5
  /**
6
6
  * Creates a local video and audio track at the same time. When acquiring both
7
7
  * audio and video tracks together, it'll display a single permission prompt to
@@ -21,9 +21,15 @@ export interface TrackPublishDefaults {
21
21
  */
22
22
  videoCodec?: VideoCodec;
23
23
  /**
24
- * max audio bitrate, defaults to [[AudioPresets.speech]]
24
+ * max audio bitrate, defaults to [[AudioPresets.music]]
25
+ * @deprecated use `audioPreset` instead
25
26
  */
26
27
  audioBitrate?: number;
28
+ /**
29
+ * which audio preset should be used for publishing (audio) tracks
30
+ * defaults to [[AudioPresets.music]]
31
+ */
32
+ audioPreset?: AudioPreset;
27
33
  /**
28
34
  * dtx (Discontinuous Transmission of audio), enabled by default for mono tracks.
29
35
  */
@@ -180,16 +186,18 @@ export interface VideoResolution {
180
186
  export interface VideoEncoding {
181
187
  maxBitrate: number;
182
188
  maxFramerate?: number;
189
+ priority?: RTCPriorityType;
183
190
  }
184
191
  export declare class VideoPreset {
185
192
  encoding: VideoEncoding;
186
193
  width: number;
187
194
  height: number;
188
- constructor(width: number, height: number, maxBitrate: number, maxFramerate?: number);
195
+ constructor(width: number, height: number, maxBitrate: number, maxFramerate?: number, priority?: RTCPriorityType);
189
196
  get resolution(): VideoResolution;
190
197
  }
191
198
  export interface AudioPreset {
192
199
  maxBitrate: number;
200
+ priority?: RTCPriorityType;
193
201
  }
194
202
  declare const codecs: readonly [
195
203
  "vp8",
@@ -17,6 +17,7 @@ export declare function supportsSetSinkId(elm?: HTMLMediaElement): boolean;
17
17
  export declare function supportsSetCodecPreferences(transceiver: RTCRtpTransceiver): boolean;
18
18
  export declare function isBrowserSupported(): boolean;
19
19
  export declare function isFireFox(): boolean;
20
+ export declare function isChromiumBased(): boolean;
20
21
  export declare function isSafari(): boolean;
21
22
  export declare function isMobile(): boolean;
22
23
  export declare function isWeb(): boolean;