@microsoft/teamsfx 2.2.3-alpha.0c7c513de.0 → 2.2.3-alpha.13d1e618d.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 +5 -6
- package/dist/index.esm2017.js +18 -18
- package/dist/index.esm2017.js.map +1 -1
- package/dist/index.esm2017.mjs +43 -29
- package/dist/index.esm2017.mjs.map +1 -1
- package/dist/index.esm5.js +15 -43
- package/dist/index.esm5.js.map +1 -1
- package/dist/index.node.cjs.js +85 -77
- package/dist/index.node.cjs.js.map +1 -1
- package/package.json +4 -4
- package/types/teamsfx.d.ts +9 -2
package/dist/index.esm5.js
CHANGED
@@ -881,7 +881,7 @@ class MsGraphAuthProvider {
|
|
881
881
|
* };
|
882
882
|
* const prompt = new TeamsBotSsoPrompt(dialogId, {
|
883
883
|
* config: config
|
884
|
-
* scopes:
|
884
|
+
* scopes: ["User.Read"],
|
885
885
|
* });
|
886
886
|
* this.addDialog(prompt);
|
887
887
|
*
|
@@ -1187,9 +1187,7 @@ class BasicAuthProvider {
|
|
1187
1187
|
* @throws {@link ErrorCode|RuntimeNotSupported} when runtime is browser.
|
1188
1188
|
*/
|
1189
1189
|
AddAuthenticationInfo(config) {
|
1190
|
-
return
|
1191
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "BasicAuthProvider"), ErrorCode.RuntimeNotSupported);
|
1192
|
-
});
|
1190
|
+
return Promise.reject(new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "BasicAuthProvider"), ErrorCode.RuntimeNotSupported));
|
1193
1191
|
}
|
1194
1192
|
}
|
1195
1193
|
|
@@ -1222,9 +1220,7 @@ class ApiKeyProvider {
|
|
1222
1220
|
* @throws {@link ErrorCode|RuntimeNotSupported} when runtime is browser.
|
1223
1221
|
*/
|
1224
1222
|
AddAuthenticationInfo(config) {
|
1225
|
-
return
|
1226
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "ApiKeyProvider"), ErrorCode.RuntimeNotSupported);
|
1227
|
-
});
|
1223
|
+
return Promise.reject(new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "ApiKeyProvider"), ErrorCode.RuntimeNotSupported));
|
1228
1224
|
}
|
1229
1225
|
}
|
1230
1226
|
/**
|
@@ -1266,9 +1262,7 @@ class CertificateAuthProvider {
|
|
1266
1262
|
* @throws {@link ErrorCode|RuntimeNotSupported} when runtime is browser.
|
1267
1263
|
*/
|
1268
1264
|
AddAuthenticationInfo(config) {
|
1269
|
-
return
|
1270
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "CertificateAuthProvider"), ErrorCode.RuntimeNotSupported);
|
1271
|
-
});
|
1265
|
+
return Promise.reject(new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "CertificateAuthProvider"), ErrorCode.RuntimeNotSupported));
|
1272
1266
|
}
|
1273
1267
|
}
|
1274
1268
|
/**
|
@@ -1515,9 +1509,7 @@ class ConversationBot$1 {
|
|
1515
1509
|
* Only work on server side.
|
1516
1510
|
*/
|
1517
1511
|
requestHandler(req, res, logic) {
|
1518
|
-
|
1519
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "ConversationBot"), ErrorCode.RuntimeNotSupported);
|
1520
|
-
});
|
1512
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "ConversationBot"), ErrorCode.RuntimeNotSupported);
|
1521
1513
|
}
|
1522
1514
|
}
|
1523
1515
|
|
@@ -1643,9 +1635,7 @@ class Channel$1 {
|
|
1643
1635
|
* @returns the response of sending adaptive card message.
|
1644
1636
|
*/
|
1645
1637
|
sendAdaptiveCard(card, onError) {
|
1646
|
-
|
1647
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "Channel"), ErrorCode.RuntimeNotSupported);
|
1648
|
-
});
|
1638
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "Channel"), ErrorCode.RuntimeNotSupported);
|
1649
1639
|
}
|
1650
1640
|
}
|
1651
1641
|
/**
|
@@ -1702,9 +1692,7 @@ class Member$1 {
|
|
1702
1692
|
* @returns the response of sending adaptive card message.
|
1703
1693
|
*/
|
1704
1694
|
sendAdaptiveCard(card, onError) {
|
1705
|
-
|
1706
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "Member"), ErrorCode.RuntimeNotSupported);
|
1707
|
-
});
|
1695
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "Member"), ErrorCode.RuntimeNotSupported);
|
1708
1696
|
}
|
1709
1697
|
}
|
1710
1698
|
/**
|
@@ -1771,9 +1759,7 @@ class TeamsBotInstallation$1 {
|
|
1771
1759
|
* @returns an array of channels if bot is installed into a team, otherwise returns an empty array.
|
1772
1760
|
*/
|
1773
1761
|
channels() {
|
1774
|
-
|
1775
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "TeamsBotInstallation"), ErrorCode.RuntimeNotSupported);
|
1776
|
-
});
|
1762
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "TeamsBotInstallation"), ErrorCode.RuntimeNotSupported);
|
1777
1763
|
}
|
1778
1764
|
/**
|
1779
1765
|
* Get members from this bot installation.
|
@@ -1784,9 +1770,7 @@ class TeamsBotInstallation$1 {
|
|
1784
1770
|
* @returns an array of members from where the bot is installed.
|
1785
1771
|
*/
|
1786
1772
|
members() {
|
1787
|
-
|
1788
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "TeamsBotInstallation"), ErrorCode.RuntimeNotSupported);
|
1789
|
-
});
|
1773
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "TeamsBotInstallation"), ErrorCode.RuntimeNotSupported);
|
1790
1774
|
}
|
1791
1775
|
/**
|
1792
1776
|
* Get team details from this bot installation
|
@@ -1794,9 +1778,7 @@ class TeamsBotInstallation$1 {
|
|
1794
1778
|
* @returns the team details if bot is installed into a team, otherwise returns undefined.
|
1795
1779
|
*/
|
1796
1780
|
getTeamDetails() {
|
1797
|
-
|
1798
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "TeamsBotInstallation"), ErrorCode.RuntimeNotSupported);
|
1799
|
-
});
|
1781
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "TeamsBotInstallation"), ErrorCode.RuntimeNotSupported);
|
1800
1782
|
}
|
1801
1783
|
}
|
1802
1784
|
/**
|
@@ -1853,9 +1835,7 @@ class NotificationBot$1 {
|
|
1853
1835
|
* @returns - an array of {@link TeamsBotInstallation}.
|
1854
1836
|
*/
|
1855
1837
|
static installations() {
|
1856
|
-
|
1857
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1858
|
-
});
|
1838
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1859
1839
|
}
|
1860
1840
|
/**
|
1861
1841
|
* Returns the first {@link Member} where predicate is true, and undefined otherwise.
|
@@ -1871,9 +1851,7 @@ class NotificationBot$1 {
|
|
1871
1851
|
* @returns the first {@link Member} where predicate is true, and undefined otherwise.
|
1872
1852
|
*/
|
1873
1853
|
findMember(predicate, scope) {
|
1874
|
-
|
1875
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1876
|
-
});
|
1854
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1877
1855
|
}
|
1878
1856
|
/**
|
1879
1857
|
* Returns the first {@link Channel} where predicate is true, and undefined otherwise.
|
@@ -1888,9 +1866,7 @@ class NotificationBot$1 {
|
|
1888
1866
|
* @returns the first {@link Channel} where predicate is true, and undefined otherwise.
|
1889
1867
|
*/
|
1890
1868
|
findChannel(predicate) {
|
1891
|
-
|
1892
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1893
|
-
});
|
1869
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1894
1870
|
}
|
1895
1871
|
/**
|
1896
1872
|
* Returns all {@link Member} where predicate is true, and empty array otherwise.
|
@@ -1904,9 +1880,7 @@ class NotificationBot$1 {
|
|
1904
1880
|
* @returns an array of {@link Member} where predicate is true, and empty array otherwise.
|
1905
1881
|
*/
|
1906
1882
|
findAllMembers(predicate, scope) {
|
1907
|
-
|
1908
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1909
|
-
});
|
1883
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1910
1884
|
}
|
1911
1885
|
/**
|
1912
1886
|
* Returns all {@link Channel} where predicate is true, and empty array otherwise.
|
@@ -1919,9 +1893,7 @@ class NotificationBot$1 {
|
|
1919
1893
|
* @returns an array of {@link Channel} where predicate is true, and empty array otherwise.
|
1920
1894
|
*/
|
1921
1895
|
findAllChannels(predicate) {
|
1922
|
-
|
1923
|
-
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1924
|
-
});
|
1896
|
+
throw new ErrorWithCode(formatString(ErrorMessage.BrowserRuntimeNotSupported, "NotificationBot"), ErrorCode.RuntimeNotSupported);
|
1925
1897
|
}
|
1926
1898
|
}
|
1927
1899
|
/**
|