@sap-ux/ui5-application-writer 1.9.1 → 1.9.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/package.json CHANGED
@@ -9,7 +9,7 @@
9
9
  "bugs": {
10
10
  "url": "https://github.com/SAP/open-ux-tools/issues?q=is%3Aopen+is%3Aissue+label%3Abug+label%3Aui5-application-writer"
11
11
  },
12
- "version": "1.9.1",
12
+ "version": "1.9.2",
13
13
  "license": "Apache-2.0",
14
14
  "main": "dist/index.js",
15
15
  "files": [
@@ -37,7 +37,7 @@
37
37
  "@types/mem-fs-editor": "7.0.1",
38
38
  "@types/semver": "7.7.1",
39
39
  "fs-extra": "11.3.4",
40
- "@sap-ux/eslint-plugin-fiori-tools": "10.2.1",
40
+ "@sap-ux/eslint-plugin-fiori-tools": "10.2.2",
41
41
  "@sap-ux/project-access": "1.38.1"
42
42
  },
43
43
  "engines": {
@@ -215,10 +215,17 @@
215
215
  // set up test service for local testing
216
216
  server.init();
217
217
  // initialize the ushell sandbox component
218
- sap.ui.require(["sap/ushell/Container"], async function (Container) {
219
- Container.createRenderer(true).then(function (component) {
220
- component.placeAt("content");
221
- });
218
+ sap.ui.require(["sap/ushell/Container"], function (Container) {
219
+ (typeof Container.createRendererInternal === 'function'
220
+ ? Container.createRendererInternal(undefined, true)
221
+ : Container.createRenderer(undefined, true))
222
+ .then(function (component) {
223
+ component.placeAt("content");
224
+ })
225
+ .catch(function () {
226
+ // support older versions of ui5
227
+ Container.createRenderer().placeAt("content");
228
+ });
222
229
  });
223
230
  });
224
231
  });
@@ -249,15 +256,17 @@
249
256
  Core.ready(() => {
250
257
  registerSAPFonts();
251
258
  // initialize the ushell sandbox component
252
- sap.ui.require(["sap/ushell/Container"], async function (Container) {
253
- try {
254
- Container.createRenderer(true).then(function (component) {
255
- component.placeAt("content");
256
- });
257
- } catch (error) {
258
- // support older versions of ui5
259
- Container.createRenderer().placeAt("content");
260
- }
259
+ sap.ui.require(["sap/ushell/Container"], function (Container) {
260
+ (typeof Container.createRendererInternal === 'function'
261
+ ? Container.createRendererInternal(undefined, true)
262
+ : Container.createRenderer(undefined, true))
263
+ .then(function (component) {
264
+ component.placeAt("content");
265
+ })
266
+ .catch(function () {
267
+ // support older versions of ui5
268
+ Container.createRenderer().placeAt("content");
269
+ });
261
270
  });
262
271
  });
263
272
  });