Skip to content

Commit b138c33

Browse files
committed
Merge branch 'pskelin-master'
2 parents 0799909 + a12d85f commit b138c33

32 files changed

+415
-3622
lines changed
Lines changed: 21 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,28 @@
11
<!DOCTYPE html>
22
<html>
3-
<head>
4-
<meta charset="utf-8">
5-
<title>UI5 Benchmark</title>
6-
<script
7-
id="sap-ui-bootstrap"
8-
src="./dist/resources/sap-ui-core.js"
9-
data-sap-ui-libs="sap.m"
10-
data-sap-ui-compatVersion="edge"
11-
data-sap-ui-async="true"
12-
data-sap-ui-onInit="module:sap/ui/core/ComponentSupport"
13-
data-sap-ui-resourceroots='{
14-
"ui5.benchmark": "./dist/"
15-
}'>
163

4+
<head>
5+
<meta charset="utf-8" />
6+
<title>OpenUI5</title>
7+
<script id="sap-ui-bootstrap"
8+
src="./dist/resources/sap-ui-boot.js"
9+
data-sap-ui-language="en"
10+
data-sap-ui-compat-version="edge"
11+
data-sap-ui-modules="[ui5/benchmark/Component-bundle]"
12+
data-sap-ui-on-init="ui5/benchmark/startUp@./dist/"
13+
data-sap-ui-preload-lib-css="sap.ui.core"
14+
data-sap-ui-async="true" async>
1715
</script>
18-
<link href="/css/currentStyle.css" rel="stylesheet" />
16+
<style>
17+
.danger {
18+
background-color: red;
19+
}
20+
</style>
1921
</head>
22+
2023
<body class="container" id="content">
21-
<div data-sap-ui-component data-name="ui5.benchmark" data-id="container" data-settings='{"id" : "benchmark"}'></div>
24+
<span class="preloadicon glyphicon glyphicon-remove" aria-hidden="true"></span>
2225
</body>
23-
</html>
26+
<link href="/css/currentStyle.css" rel="stylesheet"/>
27+
28+
</html>

frameworks/non-keyed/openui5/package-lock.json

Lines changed: 5 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

frameworks/non-keyed/openui5/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,19 @@
33
"version": "1.0.0",
44
"description": "UI5 Benchmark",
55
"js-framework-benchmark": {
6-
"frameworkVersion": "1.119.1",
6+
"frameworkVersion": "1.120.0",
77
"frameworkHomeURL": "https://openui5.org/"
88
},
99
"scripts": {
1010
"build-dev": "ui5 serve -o index.html",
11-
"build-prod": "ui5 build --include-all-dependencies --clean-dest"
11+
"build-prod": "ui5 build self-contained --include-all-dependencies --clean-dest"
1212
},
1313
"homepage": "https://github.com/krausest/js-framework-benchmark",
1414
"repository": {
1515
"type": "git",
1616
"url": "https://github.com/krausest/js-framework-benchmark.git"
1717
},
18-
"devDependencies": {
18+
"devDependencies": {
1919
"@ui5/cli": "^3"
2020
}
2121
}

frameworks/non-keyed/openui5/ui5.yaml

Lines changed: 36 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,42 @@
1-
specVersion: "3.0"
1+
specVersion: "2.2"
2+
type: application
23
metadata:
34
name: ui5.benchmark
4-
type: application
5+
56
framework:
67
name: OpenUI5
7-
version: "1.119.1"
8+
version: "1.120.0"
89
libraries:
9-
- name: sap.m
1010
- name: sap.ui.core
11-
- name: sap.ui.table
11+
builder:
12+
bundles:
13+
- bundleDefinition:
14+
name: ui5/benchmark/Component-bundle.js
15+
defaultFileTypes:
16+
- ".js"
17+
- ".json"
18+
- ".xml"
19+
- ".properties"
20+
- ".css"
21+
sections:
22+
- mode: provided
23+
filters:
24+
- ui5loader-autoconfig.js
25+
- ui5loader.js
26+
- sap/ui/core/theming/ThemeManager.js
27+
- sap/ui/core/date/
28+
- sap/ui/events/jquery/EventSimulation.js
29+
resolve: true
30+
- mode: preload
31+
filters:
32+
- "!sap/ui/core/Core.js"
33+
- ui5/benchmark/
34+
- sap/ui/core/Popup.js
35+
- sap/ui/dom/rect.js
36+
resolve: true
37+
resolveConditional: false
38+
sort: true
39+
bundleOptions:
40+
optimize: true
41+
usePredefineCalls: true
42+
numberOfParts: 1

frameworks/non-keyed/openui5/webapp/Component.js

Lines changed: 0 additions & 27 deletions
This file was deleted.
Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
sap.ui.define(["sap/ui/core/Control", "./ControlRenderer", "./Store"], (Control, ControlRenderer, Store) => {
2+
return Control.extend("ui5.benchmark.Control", {
3+
metadata: {
4+
properties: {
5+
text: { type: "string", defaultValue: "asdf" },
6+
rows: { type: "object[]", defaultValue: [] },
7+
selected: {type: "int", defaultValue: undefined}
8+
},
9+
},
10+
init() {
11+
this.store = new Store();
12+
},
13+
onclick(e) {
14+
switch (e.target?.id) {
15+
case "run":
16+
this.run();
17+
break;
18+
case "runlots":
19+
this.runlots();
20+
break;
21+
case "add":
22+
this.add();
23+
break;
24+
case "update":
25+
this.update();
26+
break;
27+
case "clear":
28+
this.clear();
29+
break;
30+
case "swaprows":
31+
this.swaprows();
32+
break;
33+
}
34+
35+
const { action, id } = e.target.dataset;
36+
if (action && id) {
37+
this[action](id);
38+
}
39+
},
40+
run() {
41+
this.store.run()
42+
this.setRows(this.store.data);
43+
},
44+
runlots() {
45+
this.store.runlots();
46+
this.setRows(this.store.data);
47+
},
48+
add() {
49+
this.store.add();
50+
this.setRows(this.store.data);
51+
},
52+
update() {
53+
this.store.update();
54+
this.setRows(this.store.data);
55+
this.setText(`${Date.now()}`)
56+
},
57+
clear() {
58+
this.store.clear();
59+
this.setRows(this.store.data)
60+
},
61+
swaprows() {
62+
this.store.swaprows();
63+
this.setRows(this.store.data);
64+
},
65+
remove(id) {
66+
this.store.delete(parseInt(id));
67+
this.setRows(this.store.data);
68+
},
69+
select(id) {
70+
this.setSelected(parseInt(id));
71+
},
72+
renderer: ControlRenderer,
73+
})
74+
})

0 commit comments

Comments
 (0)