@sap-ux/ui5-library-inquirer 0.3.8 → 0.3.10
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/i18n.js +5 -1
- package/package.json +3 -3
package/dist/i18n.js
CHANGED
|
@@ -7,12 +7,16 @@ exports.initI18n = initI18n;
|
|
|
7
7
|
exports.t = t;
|
|
8
8
|
const i18next_1 = __importDefault(require("i18next"));
|
|
9
9
|
const ui5_library_inquirer_i18n_json_1 = __importDefault(require("./translations/ui5-library-inquirer.i18n.json"));
|
|
10
|
+
const inquirer_common_1 = require("@sap-ux/inquirer-common");
|
|
10
11
|
const ui5LibI18nNamespace = 'ui5-library-inquirer';
|
|
11
12
|
/**
|
|
12
13
|
* Initialize i18next with the translations for this module.
|
|
13
14
|
*/
|
|
14
15
|
async function initI18n() {
|
|
15
|
-
await i18next_1.default.init({ lng: 'en', fallbackLng: 'en' }
|
|
16
|
+
await i18next_1.default.init({ lng: 'en', fallbackLng: 'en' });
|
|
17
|
+
i18next_1.default.addResourceBundle('en', ui5LibI18nNamespace, ui5_library_inquirer_i18n_json_1.default);
|
|
18
|
+
// add the inquirer common i18n resource bundle to ensure all translations are available
|
|
19
|
+
(0, inquirer_common_1.addi18nResourceBundle)();
|
|
16
20
|
}
|
|
17
21
|
/**
|
|
18
22
|
* Helper function facading the call to i18next. Unless a namespace option is provided the local namespace will be used.
|
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.3.
|
|
4
|
+
"version": "0.3.10",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/SAP/open-ux-tools.git",
|
|
@@ -22,9 +22,9 @@
|
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"i18next": "23.5.1",
|
|
24
24
|
"inquirer-autocomplete-prompt": "2.0.1",
|
|
25
|
-
"@sap-ux/inquirer-common": "0.4.
|
|
25
|
+
"@sap-ux/inquirer-common": "0.4.9",
|
|
26
26
|
"@sap-ux/project-input-validator": "0.3.3",
|
|
27
|
-
"@sap-ux/ui5-info": "0.8.
|
|
27
|
+
"@sap-ux/ui5-info": "0.8.2"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
30
|
"inquirer": "8.2.6",
|