@cometchat/calls-sdk-react-native 4.4.2-beta.1 → 5.0.0-beta.2
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/README.md +85 -19
- package/android/.gradle/8.9/checksums/checksums.lock +0 -0
- package/android/.gradle/8.9/dependencies-accessors/gc.properties +0 -0
- package/android/.gradle/8.9/fileChanges/last-build.bin +0 -0
- package/android/.gradle/8.9/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/8.9/gc.properties +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -0
- package/android/.gradle/vcs-1/gc.properties +0 -0
- package/android/build.gradle +13 -12
- package/android/src/main/AndroidManifest.xml +15 -6
- package/android/src/main/java/com/callingv5/AudioDeviceHandlerConnectionService.java +185 -0
- package/android/src/main/java/com/callingv5/AudioDeviceHandlerGeneric.java +254 -0
- package/android/src/main/java/com/{CometChatCalls → callingv5}/AudioModeModule.java +93 -56
- package/android/src/main/java/com/callingv5/ConnectionService.java +451 -0
- package/android/src/main/java/com/callingv5/KeepAwakeModule.java +53 -0
- package/android/src/main/java/com/callingv5/MyAppPackage.java +35 -0
- package/android/src/main/java/com/callingv5/RNConnectionService.java +244 -0
- package/android/src/main/java/com/callingv5/ToastModule.java +29 -0
- package/android/src/main/java/com/callingv5/utils/CometChatLogger.java +88 -0
- package/cometchat-calls-sdk-react-native.podspec +9 -10
- package/dist/index.d.mts +4066 -0
- package/dist/index.d.ts +4066 -9
- package/dist/index.js +11116 -132
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +11085 -0
- package/dist/index.mjs.map +1 -0
- package/dist/polyfills/RTCPeerConnection.js +19 -0
- package/dist/polyfills/Storage.js +192 -0
- package/dist/polyfills/browser.js +337 -0
- package/dist/polyfills/index.js +1 -0
- package/dist/polyfills/ipv6utils.js +197 -0
- package/dist/polyfills/webrtc.js +11 -0
- package/ios/{JitsiAudioSession+Private.h → Audio/CometChatAudioSession+Private.h} +2 -3
- package/ios/{LogUtils.h → Audio/CometChatAudioSession.h} +9 -6
- package/ios/{JitsiAudioSession.m → Audio/CometChatAudioSession.m} +4 -3
- package/ios/{AudioMode.m → Modules/AudioMode.m} +15 -49
- package/ios/Modules/KeepAwake.h +4 -0
- package/ios/Modules/KeepAwake.m +29 -0
- package/package.json +24 -110
- package/LICENSE.md +0 -3
- package/android/src/main/java/com/CometChatCalls/AudioDeviceHandlerGeneric.java +0 -213
- package/android/src/main/java/com/CometChatCalls/AudioDeviceHandlerLegacy.java +0 -213
- package/android/src/main/java/com/CometChatCalls/BluetoothHeadsetMonitor.java +0 -187
- package/android/src/main/java/com/CometChatCalls/CallNotificationService.java +0 -93
- package/android/src/main/java/com/CometChatCalls/CallNotificationServiceModule.java +0 -48
- package/android/src/main/java/com/CometChatCalls/CometChatCallsPackage.java +0 -56
- package/android/src/main/java/com/CometChatCalls/CometChatCommonModule.java +0 -48
- package/android/src/main/java/com/CometChatCalls/PictureInPictureModule.java +0 -133
- package/android/src/main/res/drawable-mdpi/callingcomponent_icons_headphones_pluged.png +0 -0
- package/dist/CometChatErrorConstants.d.ts +0 -124
- package/dist/Constants.d.ts +0 -724
- package/dist/Helper copy.d.ts +0 -1
- package/dist/Helper.d.ts +0 -7
- package/dist/api/APIHandler.d.ts +0 -42
- package/dist/api/endpoints.d.ts +0 -7
- package/dist/api/helper.d.ts +0 -69
- package/dist/api/index.d.ts +0 -2
- package/dist/constants/CallConstants.d.ts +0 -136
- package/dist/constants/index.d.ts +0 -1
- package/dist/defaultCallsettings.d.ts +0 -2
- package/dist/models/CallAppSettings.d.ts +0 -42
- package/dist/models/CallGroup.d.ts +0 -14
- package/dist/models/CallLog.d.ts +0 -276
- package/dist/models/CallLogFilterParams.d.ts +0 -97
- package/dist/models/CallSettings.d.ts +0 -330
- package/dist/models/CallUser.d.ts +0 -14
- package/dist/models/CometChatCallLogs.d.ts +0 -193
- package/dist/models/CometChatCalls.d.ts +0 -110
- package/dist/models/CometChatCallsComponent.d.ts +0 -13
- package/dist/models/CometChatCallsComponentCore.d.ts +0 -18
- package/dist/models/CometChatCallsException.d.ts +0 -7
- package/dist/models/CometChatPresenterComponent.d.ts +0 -13
- package/dist/models/ErrorModel.d.ts +0 -11
- package/dist/models/Listner.d.ts +0 -69
- package/dist/models/ListnerHandler.d.ts +0 -10
- package/dist/models/MessageComponent.d.ts +0 -7
- package/dist/models/Participant.d.ts +0 -184
- package/dist/models/PresenterSettings.d.ts +0 -208
- package/dist/models/RTCUser.d.ts +0 -18
- package/dist/models/Recording.d.ts +0 -86
- package/dist/models/index.d.ts +0 -9
- package/dist/types/ICallAppSettings.d.ts +0 -6
- package/dist/types/ICallSettings.d.ts +0 -61
- package/dist/types/RTCUser.d.ts +0 -6
- package/dist/types/callEvents.d.ts +0 -54
- package/dist/types/common.d.ts +0 -18
- package/dist/types/index.d.ts +0 -2
- package/ios/AudioMode.h +0 -11
- package/ios/CometChatCommonModule.h +0 -6
- package/ios/CometChatCommonModule.m +0 -29
- package/ios/JitsiAudioSession.h +0 -17
- package/ios/react-native-calls2.xcodeproj/project.pbxproj +0 -269
|
@@ -1,330 +0,0 @@
|
|
|
1
|
-
import { OngoingCallListener } from './Listner';
|
|
2
|
-
import { CallConstants } from '../Constants';
|
|
3
|
-
import { AspectRatio, Position } from '../types/common';
|
|
4
|
-
export declare class CallSettings {
|
|
5
|
-
static readonly POSITION_TOP_LEFT = "top-left";
|
|
6
|
-
static readonly POSITION_TOP_RIGHT = "top-right";
|
|
7
|
-
static readonly POSITION_BOTTOM_LEFT = "bottom-left";
|
|
8
|
-
static readonly POSITION_BOTTOM_RIGHT = "bottom-right";
|
|
9
|
-
static readonly ASPECT_RATIO_DEFAULT = "default";
|
|
10
|
-
static readonly ASPECT_RATIO_CONTAIN = "contain";
|
|
11
|
-
static readonly ASPECT_RATIO_COVER = "cover";
|
|
12
|
-
static readonly POSITION: {
|
|
13
|
-
readonly TOP_LEFT: "top-left";
|
|
14
|
-
readonly TOP_RIGHT: "top-right";
|
|
15
|
-
readonly BOTTOM_LEFT: "bottom-left";
|
|
16
|
-
readonly BOTTOM_RIGHT: "bottom-right";
|
|
17
|
-
};
|
|
18
|
-
static readonly ASPECT_RATIO: {
|
|
19
|
-
readonly DEFAULT: "default";
|
|
20
|
-
readonly CONTAIN: "contain";
|
|
21
|
-
readonly COVER: "cover";
|
|
22
|
-
};
|
|
23
|
-
private defaultLayout;
|
|
24
|
-
private isAudioOnly;
|
|
25
|
-
private listener;
|
|
26
|
-
private mode;
|
|
27
|
-
private ShowEndCallButton;
|
|
28
|
-
private ShowSwitchCameraButton;
|
|
29
|
-
private ShowMuteAudioButton;
|
|
30
|
-
private ShowPauseVideoButton;
|
|
31
|
-
private ShowAudioModeButton;
|
|
32
|
-
private StartAudioMuted;
|
|
33
|
-
private StartVideoMuted;
|
|
34
|
-
private defaultAudioMode;
|
|
35
|
-
private ShowSwitchToVideoCallButton;
|
|
36
|
-
private AvatarMode;
|
|
37
|
-
private ShowRecordingButton;
|
|
38
|
-
private idleTimeoutPeriod;
|
|
39
|
-
private StartRecordingOnCallStart;
|
|
40
|
-
private MainVideoContainerSetting;
|
|
41
|
-
private EnableVideoTileClick;
|
|
42
|
-
private enableDraggableVideoTile;
|
|
43
|
-
constructor(builder: CallSettingsBuilder);
|
|
44
|
-
isAudioOnlyCall(): boolean;
|
|
45
|
-
isDefaultLayoutEnabled(): boolean;
|
|
46
|
-
getCallEventListener(): OngoingCallListener;
|
|
47
|
-
getMode(): string;
|
|
48
|
-
isEndCallButtonEnabled(): boolean;
|
|
49
|
-
isSwitchCameraButtonEnabled(): boolean;
|
|
50
|
-
isMuteAudioButtonEnabled(): boolean;
|
|
51
|
-
isPauseVideoButtonEnabled(): boolean;
|
|
52
|
-
isAudioModeButtonEnabled(): boolean;
|
|
53
|
-
getStartWithAudioMuted(): boolean;
|
|
54
|
-
getStartWithVideoMuted(): boolean;
|
|
55
|
-
getDefaultAudioMode(): string;
|
|
56
|
-
isAudioToVideoButtonEnabled(): boolean;
|
|
57
|
-
getAvatarMode(): string;
|
|
58
|
-
isRecordingButtonEnabled(): boolean;
|
|
59
|
-
getIdleTimeoutPeriod(): number;
|
|
60
|
-
shouldStartRecordingOnCallStart(): boolean;
|
|
61
|
-
getMainVideoContainerSetting(): MainVideoContainerSetting;
|
|
62
|
-
isVideoTileClickEnabled(): boolean;
|
|
63
|
-
isVideoTileDragEnabled(): boolean;
|
|
64
|
-
}
|
|
65
|
-
type CallModes = typeof CallConstants.CALL_MODE[keyof typeof CallConstants.CALL_MODE];
|
|
66
|
-
export declare class CallSettingsBuilder {
|
|
67
|
-
/** @private */ defaultLayout: boolean;
|
|
68
|
-
/** @private */ isAudioOnly: boolean;
|
|
69
|
-
/** @private */ listener: OngoingCallListener;
|
|
70
|
-
/** @private */ mode: CallModes;
|
|
71
|
-
/** @private */ ShowEndCallButton: boolean;
|
|
72
|
-
/** @private */ ShowSwitchCameraButton: boolean;
|
|
73
|
-
/** @private */ ShowMuteAudioButton: boolean;
|
|
74
|
-
/** @private */ ShowPauseVideoButton: boolean;
|
|
75
|
-
/** @private */ ShowAudioModeButton: boolean;
|
|
76
|
-
/** @private */ StartAudioMuted: boolean;
|
|
77
|
-
/** @private */ StartVideoMuted: boolean;
|
|
78
|
-
/** @private */ defaultAudioMode: typeof CallConstants.AUDIO_MODE[keyof typeof CallConstants.AUDIO_MODE];
|
|
79
|
-
/** @private */ ShowSwitchToVideoCallButton: boolean;
|
|
80
|
-
/** @private */ AvatarMode: string;
|
|
81
|
-
/** @private */ ShowRecordingButton: boolean;
|
|
82
|
-
/** @private */ idleTimeoutPeriod: number;
|
|
83
|
-
/** @private */ StartRecordingOnCallStart: boolean;
|
|
84
|
-
/** @private */ MainVideoContainerSetting: MainVideoContainerSetting;
|
|
85
|
-
/** @private */ EnableVideoTileClick: boolean;
|
|
86
|
-
/** @private */ enableDraggableVideoTile: boolean;
|
|
87
|
-
/**
|
|
88
|
-
*
|
|
89
|
-
* @param {boolean} defaultLayout
|
|
90
|
-
* This methods shows/hides the default button layout.
|
|
91
|
-
* If set to true the default button layout will be shown.
|
|
92
|
-
* If set to false the default button layout will be hidden.
|
|
93
|
-
* Default value is true
|
|
94
|
-
* @returns
|
|
95
|
-
*/
|
|
96
|
-
enableDefaultLayout(defaultLayout: boolean): this;
|
|
97
|
-
/**
|
|
98
|
-
*
|
|
99
|
-
* @param {boolean} isAudioOnly
|
|
100
|
-
* This methods sets the type(audio/video) of the call.
|
|
101
|
-
* If set to true, the call will be strictly an audio call.
|
|
102
|
-
* If set to false, the call will be an audio-video call.
|
|
103
|
-
* Default value is false
|
|
104
|
-
* @returns
|
|
105
|
-
*/
|
|
106
|
-
setIsAudioOnlyCall(isAudioOnly: boolean): this;
|
|
107
|
-
/**
|
|
108
|
-
*
|
|
109
|
-
* @param {OngoingCallListener} listener
|
|
110
|
-
* This method sets the call event listener.
|
|
111
|
-
* @returns
|
|
112
|
-
*/
|
|
113
|
-
setCallEventListener(listener: OngoingCallListener): this;
|
|
114
|
-
/**
|
|
115
|
-
*
|
|
116
|
-
* @param {string} mode
|
|
117
|
-
* This method sets the mode of the call.
|
|
118
|
-
* @returns
|
|
119
|
-
*/
|
|
120
|
-
setMode(mode: CallModes): this;
|
|
121
|
-
/**
|
|
122
|
-
*
|
|
123
|
-
* @param {boolean} showEndCallButton
|
|
124
|
-
* This method shows/hides the end call button.
|
|
125
|
-
* If set to true it will display the end call button.
|
|
126
|
-
* If set to false it will hide the end call button.
|
|
127
|
-
* Default value is true.
|
|
128
|
-
* @returns
|
|
129
|
-
*/
|
|
130
|
-
showEndCallButton(showEndCallButton?: boolean): this;
|
|
131
|
-
/**
|
|
132
|
-
*
|
|
133
|
-
* @param {boolean} showSwitchCameraButton
|
|
134
|
-
* This method shows/hides the switch camera button.
|
|
135
|
-
* If set to true it will display the switch camera button.
|
|
136
|
-
* If set to false it will hide the switch camera button.
|
|
137
|
-
* Note: For video call it remains hidden regardless of its value.
|
|
138
|
-
* Default value is true.
|
|
139
|
-
* @returns
|
|
140
|
-
*/
|
|
141
|
-
showSwitchCameraButton(showSwitchCameraButton?: boolean): this;
|
|
142
|
-
/**
|
|
143
|
-
*
|
|
144
|
-
* @param {boolean} showMuteAudioButton
|
|
145
|
-
* This method shows/hides the mute audio button.
|
|
146
|
-
* If set to true it will display the mute audio button.
|
|
147
|
-
* If set to false it will hide the mute audio button.
|
|
148
|
-
* Default value is true.
|
|
149
|
-
* @returns
|
|
150
|
-
*/
|
|
151
|
-
showMuteAudioButton(showMuteAudioButton?: boolean): this;
|
|
152
|
-
/**
|
|
153
|
-
*
|
|
154
|
-
* @param {boolean} showPauseVideoButton
|
|
155
|
-
* This method shows/hides the pause video button.
|
|
156
|
-
* If set to true it will display the pause video button.
|
|
157
|
-
* If set to false it will hide the pause video button.
|
|
158
|
-
* Note: For video call it remains hidden regardless of its value.
|
|
159
|
-
* Default value is true.
|
|
160
|
-
* @returns
|
|
161
|
-
*/
|
|
162
|
-
showPauseVideoButton(showPauseVideoButton?: boolean): this;
|
|
163
|
-
/**
|
|
164
|
-
*
|
|
165
|
-
* @param {boolean} showAudioModeButton
|
|
166
|
-
* This method shows/hides the audio mode button.
|
|
167
|
-
* If set to true it will display the audio mode button.
|
|
168
|
-
* If set to false it will hide the audio mode button.
|
|
169
|
-
* Default value is true.
|
|
170
|
-
* @returns
|
|
171
|
-
*/
|
|
172
|
-
showAudioModeButton(showAudioModeButton?: boolean): this;
|
|
173
|
-
/**
|
|
174
|
-
*
|
|
175
|
-
* @param {boolean} audioMuted
|
|
176
|
-
* This method allows the call to be started with audio muted.
|
|
177
|
-
* If set to true, the call will start with audio muted.
|
|
178
|
-
* Default value is false.
|
|
179
|
-
* @returns
|
|
180
|
-
*/
|
|
181
|
-
startWithAudioMuted(audioMuted?: boolean): this;
|
|
182
|
-
/**
|
|
183
|
-
*
|
|
184
|
-
* @param {boolean} videoMuted
|
|
185
|
-
* This method allows the call to be started with video muted.
|
|
186
|
-
* If set to true, the call will start with video muted.
|
|
187
|
-
* Note: This method has no effect for audio calls.
|
|
188
|
-
* Default value is false.
|
|
189
|
-
* @returns
|
|
190
|
-
*/
|
|
191
|
-
startWithVideoMuted(videoMuted?: boolean): this;
|
|
192
|
-
/**
|
|
193
|
-
*
|
|
194
|
-
* @param {string} audioMode
|
|
195
|
-
* This method will set the default audio mode.
|
|
196
|
-
* @returns
|
|
197
|
-
*/
|
|
198
|
-
setDefaultAudioMode(audioMode: typeof CallConstants.AUDIO_MODE[keyof typeof CallConstants.AUDIO_MODE]): this;
|
|
199
|
-
/**
|
|
200
|
-
*
|
|
201
|
-
* @param {boolean} showAudioToVideoSwitchButton
|
|
202
|
-
* This method shows/hides the switch to video call button.
|
|
203
|
-
* If set to true it will display the switch to video call button.
|
|
204
|
-
* If set to false it will hide the switch to video call button.
|
|
205
|
-
* Note: For video call it remains hidden regardless of its value.
|
|
206
|
-
* Default value is true.
|
|
207
|
-
* @returns
|
|
208
|
-
*/
|
|
209
|
-
showSwitchToVideoCallButton(showAudioToVideoSwitchButton?: boolean): this;
|
|
210
|
-
/**
|
|
211
|
-
*
|
|
212
|
-
* @param {string} mode
|
|
213
|
-
* This method sets the mode of avatar.
|
|
214
|
-
* The avatar mode can be circle, square or fullscreen.
|
|
215
|
-
* Default value is circle.
|
|
216
|
-
* @returns
|
|
217
|
-
*/
|
|
218
|
-
setAvatarMode(mode?: 'circle' | 'square' | 'fullscreen'): this;
|
|
219
|
-
/**
|
|
220
|
-
*
|
|
221
|
-
* @param {boolean} showRecordingButton
|
|
222
|
-
* This method shows/hides the recording button.
|
|
223
|
-
* If set to true it will display the recording button.
|
|
224
|
-
* If set to false it will hide the recording button.
|
|
225
|
-
* Default value is false.
|
|
226
|
-
* @returns
|
|
227
|
-
*/
|
|
228
|
-
showRecordingButton(showRecordingButton?: boolean): this;
|
|
229
|
-
/**
|
|
230
|
-
*
|
|
231
|
-
* @param {number} idleTimeoutPeriod
|
|
232
|
-
* This method sets the idle timeout period for the call.
|
|
233
|
-
* If set and you are the only one in call, the call will end
|
|
234
|
-
* after the idle timeout period, giving you the option to
|
|
235
|
-
* extend the call 60 seconds before the call ends.
|
|
236
|
-
* Default value is 180 seconds.
|
|
237
|
-
* @returns
|
|
238
|
-
*/
|
|
239
|
-
setIdleTimeoutPeriod(idleTimeoutPeriod?: number): this;
|
|
240
|
-
/**
|
|
241
|
-
*
|
|
242
|
-
* @param {boolean} startRecordingOnCallStart
|
|
243
|
-
* This method starts the recording as soon as the call start.
|
|
244
|
-
* If set to true it will start the recording as soon as the call start.
|
|
245
|
-
* Default value is false.
|
|
246
|
-
* @returns
|
|
247
|
-
*/
|
|
248
|
-
startRecordingOnCallStart(startRecordingOnCallStart?: boolean): this;
|
|
249
|
-
/**
|
|
250
|
-
*
|
|
251
|
-
* @param {MainVideoContainerSetting} mainVideoContainerSetting
|
|
252
|
-
* This method can be used to customize the main video container.
|
|
253
|
-
* @returns
|
|
254
|
-
*/
|
|
255
|
-
setMainVideoContainerSetting(mainVideoContainerSetting: MainVideoContainerSetting): this;
|
|
256
|
-
/**
|
|
257
|
-
*
|
|
258
|
-
* @param {boolean} enableVideoTileClick
|
|
259
|
-
* This method can be used to enable/disable video tile click functionality in Spotlight mode.
|
|
260
|
-
* By default the video tile is clickable.
|
|
261
|
-
* @returns
|
|
262
|
-
*/
|
|
263
|
-
enableVideoTileClick(enableVideoTileClick?: boolean): this;
|
|
264
|
-
/**
|
|
265
|
-
*
|
|
266
|
-
* @param {boolean} enableVideoTileDrag
|
|
267
|
-
* This method can be used to enable/disable video tile drag functionality in Spotlight mode.
|
|
268
|
-
* By default the video tile is draggable.
|
|
269
|
-
* @returns
|
|
270
|
-
*/
|
|
271
|
-
enableVideoTileDrag(enableVideoTileDrag?: boolean): this;
|
|
272
|
-
/**
|
|
273
|
-
* This method will return an object of the CallSettings class.
|
|
274
|
-
* @returns {CallSettings}
|
|
275
|
-
*/
|
|
276
|
-
build(): CallSettings;
|
|
277
|
-
}
|
|
278
|
-
export declare class MainVideoContainerSetting {
|
|
279
|
-
private videoFit;
|
|
280
|
-
private zoomButton;
|
|
281
|
-
private fullScreenButton;
|
|
282
|
-
private userListButton;
|
|
283
|
-
private nameLabel;
|
|
284
|
-
/**
|
|
285
|
-
*
|
|
286
|
-
* @param {string} mainVideoAspectRatio
|
|
287
|
-
* This method is used to set the aspect ratio of main video.
|
|
288
|
-
* The default value is `contain`.
|
|
289
|
-
* @returns
|
|
290
|
-
*/
|
|
291
|
-
setMainVideoAspectRatio(mainVideoAspectRatio?: AspectRatio): void;
|
|
292
|
-
/**
|
|
293
|
-
*
|
|
294
|
-
* @param {Position} position
|
|
295
|
-
* @param {boolean} visibility
|
|
296
|
-
* This method is used to set the position & visibility parameter of the full screen button.
|
|
297
|
-
* By default the full screen button is visible in the `bottom-right` position.
|
|
298
|
-
* @returns
|
|
299
|
-
*/
|
|
300
|
-
setFullScreenButtonParams(position?: Position, visibility?: boolean): void;
|
|
301
|
-
/**
|
|
302
|
-
*
|
|
303
|
-
* @param {Position} position
|
|
304
|
-
* @param {boolean} visibility
|
|
305
|
-
* @param {string} backgroundColor
|
|
306
|
-
* This method is used to set the position, visibility & background color of the name label.
|
|
307
|
-
* By default the name label is visible in the `bottom-left` position with a background-color `#333333`
|
|
308
|
-
* @returns
|
|
309
|
-
*/
|
|
310
|
-
setNameLabelParams(position?: Position, visibility?: boolean, backgroundColor?: string): void;
|
|
311
|
-
/**
|
|
312
|
-
*
|
|
313
|
-
* @param {Position} position
|
|
314
|
-
* @param {boolean} visibility
|
|
315
|
-
* This method is used to set the position & visibility parameter of the zoom button.
|
|
316
|
-
* By default the zoom button is visible in the `bottom-right` position.
|
|
317
|
-
* @returns
|
|
318
|
-
*/
|
|
319
|
-
setZoomButtonParams(position?: Position, visibility?: boolean): void;
|
|
320
|
-
/**
|
|
321
|
-
*
|
|
322
|
-
* @param {Position} position
|
|
323
|
-
* @param {boolean} visibility
|
|
324
|
-
* This method is used to set the position & visibility parameter of the user list button.
|
|
325
|
-
* By default the user list button is visible in the `bottom-right` position.
|
|
326
|
-
* @returns
|
|
327
|
-
*/
|
|
328
|
-
setUserListButtonParams(position?: Position, visibility?: boolean): void;
|
|
329
|
-
}
|
|
330
|
-
export {};
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
export declare class CallUser {
|
|
2
|
-
protected uid: string;
|
|
3
|
-
protected name: string;
|
|
4
|
-
protected avatar: string;
|
|
5
|
-
constructor(object: any);
|
|
6
|
-
getUid(): string;
|
|
7
|
-
setUid(uid: string): void;
|
|
8
|
-
getName(): string;
|
|
9
|
-
setName(name: string): void;
|
|
10
|
-
getAvatar(): string;
|
|
11
|
-
setAvatar(avatar: string): void;
|
|
12
|
-
toString(): string;
|
|
13
|
-
static getUserFromJson(object: any): CallUser;
|
|
14
|
-
}
|
|
@@ -1,193 +0,0 @@
|
|
|
1
|
-
import { CallLog } from "./CallLog";
|
|
2
|
-
/**
|
|
3
|
-
* Represents a request to fetch call logs.
|
|
4
|
-
*/
|
|
5
|
-
declare class CallLogRequest {
|
|
6
|
-
/**
|
|
7
|
-
* The maximum number of call logs to fetch.
|
|
8
|
-
*/
|
|
9
|
-
private limit;
|
|
10
|
-
/**
|
|
11
|
-
* The total number of pages of call logs.
|
|
12
|
-
*/
|
|
13
|
-
private totalPages;
|
|
14
|
-
/**
|
|
15
|
-
* The current page of call logs.
|
|
16
|
-
*/
|
|
17
|
-
private currentPage;
|
|
18
|
-
/**
|
|
19
|
-
* The type of call to filter by.
|
|
20
|
-
*/
|
|
21
|
-
private callType;
|
|
22
|
-
/**
|
|
23
|
-
* The status of call to filter by.
|
|
24
|
-
*/
|
|
25
|
-
private callStatus;
|
|
26
|
-
/**
|
|
27
|
-
* Whether the call has a recording or not.
|
|
28
|
-
*/
|
|
29
|
-
private hasRecording;
|
|
30
|
-
/**
|
|
31
|
-
* The category of call to filter by.
|
|
32
|
-
*/
|
|
33
|
-
private callCategory;
|
|
34
|
-
/**
|
|
35
|
-
* The direction of call to filter by.
|
|
36
|
-
*/
|
|
37
|
-
private callDirection;
|
|
38
|
-
/**
|
|
39
|
-
* The user ID to filter by.
|
|
40
|
-
*/
|
|
41
|
-
private uid;
|
|
42
|
-
/**
|
|
43
|
-
* The group ID to filter by.
|
|
44
|
-
*/
|
|
45
|
-
private guid;
|
|
46
|
-
/**
|
|
47
|
-
* The authentication token to use for the API call.
|
|
48
|
-
*/
|
|
49
|
-
private authToken;
|
|
50
|
-
/**
|
|
51
|
-
* Whether an API call is currently in progress.
|
|
52
|
-
*/
|
|
53
|
-
private inProgress;
|
|
54
|
-
/**
|
|
55
|
-
* The timestamp of the last update.
|
|
56
|
-
*/
|
|
57
|
-
private updatedAt;
|
|
58
|
-
/**
|
|
59
|
-
* Whether to only fetch updates.
|
|
60
|
-
*/
|
|
61
|
-
private onlyUpdates;
|
|
62
|
-
/**
|
|
63
|
-
* The timestamp of the call log.
|
|
64
|
-
*/
|
|
65
|
-
private timestamp?;
|
|
66
|
-
/**
|
|
67
|
-
* The ID of the call log.
|
|
68
|
-
*/
|
|
69
|
-
private id?;
|
|
70
|
-
/**
|
|
71
|
-
* The affix of the call log.
|
|
72
|
-
*/
|
|
73
|
-
private affix;
|
|
74
|
-
/**
|
|
75
|
-
* The last affix of the call log.
|
|
76
|
-
*/
|
|
77
|
-
private lastAffix;
|
|
78
|
-
/**
|
|
79
|
-
* The current method of the call log.
|
|
80
|
-
*/
|
|
81
|
-
private currentMethod;
|
|
82
|
-
/**
|
|
83
|
-
* The pagination metadata of the call log.
|
|
84
|
-
*/
|
|
85
|
-
private paginationMeta;
|
|
86
|
-
/**
|
|
87
|
-
* Creates a new CallLogRequest instance.
|
|
88
|
-
* @param builder The builder object to use for constructing the request.
|
|
89
|
-
*/
|
|
90
|
-
constructor(builder: CallLogRequestBuilder);
|
|
91
|
-
/**
|
|
92
|
-
* Fetches the next page of call logs.
|
|
93
|
-
* @returns A promise that resolves to an array of CallLog objects, or rejects with a CometChatCallsException if there was an error.
|
|
94
|
-
*/
|
|
95
|
-
fetchNext(): Promise<CallLog[]>;
|
|
96
|
-
/**
|
|
97
|
-
* Fetches the previous page of call logs.
|
|
98
|
-
* @returns A promise that resolves to an array of CallLog objects, or an empty array if there are no previous pages, or rejects with a CometChatCallsException if there was an error..
|
|
99
|
-
*/
|
|
100
|
-
fetchPrevious(): Promise<CallLog[] | []>;
|
|
101
|
-
/**
|
|
102
|
-
* Makes an API call to fetch call logs.
|
|
103
|
-
* @param isFetchNext Whether to fetch the next page of call logs.
|
|
104
|
-
* @returns A promise that resolves to an array of CallLog objects, or rejects with a CometChatCallsException if there was an error.
|
|
105
|
-
*/
|
|
106
|
-
private makeAPICall;
|
|
107
|
-
/**
|
|
108
|
-
* Gets the filter parameters for the API call.
|
|
109
|
-
* @param isNext Whether to fetch the next page of call logs.
|
|
110
|
-
* @returns The filter parameters object.
|
|
111
|
-
*/
|
|
112
|
-
private getParams;
|
|
113
|
-
/**
|
|
114
|
-
* Parses the API response and returns an array of CallLog objects.
|
|
115
|
-
* @param response The API response string.
|
|
116
|
-
* @returns An array of CallLog objects.
|
|
117
|
-
*/
|
|
118
|
-
private getCallLogList;
|
|
119
|
-
}
|
|
120
|
-
/**
|
|
121
|
-
* A builder class for creating a request to fetch call logs.
|
|
122
|
-
*/
|
|
123
|
-
export declare class CallLogRequestBuilder {
|
|
124
|
-
limit: number;
|
|
125
|
-
callType: string;
|
|
126
|
-
callStatus: string;
|
|
127
|
-
hasRecording: boolean;
|
|
128
|
-
callCategory: string;
|
|
129
|
-
callDirection: string;
|
|
130
|
-
uid: string;
|
|
131
|
-
guid: string;
|
|
132
|
-
authToken: string;
|
|
133
|
-
/**
|
|
134
|
-
* Sets the limit of call logs to be fetched.
|
|
135
|
-
* @param limit - The number of call logs to be fetched.
|
|
136
|
-
* @returns The CallLogRequestBuilder object.
|
|
137
|
-
*/
|
|
138
|
-
setLimit(limit: number): this;
|
|
139
|
-
/**
|
|
140
|
-
* Sets the type of call to be fetched.
|
|
141
|
-
* @param callType - The type of call to be fetched. Can be either 'video' or 'audio'.
|
|
142
|
-
* @returns The CallLogRequestBuilder object.
|
|
143
|
-
*/
|
|
144
|
-
setCallType(callType: 'video' | 'audio'): this;
|
|
145
|
-
/**
|
|
146
|
-
* Sets the status of call to be fetched.
|
|
147
|
-
* @param callStatus - The status of call to be fetched. Can be either 'ongoing', 'busy', 'rejected', 'cancelled', 'ended' or 'missed'.
|
|
148
|
-
* @returns The CallLogRequestBuilder object.
|
|
149
|
-
*/
|
|
150
|
-
setCallStatus(callStatus: 'ongoing' | 'busy' | 'rejected' | 'cancelled' | 'ended' | 'missed'): this;
|
|
151
|
-
/**
|
|
152
|
-
* Sets whether the call has recording or not.
|
|
153
|
-
* @param hasRecording - Whether the call has recording or not.
|
|
154
|
-
* @returns The CallLogRequestBuilder object.
|
|
155
|
-
*/
|
|
156
|
-
setHasRecording(hasRecording: boolean): this;
|
|
157
|
-
/**
|
|
158
|
-
* Sets the category of call to be fetched.
|
|
159
|
-
* @param callCategory - The category of call to be fetched. Can be either 'call' or 'meet'.
|
|
160
|
-
* @returns The CallLogRequestBuilder object.
|
|
161
|
-
*/
|
|
162
|
-
setCallCategory(callCategory: 'call' | 'meet'): this;
|
|
163
|
-
/**
|
|
164
|
-
* Sets the direction of call to be fetched.
|
|
165
|
-
* @param callDirection - The direction of call to be fetched. Can be either 'incoming' or 'outgoing'.
|
|
166
|
-
* @returns The CallLogRequestBuilder object.
|
|
167
|
-
*/
|
|
168
|
-
setCallDirection(callDirection: 'incoming' | 'outgoing'): this;
|
|
169
|
-
/**
|
|
170
|
-
* Sets the user ID of the call logs to be fetched.
|
|
171
|
-
* @param uid - The user ID of the call logs to be fetched.
|
|
172
|
-
* @returns The CallLogRequestBuilder object.
|
|
173
|
-
*/
|
|
174
|
-
setUid(uid: string): this;
|
|
175
|
-
/**
|
|
176
|
-
* Sets the group ID of the call logs to be fetched.
|
|
177
|
-
* @param guid - The group ID of the call logs to be fetched.
|
|
178
|
-
* @returns The CallLogRequestBuilder object.
|
|
179
|
-
*/
|
|
180
|
-
setGuid(guid: string): this;
|
|
181
|
-
/**
|
|
182
|
-
* Sets the authorization token for the request.
|
|
183
|
-
* @param authToken - The authorization token for the request.
|
|
184
|
-
* @returns The CallLogRequestBuilder object.
|
|
185
|
-
*/
|
|
186
|
-
setAuthToken(authToken: string): this;
|
|
187
|
-
/**
|
|
188
|
-
* Builds and returns the CallLogRequest object.
|
|
189
|
-
* @returns The CallLogRequest object.
|
|
190
|
-
*/
|
|
191
|
-
build(): CallLogRequest;
|
|
192
|
-
}
|
|
193
|
-
export {};
|
|
@@ -1,110 +0,0 @@
|
|
|
1
|
-
import { ListenerHandlers } from './ListnerHandler';
|
|
2
|
-
import { AudioMode } from '../types/common';
|
|
3
|
-
import { CallAppSettings, CallAppSettingsBuilder } from './CallAppSettings';
|
|
4
|
-
import { CallSettings, CallSettingsBuilder } from './CallSettings';
|
|
5
|
-
import { CometChatCallsComponentCore as CometChatCallsComponent } from './CometChatCallsComponentCore';
|
|
6
|
-
import { CometChatPresenterComponent } from './CometChatPresenterComponent';
|
|
7
|
-
import { OngoingCallListener } from './Listner';
|
|
8
|
-
import { PresenterSettings, PresenterSettingsBuilder } from './PresenterSettings';
|
|
9
|
-
import { CallLog } from './CallLog';
|
|
10
|
-
import { CallLogRequestBuilder } from './CometChatCallLogs';
|
|
11
|
-
import { CallUser } from "./CallUser";
|
|
12
|
-
import { CallGroup } from "./CallGroup";
|
|
13
|
-
import { Participant } from './Participant';
|
|
14
|
-
import { Recording } from './Recording';
|
|
15
|
-
export declare class CometChatCalls {
|
|
16
|
-
private static appSettings;
|
|
17
|
-
private static inProgress;
|
|
18
|
-
static CALL_MODE: {
|
|
19
|
-
readonly DEFAULT: "DEFAULT";
|
|
20
|
-
readonly SPOTLIGHT: "SPOTLIGHT";
|
|
21
|
-
};
|
|
22
|
-
static AUDIO_MODE: {
|
|
23
|
-
readonly SPEAKER: "SPEAKER";
|
|
24
|
-
readonly EARPIECE: "EARPIECE";
|
|
25
|
-
readonly BLUETOOTH: "BLUETOOTH";
|
|
26
|
-
readonly HEADPHONES: "HEADPHONES";
|
|
27
|
-
};
|
|
28
|
-
static addCallEventListener: typeof ListenerHandlers.addCallEventListener;
|
|
29
|
-
static removeCallEventListener: typeof ListenerHandlers.removeCallEventListener;
|
|
30
|
-
static OngoingCallListener: typeof OngoingCallListener;
|
|
31
|
-
static CallSettingsBuilder: typeof CallSettingsBuilder;
|
|
32
|
-
static CallSettings: typeof CallSettings;
|
|
33
|
-
static PresenterSettingsBuilder: typeof PresenterSettingsBuilder;
|
|
34
|
-
static PresenterSettings: typeof PresenterSettings;
|
|
35
|
-
static CallAppSettingsBuilder: typeof CallAppSettingsBuilder;
|
|
36
|
-
static CallAppSettings: typeof CallAppSettings;
|
|
37
|
-
static Component: typeof CometChatCallsComponent;
|
|
38
|
-
static PresenterComponent: typeof CometChatPresenterComponent;
|
|
39
|
-
static CallLogRequestBuilder: typeof CallLogRequestBuilder;
|
|
40
|
-
static CallLog: typeof CallLog;
|
|
41
|
-
static CallUser: typeof CallUser;
|
|
42
|
-
static CallGroup: typeof CallGroup;
|
|
43
|
-
static Participant: typeof Participant;
|
|
44
|
-
static Recording: typeof Recording;
|
|
45
|
-
static generateToken(sessionID: string, authToken: string): Promise<{
|
|
46
|
-
token: string;
|
|
47
|
-
}>;
|
|
48
|
-
static init(appSettings: CallAppSettings): Promise<void>;
|
|
49
|
-
/**
|
|
50
|
-
* Method end on-going call.
|
|
51
|
-
* @returns {void}
|
|
52
|
-
*/
|
|
53
|
-
static endSession(): void;
|
|
54
|
-
/**
|
|
55
|
-
* Method to mute/unmute audio stream.
|
|
56
|
-
* @param {boolean} muteAudio
|
|
57
|
-
* @returns {void}
|
|
58
|
-
*/
|
|
59
|
-
static muteAudio(muteAudio: boolean): void;
|
|
60
|
-
/**
|
|
61
|
-
* Method to pause/unpause video stream.
|
|
62
|
-
* @param {boolean} pauseVideo
|
|
63
|
-
* @returns {void}
|
|
64
|
-
*/
|
|
65
|
-
static pauseVideo(pauseVideo: boolean): void;
|
|
66
|
-
/**
|
|
67
|
-
* Method to resume video stream.
|
|
68
|
-
* @returns {void}
|
|
69
|
-
*/
|
|
70
|
-
static resumeVideo(): void;
|
|
71
|
-
/**
|
|
72
|
-
* Method to set audio mode.
|
|
73
|
-
* @param {string} mode
|
|
74
|
-
* @returns {void}
|
|
75
|
-
*/
|
|
76
|
-
static setAudioMode(mode: string): void;
|
|
77
|
-
/**
|
|
78
|
-
* Method to switch camera.
|
|
79
|
-
* @returns {void}
|
|
80
|
-
*/
|
|
81
|
-
static switchCamera(): void;
|
|
82
|
-
/**
|
|
83
|
-
* Method to get all the available audio output devices.
|
|
84
|
-
* @returns {Promise<AudioMode[]>}
|
|
85
|
-
*/
|
|
86
|
-
static getAudioOutputModes(): Promise<AudioMode[]>;
|
|
87
|
-
/**
|
|
88
|
-
* Method to switch from audio call to video call.
|
|
89
|
-
* @returns {void}
|
|
90
|
-
*/
|
|
91
|
-
static switchToVideoCall(): void;
|
|
92
|
-
/**
|
|
93
|
-
* Method to Start Call Recording.
|
|
94
|
-
* @returns {void}
|
|
95
|
-
*/
|
|
96
|
-
static startRecording(): void;
|
|
97
|
-
/**
|
|
98
|
-
* Method to Stop Call Recording.
|
|
99
|
-
* @returns {void}
|
|
100
|
-
*/
|
|
101
|
-
static stopRecording(): void;
|
|
102
|
-
/**
|
|
103
|
-
* Retrieves call details for a given session ID and auth token.
|
|
104
|
-
* @param sessionID - The session ID of the call.
|
|
105
|
-
* @param authToken - The authentication token required to make the API call.
|
|
106
|
-
* @returns A Promise that resolves to a CallLog object containing the call details.
|
|
107
|
-
* @throws {CometChatCallsException} If there is an error retrieving the call details.
|
|
108
|
-
*/
|
|
109
|
-
static getCallDetails(sessionID: string, authToken: string): Promise<Array<CallLog>>;
|
|
110
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { CallSettings } from './CallSettings';
|
|
3
|
-
type MyState = {
|
|
4
|
-
errored: boolean;
|
|
5
|
-
};
|
|
6
|
-
export declare class CometChatCallsComponent extends React.Component<{
|
|
7
|
-
callSettings: CallSettings;
|
|
8
|
-
callToken: string;
|
|
9
|
-
}, MyState> {
|
|
10
|
-
constructor(props: any);
|
|
11
|
-
render(): JSX.Element;
|
|
12
|
-
}
|
|
13
|
-
export {};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { CallSettings } from './CallSettings';
|
|
3
|
-
import { PresenterSettings } from './PresenterSettings';
|
|
4
|
-
type MyState = {
|
|
5
|
-
shouldLoad: boolean;
|
|
6
|
-
errored: boolean;
|
|
7
|
-
};
|
|
8
|
-
export declare class CometChatCallsComponentCore extends React.Component<{
|
|
9
|
-
callSettings: CallSettings | PresenterSettings;
|
|
10
|
-
callToken: string;
|
|
11
|
-
presenterMode?: boolean;
|
|
12
|
-
}, MyState> {
|
|
13
|
-
static ref: any;
|
|
14
|
-
callsettings: CallSettings | PresenterSettings;
|
|
15
|
-
constructor(props: any);
|
|
16
|
-
render(): JSX.Element;
|
|
17
|
-
}
|
|
18
|
-
export {};
|