@videosdk.live/react-sdk 0.1.78 → 0.1.80

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.
@@ -297,7 +297,7 @@ var MeetingConsumer = function MeetingConsumer(_ref2) {
297
297
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(MeetingProviderContex.Consumer, null, children));
298
298
  };
299
299
 
300
- var version = "0.1.78";
300
+ var version = "0.1.80";
301
301
 
302
302
  var MeetingProvider = function MeetingProvider(_ref) {
303
303
  var children = _ref.children,
@@ -1202,6 +1202,14 @@ var useParticipant = function useParticipant(participantId, _temp) {
1202
1202
  var remove = function remove() {
1203
1203
  participant === null || participant === void 0 ? void 0 : participant.remove();
1204
1204
  };
1205
+ var captureImage = function captureImage(_ref2) {
1206
+ var height = _ref2.height,
1207
+ width = _ref2.width;
1208
+ return Promise.resolve(participant === null || participant === void 0 ? void 0 : participant.captureImage({
1209
+ height: height,
1210
+ width: width
1211
+ }));
1212
+ };
1205
1213
  var getAudioStats = function getAudioStats() {
1206
1214
  return Promise.resolve(participant === null || participant === void 0 ? void 0 : participant.getAudioStats());
1207
1215
  };
@@ -1278,6 +1286,7 @@ var useParticipant = function useParticipant(participantId, _temp) {
1278
1286
  disableMic: disableMic,
1279
1287
  enableWebcam: enableWebcam,
1280
1288
  disableWebcam: disableWebcam,
1289
+ captureImage: captureImage,
1281
1290
  pin: pin,
1282
1291
  unpin: unpin,
1283
1292
  remove: remove,
@@ -1414,6 +1423,40 @@ var usePubSub = function usePubSub(topic, _temp) {
1414
1423
  };
1415
1424
  };
1416
1425
 
1426
+ var useFile = function useFile() {
1427
+ var mMeeting = useMeeting();
1428
+ var uploadBase64File = function uploadBase64File(_ref) {
1429
+ var base64Data = _ref.base64Data,
1430
+ token = _ref.token,
1431
+ fileName = _ref.fileName;
1432
+ try {
1433
+ return Promise.resolve(mMeeting.meeting.uploadBase64File({
1434
+ base64Data: base64Data,
1435
+ token: token,
1436
+ fileName: fileName
1437
+ }));
1438
+ } catch (e) {
1439
+ return Promise.reject(e);
1440
+ }
1441
+ };
1442
+ var fetchBase64File = function fetchBase64File(_ref2) {
1443
+ var url = _ref2.url,
1444
+ token = _ref2.token;
1445
+ try {
1446
+ return Promise.resolve(mMeeting.meeting.fetchBase64File({
1447
+ url: url,
1448
+ token: token
1449
+ }));
1450
+ } catch (e) {
1451
+ return Promise.reject(e);
1452
+ }
1453
+ };
1454
+ return {
1455
+ uploadBase64File: uploadBase64File,
1456
+ fetchBase64File: fetchBase64File
1457
+ };
1458
+ };
1459
+
1417
1460
  var Constants = VideoSDK.Constants;
1418
1461
  var createCameraVideoTrack = function createCameraVideoTrack(_ref) {
1419
1462
  var _ref$cameraId = _ref.cameraId,
@@ -1473,5 +1516,5 @@ var createMicrophoneAudioTrack = function createMicrophoneAudioTrack(_ref3) {
1473
1516
  }
1474
1517
  };
1475
1518
 
1476
- export { Constants, MeetingConsumer, MeetingProvider, createCameraVideoTrack, createMicrophoneAudioTrack, createScreenShareVideoTrack, useConnection, useMeeting, useParticipant, usePubSub };
1519
+ export { Constants, MeetingConsumer, MeetingProvider, createCameraVideoTrack, createMicrophoneAudioTrack, createScreenShareVideoTrack, useConnection, useFile, useMeeting, useParticipant, usePubSub };
1477
1520
  //# sourceMappingURL=index.modern.js.map