@microsoft/teams-js 2.0.0-beta.6-dev.11 → 2.0.0-beta.6-dev.14

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.
@@ -1122,7 +1122,7 @@ __webpack_require__.d(__webpack_exports__, {
1122
1122
  });
1123
1123
 
1124
1124
  ;// CONCATENATED MODULE: ./src/internal/constants.ts
1125
- var version = "2.0.0-beta.6-dev.11";
1125
+ var version = "2.0.0-beta.6-dev.14";
1126
1126
  /**
1127
1127
  * @hidden
1128
1128
  * The client version when all SDK APIs started to check platform compatibility for the APIs was 1.6.0.
@@ -1348,6 +1348,7 @@ var HostClientType;
1348
1348
  HostClientType["web"] = "web";
1349
1349
  HostClientType["android"] = "android";
1350
1350
  HostClientType["ios"] = "ios";
1351
+ HostClientType["ipados"] = "ipados";
1351
1352
  /**
1352
1353
  * @deprecated
1353
1354
  * As of 2.0.0-beta.1, please use {@link teamsRoomsWindows} instead.
@@ -2572,6 +2573,9 @@ var dialog;
2572
2573
  */
2573
2574
  function open(urlDialogInfo, submitHandler, messageFromChildHandler) {
2574
2575
  ensureInitialized(FrameContexts.content, FrameContexts.sidePanel, FrameContexts.meetingStage);
2576
+ if (!isSupported()) {
2577
+ throw errorNotSupportedOnPlatform;
2578
+ }
2575
2579
  if (messageFromChildHandler) {
2576
2580
  registerHandler('messageForParent', messageFromChildHandler);
2577
2581
  }
@@ -2590,6 +2594,9 @@ var dialog;
2590
2594
  */
2591
2595
  function submit(result, appIds) {
2592
2596
  ensureInitialized(FrameContexts.content, FrameContexts.sidePanel, FrameContexts.task, FrameContexts.meetingStage);
2597
+ if (!isSupported()) {
2598
+ throw errorNotSupportedOnPlatform;
2599
+ }
2593
2600
  // Send tasks.completeTask instead of tasks.submitTask message for backward compatibility with Mobile clients
2594
2601
  sendMessageToParent('tasks.completeTask', [result, appIds ? (Array.isArray(appIds) ? appIds : [appIds]) : []]);
2595
2602
  }
@@ -2606,6 +2613,9 @@ var dialog;
2606
2613
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
2607
2614
  message) {
2608
2615
  ensureInitialized(FrameContexts.task);
2616
+ if (!isSupported()) {
2617
+ throw errorNotSupportedOnPlatform;
2618
+ }
2609
2619
  sendMessageToParent('messageForParent', [message]);
2610
2620
  }
2611
2621
  dialog.sendMessageToParentFromDialog = sendMessageToParentFromDialog;
@@ -2618,6 +2628,9 @@ var dialog;
2618
2628
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
2619
2629
  message) {
2620
2630
  ensureInitialized(FrameContexts.content, FrameContexts.sidePanel, FrameContexts.meetingStage);
2631
+ if (!isSupported()) {
2632
+ throw errorNotSupportedOnPlatform;
2633
+ }
2621
2634
  sendMessageToParent('messageForChild', [message]);
2622
2635
  }
2623
2636
  dialog.sendMessageToDialog = sendMessageToDialog;
@@ -2631,6 +2644,9 @@ var dialog;
2631
2644
  */
2632
2645
  function registerOnMessageFromParent(listener) {
2633
2646
  ensureInitialized(FrameContexts.task);
2647
+ if (!isSupported()) {
2648
+ throw errorNotSupportedOnPlatform;
2649
+ }
2634
2650
  // We need to remove the original 'messageForChild'
2635
2651
  // handler since the original does not allow for post messages.
2636
2652
  // It is replaced by the user specified listener that is passed in.
@@ -2664,6 +2680,9 @@ var dialog;
2664
2680
  */
2665
2681
  function resize(dimensions) {
2666
2682
  ensureInitialized(FrameContexts.content, FrameContexts.sidePanel, FrameContexts.task, FrameContexts.meetingStage);
2683
+ if (!isSupported()) {
2684
+ throw errorNotSupportedOnPlatform;
2685
+ }
2667
2686
  sendMessageToParent('tasks.updateTask', [dimensions]);
2668
2687
  }
2669
2688
  update.resize = resize;
@@ -2693,6 +2712,9 @@ var dialog;
2693
2712
  */
2694
2713
  function open(botUrlDialogInfo, submitHandler, messageFromChildHandler) {
2695
2714
  ensureInitialized(FrameContexts.content, FrameContexts.sidePanel, FrameContexts.meetingStage);
2715
+ if (!isSupported()) {
2716
+ throw errorNotSupportedOnPlatform;
2717
+ }
2696
2718
  if (messageFromChildHandler) {
2697
2719
  registerHandler('messageForParent', messageFromChildHandler);
2698
2720
  }
@@ -2890,8 +2912,6 @@ var menus;
2890
2912
 
2891
2913
  /**
2892
2914
  * Namespace containing the set of APIs that support Teams-specific functionalities.
2893
- *
2894
- * @alpha
2895
2915
  */
2896
2916
  var teamsCore;
2897
2917
  (function (teamsCore) {
@@ -3349,7 +3369,7 @@ var pages;
3349
3369
  * @param navigateForward - Determines the direction to focus in host.
3350
3370
  */
3351
3371
  function returnFocus(navigateForward) {
3352
- ensureInitialized(FrameContexts.content);
3372
+ ensureInitialized();
3353
3373
  sendMessageToParent('returnFocus', [navigateForward]);
3354
3374
  }
3355
3375
  pages.returnFocus = returnFocus;
@@ -4393,9 +4413,6 @@ var logs;
4393
4413
  })(logs || (logs = {}));
4394
4414
 
4395
4415
  ;// CONCATENATED MODULE: ./src/private/interfaces.ts
4396
- /**
4397
- * @alpha
4398
- */
4399
4416
  var NotificationTypes;
4400
4417
  (function (NotificationTypes) {
4401
4418
  NotificationTypes["fileDownloadStart"] = "fileDownloadStart";
@@ -4404,8 +4421,6 @@ var NotificationTypes;
4404
4421
  /**
4405
4422
  * @hidden
4406
4423
  * Hide from docs.
4407
- * ------
4408
- * @alpha
4409
4424
  */
4410
4425
  var ViewerActionTypes;
4411
4426
  (function (ViewerActionTypes) {
@@ -4417,8 +4432,7 @@ var ViewerActionTypes;
4417
4432
  * @hidden
4418
4433
  * Hide from docs.
4419
4434
  * ------
4420
- * User setting changes that can be subscribed to,
4421
- * @alpha
4435
+ * User setting changes that can be subscribed to
4422
4436
  */
4423
4437
  var UserSettingTypes;
4424
4438
  (function (UserSettingTypes) {
@@ -4443,8 +4457,6 @@ var UserSettingTypes;
4443
4457
  /**
4444
4458
  * @hidden
4445
4459
  * Namespace to interact with the conversational subEntities inside the tab
4446
- *
4447
- * @alpha
4448
4460
  */
4449
4461
  var conversations;
4450
4462
  (function (conversations) {
@@ -4611,9 +4623,6 @@ function createTeamsDeepLinkForAppInstallDialog(appId) {
4611
4623
 
4612
4624
 
4613
4625
 
4614
- /**
4615
- * @alpha
4616
- */
4617
4626
  var appInstallDialog;
4618
4627
  (function (appInstallDialog) {
4619
4628
  function openAppInstallDialog(openAPPInstallDialogParams) {
@@ -5465,9 +5474,6 @@ var media;
5465
5474
 
5466
5475
 
5467
5476
 
5468
- /**
5469
- * @alpha
5470
- */
5471
5477
  var location_location;
5472
5478
  (function (location_1) {
5473
5479
  function getLocation(props, callback) {
@@ -5590,7 +5596,7 @@ var meeting;
5590
5596
  *
5591
5597
  * @param callback - Callback contains 2 parameters, error and meetingDetailsResponse.
5592
5598
  * error can either contain an error of type SdkError, incase of an error, or null when get is successful
5593
- * result can either contain a IMeetingDetailsResponse value, incase of a successful get or null when the get fails
5599
+ * result can either contain a IMeetingDetailsResponse value, in case of a successful get or null when the get fails
5594
5600
  *
5595
5601
  * @internal
5596
5602
  */
@@ -5803,9 +5809,6 @@ var meeting;
5803
5809
 
5804
5810
 
5805
5811
 
5806
- /**
5807
- * @alpha
5808
- */
5809
5812
  var monetization;
5810
5813
  (function (monetization) {
5811
5814
  /**
@@ -5848,9 +5851,6 @@ var monetization;
5848
5851
 
5849
5852
 
5850
5853
 
5851
- /**
5852
- * @alpha
5853
- */
5854
5854
  var calendar;
5855
5855
  (function (calendar) {
5856
5856
  function openCalendarItem(openCalendarItemParams) {
@@ -5892,9 +5892,6 @@ var calendar;
5892
5892
 
5893
5893
 
5894
5894
 
5895
- /**
5896
- * @alpha
5897
- */
5898
5895
  var mail;
5899
5896
  (function (mail) {
5900
5897
  function openMailItem(openMailItemParams) {
@@ -5942,9 +5939,6 @@ var mail;
5942
5939
 
5943
5940
 
5944
5941
 
5945
- /**
5946
- * @alpha
5947
- */
5948
5942
  var people;
5949
5943
  (function (people_1) {
5950
5944
  /**
@@ -5978,6 +5972,9 @@ var people;
5978
5972
  if (!validatePeoplePickerInput(peoplePickerInputs)) {
5979
5973
  throw { errorCode: ErrorCode.INVALID_ARGUMENTS };
5980
5974
  }
5975
+ if (!isSupported()) {
5976
+ throw errorNotSupportedOnPlatform;
5977
+ }
5981
5978
  resolve(sendAndHandleSdkError('people.selectPeople', peoplePickerInputs));
5982
5979
  });
5983
5980
  }
@@ -5994,10 +5991,7 @@ var people;
5994
5991
 
5995
5992
 
5996
5993
  /**
5997
- * Namespace to video extensibility of the SDK.
5998
- *
5999
- * @alpha
6000
- *
5994
+ * Namespace to video extensibility of the SDK
6001
5995
  */
6002
5996
  var video;
6003
5997
  (function (video) {
@@ -6014,7 +6008,7 @@ var video;
6014
6008
  var EffectChangeType;
6015
6009
  (function (EffectChangeType) {
6016
6010
  /**
6017
- * current video effect changed.
6011
+ * current video effect changed
6018
6012
  */
6019
6013
  EffectChangeType[EffectChangeType["EffectChanged"] = 0] = "EffectChanged";
6020
6014
  /**
@@ -6023,10 +6017,13 @@ var video;
6023
6017
  EffectChangeType[EffectChangeType["EffectDisabled"] = 1] = "EffectDisabled";
6024
6018
  })(EffectChangeType = video.EffectChangeType || (video.EffectChangeType = {}));
6025
6019
  /**
6026
- * register to read the video frames in Permissions section.
6020
+ * Register to read the video frames in Permissions section
6027
6021
  */
6028
6022
  function registerForVideoFrame(frameCallback, config) {
6029
6023
  ensureInitialized(FrameContexts.sidePanel);
6024
+ if (!isSupported()) {
6025
+ throw errorNotSupportedOnPlatform;
6026
+ }
6030
6027
  registerHandler('video.newVideoFrame', function (videoFrame) {
6031
6028
  if (videoFrame !== undefined) {
6032
6029
  frameCallback(videoFrame, notifyVideoFrameProcessed, notifyError);
@@ -6045,26 +6042,32 @@ var video;
6045
6042
  */
6046
6043
  function notifySelectedVideoEffectChanged(effectChangeType, effectId) {
6047
6044
  ensureInitialized(FrameContexts.sidePanel);
6045
+ if (!isSupported()) {
6046
+ throw errorNotSupportedOnPlatform;
6047
+ }
6048
6048
  sendMessageToParent('video.videoEffectChanged', [effectChangeType, effectId]);
6049
6049
  }
6050
6050
  video.notifySelectedVideoEffectChanged = notifySelectedVideoEffectChanged;
6051
6051
  /**
6052
- * Register the video effect callback, Teams client uses this to notify the video extension the new video effect will by applied.
6052
+ * Register the video effect callback, Teams client uses this to notify the video extension the new video effect will by applied
6053
6053
  */
6054
6054
  function registerForVideoEffect(callback) {
6055
6055
  ensureInitialized(FrameContexts.sidePanel);
6056
+ if (!isSupported()) {
6057
+ throw errorNotSupportedOnPlatform;
6058
+ }
6056
6059
  registerHandler('video.effectParameterChange', callback);
6057
6060
  }
6058
6061
  video.registerForVideoEffect = registerForVideoEffect;
6059
6062
  /**
6060
- * sending notification to Teams client finished the video frame processing, now Teams client can render this video frame
6061
- * or pass the video frame to next one in video pipeline.
6063
+ * Sending notification to Teams client finished the video frame processing, now Teams client can render this video frame
6064
+ * or pass the video frame to next one in video pipeline
6062
6065
  */
6063
6066
  function notifyVideoFrameProcessed() {
6064
6067
  sendMessageToParent('video.videoFrameProcessed');
6065
6068
  }
6066
6069
  /**
6067
- * sending error notification to Teams client.
6070
+ * Sending error notification to Teams client
6068
6071
  */
6069
6072
  function notifyError(errorMessage) {
6070
6073
  sendMessageToParent('video.notifyError', [errorMessage]);
@@ -6082,9 +6085,6 @@ var video;
6082
6085
 
6083
6086
 
6084
6087
 
6085
- /**
6086
- * @alpha
6087
- */
6088
6088
  var sharing;
6089
6089
  (function (sharing) {
6090
6090
  sharing.SharingAPIMessages = {
@@ -6198,9 +6198,6 @@ var stageView;
6198
6198
 
6199
6199
 
6200
6200
 
6201
- /**
6202
- * @alpha
6203
- */
6204
6201
  var call;
6205
6202
  (function (call) {
6206
6203
  var CallModalities;
@@ -7372,9 +7369,6 @@ var legacy;
7372
7369
 
7373
7370
 
7374
7371
 
7375
- /**
7376
- * @alpha
7377
- */
7378
7372
  var meetingRoom;
7379
7373
  (function (meetingRoom) {
7380
7374
  /**
@@ -7506,9 +7500,6 @@ var notifications;
7506
7500
 
7507
7501
 
7508
7502
 
7509
- /**
7510
- * @alpha
7511
- */
7512
7503
  var remoteCamera;
7513
7504
  (function (remoteCamera) {
7514
7505
  /**
@@ -7580,6 +7571,9 @@ var remoteCamera;
7580
7571
  throw new Error('[remoteCamera.getCapableParticipants] Callback cannot be null');
7581
7572
  }
7582
7573
  ensureInitialized(FrameContexts.sidePanel);
7574
+ if (!isSupported()) {
7575
+ throw errorNotSupportedOnPlatform;
7576
+ }
7583
7577
  sendMessageToParent('remoteCamera.getCapableParticipants', callback);
7584
7578
  }
7585
7579
  remoteCamera.getCapableParticipants = getCapableParticipants;
@@ -7603,6 +7597,9 @@ var remoteCamera;
7603
7597
  throw new Error('[remoteCamera.requestControl] Callback cannot be null');
7604
7598
  }
7605
7599
  ensureInitialized(FrameContexts.sidePanel);
7600
+ if (!isSupported()) {
7601
+ throw errorNotSupportedOnPlatform;
7602
+ }
7606
7603
  sendMessageToParent('remoteCamera.requestControl', [participant], callback);
7607
7604
  }
7608
7605
  remoteCamera.requestControl = requestControl;
@@ -7623,6 +7620,9 @@ var remoteCamera;
7623
7620
  throw new Error('[remoteCamera.sendControlCommand] Callback cannot be null');
7624
7621
  }
7625
7622
  ensureInitialized(FrameContexts.sidePanel);
7623
+ if (!isSupported()) {
7624
+ throw errorNotSupportedOnPlatform;
7625
+ }
7626
7626
  sendMessageToParent('remoteCamera.sendControlCommand', [ControlCommand], callback);
7627
7627
  }
7628
7628
  remoteCamera.sendControlCommand = sendControlCommand;
@@ -7639,6 +7639,9 @@ var remoteCamera;
7639
7639
  throw new Error('[remoteCamera.terminateSession] Callback cannot be null');
7640
7640
  }
7641
7641
  ensureInitialized(FrameContexts.sidePanel);
7642
+ if (!isSupported()) {
7643
+ throw errorNotSupportedOnPlatform;
7644
+ }
7642
7645
  sendMessageToParent('remoteCamera.terminateSession', callback);
7643
7646
  }
7644
7647
  remoteCamera.terminateSession = terminateSession;
@@ -7654,6 +7657,9 @@ var remoteCamera;
7654
7657
  throw new Error('[remoteCamera.registerOnCapableParticipantsChangeHandler] Handler cannot be null');
7655
7658
  }
7656
7659
  ensureInitialized(FrameContexts.sidePanel);
7660
+ if (!isSupported()) {
7661
+ throw errorNotSupportedOnPlatform;
7662
+ }
7657
7663
  registerHandler('remoteCamera.capableParticipantsChange', handler);
7658
7664
  }
7659
7665
  remoteCamera.registerOnCapableParticipantsChangeHandler = registerOnCapableParticipantsChangeHandler;
@@ -7669,6 +7675,9 @@ var remoteCamera;
7669
7675
  throw new Error('[remoteCamera.registerOnErrorHandler] Handler cannot be null');
7670
7676
  }
7671
7677
  ensureInitialized(FrameContexts.sidePanel);
7678
+ if (!isSupported()) {
7679
+ throw errorNotSupportedOnPlatform;
7680
+ }
7672
7681
  registerHandler('remoteCamera.handlerError', handler);
7673
7682
  }
7674
7683
  remoteCamera.registerOnErrorHandler = registerOnErrorHandler;
@@ -7684,6 +7693,9 @@ var remoteCamera;
7684
7693
  throw new Error('[remoteCamera.registerOnDeviceStateChangeHandler] Handler cannot be null');
7685
7694
  }
7686
7695
  ensureInitialized(FrameContexts.sidePanel);
7696
+ if (!isSupported()) {
7697
+ throw errorNotSupportedOnPlatform;
7698
+ }
7687
7699
  registerHandler('remoteCamera.deviceStateChange', handler);
7688
7700
  }
7689
7701
  remoteCamera.registerOnDeviceStateChangeHandler = registerOnDeviceStateChangeHandler;
@@ -7699,6 +7711,9 @@ var remoteCamera;
7699
7711
  throw new Error('[remoteCamera.registerOnSessionStatusChangeHandler] Handler cannot be null');
7700
7712
  }
7701
7713
  ensureInitialized(FrameContexts.sidePanel);
7714
+ if (!isSupported()) {
7715
+ throw errorNotSupportedOnPlatform;
7716
+ }
7702
7717
  registerHandler('remoteCamera.sessionStatusChange', handler);
7703
7718
  }
7704
7719
  remoteCamera.registerOnSessionStatusChangeHandler = registerOnSessionStatusChangeHandler;
@@ -7716,8 +7731,6 @@ var remoteCamera;
7716
7731
  /**
7717
7732
  * @hidden
7718
7733
  * Namespace to interact with the application entities specific part of the SDK.
7719
- *
7720
- * @alpha
7721
7734
  */
7722
7735
  var appEntity;
7723
7736
  (function (appEntity_1) {
@@ -7733,8 +7746,6 @@ var appEntity;
7733
7746
  * @param callback Callback that will be triggered once the app entity information is available.
7734
7747
  * The callback takes two arguments: an SdkError in case something happened (i.e.
7735
7748
  * no permissions to execute the API) and the app entity configuration, if available
7736
- *
7737
- * @alpha
7738
7749
  */
7739
7750
  function selectAppEntity(threadId, categories, subEntityId, callback) {
7740
7751
  ensureInitialized(FrameContexts.content);