@microsoft/teams-js 2.31.0-beta.0 → 2.31.0-beta.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (217) hide show
  1. package/dist/esm/packages/teams-js/dts/internal/appHelpers.d.ts +12 -2
  2. package/dist/esm/packages/teams-js/dts/internal/dialogHelpers.d.ts +32 -0
  3. package/dist/esm/packages/teams-js/dts/internal/handlers.d.ts +11 -1
  4. package/dist/esm/packages/teams-js/dts/internal/hostToAppTelemetry.d.ts +51 -0
  5. package/dist/esm/packages/teams-js/dts/internal/interfaces.d.ts +11 -0
  6. package/dist/esm/packages/teams-js/dts/internal/marketplaceUtils.d.ts +1 -1
  7. package/dist/esm/packages/teams-js/dts/internal/mediaUtil.d.ts +2 -2
  8. package/dist/esm/packages/teams-js/dts/internal/messageObjects.d.ts +5 -0
  9. package/dist/esm/packages/teams-js/dts/internal/pagesHelpers.d.ts +24 -0
  10. package/dist/esm/packages/teams-js/dts/internal/profileUtil.d.ts +23 -1
  11. package/dist/esm/packages/teams-js/dts/internal/uint8array-extras/uint8array-extras.d.ts +6 -0
  12. package/dist/esm/packages/teams-js/dts/internal/utils.d.ts +20 -1
  13. package/dist/esm/packages/teams-js/dts/internal/videoEffectsUtils.d.ts +2 -2
  14. package/dist/esm/packages/teams-js/dts/internal/visualMediaHelpers.d.ts +14 -0
  15. package/dist/esm/packages/teams-js/dts/internal/webStorageHelpers.d.ts +4 -0
  16. package/dist/esm/packages/teams-js/dts/private/appEntity.d.ts +61 -61
  17. package/dist/esm/packages/teams-js/dts/private/conversations.d.ts +48 -48
  18. package/dist/esm/packages/teams-js/dts/private/copilot/copilot.d.ts +2 -0
  19. package/dist/esm/packages/teams-js/dts/private/copilot/eligibility.d.ts +29 -0
  20. package/dist/esm/packages/teams-js/dts/private/externalAppAuthentication.d.ts +355 -349
  21. package/dist/esm/packages/teams-js/dts/private/externalAppAuthenticationForCEA.d.ts +67 -68
  22. package/dist/esm/packages/teams-js/dts/private/externalAppCardActions.d.ts +104 -105
  23. package/dist/esm/packages/teams-js/dts/private/externalAppCardActionsForCEA.d.ts +41 -42
  24. package/dist/esm/packages/teams-js/dts/private/externalAppCommands.d.ts +113 -114
  25. package/dist/esm/packages/teams-js/dts/private/files.d.ts +590 -582
  26. package/dist/esm/packages/teams-js/dts/private/hostEntity/hostEntity.d.ts +42 -0
  27. package/dist/esm/packages/teams-js/dts/private/hostEntity/tab.d.ts +134 -0
  28. package/dist/esm/packages/teams-js/dts/private/index.d.ts +19 -18
  29. package/dist/esm/packages/teams-js/dts/private/logs.d.ts +31 -25
  30. package/dist/esm/packages/teams-js/dts/private/meetingRoom.d.ts +147 -142
  31. package/dist/esm/packages/teams-js/dts/private/messageChannels/dataLayer.d.ts +39 -0
  32. package/dist/esm/packages/teams-js/dts/private/messageChannels/messageChannels.d.ts +28 -0
  33. package/dist/esm/packages/teams-js/dts/private/messageChannels/telemetry.d.ts +39 -0
  34. package/dist/esm/packages/teams-js/dts/private/notifications.d.ts +31 -25
  35. package/dist/esm/packages/teams-js/dts/private/otherAppStateChange.d.ts +69 -70
  36. package/dist/esm/packages/teams-js/dts/private/remoteCamera.d.ts +219 -214
  37. package/dist/esm/packages/teams-js/dts/private/teams/fullTrust/fullTrust.d.ts +31 -0
  38. package/dist/esm/packages/teams-js/dts/private/teams/fullTrust/joinedTeams.d.ts +30 -0
  39. package/dist/esm/packages/teams-js/dts/private/teams/teams.d.ts +63 -0
  40. package/dist/esm/packages/teams-js/dts/private/videoEffectsEx.d.ts +192 -186
  41. package/dist/esm/packages/teams-js/dts/public/{app.d.ts → app/app.d.ts} +33 -45
  42. package/dist/esm/packages/teams-js/dts/public/app/lifecycle.d.ts +41 -0
  43. package/dist/esm/packages/teams-js/dts/public/appInitialization.d.ts +2 -2
  44. package/dist/esm/packages/teams-js/dts/public/authentication.d.ts +6 -0
  45. package/dist/esm/packages/teams-js/dts/public/barCode.d.ts +2 -1
  46. package/dist/esm/packages/teams-js/dts/public/calendar.d.ts +1 -0
  47. package/dist/esm/packages/teams-js/dts/public/call.d.ts +1 -0
  48. package/dist/esm/packages/teams-js/dts/public/chat.d.ts +30 -28
  49. package/dist/esm/packages/teams-js/dts/public/clipboard.d.ts +1 -0
  50. package/dist/esm/packages/teams-js/dts/public/dialog/adaptiveCard/adaptiveCard.d.ts +26 -0
  51. package/dist/esm/packages/teams-js/dts/public/dialog/adaptiveCard/bot.d.ts +27 -0
  52. package/dist/esm/packages/teams-js/dts/public/dialog/dialog.d.ts +56 -0
  53. package/dist/esm/packages/teams-js/dts/public/dialog/update.d.ts +24 -0
  54. package/dist/esm/packages/teams-js/dts/public/dialog/url/bot.d.ts +30 -0
  55. package/dist/esm/packages/teams-js/dts/public/dialog/url/parentCommunication.d.ts +50 -0
  56. package/dist/esm/packages/teams-js/dts/public/dialog/url/url.d.ts +60 -0
  57. package/dist/esm/packages/teams-js/dts/public/geoLocation/geoLocation.d.ts +68 -0
  58. package/dist/esm/packages/teams-js/dts/public/geoLocation/map.d.ts +33 -0
  59. package/dist/esm/packages/teams-js/dts/public/index.d.ts +29 -27
  60. package/dist/esm/packages/teams-js/dts/public/interfaces.d.ts +23 -1
  61. package/dist/esm/packages/teams-js/dts/public/liveShareHost.d.ts +135 -136
  62. package/dist/esm/packages/teams-js/dts/public/location.d.ts +75 -76
  63. package/dist/esm/packages/teams-js/dts/public/mail.d.ts +80 -81
  64. package/dist/esm/packages/teams-js/dts/public/marketplace.d.ts +315 -316
  65. package/dist/esm/packages/teams-js/dts/public/media.d.ts +423 -428
  66. package/dist/esm/packages/teams-js/dts/public/meeting/appShareButton.d.ts +51 -0
  67. package/dist/esm/packages/teams-js/dts/public/meeting/meeting.d.ts +854 -0
  68. package/dist/esm/packages/teams-js/dts/public/menus.d.ts +165 -166
  69. package/dist/esm/packages/teams-js/dts/public/monetization.d.ts +56 -50
  70. package/dist/esm/packages/teams-js/dts/public/navigation.d.ts +2 -1
  71. package/dist/esm/packages/teams-js/dts/public/nestedAppAuth.d.ts +10 -11
  72. package/dist/esm/packages/teams-js/dts/public/pages/appButton.d.ts +30 -0
  73. package/dist/esm/packages/teams-js/dts/public/pages/backStack.d.ts +44 -0
  74. package/dist/esm/packages/teams-js/dts/public/pages/config.d.ts +123 -0
  75. package/dist/esm/packages/teams-js/dts/public/pages/currentApp.d.ts +46 -0
  76. package/dist/esm/packages/teams-js/dts/public/pages/fullTrust.d.ts +33 -0
  77. package/dist/esm/packages/teams-js/dts/public/pages/pages.d.ts +253 -0
  78. package/dist/esm/packages/teams-js/dts/public/pages/tabs.d.ts +32 -0
  79. package/dist/esm/packages/teams-js/dts/public/people.d.ts +61 -63
  80. package/dist/esm/packages/teams-js/dts/public/profile.d.ts +81 -103
  81. package/dist/esm/packages/teams-js/dts/public/runtime.d.ts +3 -0
  82. package/dist/esm/packages/teams-js/dts/public/search.d.ts +81 -82
  83. package/dist/esm/packages/teams-js/dts/public/secondaryBrowser.d.ts +26 -27
  84. package/dist/esm/packages/teams-js/dts/public/settings.d.ts +4 -3
  85. package/dist/esm/packages/teams-js/dts/public/sharing/history.d.ts +47 -0
  86. package/dist/esm/packages/teams-js/dts/public/sharing/sharing.d.ts +76 -0
  87. package/dist/esm/packages/teams-js/dts/public/stageView/self.d.ts +23 -0
  88. package/dist/esm/packages/teams-js/dts/public/stageView/stageView.d.ts +81 -0
  89. package/dist/esm/packages/teams-js/dts/public/tasks.d.ts +46 -56
  90. package/dist/esm/packages/teams-js/dts/public/teamsAPIs.d.ts +78 -76
  91. package/dist/esm/packages/teams-js/dts/public/thirdPartyCloudStorage.d.ts +98 -99
  92. package/dist/esm/packages/teams-js/dts/public/videoEffects.d.ts +209 -210
  93. package/dist/esm/packages/teams-js/dts/public/visualMedia/image.d.ts +64 -0
  94. package/dist/esm/packages/teams-js/dts/public/visualMedia/visualMedia.d.ts +116 -0
  95. package/dist/esm/packages/teams-js/dts/public/webStorage.d.ts +20 -22
  96. package/dist/esm/packages/teams-js/src/index.js +1 -1
  97. package/dist/esm/packages/teams-js/src/internal/appHelpers.js +1 -1
  98. package/dist/esm/packages/teams-js/src/internal/communication.js +1 -1
  99. package/dist/esm/packages/teams-js/src/internal/deepLinkUtilities.js +1 -1
  100. package/dist/esm/packages/teams-js/src/internal/dialogHelpers.js +1 -0
  101. package/dist/esm/packages/teams-js/src/internal/handlers.js +1 -1
  102. package/dist/esm/packages/teams-js/src/internal/hostToAppTelemetry.js +1 -0
  103. package/dist/esm/packages/teams-js/src/internal/marketplaceUtils.js +1 -1
  104. package/dist/esm/packages/teams-js/src/internal/mediaUtil.js +1 -1
  105. package/dist/esm/packages/teams-js/src/internal/messageObjects.js +1 -1
  106. package/dist/esm/packages/teams-js/src/internal/pagesHelpers.js +1 -0
  107. package/dist/esm/packages/teams-js/src/internal/uint8array-extras/uint8array-extras.js +1 -0
  108. package/dist/esm/packages/teams-js/src/internal/utils.js +1 -1
  109. package/dist/esm/packages/teams-js/src/internal/validOrigins.js +1 -1
  110. package/dist/esm/packages/teams-js/src/internal/videoEffectsUtils.js +1 -1
  111. package/dist/esm/packages/teams-js/src/internal/visualMediaHelpers.js +1 -0
  112. package/dist/esm/packages/teams-js/src/internal/webStorageHelpers.js +1 -0
  113. package/dist/esm/packages/teams-js/src/private/appEntity.js +1 -1
  114. package/dist/esm/packages/teams-js/src/private/conversations.js +1 -1
  115. package/dist/esm/packages/teams-js/src/private/copilot/copilot.js +1 -0
  116. package/dist/esm/packages/teams-js/src/private/copilot/eligibility.js +1 -0
  117. package/dist/esm/packages/teams-js/src/private/externalAppAuthentication.js +1 -1
  118. package/dist/esm/packages/teams-js/src/private/externalAppAuthenticationForCEA.js +1 -1
  119. package/dist/esm/packages/teams-js/src/private/externalAppCardActions.js +1 -1
  120. package/dist/esm/packages/teams-js/src/private/externalAppCardActionsForCEA.js +1 -1
  121. package/dist/esm/packages/teams-js/src/private/externalAppCommands.js +1 -1
  122. package/dist/esm/packages/teams-js/src/private/files.js +1 -1
  123. package/dist/esm/packages/teams-js/src/private/hostEntity/hostEntity.js +1 -0
  124. package/dist/esm/packages/teams-js/src/private/hostEntity/tab.js +1 -0
  125. package/dist/esm/packages/teams-js/src/private/logs.js +1 -1
  126. package/dist/esm/packages/teams-js/src/private/meetingRoom.js +1 -1
  127. package/dist/esm/packages/teams-js/src/private/messageChannels/dataLayer.js +1 -0
  128. package/dist/esm/packages/teams-js/src/private/messageChannels/messageChannels.js +1 -0
  129. package/dist/esm/packages/teams-js/src/private/messageChannels/telemetry.js +1 -0
  130. package/dist/esm/packages/teams-js/src/private/notifications.js +1 -1
  131. package/dist/esm/packages/teams-js/src/private/otherAppStateChange.js +1 -1
  132. package/dist/esm/packages/teams-js/src/private/remoteCamera.js +1 -1
  133. package/dist/esm/packages/teams-js/src/private/teams/fullTrust/fullTrust.js +1 -0
  134. package/dist/esm/packages/teams-js/src/private/teams/fullTrust/joinedTeams.js +1 -0
  135. package/dist/esm/packages/teams-js/src/private/teams/teams.js +1 -0
  136. package/dist/esm/packages/teams-js/src/private/videoEffectsEx.js +1 -1
  137. package/dist/esm/packages/teams-js/src/public/app/app.js +1 -0
  138. package/dist/esm/packages/teams-js/src/public/app/lifecycle.js +1 -0
  139. package/dist/esm/packages/teams-js/src/public/appInitialization.js +1 -1
  140. package/dist/esm/packages/teams-js/src/public/chat.js +1 -1
  141. package/dist/esm/packages/teams-js/src/public/clipboard.js +1 -1
  142. package/dist/esm/packages/teams-js/src/public/dialog/adaptiveCard/adaptiveCard.js +1 -0
  143. package/dist/esm/packages/teams-js/src/public/dialog/adaptiveCard/bot.js +1 -0
  144. package/dist/esm/packages/teams-js/src/public/dialog/dialog.js +1 -0
  145. package/dist/esm/packages/teams-js/src/public/dialog/update.js +1 -0
  146. package/dist/esm/packages/teams-js/src/public/dialog/url/bot.js +1 -0
  147. package/dist/esm/packages/teams-js/src/public/dialog/url/parentCommunication.js +1 -0
  148. package/dist/esm/packages/teams-js/src/public/dialog/url/url.js +1 -0
  149. package/dist/esm/packages/teams-js/src/public/geoLocation/geoLocation.js +1 -0
  150. package/dist/esm/packages/teams-js/src/public/geoLocation/map.js +1 -0
  151. package/dist/esm/packages/teams-js/src/public/liveShareHost.js +1 -1
  152. package/dist/esm/packages/teams-js/src/public/location.js +1 -1
  153. package/dist/esm/packages/teams-js/src/public/mail.js +1 -1
  154. package/dist/esm/packages/teams-js/src/public/marketplace.js +1 -1
  155. package/dist/esm/packages/teams-js/src/public/media.js +1 -1
  156. package/dist/esm/packages/teams-js/src/public/meeting/appShareButton.js +1 -0
  157. package/dist/esm/packages/teams-js/src/public/meeting/meeting.js +1 -0
  158. package/dist/esm/packages/teams-js/src/public/menus.js +1 -1
  159. package/dist/esm/packages/teams-js/src/public/monetization.js +1 -1
  160. package/dist/esm/packages/teams-js/src/public/navigation.js +1 -1
  161. package/dist/esm/packages/teams-js/src/public/nestedAppAuth.js +1 -1
  162. package/dist/esm/packages/teams-js/src/public/pages/appButton.js +1 -0
  163. package/dist/esm/packages/teams-js/src/public/pages/backStack.js +1 -0
  164. package/dist/esm/packages/teams-js/src/public/pages/config.js +1 -0
  165. package/dist/esm/packages/teams-js/src/public/pages/currentApp.js +1 -0
  166. package/dist/esm/packages/teams-js/src/public/pages/fullTrust.js +1 -0
  167. package/dist/esm/packages/teams-js/src/public/pages/pages.js +1 -0
  168. package/dist/esm/packages/teams-js/src/public/pages/tabs.js +1 -0
  169. package/dist/esm/packages/teams-js/src/public/people.js +1 -1
  170. package/dist/esm/packages/teams-js/src/public/profile.js +1 -1
  171. package/dist/esm/packages/teams-js/src/public/publicAPIs.js +1 -1
  172. package/dist/esm/packages/teams-js/src/public/runtime.js +1 -1
  173. package/dist/esm/packages/teams-js/src/public/search.js +1 -1
  174. package/dist/esm/packages/teams-js/src/public/secondaryBrowser.js +1 -1
  175. package/dist/esm/packages/teams-js/src/public/settings.js +1 -1
  176. package/dist/esm/packages/teams-js/src/public/sharing/history.js +1 -0
  177. package/dist/esm/packages/teams-js/src/public/sharing/sharing.js +1 -0
  178. package/dist/esm/packages/teams-js/src/public/stageView/self.js +1 -0
  179. package/dist/esm/packages/teams-js/src/public/stageView/stageView.js +1 -0
  180. package/dist/esm/packages/teams-js/src/public/tasks.js +1 -1
  181. package/dist/esm/packages/teams-js/src/public/teamsAPIs.js +1 -1
  182. package/dist/esm/packages/teams-js/src/public/thirdPartyCloudStorage.js +1 -1
  183. package/dist/esm/packages/teams-js/src/public/version.js +1 -1
  184. package/dist/esm/packages/teams-js/src/public/videoEffects.js +1 -1
  185. package/dist/esm/packages/teams-js/src/public/visualMedia/image.js +1 -0
  186. package/dist/esm/packages/teams-js/src/public/visualMedia/visualMedia.js +1 -0
  187. package/dist/esm/packages/teams-js/src/public/webStorage.js +1 -1
  188. package/dist/umd/MicrosoftTeams.d.ts +8195 -7407
  189. package/dist/umd/MicrosoftTeams.js +12298 -12356
  190. package/dist/umd/MicrosoftTeams.js.map +1 -1
  191. package/dist/umd/MicrosoftTeams.min.js +1 -1
  192. package/dist/umd/MicrosoftTeams.min.js.map +1 -1
  193. package/package.json +1 -1
  194. package/dist/esm/packages/teams-js/dts/private/copilot.d.ts +0 -39
  195. package/dist/esm/packages/teams-js/dts/private/hostEntity.d.ts +0 -176
  196. package/dist/esm/packages/teams-js/dts/private/messageChannels.d.ts +0 -107
  197. package/dist/esm/packages/teams-js/dts/private/teams.d.ts +0 -116
  198. package/dist/esm/packages/teams-js/dts/public/dialog.d.ts +0 -286
  199. package/dist/esm/packages/teams-js/dts/public/geoLocation.d.ts +0 -100
  200. package/dist/esm/packages/teams-js/dts/public/meeting.d.ts +0 -906
  201. package/dist/esm/packages/teams-js/dts/public/pages.d.ts +0 -574
  202. package/dist/esm/packages/teams-js/dts/public/sharing.d.ts +0 -124
  203. package/dist/esm/packages/teams-js/dts/public/stageView.d.ts +0 -104
  204. package/dist/esm/packages/teams-js/dts/public/visualMedia.d.ts +0 -192
  205. package/dist/esm/packages/teams-js/src/private/copilot.js +0 -1
  206. package/dist/esm/packages/teams-js/src/private/hostEntity.js +0 -1
  207. package/dist/esm/packages/teams-js/src/private/messageChannels.js +0 -1
  208. package/dist/esm/packages/teams-js/src/private/teams.js +0 -1
  209. package/dist/esm/packages/teams-js/src/public/app.js +0 -1
  210. package/dist/esm/packages/teams-js/src/public/dialog.js +0 -1
  211. package/dist/esm/packages/teams-js/src/public/geoLocation.js +0 -1
  212. package/dist/esm/packages/teams-js/src/public/meeting.js +0 -1
  213. package/dist/esm/packages/teams-js/src/public/pages.js +0 -1
  214. package/dist/esm/packages/teams-js/src/public/sharing.js +0 -1
  215. package/dist/esm/packages/teams-js/src/public/stageView.js +0 -1
  216. package/dist/esm/packages/teams-js/src/public/visualMedia.js +0 -1
  217. /package/dist/esm/node_modules/.pnpm/{@rollup_plugin-typescript@11.1.6_rollup@4.24.0_tslib@2.6.3_typescript@4.9.5 → @rollup_plugin-typescript@11.1.6_rollup@4.24.4_tslib@2.6.3_typescript@4.9.5}/node_modules/tslib/tslib.es6.js +0 -0
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Describes information needed to start a chat
3
+ * @module
4
+ */
1
5
  interface OpenChatRequest {
2
6
  /**
3
7
  * An optional message used when initiating chat
@@ -35,32 +39,30 @@ export interface OpenGroupChatRequest extends OpenChatRequest {
35
39
  /**
36
40
  * Contains functionality to start chat with others
37
41
  */
38
- export declare namespace chat {
39
- /**
40
- * Allows the user to open a chat with a single user and allows
41
- * for the user to specify the message they wish to send.
42
- *
43
- * @param openChatRequest: {@link OpenSingleChatRequest}- a request object that contains a user's email as well as an optional message parameter.
44
- *
45
- * @returns Promise resolved upon completion
46
- */
47
- function openChat(openChatRequest: OpenSingleChatRequest): Promise<void>;
48
- /**
49
- * Allows the user to create a chat with multiple users (2+) and allows
50
- * for the user to specify a message and name the topic of the conversation. If
51
- * only 1 user is provided into users array default back to origin openChat.
52
- *
53
- * @param openChatRequest: {@link OpenGroupChatRequest} - a request object that contains a list of user emails as well as optional parameters for message and topic (display name for the group chat).
54
- *
55
- * @returns Promise resolved upon completion
56
- */
57
- function openGroupChat(openChatRequest: OpenGroupChatRequest): Promise<void>;
58
- /**
59
- * Checks if the chat capability is supported by the host
60
- * @returns boolean to represent whether the chat capability is supported
61
- *
62
- * @throws Error if {@linkcode app.initialize} has not successfully completed
63
- */
64
- function isSupported(): boolean;
65
- }
42
+ /**
43
+ * Allows the user to open a chat with a single user and allows
44
+ * for the user to specify the message they wish to send.
45
+ *
46
+ * @param openChatRequest: {@link OpenSingleChatRequest}- a request object that contains a user's email as well as an optional message parameter.
47
+ *
48
+ * @returns Promise resolved upon completion
49
+ */
50
+ export declare function openChat(openChatRequest: OpenSingleChatRequest): Promise<void>;
51
+ /**
52
+ * Allows the user to create a chat with multiple users (2+) and allows
53
+ * for the user to specify a message and name the topic of the conversation. If
54
+ * only 1 user is provided into users array default back to origin openChat.
55
+ *
56
+ * @param openChatRequest: {@link OpenGroupChatRequest} - a request object that contains a list of user emails as well as optional parameters for message and topic (display name for the group chat).
57
+ *
58
+ * @returns Promise resolved upon completion
59
+ */
60
+ export declare function openGroupChat(openChatRequest: OpenGroupChatRequest): Promise<void>;
61
+ /**
62
+ * Checks if the chat capability is supported by the host
63
+ * @returns boolean to represent whether the chat capability is supported
64
+ *
65
+ * @throws Error if {@linkcode app.initialize} has not successfully completed
66
+ */
67
+ export declare function isSupported(): boolean;
66
68
  export {};
@@ -2,6 +2,7 @@
2
2
  * Interact with the system clipboard
3
3
  *
4
4
  * @beta
5
+ * @module
5
6
  */
6
7
  /**
7
8
  * Function to copy data to clipboard.
@@ -0,0 +1,26 @@
1
+ import { AdaptiveCardDialogInfo } from '../../interfaces';
2
+ import { DialogSubmitHandler } from '../dialog';
3
+ import * as bot from './bot';
4
+ /**
5
+ * Allows app to open an adaptive card based dialog.
6
+ *
7
+ * @remarks
8
+ * This function cannot be called from inside of a dialog
9
+ *
10
+ * @param adaptiveCardDialogInfo - An object containing the parameters of the dialog module {@link AdaptiveCardDialogInfo}.
11
+ * @param submitHandler - Handler that triggers when a dialog fires an [Action.Submit](https://adaptivecards.io/explorer/Action.Submit.html) or when the user closes the dialog.
12
+ *
13
+ * @beta
14
+ */
15
+ export declare function open(adaptiveCardDialogInfo: AdaptiveCardDialogInfo, submitHandler?: DialogSubmitHandler): void;
16
+ /**
17
+ * Checks if dialog.adaptiveCard module is supported by the host
18
+ *
19
+ * @returns boolean to represent whether dialog.adaptiveCard module is supported
20
+ *
21
+ * @throws Error if {@linkcode app.initialize} has not successfully completed
22
+ *
23
+ * @beta
24
+ */
25
+ export declare function isSupported(): boolean;
26
+ export { bot };
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Module for interaction with adaptive card dialogs that need to communicate with the bot framework
3
+ *
4
+ * @beta
5
+ * @module
6
+ */
7
+ import { BotAdaptiveCardDialogInfo } from '../../interfaces';
8
+ import { DialogSubmitHandler } from '../dialog';
9
+ /**
10
+ * Allows an app to open an adaptive card-based dialog module using bot.
11
+ *
12
+ * @param botAdaptiveCardDialogInfo - An object containing the parameters of the dialog module including completionBotId.
13
+ * @param submitHandler - Handler that triggers when the dialog has been submitted or closed.
14
+ *
15
+ * @beta
16
+ */
17
+ export declare function open(botAdaptiveCardDialogInfo: BotAdaptiveCardDialogInfo, submitHandler?: DialogSubmitHandler): void;
18
+ /**
19
+ * Checks if dialog.adaptiveCard.bot capability is supported by the host
20
+ *
21
+ * @returns boolean to represent whether dialog.adaptiveCard.bot is supported
22
+ *
23
+ * @throws Error if {@linkcode app.initialize} has not successfully completed
24
+ *
25
+ * @beta
26
+ */
27
+ export declare function isSupported(): boolean;
@@ -0,0 +1,56 @@
1
+ import * as adaptiveCard from './adaptiveCard/adaptiveCard';
2
+ import * as update from './update';
3
+ import * as url from './url/url';
4
+ /**
5
+ * Data Structure to represent the SDK response when dialog closes
6
+ *
7
+ * @beta
8
+ */
9
+ export interface ISdkResponse {
10
+ /**
11
+ * Error in case there is a failure before dialog submission
12
+ */
13
+ err?: string;
14
+ /**
15
+ * Value provided in the `result` parameter by the dialog when the {@linkcode url.submit} function
16
+ * was called.
17
+ * If the dialog was closed by the user without submitting (e.g., using a control in the corner
18
+ * of the dialog), this value will be `undefined` here.
19
+ */
20
+ result?: string | object;
21
+ }
22
+ /**
23
+ * Handler used to receive and process messages sent between a dialog and the app that launched it
24
+ * @beta
25
+ */
26
+ export type PostMessageChannel = (message: any) => void;
27
+ /**
28
+ * Handler used for receiving results when a dialog closes, either the value passed by {@linkcode url.submit}
29
+ * or an error if the dialog was closed by the user.
30
+ *
31
+ * @see {@linkcode ISdkResponse}
32
+ *
33
+ * @beta
34
+ */
35
+ export type DialogSubmitHandler = (result: ISdkResponse) => void;
36
+ /**
37
+ * @hidden
38
+ * Hide from docs because this function is only used during initialization
39
+ *
40
+ * Adds register handlers for messageForChild upon initialization and only in the tasks FrameContext. {@link FrameContexts.task}
41
+ * Function is called during app initialization
42
+ * @internal
43
+ * Limited to Microsoft-internal use
44
+ *
45
+ * @beta
46
+ */
47
+ export declare function initialize(): void;
48
+ /**
49
+ * This function currently serves no purpose and should not be used. All functionality that used
50
+ * to be covered by this method is now in subcapabilities and those isSupported methods should be
51
+ * used directly.
52
+ *
53
+ * @hidden
54
+ */
55
+ export declare function isSupported(): boolean;
56
+ export { adaptiveCard, url, update };
@@ -0,0 +1,24 @@
1
+ /**
2
+ * Module to update the dialog
3
+ *
4
+ * @beta
5
+ * @module
6
+ */
7
+ import { DialogSize } from '../interfaces';
8
+ /**
9
+ * Update dimensions - height/width of a dialog.
10
+ *
11
+ * @param dimensions - An object containing width and height properties.
12
+ *
13
+ * @beta
14
+ */
15
+ export declare function resize(dimensions: DialogSize): void;
16
+ /**
17
+ * Checks if dialog.update capability is supported by the host
18
+ * @returns boolean to represent whether dialog.update capabilty is supported
19
+ *
20
+ * @throws Error if {@linkcode app.initialize} has not successfully completed
21
+ *
22
+ * @beta
23
+ */
24
+ export declare function isSupported(): boolean;
@@ -0,0 +1,30 @@
1
+ /**
2
+ * Module to open a dialog that sends results to the bot framework
3
+ *
4
+ * @beta
5
+ * @module
6
+ */
7
+ import { BotUrlDialogInfo } from '../../interfaces';
8
+ import { DialogSubmitHandler, PostMessageChannel } from '../dialog';
9
+ /**
10
+ * Allows an app to open a dialog that sends submitted data to a bot.
11
+ *
12
+ * @param botUrlDialogInfo - An object containing the parameters of the dialog module including completionBotId.
13
+ * @param submitHandler - Handler that triggers when the dialog has been submitted or closed.
14
+ * @param messageFromChildHandler - Handler that triggers if dialog sends a message to the app.
15
+ *
16
+ * @returns a function that can be used to send messages to the dialog.
17
+ *
18
+ * @beta
19
+ */
20
+ export declare function open(botUrlDialogInfo: BotUrlDialogInfo, submitHandler?: DialogSubmitHandler, messageFromChildHandler?: PostMessageChannel): void;
21
+ /**
22
+ * Checks if dialog.url.bot capability is supported by the host
23
+ *
24
+ * @returns boolean to represent whether dialog.url.bot is supported
25
+ *
26
+ * @throws Error if {@linkcode app.initialize} has not successfully completed
27
+ *
28
+ * @beta
29
+ */
30
+ export declare function isSupported(): boolean;
@@ -0,0 +1,50 @@
1
+ /**
2
+ * Subcapability that allows communication between the dialog and the parent app.
3
+ *
4
+ * @remarks
5
+ * Note that dialog can be invoked from parentless scenarios e.g. Search Message Extensions. The subcapability `parentCommunication` is not supported in such scenarios.
6
+ *
7
+ * @beta
8
+ * @module
9
+ */
10
+ import { PostMessageChannel } from '../dialog';
11
+ /**
12
+ * Send message to the parent from dialog
13
+ *
14
+ * @remarks
15
+ * This function is only intended to be called from code running within the dialog. Calling it from outside the dialog will have no effect.
16
+ *
17
+ * @param message - The message to send to the parent
18
+ *
19
+ * @beta
20
+ */
21
+ export declare function sendMessageToParentFromDialog(message: any): void;
22
+ /**
23
+ * Send message to the dialog from the parent
24
+ *
25
+ * @param message - The message to send
26
+ *
27
+ * @beta
28
+ */
29
+ export declare function sendMessageToDialog(message: any): void;
30
+ /**
31
+ * Register a listener that will be triggered when a message is received from the app that opened the dialog.
32
+ *
33
+ * @remarks
34
+ * This function is only intended to be called from code running within the dialog. Calling it from outside the dialog will have no effect.
35
+ *
36
+ * @param listener - The listener that will be triggered.
37
+ *
38
+ * @beta
39
+ */
40
+ export declare function registerOnMessageFromParent(listener: PostMessageChannel): void;
41
+ /**
42
+ * Checks if dialog.url.parentCommunication capability is supported by the host
43
+ *
44
+ * @returns boolean to represent whether dialog.url.parentCommunication capability is supported
45
+ *
46
+ * @throws Error if {@linkcode app.initialize} has not successfully completed
47
+ *
48
+ * @beta
49
+ */
50
+ export declare function isSupported(): boolean;
@@ -0,0 +1,60 @@
1
+ import { BotUrlDialogInfo, DialogInfo, UrlDialogInfo } from '../../interfaces';
2
+ import { DialogSubmitHandler, PostMessageChannel } from '../dialog';
3
+ import * as bot from './bot';
4
+ import * as parentCommunication from './parentCommunication';
5
+ /**
6
+ * Allows app to open a url based dialog.
7
+ *
8
+ * @remarks
9
+ * This function cannot be called from inside of a dialog
10
+ *
11
+ * @param urlDialogInfo - An object containing the parameters of the dialog module.
12
+ * @param submitHandler - Handler that triggers when a dialog calls the {@linkcode submit} function or when the user closes the dialog.
13
+ * @param messageFromChildHandler - Handler that triggers if dialog sends a message to the app.
14
+ *
15
+ * @beta
16
+ */
17
+ export declare function open(urlDialogInfo: UrlDialogInfo, submitHandler?: DialogSubmitHandler, messageFromChildHandler?: PostMessageChannel): void;
18
+ /**
19
+ * Submit the dialog module and close the dialog
20
+ *
21
+ * @remarks
22
+ * This function is only intended to be called from code running within the dialog. Calling it from outside the dialog will have no effect.
23
+ *
24
+ * @param result - The result to be sent to the bot or the app. Typically a JSON object or a serialized version of it,
25
+ * If this function is called from a dialog while {@link M365ContentAction} is set in the context object by the host, result will be ignored
26
+ *
27
+ * @param appIds - Valid application(s) that can receive the result of the submitted dialogs. Specifying this parameter helps prevent malicious apps from retrieving the dialog result. Multiple app IDs can be specified because a web app from a single underlying domain can power multiple apps across different environments and branding schemes.
28
+ *
29
+ * @beta
30
+ */
31
+ export declare function submit(result?: string | object, appIds?: string | string[]): void;
32
+ /**
33
+ * Checks if dialog.url module is supported by the host
34
+ *
35
+ * @returns boolean to represent whether dialog.url module is supported
36
+ *
37
+ * @throws Error if {@linkcode app.initialize} has not successfully completed
38
+ *
39
+ * @beta
40
+ */
41
+ export declare function isSupported(): boolean;
42
+ /**
43
+ * @hidden
44
+ *
45
+ * Convert UrlDialogInfo to DialogInfo to send the information to host in {@linkcode open} API.
46
+ *
47
+ * @internal
48
+ * Limited to Microsoft-internal use
49
+ */
50
+ export declare function getDialogInfoFromUrlDialogInfo(urlDialogInfo: UrlDialogInfo): DialogInfo;
51
+ /**
52
+ * @hidden
53
+ *
54
+ * Convert BotUrlDialogInfo to DialogInfo to send the information to host in {@linkcode bot.open} API.
55
+ *
56
+ * @internal
57
+ * Limited to Microsoft-internal use
58
+ */
59
+ export declare function getDialogInfoFromBotUrlDialogInfo(botUrlDialogInfo: BotUrlDialogInfo): DialogInfo;
60
+ export { bot, parentCommunication };
@@ -0,0 +1,68 @@
1
+ /**
2
+ * Module to interact with the geoLocation module-specific part of the SDK. This is the newer version of location module.
3
+ *
4
+ * @beta
5
+ * @module
6
+ */
7
+ import * as map from './map';
8
+ /**
9
+ * Data struture to represent the location information
10
+ *
11
+ * @beta
12
+ */
13
+ export interface Location {
14
+ /**
15
+ Latitude of the location
16
+ */
17
+ latitude: number;
18
+ /**
19
+ Longitude of the location
20
+ */
21
+ longitude: number;
22
+ /**
23
+ Accuracy describes the maximum distance in meters from the captured coordinates to the possible actual location
24
+ @remarks
25
+ This property is only in scope for mobile
26
+ */
27
+ accuracy?: number;
28
+ /**
29
+ Time stamp when the location was captured
30
+ */
31
+ timestamp?: number;
32
+ }
33
+ /**
34
+ * Fetches current user coordinates
35
+ * @returns Promise that will resolve with {@link geoLocation.Location} object or reject with an error. Function can also throw a NOT_SUPPORTED_ON_PLATFORM error
36
+ *
37
+ * @beta
38
+ */
39
+ export declare function getCurrentLocation(): Promise<Location>;
40
+ /**
41
+ * Checks whether or not location has user permission
42
+ *
43
+ * @returns Promise that will resolve with true if the user had granted the app permission to location information, or with false otherwise,
44
+ * In case of an error, promise will reject with the error. Function can also throw a NOT_SUPPORTED_ON_PLATFORM error
45
+ *
46
+ * @beta
47
+ */
48
+ export declare function hasPermission(): Promise<boolean>;
49
+ /**
50
+ * Requests user permission for location
51
+ *
52
+ * @returns true if the user consented permission for location, false otherwise
53
+ * @returns Promise that will resolve with true if the user consented permission for location, or with false otherwise,
54
+ * In case of an error, promise will reject with the error. Function can also throw a NOT_SUPPORTED_ON_PLATFORM error
55
+ *
56
+ * @beta
57
+ */
58
+ export declare function requestPermission(): Promise<boolean>;
59
+ /**
60
+ * Checks if geoLocation capability is supported by the host
61
+ * @returns boolean to represent whether geoLocation is supported
62
+ *
63
+ * @throws Error if {@linkcode app.initialize} has not successfully completed
64
+ *
65
+ * @beta
66
+ */
67
+ export declare function isSupported(): boolean;
68
+ export { map };
@@ -0,0 +1,33 @@
1
+ /**
2
+ * Module to interact with the location on map module-specific part of the SDK.
3
+ *
4
+ * @beta
5
+ * @module
6
+ */
7
+ import { Location } from './geoLocation';
8
+ /**
9
+ * Allows user to choose location on map
10
+ *
11
+ * @returns Promise that will resolve with {@link geoLocation.Location} object chosen by the user or reject with an error. Function can also throw a NOT_SUPPORTED_ON_PLATFORM error
12
+ *
13
+ * @beta
14
+ */
15
+ export declare function chooseLocation(): Promise<Location>;
16
+ /**
17
+ * Shows the location on map corresponding to the given coordinates
18
+ *
19
+ * @param location - Location to be shown on the map
20
+ * @returns Promise that resolves when the location dialog has been closed or reject with an error. Function can also throw a NOT_SUPPORTED_ON_PLATFORM error
21
+ *
22
+ * @beta
23
+ */
24
+ export declare function showLocation(location: Location): Promise<void>;
25
+ /**
26
+ * Checks if geoLocation.map capability is supported by the host
27
+ * @returns boolean to represent whether geoLocation.map is supported
28
+ *
29
+ * @throws Error if {@linkcode app.initialize} has not successfully completed
30
+ *
31
+ * @beta
32
+ */
33
+ export declare function isSupported(): boolean;
@@ -1,44 +1,46 @@
1
1
  export * as authentication from './authentication';
2
2
  export { ChannelType, DialogDimension, FrameContexts, HostClientType, HostName, TaskModuleDimension, TeamType, UserTeamRole, } from './constants';
3
- export { ActionInfo, ActionObjectType, AdaptiveCardVersion, AdaptiveCardDialogInfo, BaseActionObject, BotAdaptiveCardDialogInfo, BotUrlDialogInfo, Context, DeepLinkParameters, DialogInfo, DialogSize, ErrorCode, FileOpenPreference, FrameContext, FrameInfo, LoadContext, LocaleInfo, M365ContentAction, ResumeContext, SdkError, SecondaryId, SecondaryM365ContentIdName, ShareDeepLinkParameters, TabInformation, TabInstance, TabInstanceParameters, TaskInfo, TeamInformation, UrlDialogInfo, } from './interfaces';
4
- export * as app from './app';
3
+ export { ActionInfo, ActionObjectType, AdaptiveCardVersion, AdaptiveCardDialogInfo, BaseActionObject, BotAdaptiveCardDialogInfo, BotUrlDialogInfo, Context, DeepLinkParameters, DialogInfo, DialogSize, ErrorCode, FileOpenPreference, FrameContext, FrameInfo, HostToAppPerformanceMetrics, LoadContext, LocaleInfo, M365ContentAction, ResumeContext, SdkError, SecondaryId, SecondaryM365ContentIdName, ShareDeepLinkParameters, TabInformation, TabInstance, TabInstanceParameters, TaskInfo, TeamInformation, UrlDialogInfo, } from './interfaces';
4
+ export * as app from './app/app';
5
5
  export { AppId } from './appId';
6
6
  export { EmailAddress } from './emailAddress';
7
7
  export * as appInstallDialog from './appInstallDialog';
8
8
  export * as barCode from './barCode';
9
- export { chat, OpenGroupChatRequest, OpenSingleChatRequest } from './chat';
9
+ export * as chat from './chat';
10
+ export { OpenGroupChatRequest, OpenSingleChatRequest } from './chat';
10
11
  export * as clipboard from './clipboard';
11
- export { dialog } from './dialog';
12
- export { nestedAppAuth } from './nestedAppAuth';
13
- export { geoLocation } from './geoLocation';
12
+ export * as dialog from './dialog/dialog';
13
+ export * as nestedAppAuth from './nestedAppAuth';
14
+ export * as geoLocation from './geoLocation/geoLocation';
14
15
  export { getAdaptiveCardSchemaVersion } from './adaptiveCards';
15
- export { pages } from './pages';
16
+ export * as pages from './pages/pages';
16
17
  export { addEventListnerFunctionType, ChildAppWindow, IAppWindow, onCompleteFunctionType, ParentAppWindow, } from './appWindow';
17
- export { menus } from './menus';
18
- export { media } from './media';
19
- export { secondaryBrowser } from './secondaryBrowser';
20
- export { location } from './location';
21
- export { meeting } from './meeting';
22
- export { monetization } from './monetization';
18
+ export * as menus from './menus';
19
+ export * as media from './media';
20
+ export * as secondaryBrowser from './secondaryBrowser';
21
+ export * as location from './location';
22
+ export * as meeting from './meeting/meeting';
23
+ export * as monetization from './monetization';
23
24
  export * as calendar from './calendar';
24
- export { mail } from './mail';
25
- export { teamsCore } from './teamsAPIs';
26
- export { people } from './people';
27
- export { profile } from './profile';
28
- export { videoEffects } from './videoEffects';
29
- export { search } from './search';
30
- export { sharing } from './sharing';
31
- export { stageView } from './stageView';
25
+ export * as mail from './mail';
26
+ export * as teamsCore from './teamsAPIs';
27
+ export * as people from './people';
28
+ export * as profile from './profile';
29
+ export * as videoEffects from './videoEffects';
30
+ export * as search from './search';
31
+ export * as sharing from './sharing/sharing';
32
+ export * as stageView from './stageView/stageView';
32
33
  export { version } from './version';
33
- export { visualMedia } from './visualMedia';
34
- export { webStorage } from './webStorage';
34
+ export * as visualMedia from './visualMedia/visualMedia';
35
+ export * as webStorage from './webStorage';
35
36
  export * as call from './call';
36
37
  export * as appInitialization from './appInitialization';
37
- export { thirdPartyCloudStorage } from './thirdPartyCloudStorage';
38
+ export * as thirdPartyCloudStorage from './thirdPartyCloudStorage';
38
39
  export { callbackFunctionType, enablePrintCapability, executeDeepLink, executeDeepLinkOnCompleteFunctionType, getContext, getContextCallbackFunctionType, getMruTabInstances, getTabInstances, getTabInstancesCallbackFunctionType, initialize, initializeWithFrameContext, print, registerAppButtonClickHandler, registerAppButtonHoverEnterHandler, registerAppButtonHoverLeaveHandler, registerBackButtonHandler, registerBackButtonHandlerFunctionType, registerBeforeUnloadHandler, registerChangeSettingsHandler, registerFocusEnterHandler, registerFullScreenHandler, registerFullScreenHandlerFunctionType, registerOnLoadHandler, registerOnThemeChangeHandler, registerOnThemeChangeHandlerFunctionType, setFrameContext, shareDeepLink, } from './publicAPIs';
39
40
  export { navigateBack, navigateCrossDomain, navigateToTab, onCompleteHandlerFunctionType, returnFocus, } from './navigation';
40
41
  export * as settings from './settings';
41
- export { tasks } from './tasks';
42
- export { liveShare, LiveShareHost } from './liveShareHost';
43
- export { marketplace } from './marketplace';
42
+ export * as tasks from './tasks';
43
+ export * as liveShare from './liveShareHost';
44
+ export { LiveShareHost } from './liveShareHost';
45
+ export * as marketplace from './marketplace';
44
46
  export { ISerializable } from './serializable.interface';
@@ -622,9 +622,20 @@ export interface Context {
622
622
  * @deprecated
623
623
  * As of TeamsJS v2.0.0, please use {@link app.AppInfo.userClickTime | app.Context.app.userClickTime} instead
624
624
  *
625
- * Time when the user clicked on the tab
625
+ * Time when the user clicked on the tab using the date.
626
+ *
627
+ * For measuring elapsed time between the moment the user click the tab, use {@link app.AppInfo.userClickTimeV2 | app.Context.app.userClickTimeV2} instead as it uses the performance timer API.
626
628
  */
627
629
  userClickTime?: number;
630
+ /**
631
+ * @deprecated
632
+ * As of TeamsJS v2.0.0, please use {@link app.AppInfo.userClickTimeV2 | app.Context.app.userClickTimeV2} instead
633
+ *
634
+ * Time when the user click on the app by using the performance timer API. Useful for measuring elapsed time accurately.
635
+ *
636
+ * For displaying the time when the user clicked on the app, please use {@link app.AppInfo.userClickTime | app.Context.app.userClickTime} as it uses the date.
637
+ */
638
+ userClickTimeV2?: number;
628
639
  /**
629
640
  * @deprecated
630
641
  * As of TeamsJS v2.0.0, please use {@link app.TeamInfo.templateId | app.Context.team.templateId} instead
@@ -1131,3 +1142,14 @@ export interface ClipboardParams {
1131
1142
  /** Blob content in Base64 string format */
1132
1143
  content: string;
1133
1144
  }
1145
+ /**
1146
+ * Meant for passing data to the app related to host-to-app message performance metrics.
1147
+ */
1148
+ export interface HostToAppPerformanceMetrics {
1149
+ /** The name of the action the host is responding to. */
1150
+ actionName: string;
1151
+ /** The delay the message took traveling from host to app */
1152
+ messageDelay: number;
1153
+ /** The time when the request was dispatched */
1154
+ requestStartedAt: number;
1155
+ }