@sap-ux/ui5-library-inquirer 0.4.47 → 0.5.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/dist/index.d.ts CHANGED
@@ -16,5 +16,7 @@ declare function getPrompts(promptOptions?: UI5LibraryPromptOptions): Promise<Qu
16
16
  * @returns the prompt answers
17
17
  */
18
18
  declare function prompt(promptOptions?: UI5LibraryPromptOptions, adapter?: InquirerAdapter): Promise<UI5LibraryAnswers>;
19
- export { getPrompts, prompt, type UI5LibraryPromptOptions, type UI5LibraryAnswers, type InquirerAdapter };
19
+ export { getPrompts, prompt };
20
+ export type { UI5LibraryAnswers, UI5LibraryPromptOptions } from './types';
21
+ export type { InquirerAdapter } from '@sap-ux/inquirer-common';
20
22
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js CHANGED
@@ -18,8 +18,10 @@ const inquirer_autocomplete_prompt_1 = __importDefault(require("inquirer-autocom
18
18
  async function getPrompts(promptOptions) {
19
19
  const filterOptions = {
20
20
  useCache: true,
21
- includeMaintained: true
21
+ includeMaintained: true,
22
+ onlyNpmVersion: true
22
23
  };
24
+ // Get only npm-available UI5 versions to avoid post-selection resolution
23
25
  const ui5Versions = await (0, ui5_info_1.getUI5Versions)(filterOptions);
24
26
  const ui5LibPromptInputs = {
25
27
  targetFolder: promptOptions?.targetFolder,
@@ -36,11 +38,14 @@ async function getPrompts(promptOptions) {
36
38
  * @returns the prompt answers
37
39
  */
38
40
  async function prompt(promptOptions, adapter) {
39
- const ui5LibPrompts = await exports.getPrompts(promptOptions);
41
+ const ui5LibPrompts = await getPrompts(promptOptions);
40
42
  const pm = adapter ? adapter.promptModule : inquirer_1.default;
41
43
  if (pm && promptOptions?.useAutocomplete) {
42
44
  pm.registerPrompt('autocomplete', inquirer_autocomplete_prompt_1.default);
43
45
  }
44
- return adapter ? adapter.prompt(ui5LibPrompts) : inquirer_1.default.prompt(ui5LibPrompts);
46
+ const answers = adapter
47
+ ? await adapter.prompt(ui5LibPrompts)
48
+ : await inquirer_1.default.prompt(ui5LibPrompts);
49
+ return answers;
45
50
  }
46
51
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@sap-ux/ui5-library-inquirer",
3
3
  "description": "Prompts module that can provide prompts for UI5 library writer",
4
- "version": "0.4.47",
4
+ "version": "0.5.0",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "https://github.com/SAP/open-ux-tools.git",
@@ -22,7 +22,8 @@
22
22
  "dependencies": {
23
23
  "i18next": "25.3.0",
24
24
  "inquirer-autocomplete-prompt": "2.0.1",
25
- "@sap-ux/inquirer-common": "0.7.44",
25
+ "@sap-ux/inquirer-common": "0.7.45",
26
+ "@sap-ux/logger": "0.7.0",
26
27
  "@sap-ux/project-input-validator": "0.6.22",
27
28
  "@sap-ux/ui5-info": "0.12.3"
28
29
  },