homematic-manager 3.0.0-beta.27 → 3.0.0-beta.28

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.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@homematic-manager/backend",
3
- "version": "3.0.0-beta.27",
3
+ "version": "3.0.0-beta.28",
4
4
  "type": "module",
5
5
  "description": "Homematic Manager backend: XML-RPC/BIN-RPC clients and callback servers, caches, optional ReGa",
6
6
  "license": "AGPL-3.0-or-later",
@@ -80,14 +80,25 @@ export class TranslationLookup {
80
80
  return undefined;
81
81
  }
82
82
  }
83
- /** `CHANNEL_TYPE|SUFFIX` before `SUFFIX`, each as given and upper-cased. */
83
+ /**
84
+ * `CHANNEL_TYPE|SUFFIX` before `SUFFIX`, each as given and upper-cased - and then the same two
85
+ * again without a `SHORT_` or `LONG_` prefix (B-75). The string tables label a link's parameters
86
+ * by the name behind the key press: `ON_TIME`, `JT_ON`, `PROFILE_ACTION_TYPE` are in them,
87
+ * `SHORT_ON_TIME` and `LONG_ON_TIME` are not - 2.7.1 stripped the prefix for a link's help
88
+ * texts (homematic-manager.js:3475), and a MASTER parameter that happens to start with one
89
+ * (`LONG_PRESS_TIME`) still finds its own entry first.
90
+ */
84
91
  function keys(suffix, channelType) {
85
- const bare = identifiers(suffix);
86
- if (channelType === undefined || channelType === '') {
87
- return bare;
88
- }
89
- const qualified = identifiers(channelType).map((type) => `${type}|${suffix}`);
90
- return dedupe([...qualified, ...qualified.map((key) => key.toUpperCase()), ...bare]);
92
+ const stripped = suffix.replace(/^(?:SHORT|LONG)_/i, '');
93
+ const forms = stripped === suffix ? [suffix] : [suffix, stripped];
94
+ return dedupe(forms.flatMap((form) => {
95
+ const bare = identifiers(form);
96
+ if (channelType === undefined || channelType === '') {
97
+ return bare;
98
+ }
99
+ const qualified = identifiers(channelType).map((type) => `${type}|${form}`);
100
+ return [...qualified, ...qualified.map((key) => key.toUpperCase()), ...bare];
101
+ }));
91
102
  }
92
103
  /** The key as it was given, plus its upper-case form where that differs. */
93
104
  function identifiers(value) {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@homematic-manager/core",
3
- "version": "3.0.0-beta.27",
3
+ "version": "3.0.0-beta.28",
4
4
  "type": "module",
5
5
  "description": "Pure domain logic of the Homematic Manager: no I/O, no DOM",
6
6
  "license": "AGPL-3.0-or-later",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "homematic-manager",
3
- "version": "3.0.0-beta.27",
3
+ "version": "3.0.0-beta.28",
4
4
  "type": "module",
5
5
  "description": "Configure and administer Homematic and HomematicIP devices - devices and channels, direct links, paramsets, RSSI, service messages, events and an RPC console - from a local HTTP/WebSocket server that also serves the web UI",
6
6
  "keywords": [
@@ -67,8 +67,8 @@
67
67
  "hm-simulator": "^1.0.0"
68
68
  },
69
69
  "dependencies": {
70
- "@homematic-manager/backend": "3.0.0-beta.27",
71
- "@homematic-manager/core": "3.0.0-beta.27",
70
+ "@homematic-manager/backend": "3.0.0-beta.28",
71
+ "@homematic-manager/core": "3.0.0-beta.28",
72
72
  "binrpc": "^4.2.0",
73
73
  "homematic-rega": "^2.0.0",
74
74
  "homematic-xmlrpc": "^2.0.0",