@microsoft/teams-js 2.1.0-beta.3 → 2.1.0
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 +4 -4
- package/dist/MicrosoftTeams.d.ts +395 -76
- package/dist/MicrosoftTeams.js +961 -613
- package/dist/MicrosoftTeams.js.map +1 -1
- package/dist/MicrosoftTeams.min.js +1 -1
- package/dist/MicrosoftTeams.min.js.map +1 -1
- package/package.json +34 -1
package/dist/MicrosoftTeams.d.ts
CHANGED
@@ -1943,65 +1943,85 @@ export enum FileOpenPreference {
|
|
1943
1943
|
*/
|
1944
1944
|
export interface Context {
|
1945
1945
|
/**
|
1946
|
-
* @
|
1946
|
+
* @deprecated
|
1947
|
+
* As of 2.0.0, please use {@link app.Context.team.groupId} instead
|
1948
|
+
*
|
1947
1949
|
* The Office 365 group ID for the team with which the content is associated.
|
1948
1950
|
* This field is available only when the identity permission is requested in the manifest.
|
1949
1951
|
*/
|
1950
1952
|
groupId?: string;
|
1951
1953
|
/**
|
1952
|
-
* @
|
1954
|
+
* @deprecated
|
1955
|
+
* As of 2.0.0, please use {@link app.Context.team.internalId} instead
|
1956
|
+
*
|
1953
1957
|
* The Microsoft Teams ID for the team with which the content is associated.
|
1954
1958
|
*/
|
1955
1959
|
teamId?: string;
|
1956
1960
|
/**
|
1957
|
-
* @
|
1961
|
+
* @deprecated
|
1962
|
+
* As of 2.0.0, please use {@link app.Context.team.displayName} instead
|
1963
|
+
*
|
1958
1964
|
* The name for the team with which the content is associated.
|
1959
1965
|
*/
|
1960
1966
|
teamName?: string;
|
1961
1967
|
/**
|
1962
|
-
* @
|
1968
|
+
* @deprecated
|
1969
|
+
* As of 2.0.0, please use {@link app.Context.channel.id} instead
|
1970
|
+
*
|
1963
1971
|
* The Microsoft Teams ID for the channel with which the content is associated.
|
1964
1972
|
*/
|
1965
1973
|
channelId?: string;
|
1966
1974
|
/**
|
1967
|
-
* @
|
1975
|
+
* @deprecated
|
1976
|
+
* As of 2.0.0, please use {@link app.Context.channel.displayName} instead
|
1977
|
+
*
|
1968
1978
|
* The name for the channel with which the content is associated.
|
1969
1979
|
*/
|
1970
1980
|
channelName?: string;
|
1971
1981
|
/**
|
1972
|
-
* @
|
1982
|
+
* @deprecated
|
1983
|
+
* As of 2.0.0, please use {@link app.Context.channel.membershipType} instead
|
1984
|
+
*
|
1973
1985
|
* The type of the channel with which the content is associated.
|
1974
1986
|
*/
|
1975
1987
|
channelType?: ChannelType;
|
1976
1988
|
/**
|
1977
|
-
* @
|
1989
|
+
* @deprecated
|
1990
|
+
* As of 2.0.0, please use {@link app.Context.page.id} instead
|
1991
|
+
*
|
1978
1992
|
* The developer-defined unique ID for the entity this content points to.
|
1979
1993
|
*/
|
1980
1994
|
entityId: string;
|
1981
1995
|
/**
|
1982
|
-
* @
|
1996
|
+
* @deprecated
|
1997
|
+
* As of 2.0.0, please use {@link app.Context.page.subPageId} instead
|
1998
|
+
*
|
1983
1999
|
* The developer-defined unique ID for the sub-entity this content points to.
|
1984
2000
|
* This field should be used to restore to a specific state within an entity,
|
1985
2001
|
* such as scrolling to or activating a specific piece of content.
|
1986
2002
|
*/
|
1987
2003
|
subEntityId?: string;
|
1988
2004
|
/**
|
1989
|
-
* @
|
2005
|
+
* @deprecated
|
2006
|
+
* As of 2.0.0, please use {@link app.Context.app.locale} instead
|
2007
|
+
*
|
1990
2008
|
* The current locale that the user has configured for the app formatted as
|
1991
2009
|
* languageId-countryId (for example, en-us).
|
1992
2010
|
*/
|
1993
2011
|
locale: string;
|
1994
2012
|
/**
|
1995
|
-
* @
|
2013
|
+
* @deprecated
|
2014
|
+
* As of 2.0.0, please use {@link app.Context.app.osLocaleInfo} instead
|
2015
|
+
*
|
1996
2016
|
* More detailed locale info from the user's OS if available. Can be used together with
|
1997
2017
|
* the @microsoft/globe NPM package to ensure your app respects the user's OS date and
|
1998
2018
|
* time format configuration
|
1999
2019
|
*/
|
2000
2020
|
osLocaleInfo?: LocaleInfo;
|
2001
2021
|
/**
|
2002
|
-
* @hidden
|
2003
2022
|
* @deprecated
|
2004
|
-
*
|
2023
|
+
*
|
2024
|
+
* As of 2.0.0, please use {@link app.Context.user.loginHint} or {@link app.Context.user.userPrincipalName} instead.
|
2005
2025
|
* The UPN of the current user.
|
2006
2026
|
* Because a malicious party can run your content in a browser, this value should
|
2007
2027
|
* be used only as a hint as to who the user is and never as proof of identity.
|
@@ -2009,7 +2029,9 @@ export interface Context {
|
|
2009
2029
|
*/
|
2010
2030
|
upn?: string;
|
2011
2031
|
/**
|
2012
|
-
* @
|
2032
|
+
* @deprecated
|
2033
|
+
* As of 2.0.0, please use {@link app.Context.user.tenant.id} instead
|
2034
|
+
*
|
2013
2035
|
* The Azure AD tenant ID of the current user.
|
2014
2036
|
* Because a malicious party can run your content in a browser, this value should
|
2015
2037
|
* be used only as a hint as to who the user is and never as proof of identity.
|
@@ -2017,69 +2039,95 @@ export interface Context {
|
|
2017
2039
|
*/
|
2018
2040
|
tid?: string;
|
2019
2041
|
/**
|
2020
|
-
* @
|
2042
|
+
* @deprecated
|
2043
|
+
* As of 2.0.0, please use {@link app.Context.app.theme} instead
|
2044
|
+
*
|
2021
2045
|
* The current UI theme.
|
2022
2046
|
*/
|
2023
2047
|
theme?: string;
|
2024
2048
|
/**
|
2025
|
-
* @
|
2049
|
+
* @deprecated
|
2050
|
+
* As of 2.0.0, please use {@link app.Context.page.isFullScreen} instead
|
2051
|
+
*
|
2026
2052
|
* Indication whether the tab is in full-screen mode.
|
2027
2053
|
*/
|
2028
2054
|
isFullScreen?: boolean;
|
2029
2055
|
/**
|
2030
|
-
* @
|
2056
|
+
* @deprecated
|
2057
|
+
* As of 2.0.0, please use {@link app.Context.team.type} instead
|
2058
|
+
*
|
2031
2059
|
* The type of the team.
|
2032
2060
|
*/
|
2033
2061
|
teamType?: TeamType;
|
2034
2062
|
/**
|
2035
|
-
* @
|
2063
|
+
* @deprecated
|
2064
|
+
* As of 2.0.0, please use {@link app.Context.sharePointSite.teamSiteUrl} instead
|
2065
|
+
*
|
2036
2066
|
* The root SharePoint site associated with the team.
|
2037
2067
|
*/
|
2038
2068
|
teamSiteUrl?: string;
|
2039
2069
|
/**
|
2040
|
-
* @
|
2070
|
+
* @deprecated
|
2071
|
+
* As of 2.0.0, please use {@link app.Context.sharePointSite.teamSiteDomain} instead
|
2072
|
+
*
|
2041
2073
|
* The domain of the root SharePoint site associated with the team.
|
2042
2074
|
*/
|
2043
2075
|
teamSiteDomain?: string;
|
2044
2076
|
/**
|
2045
|
-
* @
|
2077
|
+
* @deprecated
|
2078
|
+
* As of 2.0.0, please use {@link app.Context.sharePointSite.teamSitePath} instead
|
2079
|
+
*
|
2046
2080
|
* The relative path to the SharePoint site associated with the team.
|
2047
2081
|
*/
|
2048
2082
|
teamSitePath?: string;
|
2049
2083
|
/**
|
2050
|
-
* @
|
2084
|
+
* @deprecated
|
2085
|
+
* As of 2.0.0, please use {@link app.Context.channel.ownerTeamTenantId} instead
|
2086
|
+
*
|
2051
2087
|
* The tenant ID of the host team.
|
2052
2088
|
*/
|
2053
2089
|
hostTeamTenantId?: string;
|
2054
2090
|
/**
|
2055
|
-
* @
|
2091
|
+
* @deprecated
|
2092
|
+
* As of 2.0.0, please use {@link app.Context.channel.ownerGroupId} instead
|
2093
|
+
*
|
2056
2094
|
* The AAD group ID of the host team.
|
2057
2095
|
*/
|
2058
2096
|
hostTeamGroupId?: string;
|
2059
2097
|
/**
|
2060
|
-
* @
|
2098
|
+
* @deprecated
|
2099
|
+
* As of 2.0.0, please use {@link app.Context.channel.relativeUrl} instead
|
2100
|
+
*
|
2061
2101
|
* The relative path to the SharePoint folder associated with the channel.
|
2062
2102
|
*/
|
2063
2103
|
channelRelativeUrl?: string;
|
2064
2104
|
/**
|
2065
|
-
* @
|
2105
|
+
* @deprecated
|
2106
|
+
* As of 2.0.0, please use {@link app.Context.app.host.sessionId} instead
|
2107
|
+
*
|
2066
2108
|
* Unique ID for the current Teams session for use in correlating telemetry data.
|
2067
2109
|
*/
|
2068
2110
|
sessionId?: string;
|
2069
2111
|
/**
|
2070
|
-
* @
|
2112
|
+
* @deprecated
|
2113
|
+
* As of 2.0.0, please use {@link app.Context.team.userRole} instead
|
2114
|
+
*
|
2071
2115
|
* The user's role in the team.
|
2072
2116
|
* Because a malicious party can run your content in a browser, this value should
|
2073
2117
|
* be used only as a hint as to the user's role, and never as proof of her role.
|
2074
2118
|
*/
|
2075
2119
|
userTeamRole?: UserTeamRole;
|
2076
2120
|
/**
|
2077
|
-
* @
|
2121
|
+
* @deprecated
|
2122
|
+
* As of 2.0.0, please use {@link app.Context.chat.id} instead
|
2123
|
+
*
|
2078
2124
|
* The Microsoft Teams ID for the chat with which the content is associated.
|
2079
2125
|
*/
|
2080
2126
|
chatId?: string;
|
2081
2127
|
/**
|
2082
|
-
* @
|
2128
|
+
* @deprecated
|
2129
|
+
* As of 2.0.0, please use {@link app.Context.user.loginHint} instead
|
2130
|
+
*
|
2083
2131
|
* A value suitable for use as a login_hint when authenticating with Azure AD.
|
2084
2132
|
* Because a malicious party can run your content in a browser, this value should
|
2085
2133
|
* be used only as a hint as to who the user is and never as proof of identity.
|
@@ -2087,7 +2135,9 @@ export interface Context {
|
|
2087
2135
|
*/
|
2088
2136
|
loginHint?: string;
|
2089
2137
|
/**
|
2090
|
-
* @
|
2138
|
+
* @deprecated
|
2139
|
+
* As of 2.0.0, please use {@link app.Context.user.userPrincipalName} instead
|
2140
|
+
*
|
2091
2141
|
* The UPN of the current user. This may be an externally-authenticated UPN (e.g., guest users).
|
2092
2142
|
* Because a malicious party run your content in a browser, this value should
|
2093
2143
|
* be used only as a hint as to who the user is and never as proof of identity.
|
@@ -2095,7 +2145,9 @@ export interface Context {
|
|
2095
2145
|
*/
|
2096
2146
|
userPrincipalName?: string;
|
2097
2147
|
/**
|
2098
|
-
* @
|
2148
|
+
* @deprecated
|
2149
|
+
* As of 2.0.0, please use {@link app.Context.user.id} instead
|
2150
|
+
*
|
2099
2151
|
* The Azure AD object id of the current user.
|
2100
2152
|
* Because a malicious party run your content in a browser, this value should
|
2101
2153
|
* be used only as a hint as to who the user is and never as proof of identity.
|
@@ -2103,130 +2155,180 @@ export interface Context {
|
|
2103
2155
|
*/
|
2104
2156
|
userObjectId?: string;
|
2105
2157
|
/**
|
2106
|
-
* @
|
2158
|
+
* @deprecated
|
2159
|
+
* As of 2.0.0, please use {@link app.Context.team.isArchived} instead
|
2160
|
+
*
|
2107
2161
|
* Indicates whether team is archived.
|
2108
2162
|
* Apps should use this as a signal to prevent any changes to content associated with archived teams.
|
2109
2163
|
*/
|
2110
2164
|
isTeamArchived?: boolean;
|
2111
2165
|
/**
|
2112
|
-
* @
|
2166
|
+
* @deprecated
|
2167
|
+
* As of 2.0.0, please use {@link app.Context.host.name} instead
|
2168
|
+
*
|
2113
2169
|
* The name of the host client. Possible values are: Office, Orange, Outlook, Teams
|
2114
2170
|
*/
|
2115
2171
|
hostName?: HostName;
|
2116
2172
|
/**
|
2117
|
-
* @
|
2173
|
+
* @deprecated
|
2174
|
+
* As of 2.0.0, please use {@link app.Context.host.clientType} instead
|
2175
|
+
*
|
2118
2176
|
* The type of the host client. Possible values are : android, ios, web, desktop, rigel(deprecated, use teamsRoomsWindows instead),
|
2119
2177
|
* surfaceHub, teamsRoomsWindows, teamsRoomsAndroid, teamsPhones, teamsDisplays
|
2120
2178
|
*/
|
2121
2179
|
hostClientType?: HostClientType;
|
2122
2180
|
/**
|
2123
|
-
* @
|
2181
|
+
* @deprecated
|
2182
|
+
* As of 2.0.0, please use {@link app.Context.page.frameContext} instead
|
2183
|
+
*
|
2124
2184
|
* The context where tab url is loaded (content, task, setting, remove, sidePanel)
|
2125
2185
|
*/
|
2126
2186
|
frameContext?: FrameContexts;
|
2127
2187
|
/**
|
2128
|
-
* @
|
2188
|
+
* @deprecated
|
2189
|
+
* As of 2.0.0, please use {@link app.Context.sharepoint} instead
|
2190
|
+
*
|
2129
2191
|
* SharePoint context. This is only available when hosted in SharePoint.
|
2130
2192
|
*/
|
2131
2193
|
sharepoint?: any;
|
2132
2194
|
/**
|
2133
|
-
* @
|
2195
|
+
* @deprecated
|
2196
|
+
* As of 2.0.0, please use {@link app.Context.user.tenant.teamsSku} instead
|
2197
|
+
*
|
2134
2198
|
* The type of license for the current users tenant.
|
2135
2199
|
*/
|
2136
2200
|
tenantSKU?: string;
|
2137
2201
|
/**
|
2138
|
-
* @
|
2202
|
+
* @deprecated
|
2203
|
+
* As of 2.0.0, please use {@link app.Context.user.licenseType} instead
|
2204
|
+
*
|
2139
2205
|
* The license type for the current user.
|
2140
2206
|
*/
|
2141
2207
|
userLicenseType?: string;
|
2142
2208
|
/**
|
2143
|
-
* @
|
2209
|
+
* @deprecated
|
2210
|
+
* As of 2.0.0, please use {@link app.Context.app.parentMessageId} instead
|
2211
|
+
*
|
2144
2212
|
* The ID of the parent message from which this task module was launched.
|
2145
2213
|
* This is only available in task modules launched from bot cards.
|
2146
2214
|
*/
|
2147
2215
|
parentMessageId?: string;
|
2148
2216
|
/**
|
2149
|
-
* @
|
2217
|
+
* @deprecated
|
2218
|
+
* As of 2.0.0, please use {@link app.Context.app.host.ringId} instead
|
2219
|
+
*
|
2150
2220
|
* Current ring ID
|
2151
2221
|
*/
|
2152
2222
|
ringId?: string;
|
2153
2223
|
/**
|
2154
|
-
* @
|
2224
|
+
* @deprecated
|
2225
|
+
* As of 2.0.0, please use {@link app.Context.app.sessionId} instead
|
2226
|
+
*
|
2155
2227
|
* Unique ID for the current session for use in correlating telemetry data.
|
2156
2228
|
*/
|
2157
2229
|
appSessionId?: string;
|
2158
2230
|
/**
|
2159
|
-
* @
|
2231
|
+
* @deprecated
|
2232
|
+
* As of 2.0.0, please use {@link app.Context.app.appLaunchId} instead
|
2233
|
+
*
|
2160
2234
|
* ID for the current visible app which is different for across cached sessions. Used for correlating telemetry data``
|
2161
2235
|
*/
|
2162
2236
|
appLaunchId?: string;
|
2163
2237
|
/**
|
2164
|
-
* @
|
2238
|
+
* @deprecated
|
2239
|
+
* As of 2.0.0, please use {@link app.Context.user.isCallingAllowed} instead
|
2240
|
+
*
|
2165
2241
|
* Represents whether calling is allowed for the current logged in User
|
2166
2242
|
*/
|
2167
2243
|
isCallingAllowed?: boolean;
|
2168
2244
|
/**
|
2169
|
-
* @
|
2245
|
+
* @deprecated
|
2246
|
+
* As of 2.0.0, please use {@link app.Context.user.isPSTNCallingAllowed} instead
|
2247
|
+
*
|
2170
2248
|
* Represents whether PSTN calling is allowed for the current logged in User
|
2171
2249
|
*/
|
2172
2250
|
isPSTNCallingAllowed?: boolean;
|
2173
2251
|
/**
|
2174
|
-
* @
|
2252
|
+
* @deprecated
|
2253
|
+
* As of 2.0.0, please use {@link app.Context.meeting.id} instead
|
2254
|
+
*
|
2175
2255
|
* Meeting Id used by tab when running in meeting context
|
2176
2256
|
*/
|
2177
2257
|
meetingId?: string;
|
2178
2258
|
/**
|
2179
|
-
* @
|
2259
|
+
* @deprecated
|
2260
|
+
* As of 2.0.0, please use {@link app.Context.channel.defaultOneNoteSectionId} instead
|
2261
|
+
*
|
2180
2262
|
* The OneNote section ID that is linked to the channel.
|
2181
2263
|
*/
|
2182
2264
|
defaultOneNoteSectionId?: string;
|
2183
2265
|
/**
|
2184
|
-
* @
|
2266
|
+
* @deprecated
|
2267
|
+
* As of 2.0.0, please use {@link app.Context.page.isMultiWindow} instead
|
2268
|
+
*
|
2185
2269
|
* Indication whether the tab is in a pop out window
|
2186
2270
|
*/
|
2187
2271
|
isMultiWindow?: boolean;
|
2188
2272
|
/**
|
2189
|
-
* @
|
2273
|
+
* @deprecated
|
2274
|
+
* As of 2.0.0, please use {@link app.Context.app.iconPositionVertical} instead
|
2275
|
+
*
|
2190
2276
|
* Personal app icon y coordinate position
|
2191
2277
|
*/
|
2192
2278
|
appIconPosition?: number;
|
2193
2279
|
/**
|
2194
|
-
* @
|
2280
|
+
* @deprecated
|
2281
|
+
* As of 2.0.0, please use {@link app.Context.page.sourceOrigin} instead
|
2282
|
+
*
|
2195
2283
|
* Source origin from where the tab is opened
|
2196
2284
|
*/
|
2197
2285
|
sourceOrigin?: string;
|
2198
2286
|
/**
|
2199
|
-
* @
|
2287
|
+
* @deprecated
|
2288
|
+
* As of 2.0.0, please use {@link app.Context.app.userClickTime} instead
|
2289
|
+
*
|
2200
2290
|
* Time when the user clicked on the tab
|
2201
2291
|
*/
|
2202
2292
|
userClickTime?: number;
|
2203
2293
|
/**
|
2204
|
-
* @
|
2294
|
+
* @deprecated
|
2295
|
+
* As of 2.0.0, please use {@link app.Context.team.templateId} instead
|
2296
|
+
*
|
2205
2297
|
* Team Template ID if there was a Team Template associated with the creation of the team.
|
2206
2298
|
*/
|
2207
2299
|
teamTemplateId?: string;
|
2208
2300
|
/**
|
2209
|
-
* @
|
2301
|
+
* @deprecated
|
2302
|
+
* As of 2.0.0, please use {@link app.Context.app.userFileOpenPreference} instead
|
2303
|
+
*
|
2210
2304
|
* Where the user prefers the file to be opened from by default during file open
|
2211
2305
|
*/
|
2212
2306
|
userFileOpenPreference?: FileOpenPreference;
|
2213
2307
|
/**
|
2214
|
-
* @
|
2308
|
+
* @deprecated
|
2309
|
+
* As of 2.0.0, please use {@link app.Context.user.displayName} instead
|
2310
|
+
*
|
2215
2311
|
* The address book name of the current user.
|
2216
2312
|
*/
|
2217
2313
|
userDisplayName?: string;
|
2218
2314
|
/**
|
2219
|
-
* @
|
2315
|
+
* @deprecated
|
2316
|
+
* As of 2.0.0, please use {@link app.Context.sharePointSite.teamSiteId} instead
|
2317
|
+
*
|
2220
2318
|
* Teamsite ID, aka sharepoint site id.
|
2221
2319
|
*/
|
2222
2320
|
teamSiteId?: string;
|
2223
2321
|
/**
|
2224
|
-
* @
|
2322
|
+
* @deprecated
|
2323
|
+
* As of 2.0.0, please use {@link app.Context.sharePointSite.mySiteDomain} instead
|
2324
|
+
*
|
2225
2325
|
* The SharePoint my site domain associated with the user.
|
2226
2326
|
*/
|
2227
2327
|
mySiteDomain?: string;
|
2228
2328
|
/**
|
2229
|
-
* @
|
2329
|
+
* @deprecated
|
2330
|
+
* As of 2.0.0, please use {@link app.Context.sharePointSite.mySitePath} instead
|
2331
|
+
*
|
2230
2332
|
* The SharePoint relative path to the current users mysite
|
2231
2333
|
*/
|
2232
2334
|
mySitePath?: string;
|
@@ -2468,6 +2570,11 @@ export enum ErrorCode {
|
|
2468
2570
|
*/
|
2469
2571
|
SIZE_EXCEEDED = 10000
|
2470
2572
|
}
|
2573
|
+
/** @hidden */
|
2574
|
+
export enum DevicePermission {
|
2575
|
+
GeoLocation = "geolocation",
|
2576
|
+
Media = "media"
|
2577
|
+
}
|
2471
2578
|
|
2472
2579
|
/**
|
2473
2580
|
* Namespace to interact with app initialization and lifecycle.
|
@@ -2961,6 +3068,61 @@ export namespace appInstallDialog {
|
|
2961
3068
|
function isSupported(): boolean;
|
2962
3069
|
}
|
2963
3070
|
|
3071
|
+
/**
|
3072
|
+
* Namespace to interact with the barcode scanning-specific part of the SDK.
|
3073
|
+
*
|
3074
|
+
* @beta
|
3075
|
+
*/
|
3076
|
+
export namespace barCode {
|
3077
|
+
/**
|
3078
|
+
* Data structure to customize the barcode scanning experience in scanBarCode API.
|
3079
|
+
* All properties in BarCodeConfig are optional and have default values in the platform
|
3080
|
+
*
|
3081
|
+
* @beta
|
3082
|
+
*/
|
3083
|
+
interface BarCodeConfig {
|
3084
|
+
/**
|
3085
|
+
* Optional; designates the scan timeout interval in seconds.
|
3086
|
+
* Default value is 30 seconds, max allowed value is 60 seconds.
|
3087
|
+
*/
|
3088
|
+
timeOutIntervalInSec?: number;
|
3089
|
+
}
|
3090
|
+
/**
|
3091
|
+
* Scan Barcode or QRcode using camera
|
3092
|
+
*
|
3093
|
+
* @param barCodeConfig - input configuration to customize the barcode scanning experience
|
3094
|
+
*
|
3095
|
+
* @returns a scanned code
|
3096
|
+
*
|
3097
|
+
* @beta
|
3098
|
+
*/
|
3099
|
+
function scanBarCode(barCodeConfig: BarCodeConfig): Promise<string>;
|
3100
|
+
/**
|
3101
|
+
* Checks whether or not media has user permission
|
3102
|
+
*
|
3103
|
+
* @returns true if the user has granted the app permission to media information, false otherwise
|
3104
|
+
*
|
3105
|
+
* @beta
|
3106
|
+
*/
|
3107
|
+
function hasPermission(): Promise<boolean>;
|
3108
|
+
/**
|
3109
|
+
* Requests user permission for media
|
3110
|
+
*
|
3111
|
+
* @returns true if the user has granted the app permission to the media, false otherwise
|
3112
|
+
*
|
3113
|
+
* @beta
|
3114
|
+
*/
|
3115
|
+
function requestPermission(): Promise<boolean>;
|
3116
|
+
/**
|
3117
|
+
* Checks if barCode capability is supported by the host
|
3118
|
+
*
|
3119
|
+
* @returns boolean to represent whether barCode is supported
|
3120
|
+
*
|
3121
|
+
* @beta
|
3122
|
+
*/
|
3123
|
+
function isSupported(): boolean;
|
3124
|
+
}
|
3125
|
+
|
2964
3126
|
/**
|
2965
3127
|
* Describes information needed to start a chat
|
2966
3128
|
*
|
@@ -3170,6 +3332,103 @@ export namespace dialog {
|
|
3170
3332
|
function getDialogInfoFromBotUrlDialogInfo(botUrlDialogInfo: BotUrlDialogInfo): DialogInfo;
|
3171
3333
|
}
|
3172
3334
|
|
3335
|
+
/**
|
3336
|
+
* Namespace to interact with the geoLocation module-specific part of the SDK. This is the newer version of location module.
|
3337
|
+
*
|
3338
|
+
* @beta
|
3339
|
+
*/
|
3340
|
+
export namespace geoLocation {
|
3341
|
+
/**
|
3342
|
+
* Data struture to represent the location information
|
3343
|
+
*
|
3344
|
+
* @beta
|
3345
|
+
*/
|
3346
|
+
interface Location {
|
3347
|
+
/**
|
3348
|
+
Latitude of the location
|
3349
|
+
*/
|
3350
|
+
latitude: number;
|
3351
|
+
/**
|
3352
|
+
Longitude of the location
|
3353
|
+
*/
|
3354
|
+
longitude: number;
|
3355
|
+
/**
|
3356
|
+
Accuracy of the coordinates captured
|
3357
|
+
*/
|
3358
|
+
accuracy?: number;
|
3359
|
+
/**
|
3360
|
+
Time stamp when the location was captured
|
3361
|
+
*/
|
3362
|
+
timestamp?: number;
|
3363
|
+
}
|
3364
|
+
/**
|
3365
|
+
* Fetches current user coordinates
|
3366
|
+
* @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
|
3367
|
+
*
|
3368
|
+
* @beta
|
3369
|
+
*/
|
3370
|
+
function getCurrentLocation(): Promise<Location>;
|
3371
|
+
/**
|
3372
|
+
* Checks whether or not location has user permission
|
3373
|
+
*
|
3374
|
+
* @returns Promise that will resolve with true if the user had granted the app permission to location information, or with false otherwise,
|
3375
|
+
* In case of an error, promise will reject with the error. Function can also throw a NOT_SUPPORTED_ON_PLATFORM error
|
3376
|
+
*
|
3377
|
+
* @beta
|
3378
|
+
*/
|
3379
|
+
function hasPermission(): Promise<boolean>;
|
3380
|
+
/**
|
3381
|
+
* Requests user permission for location
|
3382
|
+
*
|
3383
|
+
* @returns true if the user consented permission for location, false otherwise
|
3384
|
+
* @returns Promise that will resolve with true if the user consented permission for location, or with false otherwise,
|
3385
|
+
* In case of an error, promise will reject with the error. Function can also throw a NOT_SUPPORTED_ON_PLATFORM error
|
3386
|
+
*
|
3387
|
+
* @beta
|
3388
|
+
*/
|
3389
|
+
function requestPermission(): Promise<boolean>;
|
3390
|
+
/**
|
3391
|
+
* Checks if geoLocation capability is supported by the host
|
3392
|
+
*
|
3393
|
+
* @returns boolean to represent whether geoLocation is supported
|
3394
|
+
*
|
3395
|
+
* @beta
|
3396
|
+
*/
|
3397
|
+
function isSupported(): boolean;
|
3398
|
+
/**
|
3399
|
+
* Namespace to interact with the location on map module-specific part of the SDK.
|
3400
|
+
*
|
3401
|
+
* @beta
|
3402
|
+
*/
|
3403
|
+
namespace map {
|
3404
|
+
/**
|
3405
|
+
* Allows user to choose location on map
|
3406
|
+
*
|
3407
|
+
* @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
|
3408
|
+
*
|
3409
|
+
* @beta
|
3410
|
+
*/
|
3411
|
+
function chooseLocation(): Promise<Location>;
|
3412
|
+
/**
|
3413
|
+
* Shows the location on map corresponding to the given coordinates
|
3414
|
+
*
|
3415
|
+
* @param location - Location to be shown on the map
|
3416
|
+
* @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
|
3417
|
+
*
|
3418
|
+
* @beta
|
3419
|
+
*/
|
3420
|
+
function showLocation(location: Location): Promise<void>;
|
3421
|
+
/**
|
3422
|
+
* Checks if geoLocation.map capability is supported by the host
|
3423
|
+
*
|
3424
|
+
* @returns boolean to represent whether geoLocation.map is supported
|
3425
|
+
*
|
3426
|
+
* @beta
|
3427
|
+
*/
|
3428
|
+
function isSupported(): boolean;
|
3429
|
+
}
|
3430
|
+
}
|
3431
|
+
|
3173
3432
|
/**
|
3174
3433
|
* Navigation-specific part of the SDK.
|
3175
3434
|
*
|
@@ -4078,6 +4337,9 @@ export namespace media {
|
|
4078
4337
|
timeOutIntervalInSec?: number;
|
4079
4338
|
}
|
4080
4339
|
/**
|
4340
|
+
* @deprecated
|
4341
|
+
* As of 2.1.0, please use {@link barCode.scanBarCode barCode.scanBarCode(config?: BarCodeConfig): Promise\<string\>} instead.
|
4342
|
+
|
4081
4343
|
* Scan Barcode/QRcode using camera
|
4082
4344
|
*
|
4083
4345
|
* @remarks
|
@@ -4090,7 +4352,17 @@ export namespace media {
|
|
4090
4352
|
export {};
|
4091
4353
|
}
|
4092
4354
|
|
4355
|
+
/**
|
4356
|
+
* @deprecated
|
4357
|
+
* As of 2.1.0, please use geoLocation namespace.
|
4358
|
+
*
|
4359
|
+
* Namespace to interact with the location module-specific part of the SDK.
|
4360
|
+
*/
|
4093
4361
|
export namespace location {
|
4362
|
+
/**
|
4363
|
+
* @deprecated
|
4364
|
+
* Data Structure to set the location properties in getLocation call.
|
4365
|
+
*/
|
4094
4366
|
interface LocationProps {
|
4095
4367
|
/**
|
4096
4368
|
whether user can alter location or not
|
@@ -4106,6 +4378,10 @@ export namespace location {
|
|
4106
4378
|
*/
|
4107
4379
|
showMap?: boolean;
|
4108
4380
|
}
|
4381
|
+
/**
|
4382
|
+
* @deprecated
|
4383
|
+
* Data struture to represent the location information
|
4384
|
+
*/
|
4109
4385
|
interface Location {
|
4110
4386
|
/**
|
4111
4387
|
Latitude of the location
|
@@ -4124,36 +4400,35 @@ export namespace location {
|
|
4124
4400
|
*/
|
4125
4401
|
timestamp?: number;
|
4126
4402
|
}
|
4127
|
-
/**
|
4128
|
-
* Fetches current user coordinates or allows user to choose location on map
|
4129
|
-
*
|
4130
|
-
* @param props {@link LocationProps} - Specifying how the location request is handled
|
4131
|
-
* @returns Promise that will be fulfilled when the operation has completed
|
4132
|
-
*/
|
4133
|
-
function getLocation(props: LocationProps): Promise<Location>;
|
4134
4403
|
/**
|
4135
4404
|
* @deprecated
|
4136
|
-
* As of 2.
|
4405
|
+
* As of 2.1.0, please use one of the following functions:
|
4406
|
+
* - {@link geoLocation.getCurrentLocation geoLocation.getCurrentLocation(): Promise\<Location\>} to get the current location.
|
4407
|
+
* - {@link geoLocation.map.chooseLocation geoLocation.map.chooseLocation(): Promise\<Location\>} to choose location on map.
|
4408
|
+
*
|
4409
|
+
* Fetches user location
|
4137
4410
|
* @param props {@link LocationProps} - Specifying how the location request is handled
|
4138
4411
|
* @param callback - Callback to invoke when current user location is fetched
|
4139
4412
|
*/
|
4140
4413
|
function getLocation(props: LocationProps, callback: (error: SdkError, location: Location) => void): void;
|
4141
4414
|
/**
|
4415
|
+
* @deprecated
|
4416
|
+
* As of 2.1.0, please use {@link geoLocation.map.showLocation geoLocation.map.showLocation(location: Location): Promise\<void\>} instead.
|
4417
|
+
*
|
4142
4418
|
* Shows the location on map corresponding to the given coordinates
|
4143
4419
|
*
|
4144
|
-
* @param location
|
4145
|
-
* @
|
4420
|
+
* @param location - Location to be shown on the map
|
4421
|
+
* @param callback - Callback to invoke when the location is opened on map
|
4146
4422
|
*/
|
4147
|
-
function showLocation(location: Location):
|
4423
|
+
function showLocation(location: Location, callback: (error: SdkError, status: boolean) => void): void;
|
4148
4424
|
/**
|
4149
4425
|
* @deprecated
|
4150
|
-
* As of 2.
|
4151
|
-
*
|
4152
|
-
*
|
4153
|
-
*
|
4426
|
+
* As of 2.1.0, please use geoLocation namespace, and use {@link geoLocation.isSupported geoLocation.isSupported: boolean} to check if geoLocation is supported.
|
4427
|
+
*
|
4428
|
+
* Checks if Location capability is supported by the host
|
4429
|
+
*
|
4430
|
+
* @returns boolean to represent whether Location is supported
|
4154
4431
|
*/
|
4155
|
-
function showLocation(location: Location, callback: (error: SdkError, status: boolean) => void): void;
|
4156
|
-
function showLocationHelper(location: Location): Promise<void>;
|
4157
4432
|
function isSupported(): boolean;
|
4158
4433
|
}
|
4159
4434
|
|
@@ -4802,10 +5077,12 @@ export namespace profile {
|
|
4802
5077
|
|
4803
5078
|
/**
|
4804
5079
|
* Namespace to video extensibility of the SDK
|
5080
|
+
* @beta
|
4805
5081
|
*/
|
4806
5082
|
export namespace video {
|
4807
5083
|
/**
|
4808
5084
|
* Represents a video frame
|
5085
|
+
* @beta
|
4809
5086
|
*/
|
4810
5087
|
interface VideoFrame {
|
4811
5088
|
/**
|
@@ -4835,21 +5112,24 @@ export namespace video {
|
|
4835
5112
|
}
|
4836
5113
|
/**
|
4837
5114
|
* Video frame format enum, currently only support NV12
|
5115
|
+
* @beta
|
4838
5116
|
*/
|
4839
5117
|
enum VideoFrameFormat {
|
4840
5118
|
NV12 = 0
|
4841
5119
|
}
|
4842
5120
|
/**
|
4843
5121
|
* Video frame configuration supplied to the host to customize the generated video frame parameters, like format
|
5122
|
+
* @beta
|
4844
5123
|
*/
|
4845
5124
|
interface VideoFrameConfig {
|
4846
5125
|
/**
|
4847
|
-
*
|
5126
|
+
* Video format
|
4848
5127
|
*/
|
4849
5128
|
format: VideoFrameFormat;
|
4850
5129
|
}
|
4851
5130
|
/**
|
4852
|
-
*
|
5131
|
+
* Video effect change type enum
|
5132
|
+
* @beta
|
4853
5133
|
*/
|
4854
5134
|
enum EffectChangeType {
|
4855
5135
|
/**
|
@@ -4862,35 +5142,40 @@ export namespace video {
|
|
4862
5142
|
EffectDisabled = 1
|
4863
5143
|
}
|
4864
5144
|
/**
|
4865
|
-
*
|
5145
|
+
* Video frame call back function definition
|
5146
|
+
* @beta
|
4866
5147
|
*/
|
4867
5148
|
type VideoFrameCallback = (frame: VideoFrame, notifyVideoFrameProcessed: () => void, notifyError: (errorMessage: string) => void) => void;
|
4868
5149
|
/**
|
4869
|
-
*
|
5150
|
+
* Video effect change call back function definition
|
5151
|
+
* @beta
|
4870
5152
|
*/
|
4871
5153
|
type VideoEffectCallBack = (effectId: string | undefined) => void;
|
4872
5154
|
/**
|
4873
5155
|
* Register to read the video frames in Permissions section
|
5156
|
+
* @beta
|
4874
5157
|
* @param frameCallback - The callback to invoke when registerForVideoFrame has completed
|
4875
5158
|
* @param config - VideoFrameConfig to customize generated video frame parameters
|
4876
5159
|
*/
|
4877
5160
|
function registerForVideoFrame(frameCallback: VideoFrameCallback, config: VideoFrameConfig): void;
|
4878
5161
|
/**
|
4879
|
-
*
|
5162
|
+
* Video extension should call this to notify host client that the current selected effect parameter changed.
|
4880
5163
|
* If it's pre-meeting, host client will call videoEffectCallback immediately then use the videoEffect.
|
4881
5164
|
* If it's the in-meeting scenario, we will call videoEffectCallback when apply button clicked.
|
4882
|
-
*
|
5165
|
+
* @beta
|
4883
5166
|
* @param effectChangeType - the effect change type.
|
4884
5167
|
* @param effectId - Newly selected effect id.
|
4885
5168
|
*/
|
4886
5169
|
function notifySelectedVideoEffectChanged(effectChangeType: EffectChangeType, effectId: string | undefined): void;
|
4887
5170
|
/**
|
4888
5171
|
* Register the video effect callback, host client uses this to notify the video extension the new video effect will by applied
|
5172
|
+
* @beta
|
4889
5173
|
* @param callback - The VideoEffectCallback to invoke when registerForVideoEffect has completed
|
4890
5174
|
*/
|
4891
5175
|
function registerForVideoEffect(callback: VideoEffectCallBack): void;
|
4892
5176
|
/**
|
4893
5177
|
* Checks if video capability is supported by the host
|
5178
|
+
* @beta
|
4894
5179
|
* @returns true if the video capability is enabled in runtime.supports.video and
|
4895
5180
|
* false if it is disabled
|
4896
5181
|
*/
|
@@ -4949,6 +5234,8 @@ export namespace sharing {
|
|
4949
5234
|
|
4950
5235
|
/**
|
4951
5236
|
* Namespace to interact with the stage view specific part of the SDK.
|
5237
|
+
*
|
5238
|
+
* @beta
|
4952
5239
|
*/
|
4953
5240
|
export namespace stageView {
|
4954
5241
|
/**
|
@@ -4985,10 +5272,42 @@ export namespace stageView {
|
|
4985
5272
|
* Feature is under development
|
4986
5273
|
*
|
4987
5274
|
* Opens a stage view to display a Teams application
|
5275
|
+
* @beta
|
4988
5276
|
* @param stageViewParams - The parameters to pass into the stage view.
|
4989
5277
|
* @returns Promise that resolves or rejects with an error once the stage view is closed.
|
4990
5278
|
*/
|
4991
5279
|
function open(stageViewParams: StageViewParams): Promise<void>;
|
5280
|
+
/**
|
5281
|
+
* Checks if stageView capability is supported by the host
|
5282
|
+
* @beta
|
5283
|
+
* @returns true if the stageView capability is enabled in runtime.supports.stageView and
|
5284
|
+
* false if it is disabled
|
5285
|
+
*/
|
5286
|
+
function isSupported(): boolean;
|
5287
|
+
}
|
5288
|
+
|
5289
|
+
/**
|
5290
|
+
* Contains functionality to allow web apps to store data in webview cache
|
5291
|
+
*
|
5292
|
+
* @beta
|
5293
|
+
*/
|
5294
|
+
export namespace webStorage {
|
5295
|
+
/**
|
5296
|
+
* Checks if web storage gets cleared when a user logs out from host client
|
5297
|
+
*
|
5298
|
+
* @returns true is web storage gets cleared on logout and false if it does not
|
5299
|
+
*
|
5300
|
+
* @beta
|
5301
|
+
*/
|
5302
|
+
function isWebStorageClearedOnUserLogOut(): boolean;
|
5303
|
+
/**
|
5304
|
+
* Checks if webStorage capability is supported by the host
|
5305
|
+
* @returns true if the webStorage capability is enabled in runtime.supports.webStorage and
|
5306
|
+
* false if it is disabled
|
5307
|
+
*
|
5308
|
+
* @beta
|
5309
|
+
*/
|
5310
|
+
function isSupported(): boolean;
|
4992
5311
|
}
|
4993
5312
|
|
4994
5313
|
export namespace call {
|