@microsoft/teamsfx-core 2.0.4-alpha.dc097d3df.0 → 2.0.4-alpha.e432bab97.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/build/common/deps-checker/checkerFactory.d.ts +1 -2
- package/build/common/deps-checker/checkerFactory.d.ts.map +1 -1
- package/build/common/deps-checker/checkerFactory.js +2 -2
- package/build/common/deps-checker/checkerFactory.js.map +1 -1
- package/build/common/deps-checker/depsLogger.d.ts +14 -14
- package/build/common/deps-checker/depsLogger.d.ts.map +1 -1
- package/build/common/deps-checker/depsLogger.js +7 -21
- package/build/common/deps-checker/depsLogger.js.map +1 -1
- package/build/common/deps-checker/internal/dotnetChecker.d.ts.map +1 -1
- package/build/common/deps-checker/internal/dotnetChecker.js +42 -37
- package/build/common/deps-checker/internal/dotnetChecker.js.map +1 -1
- package/build/common/deps-checker/internal/funcToolChecker.d.ts.map +1 -1
- package/build/common/deps-checker/internal/funcToolChecker.js +2 -2
- package/build/common/deps-checker/internal/funcToolChecker.js.map +1 -1
- package/build/common/deps-checker/internal/nodeChecker.d.ts.map +1 -1
- package/build/common/deps-checker/internal/nodeChecker.js +8 -8
- package/build/common/deps-checker/internal/nodeChecker.js.map +1 -1
- package/build/common/deps-checker/internal/vxTestAppChecker.js +1 -1
- package/build/common/deps-checker/internal/vxTestAppChecker.js.map +1 -1
- package/build/common/deps-checker/util/cpUtils.d.ts +1 -1
- package/build/common/deps-checker/util/cpUtils.d.ts.map +1 -1
- package/build/common/deps-checker/util/cpUtils.js +5 -5
- package/build/common/deps-checker/util/cpUtils.js.map +1 -1
- package/build/common/deps-checker/util/fileHelper.d.ts.map +1 -1
- package/build/common/deps-checker/util/fileHelper.js +2 -0
- package/build/common/deps-checker/util/fileHelper.js.map +1 -1
- package/build/common/deps-checker/util/progressIndicator.js +2 -2
- package/build/common/deps-checker/util/progressIndicator.js.map +1 -1
- package/build/common/featureFlags.d.ts +1 -0
- package/build/common/featureFlags.d.ts.map +1 -1
- package/build/common/featureFlags.js +7 -2
- package/build/common/featureFlags.js.map +1 -1
- package/build/common/jsonUtils.d.ts.map +1 -1
- package/build/common/jsonUtils.js +2 -0
- package/build/common/jsonUtils.js.map +1 -1
- package/build/common/local/localCertificateManager.d.ts.map +1 -1
- package/build/common/local/localCertificateManager.js +4 -1
- package/build/common/local/localCertificateManager.js.map +1 -1
- package/build/common/local/packageJsonHelper.d.ts.map +1 -1
- package/build/common/local/packageJsonHelper.js +1 -0
- package/build/common/local/packageJsonHelper.js.map +1 -1
- package/build/common/local/portChecker.js.map +1 -1
- package/build/common/m365/launchHelper.d.ts +2 -2
- package/build/common/m365/launchHelper.d.ts.map +1 -1
- package/build/common/m365/launchHelper.js +13 -4
- package/build/common/m365/launchHelper.js.map +1 -1
- package/build/common/m365/packageService.d.ts.map +1 -1
- package/build/common/m365/packageService.js +38 -0
- package/build/common/m365/packageService.js.map +1 -1
- package/build/common/projectSettingsHelper.d.ts.map +1 -1
- package/build/common/projectSettingsHelper.js +1 -0
- package/build/common/projectSettingsHelper.js.map +1 -1
- package/build/common/samples-config-v3.json +234 -27
- package/build/common/samples.d.ts +10 -6
- package/build/common/samples.d.ts.map +1 -1
- package/build/common/samples.js +31 -29
- package/build/common/samples.js.map +1 -1
- package/build/common/spec-parser/adaptiveCardGenerator.d.ts +5 -0
- package/build/common/spec-parser/adaptiveCardGenerator.d.ts.map +1 -0
- package/build/common/spec-parser/adaptiveCardGenerator.js +119 -0
- package/build/common/spec-parser/adaptiveCardGenerator.js.map +1 -0
- package/build/common/spec-parser/constants.d.ts +20 -0
- package/build/common/spec-parser/constants.d.ts.map +1 -0
- package/build/common/spec-parser/constants.js +27 -0
- package/build/common/spec-parser/constants.js.map +1 -0
- package/build/common/spec-parser/interfaces.d.ts +133 -0
- package/build/common/spec-parser/interfaces.d.ts.map +1 -0
- package/build/common/spec-parser/interfaces.js +46 -0
- package/build/common/spec-parser/interfaces.js.map +1 -0
- package/build/common/spec-parser/manifestUpdater.d.ts +5 -0
- package/build/common/spec-parser/manifestUpdater.d.ts.map +1 -0
- package/build/common/spec-parser/manifestUpdater.js +81 -0
- package/build/common/spec-parser/manifestUpdater.js.map +1 -0
- package/build/common/spec-parser/specFilter.d.ts +3 -0
- package/build/common/spec-parser/specFilter.d.ts.map +1 -0
- package/build/common/spec-parser/specFilter.js +40 -0
- package/build/common/spec-parser/specFilter.js.map +1 -0
- package/build/common/spec-parser/specParser.d.ts +45 -0
- package/build/common/spec-parser/specParser.d.ts.map +1 -0
- package/build/common/spec-parser/specParser.js +247 -0
- package/build/common/spec-parser/specParser.js.map +1 -0
- package/build/common/spec-parser/specParserError.d.ts +6 -0
- package/build/common/spec-parser/specParserError.d.ts.map +1 -0
- package/build/common/spec-parser/specParserError.js +13 -0
- package/build/common/spec-parser/specParserError.js.map +1 -0
- package/build/common/spec-parser/utils.d.ts +8 -0
- package/build/common/spec-parser/utils.d.ts.map +1 -0
- package/build/common/spec-parser/utils.js +91 -0
- package/build/common/spec-parser/utils.js.map +1 -0
- package/build/common/telemetry.d.ts +7 -5
- package/build/common/telemetry.d.ts.map +1 -1
- package/build/common/telemetry.js +40 -15
- package/build/common/telemetry.js.map +1 -1
- package/build/common/tools.js +3 -3
- package/build/common/tools.js.map +1 -1
- package/build/common/utils.d.ts +1 -0
- package/build/common/utils.d.ts.map +1 -1
- package/build/common/utils.js +5 -1
- package/build/common/utils.js.map +1 -1
- package/build/component/configManager/constant.d.ts.map +1 -1
- package/build/component/configManager/constant.js +4 -2
- package/build/component/configManager/constant.js.map +1 -1
- package/build/component/configManager/interface.d.ts +5 -0
- package/build/component/configManager/interface.d.ts.map +1 -1
- package/build/component/configManager/interface.js +2 -3
- package/build/component/configManager/interface.js.map +1 -1
- package/build/component/configManager/lifecycle.d.ts.map +1 -1
- package/build/component/configManager/lifecycle.js +22 -13
- package/build/component/configManager/lifecycle.js.map +1 -1
- package/build/component/configManager/parser.d.ts.map +1 -1
- package/build/component/configManager/parser.js +17 -9
- package/build/component/configManager/parser.js.map +1 -1
- package/build/component/configManager/validator.d.ts +0 -3
- package/build/component/configManager/validator.d.ts.map +1 -1
- package/build/component/configManager/validator.js +4 -12
- package/build/component/configManager/validator.js.map +1 -1
- package/build/component/constants.d.ts +10 -23
- package/build/component/constants.d.ts.map +1 -1
- package/build/component/constants.js +11 -24
- package/build/component/constants.js.map +1 -1
- package/build/component/coordinator/index.d.ts +12 -8
- package/build/component/coordinator/index.d.ts.map +1 -1
- package/build/component/coordinator/index.js +76 -59
- package/build/component/coordinator/index.js.map +1 -1
- package/build/component/coordinator/summary.d.ts.map +1 -1
- package/build/component/coordinator/summary.js +4 -1
- package/build/component/coordinator/summary.js.map +1 -1
- package/build/component/developerPortalScaffoldUtils.d.ts +1 -1
- package/build/component/developerPortalScaffoldUtils.d.ts.map +1 -1
- package/build/component/developerPortalScaffoldUtils.js +7 -7
- package/build/component/developerPortalScaffoldUtils.js.map +1 -1
- package/build/component/driver/aad/create.d.ts +1 -0
- package/build/component/driver/aad/create.d.ts.map +1 -1
- package/build/component/driver/aad/create.js +2 -5
- package/build/component/driver/aad/create.js.map +1 -1
- package/build/component/driver/aad/error/aadManifestError.d.ts +13 -3
- package/build/component/driver/aad/error/aadManifestError.d.ts.map +1 -1
- package/build/component/driver/aad/error/aadManifestError.js +51 -5
- package/build/component/driver/aad/error/aadManifestError.js.map +1 -1
- package/build/component/driver/aad/interface/AADApplication.js +1 -1
- package/build/component/driver/aad/interface/AADApplication.js.map +1 -1
- package/build/component/driver/aad/interface/AADManifest.js +1 -1
- package/build/component/driver/aad/interface/AADManifest.js.map +1 -1
- package/build/component/driver/aad/update.d.ts +1 -0
- package/build/component/driver/aad/update.d.ts.map +1 -1
- package/build/component/driver/aad/update.js +2 -5
- package/build/component/driver/aad/update.js.map +1 -1
- package/build/component/driver/aad/utility/aadAppClient.d.ts +1 -1
- package/build/component/driver/aad/utility/aadAppClient.d.ts.map +1 -1
- package/build/component/driver/aad/utility/aadAppClient.js +58 -13
- package/build/component/driver/aad/utility/aadAppClient.js.map +1 -1
- package/build/component/driver/aad/utility/aadManifestHelper.d.ts.map +1 -1
- package/build/component/driver/aad/utility/aadManifestHelper.js +14 -19
- package/build/component/driver/aad/utility/aadManifestHelper.js.map +1 -1
- package/build/component/driver/aad/utility/buildAadManifest.d.ts.map +1 -1
- package/build/component/driver/aad/utility/buildAadManifest.js +12 -2
- package/build/component/driver/aad/utility/buildAadManifest.js.map +1 -1
- package/build/component/driver/aad/utility/constants.d.ts +3 -0
- package/build/component/driver/aad/utility/constants.d.ts.map +1 -1
- package/build/component/driver/aad/utility/constants.js +4 -1
- package/build/component/driver/aad/utility/constants.js.map +1 -1
- package/build/component/driver/add/addWebPart.js +1 -1
- package/build/component/driver/add/addWebPart.js.map +1 -1
- package/build/component/driver/arm/deploy.d.ts +1 -0
- package/build/component/driver/arm/deploy.d.ts.map +1 -1
- package/build/component/driver/arm/deploy.js +1 -8
- package/build/component/driver/arm/deploy.js.map +1 -1
- package/build/component/driver/arm/deployImpl.d.ts +2 -1
- package/build/component/driver/arm/deployImpl.d.ts.map +1 -1
- package/build/component/driver/arm/deployImpl.js +15 -0
- package/build/component/driver/arm/deployImpl.js.map +1 -1
- package/build/component/driver/arm/util/bicepChecker.d.ts.map +1 -1
- package/build/component/driver/arm/util/bicepChecker.js +9 -6
- package/build/component/driver/arm/util/bicepChecker.js.map +1 -1
- package/build/component/driver/arm/util/handleError.js.map +1 -1
- package/build/component/driver/arm/validator.d.ts.map +1 -1
- package/build/component/driver/arm/validator.js +3 -3
- package/build/component/driver/arm/validator.js.map +1 -1
- package/build/component/driver/botAadApp/create.d.ts +1 -0
- package/build/component/driver/botAadApp/create.d.ts.map +1 -1
- package/build/component/driver/botAadApp/create.js +4 -7
- package/build/component/driver/botAadApp/create.js.map +1 -1
- package/build/component/driver/botFramework/createOrUpdateBot.d.ts +1 -0
- package/build/component/driver/botFramework/createOrUpdateBot.d.ts.map +1 -1
- package/build/component/driver/botFramework/createOrUpdateBot.js +7 -11
- package/build/component/driver/botFramework/createOrUpdateBot.js.map +1 -1
- package/build/component/driver/deploy/azure/azureStorageDeployDriver.d.ts.map +1 -1
- package/build/component/driver/deploy/azure/azureStorageDeployDriver.js +12 -5
- package/build/component/driver/deploy/azure/azureStorageDeployDriver.js.map +1 -1
- package/build/component/driver/deploy/azure/azureStorageStaticWebsiteConfigDriver.d.ts.map +1 -1
- package/build/component/driver/deploy/azure/azureStorageStaticWebsiteConfigDriver.js +11 -4
- package/build/component/driver/deploy/azure/azureStorageStaticWebsiteConfigDriver.js.map +1 -1
- package/build/component/driver/deploy/azure/impl/AzureZipDeployImpl.d.ts.map +1 -1
- package/build/component/driver/deploy/azure/impl/AzureZipDeployImpl.js +22 -14
- package/build/component/driver/deploy/azure/impl/AzureZipDeployImpl.js.map +1 -1
- package/build/component/driver/deploy/azure/impl/azureDeployImpl.d.ts.map +1 -1
- package/build/component/driver/deploy/azure/impl/azureDeployImpl.js +8 -8
- package/build/component/driver/deploy/azure/impl/azureDeployImpl.js.map +1 -1
- package/build/component/driver/deploy/azure/impl/baseDeployImpl.js +4 -4
- package/build/component/driver/deploy/azure/impl/baseDeployImpl.js.map +1 -1
- package/build/component/driver/deploy/spfx/deployDriver.d.ts +1 -0
- package/build/component/driver/deploy/spfx/deployDriver.d.ts.map +1 -1
- package/build/component/driver/deploy/spfx/deployDriver.js +11 -5
- package/build/component/driver/deploy/spfx/deployDriver.js.map +1 -1
- package/build/component/driver/devTool/installDriver.d.ts +1 -0
- package/build/component/driver/devTool/installDriver.d.ts.map +1 -1
- package/build/component/driver/devTool/installDriver.js +10 -6
- package/build/component/driver/devTool/installDriver.js.map +1 -1
- package/build/component/driver/file/createOrUpdateEnvironmentFile.d.ts +1 -0
- package/build/component/driver/file/createOrUpdateEnvironmentFile.d.ts.map +1 -1
- package/build/component/driver/file/createOrUpdateEnvironmentFile.js +5 -11
- package/build/component/driver/file/createOrUpdateEnvironmentFile.js.map +1 -1
- package/build/component/driver/file/createOrUpdateJsonFile.d.ts +1 -0
- package/build/component/driver/file/createOrUpdateJsonFile.d.ts.map +1 -1
- package/build/component/driver/file/createOrUpdateJsonFile.js +5 -11
- package/build/component/driver/file/createOrUpdateJsonFile.js.map +1 -1
- package/build/component/driver/interface/buildAndDeployArgs.d.ts +3 -6
- package/build/component/driver/interface/buildAndDeployArgs.d.ts.map +1 -1
- package/build/component/driver/interface/stepDriver.d.ts +1 -0
- package/build/component/driver/interface/stepDriver.d.ts.map +1 -1
- package/build/component/driver/m365/acquire.d.ts +1 -0
- package/build/component/driver/m365/acquire.d.ts.map +1 -1
- package/build/component/driver/m365/acquire.js +5 -11
- package/build/component/driver/m365/acquire.js.map +1 -1
- package/build/component/driver/script/baseBuildDriver.d.ts.map +1 -1
- package/build/component/driver/script/baseBuildDriver.js +1 -0
- package/build/component/driver/script/baseBuildDriver.js.map +1 -1
- package/build/component/driver/script/scriptDriver.d.ts +1 -0
- package/build/component/driver/script/scriptDriver.d.ts.map +1 -1
- package/build/component/driver/script/scriptDriver.js +30 -21
- package/build/component/driver/script/scriptDriver.js.map +1 -1
- package/build/component/driver/teamsApp/appStudio.d.ts.map +1 -1
- package/build/component/driver/teamsApp/appStudio.js +6 -6
- package/build/component/driver/teamsApp/appStudio.js.map +1 -1
- package/build/component/driver/teamsApp/clients/appStudioClient.d.ts.map +1 -1
- package/build/component/driver/teamsApp/clients/appStudioClient.js +21 -5
- package/build/component/driver/teamsApp/clients/appStudioClient.js.map +1 -1
- package/build/component/driver/teamsApp/clients/authSvcClient.d.ts +1 -1
- package/build/component/driver/teamsApp/clients/authSvcClient.d.ts.map +1 -1
- package/build/component/driver/teamsApp/clients/authSvcClient.js +3 -1
- package/build/component/driver/teamsApp/clients/authSvcClient.js.map +1 -1
- package/build/component/driver/teamsApp/configure.d.ts +1 -0
- package/build/component/driver/teamsApp/configure.d.ts.map +1 -1
- package/build/component/driver/teamsApp/configure.js +4 -17
- package/build/component/driver/teamsApp/configure.js.map +1 -1
- package/build/component/driver/teamsApp/constants.d.ts +0 -1
- package/build/component/driver/teamsApp/constants.d.ts.map +1 -1
- package/build/component/driver/teamsApp/constants.js +1 -2
- package/build/component/driver/teamsApp/constants.js.map +1 -1
- package/build/component/driver/teamsApp/copyAppPackageToSPFx.d.ts +1 -0
- package/build/component/driver/teamsApp/copyAppPackageToSPFx.d.ts.map +1 -1
- package/build/component/driver/teamsApp/copyAppPackageToSPFx.js +3 -6
- package/build/component/driver/teamsApp/copyAppPackageToSPFx.js.map +1 -1
- package/build/component/driver/teamsApp/create.d.ts +1 -0
- package/build/component/driver/teamsApp/create.d.ts.map +1 -1
- package/build/component/driver/teamsApp/create.js +4 -5
- package/build/component/driver/teamsApp/create.js.map +1 -1
- package/build/component/driver/teamsApp/createAppPackage.d.ts +3 -2
- package/build/component/driver/teamsApp/createAppPackage.d.ts.map +1 -1
- package/build/component/driver/teamsApp/createAppPackage.js +47 -23
- package/build/component/driver/teamsApp/createAppPackage.js.map +1 -1
- package/build/component/driver/teamsApp/errors.d.ts.map +1 -1
- package/build/component/driver/teamsApp/errors.js +2 -0
- package/build/component/driver/teamsApp/errors.js.map +1 -1
- package/build/component/driver/teamsApp/interfaces/appdefinitions/messagingExtension.d.ts +3 -0
- package/build/component/driver/teamsApp/interfaces/appdefinitions/messagingExtension.d.ts.map +1 -1
- package/build/component/driver/teamsApp/interfaces/appdefinitions/messagingExtensionCommand.d.ts +1 -0
- package/build/component/driver/teamsApp/interfaces/appdefinitions/messagingExtensionCommand.d.ts.map +1 -1
- package/build/component/driver/teamsApp/publishAppPackage.d.ts +1 -0
- package/build/component/driver/teamsApp/publishAppPackage.d.ts.map +1 -1
- package/build/component/driver/teamsApp/publishAppPackage.js +2 -5
- package/build/component/driver/teamsApp/publishAppPackage.js.map +1 -1
- package/build/component/driver/teamsApp/results.d.ts.map +1 -1
- package/build/component/driver/teamsApp/results.js +2 -0
- package/build/component/driver/teamsApp/results.js.map +1 -1
- package/build/component/driver/teamsApp/utils/ManifestUtils.d.ts +6 -1
- package/build/component/driver/teamsApp/utils/ManifestUtils.d.ts.map +1 -1
- package/build/component/driver/teamsApp/utils/ManifestUtils.js +19 -2
- package/build/component/driver/teamsApp/utils/ManifestUtils.js.map +1 -1
- package/build/component/driver/teamsApp/utils/utils.d.ts +2 -3
- package/build/component/driver/teamsApp/utils/utils.d.ts.map +1 -1
- package/build/component/driver/teamsApp/utils/utils.js +21 -19
- package/build/component/driver/teamsApp/utils/utils.js.map +1 -1
- package/build/component/driver/teamsApp/validate.d.ts +1 -0
- package/build/component/driver/teamsApp/validate.d.ts.map +1 -1
- package/build/component/driver/teamsApp/validate.js +8 -5
- package/build/component/driver/teamsApp/validate.js.map +1 -1
- package/build/component/driver/teamsApp/validateAppPackage.d.ts +1 -0
- package/build/component/driver/teamsApp/validateAppPackage.d.ts.map +1 -1
- package/build/component/driver/teamsApp/validateAppPackage.js +26 -18
- package/build/component/driver/teamsApp/validateAppPackage.js.map +1 -1
- package/build/component/error/componentError.d.ts +2 -5
- package/build/component/error/componentError.d.ts.map +1 -1
- package/build/component/error/componentError.js +9 -14
- package/build/component/error/componentError.js.map +1 -1
- package/build/component/feature/collaboration.d.ts.map +1 -1
- package/build/component/feature/collaboration.js +50 -21
- package/build/component/feature/collaboration.js.map +1 -1
- package/build/component/feature/createAuthFiles.js.map +1 -1
- package/build/component/generator/copilotPlugin/generator.d.ts +8 -0
- package/build/component/generator/copilotPlugin/generator.d.ts.map +1 -0
- package/build/component/generator/copilotPlugin/generator.js +142 -0
- package/build/component/generator/copilotPlugin/generator.js.map +1 -0
- package/build/component/generator/copilotPlugin/helper.d.ts +30 -0
- package/build/component/generator/copilotPlugin/helper.d.ts.map +1 -0
- package/build/component/generator/copilotPlugin/helper.js +261 -0
- package/build/component/generator/copilotPlugin/helper.js.map +1 -0
- package/build/component/generator/error.d.ts +1 -1
- package/build/component/generator/error.d.ts.map +1 -1
- package/build/component/generator/error.js +2 -2
- package/build/component/generator/error.js.map +1 -1
- package/build/component/generator/generator.d.ts.map +1 -1
- package/build/component/generator/generator.js +24 -20
- package/build/component/generator/generator.js.map +1 -1
- package/build/component/generator/generatorAction.d.ts.map +1 -1
- package/build/component/generator/generatorAction.js +4 -3
- package/build/component/generator/generatorAction.js.map +1 -1
- package/build/component/generator/officeAddin/config/projectProperties.d.ts.map +1 -1
- package/build/component/generator/officeAddin/config/projectProperties.js +2 -0
- package/build/component/generator/officeAddin/config/projectProperties.js.map +1 -1
- package/build/component/generator/officeAddin/config/projectsJsonData.d.ts.map +1 -1
- package/build/component/generator/officeAddin/config/projectsJsonData.js +2 -0
- package/build/component/generator/officeAddin/config/projectsJsonData.js.map +1 -1
- package/build/component/generator/officeAddin/generator.d.ts.map +1 -1
- package/build/component/generator/officeAddin/generator.js +17 -9
- package/build/component/generator/officeAddin/generator.js.map +1 -1
- package/build/component/generator/officeAddin/helperMethods.d.ts.map +1 -1
- package/build/component/generator/officeAddin/helperMethods.js +11 -5
- package/build/component/generator/officeAddin/helperMethods.js.map +1 -1
- package/build/component/generator/spfx/depsChecker/generatorChecker.d.ts +1 -1
- package/build/component/generator/spfx/depsChecker/generatorChecker.d.ts.map +1 -1
- package/build/component/generator/spfx/depsChecker/generatorChecker.js +12 -12
- package/build/component/generator/spfx/depsChecker/generatorChecker.js.map +1 -1
- package/build/component/generator/spfx/depsChecker/yoChecker.d.ts +1 -1
- package/build/component/generator/spfx/depsChecker/yoChecker.d.ts.map +1 -1
- package/build/component/generator/spfx/depsChecker/yoChecker.js +10 -10
- package/build/component/generator/spfx/depsChecker/yoChecker.js.map +1 -1
- package/build/component/generator/spfx/error.d.ts +2 -0
- package/build/component/generator/spfx/error.d.ts.map +1 -1
- package/build/component/generator/spfx/error.js +21 -1
- package/build/component/generator/spfx/error.js.map +1 -1
- package/build/component/generator/spfx/spfxGenerator.d.ts +4 -1
- package/build/component/generator/spfx/spfxGenerator.d.ts.map +1 -1
- package/build/component/generator/spfx/spfxGenerator.js +141 -117
- package/build/component/generator/spfx/spfxGenerator.js.map +1 -1
- package/build/component/generator/spfx/utils/constants.d.ts +1 -0
- package/build/component/generator/spfx/utils/constants.d.ts.map +1 -1
- package/build/component/generator/spfx/utils/constants.js +2 -0
- package/build/component/generator/spfx/utils/constants.js.map +1 -1
- package/build/component/generator/spfx/utils/telemetryEvents.d.ts +2 -1
- package/build/component/generator/spfx/utils/telemetryEvents.d.ts.map +1 -1
- package/build/component/generator/spfx/utils/telemetryEvents.js +1 -0
- package/build/component/generator/spfx/utils/telemetryEvents.js.map +1 -1
- package/build/component/generator/spfx/utils/utils.js +3 -3
- package/build/component/generator/spfx/utils/utils.js.map +1 -1
- package/build/component/generator/utils.d.ts +10 -3
- package/build/component/generator/utils.d.ts.map +1 -1
- package/build/component/generator/utils.js +6 -9
- package/build/component/generator/utils.js.map +1 -1
- package/build/component/messages.d.ts +2 -3
- package/build/component/messages.d.ts.map +1 -1
- package/build/component/messages.js +3 -4
- package/build/component/messages.js.map +1 -1
- package/build/component/middleware/questionMW.d.ts +2 -2
- package/build/component/middleware/questionMW.d.ts.map +1 -1
- package/build/component/middleware/questionMW.js +7 -11
- package/build/component/middleware/questionMW.js.map +1 -1
- package/build/component/migrate.d.ts.map +1 -1
- package/build/component/migrate.js +2 -0
- package/build/component/migrate.js.map +1 -1
- package/build/component/provisionUtils.d.ts +3 -3
- package/build/component/provisionUtils.d.ts.map +1 -1
- package/build/component/provisionUtils.js +3 -3
- package/build/component/provisionUtils.js.map +1 -1
- package/build/component/registerService.d.ts +0 -1
- package/build/component/registerService.d.ts.map +1 -1
- package/build/component/registerService.js +0 -1
- package/build/component/registerService.js.map +1 -1
- package/build/component/resource/botService/appStudio/appStudioClient.d.ts.map +1 -1
- package/build/component/resource/botService/appStudio/appStudioClient.js +24 -2
- package/build/component/resource/botService/appStudio/appStudioClient.js.map +1 -1
- package/build/component/telemetry.d.ts.map +1 -1
- package/build/component/telemetry.js +3 -6
- package/build/component/telemetry.js.map +1 -1
- package/build/component/utils/ResourceGroupHelper.d.ts +2 -2
- package/build/component/utils/ResourceGroupHelper.d.ts.map +1 -1
- package/build/component/utils/ResourceGroupHelper.js +1 -4
- package/build/component/utils/ResourceGroupHelper.js.map +1 -1
- package/build/component/utils/azureResourceOperation.js +2 -2
- package/build/component/utils/azureResourceOperation.js.map +1 -1
- package/build/component/utils/charsetUtils.d.ts.map +1 -1
- package/build/component/utils/charsetUtils.js +5 -3
- package/build/component/utils/charsetUtils.js.map +1 -1
- package/build/component/utils/common.d.ts +1 -1
- package/build/component/utils/common.d.ts.map +1 -1
- package/build/component/utils/common.js +5 -6
- package/build/component/utils/common.js.map +1 -1
- package/build/component/utils/depsChecker/common.d.ts.map +1 -1
- package/build/component/utils/depsChecker/common.js +1 -1
- package/build/component/utils/depsChecker/common.js.map +1 -1
- package/build/component/utils/depsChecker/cpUtils.d.ts.map +1 -1
- package/build/component/utils/depsChecker/cpUtils.js +9 -5
- package/build/component/utils/depsChecker/cpUtils.js.map +1 -1
- package/build/component/utils/envUtil.d.ts.map +1 -1
- package/build/component/utils/envUtil.js +4 -2
- package/build/component/utils/envUtil.js.map +1 -1
- package/build/component/utils/metadataUtil.d.ts +3 -0
- package/build/component/utils/metadataUtil.d.ts.map +1 -1
- package/build/component/utils/metadataUtil.js +18 -4
- package/build/component/utils/metadataUtil.js.map +1 -1
- package/build/component/utils/pathUtils.d.ts.map +1 -1
- package/build/component/utils/pathUtils.js +2 -0
- package/build/component/utils/pathUtils.js.map +1 -1
- package/build/component/utils/teamsFxTelemetryReporter.d.ts.map +1 -1
- package/build/component/utils/teamsFxTelemetryReporter.js +3 -6
- package/build/component/utils/teamsFxTelemetryReporter.js.map +1 -1
- package/build/component/utils.js.map +1 -1
- package/build/core/FxCore.d.ts +43 -32
- package/build/core/FxCore.d.ts.map +1 -1
- package/build/core/FxCore.js +816 -63
- package/build/core/FxCore.js.map +1 -1
- package/build/core/collaborator.d.ts +1 -1
- package/build/core/collaborator.d.ts.map +1 -1
- package/build/core/collaborator.js +16 -10
- package/build/core/collaborator.js.map +1 -1
- package/build/core/error.d.ts +6 -0
- package/build/core/error.d.ts.map +1 -1
- package/build/core/error.js +23 -1
- package/build/core/error.js.map +1 -1
- package/build/core/globalVars.d.ts +16 -0
- package/build/core/globalVars.d.ts.map +1 -1
- package/build/core/globalVars.js +34 -1
- package/build/core/globalVars.js.map +1 -1
- package/build/core/index.js +1 -0
- package/build/core/index.js.map +1 -1
- package/build/core/middleware/concurrentLocker.d.ts.map +1 -1
- package/build/core/middleware/concurrentLocker.js +7 -3
- package/build/core/middleware/concurrentLocker.js.map +1 -1
- package/build/core/middleware/errorHandler.d.ts +2 -0
- package/build/core/middleware/errorHandler.d.ts.map +1 -1
- package/build/core/middleware/errorHandler.js +16 -25
- package/build/core/middleware/errorHandler.js.map +1 -1
- package/build/core/middleware/projectMigratorV3.d.ts +7 -1
- package/build/core/middleware/projectMigratorV3.d.ts.map +1 -1
- package/build/core/middleware/projectMigratorV3.js +35 -34
- package/build/core/middleware/projectMigratorV3.js.map +1 -1
- package/build/core/middleware/projectVersionChecker.js +8 -8
- package/build/core/middleware/projectVersionChecker.js.map +1 -1
- package/build/core/middleware/utils/appYmlGenerator.d.ts.map +1 -1
- package/build/core/middleware/utils/appYmlGenerator.js +2 -1
- package/build/core/middleware/utils/appYmlGenerator.js.map +1 -1
- package/build/core/middleware/utils/debug/appLocalYmlGenerator.d.ts.map +1 -1
- package/build/core/middleware/utils/debug/appLocalYmlGenerator.js +3 -2
- package/build/core/middleware/utils/debug/appLocalYmlGenerator.js.map +1 -1
- package/build/core/middleware/utils/debug/debugV3MigrationUtils.js.map +1 -1
- package/build/core/middleware/utils/debug/taskMigrator.d.ts.map +1 -1
- package/build/core/middleware/utils/debug/taskMigrator.js +33 -15
- package/build/core/middleware/utils/debug/taskMigrator.js.map +1 -1
- package/build/core/middleware/utils/migrationContext.d.ts +1 -0
- package/build/core/middleware/utils/migrationContext.d.ts.map +1 -1
- package/build/core/middleware/utils/migrationContext.js.map +1 -1
- package/build/core/middleware/utils/v3MigrationUtils.d.ts.map +1 -1
- package/build/core/middleware/utils/v3MigrationUtils.js +6 -2
- package/build/core/middleware/utils/v3MigrationUtils.js.map +1 -1
- package/build/error/arm.d.ts.map +1 -1
- package/build/error/arm.js +2 -0
- package/build/error/arm.js.map +1 -1
- package/build/error/azure.d.ts.map +1 -1
- package/build/error/azure.js +2 -0
- package/build/error/azure.js.map +1 -1
- package/build/error/common.d.ts +8 -2
- package/build/error/common.d.ts.map +1 -1
- package/build/error/common.js +129 -22
- package/build/error/common.js.map +1 -1
- package/build/error/deploy.d.ts.map +1 -1
- package/build/error/deploy.js +10 -8
- package/build/error/deploy.js.map +1 -1
- package/build/error/index.d.ts.map +1 -1
- package/build/error/index.js +2 -0
- package/build/error/index.js.map +1 -1
- package/build/error/m365.d.ts.map +1 -1
- package/build/error/m365.js +2 -0
- package/build/error/m365.js.map +1 -1
- package/build/error/script.d.ts.map +1 -1
- package/build/error/script.js +2 -0
- package/build/error/script.js.map +1 -1
- package/build/error/upgrade.d.ts.map +1 -1
- package/build/error/upgrade.js +2 -0
- package/build/error/upgrade.js.map +1 -1
- package/build/error/yml.d.ts.map +1 -1
- package/build/error/yml.js +2 -0
- package/build/error/yml.js.map +1 -1
- package/build/failpoint/index.d.ts.map +1 -1
- package/build/failpoint/index.js +2 -0
- package/build/failpoint/index.js.map +1 -1
- package/build/failpoint/marker.d.ts.map +1 -1
- package/build/failpoint/marker.js +2 -0
- package/build/failpoint/marker.js.map +1 -1
- package/build/failpoint/runtime.d.ts.map +1 -1
- package/build/failpoint/runtime.js +3 -4
- package/build/failpoint/runtime.js.map +1 -1
- package/build/index.d.ts +3 -1
- package/build/index.d.ts.map +1 -1
- package/build/index.js +4 -1
- package/build/index.js.map +1 -1
- package/build/question/constants.d.ts +4 -0
- package/build/question/constants.d.ts.map +1 -0
- package/build/question/constants.js +12 -0
- package/build/question/constants.js.map +1 -0
- package/build/question/create.d.ts +14 -15
- package/build/question/create.d.ts.map +1 -1
- package/build/question/create.js +478 -332
- package/build/question/create.js.map +1 -1
- package/build/question/generator.d.ts +4 -0
- package/build/question/generator.d.ts.map +1 -0
- package/build/question/generator.js +371 -0
- package/build/question/generator.js.map +1 -0
- package/build/question/index.d.ts +18 -28
- package/build/question/index.d.ts.map +1 -1
- package/build/question/index.js +18 -44
- package/build/question/index.js.map +1 -1
- package/build/question/inputs/CreateEnvInputs.d.ts +14 -0
- package/build/question/inputs/CreateEnvInputs.d.ts.map +1 -0
- package/build/question/inputs/CreateEnvInputs.js +5 -0
- package/build/question/inputs/CreateEnvInputs.js.map +1 -0
- package/build/question/inputs/CreateProjectInputs.d.ts +40 -0
- package/build/question/inputs/CreateProjectInputs.d.ts.map +1 -0
- package/build/question/inputs/CreateProjectInputs.js +5 -0
- package/build/question/inputs/CreateProjectInputs.js.map +1 -0
- package/build/question/inputs/CreateSampleProjectInputs.d.ts +12 -0
- package/build/question/inputs/CreateSampleProjectInputs.d.ts.map +1 -0
- package/build/question/inputs/CreateSampleProjectInputs.js +5 -0
- package/build/question/inputs/CreateSampleProjectInputs.js.map +1 -0
- package/build/question/inputs/DeployAadManifestInputs.d.ts +14 -0
- package/build/question/inputs/DeployAadManifestInputs.d.ts.map +1 -0
- package/build/question/inputs/DeployAadManifestInputs.js +5 -0
- package/build/question/inputs/DeployAadManifestInputs.js.map +1 -0
- package/build/question/inputs/PermissionGrantInputs.d.ts +18 -0
- package/build/question/inputs/PermissionGrantInputs.d.ts.map +1 -0
- package/build/question/inputs/PermissionGrantInputs.js +5 -0
- package/build/question/inputs/PermissionGrantInputs.js.map +1 -0
- package/build/question/inputs/PermissionListInputs.d.ts +16 -0
- package/build/question/inputs/PermissionListInputs.d.ts.map +1 -0
- package/build/question/inputs/PermissionListInputs.js +5 -0
- package/build/question/inputs/PermissionListInputs.js.map +1 -0
- package/build/question/inputs/PreviewTeamsAppInputs.d.ts +14 -0
- package/build/question/inputs/PreviewTeamsAppInputs.d.ts.map +1 -0
- package/build/question/inputs/PreviewTeamsAppInputs.js +5 -0
- package/build/question/inputs/PreviewTeamsAppInputs.js.map +1 -0
- package/build/question/inputs/SPFxAddWebpartInputs.d.ts +18 -0
- package/build/question/inputs/SPFxAddWebpartInputs.d.ts.map +1 -0
- package/build/question/inputs/SPFxAddWebpartInputs.js +5 -0
- package/build/question/inputs/SPFxAddWebpartInputs.js.map +1 -0
- package/build/question/inputs/SelectTeamsManifestInputs.d.ts +12 -0
- package/build/question/inputs/SelectTeamsManifestInputs.d.ts.map +1 -0
- package/build/question/inputs/SelectTeamsManifestInputs.js +5 -0
- package/build/question/inputs/SelectTeamsManifestInputs.js.map +1 -0
- package/build/question/inputs/ValidateTeamsAppInputs.d.ts +14 -0
- package/build/question/inputs/ValidateTeamsAppInputs.d.ts.map +1 -0
- package/build/question/inputs/ValidateTeamsAppInputs.js +5 -0
- package/build/question/inputs/ValidateTeamsAppInputs.js.map +1 -0
- package/build/question/inputs/index.d.ts +11 -0
- package/build/question/inputs/index.d.ts.map +1 -0
- package/build/question/inputs/index.js +16 -0
- package/build/question/inputs/index.js.map +1 -0
- package/build/question/options/CreateEnvOptions.d.ts +10 -0
- package/build/question/options/CreateEnvOptions.d.ts.map +1 -0
- package/build/question/options/CreateEnvOptions.js +24 -0
- package/build/question/options/CreateEnvOptions.js.map +1 -0
- package/build/question/options/CreateProjectOptions.d.ts +10 -0
- package/build/question/options/CreateProjectOptions.d.ts.map +1 -0
- package/build/question/options/CreateProjectOptions.js +139 -0
- package/build/question/options/CreateProjectOptions.js.map +1 -0
- package/build/question/options/CreateSampleProjectOptions.d.ts +10 -0
- package/build/question/options/CreateSampleProjectOptions.d.ts.map +1 -0
- package/build/question/options/CreateSampleProjectOptions.js +52 -0
- package/build/question/options/CreateSampleProjectOptions.js.map +1 -0
- package/build/question/options/DeployAadManifestOptions.d.ts +10 -0
- package/build/question/options/DeployAadManifestOptions.d.ts.map +1 -0
- package/build/question/options/DeployAadManifestOptions.js +21 -0
- package/build/question/options/DeployAadManifestOptions.js.map +1 -0
- package/build/question/options/PermissionGrantOptions.d.ts +10 -0
- package/build/question/options/PermissionGrantOptions.d.ts.map +1 -0
- package/build/question/options/PermissionGrantOptions.js +33 -0
- package/build/question/options/PermissionGrantOptions.js.map +1 -0
- package/build/question/options/PermissionListOptions.d.ts +10 -0
- package/build/question/options/PermissionListOptions.d.ts.map +1 -0
- package/build/question/options/PermissionListOptions.js +28 -0
- package/build/question/options/PermissionListOptions.js.map +1 -0
- package/build/question/options/PreviewTeamsAppOptions.d.ts +10 -0
- package/build/question/options/PreviewTeamsAppOptions.d.ts.map +1 -0
- package/build/question/options/PreviewTeamsAppOptions.js +26 -0
- package/build/question/options/PreviewTeamsAppOptions.js.map +1 -0
- package/build/question/options/SPFxAddWebpartOptions.d.ts +10 -0
- package/build/question/options/SPFxAddWebpartOptions.d.ts.map +1 -0
- package/build/question/options/SPFxAddWebpartOptions.js +38 -0
- package/build/question/options/SPFxAddWebpartOptions.js.map +1 -0
- package/build/question/options/SelectTeamsManifestOptions.d.ts +10 -0
- package/build/question/options/SelectTeamsManifestOptions.d.ts.map +1 -0
- package/build/question/options/SelectTeamsManifestOptions.js +17 -0
- package/build/question/options/SelectTeamsManifestOptions.js.map +1 -0
- package/build/question/options/ValidateTeamsAppOptions.d.ts +10 -0
- package/build/question/options/ValidateTeamsAppOptions.d.ts.map +1 -0
- package/build/question/options/ValidateTeamsAppOptions.js +23 -0
- package/build/question/options/ValidateTeamsAppOptions.js.map +1 -0
- package/build/question/options/index.d.ts +11 -0
- package/build/question/options/index.d.ts.map +1 -0
- package/build/question/options/index.js +16 -0
- package/build/question/options/index.js.map +1 -0
- package/build/question/other.d.ts +13 -1
- package/build/question/other.d.ts.map +1 -1
- package/build/question/other.js +132 -26
- package/build/question/other.js.map +1 -1
- package/build/question/questionNames.d.ts +6 -2
- package/build/question/questionNames.d.ts.map +1 -1
- package/build/question/questionNames.js +10 -3
- package/build/question/questionNames.js.map +1 -1
- package/build/question/util.d.ts +1 -1
- package/build/question/util.d.ts.map +1 -1
- package/build/question/util.js +7 -5
- package/build/question/util.js.map +1 -1
- package/build/ui/validationUtils.d.ts +15 -0
- package/build/ui/validationUtils.d.ts.map +1 -0
- package/build/ui/validationUtils.js +95 -0
- package/build/ui/validationUtils.js.map +1 -0
- package/build/ui/visitor.d.ts +13 -1
- package/build/ui/visitor.d.ts.map +1 -1
- package/build/ui/visitor.js +259 -213
- package/build/ui/visitor.js.map +1 -1
- package/package.json +15 -9
- package/resource/package.nls.cs.json +30 -56
- package/resource/package.nls.de.json +30 -56
- package/resource/package.nls.es.json +30 -56
- package/resource/package.nls.fr.json +30 -56
- package/resource/package.nls.it.json +30 -56
- package/resource/package.nls.ja.json +30 -56
- package/resource/package.nls.json +57 -19
- package/resource/package.nls.ko.json +30 -56
- package/resource/package.nls.pl.json +30 -56
- package/resource/package.nls.pt-BR.json +31 -57
- package/resource/package.nls.ru.json +34 -60
- package/resource/package.nls.tr.json +31 -57
- package/resource/package.nls.zh-Hans.json +31 -57
- package/resource/package.nls.zh-Hant.json +30 -56
- package/resource/package.nls.zh-cn.json +232 -712
- package/resource/package.nls.zh-tw.json +230 -710
- package/resource/yaml-schema/v1.2/yaml.schema.json +1474 -0
- package/templates/fallback/common.zip +0 -0
- package/templates/fallback/csharp.zip +0 -0
- package/templates/fallback/js.zip +0 -0
- package/templates/fallback/ts.zip +0 -0
- package/templates/plugins/resource/aad/auth/V3/Tab/GetUserProfile.razor +1 -2
- package/templates/plugins/resource/aad/auth/bot/README.md +281 -263
- package/templates/plugins/resource/aad/auth/bot/js/sso/handleMessageExtensionQueryWithToken.js +13 -3
- package/templates/plugins/resource/aad/auth/bot/js/sso/profileSsoCommandHandler.js +14 -5
- package/templates/plugins/resource/aad/auth/bot/ts/sso/handleMessageExtensionQueryWithToken.ts +11 -3
- package/templates/plugins/resource/aad/auth/bot/ts/sso/profileSsoCommandHandler.ts +12 -3
- package/templates/plugins/resource/aad/auth/tab/csharp/GetUserProfile.razor +1 -2
- package/build/component/configManager/diagnostic.d.ts +0 -9
- package/build/component/configManager/diagnostic.d.ts.map +0 -1
- package/build/component/configManager/diagnostic.js +0 -47
- package/build/component/configManager/diagnostic.js.map +0 -1
- package/build/component/driver/middleware/updateProgress.d.ts +0 -6
- package/build/component/driver/middleware/updateProgress.d.ts.map +0 -1
- package/build/component/driver/middleware/updateProgress.js +0 -15
- package/build/component/driver/middleware/updateProgress.js.map +0 -1
- package/build/component/generator/officeAddin/question.d.ts +0 -10
- package/build/component/generator/officeAddin/question.d.ts.map +0 -1
- package/build/component/generator/officeAddin/question.js +0 -118
- package/build/component/generator/officeAddin/question.js.map +0 -1
- package/build/core/FxCoreImplementV3.d.ts +0 -43
- package/build/core/FxCoreImplementV3.d.ts.map +0 -1
- package/build/core/FxCoreImplementV3.js +0 -653
- package/build/core/FxCoreImplementV3.js.map +0 -1
- package/templates/plugins/resource/apim/README.md +0 -92
package/build/question/create.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
// Copyright (c) Microsoft Corporation.
|
|
3
|
+
// Licensed under the MIT license.
|
|
2
4
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.createProjectCliHelpNode = exports.createProjectQuestionNode = exports.
|
|
5
|
+
exports.createProjectCliHelpNode = exports.createSampleProjectQuestionNode = exports.createProjectQuestionNode = exports.capabilitySubTree = exports.apiOperationQuestion = exports.openAIPluginManifestLocationQuestion = exports.apiSpecLocationQuestion = exports.RuntimeOptions = exports.appNameQuestion = exports.AppNamePattern = exports.folderQuestion = exports.programmingLanguageQuestion = exports.ProgrammingLanguage = exports.getLanguageOptions = exports.officeAddinHostingQuestion = exports.getTemplate = exports.SPFxImportFolderQuestion = exports.SPFxVersionOptionIds = exports.SPFxWebpartNameQuestion = exports.SPFxPackageSelectQuestion = exports.NotificationTriggerOptions = exports.CapabilityOptions = exports.ProjectTypeOptions = exports.ScratchOptions = void 0;
|
|
4
6
|
const tslib_1 = require("tslib");
|
|
5
7
|
const teamsfx_api_1 = require("@microsoft/teamsfx-api");
|
|
6
8
|
const fs_extra_1 = tslib_1.__importDefault(require("fs-extra"));
|
|
@@ -8,7 +10,6 @@ const jsonschema = tslib_1.__importStar(require("jsonschema"));
|
|
|
8
10
|
const lodash_1 = require("lodash");
|
|
9
11
|
const os = tslib_1.__importStar(require("os"));
|
|
10
12
|
const path = tslib_1.__importStar(require("path"));
|
|
11
|
-
const semver_1 = tslib_1.__importDefault(require("semver"));
|
|
12
13
|
const constants_1 = require("../common/constants");
|
|
13
14
|
const featureFlags_1 = require("../common/featureFlags");
|
|
14
15
|
const localizeUtils_1 = require("../common/localizeUtils");
|
|
@@ -16,14 +17,17 @@ const samples_1 = require("../common/samples");
|
|
|
16
17
|
const utils_1 = require("../common/utils");
|
|
17
18
|
const developerPortalScaffoldUtils_1 = require("../component/developerPortalScaffoldUtils");
|
|
18
19
|
const utils_2 = require("../component/driver/teamsApp/utils/utils");
|
|
20
|
+
const helper_1 = require("../component/generator/copilotPlugin/helper");
|
|
19
21
|
const projectsJsonData_1 = tslib_1.__importDefault(require("../component/generator/officeAddin/config/projectsJsonData"));
|
|
20
22
|
const error_1 = require("../component/generator/spfx/error");
|
|
21
23
|
const spfxGenerator_1 = require("../component/generator/spfx/spfxGenerator");
|
|
22
24
|
const constants_2 = require("../component/generator/spfx/utils/constants");
|
|
23
25
|
const utils_3 = require("../component/generator/spfx/utils/utils");
|
|
26
|
+
const utils_4 = require("../component/utils");
|
|
27
|
+
const error_2 = require("../error");
|
|
24
28
|
const questionNames_1 = require("./questionNames");
|
|
25
|
-
const sleep_1 = require("../component/driver/deploy/spfx/utility/sleep");
|
|
26
29
|
const util_1 = require("./util");
|
|
30
|
+
const constants_3 = require("./constants");
|
|
27
31
|
class ScratchOptions {
|
|
28
32
|
static yes() {
|
|
29
33
|
return {
|
|
@@ -82,19 +86,6 @@ class ProjectTypeOptions {
|
|
|
82
86
|
}
|
|
83
87
|
}
|
|
84
88
|
exports.ProjectTypeOptions = ProjectTypeOptions;
|
|
85
|
-
function scratchOrSampleQuestion() {
|
|
86
|
-
const staticOptions = ScratchOptions.all();
|
|
87
|
-
return {
|
|
88
|
-
type: "singleSelect",
|
|
89
|
-
name: questionNames_1.QuestionNames.Scratch,
|
|
90
|
-
title: localizeUtils_1.getLocalizedString("core.getCreateNewOrFromSampleQuestion.title"),
|
|
91
|
-
staticOptions,
|
|
92
|
-
default: ScratchOptions.yes().id,
|
|
93
|
-
placeholder: localizeUtils_1.getLocalizedString("core.getCreateNewOrFromSampleQuestion.placeholder"),
|
|
94
|
-
skipSingleOption: true,
|
|
95
|
-
forgetLastValue: true,
|
|
96
|
-
};
|
|
97
|
-
}
|
|
98
89
|
function projectTypeQuestion() {
|
|
99
90
|
const staticOptions = [
|
|
100
91
|
ProjectTypeOptions.bot(),
|
|
@@ -126,7 +117,7 @@ function projectTypeQuestion() {
|
|
|
126
117
|
];
|
|
127
118
|
}
|
|
128
119
|
if (developerPortalScaffoldUtils_1.isFromDevPortal(inputs)) {
|
|
129
|
-
const projectType = (_a = developerPortalScaffoldUtils_1.
|
|
120
|
+
const projectType = (_a = developerPortalScaffoldUtils_1.getProjectTypeAndCapability(inputs.teamsAppFromTdp)) === null || _a === void 0 ? void 0 : _a.projectType;
|
|
130
121
|
if (projectType) {
|
|
131
122
|
return [projectType];
|
|
132
123
|
}
|
|
@@ -145,18 +136,16 @@ class CapabilityOptions {
|
|
|
145
136
|
// bot
|
|
146
137
|
static basicBot() {
|
|
147
138
|
return {
|
|
148
|
-
id: "
|
|
139
|
+
id: "bot",
|
|
149
140
|
label: `${localizeUtils_1.getLocalizedString("core.BotNewUIOption.label")}`,
|
|
150
|
-
cliName: "bot",
|
|
151
141
|
detail: localizeUtils_1.getLocalizedString("core.BotNewUIOption.detail"),
|
|
152
142
|
};
|
|
153
143
|
}
|
|
154
144
|
static notificationBot() {
|
|
155
145
|
return {
|
|
156
146
|
// For default option, id and cliName must be the same
|
|
157
|
-
id: "
|
|
147
|
+
id: "notification",
|
|
158
148
|
label: `${localizeUtils_1.getLocalizedString("core.NotificationOption.label")}`,
|
|
159
|
-
cliName: "notification",
|
|
160
149
|
detail: localizeUtils_1.getLocalizedString("core.NotificationOption.detail"),
|
|
161
150
|
data: "https://aka.ms/teamsfx-send-notification",
|
|
162
151
|
buttons: [
|
|
@@ -173,7 +162,6 @@ class CapabilityOptions {
|
|
|
173
162
|
// id must match cli `yargsHelp`
|
|
174
163
|
id: "command-bot",
|
|
175
164
|
label: `${localizeUtils_1.getLocalizedString("core.CommandAndResponseOption.label")}`,
|
|
176
|
-
cliName: "command-bot",
|
|
177
165
|
detail: localizeUtils_1.getLocalizedString("core.CommandAndResponseOption.detail"),
|
|
178
166
|
data: "https://aka.ms/teamsfx-create-command",
|
|
179
167
|
buttons: [
|
|
@@ -190,7 +178,6 @@ class CapabilityOptions {
|
|
|
190
178
|
// id must match cli `yargsHelp`
|
|
191
179
|
id: "workflow-bot",
|
|
192
180
|
label: `${localizeUtils_1.getLocalizedString("core.WorkflowOption.label")}`,
|
|
193
|
-
cliName: "workflow-bot",
|
|
194
181
|
detail: localizeUtils_1.getLocalizedString("core.WorkflowOption.detail"),
|
|
195
182
|
data: "https://aka.ms/teamsfx-create-workflow",
|
|
196
183
|
buttons: [
|
|
@@ -216,27 +203,24 @@ class CapabilityOptions {
|
|
|
216
203
|
//tab
|
|
217
204
|
static nonSsoTab() {
|
|
218
205
|
return {
|
|
219
|
-
id: "
|
|
206
|
+
id: "tab-non-sso",
|
|
220
207
|
label: `${localizeUtils_1.getLocalizedString("core.TabNonSso.label")}`,
|
|
221
|
-
cliName: "tab-non-sso",
|
|
222
208
|
detail: localizeUtils_1.getLocalizedString("core.TabNonSso.detail"),
|
|
223
209
|
description: localizeUtils_1.getLocalizedString("core.createProjectQuestion.option.description.worksInOutlookM365"),
|
|
224
210
|
};
|
|
225
211
|
}
|
|
226
212
|
static tab() {
|
|
227
213
|
return {
|
|
228
|
-
id: "
|
|
214
|
+
id: "tab",
|
|
229
215
|
label: localizeUtils_1.getLocalizedString("core.TabOption.label"),
|
|
230
|
-
cliName: "tab",
|
|
231
216
|
description: localizeUtils_1.getLocalizedString("core.TabOption.description"),
|
|
232
217
|
detail: localizeUtils_1.getLocalizedString("core.TabOption.detail"),
|
|
233
218
|
};
|
|
234
219
|
}
|
|
235
220
|
static m365SsoLaunchPage() {
|
|
236
221
|
return {
|
|
237
|
-
id: "
|
|
222
|
+
id: "sso-launch-page",
|
|
238
223
|
label: `${localizeUtils_1.getLocalizedString("core.M365SsoLaunchPageOptionItem.label")}`,
|
|
239
|
-
cliName: "sso-launch-page",
|
|
240
224
|
detail: localizeUtils_1.getLocalizedString("core.M365SsoLaunchPageOptionItem.detail"),
|
|
241
225
|
description: localizeUtils_1.getLocalizedString("core.createProjectQuestion.option.description.worksInOutlookM365"),
|
|
242
226
|
};
|
|
@@ -245,7 +229,6 @@ class CapabilityOptions {
|
|
|
245
229
|
return {
|
|
246
230
|
id: "dashboard-tab",
|
|
247
231
|
label: `${localizeUtils_1.getLocalizedString("core.DashboardOption.label")}`,
|
|
248
|
-
cliName: "dashboard-tab",
|
|
249
232
|
detail: localizeUtils_1.getLocalizedString("core.DashboardOption.detail"),
|
|
250
233
|
description: localizeUtils_1.getLocalizedString("core.createProjectQuestion.option.description.worksInOutlookM365"),
|
|
251
234
|
data: "https://aka.ms/teamsfx-dashboard-app",
|
|
@@ -260,9 +243,8 @@ class CapabilityOptions {
|
|
|
260
243
|
}
|
|
261
244
|
static SPFxTab() {
|
|
262
245
|
return {
|
|
263
|
-
id: "
|
|
246
|
+
id: "tab-spfx",
|
|
264
247
|
label: localizeUtils_1.getLocalizedString("core.TabSPFxOption.labelNew"),
|
|
265
|
-
cliName: "tab-spfx",
|
|
266
248
|
description: localizeUtils_1.getLocalizedString("core.createProjectQuestion.option.description.worksInOutlookM365"),
|
|
267
249
|
detail: localizeUtils_1.getLocalizedString("core.TabSPFxOption.detailNew"),
|
|
268
250
|
};
|
|
@@ -270,46 +252,58 @@ class CapabilityOptions {
|
|
|
270
252
|
//message extension
|
|
271
253
|
static linkUnfurling() {
|
|
272
254
|
return {
|
|
273
|
-
id: "
|
|
255
|
+
id: "link-unfurling",
|
|
274
256
|
label: `${localizeUtils_1.getLocalizedString("core.LinkUnfurlingOption.label")}`,
|
|
275
|
-
cliName: "link-unfurling",
|
|
276
257
|
detail: localizeUtils_1.getLocalizedString("core.LinkUnfurlingOption.detail"),
|
|
277
258
|
description: localizeUtils_1.getLocalizedString("core.createProjectQuestion.option.description.worksInOutlook"),
|
|
278
259
|
};
|
|
279
260
|
}
|
|
280
261
|
static m365SearchMe() {
|
|
281
262
|
return {
|
|
282
|
-
id: "
|
|
263
|
+
id: "search-app",
|
|
283
264
|
label: `${localizeUtils_1.getLocalizedString("core.M365SearchAppOptionItem.label")}`,
|
|
284
|
-
cliName: "search-app",
|
|
285
265
|
detail: localizeUtils_1.getLocalizedString("core.M365SearchAppOptionItem.detail"),
|
|
286
266
|
description: localizeUtils_1.getLocalizedString("core.createProjectQuestion.option.description.worksInOutlook"),
|
|
287
267
|
};
|
|
288
268
|
}
|
|
269
|
+
static SearchMe() {
|
|
270
|
+
return {
|
|
271
|
+
id: "search-message-extension",
|
|
272
|
+
label: `${localizeUtils_1.getLocalizedString("core.M365SearchAppOptionItem.label")}`,
|
|
273
|
+
detail: localizeUtils_1.getLocalizedString("core.SearchAppOptionItem.detail"),
|
|
274
|
+
};
|
|
275
|
+
}
|
|
289
276
|
static collectFormMe() {
|
|
290
277
|
return {
|
|
291
|
-
id: "
|
|
278
|
+
id: "collect-form-message-extension",
|
|
292
279
|
label: `${localizeUtils_1.getLocalizedString("core.MessageExtensionOption.labelNew")}`,
|
|
293
|
-
cliName: "message-extension",
|
|
294
280
|
detail: localizeUtils_1.getLocalizedString("core.MessageExtensionOption.detail"),
|
|
295
281
|
};
|
|
296
282
|
}
|
|
297
283
|
static me() {
|
|
298
284
|
return {
|
|
299
|
-
id: "
|
|
285
|
+
id: "message-extension",
|
|
300
286
|
label: localizeUtils_1.getLocalizedString("core.MessageExtensionOption.label"),
|
|
301
|
-
cliName: "message-extension",
|
|
302
287
|
description: localizeUtils_1.getLocalizedString("core.MessageExtensionOption.description"),
|
|
303
288
|
detail: localizeUtils_1.getLocalizedString("core.MessageExtensionOption.detail"),
|
|
304
289
|
};
|
|
305
290
|
}
|
|
306
291
|
static bots(inputs) {
|
|
307
|
-
return
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
292
|
+
return inputs !== undefined && getRuntime(inputs) === RuntimeOptions.DotNet().id
|
|
293
|
+
? // currently no ai bot for dotnet
|
|
294
|
+
[
|
|
295
|
+
CapabilityOptions.basicBot(),
|
|
296
|
+
CapabilityOptions.notificationBot(),
|
|
297
|
+
CapabilityOptions.commandBot(),
|
|
298
|
+
CapabilityOptions.workflowBot(inputs),
|
|
299
|
+
]
|
|
300
|
+
: [
|
|
301
|
+
CapabilityOptions.basicBot(),
|
|
302
|
+
CapabilityOptions.aiBot(),
|
|
303
|
+
CapabilityOptions.notificationBot(),
|
|
304
|
+
CapabilityOptions.commandBot(),
|
|
305
|
+
CapabilityOptions.workflowBot(inputs),
|
|
306
|
+
];
|
|
313
307
|
}
|
|
314
308
|
static tabs() {
|
|
315
309
|
return [
|
|
@@ -319,21 +313,27 @@ class CapabilityOptions {
|
|
|
319
313
|
CapabilityOptions.SPFxTab(),
|
|
320
314
|
];
|
|
321
315
|
}
|
|
322
|
-
static dotnetCaps() {
|
|
316
|
+
static dotnetCaps(inputs) {
|
|
323
317
|
return [
|
|
324
|
-
CapabilityOptions.
|
|
325
|
-
CapabilityOptions.
|
|
318
|
+
...CapabilityOptions.copilotPlugins(),
|
|
319
|
+
...CapabilityOptions.bots(inputs),
|
|
326
320
|
CapabilityOptions.nonSsoTab(),
|
|
327
321
|
CapabilityOptions.tab(),
|
|
328
|
-
CapabilityOptions.
|
|
322
|
+
...CapabilityOptions.mes(inputs),
|
|
329
323
|
];
|
|
330
324
|
}
|
|
331
|
-
static mes() {
|
|
332
|
-
return
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
325
|
+
static mes(inputs) {
|
|
326
|
+
return inputs !== undefined && getRuntime(inputs) === RuntimeOptions.DotNet().id
|
|
327
|
+
? [
|
|
328
|
+
CapabilityOptions.linkUnfurling(),
|
|
329
|
+
CapabilityOptions.SearchMe(),
|
|
330
|
+
CapabilityOptions.collectFormMe(),
|
|
331
|
+
]
|
|
332
|
+
: [
|
|
333
|
+
CapabilityOptions.linkUnfurling(),
|
|
334
|
+
CapabilityOptions.m365SearchMe(),
|
|
335
|
+
CapabilityOptions.collectFormMe(),
|
|
336
|
+
];
|
|
337
337
|
}
|
|
338
338
|
static copilotPlugins() {
|
|
339
339
|
return [
|
|
@@ -342,22 +342,38 @@ class CapabilityOptions {
|
|
|
342
342
|
CapabilityOptions.copilotPluginOpenAIPlugin(),
|
|
343
343
|
];
|
|
344
344
|
}
|
|
345
|
+
static copilotPluginCli() {
|
|
346
|
+
return {
|
|
347
|
+
id: "copilot-plugin-capability",
|
|
348
|
+
label: `${localizeUtils_1.getLocalizedString("core.createProjectQuestion.projectType.copilotPlugin.label")}`,
|
|
349
|
+
detail: localizeUtils_1.getLocalizedString("core.createProjectQuestion.projectType.copilotPlugin.detail"),
|
|
350
|
+
};
|
|
351
|
+
}
|
|
352
|
+
static staticAll(inputs) {
|
|
353
|
+
const capabilityOptions = [
|
|
354
|
+
...CapabilityOptions.bots(inputs),
|
|
355
|
+
...CapabilityOptions.tabs(),
|
|
356
|
+
...CapabilityOptions.mes(),
|
|
357
|
+
CapabilityOptions.copilotPluginCli(),
|
|
358
|
+
];
|
|
359
|
+
return capabilityOptions;
|
|
360
|
+
}
|
|
345
361
|
static all(inputs) {
|
|
362
|
+
// teamsfx list capabilities
|
|
346
363
|
const capabilityOptions = [
|
|
347
364
|
...CapabilityOptions.bots(inputs),
|
|
348
365
|
...CapabilityOptions.tabs(),
|
|
349
366
|
...CapabilityOptions.mes(),
|
|
350
367
|
];
|
|
351
368
|
if (featureFlags_1.isCopilotPluginEnabled()) {
|
|
352
|
-
capabilityOptions.push(
|
|
369
|
+
capabilityOptions.push(CapabilityOptions.copilotPluginCli());
|
|
353
370
|
}
|
|
354
371
|
return capabilityOptions;
|
|
355
372
|
}
|
|
356
373
|
static officeAddinImport() {
|
|
357
374
|
return {
|
|
358
|
-
id: "import
|
|
375
|
+
id: "import",
|
|
359
376
|
label: localizeUtils_1.getLocalizedString("core.importAddin.label"),
|
|
360
|
-
cliName: "import",
|
|
361
377
|
detail: localizeUtils_1.getLocalizedString("core.importAddin.detail"),
|
|
362
378
|
description: localizeUtils_1.getLocalizedString("core.createProjectQuestion.option.description.previewOnWindow"),
|
|
363
379
|
};
|
|
@@ -385,25 +401,32 @@ class CapabilityOptions {
|
|
|
385
401
|
// copilot plugin
|
|
386
402
|
static copilotPluginNewApi() {
|
|
387
403
|
return {
|
|
388
|
-
id: "copilot-new-api",
|
|
404
|
+
id: "copilot-plugin-new-api",
|
|
389
405
|
label: localizeUtils_1.getLocalizedString("core.createProjectQuestion.capability.copilotPluginNewApiOption.label"),
|
|
390
406
|
detail: localizeUtils_1.getLocalizedString("core.createProjectQuestion.capability.copilotPluginNewApiOption.detail"),
|
|
391
407
|
};
|
|
392
408
|
}
|
|
393
409
|
static copilotPluginApiSpec() {
|
|
394
410
|
return {
|
|
395
|
-
id:
|
|
411
|
+
id: constants_3.copilotPluginApiSpecOptionId,
|
|
396
412
|
label: localizeUtils_1.getLocalizedString("core.createProjectQuestion.capability.copilotPluginApiSpecOption.label"),
|
|
397
413
|
detail: localizeUtils_1.getLocalizedString("core.createProjectQuestion.capability.copilotPluginApiSpecOption.detail"),
|
|
398
414
|
};
|
|
399
415
|
}
|
|
400
416
|
static copilotPluginOpenAIPlugin() {
|
|
401
417
|
return {
|
|
402
|
-
id:
|
|
418
|
+
id: constants_3.copilotPluginOpenAIPluginOptionId,
|
|
403
419
|
label: localizeUtils_1.getLocalizedString("core.createProjectQuestion.capability.copilotPluginAIPluginOption.label"),
|
|
404
420
|
detail: localizeUtils_1.getLocalizedString("core.createProjectQuestion.capability.copilotPluginAIPluginOption.detail"),
|
|
405
421
|
};
|
|
406
422
|
}
|
|
423
|
+
static aiBot() {
|
|
424
|
+
return {
|
|
425
|
+
id: "ai-bot",
|
|
426
|
+
label: localizeUtils_1.getLocalizedString("core.aiBotOption.label"),
|
|
427
|
+
detail: localizeUtils_1.getLocalizedString("core.aiBotOption.detail"),
|
|
428
|
+
};
|
|
429
|
+
}
|
|
407
430
|
}
|
|
408
431
|
exports.CapabilityOptions = CapabilityOptions;
|
|
409
432
|
function capabilityQuestion() {
|
|
@@ -426,20 +449,24 @@ function capabilityQuestion() {
|
|
|
426
449
|
return localizeUtils_1.getLocalizedString("core.createCapabilityQuestion.titleNew");
|
|
427
450
|
}
|
|
428
451
|
},
|
|
452
|
+
cliDescription: "Specifies the Teams App capability.",
|
|
453
|
+
cliName: questionNames_1.CliQuestionName.Capability,
|
|
454
|
+
cliShortName: "c",
|
|
455
|
+
cliChoiceListCommand: "teamsfx list capabilities",
|
|
429
456
|
type: "singleSelect",
|
|
430
|
-
staticOptions: CapabilityOptions.
|
|
457
|
+
staticOptions: CapabilityOptions.staticAll(),
|
|
431
458
|
dynamicOptions: (inputs) => {
|
|
432
459
|
var _a;
|
|
433
460
|
// from dev portal
|
|
434
461
|
if (developerPortalScaffoldUtils_1.isFromDevPortal(inputs)) {
|
|
435
|
-
const capability = (_a = developerPortalScaffoldUtils_1.
|
|
462
|
+
const capability = (_a = developerPortalScaffoldUtils_1.getProjectTypeAndCapability(inputs.teamsAppFromTdp)) === null || _a === void 0 ? void 0 : _a.templateId;
|
|
436
463
|
if (capability) {
|
|
437
464
|
return [capability];
|
|
438
465
|
}
|
|
439
466
|
}
|
|
440
467
|
// dotnet capabilities
|
|
441
468
|
if (getRuntime(inputs) === RuntimeOptions.DotNet().id) {
|
|
442
|
-
return CapabilityOptions.dotnetCaps();
|
|
469
|
+
return CapabilityOptions.dotnetCaps(inputs);
|
|
443
470
|
}
|
|
444
471
|
// nodejs capabilities
|
|
445
472
|
const projectType = inputs[questionNames_1.QuestionNames.ProjectType];
|
|
@@ -465,7 +492,7 @@ function capabilityQuestion() {
|
|
|
465
492
|
...CapabilityOptions.mes(),
|
|
466
493
|
];
|
|
467
494
|
if (featureFlags_1.isCopilotPluginEnabled()) {
|
|
468
|
-
capabilityOptions.push(
|
|
495
|
+
capabilityOptions.push(CapabilityOptions.copilotPluginCli());
|
|
469
496
|
}
|
|
470
497
|
return capabilityOptions;
|
|
471
498
|
}
|
|
@@ -495,7 +522,6 @@ class NotificationTriggerOptions {
|
|
|
495
522
|
id: "http-restify",
|
|
496
523
|
hostType: HostType.AppService,
|
|
497
524
|
label: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-restify.label"),
|
|
498
|
-
cliName: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-restify.cliName"),
|
|
499
525
|
description: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-restify.description"),
|
|
500
526
|
detail: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-restify.detail"),
|
|
501
527
|
};
|
|
@@ -505,7 +531,6 @@ class NotificationTriggerOptions {
|
|
|
505
531
|
id: "http-webapi",
|
|
506
532
|
hostType: HostType.AppService,
|
|
507
533
|
label: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-webapi.label"),
|
|
508
|
-
cliName: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-webapi.cliName"),
|
|
509
534
|
description: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-webapi.description"),
|
|
510
535
|
detail: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-webapi.detail"),
|
|
511
536
|
};
|
|
@@ -517,7 +542,6 @@ class NotificationTriggerOptions {
|
|
|
517
542
|
hostType: HostType.Functions,
|
|
518
543
|
triggers: [NotificationTriggers.TIMER],
|
|
519
544
|
label: localizeUtils_1.getLocalizedString("plugins.bot.triggers.timer-functions.label"),
|
|
520
|
-
cliName: localizeUtils_1.getLocalizedString("plugins.bot.triggers.timer-functions.cliName"),
|
|
521
545
|
description: localizeUtils_1.getLocalizedString("plugins.bot.triggers.timer-functions.description"),
|
|
522
546
|
detail: localizeUtils_1.getLocalizedString("plugins.bot.triggers.timer-functions.detail"),
|
|
523
547
|
};
|
|
@@ -528,7 +552,6 @@ class NotificationTriggerOptions {
|
|
|
528
552
|
hostType: HostType.Functions,
|
|
529
553
|
triggers: [NotificationTriggers.HTTP, NotificationTriggers.TIMER],
|
|
530
554
|
label: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-and-timer-functions.label"),
|
|
531
|
-
cliName: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-and-timer-functions.cliName"),
|
|
532
555
|
description: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-and-timer-functions.description"),
|
|
533
556
|
detail: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-and-timer-functions.detail"),
|
|
534
557
|
};
|
|
@@ -539,7 +562,6 @@ class NotificationTriggerOptions {
|
|
|
539
562
|
hostType: HostType.Functions,
|
|
540
563
|
triggers: [NotificationTriggers.HTTP],
|
|
541
564
|
label: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-functions.label"),
|
|
542
|
-
cliName: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-functions.cliName"),
|
|
543
565
|
description: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-functions.description"),
|
|
544
566
|
detail: localizeUtils_1.getLocalizedString("plugins.bot.triggers.http-functions.detail"),
|
|
545
567
|
};
|
|
@@ -578,6 +600,8 @@ function botTriggerQuestion() {
|
|
|
578
600
|
return {
|
|
579
601
|
name: questionNames_1.QuestionNames.BotTrigger,
|
|
580
602
|
title: localizeUtils_1.getLocalizedString("plugins.bot.questionHostTypeTrigger.title"),
|
|
603
|
+
cliDescription: "Specifies the trigger for `Chat Notification Message` app template.",
|
|
604
|
+
cliShortName: "t",
|
|
581
605
|
type: "singleSelect",
|
|
582
606
|
staticOptions: NotificationTriggerOptions.all(),
|
|
583
607
|
dynamicOptions: (inputs) => {
|
|
@@ -598,16 +622,33 @@ function botTriggerQuestion() {
|
|
|
598
622
|
placeholder: localizeUtils_1.getLocalizedString("plugins.bot.questionHostTypeTrigger.placeholder"),
|
|
599
623
|
};
|
|
600
624
|
}
|
|
625
|
+
function copilotPluginDevelopmentQuestion() {
|
|
626
|
+
return {
|
|
627
|
+
name: questionNames_1.QuestionNames.CopilotPluginDevelopment,
|
|
628
|
+
title: localizeUtils_1.getLocalizedString("core.createProjectQuestion.projectType.copilotPlugin.title"),
|
|
629
|
+
type: "singleSelect",
|
|
630
|
+
staticOptions: CapabilityOptions.copilotPlugins(),
|
|
631
|
+
cliShortName: "cp",
|
|
632
|
+
cliDescription: "Plugin for Copilot.",
|
|
633
|
+
};
|
|
634
|
+
}
|
|
601
635
|
function SPFxSolutionQuestion() {
|
|
602
636
|
return {
|
|
603
637
|
type: "singleSelect",
|
|
604
638
|
name: questionNames_1.QuestionNames.SPFxSolution,
|
|
605
639
|
title: localizeUtils_1.getLocalizedString("plugins.spfx.questions.spfxSolution.title"),
|
|
640
|
+
cliDescription: "Create a new or import an existing SharePoint Framework solution.",
|
|
641
|
+
cliShortName: "ss",
|
|
606
642
|
staticOptions: [
|
|
607
|
-
{
|
|
643
|
+
{
|
|
644
|
+
id: "new",
|
|
645
|
+
label: localizeUtils_1.getLocalizedString("plugins.spfx.questions.spfxSolution.createNew"),
|
|
646
|
+
detail: localizeUtils_1.getLocalizedString("plugins.spfx.questions.spfxSolution.createNew.detail"),
|
|
647
|
+
},
|
|
608
648
|
{
|
|
609
649
|
id: "import",
|
|
610
650
|
label: localizeUtils_1.getLocalizedString("plugins.spfx.questions.spfxSolution.importExisting"),
|
|
651
|
+
detail: localizeUtils_1.getLocalizedString("plugins.spfx.questions.spfxSolution.importExisting.detail"),
|
|
611
652
|
},
|
|
612
653
|
],
|
|
613
654
|
default: "new",
|
|
@@ -618,24 +659,50 @@ function SPFxPackageSelectQuestion() {
|
|
|
618
659
|
type: "singleSelect",
|
|
619
660
|
name: questionNames_1.QuestionNames.SPFxInstallPackage,
|
|
620
661
|
title: localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.title"),
|
|
662
|
+
cliDescription: "Install the latest version of SharePoint Framework.",
|
|
621
663
|
staticOptions: [],
|
|
622
664
|
placeholder: localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.placeholder"),
|
|
623
665
|
dynamicOptions: async (inputs) => {
|
|
624
|
-
await
|
|
625
|
-
|
|
666
|
+
const versions = await Promise.all([
|
|
667
|
+
utils_3.Utils.findGloballyInstalledVersion(undefined, constants_2.Constants.GeneratorPackageName, 0, false),
|
|
668
|
+
utils_3.Utils.findLatestVersion(undefined, constants_2.Constants.GeneratorPackageName, 5),
|
|
669
|
+
utils_3.Utils.findGloballyInstalledVersion(undefined, constants_2.Constants.YeomanPackageName, 0, false),
|
|
670
|
+
]);
|
|
671
|
+
inputs.globalSpfxPackageVersion = versions[0];
|
|
672
|
+
inputs.latestSpfxPackageVersion = versions[1];
|
|
673
|
+
inputs.globalYeomanPackageVersion = versions[2];
|
|
674
|
+
return [
|
|
675
|
+
{
|
|
676
|
+
id: SPFxVersionOptionIds.installLocally,
|
|
677
|
+
label: versions[1] !== undefined
|
|
678
|
+
? localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.installLocally.withVersion.label", "v" + versions[1])
|
|
679
|
+
: localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.installLocally.noVersion.label"),
|
|
680
|
+
},
|
|
681
|
+
{
|
|
682
|
+
id: SPFxVersionOptionIds.globalPackage,
|
|
683
|
+
label: versions[0] !== undefined
|
|
684
|
+
? localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.useGlobalPackage.withVersion.label", "v" + versions[0])
|
|
685
|
+
: localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.useGlobalPackage.noVersion.label"),
|
|
686
|
+
description: localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.useGlobalPackage.detail", constants_2.Constants.RecommendedLowestSpfxVersion),
|
|
687
|
+
},
|
|
688
|
+
];
|
|
626
689
|
},
|
|
627
690
|
default: SPFxVersionOptionIds.installLocally,
|
|
628
691
|
validation: {
|
|
629
|
-
validFunc:
|
|
692
|
+
validFunc: (input, previousInputs) => {
|
|
630
693
|
if (input === SPFxVersionOptionIds.globalPackage) {
|
|
631
|
-
const hasPackagesInstalled =
|
|
694
|
+
const hasPackagesInstalled = !!previousInputs &&
|
|
695
|
+
!!previousInputs.globalSpfxPackageVersion &&
|
|
696
|
+
!!previousInputs.globalYeomanPackageVersion;
|
|
632
697
|
if (!hasPackagesInstalled) {
|
|
633
|
-
|
|
698
|
+
return Promise.reject(error_1.DevEnvironmentSetupError());
|
|
634
699
|
}
|
|
635
700
|
}
|
|
636
|
-
return undefined;
|
|
701
|
+
return Promise.resolve(undefined);
|
|
637
702
|
},
|
|
638
703
|
},
|
|
704
|
+
cliShortName: "sp",
|
|
705
|
+
isBoolean: true,
|
|
639
706
|
};
|
|
640
707
|
}
|
|
641
708
|
exports.SPFxPackageSelectQuestion = SPFxPackageSelectQuestion;
|
|
@@ -643,6 +710,7 @@ function SPFxFrameworkQuestion() {
|
|
|
643
710
|
return {
|
|
644
711
|
type: "singleSelect",
|
|
645
712
|
name: questionNames_1.QuestionNames.SPFxFramework,
|
|
713
|
+
cliShortName: "sfk",
|
|
646
714
|
title: localizeUtils_1.getLocalizedString("plugins.spfx.questions.framework.title"),
|
|
647
715
|
staticOptions: [
|
|
648
716
|
{ id: "react", label: "React" },
|
|
@@ -657,7 +725,8 @@ function SPFxWebpartNameQuestion() {
|
|
|
657
725
|
return {
|
|
658
726
|
type: "text",
|
|
659
727
|
name: questionNames_1.QuestionNames.SPFxWebpartName,
|
|
660
|
-
|
|
728
|
+
cliShortName: "sw",
|
|
729
|
+
title: "Name for SharePoint Framework Web Part.",
|
|
661
730
|
default: constants_2.Constants.DEFAULT_WEBPART_NAME,
|
|
662
731
|
validation: {
|
|
663
732
|
validFunc: async (input, previousInputs) => {
|
|
@@ -688,65 +757,13 @@ var SPFxVersionOptionIds;
|
|
|
688
757
|
SPFxVersionOptionIds["installLocally"] = "true";
|
|
689
758
|
SPFxVersionOptionIds["globalPackage"] = "false";
|
|
690
759
|
})(SPFxVersionOptionIds = exports.SPFxVersionOptionIds || (exports.SPFxVersionOptionIds = {}));
|
|
691
|
-
class PackageSelectOptionsHelper {
|
|
692
|
-
static async loadOptions() {
|
|
693
|
-
const versions = await Promise.all([
|
|
694
|
-
utils_3.Utils.findGloballyInstalledVersion(undefined, constants_2.Constants.GeneratorPackageName, 0, false),
|
|
695
|
-
utils_3.Utils.findLatestVersion(undefined, constants_2.Constants.GeneratorPackageName, 5),
|
|
696
|
-
utils_3.Utils.findGloballyInstalledVersion(undefined, constants_2.Constants.YeomanPackageName, 0, false),
|
|
697
|
-
]);
|
|
698
|
-
PackageSelectOptionsHelper.globalPackageVersions[0] = versions[0];
|
|
699
|
-
PackageSelectOptionsHelper.globalPackageVersions[1] = versions[2];
|
|
700
|
-
PackageSelectOptionsHelper.latestSpGeneratorVersion = versions[1];
|
|
701
|
-
PackageSelectOptionsHelper.options = [
|
|
702
|
-
{
|
|
703
|
-
id: SPFxVersionOptionIds.installLocally,
|
|
704
|
-
label: versions[1] !== undefined
|
|
705
|
-
? localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.installLocally.withVersion.label", "v" + versions[1])
|
|
706
|
-
: localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.installLocally.noVersion.label"),
|
|
707
|
-
},
|
|
708
|
-
{
|
|
709
|
-
id: SPFxVersionOptionIds.globalPackage,
|
|
710
|
-
label: versions[0] !== undefined
|
|
711
|
-
? localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.useGlobalPackage.withVersion.label", "v" + versions[0])
|
|
712
|
-
: localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.useGlobalPackage.noVersion.label"),
|
|
713
|
-
description: localizeUtils_1.getLocalizedString("plugins.spfx.questions.packageSelect.useGlobalPackage.detail", constants_2.Constants.RecommendedLowestSpfxVersion),
|
|
714
|
-
},
|
|
715
|
-
];
|
|
716
|
-
}
|
|
717
|
-
static getOptions() {
|
|
718
|
-
return PackageSelectOptionsHelper.options;
|
|
719
|
-
}
|
|
720
|
-
static clear() {
|
|
721
|
-
PackageSelectOptionsHelper.options = [];
|
|
722
|
-
PackageSelectOptionsHelper.globalPackageVersions = [undefined, undefined];
|
|
723
|
-
PackageSelectOptionsHelper.latestSpGeneratorVersion = undefined;
|
|
724
|
-
}
|
|
725
|
-
static checkGlobalPackages() {
|
|
726
|
-
return (!!PackageSelectOptionsHelper.globalPackageVersions[0] &&
|
|
727
|
-
!!PackageSelectOptionsHelper.globalPackageVersions[1]);
|
|
728
|
-
}
|
|
729
|
-
static getLatestSpGeneratorVersion() {
|
|
730
|
-
return PackageSelectOptionsHelper.latestSpGeneratorVersion;
|
|
731
|
-
}
|
|
732
|
-
static isLowerThanRecommendedVersion() {
|
|
733
|
-
const installedVersion = PackageSelectOptionsHelper.globalPackageVersions[0];
|
|
734
|
-
if (!installedVersion) {
|
|
735
|
-
return undefined;
|
|
736
|
-
}
|
|
737
|
-
const recommendedLowestVersion = constants_2.Constants.RecommendedLowestSpfxVersion.substring(1); // remove "v"
|
|
738
|
-
return semver_1.default.lte(installedVersion, recommendedLowestVersion);
|
|
739
|
-
}
|
|
740
|
-
}
|
|
741
|
-
exports.PackageSelectOptionsHelper = PackageSelectOptionsHelper;
|
|
742
|
-
PackageSelectOptionsHelper.options = [];
|
|
743
|
-
PackageSelectOptionsHelper.globalPackageVersions = [undefined, undefined];
|
|
744
|
-
PackageSelectOptionsHelper.latestSpGeneratorVersion = undefined;
|
|
745
760
|
function SPFxImportFolderQuestion(hasDefaultFunc = false) {
|
|
746
761
|
return {
|
|
747
762
|
type: "folder",
|
|
748
763
|
name: questionNames_1.QuestionNames.SPFxFolder,
|
|
764
|
+
cliShortName: "sf",
|
|
749
765
|
title: localizeUtils_1.getLocalizedString("core.spfxFolder.title"),
|
|
766
|
+
cliDescription: "Directory or Path that contains the existing SharePoint Framework solution.",
|
|
750
767
|
placeholder: localizeUtils_1.getLocalizedString("core.spfxFolder.placeholder"),
|
|
751
768
|
default: hasDefaultFunc
|
|
752
769
|
? (inputs) => {
|
|
@@ -762,7 +779,7 @@ const getTemplate = (inputs) => {
|
|
|
762
779
|
const capabilities = inputs[questionNames_1.QuestionNames.Capabilities];
|
|
763
780
|
const templates = officeAddinJsonData.getProjectTemplateNames();
|
|
764
781
|
const foundTemplate = templates.find((template) => {
|
|
765
|
-
return capabilities.includes(template);
|
|
782
|
+
return capabilities && capabilities.includes(template);
|
|
766
783
|
});
|
|
767
784
|
return foundTemplate !== null && foundTemplate !== void 0 ? foundTemplate : "";
|
|
768
785
|
};
|
|
@@ -773,7 +790,7 @@ function officeAddinHostingQuestion() {
|
|
|
773
790
|
name: questionNames_1.QuestionNames.OfficeAddinHost,
|
|
774
791
|
title: "Add-in Host",
|
|
775
792
|
staticOptions: [],
|
|
776
|
-
dynamicOptions:
|
|
793
|
+
dynamicOptions: (inputs) => {
|
|
777
794
|
const template = exports.getTemplate(inputs);
|
|
778
795
|
const getHostTemplateNames = officeAddinJsonData.getHostTemplateNames(template);
|
|
779
796
|
const options = getHostTemplateNames.map((host) => ({
|
|
@@ -782,7 +799,7 @@ function officeAddinHostingQuestion() {
|
|
|
782
799
|
}));
|
|
783
800
|
return options.length > 0 ? options : [{ label: "No Options", id: "No Options" }];
|
|
784
801
|
},
|
|
785
|
-
default:
|
|
802
|
+
default: (inputs) => {
|
|
786
803
|
const template = exports.getTemplate(inputs);
|
|
787
804
|
const options = officeAddinJsonData.getHostTemplateNames(template);
|
|
788
805
|
return options[0] || "No Options";
|
|
@@ -791,6 +808,7 @@ function officeAddinHostingQuestion() {
|
|
|
791
808
|
};
|
|
792
809
|
return OfficeHostQuestion;
|
|
793
810
|
}
|
|
811
|
+
exports.officeAddinHostingQuestion = officeAddinHostingQuestion;
|
|
794
812
|
const officeAddinJsonData = new projectsJsonData_1.default();
|
|
795
813
|
function getLanguageOptions(inputs) {
|
|
796
814
|
const runtime = getRuntime(inputs);
|
|
@@ -827,7 +845,8 @@ var ProgrammingLanguage;
|
|
|
827
845
|
function programmingLanguageQuestion() {
|
|
828
846
|
const programmingLanguageQuestion = {
|
|
829
847
|
name: questionNames_1.QuestionNames.ProgrammingLanguage,
|
|
830
|
-
|
|
848
|
+
cliShortName: "l",
|
|
849
|
+
title: "Programming Language.",
|
|
831
850
|
type: "singleSelect",
|
|
832
851
|
staticOptions: [
|
|
833
852
|
{ id: ProgrammingLanguage.JS, label: "JavaScript" },
|
|
@@ -864,26 +883,42 @@ function programmingLanguageQuestion() {
|
|
|
864
883
|
return programmingLanguageQuestion;
|
|
865
884
|
}
|
|
866
885
|
exports.programmingLanguageQuestion = programmingLanguageQuestion;
|
|
867
|
-
function
|
|
886
|
+
function folderQuestion() {
|
|
868
887
|
return {
|
|
869
888
|
type: "folder",
|
|
870
889
|
name: questionNames_1.QuestionNames.Folder,
|
|
871
|
-
|
|
890
|
+
cliShortName: "f",
|
|
891
|
+
title: (inputs) => teamsfx_api_1.CLIPlatforms.includes(inputs.platform)
|
|
892
|
+
? "Directory where the project folder will be created in"
|
|
893
|
+
: localizeUtils_1.getLocalizedString("core.question.workspaceFolder.title"),
|
|
894
|
+
cliDescription: "Directory where the project folder will be created in.",
|
|
872
895
|
placeholder: localizeUtils_1.getLocalizedString("core.question.workspaceFolder.placeholder"),
|
|
873
|
-
default:
|
|
896
|
+
default: (inputs) => teamsfx_api_1.CLIPlatforms.includes(inputs.platform)
|
|
897
|
+
? "./"
|
|
898
|
+
: path.join(os.homedir(), constants_1.ConstantString.RootFolder),
|
|
874
899
|
};
|
|
875
900
|
}
|
|
901
|
+
exports.folderQuestion = folderQuestion;
|
|
876
902
|
exports.AppNamePattern = '^(?=(.*[\\da-zA-Z]){2})[a-zA-Z][^"<>:\\?/*&|\u0000-\u001F]*[^"\\s.<>:\\?/*&|\u0000-\u001F]$';
|
|
877
903
|
function appNameQuestion() {
|
|
878
904
|
const question = {
|
|
879
905
|
type: "text",
|
|
880
906
|
name: questionNames_1.QuestionNames.AppName,
|
|
907
|
+
cliShortName: "n",
|
|
881
908
|
title: "Application name",
|
|
882
|
-
|
|
909
|
+
required: true,
|
|
910
|
+
default: async (inputs) => {
|
|
883
911
|
var _a, _b;
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
912
|
+
let defaultName = undefined;
|
|
913
|
+
if ((_a = inputs.teamsAppFromTdp) === null || _a === void 0 ? void 0 : _a.appName) {
|
|
914
|
+
defaultName = utils_1.convertToAlphanumericOnly((_b = inputs.teamsAppFromTdp) === null || _b === void 0 ? void 0 : _b.appName);
|
|
915
|
+
}
|
|
916
|
+
else if (inputs[questionNames_1.QuestionNames.SPFxSolution] == "import") {
|
|
917
|
+
defaultName = await spfxGenerator_1.SPFxGenerator.getSolutionName(inputs[questionNames_1.QuestionNames.SPFxFolder]);
|
|
918
|
+
}
|
|
919
|
+
else if (inputs.openAIPluginManifest) {
|
|
920
|
+
defaultName = inputs.openAIPluginManifest.name_for_human;
|
|
921
|
+
}
|
|
887
922
|
return defaultName;
|
|
888
923
|
},
|
|
889
924
|
validation: {
|
|
@@ -919,32 +954,15 @@ function appNameQuestion() {
|
|
|
919
954
|
return question;
|
|
920
955
|
}
|
|
921
956
|
exports.appNameQuestion = appNameQuestion;
|
|
922
|
-
function fillInAppNameFuncQuestion() {
|
|
923
|
-
const q = {
|
|
924
|
-
type: "func",
|
|
925
|
-
name: questionNames_1.QuestionNames.SkipAppName,
|
|
926
|
-
title: "Set app name to skip",
|
|
927
|
-
func: async (inputs) => {
|
|
928
|
-
if (inputs[questionNames_1.QuestionNames.SPFxSolution] == "import") {
|
|
929
|
-
const solutionName = await spfxGenerator_1.SPFxGenerator.getSolutionName(inputs[questionNames_1.QuestionNames.SPFxFolder]);
|
|
930
|
-
if (solutionName) {
|
|
931
|
-
inputs[questionNames_1.QuestionNames.AppName] = solutionName;
|
|
932
|
-
if (await fs_extra_1.default.pathExists(path.join(inputs.folder, solutionName)))
|
|
933
|
-
throw error_1.PathAlreadyExistsError(path.join(inputs.folder, solutionName));
|
|
934
|
-
}
|
|
935
|
-
else {
|
|
936
|
-
throw error_1.RetrieveSPFxInfoError();
|
|
937
|
-
}
|
|
938
|
-
}
|
|
939
|
-
},
|
|
940
|
-
};
|
|
941
|
-
return q;
|
|
942
|
-
}
|
|
943
|
-
exports.fillInAppNameFuncQuestion = fillInAppNameFuncQuestion;
|
|
944
957
|
function sampleSelectQuestion() {
|
|
945
958
|
return {
|
|
946
959
|
type: "singleSelect",
|
|
947
960
|
name: questionNames_1.QuestionNames.Samples,
|
|
961
|
+
cliName: "sample-name",
|
|
962
|
+
cliDescription: "Specifies the Teams App sample name.",
|
|
963
|
+
cliChoiceListCommand: "teamsfx list samples",
|
|
964
|
+
skipValidation: true,
|
|
965
|
+
cliType: "argument",
|
|
948
966
|
title: localizeUtils_1.getLocalizedString("core.SampleSelect.title"),
|
|
949
967
|
staticOptions: samples_1.sampleProvider.SampleCollection.samples.map((sample) => {
|
|
950
968
|
return {
|
|
@@ -952,9 +970,19 @@ function sampleSelectQuestion() {
|
|
|
952
970
|
label: sample.title,
|
|
953
971
|
description: `${sample.time} • ${sample.configuration}`,
|
|
954
972
|
detail: sample.shortDescription,
|
|
955
|
-
data: sample.link,
|
|
956
973
|
};
|
|
957
974
|
}),
|
|
975
|
+
dynamicOptions: async () => {
|
|
976
|
+
await samples_1.sampleProvider.fetchSampleConfig();
|
|
977
|
+
return samples_1.sampleProvider.SampleCollection.samples.map((sample) => {
|
|
978
|
+
return {
|
|
979
|
+
id: sample.id,
|
|
980
|
+
label: sample.title,
|
|
981
|
+
description: `${sample.time} • ${sample.configuration}`,
|
|
982
|
+
detail: sample.shortDescription,
|
|
983
|
+
};
|
|
984
|
+
});
|
|
985
|
+
},
|
|
958
986
|
placeholder: localizeUtils_1.getLocalizedString("core.SampleSelect.placeholder"),
|
|
959
987
|
buttons: [
|
|
960
988
|
{
|
|
@@ -990,6 +1018,7 @@ function runtimeQuestion() {
|
|
|
990
1018
|
staticOptions: [RuntimeOptions.NodeJS(), RuntimeOptions.DotNet()],
|
|
991
1019
|
default: RuntimeOptions.NodeJS().id,
|
|
992
1020
|
placeholder: localizeUtils_1.getLocalizedString("core.getRuntimeQuestion.placeholder"),
|
|
1021
|
+
cliHidden: true,
|
|
993
1022
|
};
|
|
994
1023
|
}
|
|
995
1024
|
const defaultTabLocalHostUrl = "https://localhost:53000/index.html#/tab";
|
|
@@ -1081,6 +1110,8 @@ function getBotIdAndMeId(appDefinition) {
|
|
|
1081
1110
|
}
|
|
1082
1111
|
function getBotOptions(inputs) {
|
|
1083
1112
|
const appDefinition = inputs.teamsAppFromTdp;
|
|
1113
|
+
if (!appDefinition)
|
|
1114
|
+
return [];
|
|
1084
1115
|
const [botId, messageExtensionId] = getBotIdAndMeId(appDefinition);
|
|
1085
1116
|
const options = [];
|
|
1086
1117
|
if (botId) {
|
|
@@ -1092,14 +1123,14 @@ function getBotOptions(inputs) {
|
|
|
1092
1123
|
return options;
|
|
1093
1124
|
}
|
|
1094
1125
|
function selectBotIdsQuestion() {
|
|
1095
|
-
const statcOptions = [];
|
|
1096
|
-
statcOptions.push(botOptionItem(false, "000000-0000-0000"));
|
|
1097
|
-
statcOptions.push(botOptionItem(true, "000000-0000-0000"));
|
|
1126
|
+
// const statcOptions: OptionItem[] = [];
|
|
1127
|
+
// statcOptions.push(botOptionItem(false, "000000-0000-0000"));
|
|
1128
|
+
// statcOptions.push(botOptionItem(true, "000000-0000-0000"));
|
|
1098
1129
|
return {
|
|
1099
1130
|
type: "multiSelect",
|
|
1100
1131
|
name: questionNames_1.QuestionNames.ReplaceBotIds,
|
|
1101
1132
|
title: localizeUtils_1.getLocalizedString("core.updateBotIdsQuestion.title"),
|
|
1102
|
-
staticOptions:
|
|
1133
|
+
staticOptions: [],
|
|
1103
1134
|
dynamicOptions: getBotOptions,
|
|
1104
1135
|
default: (inputs) => {
|
|
1105
1136
|
const options = getBotOptions(inputs);
|
|
@@ -1109,21 +1140,58 @@ function selectBotIdsQuestion() {
|
|
|
1109
1140
|
forgetLastValue: true,
|
|
1110
1141
|
};
|
|
1111
1142
|
}
|
|
1112
|
-
|
|
1143
|
+
const maximumLengthOfDetailsErrorMessageInInputBox = 90;
|
|
1144
|
+
function apiSpecLocationQuestion(includeExistingAPIs = true) {
|
|
1145
|
+
const validationOnAccept = async (input, inputs) => {
|
|
1146
|
+
try {
|
|
1147
|
+
const context = utils_4.createContextV3();
|
|
1148
|
+
const res = await helper_1.listOperations(context, undefined, input, inputs[questionNames_1.QuestionNames.ManifestPath], includeExistingAPIs, false);
|
|
1149
|
+
if (res.isOk()) {
|
|
1150
|
+
inputs.supportedApisFromApiSpec = res.value;
|
|
1151
|
+
}
|
|
1152
|
+
else {
|
|
1153
|
+
const errors = res.error;
|
|
1154
|
+
if ((inputs === null || inputs === void 0 ? void 0 : inputs.platform) === teamsfx_api_1.Platform.CLI) {
|
|
1155
|
+
return errors.map((e) => e.content).join("\n");
|
|
1156
|
+
}
|
|
1157
|
+
if (errors.length === 1 &&
|
|
1158
|
+
errors[0].content.length <= maximumLengthOfDetailsErrorMessageInInputBox) {
|
|
1159
|
+
return errors[0].content;
|
|
1160
|
+
}
|
|
1161
|
+
else {
|
|
1162
|
+
return inputs.platform === teamsfx_api_1.Platform.VSCode
|
|
1163
|
+
? localizeUtils_1.getLocalizedString("core.createProjectQuestion.apiSpec.multipleValidationErrors.vscode.message")
|
|
1164
|
+
: localizeUtils_1.getLocalizedString("core.createProjectQuestion.apiSpec.multipleValidationErrors.message");
|
|
1165
|
+
}
|
|
1166
|
+
}
|
|
1167
|
+
}
|
|
1168
|
+
catch (e) {
|
|
1169
|
+
const error = error_2.assembleError(e);
|
|
1170
|
+
throw error;
|
|
1171
|
+
}
|
|
1172
|
+
};
|
|
1113
1173
|
return {
|
|
1114
1174
|
type: "singleFileOrText",
|
|
1115
1175
|
name: questionNames_1.QuestionNames.ApiSpecLocation,
|
|
1176
|
+
cliShortName: "oapi",
|
|
1177
|
+
cliDescription: "OpenAPI specification file location.",
|
|
1116
1178
|
title: localizeUtils_1.getLocalizedString("core.createProjectQuestion.apiSpec.title"),
|
|
1117
1179
|
forgetLastValue: true,
|
|
1118
1180
|
inputBoxConfig: {
|
|
1181
|
+
type: "innerText",
|
|
1119
1182
|
title: localizeUtils_1.getLocalizedString("core.createProjectQuestion.apiSpec.title"),
|
|
1120
1183
|
placeholder: localizeUtils_1.getLocalizedString("core.createProjectQuestion.apiSpec.placeholder"),
|
|
1121
1184
|
name: "input-api-spec-url",
|
|
1122
1185
|
step: 2,
|
|
1123
|
-
validation:
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1186
|
+
validation: {
|
|
1187
|
+
validFunc: (input, inputs) => {
|
|
1188
|
+
const result = util_1.isValidHttpUrl(input)
|
|
1189
|
+
? undefined
|
|
1190
|
+
: (inputs === null || inputs === void 0 ? void 0 : inputs.platform) === teamsfx_api_1.Platform.CLI
|
|
1191
|
+
? "Please enter a valid URL or local path of your API Specification"
|
|
1192
|
+
: localizeUtils_1.getLocalizedString("core.createProjectQuestion.invalidUrl.message");
|
|
1193
|
+
return Promise.resolve(result);
|
|
1194
|
+
},
|
|
1127
1195
|
},
|
|
1128
1196
|
},
|
|
1129
1197
|
inputOptionItem: {
|
|
@@ -1133,218 +1201,296 @@ function apiSpecLocationQuestion() {
|
|
|
1133
1201
|
filters: {
|
|
1134
1202
|
files: ["json", "yml", "yaml"],
|
|
1135
1203
|
},
|
|
1204
|
+
validation: {
|
|
1205
|
+
validFunc: async (input, inputs) => {
|
|
1206
|
+
if (!util_1.isValidHttpUrl(input) && !(await fs_extra_1.default.pathExists(input))) {
|
|
1207
|
+
return "Please enter a valid URL or local path of your API Specification";
|
|
1208
|
+
}
|
|
1209
|
+
return await validationOnAccept(input, inputs);
|
|
1210
|
+
},
|
|
1211
|
+
},
|
|
1136
1212
|
};
|
|
1137
1213
|
}
|
|
1214
|
+
exports.apiSpecLocationQuestion = apiSpecLocationQuestion;
|
|
1138
1215
|
function openAIPluginManifestLocationQuestion() {
|
|
1216
|
+
// export for unit test
|
|
1139
1217
|
return {
|
|
1140
1218
|
type: "text",
|
|
1141
|
-
name: questionNames_1.QuestionNames.
|
|
1219
|
+
name: questionNames_1.QuestionNames.OpenAIPluginDomain,
|
|
1220
|
+
cliShortName: "oai",
|
|
1142
1221
|
title: localizeUtils_1.getLocalizedString("core.createProjectQuestion.AIPluginManifest.title"),
|
|
1143
1222
|
placeholder: localizeUtils_1.getLocalizedString("core.createProjectQuestion.AIPluginManifest.placeholder"),
|
|
1223
|
+
cliDescription: "OpenAI plugin website domain.",
|
|
1144
1224
|
forgetLastValue: true,
|
|
1145
1225
|
validation: {
|
|
1146
|
-
validFunc:
|
|
1147
|
-
|
|
1226
|
+
validFunc: (input) => {
|
|
1227
|
+
const pattern = /(https?:\/\/)?([a-z0-9-]+(\.[a-z0-9-]+)*)(:[0-9]{1,5})?(\/)?$/i;
|
|
1228
|
+
const match = pattern.test(input);
|
|
1229
|
+
const result = match
|
|
1148
1230
|
? undefined
|
|
1149
|
-
: localizeUtils_1.getLocalizedString("core.createProjectQuestion.
|
|
1231
|
+
: localizeUtils_1.getLocalizedString("core.createProjectQuestion.invalidDomain.message");
|
|
1232
|
+
return Promise.resolve(result);
|
|
1233
|
+
},
|
|
1234
|
+
},
|
|
1235
|
+
additionalValidationOnAccept: {
|
|
1236
|
+
validFunc: async (input, inputs) => {
|
|
1237
|
+
let manifest;
|
|
1238
|
+
try {
|
|
1239
|
+
manifest = await helper_1.OpenAIPluginManifestHelper.loadOpenAIPluginManifest(input);
|
|
1240
|
+
inputs.openAIPluginManifest = manifest;
|
|
1241
|
+
}
|
|
1242
|
+
catch (e) {
|
|
1243
|
+
const error = error_2.assembleError(e);
|
|
1244
|
+
return error.message;
|
|
1245
|
+
}
|
|
1246
|
+
const context = utils_4.createContextV3();
|
|
1247
|
+
try {
|
|
1248
|
+
const res = await helper_1.listOperations(context, manifest, inputs[questionNames_1.QuestionNames.ApiSpecLocation], undefined, true, true);
|
|
1249
|
+
if (res.isOk()) {
|
|
1250
|
+
inputs.supportedApisFromApiSpec = res.value;
|
|
1251
|
+
}
|
|
1252
|
+
else {
|
|
1253
|
+
const errors = res.error;
|
|
1254
|
+
if ((inputs === null || inputs === void 0 ? void 0 : inputs.platform) === teamsfx_api_1.Platform.CLI) {
|
|
1255
|
+
return errors.map((e) => e.content).join("\n");
|
|
1256
|
+
}
|
|
1257
|
+
if (errors.length === 1 &&
|
|
1258
|
+
errors[0].content.length <= maximumLengthOfDetailsErrorMessageInInputBox) {
|
|
1259
|
+
return errors[0].content;
|
|
1260
|
+
}
|
|
1261
|
+
else {
|
|
1262
|
+
return inputs.platform === teamsfx_api_1.Platform.VSCode
|
|
1263
|
+
? localizeUtils_1.getLocalizedString("core.createProjectQuestion.openAiPluginManifest.multipleValidationErrors.vscode.message")
|
|
1264
|
+
: localizeUtils_1.getLocalizedString("core.createProjectQuestion.openAiPluginManifest.multipleValidationErrors.message");
|
|
1265
|
+
}
|
|
1266
|
+
}
|
|
1267
|
+
}
|
|
1268
|
+
catch (e) {
|
|
1269
|
+
const error = error_2.assembleError(e);
|
|
1270
|
+
throw error;
|
|
1271
|
+
}
|
|
1150
1272
|
},
|
|
1151
1273
|
},
|
|
1152
1274
|
};
|
|
1153
1275
|
}
|
|
1154
|
-
|
|
1276
|
+
exports.openAIPluginManifestLocationQuestion = openAIPluginManifestLocationQuestion;
|
|
1277
|
+
function apiOperationQuestion(includeExistingAPIs = true) {
|
|
1278
|
+
// export for unit test
|
|
1155
1279
|
return {
|
|
1156
1280
|
type: "multiSelect",
|
|
1157
1281
|
name: questionNames_1.QuestionNames.ApiOperation,
|
|
1158
1282
|
title: localizeUtils_1.getLocalizedString("core.createProjectQuestion.apiSpec.operation.title"),
|
|
1159
|
-
|
|
1283
|
+
cliDescription: "Specifies API(s) to be used in Copilot plugin.",
|
|
1284
|
+
cliShortName: "api",
|
|
1285
|
+
placeholder: includeExistingAPIs
|
|
1286
|
+
? localizeUtils_1.getLocalizedString("core.createProjectQuestion.apiSpec.operation.placeholder")
|
|
1287
|
+
: localizeUtils_1.getLocalizedString("core.createProjectQuestion.apiSpec.operation.placeholder.skipExisting"),
|
|
1160
1288
|
forgetLastValue: true,
|
|
1161
1289
|
staticOptions: [],
|
|
1162
1290
|
validation: {
|
|
1163
1291
|
minItems: 1,
|
|
1164
1292
|
},
|
|
1165
|
-
dynamicOptions:
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
];
|
|
1293
|
+
dynamicOptions: (inputs) => {
|
|
1294
|
+
if (!inputs.supportedApisFromApiSpec) {
|
|
1295
|
+
throw new error_2.EmptyOptionError(questionNames_1.QuestionNames.ApiOperation, "question");
|
|
1296
|
+
}
|
|
1297
|
+
const operations = inputs.supportedApisFromApiSpec;
|
|
1298
|
+
return operations;
|
|
1172
1299
|
},
|
|
1173
1300
|
};
|
|
1174
1301
|
}
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1302
|
+
exports.apiOperationQuestion = apiOperationQuestion;
|
|
1303
|
+
function getCopilotPluginFeatureId(inputs) {
|
|
1304
|
+
if (teamsfx_api_1.CLIPlatforms.includes(inputs.platform)) {
|
|
1305
|
+
return inputs[questionNames_1.QuestionNames.CopilotPluginDevelopment];
|
|
1306
|
+
}
|
|
1307
|
+
else {
|
|
1308
|
+
return inputs[questionNames_1.QuestionNames.Capabilities];
|
|
1309
|
+
}
|
|
1310
|
+
}
|
|
1311
|
+
function capabilitySubTree() {
|
|
1312
|
+
const node = {
|
|
1313
|
+
data: capabilityQuestion(),
|
|
1178
1314
|
children: [
|
|
1179
1315
|
{
|
|
1180
|
-
|
|
1181
|
-
|
|
1316
|
+
// Notification bot trigger sub-tree
|
|
1317
|
+
condition: { equals: CapabilityOptions.notificationBot().id },
|
|
1318
|
+
data: botTriggerQuestion(),
|
|
1319
|
+
},
|
|
1320
|
+
{
|
|
1321
|
+
// SPFx sub-tree
|
|
1322
|
+
condition: { equals: CapabilityOptions.SPFxTab().id },
|
|
1323
|
+
data: SPFxSolutionQuestion(),
|
|
1182
1324
|
children: [
|
|
1183
1325
|
{
|
|
1184
|
-
|
|
1185
|
-
|
|
1326
|
+
data: { type: "group" },
|
|
1327
|
+
children: [
|
|
1328
|
+
{ data: SPFxPackageSelectQuestion() },
|
|
1329
|
+
{ data: SPFxFrameworkQuestion() },
|
|
1330
|
+
{ data: SPFxWebpartNameQuestion() },
|
|
1331
|
+
],
|
|
1332
|
+
condition: { equals: "new" },
|
|
1186
1333
|
},
|
|
1187
1334
|
{
|
|
1188
|
-
|
|
1189
|
-
|
|
1335
|
+
data: SPFxImportFolderQuestion(),
|
|
1336
|
+
condition: { equals: "import" },
|
|
1190
1337
|
},
|
|
1338
|
+
],
|
|
1339
|
+
},
|
|
1340
|
+
{
|
|
1341
|
+
// office addin import sub-tree
|
|
1342
|
+
condition: { equals: CapabilityOptions.officeAddinImport().id },
|
|
1343
|
+
data: { type: "group", name: questionNames_1.QuestionNames.OfficeAddinImport },
|
|
1344
|
+
children: [
|
|
1191
1345
|
{
|
|
1192
|
-
data:
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
data: botTriggerQuestion(),
|
|
1198
|
-
},
|
|
1199
|
-
{
|
|
1200
|
-
// SPFx sub-tree
|
|
1201
|
-
condition: { equals: CapabilityOptions.SPFxTab().id },
|
|
1202
|
-
data: SPFxSolutionQuestion(),
|
|
1203
|
-
children: [
|
|
1204
|
-
{
|
|
1205
|
-
data: { type: "group" },
|
|
1206
|
-
children: [
|
|
1207
|
-
{ data: SPFxPackageSelectQuestion() },
|
|
1208
|
-
{ data: SPFxFrameworkQuestion() },
|
|
1209
|
-
{ data: SPFxWebpartNameQuestion() },
|
|
1210
|
-
],
|
|
1211
|
-
condition: { equals: "new" },
|
|
1212
|
-
},
|
|
1213
|
-
{
|
|
1214
|
-
data: SPFxImportFolderQuestion(),
|
|
1215
|
-
condition: { equals: "import" },
|
|
1216
|
-
children: [
|
|
1217
|
-
{
|
|
1218
|
-
// auto fill in "app-name" question,
|
|
1219
|
-
// TODO can we make it as a default value of "app-name" question? (need to discuss)
|
|
1220
|
-
data: fillInAppNameFuncQuestion(),
|
|
1221
|
-
},
|
|
1222
|
-
],
|
|
1223
|
-
},
|
|
1224
|
-
],
|
|
1225
|
-
},
|
|
1226
|
-
{
|
|
1227
|
-
// office addin import sub-tree
|
|
1228
|
-
condition: { equals: CapabilityOptions.officeAddinImport().id },
|
|
1229
|
-
data: { type: "group", name: questionNames_1.QuestionNames.OfficeAddinImport },
|
|
1230
|
-
children: [
|
|
1231
|
-
{
|
|
1232
|
-
data: {
|
|
1233
|
-
type: "folder",
|
|
1234
|
-
name: questionNames_1.QuestionNames.OfficeAddinFolder,
|
|
1235
|
-
title: "Existing add-in project folder",
|
|
1236
|
-
},
|
|
1237
|
-
},
|
|
1238
|
-
{
|
|
1239
|
-
data: {
|
|
1240
|
-
type: "singleFile",
|
|
1241
|
-
name: questionNames_1.QuestionNames.OfficeAddinManifest,
|
|
1242
|
-
title: "Select import project manifest file",
|
|
1243
|
-
},
|
|
1244
|
-
},
|
|
1245
|
-
],
|
|
1246
|
-
},
|
|
1247
|
-
{
|
|
1248
|
-
// office addin other items sub-tree
|
|
1249
|
-
condition: {
|
|
1250
|
-
enum: CapabilityOptions.officeAddinItems().map((i) => i.id),
|
|
1251
|
-
},
|
|
1252
|
-
data: officeAddinHostingQuestion(),
|
|
1253
|
-
},
|
|
1254
|
-
{
|
|
1255
|
-
// Copilot plugin from API spec or AI Plugin
|
|
1256
|
-
condition: {
|
|
1257
|
-
enum: [
|
|
1258
|
-
CapabilityOptions.copilotPluginApiSpec().id,
|
|
1259
|
-
CapabilityOptions.copilotPluginOpenAIPlugin().id,
|
|
1260
|
-
],
|
|
1261
|
-
},
|
|
1262
|
-
data: { type: "group", name: questionNames_1.QuestionNames.CopilotPluginExistingApi },
|
|
1263
|
-
children: [
|
|
1264
|
-
{
|
|
1265
|
-
condition: { equals: CapabilityOptions.copilotPluginApiSpec().id },
|
|
1266
|
-
data: apiSpecLocationQuestion(),
|
|
1267
|
-
},
|
|
1268
|
-
{
|
|
1269
|
-
condition: { equals: CapabilityOptions.copilotPluginOpenAIPlugin().id },
|
|
1270
|
-
data: openAIPluginManifestLocationQuestion(),
|
|
1271
|
-
},
|
|
1272
|
-
{
|
|
1273
|
-
data: apiOperationQuestion(),
|
|
1274
|
-
},
|
|
1275
|
-
],
|
|
1276
|
-
},
|
|
1277
|
-
{
|
|
1278
|
-
// programming language
|
|
1279
|
-
data: programmingLanguageQuestion(),
|
|
1280
|
-
condition: {
|
|
1281
|
-
excludesEnum: [
|
|
1282
|
-
CapabilityOptions.copilotPluginApiSpec().id,
|
|
1283
|
-
CapabilityOptions.copilotPluginOpenAIPlugin().id,
|
|
1284
|
-
],
|
|
1285
|
-
},
|
|
1286
|
-
},
|
|
1287
|
-
{
|
|
1288
|
-
// root folder
|
|
1289
|
-
data: rootFolderQuestion(),
|
|
1290
|
-
},
|
|
1291
|
-
{
|
|
1292
|
-
// app name
|
|
1293
|
-
data: appNameQuestion(),
|
|
1294
|
-
},
|
|
1295
|
-
],
|
|
1346
|
+
data: {
|
|
1347
|
+
type: "folder",
|
|
1348
|
+
name: questionNames_1.QuestionNames.OfficeAddinFolder,
|
|
1349
|
+
title: "Existing add-in project folder",
|
|
1350
|
+
},
|
|
1296
1351
|
},
|
|
1297
1352
|
{
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
var _a;
|
|
1304
|
-
return (((_a = inputs.teamsAppFromTdp) === null || _a === void 0 ? void 0 : _a.staticTabs.filter((o) => !!o.websiteUrl)) || [])
|
|
1305
|
-
.length > 0;
|
|
1306
|
-
},
|
|
1307
|
-
data: selectTabWebsiteUrlQuestion(),
|
|
1308
|
-
},
|
|
1309
|
-
{
|
|
1310
|
-
condition: (inputs) => {
|
|
1311
|
-
var _a;
|
|
1312
|
-
return (((_a = inputs.teamsAppFromTdp) === null || _a === void 0 ? void 0 : _a.staticTabs.filter((o) => !!o.contentUrl)) || [])
|
|
1313
|
-
.length > 0;
|
|
1314
|
-
},
|
|
1315
|
-
data: selectTabsContentUrlQuestion(),
|
|
1316
|
-
},
|
|
1317
|
-
],
|
|
1353
|
+
data: {
|
|
1354
|
+
type: "singleFile",
|
|
1355
|
+
name: questionNames_1.QuestionNames.OfficeAddinManifest,
|
|
1356
|
+
title: "Select import project manifest file",
|
|
1357
|
+
},
|
|
1318
1358
|
},
|
|
1359
|
+
],
|
|
1360
|
+
},
|
|
1361
|
+
{
|
|
1362
|
+
// office addin other items sub-tree
|
|
1363
|
+
condition: {
|
|
1364
|
+
enum: CapabilityOptions.officeAddinItems().map((i) => i.id),
|
|
1365
|
+
},
|
|
1366
|
+
data: officeAddinHostingQuestion(),
|
|
1367
|
+
},
|
|
1368
|
+
{
|
|
1369
|
+
// Copilot plugin sub-tree (will show in CLI only)
|
|
1370
|
+
condition: (inputs) => {
|
|
1371
|
+
return (teamsfx_api_1.CLIPlatforms.includes(inputs.platform) &&
|
|
1372
|
+
inputs[questionNames_1.QuestionNames.Capabilities] === CapabilityOptions.copilotPluginCli().id);
|
|
1373
|
+
},
|
|
1374
|
+
data: copilotPluginDevelopmentQuestion(),
|
|
1375
|
+
},
|
|
1376
|
+
{
|
|
1377
|
+
// Copilot plugin from API spec or AI Plugin
|
|
1378
|
+
condition: (inputs) => {
|
|
1379
|
+
return constants_3.copilotPluginExistingApiOptionIds.includes(getCopilotPluginFeatureId(inputs));
|
|
1380
|
+
},
|
|
1381
|
+
data: { type: "group", name: questionNames_1.QuestionNames.CopilotPluginExistingApi },
|
|
1382
|
+
children: [
|
|
1319
1383
|
{
|
|
1320
1384
|
condition: (inputs) => {
|
|
1321
|
-
|
|
1322
|
-
return appDef && utils_2.needBotCode(appDef);
|
|
1385
|
+
return (getCopilotPluginFeatureId(inputs) === CapabilityOptions.copilotPluginApiSpec().id);
|
|
1323
1386
|
},
|
|
1324
|
-
data:
|
|
1387
|
+
data: apiSpecLocationQuestion(),
|
|
1388
|
+
},
|
|
1389
|
+
{
|
|
1390
|
+
condition: (inputs) => {
|
|
1391
|
+
return (getCopilotPluginFeatureId(inputs) ===
|
|
1392
|
+
CapabilityOptions.copilotPluginOpenAIPlugin().id);
|
|
1393
|
+
},
|
|
1394
|
+
data: openAIPluginManifestLocationQuestion(),
|
|
1395
|
+
},
|
|
1396
|
+
{
|
|
1397
|
+
data: apiOperationQuestion(),
|
|
1325
1398
|
},
|
|
1326
1399
|
],
|
|
1327
1400
|
},
|
|
1328
1401
|
{
|
|
1329
|
-
|
|
1330
|
-
data:
|
|
1402
|
+
// programming language
|
|
1403
|
+
data: programmingLanguageQuestion(),
|
|
1404
|
+
condition: (inputs) => {
|
|
1405
|
+
const copilotFeature = getCopilotPluginFeatureId(inputs);
|
|
1406
|
+
if (copilotFeature) {
|
|
1407
|
+
return !constants_3.copilotPluginExistingApiOptionIds.includes(getCopilotPluginFeatureId(inputs));
|
|
1408
|
+
}
|
|
1409
|
+
else {
|
|
1410
|
+
return !!inputs[questionNames_1.QuestionNames.Capabilities];
|
|
1411
|
+
}
|
|
1412
|
+
},
|
|
1413
|
+
},
|
|
1414
|
+
{
|
|
1415
|
+
// root folder
|
|
1416
|
+
data: folderQuestion(),
|
|
1417
|
+
},
|
|
1418
|
+
{
|
|
1419
|
+
// app name
|
|
1420
|
+
data: appNameQuestion(),
|
|
1421
|
+
},
|
|
1422
|
+
],
|
|
1423
|
+
};
|
|
1424
|
+
return node;
|
|
1425
|
+
}
|
|
1426
|
+
exports.capabilitySubTree = capabilitySubTree;
|
|
1427
|
+
function createProjectQuestionNode() {
|
|
1428
|
+
const createProjectQuestion = {
|
|
1429
|
+
data: { type: "group" },
|
|
1430
|
+
children: [
|
|
1431
|
+
{
|
|
1432
|
+
condition: (inputs) => featureFlags_1.isCLIDotNetEnabled() && teamsfx_api_1.CLIPlatforms.includes(inputs.platform),
|
|
1433
|
+
data: runtimeQuestion(),
|
|
1434
|
+
},
|
|
1435
|
+
{
|
|
1436
|
+
condition: (inputs) => inputs.platform === teamsfx_api_1.Platform.VSCode,
|
|
1437
|
+
data: projectTypeQuestion(),
|
|
1438
|
+
cliOptionDisabled: "self",
|
|
1439
|
+
},
|
|
1440
|
+
capabilitySubTree(),
|
|
1441
|
+
{
|
|
1442
|
+
condition: (inputs) => inputs.teamsAppFromTdp && utils_2.isPersonalApp(inputs.teamsAppFromTdp),
|
|
1443
|
+
data: { type: "group", name: questionNames_1.QuestionNames.RepalceTabUrl },
|
|
1444
|
+
cliOptionDisabled: "all",
|
|
1445
|
+
inputsDisabled: "all",
|
|
1331
1446
|
children: [
|
|
1332
1447
|
{
|
|
1333
|
-
|
|
1334
|
-
|
|
1448
|
+
condition: (inputs) => {
|
|
1449
|
+
var _a;
|
|
1450
|
+
return (((_a = inputs.teamsAppFromTdp) === null || _a === void 0 ? void 0 : _a.staticTabs.filter((o) => !!o.websiteUrl)) || []).length >
|
|
1451
|
+
0;
|
|
1452
|
+
},
|
|
1453
|
+
data: selectTabWebsiteUrlQuestion(),
|
|
1454
|
+
},
|
|
1455
|
+
{
|
|
1456
|
+
condition: (inputs) => {
|
|
1457
|
+
var _a;
|
|
1458
|
+
return (((_a = inputs.teamsAppFromTdp) === null || _a === void 0 ? void 0 : _a.staticTabs.filter((o) => !!o.contentUrl)) || []).length >
|
|
1459
|
+
0;
|
|
1460
|
+
},
|
|
1461
|
+
data: selectTabsContentUrlQuestion(),
|
|
1335
1462
|
},
|
|
1336
1463
|
],
|
|
1337
1464
|
},
|
|
1465
|
+
{
|
|
1466
|
+
condition: (inputs) => {
|
|
1467
|
+
const appDef = inputs.teamsAppFromTdp;
|
|
1468
|
+
return appDef && utils_2.needBotCode(appDef);
|
|
1469
|
+
},
|
|
1470
|
+
data: selectBotIdsQuestion(),
|
|
1471
|
+
cliOptionDisabled: "all",
|
|
1472
|
+
inputsDisabled: "all",
|
|
1473
|
+
},
|
|
1338
1474
|
],
|
|
1339
1475
|
};
|
|
1340
1476
|
return createProjectQuestion;
|
|
1341
1477
|
}
|
|
1342
1478
|
exports.createProjectQuestionNode = createProjectQuestionNode;
|
|
1479
|
+
function createSampleProjectQuestionNode() {
|
|
1480
|
+
return {
|
|
1481
|
+
data: sampleSelectQuestion(),
|
|
1482
|
+
children: [
|
|
1483
|
+
{
|
|
1484
|
+
data: folderQuestion(),
|
|
1485
|
+
},
|
|
1486
|
+
],
|
|
1487
|
+
};
|
|
1488
|
+
}
|
|
1489
|
+
exports.createSampleProjectQuestionNode = createSampleProjectQuestionNode;
|
|
1343
1490
|
function createProjectCliHelpNode() {
|
|
1344
1491
|
const node = lodash_1.cloneDeep(createProjectQuestionNode());
|
|
1345
1492
|
const deleteNames = [
|
|
1346
1493
|
questionNames_1.QuestionNames.ProjectType,
|
|
1347
|
-
questionNames_1.QuestionNames.SkipAppName,
|
|
1348
1494
|
questionNames_1.QuestionNames.OfficeAddinImport,
|
|
1349
1495
|
questionNames_1.QuestionNames.OfficeAddinHost,
|
|
1350
1496
|
questionNames_1.QuestionNames.RepalceTabUrl,
|
|
@@ -1356,10 +1502,10 @@ function createProjectCliHelpNode() {
|
|
|
1356
1502
|
}
|
|
1357
1503
|
if (!featureFlags_1.isCopilotPluginEnabled()) {
|
|
1358
1504
|
deleteNames.push(questionNames_1.QuestionNames.CopilotPluginExistingApi);
|
|
1505
|
+
deleteNames.push(questionNames_1.QuestionNames.CopilotPluginDevelopment);
|
|
1359
1506
|
}
|
|
1360
1507
|
trimQuestionTreeForCliHelp(node, deleteNames);
|
|
1361
|
-
|
|
1362
|
-
return subTree;
|
|
1508
|
+
return node;
|
|
1363
1509
|
}
|
|
1364
1510
|
exports.createProjectCliHelpNode = createProjectCliHelpNode;
|
|
1365
1511
|
function trimQuestionTreeForCliHelp(node, deleteNames) {
|