@ui5/builder 4.0.0 → 4.0.2
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/CHANGELOG.md +16 -1
- package/lib/lbt/analyzer/XMLTemplateAnalyzer.js +1 -1
- package/lib/lbt/bundle/Builder.js +1 -1
- package/lib/lbt/resources/ResourceCollector.js +1 -1
- package/lib/processors/bootstrapHtmlTransformer.js +1 -1
- package/lib/processors/manifestEnhancer.js +9 -4
- package/lib/tasks/bundlers/generateFlexChangesBundle.js +1 -0
- package/package.json +9 -7
package/CHANGELOG.md
CHANGED
|
@@ -2,7 +2,20 @@
|
|
|
2
2
|
All notable changes to this project will be documented in this file.
|
|
3
3
|
This project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
|
4
4
|
|
|
5
|
-
A list of unreleased changes can be found [here](https://github.com/SAP/ui5-builder/compare/v4.0.
|
|
5
|
+
A list of unreleased changes can be found [here](https://github.com/SAP/ui5-builder/compare/v4.0.2...HEAD).
|
|
6
|
+
|
|
7
|
+
<a name="v4.0.2"></a>
|
|
8
|
+
## [v4.0.2] - 2024-08-18
|
|
9
|
+
### Dependency Updates
|
|
10
|
+
- Bump cheerio from 1.0.0-rc.12 to 1.0.0 ([#1078](https://github.com/SAP/ui5-builder/issues/1078)) [`d80c79d`](https://github.com/SAP/ui5-builder/commit/d80c79d5578516cf533e649e73d55602afa8b908)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
<a name="v4.0.1"></a>
|
|
14
|
+
## [v4.0.1] - 2024-07-29
|
|
15
|
+
### Bug Fixes
|
|
16
|
+
- **manifestEnhancer:** Improve error handling [`16a4e78`](https://github.com/SAP/ui5-builder/commit/16a4e785ab71f8714b3926aa0bb8573f8da4dd08)
|
|
17
|
+
- **manifestEnhancer:** Fix fallbackLocale handling [`421a375`](https://github.com/SAP/ui5-builder/commit/421a37577c11c50d938bc59f3b8fca371a703cd3)
|
|
18
|
+
|
|
6
19
|
|
|
7
20
|
<a name="v4.0.0"></a>
|
|
8
21
|
## [v4.0.0] - 2024-07-23
|
|
@@ -919,6 +932,8 @@ to load the custom bundle file instead.
|
|
|
919
932
|
|
|
920
933
|
### Features
|
|
921
934
|
- Add ability to configure component preloads and custom bundles [`2241e5f`](https://github.com/SAP/ui5-builder/commit/2241e5ff98fd95f1f80cc74959655ae7a9c660e7)
|
|
935
|
+
[v4.0.2]: https://github.com/SAP/ui5-builder/compare/v4.0.1...v4.0.2
|
|
936
|
+
[v4.0.1]: https://github.com/SAP/ui5-builder/compare/v4.0.0...v4.0.1
|
|
922
937
|
[v4.0.0]: https://github.com/SAP/ui5-builder/compare/v3.3.0...v4.0.0
|
|
923
938
|
[v3.5.1]: https://github.com/SAP/ui5-builder/compare/v3.5.0...v3.5.1
|
|
924
939
|
[v3.5.0]: https://github.com/SAP/ui5-builder/compare/v3.4.1...v3.5.0
|
|
@@ -140,7 +140,7 @@ class ResourceCollector {
|
|
|
140
140
|
let subModuleInfo;
|
|
141
141
|
try {
|
|
142
142
|
subModuleInfo = await this._pool.getModuleInfo(subModule);
|
|
143
|
-
} catch
|
|
143
|
+
} catch {
|
|
144
144
|
log.verbose(` Missing submodule ${subModule} included by ${moduleInfo.name}`);
|
|
145
145
|
}
|
|
146
146
|
if (subModuleInfo) {
|
|
@@ -15,7 +15,7 @@ function isAbsoluteUrl(url) {
|
|
|
15
15
|
const parsedUrl = new URL(url);
|
|
16
16
|
// URL with ui5 protocol shouldn't be treated as absolute URL and will be handled separately
|
|
17
17
|
return parsedUrl.protocol !== "ui5:";
|
|
18
|
-
} catch
|
|
18
|
+
} catch {
|
|
19
19
|
// URL constructor without base requires absolute URL and throws an error for relative URLs
|
|
20
20
|
return false;
|
|
21
21
|
}
|
|
@@ -212,7 +212,7 @@ class ManifestEnhancer {
|
|
|
212
212
|
}
|
|
213
213
|
const supportedLocales = await this.findSupportedLocales(normalizedBundleUrl);
|
|
214
214
|
if (!isTerminologyBundle && supportedLocales.length > 0) {
|
|
215
|
-
if (fallbackLocale && !supportedLocales.includes(fallbackLocale)) {
|
|
215
|
+
if (typeof fallbackLocale === "string" && !supportedLocales.includes(fallbackLocale)) {
|
|
216
216
|
log.error(
|
|
217
217
|
`${this.filePath}: ` +
|
|
218
218
|
`Generated supported locales ('${supportedLocales.join("', '")}') for ` +
|
|
@@ -221,7 +221,7 @@ class ManifestEnhancer {
|
|
|
221
221
|
"properties file for defined fallbackLocale or configure another available fallbackLocale"
|
|
222
222
|
);
|
|
223
223
|
return [];
|
|
224
|
-
} else if (
|
|
224
|
+
} else if (typeof fallbackLocale === "undefined" && !supportedLocales.includes("en")) {
|
|
225
225
|
log.warn(
|
|
226
226
|
`${this.filePath}: ` +
|
|
227
227
|
`Generated supported locales ('${supportedLocales.join("', '")}') for ` +
|
|
@@ -359,7 +359,7 @@ class ManifestEnhancer {
|
|
|
359
359
|
this.runInvoked = true;
|
|
360
360
|
|
|
361
361
|
if (!this.manifest._version) {
|
|
362
|
-
log.verbose(`${this.filePath}: _version is not defined. No supportedLocales
|
|
362
|
+
log.verbose(`${this.filePath}: _version is not defined. No supportedLocales can be generated`);
|
|
363
363
|
return;
|
|
364
364
|
}
|
|
365
365
|
|
|
@@ -368,6 +368,11 @@ class ManifestEnhancer {
|
|
|
368
368
|
return;
|
|
369
369
|
}
|
|
370
370
|
|
|
371
|
+
if (!this.manifest["sap.app"]?.id) {
|
|
372
|
+
log.verbose(`${this.filePath}: sap.app/id is not defined. No supportedLocales can be generated`);
|
|
373
|
+
return;
|
|
374
|
+
}
|
|
375
|
+
|
|
371
376
|
if (this.manifest["sap.app"].type === "library") {
|
|
372
377
|
await this.processSapUi5LibraryI18n();
|
|
373
378
|
} else {
|
|
@@ -74,6 +74,7 @@ export default async function({workspace, taskUtil, options = {}}) {
|
|
|
74
74
|
manifestContent["sap.ui5"].dependencies = manifestContent["sap.ui5"].dependencies || {};
|
|
75
75
|
if (!Array.isArray(manifestContent["sap.ui5"].dependencies.minUI5Version)) {
|
|
76
76
|
manifestContent["sap.ui5"].dependencies.minUI5Version =
|
|
77
|
+
// eslint-disable-next-line no-constant-binary-expression
|
|
77
78
|
[manifestContent["sap.ui5"].dependencies.minUI5Version] || [""];
|
|
78
79
|
}
|
|
79
80
|
return manifestContent["sap.ui5"].dependencies.minUI5Version;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ui5/builder",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.2",
|
|
4
4
|
"description": "UI5 Tooling - Builder",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "SAP SE",
|
|
@@ -124,7 +124,7 @@
|
|
|
124
124
|
"@jridgewell/sourcemap-codec": "^1.5.0",
|
|
125
125
|
"@ui5/fs": "^4.0.0",
|
|
126
126
|
"@ui5/logger": "^4.0.1",
|
|
127
|
-
"cheerio": "1.0.0
|
|
127
|
+
"cheerio": "1.0.0",
|
|
128
128
|
"escape-unicode": "^0.2.0",
|
|
129
129
|
"escope": "^4.0.0",
|
|
130
130
|
"espree": "^10.1.0",
|
|
@@ -134,24 +134,26 @@
|
|
|
134
134
|
"pretty-data": "^0.40.0",
|
|
135
135
|
"rimraf": "^6.0.1",
|
|
136
136
|
"semver": "^7.6.3",
|
|
137
|
-
"terser": "^5.31.
|
|
137
|
+
"terser": "^5.31.6",
|
|
138
138
|
"workerpool": "^9.1.3",
|
|
139
139
|
"xml2js": "^0.6.2"
|
|
140
140
|
},
|
|
141
141
|
"devDependencies": {
|
|
142
|
+
"@eslint/js": "^9.8.0",
|
|
142
143
|
"@istanbuljs/esm-loader-hook": "^0.2.0",
|
|
143
144
|
"@jridgewell/trace-mapping": "^0.3.25",
|
|
144
|
-
"@ui5/project": "^4.0.
|
|
145
|
+
"@ui5/project": "^4.0.2",
|
|
145
146
|
"ava": "^6.1.3",
|
|
146
147
|
"chokidar-cli": "^3.0.0",
|
|
147
148
|
"cross-env": "^7.0.3",
|
|
148
149
|
"depcheck": "^1.4.7",
|
|
149
150
|
"docdash": "^2.0.2",
|
|
150
|
-
"eslint": "^
|
|
151
|
+
"eslint": "^9.9.0",
|
|
151
152
|
"eslint-config-google": "^0.14.0",
|
|
152
|
-
"eslint-plugin-ava": "^
|
|
153
|
-
"eslint-plugin-jsdoc": "^
|
|
153
|
+
"eslint-plugin-ava": "^15.0.1",
|
|
154
|
+
"eslint-plugin-jsdoc": "^50.2.2",
|
|
154
155
|
"esmock": "^2.6.7",
|
|
156
|
+
"globals": "^15.9.0",
|
|
155
157
|
"line-column": "^1.0.2",
|
|
156
158
|
"nyc": "^17.0.0",
|
|
157
159
|
"open-cli": "^8.0.0",
|