@microsoft/teamsfx-core 2.0.0 → 2.0.1-alpha.6f92bb6f7.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.
Files changed (412) hide show
  1. package/build/common/armInterface.d.ts +0 -5
  2. package/build/common/armInterface.d.ts.map +1 -1
  3. package/build/common/deps-checker/checkerFactory.d.ts.map +1 -1
  4. package/build/common/deps-checker/checkerFactory.js +0 -7
  5. package/build/common/deps-checker/checkerFactory.js.map +1 -1
  6. package/build/common/deps-checker/constant/helpLink.d.ts +0 -4
  7. package/build/common/deps-checker/constant/helpLink.d.ts.map +1 -1
  8. package/build/common/deps-checker/constant/helpLink.js +1 -9
  9. package/build/common/deps-checker/constant/helpLink.js.map +1 -1
  10. package/build/common/deps-checker/constant/message.d.ts +0 -5
  11. package/build/common/deps-checker/constant/message.d.ts.map +1 -1
  12. package/build/common/deps-checker/constant/message.js +0 -6
  13. package/build/common/deps-checker/constant/message.js.map +1 -1
  14. package/build/common/deps-checker/constant/telemetry.d.ts +2 -33
  15. package/build/common/deps-checker/constant/telemetry.d.ts.map +1 -1
  16. package/build/common/deps-checker/constant/telemetry.js +0 -31
  17. package/build/common/deps-checker/constant/telemetry.js.map +1 -1
  18. package/build/common/deps-checker/depsChecker.d.ts +0 -3
  19. package/build/common/deps-checker/depsChecker.d.ts.map +1 -1
  20. package/build/common/deps-checker/depsChecker.js +0 -3
  21. package/build/common/deps-checker/depsChecker.js.map +1 -1
  22. package/build/common/deps-checker/depsError.d.ts +0 -9
  23. package/build/common/deps-checker/depsError.d.ts.map +1 -1
  24. package/build/common/deps-checker/depsError.js +1 -22
  25. package/build/common/deps-checker/depsError.js.map +1 -1
  26. package/build/common/deps-checker/depsManager.d.ts.map +1 -1
  27. package/build/common/deps-checker/depsManager.js +0 -3
  28. package/build/common/deps-checker/depsManager.js.map +1 -1
  29. package/build/common/deps-checker/internal/funcToolChecker.d.ts +2 -2
  30. package/build/common/deps-checker/internal/funcToolChecker.d.ts.map +1 -1
  31. package/build/common/deps-checker/internal/funcToolChecker.js +4 -2
  32. package/build/common/deps-checker/internal/funcToolChecker.js.map +1 -1
  33. package/build/common/deps-checker/internal/nodeChecker.d.ts +0 -20
  34. package/build/common/deps-checker/internal/nodeChecker.d.ts.map +1 -1
  35. package/build/common/deps-checker/internal/nodeChecker.js +1 -51
  36. package/build/common/deps-checker/internal/nodeChecker.js.map +1 -1
  37. package/build/common/local/localEnvManager.d.ts +0 -9
  38. package/build/common/local/localEnvManager.d.ts.map +1 -1
  39. package/build/common/local/localEnvManager.js +0 -59
  40. package/build/common/local/localEnvManager.js.map +1 -1
  41. package/build/common/projectSettingsHelper.d.ts +1 -7
  42. package/build/common/projectSettingsHelper.d.ts.map +1 -1
  43. package/build/common/projectSettingsHelper.js +5 -81
  44. package/build/common/projectSettingsHelper.js.map +1 -1
  45. package/build/common/projectSettingsHelperV3.d.ts +0 -1
  46. package/build/common/projectSettingsHelperV3.d.ts.map +1 -1
  47. package/build/common/projectSettingsHelperV3.js +1 -10
  48. package/build/common/projectSettingsHelperV3.js.map +1 -1
  49. package/build/common/samples.d.ts.map +1 -1
  50. package/build/common/samples.js +18 -40
  51. package/build/common/samples.js.map +1 -1
  52. package/build/common/templates-config.json +2 -2
  53. package/build/common/tools.d.ts +1 -2
  54. package/build/common/tools.d.ts.map +1 -1
  55. package/build/common/tools.js +5 -70
  56. package/build/common/tools.js.map +1 -1
  57. package/build/component/code/utils.d.ts +1 -8
  58. package/build/component/code/utils.d.ts.map +1 -1
  59. package/build/component/code/utils.js +5 -144
  60. package/build/component/code/utils.js.map +1 -1
  61. package/build/component/constants.d.ts +3 -0
  62. package/build/component/constants.d.ts.map +1 -1
  63. package/build/component/constants.js +13 -2
  64. package/build/component/constants.js.map +1 -1
  65. package/build/component/coordinator/index.d.ts +7 -7
  66. package/build/component/coordinator/index.d.ts.map +1 -1
  67. package/build/component/coordinator/index.js +15 -179
  68. package/build/component/coordinator/index.js.map +1 -1
  69. package/build/component/debug/error.d.ts +0 -1
  70. package/build/component/debug/error.d.ts.map +1 -1
  71. package/build/component/debug/error.js +1 -11
  72. package/build/component/debug/error.js.map +1 -1
  73. package/build/component/debug/index.d.ts.map +1 -1
  74. package/build/component/debug/index.js +1 -25
  75. package/build/component/debug/index.js.map +1 -1
  76. package/build/component/driver/aad/create.d.ts.map +1 -1
  77. package/build/component/driver/aad/create.js +2 -2
  78. package/build/component/driver/aad/create.js.map +1 -1
  79. package/build/component/driver/aad/update.d.ts.map +1 -1
  80. package/build/component/driver/aad/update.js +6 -20
  81. package/build/component/driver/aad/update.js.map +1 -1
  82. package/build/component/driver/botAadApp/create.d.ts.map +1 -1
  83. package/build/component/driver/botAadApp/create.js +2 -2
  84. package/build/component/driver/botAadApp/create.js.map +1 -1
  85. package/build/component/driver/devTool/error/dotnetInstallationUserError.d.ts +1 -1
  86. package/build/component/driver/devTool/error/dotnetInstallationUserError.d.ts.map +1 -1
  87. package/build/component/driver/devTool/error/dotnetInstallationUserError.js +4 -2
  88. package/build/component/driver/devTool/error/dotnetInstallationUserError.js.map +1 -1
  89. package/build/component/driver/devTool/error/funcInstallationUserError.d.ts +1 -1
  90. package/build/component/driver/devTool/error/funcInstallationUserError.d.ts.map +1 -1
  91. package/build/component/driver/devTool/error/funcInstallationUserError.js +4 -2
  92. package/build/component/driver/devTool/error/funcInstallationUserError.js.map +1 -1
  93. package/build/component/driver/devTool/installDriver.d.ts +1 -0
  94. package/build/component/driver/devTool/installDriver.d.ts.map +1 -1
  95. package/build/component/driver/devTool/installDriver.js +17 -24
  96. package/build/component/driver/devTool/installDriver.js.map +1 -1
  97. package/build/component/driver/script/baseBuildDriver.d.ts.map +1 -1
  98. package/build/component/driver/script/baseBuildDriver.js +2 -2
  99. package/build/component/driver/script/baseBuildDriver.js.map +1 -1
  100. package/build/component/driver/script/scriptDriver.d.ts +11 -1
  101. package/build/component/driver/script/scriptDriver.d.ts.map +1 -1
  102. package/build/component/driver/script/scriptDriver.js +121 -4
  103. package/build/component/driver/script/scriptDriver.js.map +1 -1
  104. package/build/component/driver/teamsApp/createAppPackage.d.ts +0 -1
  105. package/build/component/driver/teamsApp/createAppPackage.d.ts.map +1 -1
  106. package/build/component/driver/teamsApp/createAppPackage.js +1 -11
  107. package/build/component/driver/teamsApp/createAppPackage.js.map +1 -1
  108. package/build/component/driver/teamsApp/validate.d.ts +0 -1
  109. package/build/component/driver/teamsApp/validate.d.ts.map +1 -1
  110. package/build/component/driver/teamsApp/validate.js +34 -18
  111. package/build/component/driver/teamsApp/validate.js.map +1 -1
  112. package/build/component/feature/bot/question.d.ts.map +1 -1
  113. package/build/component/feature/bot/question.js +7 -16
  114. package/build/component/feature/bot/question.js.map +1 -1
  115. package/build/component/feature/sso.d.ts +0 -4
  116. package/build/component/feature/sso.d.ts.map +1 -1
  117. package/build/component/feature/sso.js +10 -144
  118. package/build/component/feature/sso.js.map +1 -1
  119. package/build/component/question.d.ts +3 -64
  120. package/build/component/question.d.ts.map +1 -1
  121. package/build/component/question.js +61 -663
  122. package/build/component/question.js.map +1 -1
  123. package/build/component/registerService.d.ts +0 -14
  124. package/build/component/registerService.d.ts.map +1 -1
  125. package/build/component/registerService.js +0 -14
  126. package/build/component/registerService.js.map +1 -1
  127. package/build/component/resource/aadApp/aadApp.d.ts.map +1 -1
  128. package/build/component/resource/aadApp/aadApp.js +6 -24
  129. package/build/component/resource/aadApp/aadApp.js.map +1 -1
  130. package/build/component/resource/appManifest/appStudio.js +1 -1
  131. package/build/component/resource/appManifest/appStudio.js.map +1 -1
  132. package/build/component/resource/appManifest/utils/ManifestUtils.d.ts +1 -1
  133. package/build/component/resource/appManifest/utils/ManifestUtils.d.ts.map +1 -1
  134. package/build/component/resource/appManifest/utils/ManifestUtils.js +1 -9
  135. package/build/component/resource/appManifest/utils/ManifestUtils.js.map +1 -1
  136. package/build/component/resource/spfx/utils/questions.d.ts.map +1 -1
  137. package/build/component/resource/spfx/utils/questions.js +1 -4
  138. package/build/component/resource/spfx/utils/questions.js.map +1 -1
  139. package/build/component/utils/backupFiles.d.ts +2 -1
  140. package/build/component/utils/backupFiles.d.ts.map +1 -1
  141. package/build/component/utils/backupFiles.js +23 -3
  142. package/build/component/utils/backupFiles.js.map +1 -1
  143. package/build/component/utils/charsetUtils.d.ts +3 -0
  144. package/build/component/utils/charsetUtils.d.ts.map +1 -0
  145. package/build/component/utils/charsetUtils.js +241 -0
  146. package/build/component/utils/charsetUtils.js.map +1 -0
  147. package/build/component/utils/envUtil.d.ts.map +1 -1
  148. package/build/component/utils/envUtil.js +4 -1
  149. package/build/component/utils/envUtil.js.map +1 -1
  150. package/build/component/utils/metadataUtil.d.ts.map +1 -1
  151. package/build/component/utils/metadataUtil.js +9 -7
  152. package/build/component/utils/metadataUtil.js.map +1 -1
  153. package/build/component/utils/pathUtils.d.ts.map +1 -1
  154. package/build/component/utils/pathUtils.js +8 -7
  155. package/build/component/utils/pathUtils.js.map +1 -1
  156. package/build/component/utils/settingsUtil.js +3 -3
  157. package/build/component/utils/settingsUtil.js.map +1 -1
  158. package/build/component/utils.d.ts +1 -12
  159. package/build/component/utils.d.ts.map +1 -1
  160. package/build/component/utils.js +2 -225
  161. package/build/component/utils.js.map +1 -1
  162. package/build/component/workflow.d.ts +0 -1
  163. package/build/component/workflow.d.ts.map +1 -1
  164. package/build/component/workflow.js +1 -687
  165. package/build/component/workflow.js.map +1 -1
  166. package/build/core/FxCore.d.ts +26 -34
  167. package/build/core/FxCore.d.ts.map +1 -1
  168. package/build/core/FxCore.js +86 -654
  169. package/build/core/FxCore.js.map +1 -1
  170. package/build/core/FxCoreImplementV3.d.ts +15 -9
  171. package/build/core/FxCoreImplementV3.d.ts.map +1 -1
  172. package/build/core/FxCoreImplementV3.js +105 -105
  173. package/build/core/FxCoreImplementV3.js.map +1 -1
  174. package/build/core/middleware/envInfoLoaderV3.d.ts +1 -10
  175. package/build/core/middleware/envInfoLoaderV3.d.ts.map +1 -1
  176. package/build/core/middleware/envInfoLoaderV3.js +1 -207
  177. package/build/core/middleware/envInfoLoaderV3.js.map +1 -1
  178. package/build/core/middleware/projectMigratorV3.d.ts +1 -0
  179. package/build/core/middleware/projectMigratorV3.d.ts.map +1 -1
  180. package/build/core/middleware/projectMigratorV3.js +7 -7
  181. package/build/core/middleware/projectMigratorV3.js.map +1 -1
  182. package/build/core/middleware/projectSettingsLoader.d.ts +1 -4
  183. package/build/core/middleware/projectSettingsLoader.d.ts.map +1 -1
  184. package/build/core/middleware/projectSettingsLoader.js +4 -58
  185. package/build/core/middleware/projectSettingsLoader.js.map +1 -1
  186. package/build/core/middleware/projectVersionChecker.d.ts.map +1 -1
  187. package/build/core/middleware/projectVersionChecker.js +4 -5
  188. package/build/core/middleware/projectVersionChecker.js.map +1 -1
  189. package/build/core/middleware/questionModel.d.ts +0 -1
  190. package/build/core/middleware/questionModel.d.ts.map +1 -1
  191. package/build/core/middleware/questionModel.js +8 -54
  192. package/build/core/middleware/questionModel.js.map +1 -1
  193. package/build/core/middleware/utils/MigrationUtils.d.ts +0 -5
  194. package/build/core/middleware/utils/MigrationUtils.d.ts.map +1 -1
  195. package/build/core/middleware/utils/MigrationUtils.js +1 -77
  196. package/build/core/middleware/utils/MigrationUtils.js.map +1 -1
  197. package/build/core/question.d.ts +2 -12
  198. package/build/core/question.d.ts.map +1 -1
  199. package/build/core/question.js +14 -236
  200. package/build/core/question.js.map +1 -1
  201. package/build/core/types.d.ts +3 -3
  202. package/build/core/types.d.ts.map +1 -1
  203. package/build/error/common.d.ts +9 -0
  204. package/build/error/common.d.ts.map +1 -1
  205. package/build/error/common.js +39 -1
  206. package/build/error/common.js.map +1 -1
  207. package/build/error/script.d.ts +1 -1
  208. package/build/error/script.d.ts.map +1 -1
  209. package/build/error/script.js +3 -3
  210. package/build/error/script.js.map +1 -1
  211. package/build/index.d.ts +0 -2
  212. package/build/index.d.ts.map +1 -1
  213. package/build/index.js +1 -4
  214. package/build/index.js.map +1 -1
  215. package/package.json +12 -28
  216. package/resource/package.nls.json +10 -97
  217. package/templates/fallback/common.zip +0 -0
  218. package/templates/fallback/csharp.zip +0 -0
  219. package/templates/fallback/js.zip +0 -0
  220. package/templates/fallback/ts.zip +0 -0
  221. package/build/common/deps-checker/internal/ngrokChecker.d.ts +0 -27
  222. package/build/common/deps-checker/internal/ngrokChecker.d.ts.map +0 -1
  223. package/build/common/deps-checker/internal/ngrokChecker.js +0 -222
  224. package/build/common/deps-checker/internal/ngrokChecker.js.map +0 -1
  225. package/build/component/connection/apimConfig.d.ts +0 -11
  226. package/build/component/connection/apimConfig.d.ts.map +0 -1
  227. package/build/component/connection/apimConfig.js +0 -44
  228. package/build/component/connection/apimConfig.js.map +0 -1
  229. package/build/component/connection/azureFunctionConfig.d.ts +0 -9
  230. package/build/component/connection/azureFunctionConfig.d.ts.map +0 -1
  231. package/build/component/connection/azureFunctionConfig.js +0 -25
  232. package/build/component/connection/azureFunctionConfig.js.map +0 -1
  233. package/build/component/connection/azureResourceConfig.d.ts +0 -11
  234. package/build/component/connection/azureResourceConfig.d.ts.map +0 -1
  235. package/build/component/connection/azureResourceConfig.js +0 -72
  236. package/build/component/connection/azureResourceConfig.js.map +0 -1
  237. package/build/component/connection/azureWebAppConfig.d.ts +0 -9
  238. package/build/component/connection/azureWebAppConfig.d.ts.map +0 -1
  239. package/build/component/connection/azureWebAppConfig.js +0 -25
  240. package/build/component/connection/azureWebAppConfig.js.map +0 -1
  241. package/build/component/coordinator/lifecycleStage.d.ts +0 -2
  242. package/build/component/coordinator/lifecycleStage.d.ts.map +0 -1
  243. package/build/component/coordinator/lifecycleStage.js +0 -23
  244. package/build/component/coordinator/lifecycleStage.js.map +0 -1
  245. package/build/component/core.d.ts +0 -65
  246. package/build/component/core.d.ts.map +0 -1
  247. package/build/component/core.js +0 -653
  248. package/build/component/core.js.map +0 -1
  249. package/build/component/debug/util/ngrok.d.ts +0 -6
  250. package/build/component/debug/util/ngrok.d.ts.map +0 -1
  251. package/build/component/debug/util/ngrok.js +0 -65
  252. package/build/component/debug/util/ngrok.js.map +0 -1
  253. package/build/component/feature/api/api.d.ts +0 -8
  254. package/build/component/feature/api/api.d.ts.map +0 -1
  255. package/build/component/feature/api/api.js +0 -188
  256. package/build/component/feature/api/api.js.map +0 -1
  257. package/build/component/feature/apiconnector/apiConnector.d.ts +0 -11
  258. package/build/component/feature/apiconnector/apiConnector.d.ts.map +0 -1
  259. package/build/component/feature/apiconnector/apiConnector.js +0 -43
  260. package/build/component/feature/apiconnector/apiConnector.js.map +0 -1
  261. package/build/component/feature/apim.d.ts +0 -8
  262. package/build/component/feature/apim.d.ts.map +0 -1
  263. package/build/component/feature/apim.js +0 -123
  264. package/build/component/feature/apim.js.map +0 -1
  265. package/build/component/feature/bot/bot.d.ts +0 -12
  266. package/build/component/feature/bot/bot.d.ts.map +0 -1
  267. package/build/component/feature/bot/bot.js +0 -309
  268. package/build/component/feature/bot/bot.js.map +0 -1
  269. package/build/component/feature/keyVault.d.ts +0 -16
  270. package/build/component/feature/keyVault.d.ts.map +0 -1
  271. package/build/component/feature/keyVault.js +0 -90
  272. package/build/component/feature/keyVault.js.map +0 -1
  273. package/build/component/feature/spfx.d.ts +0 -9
  274. package/build/component/feature/spfx.d.ts.map +0 -1
  275. package/build/component/feature/spfx.js +0 -121
  276. package/build/component/feature/spfx.js.map +0 -1
  277. package/build/component/feature/sql.d.ts +0 -10
  278. package/build/component/feature/sql.d.ts.map +0 -1
  279. package/build/component/feature/sql.js +0 -80
  280. package/build/component/feature/sql.js.map +0 -1
  281. package/build/component/feature/tab.d.ts +0 -10
  282. package/build/component/feature/tab.d.ts.map +0 -1
  283. package/build/component/feature/tab.js +0 -238
  284. package/build/component/feature/tab.js.map +0 -1
  285. package/build/component/resource/azureSql/actions/configure.d.ts +0 -15
  286. package/build/component/resource/azureSql/actions/configure.d.ts.map +0 -1
  287. package/build/component/resource/azureSql/actions/configure.js +0 -92
  288. package/build/component/resource/azureSql/actions/configure.js.map +0 -1
  289. package/build/component/resource/azureSql/actions/provision.d.ts +0 -10
  290. package/build/component/resource/azureSql/actions/provision.d.ts.map +0 -1
  291. package/build/component/resource/azureSql/actions/provision.js +0 -63
  292. package/build/component/resource/azureSql/actions/provision.js.map +0 -1
  293. package/build/component/resource/azureSql/actions/utils.d.ts +0 -12
  294. package/build/component/resource/azureSql/actions/utils.d.ts.map +0 -1
  295. package/build/component/resource/azureSql/actions/utils.js +0 -82
  296. package/build/component/resource/azureSql/actions/utils.js.map +0 -1
  297. package/build/component/resource/azureSql/azureSql.d.ts +0 -24
  298. package/build/component/resource/azureSql/azureSql.d.ts.map +0 -1
  299. package/build/component/resource/azureSql/azureSql.js +0 -75
  300. package/build/component/resource/azureSql/azureSql.js.map +0 -1
  301. package/build/component/resource/azureSql/clients/management.d.ts +0 -18
  302. package/build/component/resource/azureSql/clients/management.d.ts.map +0 -1
  303. package/build/component/resource/azureSql/clients/management.js +0 -124
  304. package/build/component/resource/azureSql/clients/management.js.map +0 -1
  305. package/build/component/resource/azureSql/clients/sql.d.ts +0 -13
  306. package/build/component/resource/azureSql/clients/sql.d.ts.map +0 -1
  307. package/build/component/resource/azureSql/clients/sql.js +0 -153
  308. package/build/component/resource/azureSql/clients/sql.js.map +0 -1
  309. package/build/component/resource/azureSql/config.d.ts +0 -7
  310. package/build/component/resource/azureSql/config.d.ts.map +0 -1
  311. package/build/component/resource/azureSql/config.js +0 -77
  312. package/build/component/resource/azureSql/config.js.map +0 -1
  313. package/build/component/resource/azureSql/constants.d.ts +0 -85
  314. package/build/component/resource/azureSql/constants.d.ts.map +0 -1
  315. package/build/component/resource/azureSql/constants.js +0 -95
  316. package/build/component/resource/azureSql/constants.js.map +0 -1
  317. package/build/component/resource/azureSql/errors.d.ts +0 -63
  318. package/build/component/resource/azureSql/errors.d.ts.map +0 -1
  319. package/build/component/resource/azureSql/errors.js +0 -107
  320. package/build/component/resource/azureSql/errors.js.map +0 -1
  321. package/build/component/resource/azureSql/index.d.ts +0 -2
  322. package/build/component/resource/azureSql/index.d.ts.map +0 -1
  323. package/build/component/resource/azureSql/index.js +0 -7
  324. package/build/component/resource/azureSql/index.js.map +0 -1
  325. package/build/component/resource/azureSql/questions.d.ts +0 -6
  326. package/build/component/resource/azureSql/questions.d.ts.map +0 -1
  327. package/build/component/resource/azureSql/questions.js +0 -59
  328. package/build/component/resource/azureSql/questions.js.map +0 -1
  329. package/build/component/resource/azureSql/results.d.ts +0 -10
  330. package/build/component/resource/azureSql/results.d.ts.map +0 -1
  331. package/build/component/resource/azureSql/results.js +0 -34
  332. package/build/component/resource/azureSql/results.js.map +0 -1
  333. package/build/component/resource/azureSql/types.d.ts +0 -12
  334. package/build/component/resource/azureSql/types.d.ts.map +0 -1
  335. package/build/component/resource/azureSql/types.js +0 -5
  336. package/build/component/resource/azureSql/types.js.map +0 -1
  337. package/build/component/resource/azureSql/utils/checkInput.d.ts +0 -10
  338. package/build/component/resource/azureSql/utils/checkInput.d.ts.map +0 -1
  339. package/build/component/resource/azureSql/utils/checkInput.js +0 -89
  340. package/build/component/resource/azureSql/utils/checkInput.js.map +0 -1
  341. package/build/component/resource/azureSql/utils/common.d.ts +0 -12
  342. package/build/component/resource/azureSql/utils/common.d.ts.map +0 -1
  343. package/build/component/resource/azureSql/utils/common.js +0 -51
  344. package/build/component/resource/azureSql/utils/common.js.map +0 -1
  345. package/build/component/resource/identity.d.ts +0 -28
  346. package/build/component/resource/identity.d.ts.map +0 -1
  347. package/build/component/resource/identity.js +0 -42
  348. package/build/component/resource/identity.js.map +0 -1
  349. package/build/component/resource/keyVault.d.ts +0 -29
  350. package/build/component/resource/keyVault.d.ts.map +0 -1
  351. package/build/component/resource/keyVault.js +0 -47
  352. package/build/component/resource/keyVault.js.map +0 -1
  353. package/build/component/resource/simpleAuth/constants.d.ts +0 -122
  354. package/build/component/resource/simpleAuth/constants.d.ts.map +0 -1
  355. package/build/component/resource/simpleAuth/constants.js +0 -163
  356. package/build/component/resource/simpleAuth/constants.js.map +0 -1
  357. package/build/component/resource/simpleAuth/errors.d.ts +0 -17
  358. package/build/component/resource/simpleAuth/errors.d.ts.map +0 -1
  359. package/build/component/resource/simpleAuth/errors.js +0 -91
  360. package/build/component/resource/simpleAuth/errors.js.map +0 -1
  361. package/build/component/resource/simpleAuth/index.d.ts +0 -12
  362. package/build/component/resource/simpleAuth/index.d.ts.map +0 -1
  363. package/build/component/resource/simpleAuth/index.js +0 -115
  364. package/build/component/resource/simpleAuth/index.js.map +0 -1
  365. package/build/component/resource/simpleAuth/result.d.ts +0 -9
  366. package/build/component/resource/simpleAuth/result.d.ts.map +0 -1
  367. package/build/component/resource/simpleAuth/result.js +0 -35
  368. package/build/component/resource/simpleAuth/result.js.map +0 -1
  369. package/build/component/resource/simpleAuth/utils/common.d.ts +0 -23
  370. package/build/component/resource/simpleAuth/utils/common.d.ts.map +0 -1
  371. package/build/component/resource/simpleAuth/utils/common.js +0 -150
  372. package/build/component/resource/simpleAuth/utils/common.js.map +0 -1
  373. package/build/component/resource/simpleAuth/utils/dialog.d.ts +0 -5
  374. package/build/component/resource/simpleAuth/utils/dialog.d.ts.map +0 -1
  375. package/build/component/resource/simpleAuth/utils/dialog.js +0 -7
  376. package/build/component/resource/simpleAuth/utils/dialog.js.map +0 -1
  377. package/build/component/resource/simpleAuth/utils/telemetry.d.ts +0 -17
  378. package/build/component/resource/simpleAuth/utils/telemetry.d.ts.map +0 -1
  379. package/build/component/resource/simpleAuth/utils/telemetry.js +0 -45
  380. package/build/component/resource/simpleAuth/utils/telemetry.js.map +0 -1
  381. package/build/core/dependencyChecker.d.ts +0 -1
  382. package/build/core/dependencyChecker.d.ts.map +0 -1
  383. package/build/core/dependencyChecker.js +0 -2
  384. package/build/core/dependencyChecker.js.map +0 -1
  385. package/build/core/middleware/CommonErrorHandlerMW.d.ts +0 -14
  386. package/build/core/middleware/CommonErrorHandlerMW.d.ts.map +0 -1
  387. package/build/core/middleware/CommonErrorHandlerMW.js +0 -63
  388. package/build/core/middleware/CommonErrorHandlerMW.js.map +0 -1
  389. package/build/core/middleware/aadManifestMigration.d.ts +0 -3
  390. package/build/core/middleware/aadManifestMigration.d.ts.map +0 -1
  391. package/build/core/middleware/aadManifestMigration.js +0 -119
  392. package/build/core/middleware/aadManifestMigration.js.map +0 -1
  393. package/build/core/middleware/consolidateLocalRemote.d.ts +0 -5
  394. package/build/core/middleware/consolidateLocalRemote.d.ts.map +0 -1
  395. package/build/core/middleware/consolidateLocalRemote.js +0 -378
  396. package/build/core/middleware/consolidateLocalRemote.js.map +0 -1
  397. package/build/core/middleware/envInfoWriter.d.ts +0 -8
  398. package/build/core/middleware/envInfoWriter.d.ts.map +0 -1
  399. package/build/core/middleware/envInfoWriter.js +0 -76
  400. package/build/core/middleware/envInfoWriter.js.map +0 -1
  401. package/build/core/middleware/envInfoWriterV3.d.ts +0 -6
  402. package/build/core/middleware/envInfoWriterV3.d.ts.map +0 -1
  403. package/build/core/middleware/envInfoWriterV3.js +0 -67
  404. package/build/core/middleware/envInfoWriterV3.js.map +0 -1
  405. package/build/core/middleware/projectMigrator.d.ts +0 -40
  406. package/build/core/middleware/projectMigrator.d.ts.map +0 -1
  407. package/build/core/middleware/projectMigrator.js +0 -1014
  408. package/build/core/middleware/projectMigrator.js.map +0 -1
  409. package/build/core/middleware/projectSettingsWriter.d.ts +0 -6
  410. package/build/core/middleware/projectSettingsWriter.d.ts.map +0 -1
  411. package/build/core/middleware/projectSettingsWriter.js +0 -52
  412. package/build/core/middleware/projectSettingsWriter.js.map +0 -1
@@ -1 +0,0 @@
1
- {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../../src/component/resource/simpleAuth/errors.ts"],"names":[],"mappings":"AAKA,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,CAAC,GAAG,IAAI,EAAE,MAAM,EAAE,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAClD;AAED,eAAO,MAAM,aAAa,EAAE,WAM3B,CAAC;AAEF,eAAO,MAAM,oBAAoB,EAAE,WAMlC,CAAC;AAEF,eAAO,MAAM,yBAAyB,EAAE,WAMvC,CAAC;AAEF,eAAO,MAAM,yBAAyB,EAAE,WAMvC,CAAC;AAEF,eAAO,MAAM,oCAAoC,EAAE,WAMlD,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,WAM/B,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,WAM5B,CAAC;AAEF,eAAO,MAAM,8BAA8B,EAAE,WAM5C,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,WAM5B,CAAC;AAEF,eAAO,MAAM,oBAAoB,EAAE,WAMlC,CAAC;AAEF,eAAO,MAAM,gBAAgB,EAAE,WAM9B,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,WAMjC,CAAC"}
@@ -1,91 +0,0 @@
1
- "use strict";
2
- // Copyright (c) Microsoft Corporation.
3
- // Licensed under the MIT license.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.VersionFileNotExist = exports.ZipDownloadError = exports.EndpointInvalidError = exports.UnhandledError = exports.UpdateApplicationSettingsError = exports.ZipDeployError = exports.CreateWebAppError = exports.MissingSubscriptionRegistrationError = exports.FreeServerFarmsQuotaError = exports.CreateAppServicePlanError = exports.UnauthenticatedError = exports.NoConfigError = void 0;
6
- const localizeUtils_1 = require("../../../common/localizeUtils");
7
- exports.NoConfigError = {
8
- name: "NoConfigError",
9
- message: (pluginId, configKey) => [
10
- localizeUtils_1.getDefaultString("error.sa.NoConfigError", configKey, pluginId),
11
- localizeUtils_1.getLocalizedString("error.sa.NoConfigError", configKey, pluginId),
12
- ],
13
- };
14
- exports.UnauthenticatedError = {
15
- name: "UnauthenticatedError",
16
- message: () => [
17
- localizeUtils_1.getDefaultString("error.sa.UnauthenticatedError"),
18
- localizeUtils_1.getLocalizedString("error.sa.UnauthenticatedError"),
19
- ],
20
- };
21
- exports.CreateAppServicePlanError = {
22
- name: "CreateAppServicePlanError",
23
- message: (message) => [
24
- localizeUtils_1.getDefaultString("error.sa.CreateAppServicePlanError", message),
25
- localizeUtils_1.getLocalizedString("error.sa.CreateAppServicePlanError", message),
26
- ],
27
- };
28
- exports.FreeServerFarmsQuotaError = {
29
- name: "FreeServerFarmsQuotaError",
30
- message: (message) => [
31
- localizeUtils_1.getDefaultString("error.sa.FreeServerFarmsQuotaError", message),
32
- localizeUtils_1.getLocalizedString("error.sa.FreeServerFarmsQuotaError", message),
33
- ],
34
- };
35
- exports.MissingSubscriptionRegistrationError = {
36
- name: "MissingSubscriptionRegistrationError",
37
- message: (message) => [
38
- localizeUtils_1.getDefaultString("error.sa.MissingSubscriptionRegistrationError", message),
39
- localizeUtils_1.getLocalizedString("error.sa.MissingSubscriptionRegistrationError", message),
40
- ],
41
- };
42
- exports.CreateWebAppError = {
43
- name: "CreateWebAppError",
44
- message: (message) => [
45
- localizeUtils_1.getDefaultString("error.sa.CreateWebAppError", message),
46
- localizeUtils_1.getLocalizedString("error.sa.CreateWebAppError", message),
47
- ],
48
- };
49
- exports.ZipDeployError = {
50
- name: "ZipDeployError",
51
- message: (message) => [
52
- localizeUtils_1.getDefaultString("error.sa.ZipDeployError", message),
53
- localizeUtils_1.getLocalizedString("error.sa.ZipDeployError", message),
54
- ],
55
- };
56
- exports.UpdateApplicationSettingsError = {
57
- name: "UpdateApplicationSettingsError",
58
- message: (message) => [
59
- localizeUtils_1.getDefaultString("error.sa.UpdateApplicationSettingsError", message),
60
- localizeUtils_1.getLocalizedString("error.sa.UpdateApplicationSettingsError", message),
61
- ],
62
- };
63
- exports.UnhandledError = {
64
- name: "UnhandledError",
65
- message: (message) => [
66
- localizeUtils_1.getDefaultString("error.common.UnhandledError", message),
67
- localizeUtils_1.getLocalizedString("error.common.UnhandledError", message),
68
- ],
69
- };
70
- exports.EndpointInvalidError = {
71
- name: "EndpointInvalidError",
72
- message: (endpoint, message) => [
73
- localizeUtils_1.getDefaultString("error.sa.EndpointInvalidError", endpoint, message),
74
- localizeUtils_1.getLocalizedString("error.sa.EndpointInvalidError", endpoint, message),
75
- ],
76
- };
77
- exports.ZipDownloadError = {
78
- name: "ZipDownloadError",
79
- message: (message) => [
80
- localizeUtils_1.getDefaultString("error.sa.ZipDownloadError", message),
81
- localizeUtils_1.getLocalizedString("error.sa.ZipDownloadError", message),
82
- ],
83
- };
84
- exports.VersionFileNotExist = {
85
- name: "VersionFileNotExist",
86
- message: (filePath) => [
87
- localizeUtils_1.getDefaultString("error.sa.VersionFileNotExist", filePath !== null && filePath !== void 0 ? filePath : "File not exist."),
88
- localizeUtils_1.getLocalizedString("error.sa.VersionFileNotExist", filePath !== null && filePath !== void 0 ? filePath : "File not exist."),
89
- ],
90
- };
91
- //# sourceMappingURL=errors.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"errors.js","sourceRoot":"","sources":["../../../../src/component/resource/simpleAuth/errors.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAElC,iEAAqF;AAOxE,QAAA,aAAa,GAAgB;IACxC,IAAI,EAAE,eAAe;IACrB,OAAO,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,EAAE,CAAC;QAChC,gCAAgB,CAAC,wBAAwB,EAAE,SAAS,EAAE,QAAQ,CAAC;QAC/D,kCAAkB,CAAC,wBAAwB,EAAE,SAAS,EAAE,QAAQ,CAAC;KAClE;CACF,CAAC;AAEW,QAAA,oBAAoB,GAAgB;IAC/C,IAAI,EAAE,sBAAsB;IAC5B,OAAO,EAAE,GAAG,EAAE,CAAC;QACb,gCAAgB,CAAC,+BAA+B,CAAC;QACjD,kCAAkB,CAAC,+BAA+B,CAAC;KACpD;CACF,CAAC;AAEW,QAAA,yBAAyB,GAAgB;IACpD,IAAI,EAAE,2BAA2B;IACjC,OAAO,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC;QACpB,gCAAgB,CAAC,oCAAoC,EAAE,OAAO,CAAC;QAC/D,kCAAkB,CAAC,oCAAoC,EAAE,OAAO,CAAC;KAClE;CACF,CAAC;AAEW,QAAA,yBAAyB,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OAAO,CAAC;KAC3D;CACF,CAAC;AAEW,QAAA,oBAAoB,GAAgB;IAC/C,IAAI,EAAE,sBAAsB;IAC5B,OAAO,EAAE,CAAC,QAAQ,EAAE,OAAO,EAAE,EAAE,CAAC;QAC9B,gCAAgB,CAAC,+BAA+B,EAAE,QAAQ,EAAE,OAAO,CAAC;QACpE,kCAAkB,CAAC,+BAA+B,EAAE,QAAQ,EAAE,OAAO,CAAC;KACvE;CACF,CAAC;AAEW,QAAA,gBAAgB,GAAgB;IAC3C,IAAI,EAAE,kBAAkB;IACxB,OAAO,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC;QACpB,gCAAgB,CAAC,2BAA2B,EAAE,OAAO,CAAC;QACtD,kCAAkB,CAAC,2BAA2B,EAAE,OAAO,CAAC;KACzD;CACF,CAAC;AAEW,QAAA,mBAAmB,GAAgB;IAC9C,IAAI,EAAE,qBAAqB;IAC3B,OAAO,EAAE,CAAC,QAAS,EAAE,EAAE,CAAC;QACtB,gCAAgB,CAAC,8BAA8B,EAAE,QAAQ,aAAR,QAAQ,cAAR,QAAQ,GAAI,iBAAiB,CAAC;QAC/E,kCAAkB,CAAC,8BAA8B,EAAE,QAAQ,aAAR,QAAQ,cAAR,QAAQ,GAAI,iBAAiB,CAAC;KAClF;CACF,CAAC"}
@@ -1,12 +0,0 @@
1
- import { FxError, InputsWithProjectPath, ResourceContextV3, Result } from "@microsoft/teamsfx-api";
2
- import { EnvInfoV3 } from "@microsoft/teamsfx-api/build/v3";
3
- import "reflect-metadata";
4
- export declare class SimpleAuth {
5
- provision(context: ResourceContextV3, inputs: InputsWithProjectPath): Promise<Result<undefined, FxError>>;
6
- configure(context: ResourceContextV3, inputs: InputsWithProjectPath): Promise<Result<undefined, FxError>>;
7
- checkDefined(key: string, value: any, component?: string): void;
8
- getWebAppConfig(envInfo: EnvInfoV3): {
9
- [propertyName: string]: string;
10
- };
11
- }
12
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/component/resource/simpleAuth/index.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,OAAO,EACP,qBAAqB,EAErB,iBAAiB,EACjB,MAAM,EACP,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,SAAS,EAAE,MAAM,iCAAiC,CAAC;AAC5D,OAAO,kBAAkB,CAAC;AAY1B,qBACa,UAAU;IASf,SAAS,CACb,OAAO,EAAE,iBAAiB,EAC1B,MAAM,EAAE,qBAAqB,GAC5B,OAAO,CAAC,MAAM,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;IAsBhC,SAAS,CACb,OAAO,EAAE,iBAAiB,EAC1B,MAAM,EAAE,qBAAqB,GAC5B,OAAO,CAAC,MAAM,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;IAkBtC,YAAY,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,EAAE,SAAS,SAAgB;IAM/D,eAAe,CAAC,OAAO,EAAE,SAAS,GAAG;QAAE,CAAC,YAAY,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE;CAiCxE"}
@@ -1,115 +0,0 @@
1
- "use strict";
2
- // Copyright (c) Microsoft Corporation.
3
- // Licensed under the MIT license.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.SimpleAuth = void 0;
6
- const tslib_1 = require("tslib");
7
- const lib_1 = require("@feathersjs/hooks/lib");
8
- const teamsfx_api_1 = require("@microsoft/teamsfx-api");
9
- require("reflect-metadata");
10
- const typedi_1 = require("typedi");
11
- const localSettingsConstants_1 = require("../../../common/localSettingsConstants");
12
- const localStateConstants_1 = require("../../../common/localStateConstants");
13
- const tools_1 = require("../../../common/tools");
14
- const constants_1 = require("./constants");
15
- const errors_1 = require("./errors");
16
- const result_1 = require("./result");
17
- const common_1 = require("./utils/common");
18
- const constants_2 = require("../../constants");
19
- const actionExecutionMW_1 = require("../../middleware/actionExecutionMW");
20
- let SimpleAuth = class SimpleAuth {
21
- async provision(context, inputs) {
22
- if (context.envInfo.envName === "local") {
23
- context.logProvider.info(constants_1.Messages.StartLocalDebug.log);
24
- context.envInfo.state[constants_2.ComponentNames.SimpleAuth] =
25
- context.envInfo.state[constants_2.ComponentNames.SimpleAuth] || {};
26
- const simpleAuthFilePath = common_1.Utils.getSimpleAuthFilePath();
27
- context.envInfo.state[constants_2.ComponentNames.SimpleAuth][localSettingsConstants_1.LocalSettingsSimpleAuthKeys.SimpleAuthFilePath] = simpleAuthFilePath;
28
- await common_1.Utils.downloadZip(simpleAuthFilePath);
29
- context.logProvider.info(constants_1.Messages.EndLocalDebug.log);
30
- }
31
- return teamsfx_api_1.ok(undefined);
32
- }
33
- async configure(context, inputs) {
34
- context.logProvider.info(constants_1.Messages.StartPostLocalDebug.log);
35
- context.envInfo.state[constants_2.ComponentNames.SimpleAuth] =
36
- context.envInfo.state[constants_2.ComponentNames.SimpleAuth] || {};
37
- const configs = this.getWebAppConfig(context.envInfo); //
38
- if (context.envInfo.envName === "local") {
39
- const configArray = [];
40
- for (const [key, value] of Object.entries(configs)) {
41
- configArray.push(`${key}="${value}"`);
42
- }
43
- context.envInfo.state[constants_2.ComponentNames.SimpleAuth][localStateConstants_1.LocalStateSimpleAuthKeys.EnvironmentVariableParams] = configArray.join(" ");
44
- context.logProvider.info(constants_1.Messages.EndPostLocalDebug.log);
45
- }
46
- return teamsfx_api_1.ok(undefined);
47
- }
48
- checkDefined(key, value, component = "simple-auth") {
49
- if (!value) {
50
- throw result_1.ResultFactory.SystemError(errors_1.NoConfigError.name, errors_1.NoConfigError.message(component, key));
51
- }
52
- }
53
- getWebAppConfig(envInfo) {
54
- const clientId = envInfo.state[constants_2.ComponentNames.AadApp].clientId;
55
- const clientSecret = envInfo.state[constants_2.ComponentNames.AadApp].clientSecret;
56
- const oauthAuthority = envInfo.state[constants_2.ComponentNames.AadApp].oauthAuthority;
57
- const applicationIdUris = envInfo.state[constants_2.ComponentNames.AadApp].applicationIdUris;
58
- const endpoint = envInfo.state[constants_2.ComponentNames.TeamsTab].endpoint;
59
- this.checkDefined("clientId", clientId);
60
- this.checkDefined("clientSecret", clientSecret);
61
- this.checkDefined("oauthAuthority", oauthAuthority);
62
- this.checkDefined("applicationIdUris", applicationIdUris);
63
- this.checkDefined("endpoint", endpoint, "teams-tab");
64
- const allowedAppIds = tools_1.getAllowedAppIds().join(";");
65
- const aadMetadataAddress = `${oauthAuthority}/v2.0/.well-known/openid-configuration`;
66
- let endpointUrl;
67
- try {
68
- endpointUrl = new URL(endpoint);
69
- }
70
- catch (error) {
71
- throw result_1.ResultFactory.SystemError(errors_1.EndpointInvalidError.name, errors_1.EndpointInvalidError.message(endpoint, error.message));
72
- }
73
- const tabAppEndpoint = endpointUrl.origin;
74
- return {
75
- [constants_1.Constants.ApplicationSettingsKeys.clientId]: clientId,
76
- [constants_1.Constants.ApplicationSettingsKeys.clientSecret]: clientSecret,
77
- [constants_1.Constants.ApplicationSettingsKeys.oauthAuthority]: oauthAuthority,
78
- [constants_1.Constants.ApplicationSettingsKeys.applicationIdUris]: applicationIdUris,
79
- [constants_1.Constants.ApplicationSettingsKeys.allowedAppIds]: allowedAppIds,
80
- [constants_1.Constants.ApplicationSettingsKeys.tabAppEndpoint]: tabAppEndpoint,
81
- [constants_1.Constants.ApplicationSettingsKeys.aadMetadataAddress]: aadMetadataAddress,
82
- };
83
- }
84
- };
85
- tslib_1.__decorate([
86
- lib_1.hooks([
87
- actionExecutionMW_1.ActionExecutionMW({
88
- errorSource: "sa",
89
- enableTelemetry: true,
90
- telemetryComponentName: "fx-resource-simple-auth",
91
- telemetryEventName: "local-debug",
92
- }),
93
- ]),
94
- tslib_1.__metadata("design:type", Function),
95
- tslib_1.__metadata("design:paramtypes", [Object, Object]),
96
- tslib_1.__metadata("design:returntype", Promise)
97
- ], SimpleAuth.prototype, "provision", null);
98
- tslib_1.__decorate([
99
- lib_1.hooks([
100
- actionExecutionMW_1.ActionExecutionMW({
101
- errorSource: "sa",
102
- enableTelemetry: true,
103
- telemetryComponentName: "fx-resource-simple-auth",
104
- telemetryEventName: "configure",
105
- }),
106
- ]),
107
- tslib_1.__metadata("design:type", Function),
108
- tslib_1.__metadata("design:paramtypes", [Object, Object]),
109
- tslib_1.__metadata("design:returntype", Promise)
110
- ], SimpleAuth.prototype, "configure", null);
111
- SimpleAuth = tslib_1.__decorate([
112
- typedi_1.Service(constants_2.ComponentNames.SimpleAuth)
113
- ], SimpleAuth);
114
- exports.SimpleAuth = SimpleAuth;
115
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/component/resource/simpleAuth/index.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;;AAElC,+CAA8C;AAC9C,wDAMgC;AAEhC,4BAA0B;AAC1B,mCAAiC;AACjC,mFAAqF;AACrF,6EAA+E;AAC/E,iDAAyD;AACzD,2CAAkD;AAClD,qCAA+D;AAC/D,qCAAyC;AACzC,2CAAuC;AACvC,+CAAiD;AACjD,0EAAuE;AAGvE,IAAa,UAAU,GAAvB,MAAa,UAAU;IASrB,KAAK,CAAC,SAAS,CACb,OAA0B,EAC1B,MAA6B;QAE7B,IAAI,OAAO,CAAC,OAAO,CAAC,OAAO,KAAK,OAAO,EAAE;YACvC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,oBAAQ,CAAC,eAAe,CAAC,GAAG,CAAC,CAAC;YACvD,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,0BAAc,CAAC,UAAU,CAAC;gBAC9C,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,0BAAc,CAAC,UAAU,CAAC,IAAI,EAAE,CAAC;YACzD,MAAM,kBAAkB,GAAG,cAAK,CAAC,qBAAqB,EAAE,CAAC;YACzD,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,0BAAc,CAAC,UAAU,CAAC,CAC9C,oDAA2B,CAAC,kBAAkB,CAC/C,GAAG,kBAAkB,CAAC;YAC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ult = Result<any, FxError>;
3
- export declare class ResultFactory {
4
- static readonly source: string;
5
- static UserError(name: string, messages: [string, string], innerError?: any, stack?: string, helpLink?: string): UserError;
6
- static SystemError(name: string, messages: [string, string], innerError?: any, stack?: string, issueLink?: string): SystemError;
7
- static Success(result?: any): SimpleAuthResult;
8
- }
9
- //# sourceMappingURL=result.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"result.d.ts","sourceRoot":"","sources":["../../../../src/component/resource/simpleAuth/result.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAM,MAAM,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAIrF,oBAAY,gBAAgB,GAAG,MAAM,CAAC,GAAG,EAAE,OAAO,CAAC,CAAC;AAEpD,qBAAa,aAAa;IACxB,MAAM,CAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAwC;WAExD,SAAS,CACrB,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,EAC1B,UAAU,CAAC,EAAE,GAAG,EAChB,KAAK,CAAC,EAAE,MAAM,EACd,QAAQ,CAAC,EAAE,MAAM,GAChB,SAAS;WAWE,WAAW,CACvB,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,EAC1B,UAAU,CAAC,EAAE,GAAG,EAChB,KAAK,CAAC,EAAE,MAAM,EACd,SAAS,CAAC,EAAE,MAAM,GACjB,WAAW;WAWA,OAAO,CAAC,MAAM,CAAC,EAAE,GAAG,GAAG,gBAAgB;CAGtD"}
@@ -1,35 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ResultFactory = void 0;
4
- // Copyright (c) Microsoft Corporation.
5
- // Licensed under the MIT license.
6
- const teamsfx_api_1 = require("@microsoft/teamsfx-api");
7
- const constants_1 = require("./constants");
8
- class ResultFactory {
9
- static UserError(name, messages, innerError, stack, helpLink) {
10
- return new teamsfx_api_1.UserError({
11
- name,
12
- message: messages[0],
13
- displayMessage: messages[1],
14
- source: this.source,
15
- helpLink,
16
- error: innerError,
17
- });
18
- }
19
- static SystemError(name, messages, innerError, stack, issueLink) {
20
- return new teamsfx_api_1.SystemError({
21
- name,
22
- message: messages[0],
23
- displayMessage: messages[1],
24
- source: this.source,
25
- issueLink,
26
- error: innerError,
27
- });
28
- }
29
- static Success(result) {
30
- return teamsfx_api_1.ok(result);
31
- }
32
- }
33
- exports.ResultFactory = ResultFactory;
34
- ResultFactory.source = constants_1.Constants.SimpleAuthPlugin.shortName;
35
- //# sourceMappingURL=result.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"result.js","sourceRoot":"","sources":["../../../../src/component/resource/simpleAuth/result.ts"],"names":[],"mappings":";;;AAAA,uCAAuC;AACvC,kCAAkC;AAClC,wDAAqF;AAErF,2CAAwC;AAIxC,MAAa,aAAa;IAGjB,MAAM,CAAC,SAAS,CACrB,IAAY,EACZ,QAA0B,EAC1B,UAAgB,EAChB,KAAc,EACd,QAAiB;QAEjB,OAAO,IAAI,uBAAS,CAAC;YACnB,IAAI;YACJ,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC;YACpB,cAAc,EAAE,QAAQ,CAAC,CAAC,CAAC;YAC3B,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,QAAQ;YACR,KAAK,EAAE,UAAU;SAClB,CAAC,CAAC;IACL,CAAC;IAEM,MAAM,CAAC,WAAW,CACvB,IAAY,EACZ,QAA0B,EAC1B,UAAgB,EAChB,KAAc,EACd,SAAkB;QAElB,OAAO,IAAI,yBAAW,CAAC;YACrB,IAAI;YACJ,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC;YACpB,cAAc,EAAE,QAAQ,CAAC,CAAC,CAAC;YAC3B,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,SAAS;YACT,KAAK,EAAE,UAAU;SAClB,CAAC,CAAC;IACL,CAAC;IAEM,MAAM,CAAC,OAAO,CAAC,MAAY;QAChC,OAAO,gBAAE,CAAC,MAAM,CAAC,CAAC;IACpB,CAAC;;AAvCH,sCAwCC;AAvCiB,oBAAM,GAAW,qBAAS,CAAC,gBAAgB,CAAC,SAAS,CAAC"}
@@ -1,23 +0,0 @@
1
- import { LogProvider, PluginContext } from "@microsoft/teamsfx-api";
2
- import { Message } from "../constants";
3
- export declare class Utils {
4
- static generateResourceName(appName: string, resourceNameSuffix: string): string;
5
- static getSimpleAuthFilePath(): string;
6
- static downloadZip(filePath: string): Promise<void>;
7
- static getWebAppConfig(ctx: PluginContext, isLocalDebug: boolean): {
8
- [propertyName: string]: string;
9
- };
10
- static addLocalDebugPrefix(isLocalDebug: boolean, key: string): string;
11
- static addLogAndTelemetry(logProvider: LogProvider | undefined, message: Message, properties?: {
12
- [key: string]: string;
13
- }): void;
14
- static getConfigValueWithValidation(ctx: PluginContext, pluginId: string, configKey: string, isLocalDebug?: boolean): string;
15
- static isUserError(error: any): boolean;
16
- private static getClientId;
17
- private static getClientSecret;
18
- private static getFrontendEndpoint;
19
- private static getOauthAuthority;
20
- private static getApplicationIdUris;
21
- private static checkFileExist;
22
- }
23
- //# sourceMappingURL=common.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../../../../src/component/resource/simpleAuth/utils/common.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAGpE,OAAO,EAAa,OAAO,EAAE,MAAM,cAAc,CAAC;AAiBlD,qBAAa,KAAK;WACF,oBAAoB,CAAC,OAAO,EAAE,MAAM,EAAE,kBAAkB,EAAE,MAAM,GAAG,MAAM;WAWzE,qBAAqB,IAAI,MAAM;WAWzB,WAAW,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;WAkClD,eAAe,CAC3B,GAAG,EAAE,aAAa,EAClB,YAAY,EAAE,OAAO,GACpB;QAAE,CAAC,YAAY,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE;WAgCvB,mBAAmB,CAAC,YAAY,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM;WAI/D,kBAAkB,CAC9B,WAAW,EAAE,WAAW,GAAG,SAAS,EACpC,OAAO,EAAE,OAAO,EAChB,UAAU,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,GACrC,IAAI;WAKO,4BAA4B,CACxC,GAAG,EAAE,aAAa,EAClB,QAAQ,EAAE,MAAM,EAChB,SAAS,EAAE,MAAM,EACjB,YAAY,UAAQ,GACnB,MAAM;WASK,WAAW,CAAC,KAAK,EAAE,GAAG,GAAG,OAAO;IAY9C,OAAO,CAAC,MAAM,CAAC,WAAW;IAa1B,OAAO,CAAC,MAAM,CAAC,eAAe;IAa9B,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAYlC,OAAO,CAAC,MAAM,CAAC,iBAAiB;IAYhC,OAAO,CAAC,MAAM,CAAC,oBAAoB;mBAad,cAAc;CAQpC"}
@@ -1,150 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Utils = void 0;
4
- const tslib_1 = require("tslib");
5
- const path = tslib_1.__importStar(require("path"));
6
- const fs = tslib_1.__importStar(require("fs-extra"));
7
- const constants_1 = require("../constants");
8
- const errors_1 = require("../errors");
9
- const result_1 = require("../result");
10
- const telemetry_1 = require("./telemetry");
11
- const folder_1 = require("../../../../folder");
12
- const got_1 = tslib_1.__importDefault(require("got"));
13
- const os_1 = tslib_1.__importDefault(require("os"));
14
- const localSettingsConstants_1 = require("../../../../common/localSettingsConstants");
15
- const tools_1 = require("../../../../common/tools");
16
- class Utils {
17
- static generateResourceName(appName, resourceNameSuffix) {
18
- const paddingLength = constants_1.Constants.ResourceNameMaxLength -
19
- resourceNameSuffix.length -
20
- constants_1.Constants.SimpleAuthSuffix.length;
21
- const normalizedAppName = appName.replace(/[^a-zA-Z0-9]/g, "").toLowerCase();
22
- return (normalizedAppName.substr(0, paddingLength) + constants_1.Constants.SimpleAuthSuffix + resourceNameSuffix);
23
- }
24
- static getSimpleAuthFilePath() {
25
- // const fxCoreDir: string = path.join(__dirname, "..", "..", "..", "..", "..");
26
- return path.join(folder_1.getTemplatesFolder(), "plugins", "resource", "simpleauth", constants_1.Constants.SimpleAuthFileName);
27
- }
28
- static async downloadZip(filePath) {
29
- if (await Utils.checkFileExist(filePath)) {
30
- return;
31
- }
32
- const versionFilePath = path.join(filePath, "..", constants_1.Constants.VersionFileName);
33
- if (!(await Utils.checkFileExist(versionFilePath))) {
34
- throw result_1.ResultFactory.SystemError(errors_1.VersionFileNotExist.name, errors_1.VersionFileNotExist.message(versionFilePath));
35
- }
36
- const versionFile = await fs.readFile(versionFilePath, "utf-8");
37
- const version = versionFile.split(os_1.default.EOL)[0];
38
- const tag = constants_1.Constants.SimpleAuthTag(version);
39
- const fileName = constants_1.Constants.SimpleAuthZipName(version);
40
- const distUrl = constants_1.Constants.SimpleAuthReleaseUrl(tag, fileName);
41
- try {
42
- await got_1.default.stream(distUrl).pipe(fs.createWriteStream(filePath));
43
- }
44
- catch (error) {
45
- throw result_1.ResultFactory.SystemError(errors_1.ZipDownloadError.name, errors_1.ZipDownloadError.message(error === null || error === void 0 ? void 0 : error.message), error);
46
- }
47
- if (!(await Utils.checkFileExist(filePath))) {
48
- throw result_1.ResultFactory.SystemError(errors_1.ZipDownloadError.name, errors_1.ZipDownloadError.message());
49
- }
50
- }
51
- static getWebAppConfig(ctx, isLocalDebug) {
52
- const clientId = this.getClientId(ctx, isLocalDebug);
53
- const clientSecret = this.getClientSecret(ctx, isLocalDebug);
54
- const oauthAuthority = this.getOauthAuthority(ctx, isLocalDebug);
55
- const applicationIdUris = this.getApplicationIdUris(ctx, isLocalDebug);
56
- const endpoint = this.getFrontendEndpoint(ctx, isLocalDebug);
57
- const allowedAppIds = tools_1.getAllowedAppIds().join(";");
58
- const aadMetadataAddress = `${oauthAuthority}/v2.0/.well-known/openid-configuration`;
59
- let endpointUrl;
60
- try {
61
- endpointUrl = new URL(endpoint);
62
- }
63
- catch (error) {
64
- throw result_1.ResultFactory.SystemError(errors_1.EndpointInvalidError.name, errors_1.EndpointInvalidError.message(endpoint, error.message));
65
- }
66
- const tabAppEndpoint = endpointUrl.origin;
67
- return {
68
- [constants_1.Constants.ApplicationSettingsKeys.clientId]: clientId,
69
- [constants_1.Constants.ApplicationSettingsKeys.clientSecret]: clientSecret,
70
- [constants_1.Constants.ApplicationSettingsKeys.oauthAuthority]: oauthAuthority,
71
- [constants_1.Constants.ApplicationSettingsKeys.applicationIdUris]: applicationIdUris,
72
- [constants_1.Constants.ApplicationSettingsKeys.allowedAppIds]: allowedAppIds,
73
- [constants_1.Constants.ApplicationSettingsKeys.tabAppEndpoint]: tabAppEndpoint,
74
- [constants_1.Constants.ApplicationSettingsKeys.aadMetadataAddress]: aadMetadataAddress,
75
- };
76
- }
77
- static addLocalDebugPrefix(isLocalDebug, key) {
78
- return isLocalDebug ? constants_1.Constants.LocalPrefix + key : key;
79
- }
80
- static addLogAndTelemetry(logProvider, message, properties) {
81
- logProvider === null || logProvider === void 0 ? void 0 : logProvider.info(message.log);
82
- telemetry_1.TelemetryUtils.sendEvent(message.telemetry, properties);
83
- }
84
- static getConfigValueWithValidation(ctx, pluginId, configKey, isLocalDebug = false) {
85
- var _a;
86
- const key = Utils.addLocalDebugPrefix(isLocalDebug, configKey);
87
- const configValue = (_a = ctx.envInfo.state.get(pluginId)) === null || _a === void 0 ? void 0 : _a.get(key);
88
- if (!configValue) {
89
- throw result_1.ResultFactory.SystemError(errors_1.NoConfigError.name, errors_1.NoConfigError.message(pluginId, key));
90
- }
91
- return configValue;
92
- }
93
- static isUserError(error) {
94
- var _a, _b, _c;
95
- if (((_a = error === null || error === void 0 ? void 0 : error.response) === null || _a === void 0 ? void 0 : _a.status) &&
96
- ((_b = error === null || error === void 0 ? void 0 : error.response) === null || _b === void 0 ? void 0 : _b.status) >= constants_1.Constants.statusCodeUserError &&
97
- ((_c = error === null || error === void 0 ? void 0 : error.response) === null || _c === void 0 ? void 0 : _c.status) < constants_1.Constants.statusCodeServerError) {
98
- return true;
99
- }
100
- else {
101
- return false;
102
- }
103
- }
104
- static getClientId(ctx, isLocalDebug) {
105
- var _a, _b;
106
- const clientId = isLocalDebug
107
- ? (_b = (_a = ctx.localSettings) === null || _a === void 0 ? void 0 : _a.auth) === null || _b === void 0 ? void 0 : _b.get(localSettingsConstants_1.LocalSettingsAuthKeys.ClientId)
108
- : Utils.getConfigValueWithValidation(ctx, constants_1.Constants.AadAppPlugin.id, constants_1.Constants.AadAppPlugin.configKeys.clientId, isLocalDebug);
109
- return clientId;
110
- }
111
- static getClientSecret(ctx, isLocalDebug) {
112
- var _a, _b;
113
- const clientSecret = isLocalDebug
114
- ? (_b = (_a = ctx.localSettings) === null || _a === void 0 ? void 0 : _a.auth) === null || _b === void 0 ? void 0 : _b.get(localSettingsConstants_1.LocalSettingsAuthKeys.ClientSecret)
115
- : Utils.getConfigValueWithValidation(ctx, constants_1.Constants.AadAppPlugin.id, constants_1.Constants.AadAppPlugin.configKeys.clientSecret, isLocalDebug);
116
- return clientSecret;
117
- }
118
- static getFrontendEndpoint(ctx, isLocalDebug) {
119
- var _a, _b;
120
- const tabEndpoint = isLocalDebug
121
- ? (_b = (_a = ctx.localSettings) === null || _a === void 0 ? void 0 : _a.frontend) === null || _b === void 0 ? void 0 : _b.get(localSettingsConstants_1.LocalSettingsFrontendKeys.TabEndpoint)
122
- : Utils.getConfigValueWithValidation(ctx, constants_1.Constants.FrontendPlugin.id, constants_1.Constants.FrontendPlugin.configKeys.endpoint);
123
- return tabEndpoint;
124
- }
125
- static getOauthAuthority(ctx, isLocalDebug) {
126
- var _a, _b;
127
- const oauthAuthority = isLocalDebug
128
- ? (_b = (_a = ctx.localSettings) === null || _a === void 0 ? void 0 : _a.auth) === null || _b === void 0 ? void 0 : _b.get(localSettingsConstants_1.LocalSettingsAuthKeys.OauthAuthority)
129
- : Utils.getConfigValueWithValidation(ctx, constants_1.Constants.AadAppPlugin.id, constants_1.Constants.AadAppPlugin.configKeys.oauthAuthority);
130
- return oauthAuthority;
131
- }
132
- static getApplicationIdUris(ctx, isLocalDebug) {
133
- var _a, _b;
134
- const applicationIdUris = isLocalDebug
135
- ? (_b = (_a = ctx.localSettings) === null || _a === void 0 ? void 0 : _a.auth) === null || _b === void 0 ? void 0 : _b.get(localSettingsConstants_1.LocalSettingsAuthKeys.ApplicationIdUris)
136
- : Utils.getConfigValueWithValidation(ctx, constants_1.Constants.AadAppPlugin.id, constants_1.Constants.AadAppPlugin.configKeys.applicationIdUris, isLocalDebug);
137
- return applicationIdUris;
138
- }
139
- static async checkFileExist(filePath) {
140
- try {
141
- await fs.stat(filePath);
142
- return true;
143
- }
144
- catch (error) {
145
- return false;
146
- }
147
- }
148
- }
149
- exports.Utils = Utils;
150
- //# sourceMappingURL=common.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"common.js","sourceRoot":"","sources":["../../../../../src/component/resource/simpleAuth/utils/common.ts"],"names":[],"mappings":";;;;AAGA,mDAA6B;AAC7B,qDAA+B;AAC/B,4CAAkD;AAClD,sCAKmB;AACnB,sCAA0C;AAC1C,2CAA6C;AAC7C,+CAAwD;AACxD,sDAAsB;AACtB,oDAAoB;AACpB,sFAGmD;AACnD,oDAA4D;AAC5D,MAAa,KAAK;IACT,MAAM,CAAC,oBAAoB,CAAC,OAAe,EAAE,kBAA0B;QAC5E,MAAM,aAAa,GACjB,qBAAS,CAAC,qBAAqB;YAC/B,kBAAkB,CAAC,MAAM;YACzB,qBAAS,CAAC,gBAAgB,CAAC,MAAM,CAAC;QACpC,MAAM,iBAAiB,GAAG,OAAO,CAAC,OAAO,CAAC,eAAe,EAAE,EAAE,CAAC,CAAC,WAAW,EAAE,CAAC;QAC7E,OAAO,CACL,iBAAiB,CAAC,MAAM,CAAC,CAAC,EAAE,aAAa,CAAC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CAAC,UAAU,CAAC,iBAAiB,EACnD,YAAY,CACF,CAAC;QAEjB,OAAO,iBAAiB,CAAC;IAC3B,CAAC;IAEO,MAAM,CAAC,KAAK,CAAC,cAAc,CAAC,QAAgB;QAClD,IAAI;YACF,MAAM,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;YACxB,OAAO,IAAI,CAAC;SACb;QAAC,OAAO,KAAK,EAAE;YACd,OAAO,KAAK,CAAC;SACd;IACH,CAAC;CACF;AA1MD,sBA0MC"}
@@ -1,5 +0,0 @@
1
- import { IProgressHandler } from "@microsoft/teamsfx-api";
2
- export declare class DialogUtils {
3
- static progressBar: IProgressHandler | undefined;
4
- }
5
- //# sourceMappingURL=dialog.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dialog.d.ts","sourceRoot":"","sources":["../../../../../src/component/resource/simpleAuth/utils/dialog.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAE1D,qBAAa,WAAW;IACtB,OAAc,WAAW,EAAE,gBAAgB,GAAG,SAAS,CAAC;CACzD"}
@@ -1,7 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.DialogUtils = void 0;
4
- class DialogUtils {
5
- }
6
- exports.DialogUtils = DialogUtils;
7
- //# sourceMappingURL=dialog.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dialog.js","sourceRoot":"","sources":["../../../../../src/component/resource/simpleAuth/utils/dialog.ts"],"names":[],"mappings":";;;AAIA,MAAa,WAAW;CAEvB;AAFD,kCAEC"}
@@ -1,17 +0,0 @@
1
- import { PluginContext } from "@microsoft/teamsfx-api";
2
- export declare class TelemetryUtils {
3
- static ctx: PluginContext;
4
- static init(ctx: PluginContext): void;
5
- static sendEvent(eventName: string, properties?: {
6
- [key: string]: string;
7
- }, measurements?: {
8
- [key: string]: number;
9
- }): void;
10
- static sendErrorEvent(eventName: string, errorName: string, errorType: string, errorMessage: string, properties?: {
11
- [key: string]: string;
12
- }, measurements?: {
13
- [key: string]: number;
14
- }): void;
15
- private static addAppIdInProperty;
16
- }
17
- //# sourceMappingURL=telemetry.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"telemetry.d.ts","sourceRoot":"","sources":["../../../../../src/component/resource/simpleAuth/utils/telemetry.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAGvD,qBAAa,cAAc;IACzB,MAAM,CAAC,GAAG,EAAE,aAAa,CAAC;WAEZ,IAAI,CAAC,GAAG,EAAE,aAAa;WAIvB,SAAS,CACrB,SAAS,EAAE,MAAM,EACjB,UAAU,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,EACtC,YAAY,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE;WAW5B,cAAc,CAC1B,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,MAAM,EACpB,UAAU,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,EACtC,YAAY,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE;IAkB1C,OAAO,CAAC,MAAM,CAAC,kBAAkB;CAalC"}
@@ -1,45 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.TelemetryUtils = void 0;
4
- const constants_1 = require("../constants");
5
- class TelemetryUtils {
6
- static init(ctx) {
7
- TelemetryUtils.ctx = ctx;
8
- }
9
- static sendEvent(eventName, properties, measurements) {
10
- var _a;
11
- if (!properties) {
12
- properties = {};
13
- }
14
- properties[constants_1.Telemetry.isSuccess] = constants_1.Telemetry.success;
15
- properties[constants_1.Telemetry.component] = constants_1.Constants.SimpleAuthPlugin.id;
16
- TelemetryUtils.addAppIdInProperty(properties, this.ctx);
17
- (_a = TelemetryUtils.ctx.telemetryReporter) === null || _a === void 0 ? void 0 : _a.sendTelemetryEvent(eventName, properties, measurements);
18
- }
19
- static sendErrorEvent(eventName, errorName, errorType, errorMessage, properties, measurements) {
20
- var _a;
21
- if (!properties) {
22
- properties = {};
23
- }
24
- properties[constants_1.Telemetry.isSuccess] = constants_1.Telemetry.fail;
25
- properties[constants_1.Telemetry.component] = constants_1.Constants.SimpleAuthPlugin.id;
26
- properties[constants_1.Telemetry.errorCode] = `${constants_1.Constants.SimpleAuthPlugin.shortName}.${errorName}`;
27
- properties[constants_1.Telemetry.errorType] = errorType;
28
- properties[constants_1.Telemetry.errorMessage] = errorMessage;
29
- TelemetryUtils.addAppIdInProperty(properties, this.ctx);
30
- (_a = TelemetryUtils.ctx.telemetryReporter) === null || _a === void 0 ? void 0 : _a.sendTelemetryErrorEvent(eventName, properties, measurements);
31
- }
32
- static addAppIdInProperty(properties, ctx) {
33
- var _a;
34
- const appId = (_a = ctx.envInfo.state
35
- .get(constants_1.Constants.SolutionPlugin.id)) === null || _a === void 0 ? void 0 : _a.get(constants_1.Constants.SolutionPlugin.configKeys.remoteTeamsAppId);
36
- if (appId) {
37
- properties[constants_1.Telemetry.appId] = appId;
38
- }
39
- else {
40
- properties[constants_1.Telemetry.appId] = "";
41
- }
42
- }
43
- }
44
- exports.TelemetryUtils = TelemetryUtils;
45
- //# sourceMappingURL=telemetry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"telemetry.js","sourceRoot":"","sources":["../../../../../src/component/resource/simpleAuth/utils/telemetry.ts"],"names":[],"mappings":";;;AAGA,4CAAoD;AAEpD,MAAa,cAAc;IAGlB,MAAM,CAAC,IAAI,CAAC,GAAkB;QACnC,cAAc,CAAC,GAAG,GAAG,GAAG,CAAC;IAC3B,CAAC;IAEM,MAAM,CAAC,SAAS,CACrB,SAAiB,EACjB,UAAsC,EACtC,YAAwC;;QAExC,IAAI,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B,MAAM,KAAK,GAAG,MAAA,GAAG,CAAC,OAAO,CAAC,KAAK;aAC5B,GAAG,CAAC,qBAAS,CAAC,cAAc,CAAC,EAAE,CAAC,0CAC/B,GAAG,CAAC,qBAAS,CAAC,cAAc,CAAC,UAAU,CAAC,gBAAgB,CAAC,CAAC;QAC9D,IAAI,KAAK,EAAE;YACT,UAAU,CAAC,qBAAS,CAAC,KAAK,CAAC,GAAG,KAAe,CAAC;SAC/C;aAAM;YACL,UAAU,CAAC,qBAAS,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC;SAClC;IACH,CAAC;CACF;AA1DD,wCA0DC"}
@@ -1 +0,0 @@
1
- //# sourceMappingURL=dependencyChecker.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dependencyChecker.d.ts","sourceRoot":"","sources":["../../src/core/dependencyChecker.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";
2
- //# sourceMappingURL=dependencyChecker.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dependencyChecker.js","sourceRoot":"","sources":["../../src/core/dependencyChecker.ts"],"names":[],"mappings":""}
@@ -1,14 +0,0 @@
1
- import { HookContext, Middleware } from "@feathersjs/hooks";
2
- import { FxError, Result } from "@microsoft/teamsfx-api";
3
- export interface ErrorHandleOption {
4
- error?: FxError;
5
- startFn?: (ctx: HookContext) => Promise<Result<any, FxError>>;
6
- endFn?: (ctx: HookContext) => Promise<Result<any, FxError>>;
7
- telemetry?: {
8
- component: string;
9
- eventName?: string;
10
- properties?: Record<string, string>;
11
- };
12
- }
13
- export declare function CommonErrorHandlerMW(option?: ErrorHandleOption): Middleware;
14
- //# sourceMappingURL=CommonErrorHandlerMW.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CommonErrorHandlerMW.d.ts","sourceRoot":"","sources":["../../../src/core/middleware/CommonErrorHandlerMW.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,UAAU,EAAgB,MAAM,mBAAmB,CAAC;AAC1E,OAAO,EAAsB,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAU7E,MAAM,WAAW,iBAAiB;IAChC,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,OAAO,CAAC,EAAE,CAAC,GAAG,EAAE,WAAW,KAAK,OAAO,CAAC,MAAM,CAAC,GAAG,EAAE,OAAO,CAAC,CAAC,CAAC;IAC9D,KAAK,CAAC,EAAE,CAAC,GAAG,EAAE,WAAW,KAAK,OAAO,CAAC,MAAM,CAAC,GAAG,EAAE,OAAO,CAAC,CAAC,CAAC;IAC5D,SAAS,CAAC,EAAE;QACV,SAAS,EAAE,MAAM,CAAC;QAClB,SAAS,CAAC,EAAE,MAAM,CAAC;QACnB,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;KACrC,CAAC;CACH;AAED,wBAAgB,oBAAoB,CAAC,MAAM,CAAC,EAAE,iBAAiB,GAAG,UAAU,CA4D3E"}