@sap-ux/ui5-application-inquirer 0.18.3 → 0.18.5
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/dist/prompts/index.js
CHANGED
|
@@ -48,7 +48,7 @@ async function getQuestions(ui5Versions, promptOptions, capCdsInfo, isYUI = fals
|
|
|
48
48
|
[types_1.promptNames.enableTypeScript]: (0, prompts1_1.getEnableTypeScriptPrompt)(),
|
|
49
49
|
[types_1.promptNames.addDeployConfig]: (0, prompts1_1.getAddDeployConfigPrompt)(targetDir, promptOptions?.addDeployConfig, isCapProject),
|
|
50
50
|
[types_1.promptNames.addFlpConfig]: (0, prompts1_1.getAddFlpConfigPrompt)(promptOptions?.addFlpConfig),
|
|
51
|
-
[types_1.promptNames.enableVirtualEndpoints]: (0, prompts1_1.getEnableVirtualEndpoints)(),
|
|
51
|
+
[types_1.promptNames.enableVirtualEndpoints]: (0, prompts1_1.getEnableVirtualEndpoints)(capCdsInfo),
|
|
52
52
|
[types_1.promptNames.showAdvanced]: (0, prompts2_1.getShowAdvancedPrompt)(),
|
|
53
53
|
[types_1.promptNames.ui5Theme]: (0, prompts2_1.getUI5ThemePrompt)(),
|
|
54
54
|
[types_1.promptNames.enableEslint]: (0, prompts2_1.getEnableEsLintPrompt)(),
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { promptNames } from '../types';
|
|
2
2
|
import type { UI5Version } from '@sap-ux/ui5-info';
|
|
3
3
|
import type { UI5ApplicationPromptOptions, UI5ApplicationQuestion } from '../types';
|
|
4
|
+
import type { CdsUi5PluginInfo } from '@sap-ux/project-access';
|
|
4
5
|
/**
|
|
5
6
|
* Gets the `name` prompt.
|
|
6
7
|
*
|
|
@@ -72,7 +73,8 @@ export declare function getAddFlpConfigPrompt(addFlpConfigOptions?: UI5Applicati
|
|
|
72
73
|
/**
|
|
73
74
|
* Get the `enableVirtualEndpoints` prompt.
|
|
74
75
|
*
|
|
76
|
+
* @param capCdsInfo optional CDS UI5 plugin information for CAP projects
|
|
75
77
|
* @returns the `enableVirtualEndpoints` prompt
|
|
76
78
|
*/
|
|
77
|
-
export declare function getEnableVirtualEndpoints(): UI5ApplicationQuestion;
|
|
79
|
+
export declare function getEnableVirtualEndpoints(capCdsInfo?: CdsUi5PluginInfo): UI5ApplicationQuestion;
|
|
78
80
|
//# sourceMappingURL=prompts1.d.ts.map
|
package/dist/prompts/prompts1.js
CHANGED
|
@@ -244,9 +244,10 @@ function getAddFlpConfigPrompt(addFlpConfigOptions) {
|
|
|
244
244
|
/**
|
|
245
245
|
* Get the `enableVirtualEndpoints` prompt.
|
|
246
246
|
*
|
|
247
|
+
* @param capCdsInfo optional CDS UI5 plugin information for CAP projects
|
|
247
248
|
* @returns the `enableVirtualEndpoints` prompt
|
|
248
249
|
*/
|
|
249
|
-
function getEnableVirtualEndpoints() {
|
|
250
|
+
function getEnableVirtualEndpoints(capCdsInfo) {
|
|
250
251
|
return {
|
|
251
252
|
type: 'confirm',
|
|
252
253
|
name: types_1.promptNames.enableVirtualEndpoints,
|
|
@@ -255,7 +256,14 @@ function getEnableVirtualEndpoints() {
|
|
|
255
256
|
breadcrumb: (0, i18n_1.t)('prompts.enableVirtualEndpoints.breadcrumb')
|
|
256
257
|
},
|
|
257
258
|
message: () => (0, i18n_1.t)('prompts.enableVirtualEndpoints.message'),
|
|
258
|
-
default: true
|
|
259
|
+
default: true,
|
|
260
|
+
when: (answers) => {
|
|
261
|
+
if (!capCdsInfo) {
|
|
262
|
+
return true;
|
|
263
|
+
}
|
|
264
|
+
// For CAP Node.js: only show when cds-plugin-ui5 is present OR TypeScript is selected
|
|
265
|
+
return capCdsInfo.hasCdsUi5Plugin || answers.enableTypeScript === true;
|
|
266
|
+
}
|
|
259
267
|
};
|
|
260
268
|
}
|
|
261
269
|
//# sourceMappingURL=prompts1.js.map
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sap-ux/ui5-application-inquirer",
|
|
3
3
|
"description": "Prompts module that can prompt users for inputs required for UI5 application writing",
|
|
4
|
-
"version": "0.18.
|
|
4
|
+
"version": "0.18.5",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/SAP/open-ux-tools.git",
|
|
@@ -23,10 +23,10 @@
|
|
|
23
23
|
"inquirer-autocomplete-prompt": "2.0.1",
|
|
24
24
|
"lodash": "4.18.1",
|
|
25
25
|
"semver": "7.7.4",
|
|
26
|
-
"@sap-ux/inquirer-common": "0.13.
|
|
27
|
-
"@sap-ux/project-access": "1.38.
|
|
28
|
-
"@sap-ux/
|
|
29
|
-
"@sap-ux/
|
|
26
|
+
"@sap-ux/inquirer-common": "0.13.2",
|
|
27
|
+
"@sap-ux/project-access": "1.38.1",
|
|
28
|
+
"@sap-ux/project-input-validator": "0.7.2",
|
|
29
|
+
"@sap-ux/ui5-info": "0.14.0"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@sap-devx/yeoman-ui-types": "1.25.0",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"@types/lodash": "4.17.24",
|
|
36
36
|
"@types/semver": "7.7.1",
|
|
37
37
|
"inquirer": "8.2.7",
|
|
38
|
-
"@sap-ux/cap-config-writer": "0.13.
|
|
38
|
+
"@sap-ux/cap-config-writer": "0.13.3"
|
|
39
39
|
},
|
|
40
40
|
"engines": {
|
|
41
41
|
"node": ">=22.x"
|