@cloudflare/realtimekit 2.0.3-staging.7 → 2.0.3-staging.9
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/AGENTS.md +5 -5
- package/dist/ClientMock.cjs.js +1 -1
- package/dist/ClientMock.es.js +447 -365
- package/dist/EncryptionManager.cjs.js +1 -1
- package/dist/EncryptionManager.d.ts +18 -3
- package/dist/EncryptionManager.es.js +11 -11
- package/dist/browser.js +10 -10
- package/dist/dependencies.txt +204 -16
- package/dist/index.cjs.js +7 -7
- package/dist/index.d.ts +18 -3
- package/dist/index.es.js +6007 -5888
- package/dist/index.es5.js +4672 -4680
- package/dist/index.rn.js +7 -7
- package/dist/ts3.4/dist/EncryptionManager.d.ts +18 -3
- package/dist/ts3.4/dist/index.d.ts +18 -3
- package/package.json +2 -2
|
@@ -494,6 +494,10 @@ interface PeerJoinBroadcastResponse {
|
|
|
494
494
|
* @generated from protobuf field: media.edge.RoomParticipants participant = 1;
|
|
495
495
|
*/
|
|
496
496
|
participant?: RoomParticipants;
|
|
497
|
+
/**
|
|
498
|
+
* @generated from protobuf field: optional string producer_handover_from_peer_id = 2;
|
|
499
|
+
*/
|
|
500
|
+
producerHandoverFromPeerId?: string;
|
|
497
501
|
}
|
|
498
502
|
/**
|
|
499
503
|
* @generated MessageType for protobuf message media.edge.PeerJoinBroadcastResponse
|
|
@@ -1810,6 +1814,7 @@ declare class SocketService {
|
|
|
1810
1814
|
get telemetry(): Telemetry;
|
|
1811
1815
|
get logger(): Logger;
|
|
1812
1816
|
get peerId(): string;
|
|
1817
|
+
get replacedPeerIds(): string[];
|
|
1813
1818
|
constructor(context: Context<ContextState>, { peerId, meetingId, authToken, capabilities, }: {
|
|
1814
1819
|
peerId: string;
|
|
1815
1820
|
meetingId: string;
|
|
@@ -1891,6 +1896,7 @@ declare class SelectedPeers {
|
|
|
1891
1896
|
constructor();
|
|
1892
1897
|
add(peerId: string, priority: number, context: Context<ContextState>): number;
|
|
1893
1898
|
delete(peerId: string, context: Context<ContextState>): void;
|
|
1899
|
+
reassignPeer(oldPeerId: string, newPeerId: string, context: Context<ContextState>): void;
|
|
1894
1900
|
index(peerId: string): number;
|
|
1895
1901
|
get peers(): string[];
|
|
1896
1902
|
get compulsoryPeers(): string[];
|
|
@@ -3268,6 +3274,7 @@ declare class AudioPlayback {
|
|
|
3268
3274
|
declare class AudioPlaybackManager extends AudioPlayback {
|
|
3269
3275
|
constructor();
|
|
3270
3276
|
addParticipantTrack(participantId: string, track: MediaStreamTrack): void;
|
|
3277
|
+
reassignParticipantTrack(oldParticipantId: string, newParticipantId: string): void;
|
|
3271
3278
|
removeParticipantTrack(participantId: string): void;
|
|
3272
3279
|
}
|
|
3273
3280
|
|
|
@@ -3502,13 +3509,14 @@ declare class Consumer extends EnhancedEventEmitter<TransportPromiseEvents> {
|
|
|
3502
3509
|
readonly producingTransportId: string;
|
|
3503
3510
|
readonly mimeType: string;
|
|
3504
3511
|
readonly track: MediaStreamTrack;
|
|
3505
|
-
|
|
3512
|
+
peerId: string;
|
|
3506
3513
|
readonly appData: Record<string, unknown>;
|
|
3507
3514
|
readonly transceiver: RTCRtpTransceiver;
|
|
3508
3515
|
constructor(context: Context<ContextState>, opts: ConsumerOptions);
|
|
3509
3516
|
get closed(): boolean;
|
|
3510
3517
|
get kind(): MediaKind$1;
|
|
3511
3518
|
get paused(): boolean;
|
|
3519
|
+
reassignPeer(peerId: string): void;
|
|
3512
3520
|
close(reason?: string, closeTranscieverOnClose?: boolean): void;
|
|
3513
3521
|
getStats(): Promise<RTCStatsReport>;
|
|
3514
3522
|
pause(): void;
|
|
@@ -3629,7 +3637,7 @@ declare class ParticipantMap<T extends Pick<Participant, 'id' | keyof TypedEvent
|
|
|
3629
3637
|
declare const modes: readonly ["ACTIVE_GRID", "PAGINATED", "MANUAL"];
|
|
3630
3638
|
type ViewMode = (typeof modes)[number];
|
|
3631
3639
|
interface BroadcastMessagePayload {
|
|
3632
|
-
[key: string]: boolean | number | string | Date | ActiveTab;
|
|
3640
|
+
[key: string]: boolean | number | string | string[] | Date | ActiveTab;
|
|
3633
3641
|
}
|
|
3634
3642
|
interface PeerProducerConfig {
|
|
3635
3643
|
audio: boolean;
|
|
@@ -3950,7 +3958,7 @@ declare class MediaNodeClient {
|
|
|
3950
3958
|
initializeConnection(displayName: string, roomUuid: string, rejoining?: boolean, permissions?: MediaPermissions): Promise<void>;
|
|
3951
3959
|
getConsumers(): Map<string, Consumer>;
|
|
3952
3960
|
getProducers(): Map<string, Producer>;
|
|
3953
|
-
|
|
3961
|
+
handoverPeerProducers(newPeerId: string, producerIds: string[]): Consumer[];
|
|
3954
3962
|
leaveRoom(): Promise<void>;
|
|
3955
3963
|
activatePeers(producers: ProducerState[]): Promise<void>;
|
|
3956
3964
|
createConsumers(producers: ProducerState[]): Promise<void>;
|
|
@@ -4074,8 +4082,14 @@ interface TypedEventEmitter$1<Events extends EventMap$1> {
|
|
|
4074
4082
|
reset(): void;
|
|
4075
4083
|
}
|
|
4076
4084
|
|
|
4085
|
+
type ProducerHandoverPayload = {
|
|
4086
|
+
oldPeerId: string;
|
|
4087
|
+
newPeerId: string;
|
|
4088
|
+
producerIds: string[];
|
|
4089
|
+
};
|
|
4077
4090
|
declare enum SessionEvents {
|
|
4078
4091
|
NEW_PRODUCER = "NEW_PRODUCER",
|
|
4092
|
+
PRODUCER_HANDOVER = "PRODUCER_HANDOVER",
|
|
4079
4093
|
ROOM_NODE_CONNECTION_ERROR = "ROOM_NODE_CONNECTION_ERROR",
|
|
4080
4094
|
SOCKET_SERVICE_ROOM_JOINED = "SOCKET_SERVICE_ROOM_JOINED",
|
|
4081
4095
|
SOCKET_SERVICE_RECONNECTED = "SOCKET_SERVICE_RECONNECTED",
|
|
@@ -4130,6 +4144,7 @@ type AllEvents = {
|
|
|
4130
4144
|
[key in SessionEvents]: (payload?: any) => void;
|
|
4131
4145
|
};
|
|
4132
4146
|
type TypedEvents = {
|
|
4147
|
+
[SessionEvents.PRODUCER_HANDOVER]: (payload: ProducerHandoverPayload) => void;
|
|
4133
4148
|
[SessionEvents.TRANSPORT_STATE_UPDATE]: (payload: MediaConnectionUpdate) => void;
|
|
4134
4149
|
[SessionEvents.UPDATE_PERMISSIONS]: (p: PresetUpdates) => void;
|
|
4135
4150
|
[SessionEvents.MAX_SPATIAL_LAYER_CHANGE]: (p: {
|