homebridge-intratone 0.4.1 → 0.4.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 CHANGED
@@ -2,6 +2,15 @@
2
2
 
3
3
  All notable changes to `homebridge-intratone`. Versions follow [semver](https://semver.org/).
4
4
 
5
+ ## [0.4.2] - 2026-11-12
6
+
7
+ ### Fixed
8
+
9
+ - The settings form still did not appear on first-time setup: config-ui-x only renders the schema
10
+ form once a config block exists (`pluginConfig.length`), which is empty before the first save.
11
+ The custom page now creates an empty config block before calling `showSchemaForm()`, so the
12
+ phone-number form shows on a fresh install. (0.4.1 only addressed the render timing.)
13
+
5
14
  ## [0.4.1] - 2026-11-12
6
15
 
7
16
  ### Fixed
@@ -136,6 +145,7 @@ two-way audio are out of scope.
136
145
  masked.
137
146
  - MIT license.
138
147
 
148
+ [0.4.2]: https://github.com/jtoucas-DIMO/Homebridge-Intratone/releases/tag/v0.4.2
139
149
  [0.4.1]: https://github.com/jtoucas-DIMO/Homebridge-Intratone/releases/tag/v0.4.1
140
150
  [0.4.0]: https://github.com/jtoucas-DIMO/Homebridge-Intratone/releases/tag/v0.4.0
141
151
  [0.3.0]: https://github.com/jtoucas-DIMO/Homebridge-Intratone/releases/tag/v0.3.0
@@ -14,22 +14,29 @@
14
14
  }
15
15
  started = true;
16
16
 
17
- // Render the standard schema form (country code, phone number, service, Advanced, …).
18
- try {
19
- homebridge.showSchemaForm();
20
- } catch (error) {
21
- console.error('showSchemaForm failed', error);
22
- }
23
-
24
17
  const info = document.getElementById('intratone-info');
25
18
  const doors = document.getElementById('intratone-doors');
26
19
 
27
20
  let block;
28
21
  try {
29
- const configs = await homebridge.getPluginConfig();
22
+ let configs = await homebridge.getPluginConfig();
23
+ if (!configs.length) {
24
+ // config-ui-x renders the schema form only once a config block exists (it gates on
25
+ // pluginConfig.length). Create an empty one so the phone-number form appears on first setup.
26
+ await homebridge.updatePluginConfig([{ platform: 'Intratone', name: 'Intratone' }]);
27
+ configs = await homebridge.getPluginConfig();
28
+ }
30
29
  block = configs[0] || { platform: 'Intratone', name: 'Intratone' };
31
30
  } catch (error) {
32
- return; // Leave the standard form; nothing else to add.
31
+ try { homebridge.showSchemaForm(); } catch (e) { console.error(e); }
32
+ return;
33
+ }
34
+
35
+ // With a config block present, the standard form (phone number, service, Advanced) renders.
36
+ try {
37
+ homebridge.showSchemaForm();
38
+ } catch (error) {
39
+ console.error('showSchemaForm failed', error);
33
40
  }
34
41
 
35
42
  let status;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "homebridge-intratone",
3
3
  "displayName": "Intratone",
4
- "version": "0.4.1",
4
+ "version": "0.4.2",
5
5
  "description": "Unofficial Homebridge plugin to open Intratone / Cogelec doors and gates from HomeKit and Matter (remote open, no doorbell).",
6
6
  "license": "MIT",
7
7
  "author": "jtoucas-DIMO",