vani-meeting-client 1.7.5 → 1.7.6
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/lib/MeetingHandler.d.ts +1 -0
- package/lib/MeetingHandler.js +7 -0
- package/lib/inter-communication-handler/CommunicationHandler.d.ts +1 -0
- package/lib/inter-communication-handler/CommunicationHandler.js +7 -0
- package/lib/model/MeetingStartRequest.js +1 -1
- package/lib/utility/DynamicLibHelper.js +2 -3
- package/lib/video-call-handler/BaseVideoCallHandler.d.ts +1 -0
- package/lib/video-call-handler/BaseVideoCallHandler.js +2 -0
- package/lib/video-call-handler/SFUHandler.d.ts +1 -0
- package/lib/video-call-handler/SFUHandler.js +4 -6
- package/lib/websocket-handler/WebsocketHandler.d.ts +1 -0
- package/lib/websocket-handler/WebsocketHandler.js +1 -0
- package/package.json +1 -2
package/lib/MeetingHandler.d.ts
CHANGED
|
@@ -48,6 +48,7 @@ export declare class MeetingHandler {
|
|
|
48
48
|
getMeetingStartTime(): Promise<void>;
|
|
49
49
|
startRTMPStream(urls: string[]): Promise<void>;
|
|
50
50
|
getEventEmitter(): VaniEventListener | undefined;
|
|
51
|
+
restartTransport: () => Promise<void>;
|
|
51
52
|
private emitMessageToSource;
|
|
52
53
|
private cleanup;
|
|
53
54
|
private handleGA;
|
package/lib/MeetingHandler.js
CHANGED
|
@@ -50,6 +50,13 @@ var MeetingHandler = /** @class */ (function () {
|
|
|
50
50
|
var _a;
|
|
51
51
|
(_a = _this.communicationHandler) === null || _a === void 0 ? void 0 : _a.requestToCloseTheRoom();
|
|
52
52
|
};
|
|
53
|
+
this.restartTransport = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
54
|
+
var _a;
|
|
55
|
+
return __generator(this, function (_b) {
|
|
56
|
+
(_a = this.communicationHandler) === null || _a === void 0 ? void 0 : _a.restartTransport();
|
|
57
|
+
return [2 /*return*/];
|
|
58
|
+
});
|
|
59
|
+
}); };
|
|
53
60
|
}
|
|
54
61
|
MeetingHandler.prototype.meetingStartRequestObject = function (roomId, userId, appId, wssUrl) {
|
|
55
62
|
if (!this.meetingStartRequest) {
|
|
@@ -24,6 +24,7 @@ export declare class CommunicationHandler {
|
|
|
24
24
|
emitMessageToSource(emitType: VaniEvent, payload: any): Promise<void>;
|
|
25
25
|
getEventEmitter(): VaniEventListener;
|
|
26
26
|
onAudioVideoStatusUpdated(data: any): void;
|
|
27
|
+
restartTransport: () => Promise<void>;
|
|
27
28
|
getSelfParticipant(): Participant | undefined;
|
|
28
29
|
downloadParticipantsData(): void;
|
|
29
30
|
onServerParticipants(data: any): void;
|
|
@@ -50,6 +50,13 @@ var CommunicationHandler = /** @class */ (function () {
|
|
|
50
50
|
this.selfTracks = [];
|
|
51
51
|
this.allTracks = [];
|
|
52
52
|
this.isReachable = true;
|
|
53
|
+
this.restartTransport = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
54
|
+
var _a;
|
|
55
|
+
return __generator(this, function (_b) {
|
|
56
|
+
(_a = this.videoCallHandler) === null || _a === void 0 ? void 0 : _a.restartTransport();
|
|
57
|
+
return [2 /*return*/];
|
|
58
|
+
});
|
|
59
|
+
}); };
|
|
53
60
|
this.requestToCloseTheRoom = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
54
61
|
var _a;
|
|
55
62
|
return __generator(this, function (_b) {
|
|
@@ -47,7 +47,7 @@ var MeetingStartRequest = /** @class */ (function () {
|
|
|
47
47
|
this.connectionProtocol = ConnectionProtocol.UDP;
|
|
48
48
|
this.shouldKeepTryToReconnect = false;
|
|
49
49
|
this.urlToCheckInternetPresent = "https://en.wikipedia.org/w/api.php?format=json&action=query&prop=extracts&exintro&explaintext&redirects=1&titles=Stack%20Overflow";
|
|
50
|
-
this.roomId = _roomId.
|
|
50
|
+
this.roomId = _roomId.toUpperCase();
|
|
51
51
|
this.userId = _userId;
|
|
52
52
|
this.appId = _appId;
|
|
53
53
|
if (_wssUrl.indexOf("connection=") < 0) {
|
|
@@ -41,13 +41,12 @@ var DynamicLibHelper = /** @class */ (function () {
|
|
|
41
41
|
}
|
|
42
42
|
DynamicLibHelper.prototype.getReactNativeWebrtcPlugin = function (meetingStartRequest) {
|
|
43
43
|
return __awaiter(this, void 0, void 0, function () {
|
|
44
|
-
var
|
|
44
|
+
var libName;
|
|
45
45
|
return __generator(this, function (_a) {
|
|
46
46
|
try {
|
|
47
47
|
if (meetingStartRequest.isMobileApp) {
|
|
48
|
-
optionalRequire = require('optional-require');
|
|
49
48
|
libName = 'react-native-webrtc';
|
|
50
|
-
return [2 /*return*/,
|
|
49
|
+
return [2 /*return*/, (require(libName))];
|
|
51
50
|
}
|
|
52
51
|
}
|
|
53
52
|
catch (_b) {
|
|
@@ -90,6 +90,8 @@ var BaseVideoCallHandler = /** @class */ (function (_super) {
|
|
|
90
90
|
BaseVideoCallHandler.prototype.cleanup = function () {
|
|
91
91
|
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && log.info("cleanup ");
|
|
92
92
|
};
|
|
93
|
+
BaseVideoCallHandler.prototype.restartTransport = function () {
|
|
94
|
+
};
|
|
93
95
|
return BaseVideoCallHandler;
|
|
94
96
|
}(Base));
|
|
95
97
|
export { BaseVideoCallHandler };
|
|
@@ -34,6 +34,7 @@ export declare class SFUHandler extends BaseVideoCallHandler {
|
|
|
34
34
|
sendMessageViaDataChannel(messagePayload: any): void;
|
|
35
35
|
init(): Promise<void>;
|
|
36
36
|
private onTransportNotFound;
|
|
37
|
+
restartTransport(): void;
|
|
37
38
|
private addObserverForDevice;
|
|
38
39
|
private onAllProducers;
|
|
39
40
|
private onRouterRtpCapabilities;
|
|
@@ -408,11 +408,6 @@ var SFUHandler = /** @class */ (function (_super) {
|
|
|
408
408
|
for (_i = 0, _b = this.producers; _i < _b.length; _i++) {
|
|
409
409
|
producer = _b[_i];
|
|
410
410
|
if (producer) {
|
|
411
|
-
// try {
|
|
412
|
-
// producer.track?.stop()
|
|
413
|
-
// }
|
|
414
|
-
// catch (err) {
|
|
415
|
-
// }
|
|
416
411
|
producer.close();
|
|
417
412
|
}
|
|
418
413
|
}
|
|
@@ -438,12 +433,15 @@ var SFUHandler = /** @class */ (function (_super) {
|
|
|
438
433
|
this.sendTransport = undefined;
|
|
439
434
|
}
|
|
440
435
|
this.isProduceTrackIntialWorkDone = false;
|
|
441
|
-
messageJson = { to: "self", type: SFUMessageType.
|
|
436
|
+
messageJson = { to: "self", type: SFUMessageType.OnCreateTransportsForcefully, message: SFUMessageType.OnCreateTransportsForcefully };
|
|
442
437
|
this.sendSFUMessageToSocket(messageJson);
|
|
443
438
|
return [2 /*return*/];
|
|
444
439
|
});
|
|
445
440
|
});
|
|
446
441
|
};
|
|
442
|
+
SFUHandler.prototype.restartTransport = function () {
|
|
443
|
+
this.onTransportNotFound(undefined);
|
|
444
|
+
};
|
|
447
445
|
SFUHandler.prototype.addObserverForDevice = function () {
|
|
448
446
|
return __awaiter(this, void 0, void 0, function () {
|
|
449
447
|
var _this = this;
|
|
@@ -58,6 +58,7 @@ export declare enum SFUMessageType {
|
|
|
58
58
|
UpdateSpatialConsumer = "updateSpatialConsumer",
|
|
59
59
|
OnRestartIceCandidateResponse = "onRestartIceCandidate",
|
|
60
60
|
OnTransportNotFound = "onTransportNotFound",
|
|
61
|
+
OnCreateTransportsForcefully = "OnCreateTransportsForcefully",
|
|
61
62
|
GetAllProducers = "getAllProducers",
|
|
62
63
|
OnAllProducers = "onAllProducers",
|
|
63
64
|
OnAudioVolumeChanged = "OnAudioVolumeChanged",
|
|
@@ -114,6 +114,7 @@ export var SFUMessageType;
|
|
|
114
114
|
SFUMessageType["UpdateSpatialConsumer"] = "updateSpatialConsumer";
|
|
115
115
|
SFUMessageType["OnRestartIceCandidateResponse"] = "onRestartIceCandidate";
|
|
116
116
|
SFUMessageType["OnTransportNotFound"] = "onTransportNotFound";
|
|
117
|
+
SFUMessageType["OnCreateTransportsForcefully"] = "OnCreateTransportsForcefully";
|
|
117
118
|
SFUMessageType["GetAllProducers"] = "getAllProducers";
|
|
118
119
|
SFUMessageType["OnAllProducers"] = "onAllProducers";
|
|
119
120
|
SFUMessageType["OnAudioVolumeChanged"] = "OnAudioVolumeChanged";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vani-meeting-client",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.6",
|
|
4
4
|
"description": "Vani Meeting Clinet SDK",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
@@ -47,7 +47,6 @@
|
|
|
47
47
|
"axios": "^0.24.0",
|
|
48
48
|
"loglevel": "^1.8.0",
|
|
49
49
|
"mediasoup-client": "^3.7.16",
|
|
50
|
-
"optional-require": "^1.1.8",
|
|
51
50
|
"react-native-google-analytics-bridge": "^7.1.0"
|
|
52
51
|
},
|
|
53
52
|
"optionalDependencies": {}
|