@whereby.com/browser-sdk 2.1.0-beta2 → 2.1.0-beta4
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/cdn/{v2-embed-beta2.js → v2-embed-beta4.js} +1 -1
- package/dist/cdn/v2-react-beta4.js +3 -0
- package/dist/core/index.d.ts +2360 -0
- package/dist/core/index.js +62963 -0
- package/dist/embed/index.esm.js +1 -1
- package/dist/react/index.d.ts +90 -88
- package/dist/react/index.esm.js +1089 -146
- package/package.json +9 -2
- package/dist/cdn/v2-react-beta2.js +0 -3
package/dist/embed/index.esm.js
CHANGED
package/dist/react/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as React$1 from 'react';
|
|
2
|
-
import _whereby_jslib_media_src_utils_ServerSocket, { ChatMessage as ChatMessage$2 } from '@whereby/jslib-media/src/utils/ServerSocket';
|
|
3
2
|
import * as redux_thunk from 'redux-thunk';
|
|
4
3
|
import { AxiosRequestConfig } from 'axios';
|
|
5
4
|
import EventEmitter from 'events';
|
|
6
5
|
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
7
6
|
import * as redux from 'redux';
|
|
7
|
+
import _whereby_jslib_media_src_utils_ServerSocket, { ChatMessage as ChatMessage$2 } from '@whereby/jslib-media/src/utils/ServerSocket';
|
|
8
8
|
import RtcManagerDispatcher from '@whereby/jslib-media/src/webrtc/RtcManagerDispatcher';
|
|
9
9
|
import RtcManager from '@whereby/jslib-media/src/webrtc/RtcManager';
|
|
10
10
|
|
|
@@ -25,58 +25,6 @@ interface VideoViewSelfProps {
|
|
|
25
25
|
type VideoViewProps = VideoViewSelfProps & React$1.DetailedHTMLProps<React$1.VideoHTMLAttributes<HTMLVideoElement>, HTMLVideoElement>;
|
|
26
26
|
declare const _default: ({ muted, mirror, stream, onResize, onSetAspectRatio, ...rest }: VideoViewProps) => React$1.JSX.Element;
|
|
27
27
|
|
|
28
|
-
interface RoomParticipantData {
|
|
29
|
-
displayName: string;
|
|
30
|
-
id: string;
|
|
31
|
-
stream?: MediaStream;
|
|
32
|
-
isAudioEnabled: boolean;
|
|
33
|
-
isVideoEnabled: boolean;
|
|
34
|
-
}
|
|
35
|
-
declare class RoomParticipant {
|
|
36
|
-
readonly displayName: string;
|
|
37
|
-
readonly id: string;
|
|
38
|
-
readonly stream?: MediaStream;
|
|
39
|
-
readonly isAudioEnabled: boolean;
|
|
40
|
-
readonly isLocalParticipant: boolean;
|
|
41
|
-
readonly isVideoEnabled: boolean;
|
|
42
|
-
constructor({ displayName, id, stream, isAudioEnabled, isVideoEnabled }: RoomParticipantData);
|
|
43
|
-
}
|
|
44
|
-
type StreamState = "new_accept" | "to_accept" | "old_accept" | "done_accept" | "to_unaccept" | "done_unaccept" | "auto";
|
|
45
|
-
interface Stream {
|
|
46
|
-
id: string;
|
|
47
|
-
state: StreamState;
|
|
48
|
-
}
|
|
49
|
-
interface RemoteParticipant {
|
|
50
|
-
id: string;
|
|
51
|
-
displayName: string;
|
|
52
|
-
isAudioEnabled: boolean;
|
|
53
|
-
isVideoEnabled: boolean;
|
|
54
|
-
isLocalParticipant: boolean;
|
|
55
|
-
stream: (MediaStream & {
|
|
56
|
-
inboundId?: string;
|
|
57
|
-
}) | null;
|
|
58
|
-
streams: Stream[];
|
|
59
|
-
newJoiner: boolean;
|
|
60
|
-
presentationStream: (MediaStream & {
|
|
61
|
-
inboundId?: string;
|
|
62
|
-
}) | null;
|
|
63
|
-
}
|
|
64
|
-
declare class LocalParticipant extends RoomParticipant {
|
|
65
|
-
readonly isLocalParticipant = true;
|
|
66
|
-
constructor({ displayName, id, stream, isAudioEnabled, isVideoEnabled }: RoomParticipantData);
|
|
67
|
-
}
|
|
68
|
-
interface WaitingParticipant {
|
|
69
|
-
id: string;
|
|
70
|
-
displayName: string | null;
|
|
71
|
-
}
|
|
72
|
-
interface Screenshare {
|
|
73
|
-
participantId: string;
|
|
74
|
-
id: string;
|
|
75
|
-
hasAudioTrack: boolean;
|
|
76
|
-
stream?: MediaStream;
|
|
77
|
-
isLocal: boolean;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
28
|
type Json = string | number | boolean | null | Array<Json> | {
|
|
81
29
|
[key: string]: Json;
|
|
82
30
|
};
|
|
@@ -497,6 +445,65 @@ declare class OrganizationService {
|
|
|
497
445
|
}): Promise<undefined>;
|
|
498
446
|
}
|
|
499
447
|
|
|
448
|
+
interface RoomParticipantData {
|
|
449
|
+
displayName: string;
|
|
450
|
+
id: string;
|
|
451
|
+
stream?: MediaStream;
|
|
452
|
+
isAudioEnabled: boolean;
|
|
453
|
+
isVideoEnabled: boolean;
|
|
454
|
+
}
|
|
455
|
+
declare class RoomParticipant {
|
|
456
|
+
readonly displayName: string;
|
|
457
|
+
readonly id: string;
|
|
458
|
+
readonly stream?: MediaStream;
|
|
459
|
+
readonly isAudioEnabled: boolean;
|
|
460
|
+
readonly isLocalParticipant: boolean;
|
|
461
|
+
readonly isVideoEnabled: boolean;
|
|
462
|
+
constructor({ displayName, id, stream, isAudioEnabled, isVideoEnabled }: RoomParticipantData);
|
|
463
|
+
}
|
|
464
|
+
type StreamState = "new_accept" | "to_accept" | "old_accept" | "done_accept" | "to_unaccept" | "done_unaccept" | "auto";
|
|
465
|
+
interface Stream {
|
|
466
|
+
id: string;
|
|
467
|
+
state: StreamState;
|
|
468
|
+
}
|
|
469
|
+
interface RemoteParticipant {
|
|
470
|
+
id: string;
|
|
471
|
+
displayName: string;
|
|
472
|
+
isAudioEnabled: boolean;
|
|
473
|
+
isVideoEnabled: boolean;
|
|
474
|
+
isLocalParticipant: boolean;
|
|
475
|
+
stream: (MediaStream & {
|
|
476
|
+
inboundId?: string;
|
|
477
|
+
}) | null;
|
|
478
|
+
streams: Stream[];
|
|
479
|
+
newJoiner: boolean;
|
|
480
|
+
presentationStream: (MediaStream & {
|
|
481
|
+
inboundId?: string;
|
|
482
|
+
}) | null;
|
|
483
|
+
}
|
|
484
|
+
declare class LocalParticipant extends RoomParticipant {
|
|
485
|
+
readonly isLocalParticipant = true;
|
|
486
|
+
constructor({ displayName, id, stream, isAudioEnabled, isVideoEnabled }: RoomParticipantData);
|
|
487
|
+
}
|
|
488
|
+
interface WaitingParticipant {
|
|
489
|
+
id: string;
|
|
490
|
+
displayName: string | null;
|
|
491
|
+
}
|
|
492
|
+
interface Screenshare {
|
|
493
|
+
participantId: string;
|
|
494
|
+
id: string;
|
|
495
|
+
hasAudioTrack: boolean;
|
|
496
|
+
stream?: MediaStream;
|
|
497
|
+
isLocal: boolean;
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
/**
|
|
501
|
+
* Reducer
|
|
502
|
+
*/
|
|
503
|
+
interface WaitingParticipantsState {
|
|
504
|
+
waitingParticipants: WaitingParticipant[];
|
|
505
|
+
}
|
|
506
|
+
|
|
500
507
|
/**
|
|
501
508
|
* Reducer
|
|
502
509
|
*/
|
|
@@ -555,6 +562,7 @@ interface AppState {
|
|
|
555
562
|
displayName: string | null;
|
|
556
563
|
sdkVersion: string | null;
|
|
557
564
|
externalId: string | null;
|
|
565
|
+
isNodeSdk: boolean;
|
|
558
566
|
}
|
|
559
567
|
|
|
560
568
|
/**
|
|
@@ -565,6 +573,34 @@ interface DeviceCredentialsState {
|
|
|
565
573
|
data?: Credentials | null;
|
|
566
574
|
}
|
|
567
575
|
|
|
576
|
+
type LocalMediaOptions = {
|
|
577
|
+
disabled?: boolean;
|
|
578
|
+
audio: boolean;
|
|
579
|
+
video: boolean;
|
|
580
|
+
};
|
|
581
|
+
/**
|
|
582
|
+
* Reducer
|
|
583
|
+
*/
|
|
584
|
+
interface LocalMediaState$1 {
|
|
585
|
+
busyDeviceIds: string[];
|
|
586
|
+
cameraDeviceError?: unknown;
|
|
587
|
+
cameraEnabled: boolean;
|
|
588
|
+
currentCameraDeviceId?: string;
|
|
589
|
+
currentMicrophoneDeviceId?: string;
|
|
590
|
+
devices: MediaDeviceInfo[];
|
|
591
|
+
isSettingCameraDevice: boolean;
|
|
592
|
+
isSettingMicrophoneDevice: boolean;
|
|
593
|
+
isTogglingCamera: boolean;
|
|
594
|
+
microphoneDeviceError?: unknown;
|
|
595
|
+
microphoneEnabled: boolean;
|
|
596
|
+
options?: LocalMediaOptions;
|
|
597
|
+
status: "" | "stopped" | "starting" | "started" | "error";
|
|
598
|
+
startError?: unknown;
|
|
599
|
+
stream?: MediaStream;
|
|
600
|
+
isSwitchingStream: boolean;
|
|
601
|
+
onDeviceChange?: () => void;
|
|
602
|
+
}
|
|
603
|
+
|
|
568
604
|
/**
|
|
569
605
|
* Reducer
|
|
570
606
|
*/
|
|
@@ -696,39 +732,7 @@ declare const createStore: ({ preloadedState, injectServices, }: {
|
|
|
696
732
|
}, {}>, redux.StoreEnhancer<{}, {}>]>>;
|
|
697
733
|
type Store = ReturnType<typeof createStore>;
|
|
698
734
|
|
|
699
|
-
|
|
700
|
-
* Reducer
|
|
701
|
-
*/
|
|
702
|
-
interface WaitingParticipantsState {
|
|
703
|
-
waitingParticipants: WaitingParticipant[];
|
|
704
|
-
}
|
|
705
|
-
|
|
706
|
-
type LocalMediaOptions = {
|
|
707
|
-
audio: boolean;
|
|
708
|
-
video: boolean;
|
|
709
|
-
};
|
|
710
|
-
/**
|
|
711
|
-
* Reducer
|
|
712
|
-
*/
|
|
713
|
-
interface LocalMediaState$1 {
|
|
714
|
-
busyDeviceIds: string[];
|
|
715
|
-
cameraDeviceError?: unknown;
|
|
716
|
-
cameraEnabled: boolean;
|
|
717
|
-
currentCameraDeviceId?: string;
|
|
718
|
-
currentMicrophoneDeviceId?: string;
|
|
719
|
-
devices: MediaDeviceInfo[];
|
|
720
|
-
isSettingCameraDevice: boolean;
|
|
721
|
-
isSettingMicrophoneDevice: boolean;
|
|
722
|
-
isTogglingCamera: boolean;
|
|
723
|
-
microphoneDeviceError?: unknown;
|
|
724
|
-
microphoneEnabled: boolean;
|
|
725
|
-
options?: LocalMediaOptions;
|
|
726
|
-
status: "" | "stopped" | "starting" | "started" | "error";
|
|
727
|
-
startError?: unknown;
|
|
728
|
-
stream?: MediaStream;
|
|
729
|
-
isSwitchingStream: boolean;
|
|
730
|
-
onDeviceChange?: () => void;
|
|
731
|
-
}
|
|
735
|
+
declare const sdkVersion = "__SDK_VERSION__";
|
|
732
736
|
|
|
733
737
|
interface LocalMediaState {
|
|
734
738
|
currentCameraDeviceId?: string;
|
|
@@ -853,6 +857,4 @@ interface GridProps {
|
|
|
853
857
|
}
|
|
854
858
|
declare function Grid({ roomConnection, renderParticipant, videoGridGap }: GridProps): React$1.JSX.Element;
|
|
855
859
|
|
|
856
|
-
declare const sdkVersion = "__SDK_VERSION__";
|
|
857
|
-
|
|
858
860
|
export { type ChatMessageState as ChatMessage, type LocalParticipantState as LocalParticipant, type RemoteParticipantState as RemoteParticipant, type RoomConnectionState as RoomConnection, type ScreenshareState as Screenshare, type UseLocalMediaResult, Grid as VideoGrid, _default as VideoView, type WaitingParticipantState as WaitingParticipant, sdkVersion, useLocalMedia, useRoomConnection };
|