iobroker.webui 1.25.0 → 1.25.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/README.md +7 -0
- package/dist/importmaps/importmap-config.d.ts +1 -1
- package/dist/importmaps/importmap-config.js +1 -1
- package/gulpfile.mjs +3 -3
- package/io-package.json +27 -27
- package/package.json +2 -2
- package/www/dist/frontend/common/IobrokerHandler.js +11 -9
- package/www/dist/frontend/config/IobrokerWebuiBindingsEditor.js +1 -1
- package/www/dist/frontend/config/IobrokerWebuiSignalPropertyEditor.js +1 -1
- package/www/dist/frontend/generated/Properties.json +1 -1
- package/www/dist/frontend/helper/XmlHelper.js +13 -1
- package/www/dist/importmaps/importmap-config.js +1 -1
- package/www/index.html +1 -1
- package/www/node_modules/{iobroker-webcomponent-object-selector → @iobroker/webcomponent-selectid-dialog}/dist/iobrokerSelectId.es.js +8982 -8796
- package/www/node_modules/{iobroker-webcomponent-object-selector → @iobroker/webcomponent-selectid-dialog}/dist/selectIdHelper.js +15 -12
- package/www/node_modules/@iobroker/webcomponent-selectid-dialog/dist/socket.iob.js +1 -0
- package/binary/iobroker-webcomponent-object-selector-0.0.1.tgz +0 -0
- package/www/node_modules/iobroker-webcomponent-object-selector/dist/socket.iob.js +0 -441
package/README.md
CHANGED
|
@@ -133,6 +133,13 @@ runtime.html?screenName=screen2
|
|
|
133
133
|
Placeholder for next versions:
|
|
134
134
|
### __WORK IN PROGRESS__
|
|
135
135
|
-->
|
|
136
|
+
### 1.25.2 (2025-02-05)
|
|
137
|
+
- fix null error on props
|
|
138
|
+
|
|
139
|
+
### 1.25.1 (2025-01-24)
|
|
140
|
+
- escape xml
|
|
141
|
+
- switch to official selector package
|
|
142
|
+
|
|
136
143
|
### 1.25.0 (2025-01-21)
|
|
137
144
|
- fix bindings in custom controls
|
|
138
145
|
|
|
@@ -32,7 +32,7 @@ const importMapConfig = {
|
|
|
32
32
|
"wunderbaum": "./node_modules/wunderbaum/dist/wunderbaum.esm.min.js",
|
|
33
33
|
"wunderbaum/": "./node_modules/wunderbaum/",
|
|
34
34
|
"toastify-js": "./node_modules/toastify-js/src/toastify-es.js",
|
|
35
|
-
"iobroker
|
|
35
|
+
"@iobroker/webcomponent-selectid-dialog/": "./node_modules/@iobroker/webcomponent-selectid-dialog/"
|
|
36
36
|
}
|
|
37
37
|
};
|
|
38
38
|
//@ts-ignore
|
package/gulpfile.mjs
CHANGED
|
@@ -68,9 +68,9 @@ function copyNodeFiles() {
|
|
|
68
68
|
"toastify-js/src/toastify-es.js",
|
|
69
69
|
"toastify-js/src/toastify.css",
|
|
70
70
|
"dayjs/dayjs.min.js",
|
|
71
|
-
"iobroker
|
|
72
|
-
"iobroker
|
|
73
|
-
"iobroker
|
|
71
|
+
"@iobroker/webcomponent-selectid-dialog/dist/iobrokerSelectId.es.js",
|
|
72
|
+
"@iobroker/webcomponent-selectid-dialog/dist/selectIdHelper.js",
|
|
73
|
+
"@iobroker/webcomponent-selectid-dialog/dist/socket.iob.js"
|
|
74
74
|
]
|
|
75
75
|
|
|
76
76
|
runtimeModules = runtimeModules.map(x => './node_modules/' + x)
|
package/io-package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"common": {
|
|
3
3
|
"name": "webui",
|
|
4
|
-
"version": "1.25.
|
|
4
|
+
"version": "1.25.2",
|
|
5
5
|
"titleLang": {
|
|
6
6
|
"en": "webui",
|
|
7
7
|
"de": "webui",
|
|
@@ -29,6 +29,32 @@
|
|
|
29
29
|
"zh-cn": "使用万维网传送器的高锰用户接口"
|
|
30
30
|
},
|
|
31
31
|
"news": {
|
|
32
|
+
"1.25.2": {
|
|
33
|
+
"en": "fix null error on props",
|
|
34
|
+
"de": "nullfehler auf requisiten beheben",
|
|
35
|
+
"ru": "исправить ошибку null на реквизитов",
|
|
36
|
+
"pt": "corrigir erro nulo em adereços",
|
|
37
|
+
"nl": "fix null-fout op rekwisieten",
|
|
38
|
+
"fr": "correction de l'erreur null sur les accessoires",
|
|
39
|
+
"it": "correzione di errore null su oggetti",
|
|
40
|
+
"es": "solucionar error null en props",
|
|
41
|
+
"pl": "naprawić błąd null na rekwizytach",
|
|
42
|
+
"uk": "виправити помилку null на пропсах",
|
|
43
|
+
"zh-cn": "修复道具上的无效错误"
|
|
44
|
+
},
|
|
45
|
+
"1.25.1": {
|
|
46
|
+
"en": "escape xml\nswitch to official selector package",
|
|
47
|
+
"de": "entkommen xml\nwechsel zum offiziellen auswahlpaket",
|
|
48
|
+
"ru": "xml\nпереход на официальный пакет селектора",
|
|
49
|
+
"pt": "escapar xml\nmudar para o pacote seletor oficial",
|
|
50
|
+
"nl": "ontsnappen xml\nschakel over op officiële selectiepakket",
|
|
51
|
+
"fr": "évasion xml\npasser au sélecteur officiel",
|
|
52
|
+
"it": "fuga xml\npassare al pacchetto selettore ufficiale",
|
|
53
|
+
"es": "escape xml\ncambiar al paquete oficial selector",
|
|
54
|
+
"pl": "escape xml\nprzełączanie na oficjalny pakiet wyboru",
|
|
55
|
+
"uk": "втеча xml\nвимикач на офіційному пакеті selector",
|
|
56
|
+
"zh-cn": "越狱 xml\n切换到正式选择软件包"
|
|
57
|
+
},
|
|
32
58
|
"1.25.0": {
|
|
33
59
|
"en": "fix bindings in custom controls",
|
|
34
60
|
"de": "fixe bindungen in benutzerdefinierten steuerungen",
|
|
@@ -93,32 +119,6 @@
|
|
|
93
119
|
"pl": "miejmy nadzieję, że uda się naprawić przesyłkę po zmianie nazwy",
|
|
94
120
|
"uk": "сподіваємось на те, що завантаження пакету змінено",
|
|
95
121
|
"zh-cn": "希望用更改的名称修正软件包上传"
|
|
96
|
-
},
|
|
97
|
-
"1.24.0": {
|
|
98
|
-
"en": "cleanup www dir",
|
|
99
|
-
"de": "reinigung www dr",
|
|
100
|
-
"ru": "очистка www dir",
|
|
101
|
-
"pt": "limpeza www dir",
|
|
102
|
-
"nl": "opruimen www dir",
|
|
103
|
-
"fr": "nettoyage www dir",
|
|
104
|
-
"it": "pulizia www dir",
|
|
105
|
-
"es": "cleanup www dir",
|
|
106
|
-
"pl": "czyszczenie dir www",
|
|
107
|
-
"uk": "очищувач www dir",
|
|
108
|
-
"zh-cn": "清理 www dir"
|
|
109
|
-
},
|
|
110
|
-
"1.23.2": {
|
|
111
|
-
"en": "one more fix in gulpfile",
|
|
112
|
-
"de": "noch eine fix in gulpfile",
|
|
113
|
-
"ru": "еще одно исправление в gulpfile",
|
|
114
|
-
"pt": "mais uma correção no gulpfile",
|
|
115
|
-
"nl": "nog een fix in gulpfile",
|
|
116
|
-
"fr": "une autre correction dans gulpfile",
|
|
117
|
-
"it": "un altro fix in gulpfile",
|
|
118
|
-
"es": "uno más se fijan en el archivo del gulp",
|
|
119
|
-
"pl": "jeszcze jeden fix w gulpfile",
|
|
120
|
-
"uk": "ще одна фіксація в gulpfile",
|
|
121
|
-
"zh-cn": "再加一个固醇"
|
|
122
122
|
}
|
|
123
123
|
},
|
|
124
124
|
"icon": "logo.png",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "iobroker.webui",
|
|
3
|
-
"version": "1.25.
|
|
3
|
+
"version": "1.25.2",
|
|
4
4
|
"description": "ioBroker webui",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/backend/main.js",
|
|
@@ -54,6 +54,7 @@
|
|
|
54
54
|
"@blockly/zoom-to-fit": "^6.0.12",
|
|
55
55
|
"@iobroker/socket-client": "^4.0.0",
|
|
56
56
|
"@iobroker/testing": "^5.0.0",
|
|
57
|
+
"@iobroker/webcomponent-selectid-dialog": "^1.0.3",
|
|
57
58
|
"@node-projects/base-custom-webcomponent": "0.27.8",
|
|
58
59
|
"@node-projects/lean-he-esm": "^3.3.0",
|
|
59
60
|
"@node-projects/node-html-parser-esm": "^6.2.0",
|
|
@@ -82,7 +83,6 @@
|
|
|
82
83
|
"gulp": "^5.0.0",
|
|
83
84
|
"gulp-git": "^2.11.0",
|
|
84
85
|
"gulp-replace": "^1.1.4",
|
|
85
|
-
"iobroker-webcomponent-object-selector": "file:binary/iobroker-webcomponent-object-selector-0.0.1.tgz",
|
|
86
86
|
"long": "^5.2.4",
|
|
87
87
|
"mobile-drag-drop": "^3.0.0-rc.0",
|
|
88
88
|
"mocha": "^11.0.1",
|
|
@@ -268,15 +268,17 @@ export class IobrokerHandler {
|
|
|
268
268
|
try {
|
|
269
269
|
control = await this._getObjectFromFile(this.configPath + "controls/" + name + '.control');
|
|
270
270
|
//TODO: remove in a later version, fixes old props
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
let
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
271
|
+
if (control.properties) {
|
|
272
|
+
let k = Object.keys(control.properties);
|
|
273
|
+
if (k.length && typeof control.properties[k[0]] == 'string') {
|
|
274
|
+
for (let p in control.properties) {
|
|
275
|
+
let prp = control.properties[p];
|
|
276
|
+
if (prp.startsWith("[")) {
|
|
277
|
+
control.properties[p] = { type: 'enum', values: JSON.parse(prp) };
|
|
278
|
+
}
|
|
279
|
+
else {
|
|
280
|
+
control.properties[p] = { type: prp };
|
|
281
|
+
}
|
|
280
282
|
}
|
|
281
283
|
}
|
|
282
284
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BindingsEditor } from "@node-projects/web-component-designer-visualization-addons";
|
|
2
|
-
import { openSelectIdDialog } from "iobroker
|
|
2
|
+
import { openSelectIdDialog } from "@iobroker/webcomponent-selectid-dialog/dist/selectIdHelper.js";
|
|
3
3
|
//@ts-ignore
|
|
4
4
|
export class IobrokerWebuiBindingsEditor extends BindingsEditor {
|
|
5
5
|
static is = 'iobroker-webui-bindings-editor';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { SignalPropertyEditor } from "@node-projects/web-component-designer-visualization-addons";
|
|
2
|
-
import { openSelectIdDialog } from "iobroker
|
|
2
|
+
import { openSelectIdDialog } from "@iobroker/webcomponent-selectid-dialog/dist/selectIdHelper.js";
|
|
3
3
|
export class IobrokerWebuiSignalPropertyEditor extends SignalPropertyEditor {
|
|
4
4
|
constructor(property, shell) {
|
|
5
5
|
super(property, shell);
|
|
@@ -1,6 +1,18 @@
|
|
|
1
1
|
export function escapeCData(text) {
|
|
2
2
|
return text.replaceAll("]]>", "]]]]><![CDATA[>");
|
|
3
3
|
}
|
|
4
|
+
export function escapeXml(text) {
|
|
5
|
+
return text.replace(/[<>&'"]/g, c => {
|
|
6
|
+
switch (c) {
|
|
7
|
+
case '<': return '<';
|
|
8
|
+
case '>': return '>';
|
|
9
|
+
case '&': return '&';
|
|
10
|
+
case '\'': return ''';
|
|
11
|
+
case '"': return '"';
|
|
12
|
+
}
|
|
13
|
+
return null;
|
|
14
|
+
});
|
|
15
|
+
}
|
|
4
16
|
export function parseXml(xml) {
|
|
5
17
|
let doc = new DOMParser().parseFromString(xml, "text/xml");
|
|
6
18
|
let obj = {};
|
|
@@ -67,7 +79,7 @@ export function convertToXml(type, screen) {
|
|
|
67
79
|
if (screen.properties[p].type)
|
|
68
80
|
xml += ` type="${screen.properties[p].type}"`;
|
|
69
81
|
if (screen.properties[p].default)
|
|
70
|
-
xml += ` default="${screen.properties[p].default}"`;
|
|
82
|
+
xml += ` default="${escapeXml(screen.properties[p].default)}"`;
|
|
71
83
|
if (screen.properties[p].values)
|
|
72
84
|
xml += ` values="${screen.properties[p].values.join('|')}"`;
|
|
73
85
|
if (screen.properties[p].internal)
|
|
@@ -32,7 +32,7 @@ const importMapConfig = {
|
|
|
32
32
|
"wunderbaum": "./node_modules/wunderbaum/dist/wunderbaum.esm.min.js",
|
|
33
33
|
"wunderbaum/": "./node_modules/wunderbaum/",
|
|
34
34
|
"toastify-js": "./node_modules/toastify-js/src/toastify-es.js",
|
|
35
|
-
"iobroker
|
|
35
|
+
"@iobroker/webcomponent-selectid-dialog/": "./node_modules/@iobroker/webcomponent-selectid-dialog/"
|
|
36
36
|
}
|
|
37
37
|
};
|
|
38
38
|
//@ts-ignore
|
package/www/index.html
CHANGED
|
@@ -218,7 +218,7 @@
|
|
|
218
218
|
</button>
|
|
219
219
|
<button data-command="save" title="save" disabled><img src="./node_modules/@node-projects/web-component-designer/assets/icons/save.svg"></button>
|
|
220
220
|
<div style="margin-left: 30px;">
|
|
221
|
-
webui - 1.25.
|
|
221
|
+
webui - 1.25.2 - 7cb9a07
|
|
222
222
|
</div>
|
|
223
223
|
<button style="margin-left: 30px;" data-command="paste" title="paste" disabled><img
|
|
224
224
|
src="./node_modules/@node-projects/web-component-designer/assets/icons/paste.svg"></button>
|